├── CNAME ├── config ├── prod.env.js ├── test.env.js ├── dev.env.js └── index.js ├── src ├── assets │ ├── logo.png │ └── img │ │ ├── icon_nav_msg.png │ │ ├── icon_nav_tab.png │ │ ├── pic_article.png │ │ ├── icon_nav_cell.png │ │ ├── icon_nav_icons.png │ │ ├── icon_nav_panel.png │ │ ├── icon_nav_toast.png │ │ ├── mobile-qrcode.png │ │ ├── icon_nav_article.png │ │ ├── icon_nav_button.png │ │ ├── icon_nav_dialog.png │ │ ├── icon_nav_progress.png │ │ ├── screen-dashboard.png │ │ ├── icon_nav_search_bar.png │ │ ├── screen-mobile-index.png │ │ └── icon_nav_actionSheet.png ├── scss │ ├── mobile.scss │ ├── weui │ │ ├── base │ │ │ ├── mixin │ │ │ │ ├── _mobile.scss │ │ │ │ ├── _text.scss │ │ │ │ ├── _setArrow.scss │ │ │ │ └── _setOnepx.scss │ │ │ ├── variable │ │ │ │ ├── _weui-grid.scss │ │ │ │ ├── _weui-progress.scss │ │ │ │ ├── _weui-dialog.scss │ │ │ │ ├── _weui-msg.scss │ │ │ │ ├── _global.scss │ │ │ │ ├── _color.scss │ │ │ │ ├── _weui-cell.scss │ │ │ │ └── _weui-button.scss │ │ │ ├── reset.scss │ │ │ └── fn.scss │ │ ├── widget │ │ │ ├── weui-flex │ │ │ │ └── weui-flex.scss │ │ │ ├── weui-cell │ │ │ │ ├── weui-check.scss │ │ │ │ ├── weui-form.scss │ │ │ │ ├── weui-check │ │ │ │ │ ├── weui-check_common.scss │ │ │ │ │ ├── weui-radio.scss │ │ │ │ │ └── weui-checkbox.scss │ │ │ │ ├── weui-form │ │ │ │ │ ├── weui-vcode.scss │ │ │ │ │ ├── weui-select.scss │ │ │ │ │ ├── weui-form_common.scss │ │ │ │ │ └── weui-form-preview.scss │ │ │ │ ├── weui-gallery.scss │ │ │ │ ├── weui-access.scss │ │ │ │ ├── weui-switch.scss │ │ │ │ ├── weui-cell_global.scss │ │ │ │ └── weui-uploader.scss │ │ │ ├── weui-button │ │ │ │ ├── weui-btn_warn.scss │ │ │ │ ├── weui-btn_primary.scss │ │ │ │ ├── weui-btn_default.scss │ │ │ │ ├── weui-btn_disabled.scss │ │ │ │ ├── weui-btn_plain.scss │ │ │ │ ├── weui-btn_global.scss │ │ │ │ └── weui-button.scss │ │ │ ├── weui-tab │ │ │ │ ├── weui-tab.scss │ │ │ │ ├── navbar.scss │ │ │ │ └── tabbar.scss │ │ │ ├── weui-progress │ │ │ │ └── weui-progress.scss │ │ │ ├── weui-tips │ │ │ │ ├── weui-mask.scss │ │ │ │ ├── weui-toast.scss │ │ │ │ ├── weui-loadmore.scss │ │ │ │ ├── weui-actionsheet.scss │ │ │ │ └── weui-dialog.scss │ │ │ ├── weui-page │ │ │ │ ├── weui-article.scss │ │ │ │ └── weui-msg.scss │ │ │ ├── weui-footer │ │ │ │ └── weui-footer.scss │ │ │ ├── weui-animate │ │ │ │ └── weui-animate.scss │ │ │ ├── weui-panel │ │ │ │ └── weui-panel.scss │ │ │ ├── weui-grid │ │ │ │ └── weui-grid.scss │ │ │ ├── weui-agree │ │ │ │ └── weui-agree.scss │ │ │ ├── weui-media-box │ │ │ │ └── weui-media-box.scss │ │ │ ├── weui-picker │ │ │ │ └── weui-picker.scss │ │ │ ├── weui-loading │ │ │ │ └── weui-loading.scss │ │ │ └── weui-searchbar │ │ │ │ └── weui-searchbar.scss │ │ ├── weui.scss │ │ └── icon │ │ │ └── weui-icon_font.scss │ ├── _mixins.scss │ ├── _variable.scss │ └── app.scss ├── components │ ├── ui │ │ ├── Tab │ │ │ ├── index.vue │ │ │ ├── TabItem.vue │ │ │ └── Tab.vue │ │ ├── valueToPoint.js │ │ ├── Modal │ │ │ ├── modal.scss │ │ │ └── Modal.vue │ │ ├── AxisLabel.vue │ │ ├── SVGGraph.vue │ │ ├── popup │ │ │ ├── Popup.vue │ │ │ └── popup.scss │ │ ├── NiceFileInput.vue │ │ ├── image │ │ │ └── ImageExtract.vue │ │ ├── Chart.vue │ │ ├── Menu.vue │ │ ├── Navi.vue │ │ └── Grid.vue │ ├── page │ │ ├── components │ │ │ ├── Message.vue │ │ │ ├── Notification.vue │ │ │ ├── Tooltips.vue │ │ │ ├── Modals.vue │ │ │ ├── Tabs.vue │ │ │ ├── FileInput.vue │ │ │ ├── Content.vue │ │ │ └── Icons.vue │ │ ├── filters │ │ │ ├── FilterBy.vue │ │ │ └── OrderBy.vue │ │ ├── animation │ │ │ ├── Keyframes.vue │ │ │ └── Transition.vue │ │ ├── tools │ │ │ └── ImageExtract.vue │ │ ├── Header.vue │ │ ├── grids │ │ │ ├── Flex.vue │ │ │ └── Table.vue │ │ ├── charts │ │ │ ├── Pie.vue │ │ │ ├── Doughnut.vue │ │ │ ├── Bar.vue │ │ │ ├── PolarArea.vue │ │ │ └── Radar.vue │ │ └── SideNaviBar.vue │ └── mobile │ │ ├── tab │ │ └── Index.vue │ │ ├── navbar │ │ └── Index.vue │ │ ├── message │ │ └── Index.vue │ │ ├── action-sheet │ │ └── Index.vue │ │ ├── tabbar │ │ └── Index.vue │ │ ├── icons │ │ └── Index.vue │ │ ├── article │ │ └── Index.vue │ │ ├── button │ │ └── Index.vue │ │ ├── search-bar │ │ └── Index.vue │ │ ├── dialog │ │ └── Index.vue │ │ ├── progress │ │ └── Index.vue │ │ ├── toast │ │ └── Index.vue │ │ └── Index.vue ├── filter │ ├── wrap.js │ ├── reverse.js │ └── currency.js ├── lib │ ├── uuid.js │ └── util.js ├── component-loader.js ├── index.html ├── mobile.html ├── directive │ └── demo.js ├── Mobile.vue ├── main.js ├── wap.js ├── chart.html └── Desktop.vue ├── .babelrc ├── test ├── unit │ ├── .eslintrc │ ├── specs │ │ └── Hello.spec.js │ ├── index.js │ └── karma.conf.js └── e2e │ ├── specs │ └── test.js │ ├── custom-assertions │ └── elementCount.js │ ├── nightwatch.conf.js │ └── runner.js ├── .editorconfig ├── .gitignore ├── git_commit.template ├── .eslintrc.js ├── README.md └── package.json /CNAME: -------------------------------------------------------------------------------- 1 | vue-kit.ihsueh.com -------------------------------------------------------------------------------- /config/prod.env.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | NODE_ENV: '"production"' 3 | } 4 | -------------------------------------------------------------------------------- /src/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/logo.png -------------------------------------------------------------------------------- /src/scss/mobile.scss: -------------------------------------------------------------------------------- 1 | @import "./weui/weui.scss"; 2 | body { 3 | background: #fbf9fe; 4 | } -------------------------------------------------------------------------------- /src/assets/img/icon_nav_msg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_msg.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_tab.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_tab.png -------------------------------------------------------------------------------- /src/assets/img/pic_article.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/pic_article.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_cell.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_cell.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_icons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_icons.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_panel.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_toast.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_toast.png -------------------------------------------------------------------------------- /src/assets/img/mobile-qrcode.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/mobile-qrcode.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_article.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_article.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_button.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_dialog.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_dialog.png -------------------------------------------------------------------------------- /src/assets/img/icon_nav_progress.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_progress.png -------------------------------------------------------------------------------- /src/assets/img/screen-dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/screen-dashboard.png -------------------------------------------------------------------------------- /.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": ["es2015", "stage-3"], 3 | "plugins": ["transform-runtime"], 4 | "comments": false 5 | } 6 | -------------------------------------------------------------------------------- /src/assets/img/icon_nav_search_bar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_search_bar.png -------------------------------------------------------------------------------- /src/assets/img/screen-mobile-index.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/screen-mobile-index.png -------------------------------------------------------------------------------- /src/scss/weui/base/mixin/_mobile.scss: -------------------------------------------------------------------------------- 1 | @mixin setTapColor($c:rgba(0,0,0,0)) { 2 | -webkit-tap-highlight-color: $c; 3 | } 4 | -------------------------------------------------------------------------------- /src/assets/img/icon_nav_actionSheet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hsuehic/vue-kit/HEAD/src/assets/img/icon_nav_actionSheet.png -------------------------------------------------------------------------------- /test/unit/.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "env": { 3 | "mocha": true 4 | }, 5 | "globals": { 6 | "expect": true, 7 | "sinon": true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/scss/_mixins.scss: -------------------------------------------------------------------------------- 1 | @mixin border-radius($radius) { 2 | -webkit-border-radius:$radius; 3 | -moz-border-radius:$radius; 4 | border-radius:$radius; 5 | } 6 | -------------------------------------------------------------------------------- /config/test.env.js: -------------------------------------------------------------------------------- 1 | var merge = require('webpack-merge') 2 | var devEnv = require('./dev.env') 3 | 4 | module.exports = merge(devEnv, { 5 | NODE_ENV: '"testing"' 6 | }) 7 | -------------------------------------------------------------------------------- /config/dev.env.js: -------------------------------------------------------------------------------- 1 | var merge = require('webpack-merge') 2 | var prodEnv = require('./prod.env') 3 | 4 | module.exports = merge(prodEnv, { 5 | NODE_ENV: '"development"' 6 | }) 7 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-flex/weui-flex.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | 3 | .#{$weui_ns}flex { 4 | display: flex; 5 | } 6 | .#{$weui_ns}flex_item{ 7 | flex: 1; 8 | } 9 | -------------------------------------------------------------------------------- /src/scss/weui/base/variable/_weui-grid.scss: -------------------------------------------------------------------------------- 1 | $weuiGridBorderColor: #D9D9D9 !default; 2 | $weuiGridFontSize: 14px !default; 3 | $weuiGridIconSize: 28px !default; 4 | $weuiGridColumnCount: 3 !default; 5 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-cell/weui-check.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | @import "./weui-check/weui-check_common"; 3 | @import "./weui-check/weui-radio"; 4 | @import "./weui-check/weui-checkbox"; 5 | -------------------------------------------------------------------------------- /src/components/ui/Tab/index.vue: -------------------------------------------------------------------------------- 1 | 9 | -------------------------------------------------------------------------------- /src/filter/wrap.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by Richard on 2016/6/28. 3 | */ 4 | 5 | import Vue from 'vue' 6 | const wrap = (value, start, end) => start + value + end 7 | Vue.filter('wrap', wrap) 8 | export default wrap 9 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | indent_style = space 6 | tab_size = 4 7 | indent_size = 4 8 | end_of_line = lf 9 | insert_final_newline = true 10 | trim_trailing_whitespace = true 11 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-cell/weui-form.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | @import "./weui-form/weui-form_common"; 3 | @import "./weui-form/weui-form-preview"; 4 | @import "./weui-form/weui-select"; 5 | @import "./weui-form/weui-vcode"; -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules/ 3 | dist/ 4 | npm-debug.log 5 | selenium-debug.log 6 | test/unit/coverage 7 | test/e2e/reports 8 | .idea/ 9 | static/ 10 | index.html 11 | *.sublime-project 12 | *.sublime-workspace 13 | .tern-project 14 | -------------------------------------------------------------------------------- /src/scss/weui/base/variable/_weui-progress.scss: -------------------------------------------------------------------------------- 1 | $weuiProgressBg: #ebebeb !default; 2 | $weuiProgressColor: #09bb07 !default; 3 | $weuiProgressHeight: 3px !default; 4 | $weuiProgressCloseBg: #ef4f4f !default; 5 | $weuiProgressActiveBg: #c13e3e !default; 6 | -------------------------------------------------------------------------------- /src/filter/reverse.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by Richard on 2016/6/28. 3 | */ 4 | import Vue from 'vue' 5 | let reverse = function (value) { 6 | return value.split('').reverse().join('') 7 | } 8 | Vue.filter('reverse', reverse) 9 | export default reverse 10 | -------------------------------------------------------------------------------- /src/scss/weui/base/variable/_weui-dialog.scss: -------------------------------------------------------------------------------- 1 | $weuiDialogBackgroundColor: #FFFFFF !default; 2 | $weuiDialogLineColor: #D5D5D6 !default; 3 | $weuiDialogLinkColor: #3CC51F !default; 4 | $weuiDialogLinkActiveBc: #EEEEEE !default; 5 | $weuiDialogGapWidth: 1.6em !default; 6 | -------------------------------------------------------------------------------- /src/scss/weui/base/variable/_weui-msg.scss: -------------------------------------------------------------------------------- 1 | $weuiMsgPaddingTop:36px !default; 2 | $weuiMsgIconGap:30px !default; 3 | $weuiMsgTextGap:25px !default; 4 | $weuiMsgTitleGap:5px !default; 5 | $weuiMsgOprGap:25px !default; 6 | $weuiMsgExtraAreaGap:15px !default; 7 | $weuiMsgExtraAreaOfMinHeight:438px !default; 8 | -------------------------------------------------------------------------------- /src/lib/uuid.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by Richard on 2016/7/12. 3 | */ 4 | 5 | /** 6 | * @description 提供uuid生成的方法 7 | */ 8 | export default { 9 | /** 10 | * 生成一个uuid 11 | */ 12 | created () { 13 | this.uuid = Math.random().toString(36).substring(3, 8) 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/scss/weui/base/variable/_global.scss: -------------------------------------------------------------------------------- 1 | // namespace 2 | $weui_ns: 'weui-' !default; 3 | 4 | // font 5 | $weuiFontEN:-apple-system-font,"Helvetica Neue"; 6 | $weuiFontCN:"PingFang SC","Hiragino Sans GB","Microsoft YaHei"; 7 | $weuiFontSans:sans-serif; 8 | $weuiFontDefault:$weuiFontEN,$weuiFontSans; 9 | 10 | -------------------------------------------------------------------------------- /src/component-loader.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by xuexiaowei on 2016/11/6. 3 | */ 4 | /** 5 | * 创建 6 | * @param path 7 | * @returns {function(*=)} 8 | */ 9 | const makeComponent = (path) => { 10 | return (resolve) => { 11 | require([path], resolve) 12 | } 13 | } 14 | 15 | export default makeComponent 16 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-cell/weui-check/weui-check_common.scss: -------------------------------------------------------------------------------- 1 | @import "../../../base/fn"; 2 | 3 | .#{$weui_ns}check_label { 4 | @include setTapColor(); 5 | &:active { 6 | background-color: #ECECEC; 7 | } 8 | } 9 | 10 | .#{$weui_ns}check{ 11 | position: absolute; 12 | left: -9999em; 13 | } 14 | -------------------------------------------------------------------------------- /src/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 后台管理页面模板 8 | 9 | 10 |
11 | 12 | 13 | -------------------------------------------------------------------------------- /src/mobile.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 移动页面模板 8 | 9 | 10 |
11 |
12 | 13 | 14 | -------------------------------------------------------------------------------- /src/components/page/components/Message.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/components/page/filters/FilterBy.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/components/page/filters/OrderBy.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/components/page/animation/Keyframes.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/components/page/animation/Transition.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/components/page/components/Notification.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/components/page/components/Tooltips.vue: -------------------------------------------------------------------------------- 1 | 5 | 7 | 18 | -------------------------------------------------------------------------------- /src/filter/currency.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by Richard on 2016/6/28. 3 | */ 4 | /** eslint disabled **/ 5 | 6 | import Vue from 'vue' 7 | 8 | Vue.filter('currency', { 9 | read: (val) => { 10 | return '$' + val.toFixed(2) 11 | }, 12 | write: (val, oldVal) => { 13 | var number = val.replace(/[^\d.]/g, '') 14 | return isNaN(parseFloat(number)) ? 0 : parseFloat(number) 15 | } 16 | }) 17 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-button/weui-btn_warn.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | 3 | .#{$weui_ns}btn_warn { 4 | background-color: $weuiBtnWarnBg; 5 | &:not(.#{$weui_ns}btn_disabled):visited { 6 | color: $weuiBtnFontColor; 7 | } 8 | &:not(.#{$weui_ns}btn_disabled):active { 9 | color: $weuiBtnActiveFontColor; 10 | background-color: $weuiBtnWarnActiveBg; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-button/weui-btn_primary.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | 3 | .#{$weui_ns}btn_primary { 4 | background-color: $weuiBtnPrimaryBg; 5 | &:not(.#{$weui_ns}btn_disabled):visited { 6 | color: $weuiBtnFontColor; 7 | } 8 | &:not(.#{$weui_ns}btn_disabled):active { 9 | color: $weuiBtnActiveFontColor; 10 | background-color: $weuiBtnPrimaryActiveBg; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/components/ui/valueToPoint.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by Richard on 2016/6/30. 3 | */ 4 | export default (value, index, total) => { 5 | var x = 0 6 | var y = -value * 0.8 7 | var angle = Math.PI * 2 / total * index 8 | var cos = Math.cos(angle) 9 | var sin = Math.sin(angle) 10 | var tx = x * cos - y * sin + 100 11 | var ty = x * sin + y * cos + 100 12 | return { 13 | x: tx, 14 | y: ty 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/scss/weui/base/reset.scss: -------------------------------------------------------------------------------- 1 | @import "fn"; 2 | 3 | html { 4 | -ms-text-size-adjust: 100%; 5 | -webkit-text-size-adjust: 100%; 6 | } 7 | 8 | body { 9 | line-height: 1.6; 10 | font-family: $weuiFontDefault; 11 | } 12 | 13 | * { 14 | margin: 0; 15 | padding: 0; 16 | } 17 | 18 | a img { 19 | border: 0; 20 | } 21 | 22 | a { 23 | text-decoration: none; 24 | @include setTapColor(); 25 | } 26 | -------------------------------------------------------------------------------- /test/unit/specs/Hello.spec.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import Hello from 'src/components/Hello' 3 | 4 | describe('Hello.vue', () => { 5 | it('should render correct contents', () => { 6 | const vm = new Vue({ 7 | template: '
', 8 | components: { Hello } 9 | }).$mount() 10 | expect(vm.$el.querySelector('.hello h1').textContent).to.contain('Hello World!') 11 | }) 12 | }) 13 | -------------------------------------------------------------------------------- /test/e2e/specs/test.js: -------------------------------------------------------------------------------- 1 | // For authoring Nightwatch tests, see 2 | // http://nightwatchjs.org/guide#usage 3 | 4 | module.exports = { 5 | 'default e2e tests': function (browser) { 6 | browser 7 | .url('http://localhost:8080') 8 | .waitForElementVisible('#app', 5000) 9 | .assert.elementPresent('.logo') 10 | .assert.containsText('h1', 'Hello World!') 11 | .assert.elementCount('p', 3) 12 | .end() 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-button/weui-btn_default.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | 3 | .#{$weui_ns}btn_default { 4 | color: $weuiBtnDefaultFontColor; 5 | background-color: $weuiBtnDefaultBg; 6 | &:not(.#{$weui_ns}btn_disabled):visited { 7 | color: $weuiBtnDefaultFontColor; 8 | } 9 | &:not(.#{$weui_ns}btn_disabled):active { 10 | color: $weuiBtnDefaultActiveFontColor; 11 | background-color: $weuiBtnDefaultActiveBg; 12 | } 13 | } -------------------------------------------------------------------------------- /src/scss/weui/base/fn.scss: -------------------------------------------------------------------------------- 1 | // mixin 2 | @import "./mixin/mobile"; 3 | @import "./mixin/setOnepx"; 4 | @import "./mixin/setArrow"; 5 | @import "./mixin/text"; 6 | 7 | 8 | // variable 9 | @import "./variable/global"; 10 | @import "./variable/color"; 11 | 12 | 13 | @import "./variable/weui-cell"; 14 | @import "./variable/weui-button"; 15 | @import "./variable/weui-msg"; 16 | @import "./variable/weui-grid"; 17 | @import "./variable/weui-progress"; 18 | @import "./variable/weui-dialog"; -------------------------------------------------------------------------------- /src/scss/weui/widget/weui-tab/weui-tab.scss: -------------------------------------------------------------------------------- 1 | @import "../../base/fn"; 2 | @import "tabbar"; 3 | @import "navbar"; 4 | 5 | .#{$weui_ns}tab { 6 | position: relative; 7 | height: 100%; 8 | } 9 | 10 | .#{$weui_ns}tab_panel, .#{$weui_ns}tab_bd { 11 | box-sizing: border-box; 12 | height: 100%; 13 | padding-bottom: 55px; 14 | overflow: auto; 15 | -webkit-overflow-scrolling: touch; 16 | } 17 | 18 | .#{$weui_ns}tab_bd-item { 19 | display: none; 20 | } 21 | -------------------------------------------------------------------------------- /git_commit.template: -------------------------------------------------------------------------------- 1 | 2 | #Git 提交信息格式规范 3 | #(): // 空一行 4 | 5 | # // 空一行 6 | 7 | #