mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-01 23:40:25 +00:00
rewrite: why-ads & more-gems modals
This commit is contained in:
parent
ca5e931730
commit
7b023cc00a
5 changed files with 26 additions and 46 deletions
|
|
@ -1,43 +0,0 @@
|
|||
<modals:>
|
||||
|
||||
|
||||
<!-- Buy more Gems modal -->
|
||||
<app:modals:modal modalId='more-gems-modal' header="Out Of Gems">
|
||||
<app:rewards:user-gems />
|
||||
<p>Oops, out of Gems, which are used to buy special items! Habit is an open source project, and can use all the help it can get - buy more Gems to receive this pet, and consider it a donation to the contributors.</p>
|
||||
<@footer>
|
||||
<a data-dismiss="modal" x-bind="click:showStripe" class="btn btn-success btn-large">Buy More Gems</a><span class='gem-cost'>Not enough Gems</span>
|
||||
</@footer>
|
||||
</app:modals:modal>
|
||||
|
||||
<app:modals:modal modalId="why-ads-modal" header="Why Ads?">
|
||||
<p>
|
||||
Habit is an open source project, and can use all the help it can get - consider this a donation to the contributors. You also get 20 Gems from the purchase, which you can use to buy special items.
|
||||
</p>
|
||||
<p>
|
||||
"Hey, I backed the Kickstarter!" - follow <a target="_blank" href="http://community.habitrpg.com/node/22">these instructions</a>.
|
||||
</p>
|
||||
<@footer>
|
||||
<button data-dismiss="modal" class="btn btn-success">Ok</button>
|
||||
</@footer>
|
||||
</app:modals:modal>
|
||||
|
||||
|
||||
|
||||
<!-- $modal-template -->
|
||||
<modal: nonvoid>
|
||||
{{#if @noDismiss}}
|
||||
<div data-action="backdrop" class="modal-backdrop"></div>
|
||||
{{/}}
|
||||
<div class="modal {{#unless @noDismiss}}hide{{/}}" id={{@modalId}} role="dialog">
|
||||
{#if @header}
|
||||
<div class="modal-header">
|
||||
{{#unless @noDismiss}}<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>{{/}}
|
||||
<h3>{unescaped @header}</h3>
|
||||
</div>
|
||||
{/}
|
||||
<div class="modal-body">{@content}</div>
|
||||
{{#if @footer}}
|
||||
<div class="modal-footer">{{@footer}}</div>
|
||||
{{/}}
|
||||
</div>
|
||||
|
|
@ -2,4 +2,6 @@ include ./achievements
|
|||
include ./login
|
||||
include ./reroll
|
||||
include ./death
|
||||
include ./new-stuff
|
||||
include ./new-stuff
|
||||
include ./why-ads
|
||||
include ./more-gems
|
||||
10
views/shared/modals/more-gems.jade
Normal file
10
views/shared/modals/more-gems.jade
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
div(modal='modals.moreGems', header='Out Of Gems')
|
||||
.modal-header
|
||||
h3 Out Of Gems
|
||||
.modal-body
|
||||
include ../gems
|
||||
p.
|
||||
Oops, out of Gems, which are used to buy special items! Habit is an open source project, and can use all the help
|
||||
it can get - buy more Gems to receive this pet, and consider it a donation to the contributors.
|
||||
.modal-footer
|
||||
button.btn.btn-default.cancel(ng-click='modals.moreGems = false') Cancel
|
||||
11
views/shared/modals/why-ads.jade
Normal file
11
views/shared/modals/why-ads.jade
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
div(modal='modals.whyAds')
|
||||
.modal-header
|
||||
h3 Why Ads?
|
||||
.modal-body
|
||||
p.
|
||||
Habit is an open source project, and can use all the help it can get - consider this a donation to the contributors. You also get 20 Gems from the purchase, which you can use to buy special items.
|
||||
p
|
||||
| "Hey, I backed the Kickstarter!" - follow
|
||||
a(target='_blank', href='http://community.habitrpg.com/node/22') these instructions.
|
||||
.modal-footer
|
||||
button.btn.btn-default.cancel(ng-click='modals.whyAds = false') Ok
|
||||
|
|
@ -1,9 +1,9 @@
|
|||
div(ng-if='authenticated() && user.flags.ads!="hide"')
|
||||
span.pull-right
|
||||
span.pull-right(ng-if='list.type!="reward"')
|
||||
a(x-bind='click:showStripe', tooltip='Remove Ads')
|
||||
i.icon-remove
|
||||
br
|
||||
a(href='#', data-target='#why-ads-modal', data-toggle='modal', tooltip='Why Ads?')
|
||||
a(ng-click='modals.whyAds=true', tooltip='Why Ads?')
|
||||
i.icon-question-sign
|
||||
|
||||
div(ng-if='list.type=="habit"', habitrpg-adsense)
|
||||
|
|
|
|||
Loading…
Reference in a new issue