Skip to content

Commit

Permalink
add vip donate button
Browse files Browse the repository at this point in the history
  • Loading branch information
taobataoma committed May 6, 2017
1 parent 0632522 commit 397430d
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 5 deletions.
3 changes: 3 additions & 0 deletions modules/core/client/app/trans-string-en.js
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,9 @@
USERS_LIST: 'Users',
USERS_UPDATE: 'Update',

//vip,rules views
BUTTON_DNATE: 'Donate',

//user settings
SETTINGS: 'Settings',
BUTTON_SAVE_PROFILE: 'Save Profile',
Expand Down
3 changes: 3 additions & 0 deletions modules/core/client/app/trans-string-zh.js
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,9 @@
USERS_LIST: '用户列表',
USERS_UPDATE: '修改',

//vip,rules views
BUTTON_DNATE: '捐 赠',

//user settings
SETTINGS: '控制面版',
BUTTON_SAVE_PROFILE: '保存',
Expand Down
7 changes: 6 additions & 1 deletion modules/core/client/less/mt-var.less
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
@import (reference) "../../../../public/lib/bootstrap/less/variables.less";
@import (reference) "../../../../public/lib/bootstrap/less/mixins/buttons.less";


@mt-base-color: #ff6600;

@comment-background-default: lighten(@gray-base, 95%);
@comment-background-default: lighten(@gray-base, 95%);

@btn-mt-color: #fff;
@btn-mt-bg: @mt-base-color;
@btn-mt-border: darken(@mt-base-color, 5%);
34 changes: 32 additions & 2 deletions modules/core/client/less/mt.less
Original file line number Diff line number Diff line change
Expand Up @@ -527,7 +527,37 @@
margin-left: 0;
.flag-icon {
font-size: 15px;
margin-left: 0px;
margin-left: 0;
margin-right: 10px;
}
}
}

.btn-donate {
@media (min-width: @screen-sm) {
position: absolute;
width: 70%;
top: 50px;
}
@media (max-width: @screen-sm) {
position: relative;
width: 95%;
margin: 30px 5px;
}
}

.btn-donate-hide {
@media (min-width: @screen-xs-max) {
display: none;
}
}

.btn-donate-show {
@media (max-width: @screen-xs-max) {
display: none;
}
}

.btn-mt {
.button-variant(@btn-mt-color; @btn-mt-bg; @btn-mt-border);
}

3 changes: 2 additions & 1 deletion modules/vip/client/templates/vip-zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@

如果你想修改规则内容, 请编辑 .md 文件, 它存放于 `modules/vip/client/templates/vip-xx.md`.

`xx` 代表语言标识符, 如 `zh`,`en` 等.
`xx` 代表语言标识符, 如 `zh`,`en` 等.

8 changes: 7 additions & 1 deletion modules/vip/client/views/vip.client.view.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
<section class="container padding-top-10" ng-controller="VipController as vm" ng-init="vm.init();">
<div class="row">
<div class="col-md-10 col-md-offset-1">
<div class="col-sm-2 col-md-2 btn-donate-hide">
<button class="btn btn-mt btn-donate center-block">{{'BUTTON_DNATE' | translate}}</button>
</div>
<div class="col-sm-10 col-md-9 col-md-offset-1">
<div marked src="'/modules/vip/client/templates/vip-'+vm.lang+'.md'">
</div>
</div>
<div class="col-sm-2 col-md-2 btn-donate-show">
<button class="btn btn-mt btn-donate center-block">{{'BUTTON_DNATE' | translate}}</button>
</div>
</div>
</section>

0 comments on commit 397430d

Please sign in to comment.