├── src ├── views │ ├── order.vue │ ├── about.vue │ ├── not-found.vue │ ├── coach.vue │ ├── course.vue │ └── wallet.vue ├── assets │ ├── scss │ │ ├── app │ │ │ ├── base │ │ │ │ ├── _mixins.scss │ │ │ │ ├── _index.scss │ │ │ │ ├── _function.scss │ │ │ │ └── _reset.scss │ │ │ ├── component │ │ │ │ ├── _index.scss │ │ │ │ ├── _nav.scss │ │ │ │ └── _swipe.scss │ │ │ ├── page │ │ │ │ ├── _index.scss │ │ │ │ ├── _coach.scss │ │ │ │ ├── _course.scss │ │ │ │ └── _wallet.scss │ │ │ └── app.scss │ │ ├── index.scss │ │ └── bootstrap │ │ │ ├── mixins │ │ │ ├── _clearfix.scss │ │ │ ├── _pulls.scss │ │ │ ├── _size.scss │ │ │ ├── _center-block.scss │ │ │ ├── _text-hide.scss │ │ │ ├── _lists.scss │ │ │ ├── _text-truncate.scss │ │ │ ├── _tab-focus.scss │ │ │ ├── _label.scss │ │ │ ├── _resize.scss │ │ │ ├── _text-emphasis.scss │ │ │ ├── _nav-divider.scss │ │ │ ├── _reset-filter.scss │ │ │ ├── _alert.scss │ │ │ ├── _background-variant.scss │ │ │ ├── _progress.scss │ │ │ ├── _navbar-align.scss │ │ │ ├── _reset-text.scss │ │ │ ├── _pagination.scss │ │ │ ├── _list-group.scss │ │ │ ├── _table-row.scss │ │ │ ├── _screen-reader.scss │ │ │ ├── _cards.scss │ │ │ ├── _border-radius.scss │ │ │ ├── _hover.scss │ │ │ ├── _image.scss │ │ │ ├── _grid-framework.scss │ │ │ ├── _grid.scss │ │ │ ├── _buttons.scss │ │ │ ├── _gradients.scss │ │ │ ├── _forms.scss │ │ │ └── _breakpoints.scss │ │ │ ├── bootstrap-flex.scss │ │ │ ├── bootstrap-reboot.scss │ │ │ ├── _animation.scss │ │ │ ├── _jumbotron.scss │ │ │ ├── _utilities-background.scss │ │ │ ├── _breadcrumb.scss │ │ │ ├── _responsive-embed.scss │ │ │ ├── _close.scss │ │ │ ├── _utilities-responsive.scss │ │ │ ├── _pager.scss │ │ │ ├── _utilities-spacing.scss │ │ │ ├── bootstrap.scss │ │ │ ├── _code.scss │ │ │ ├── bootstrap-grid.scss │ │ │ ├── _mixins.scss │ │ │ ├── _media.scss │ │ │ ├── _images.scss │ │ │ ├── _alert.scss │ │ │ ├── _print.scss │ │ │ ├── _labels.scss │ │ │ ├── _grid.scss │ │ │ ├── _pagination.scss │ │ │ ├── _utilities.scss │ │ │ ├── _tooltip.scss │ │ │ ├── _type.scss │ │ │ ├── _nav.scss │ │ │ ├── _modal.scss │ │ │ ├── _popover.scss │ │ │ ├── _list-group.scss │ │ │ ├── _buttons.scss │ │ │ ├── _tables.scss │ │ │ ├── _progress.scss │ │ │ ├── _navbar.scss │ │ │ ├── _input-group.scss │ │ │ ├── _dropdown.scss │ │ │ ├── _carousel.scss │ │ │ ├── _button-group.scss │ │ │ ├── _card.scss │ │ │ ├── _custom-forms.scss │ │ │ └── _normalize.scss │ └── fonts │ │ ├── FontAwesome.otf │ │ ├── fontawesome-webfont.eot │ │ ├── fontawesome-webfont.ttf │ │ ├── fontawesome-webfont.woff │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.ttf │ │ └── glyphicons-halflings-regular.woff ├── components │ ├── button.vue │ ├── utils │ │ ├── callAjax.js │ │ ├── getScrollBarWidth.js │ │ └── EventListener.js │ ├── nav.vue │ └── modal.vue ├── app.vue ├── main.js ├── route-config.js └── wx-api.js ├── mock ├── _map ├── api │ ├── data │ │ └── cache.json │ ├── user │ │ ├── get.js │ │ └── list.js │ ├── signature.js │ ├── coach │ │ └── get.js │ ├── wallet │ │ └── get.js │ └── course │ │ └── list.js └── list.js ├── assets ├── vendor │ ├── lib-flexible │ │ ├── combo.js │ │ ├── combo.debug.js │ │ ├── flexible.css │ │ ├── package.json │ │ ├── flexible_css.js │ │ ├── flexible_css.debug.js │ │ ├── makegrid.js │ │ ├── flexible.js │ │ ├── flexible.debug.css │ │ ├── makegrid.debug.js │ │ └── flexible.debug.js │ └── test.js └── img │ ├── heisencat.png │ ├── xw0129mjl.jpg │ ├── xw0131bd.jpg │ └── xw0131jy.jpg ├── README.md ├── .gitignore ├── test └── unit │ ├── index.js │ └── Hello.spec.js ├── server.js ├── wx.db ├── index.html ├── package.json ├── npm-debug.log └── .eslintrc /src/views/order.vue: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /mock/_map: -------------------------------------------------------------------------------- 1 | /list list.js 2 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/combo.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/assets/scss/app/base/_mixins.scss: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/combo.debug.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /assets/vendor/test.js: -------------------------------------------------------------------------------- 1 | console.log('test'); 2 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # wx-vue 2 | weixin html5 page with vue 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | *.sublime-project 3 | dist 4 | -------------------------------------------------------------------------------- /src/assets/scss/app/component/_index.scss: -------------------------------------------------------------------------------- 1 | @import "swipe"; 2 | @import "nav"; 3 | -------------------------------------------------------------------------------- /src/assets/scss/index.scss: -------------------------------------------------------------------------------- 1 | @import "bootstrap/bootstrap-flex"; 2 | @import "app/app"; 3 | -------------------------------------------------------------------------------- /assets/img/heisencat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/assets/img/heisencat.png -------------------------------------------------------------------------------- /assets/img/xw0129mjl.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/assets/img/xw0129mjl.jpg -------------------------------------------------------------------------------- /assets/img/xw0131bd.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/assets/img/xw0131bd.jpg -------------------------------------------------------------------------------- /assets/img/xw0131jy.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/assets/img/xw0131jy.jpg -------------------------------------------------------------------------------- /src/assets/scss/app/base/_index.scss: -------------------------------------------------------------------------------- 1 | @import "reset"; 2 | @import "mixins"; 3 | @import "function"; 4 | -------------------------------------------------------------------------------- /src/assets/scss/app/page/_index.scss: -------------------------------------------------------------------------------- 1 | @import "course"; 2 | @import "coach"; 3 | @import "wallet"; 4 | -------------------------------------------------------------------------------- /src/assets/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /src/assets/scss/app/app.scss: -------------------------------------------------------------------------------- 1 | @import "base/index"; 2 | @import "component/index"; 3 | @import "page/index"; 4 | -------------------------------------------------------------------------------- /src/assets/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /src/assets/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /src/assets/scss/app/base/_function.scss: -------------------------------------------------------------------------------- 1 | $rem: 64px; 2 | 3 | @function px2rem($px) { 4 | @return $px / $rem * 1rem; 5 | } 6 | -------------------------------------------------------------------------------- /src/assets/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /mock/api/data/cache.json: -------------------------------------------------------------------------------- 1 | {"ticket":"kgt8ON7yVITDhtdwci0qeQzO8Dvqe7SV47Zb0Pxb3Y_4C3YpLC1flNhLCpTtcJylCX2zG25TFX7LQj3YmWOQtw","time":1456309756074} -------------------------------------------------------------------------------- /src/assets/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /src/assets/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /src/assets/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/lynzz/wx-vue/HEAD/src/assets/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /src/components/button.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 10 | -------------------------------------------------------------------------------- /src/views/about.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 10 | -------------------------------------------------------------------------------- /src/assets/scss/app/component/_nav.scss: -------------------------------------------------------------------------------- 1 | .navbar { 2 | a { 3 | color: #fff; 4 | } 5 | .v-link-active { 6 | color: $link-color 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_clearfix.scss: -------------------------------------------------------------------------------- 1 | @mixin clearfix() { 2 | &::after { 3 | content: ""; 4 | display: table; 5 | clear: both; 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_pulls.scss: -------------------------------------------------------------------------------- 1 | @mixin pull-left { 2 | float: left !important; 3 | } 4 | @mixin pull-right { 5 | float: right !important; 6 | } 7 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_size.scss: -------------------------------------------------------------------------------- 1 | // Sizing shortcuts 2 | 3 | @mixin size($width, $height: $width) { 4 | width: $width; 5 | height: $height; 6 | } 7 | -------------------------------------------------------------------------------- /src/views/not-found.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 9 | 11 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_center-block.scss: -------------------------------------------------------------------------------- 1 | // Center-align a block level element 2 | 3 | @mixin center-block() { 4 | display: block; 5 | margin-left: auto; 6 | margin-right: auto; 7 | } 8 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_text-hide.scss: -------------------------------------------------------------------------------- 1 | // CSS image replacement 2 | @mixin text-hide() { 3 | font: "0/0" a; 4 | color: transparent; 5 | text-shadow: none; 6 | background-color: transparent; 7 | border: 0; 8 | } 9 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_lists.scss: -------------------------------------------------------------------------------- 1 | // Lists 2 | 3 | // Unstyled keeps list items block level, just removes default browser padding and list-style 4 | @mixin list-unstyled { 5 | padding-left: 0; 6 | list-style: none; 7 | } 8 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_text-truncate.scss: -------------------------------------------------------------------------------- 1 | // Text truncate 2 | // Requires inline-block or block for proper styling 3 | 4 | @mixin text-truncate() { 5 | overflow: hidden; 6 | text-overflow: ellipsis; 7 | white-space: nowrap; 8 | } -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/bootstrap-flex.scss: -------------------------------------------------------------------------------- 1 | // Bootstrap with Flexbox enabled 2 | // 3 | // Includes all the imports from the standard Bootstrap project, but enables 4 | // the flexbox variable. 5 | 6 | $enable-flex: true; 7 | 8 | @import "bootstrap"; 9 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_tab-focus.scss: -------------------------------------------------------------------------------- 1 | // WebKit-style focus 2 | 3 | @mixin tab-focus() { 4 | // Default 5 | outline: thin dotted; 6 | // WebKit 7 | outline: 5px auto -webkit-focus-ring-color; 8 | outline-offset: -2px; 9 | } 10 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_label.scss: -------------------------------------------------------------------------------- 1 | // Labels 2 | 3 | @mixin label-variant($color) { 4 | background-color: $color; 5 | 6 | &[href] { 7 | @include hover-focus { 8 | background-color: darken($color, 10%); 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_resize.scss: -------------------------------------------------------------------------------- 1 | // Resize anything 2 | 3 | @mixin resizable($direction) { 4 | resize: $direction; // Options: horizontal, vertical, both 5 | overflow: auto; // Per CSS3 UI, `resize` only applies when `overflow` isn't `visible` 6 | } 7 | -------------------------------------------------------------------------------- /src/assets/scss/app/base/_reset.scss: -------------------------------------------------------------------------------- 1 | body { 2 | -webkit-overflow-scrolling: touch; 3 | } 4 | 5 | a, button, input, optgroup, select, textarea { 6 | -webkit-tap-highlight-color:rgba(0,0,0,0); 7 | } 8 | 9 | a, img { 10 | -webkit-touch-callout: none; 11 | } 12 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/bootstrap-reboot.scss: -------------------------------------------------------------------------------- 1 | // Bootstrap Reboot only 2 | // 3 | // Includes only Normalize and our custom Reboot reset. 4 | 5 | @import "variables"; 6 | @import "mixins/hover"; 7 | @import "mixins/tab-focus"; 8 | 9 | @import "normalize"; 10 | @import "reboot"; 11 | -------------------------------------------------------------------------------- /src/app.vue: -------------------------------------------------------------------------------- 1 | 6 | 19 | -------------------------------------------------------------------------------- /mock/api/user/get.js: -------------------------------------------------------------------------------- 1 | module.exports = function(req, res, next) { 2 | var data = { 3 | success: true, 4 | data: { 5 | id: req.query.id, 6 | url: '#!/user/' + id, 7 | name: 'Chuck Norris ' + id 8 | } 9 | }; 10 | data = JSON.stringify(data); 11 | res.end(data); 12 | } 13 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_text-emphasis.scss: -------------------------------------------------------------------------------- 1 | // Typography 2 | 3 | @mixin text-emphasis-variant($parent, $color) { 4 | #{$parent} { 5 | color: $color !important; 6 | } 7 | a#{$parent} { 8 | @include hover-focus { 9 | color: darken($color, 10%); 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_nav-divider.scss: -------------------------------------------------------------------------------- 1 | // Horizontal dividers 2 | // 3 | // Dividers (basically an hr) within dropdowns and nav lists 4 | 5 | @mixin nav-divider($color: #e5e5e5) { 6 | height: 1px; 7 | margin: ($spacer-y / 2) 0; 8 | overflow: hidden; 9 | background-color: $color; 10 | } 11 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_reset-filter.scss: -------------------------------------------------------------------------------- 1 | // Reset filters for IE 2 | // 3 | // When you need to remove a gradient background, do not forget to use this to reset 4 | // the IE filter for IE9. 5 | 6 | @mixin reset-filter() { 7 | filter: "progid:DXImageTransform.Microsoft.gradient(enabled = false)"; 8 | } 9 | -------------------------------------------------------------------------------- /test/unit/index.js: -------------------------------------------------------------------------------- 1 | // Polyfill fn.bind() for PhantomJS 2 | /* eslint-disable no-extend-native */ 3 | Function.prototype.bind = require('function-bind') 4 | 5 | // require all test files (files that ends with .spec.js) 6 | var testsContext = require.context('.', true, /\.spec$/) 7 | testsContext.keys().forEach(testsContext) 8 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_alert.scss: -------------------------------------------------------------------------------- 1 | // Alerts 2 | 3 | @mixin alert-variant($background, $border, $body-color) { 4 | background-color: $background; 5 | border-color: $border; 6 | color: $body-color; 7 | 8 | hr { 9 | border-top-color: darken($border, 5%); 10 | } 11 | .alert-link { 12 | color: darken($body-color, 10%); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_background-variant.scss: -------------------------------------------------------------------------------- 1 | // Contextual backgrounds 2 | 3 | @mixin bg-variant($parent, $color) { 4 | #{$parent} { 5 | color: #fff !important; 6 | background-color: $color !important; 7 | } 8 | a#{$parent} { 9 | @include hover-focus { 10 | background-color: darken($color, 10%); 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/assets/scss/app/page/_coach.scss: -------------------------------------------------------------------------------- 1 | .coach { 2 | &-swipe { 3 | height: 200px; 4 | } 5 | &-profile { 6 | display: flex; 7 | img { 8 | width: 100px; 9 | height: 100px; 10 | overflow: hidden; 11 | display: block; 12 | margin-right: 10px; 13 | } 14 | } 15 | &-info { 16 | text-indent: 24px; 17 | flex: 1 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_progress.scss: -------------------------------------------------------------------------------- 1 | // Progress bars 2 | 3 | @mixin progress-variant($color) { 4 | &[value]::-webkit-progress-value { 5 | background-color: $color; 6 | } 7 | 8 | &[value]::-moz-progress-bar { 9 | background-color: $color; 10 | } 11 | 12 | // IE9 13 | @media screen and (min-width:0\0) { 14 | .progress-bar { 15 | background-color: $color; 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_navbar-align.scss: -------------------------------------------------------------------------------- 1 | // Navbar vertical align 2 | // 3 | // Vertically center elements in the navbar. 4 | // Example: an element has a height of 30px, so write out `.navbar-vertical-align(30px);` to calculate the appropriate top margin. 5 | 6 | // @mixin navbar-vertical-align($element-height) { 7 | // margin-top: (($navbar-height - $element-height) / 2); 8 | // margin-bottom: (($navbar-height - $element-height) / 2); 9 | // } 10 | -------------------------------------------------------------------------------- /src/components/utils/callAjax.js: -------------------------------------------------------------------------------- 1 | export default (url, callback)=> { 2 | var httpRequest = new XMLHttpRequest() 3 | httpRequest.onreadystatechange = function() { 4 | if (httpRequest.readyState === 4) { 5 | if (httpRequest.status === 200) { 6 | var data = JSON.parse(httpRequest.responseText) 7 | if (callback) callback(data) 8 | } 9 | } 10 | } 11 | httpRequest.open('GET', url) 12 | httpRequest.send() 13 | } -------------------------------------------------------------------------------- /src/components/nav.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 20 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_animation.scss: -------------------------------------------------------------------------------- 1 | .fade { 2 | opacity: 0; 3 | transition: opacity .15s linear; 4 | 5 | &.in { 6 | opacity: 1; 7 | } 8 | } 9 | 10 | .collapse { 11 | display: none; 12 | 13 | &.in { 14 | display: block; 15 | } 16 | // tr&.in { display: table-row; } 17 | // tbody&.in { display: table-row-group; } 18 | } 19 | 20 | .collapsing { 21 | position: relative; 22 | height: 0; 23 | overflow: hidden; 24 | transition-timing-function: ease; 25 | transition-duration: .35s; 26 | transition-property: height; 27 | } 28 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_jumbotron.scss: -------------------------------------------------------------------------------- 1 | .jumbotron { 2 | padding: $jumbotron-padding ($jumbotron-padding / 2); 3 | margin-bottom: $jumbotron-padding; 4 | background-color: $jumbotron-bg; 5 | @include border-radius($border-radius-lg); 6 | 7 | @include media-breakpoint-up(sm) { 8 | padding: ($jumbotron-padding * 2) $jumbotron-padding; 9 | } 10 | } 11 | 12 | .jumbotron-hr { 13 | border-top-color: darken($jumbotron-bg, 10%); 14 | } 15 | 16 | .jumbotron-fluid { 17 | padding-right: 0; 18 | padding-left: 0; 19 | @include border-radius(0); 20 | } 21 | -------------------------------------------------------------------------------- /mock/list.js: -------------------------------------------------------------------------------- 1 | module.exports = function(req, res, next) { 2 | var pageSize = req.query.pageSize || 5; 3 | var pageNo = req.query.pageNo || 1; 4 | var listData = []; 5 | for(var i = 0; i < 5; i++) { 6 | var id = (pageNo - 1) * pageSize + i + 1; 7 | listData.push({ 8 | id: id, 9 | name: 'Chuck Norris ' + id, 10 | power: 1000 + id 11 | }); 12 | } 13 | var data = { 14 | data: { 15 | pageNo: pageNo, 16 | totalCount: 10, 17 | listData: listData 18 | } 19 | }; 20 | data = JSON.stringify(data); 21 | res.end(data); 22 | } 23 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_reset-text.scss: -------------------------------------------------------------------------------- 1 | @mixin reset-text { 2 | font-family: $font-family-base; 3 | // We deliberately do NOT reset font-size. 4 | font-style: normal; 5 | font-weight: normal; 6 | letter-spacing: normal; 7 | line-break: auto; 8 | line-height: $line-height; 9 | text-align: left; // Fallback for where `start` is not supported 10 | text-align: start; 11 | text-decoration: none; 12 | text-shadow: none; 13 | text-transform: none; 14 | white-space: normal; 15 | word-break: normal; 16 | word-spacing: normal; 17 | word-wrap: normal; 18 | } 19 | -------------------------------------------------------------------------------- /test/unit/Hello.spec.js: -------------------------------------------------------------------------------- 1 | /* global describe, it, expect */ 2 | 3 | import Vue from 'vue' 4 | import Hello from 'src/components/Hello' 5 | 6 | describe('Hello.vue', () => { 7 | it('should render correct contents', () => { 8 | const vm = new Vue({ 9 | template: '
', 10 | components: { Hello } 11 | }).$mount() 12 | expect(vm.$el.querySelector('.hello h1').textContent).toBe('Hello World!') 13 | }) 14 | }) 15 | 16 | // also see example testing a component with mocks at 17 | // https://github.com/vuejs/vue-loader-example/blob/master/test/unit/a.spec.js#L24-L49 18 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_utilities-background.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Contextual backgrounds 3 | // 4 | 5 | // Inverse 6 | // TODO: redo this as a proper class 7 | .bg-inverse { 8 | color: $gray-lighter; 9 | background-color: $gray-dark; 10 | } 11 | 12 | .bg-faded { 13 | background-color: $gray-lightest; 14 | } 15 | 16 | @include bg-variant('.bg-primary', $brand-primary); 17 | 18 | @include bg-variant('.bg-success', $brand-success); 19 | 20 | @include bg-variant('.bg-info', $brand-info); 21 | 22 | @include bg-variant('.bg-warning', $brand-warning); 23 | 24 | @include bg-variant('.bg-danger', $brand-danger); 25 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_breadcrumb.scss: -------------------------------------------------------------------------------- 1 | .breadcrumb { 2 | padding: $breadcrumb-padding-vertical $breadcrumb-padding-horizontal; 3 | margin-bottom: $spacer-y; 4 | list-style: none; 5 | background-color: $breadcrumb-bg; 6 | @include border-radius($border-radius); 7 | @include clearfix; 8 | 9 | > li { 10 | float: left; 11 | 12 | + li::before { 13 | padding-right: .5rem; 14 | padding-left: .5rem; 15 | color: $breadcrumb-divider-color; 16 | content: "#{$breadcrumb-divider}"; 17 | } 18 | } 19 | 20 | > .active { 21 | color: $breadcrumb-active-color; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_pagination.scss: -------------------------------------------------------------------------------- 1 | // Pagination 2 | 3 | @mixin pagination-size($padding-vertical, $padding-horizontal, $font-size, $line-height, $border-radius) { 4 | .page-link { 5 | padding: $padding-vertical $padding-horizontal; 6 | font-size: $font-size; 7 | line-height: $line-height; 8 | } 9 | 10 | .page-item { 11 | &:first-child { 12 | .page-link { 13 | @include border-left-radius($border-radius); 14 | } 15 | } 16 | &:last-child { 17 | .page-link { 18 | @include border-right-radius($border-radius); 19 | } 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /mock/api/user/list.js: -------------------------------------------------------------------------------- 1 | module.exports = function(req, res, next) { 2 | var pageSize = req.query.pageSize || 5; 3 | var pageNo = req.query.pageNo || 1; 4 | var listData = []; 5 | for(var i = 0; i < pageSize; i++) { 6 | var id = (pageNo - 1) * pageSize + i + 1; 7 | listData.push({ 8 | id: id, 9 | url: '#!/user/' + id, 10 | username: 'Chuck Norris ' + id 11 | }); 12 | } 13 | var data = { 14 | success: true, 15 | data: { 16 | pageNo: pageNo, 17 | totalCount: 20, 18 | listData: listData 19 | } 20 | }; 21 | data = JSON.stringify(data); 22 | res.end(data); 23 | } 24 | -------------------------------------------------------------------------------- /mock/api/signature.js: -------------------------------------------------------------------------------- 1 | const signature = require('wx_jsapi_sign'); 2 | 3 | const APP_ID = 'wx09f7d37254dfa4d6'; // wx53f38d54c5ff7a88 4 | const APP_SECRET = '69f7240ab7e64fd7a5653171366b1833'; 5 | 6 | module.exports = function(req, res, next) { 7 | var url = req.query.url; 8 | 9 | signature.getSignature({ 10 | appId: APP_ID, 11 | appSecret: APP_SECRET, 12 | cache_json_file: __dirname + '/data', 13 | appToken: 'feilite' 14 | })(url, function(error, result) { 15 | if (error) { 16 | res.end(JSON.stringify({ 17 | 'error': error 18 | })); 19 | } else { 20 | res.end(JSON.stringify(result)); 21 | } 22 | }); 23 | } 24 | -------------------------------------------------------------------------------- /mock/api/coach/get.js: -------------------------------------------------------------------------------- 1 | var Mock = require('mockjs'); 2 | module.exports = function(req, res, next) { 3 | var data = { 4 | success: true, 5 | data: { 6 | id: req.query.id, 7 | avatar: '/assets/img/heisencat.png', 8 | description: '@cparagraph', 9 | name: '@cname', 10 | crowd: '@csentence', 11 | images: [{ 12 | url: '/assets/img/xw0129mjl.jpg', 13 | title: 'swipe1' 14 | }, { 15 | url: '/assets/img/xw0131bd.jpg', 16 | title: 'swipe2' 17 | }, { 18 | url: '/assets/img/xw0131jy.jpg', 19 | title: 'swipe3' 20 | }], 21 | effect: '@cparagraph(4,7)' 22 | } 23 | }; 24 | data = JSON.stringify(Mock.mock(data)); 25 | res.end(data); 26 | } 27 | -------------------------------------------------------------------------------- /src/assets/scss/app/page/_course.scss: -------------------------------------------------------------------------------- 1 | .course { 2 | &-date { 3 | display: flex; 4 | } 5 | &-day { 6 | flex: 1; 7 | text-align: center; 8 | &.active { 9 | background: #ccc; 10 | } 11 | } 12 | &-list { 13 | 14 | } 15 | &-item { 16 | border-bottom: 1px solid #ccc; 17 | display: flex; 18 | padding: 10px 15px; 19 | .c1 { 20 | display: block; 21 | margin-right: 10px; 22 | } 23 | .c2 { 24 | width: 100%; 25 | flex: 1; 26 | } 27 | } 28 | &-avatar { 29 | width: 50px; 30 | height: 50px; 31 | overflow: hidden; 32 | } 33 | &-tags { 34 | span { 35 | margin-left: 2px 36 | } 37 | button { 38 | float: right; 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_list-group.scss: -------------------------------------------------------------------------------- 1 | // List Groups 2 | 3 | @mixin list-group-item-variant($state, $background, $color) { 4 | .list-group-item-#{$state} { 5 | color: $color; 6 | background-color: $background; 7 | } 8 | 9 | a.list-group-item-#{$state}, 10 | button.list-group-item-#{$state} { 11 | color: $color; 12 | 13 | .list-group-item-heading { 14 | color: inherit; 15 | } 16 | 17 | @include hover-focus { 18 | color: $color; 19 | background-color: darken($background, 5%); 20 | } 21 | 22 | &.active { 23 | @include plain-hover-focus { 24 | color: #fff; 25 | background-color: $color; 26 | border-color: $color; 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /server.js: -------------------------------------------------------------------------------- 1 | 'use strict' 2 | 3 | var webpack = require('webpack'); 4 | var WebpackDevServer = require('webpack-dev-server'); 5 | var config = require('./build/webpack.dev.config'); 6 | config.entry.unshift('webpack-dev-server/client?http://localhost:8090', "webpack/hot/dev-server"); 7 | config.plugins.push(new webpack.HotModuleReplacementPlugin()); 8 | 9 | // 这里配置:请求http://localhost:9090/api, 10 | // 相当于通过本地node服务代理请求到了http://cnodejs.org/api 11 | var proxy = [{ 12 | path: "/api/*", 13 | target: "http://localhost:3000", 14 | host: "localhost" 15 | }] 16 | //启动服务 17 | var app = new WebpackDevServer(webpack(config), { 18 | publicPath: config.output.publicPath, 19 | hot:true, 20 | historyApiFallback: true, 21 | proxy:proxy 22 | }); 23 | app.listen(8090); 24 | -------------------------------------------------------------------------------- /src/components/utils/getScrollBarWidth.js: -------------------------------------------------------------------------------- 1 | export default ()=> { 2 | let inner = document.createElement('p') 3 | inner.style.width = '100%' 4 | inner.style.height = '200px' 5 | 6 | let outer = document.createElement('div') 7 | outer.style.position = 'absolute' 8 | outer.style.top = '0px' 9 | outer.style.left = '0px' 10 | outer.style.visibility = 'hidden' 11 | outer.style.width = '200px' 12 | outer.style.height = '150px' 13 | outer.style.overflow = 'hidden' 14 | outer.appendChild(inner) 15 | 16 | document.body.appendChild(outer) 17 | let w1 = inner.offsetWidth 18 | outer.style.overflow = 'scroll' 19 | let w2 = inner.offsetWidth 20 | if (w1 === w2) w2 = outer.clientWidth 21 | 22 | document.body.removeChild(outer) 23 | 24 | return (w1 - w2) 25 | } 26 | -------------------------------------------------------------------------------- /src/assets/scss/app/page/_wallet.scss: -------------------------------------------------------------------------------- 1 | .wallet { 2 | &-person { 3 | text-align: center; 4 | img { 5 | width: px2rem(80px); 6 | height: px2rem(80px); 7 | overflow: hidden; 8 | } 9 | &-bg { 10 | height: px2rem(319px); 11 | } 12 | &-level { 13 | color: #FF8112; 14 | } 15 | &-info { 16 | margin: px2rem(20px) 0; 17 | display: flex; 18 | 19 | .cell { 20 | flex: 1; 21 | border-right: 1px solid #D7D3D0; 22 | &:last-child { 23 | border-right: 0; 24 | } 25 | dt { 26 | color: #54534F 27 | } 28 | dd { 29 | color: #A9A8A6 30 | } 31 | } 32 | } 33 | } 34 | &-btns { 35 | text-align: center; 36 | } 37 | 38 | } 39 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_responsive-embed.scss: -------------------------------------------------------------------------------- 1 | // Credit: Nicolas Gallagher and SUIT CSS. 2 | 3 | .embed-responsive { 4 | position: relative; 5 | display: block; 6 | height: 0; 7 | padding: 0; 8 | overflow: hidden; 9 | 10 | .embed-responsive-item, 11 | iframe, 12 | embed, 13 | object, 14 | video { 15 | position: absolute; 16 | top: 0; 17 | bottom: 0; 18 | left: 0; 19 | width: 100%; 20 | height: 100%; 21 | border: 0; 22 | } 23 | } 24 | 25 | .embed-responsive-21by9 { 26 | padding-bottom: percentage(9 / 21); 27 | } 28 | 29 | .embed-responsive-16by9 { 30 | padding-bottom: percentage(9 / 16); 31 | } 32 | 33 | .embed-responsive-4by3 { 34 | padding-bottom: percentage(3 / 4); 35 | } 36 | 37 | .embed-responsive-1by1 { 38 | padding-bottom: percentage(1 / 1); 39 | } 40 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_table-row.scss: -------------------------------------------------------------------------------- 1 | // Tables 2 | 3 | @mixin table-row-variant($state, $background) { 4 | // Exact selectors below required to override `.table-striped` and prevent 5 | // inheritance to nested tables. 6 | .table-#{$state} { 7 | &, 8 | > th, 9 | > td { 10 | background-color: $background; 11 | } 12 | } 13 | 14 | // Hover states for `.table-hover` 15 | // Note: this is not available for cells or rows within `thead` or `tfoot`. 16 | .table-hover { 17 | $hover-background: darken($background, 5%); 18 | 19 | .table-#{$state} { 20 | @include hover { 21 | background-color: $hover-background; 22 | 23 | > td, 24 | > th { 25 | background-color: $hover-background; 26 | } 27 | } 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_close.scss: -------------------------------------------------------------------------------- 1 | .close { 2 | float: right; 3 | font-size: ($font-size-base * 1.5); 4 | font-weight: $close-font-weight; 5 | line-height: 1; 6 | color: $close-color; 7 | text-shadow: $close-text-shadow; 8 | opacity: .2; 9 | 10 | @include hover-focus { 11 | color: $close-color; 12 | text-decoration: none; 13 | cursor: pointer; 14 | opacity: .5; 15 | } 16 | } 17 | 18 | // Additional properties for button version 19 | // iOS requires the button element instead of an anchor tag. 20 | // If you want the anchor version, it requires `href="#"`. 21 | // See https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile 22 | button.close { 23 | padding: 0; 24 | cursor: pointer; 25 | background: transparent; 26 | border: 0; 27 | -webkit-appearance: none; 28 | } 29 | -------------------------------------------------------------------------------- /wx.db: -------------------------------------------------------------------------------- 1 | {"key":"token","val":"uyGx9mDpB2vDH4VkBCClwh_iZnPjYn5GbA8p-INqJnM4__BFYeH4qd1fXRKPdvtjW6D_NlZPupqiKL7jokGBVbMjOOgTYKoCUhMvo4xLZmDKTTS7sYiEd9orLicemb35HVFjAAAXLV"} 2 | {"key":"ticket","val":"kgt8ON7yVITDhtdwci0qeQzO8Dvqe7SV47Zb0Pxb3Y_4C3YpLC1flNhLCpTtcJylCX2zG25TFX7LQj3YmWOQtw"} 3 | {"key":"token","val":"RX61PVDWZlhhVBhSJ_nJxwOHrjsSJa4FlrqAV8KFXmklmcI_5PqmoLvOIwcSOyP_t-xKMR_DRMrMHm9qFUH-txI2yjQhzqCWdlD-GNuFUBFZeelsFDb6ak9DlAuYhDLPISRaADABLK"} 4 | {"key":"ticket","val":"kgt8ON7yVITDhtdwci0qeQzO8Dvqe7SV47Zb0Pxb3Y_4C3YpLC1flNhLCpTtcJylCX2zG25TFX7LQj3YmWOQtw"} 5 | {"key":"token","val":"3oqVJXzW2h6iF8BcYd0LPniN3hMqxo5TXwH-ZFM1l5Wfhhm9vXrENMrzvEt8PlSn91VfDAtw1s34pjv-4dCCEVg3344r7UXq4q41r5Cmi_DkrtwSRDyJ5ZYyWW8DyniKDRIbAEAMAR"} 6 | {"key":"ticket","val":"kgt8ON7yVITDhtdwci0qeQzO8Dvqe7SV47Zb0Pxb3Y_4C3YpLC1flNhLCpTtcJylCX2zG25TFX7LQj3YmWOQtw"} 7 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 菲特力 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 |
17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_screen-reader.scss: -------------------------------------------------------------------------------- 1 | // Only display content to screen readers 2 | // 3 | // See: http://a11yproject.com/posts/how-to-hide-content/ 4 | 5 | @mixin sr-only { 6 | position: absolute; 7 | width: 1px; 8 | height: 1px; 9 | padding: 0; 10 | margin: -1px; 11 | overflow: hidden; 12 | clip: rect(0,0,0,0); 13 | border: 0; 14 | } 15 | 16 | // Use in conjunction with .sr-only to only display content when it's focused. 17 | // 18 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1 19 | // 20 | // Credit: HTML5 Boilerplate 21 | 22 | @mixin sr-only-focusable { 23 | &:active, 24 | &:focus { 25 | position: static; 26 | width: auto; 27 | height: auto; 28 | margin: 0; 29 | overflow: visible; 30 | clip: auto; 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /src/assets/scss/app/component/_swipe.scss: -------------------------------------------------------------------------------- 1 | .swipe, 2 | .swipe-items-wrap{ 3 | overflow:hidden;position:relative 4 | } 5 | 6 | .swipe-items-wrap{height:100%} 7 | .swipe-items-wrap > div{ 8 | position:absolute; 9 | -webkit-transform:translateX(-100%); 10 | transform:translateX(-100%); 11 | width:100%; 12 | height:100%; 13 | display:none 14 | } 15 | .swipe-items-wrap > div.active { 16 | display:block; 17 | -webkit-transform:none;transform:none 18 | } 19 | .swipe-indicators{ 20 | position:absolute; 21 | bottom:10px; 22 | left:50%; 23 | -webkit-transform:translateX(-50%); 24 | transform:translateX(-50%) 25 | } 26 | .swipe-indicator{ 27 | width:8px; 28 | height:8px; 29 | display:inline-block; 30 | border-radius:100%; 31 | background:#000; 32 | opacity:.2; 33 | margin:0 3px 34 | } 35 | .swipe-indicator.active{background:#fff} 36 | -------------------------------------------------------------------------------- /mock/api/wallet/get.js: -------------------------------------------------------------------------------- 1 | var Mock = require('mockjs'); 2 | module.exports = function(req, res, next) { 3 | var data = { 4 | success: true, 5 | data: { 6 | id: req.query.id, 7 | avatar: '/assets/img/heisencat.png', 8 | description: '@cparagraph', 9 | name: '@cname', 10 | hasPrivilege: false, 11 | level: '健身达人', 12 | 'balance|168-25888': 245, 13 | spa: 3, 14 | 'integration|30-120': 33, 15 | images: [{ 16 | url: '/assets/img/xw0129mjl.jpg', 17 | title: 'swipe1' 18 | }, { 19 | url: '/assets/img/xw0131bd.jpg', 20 | title: 'swipe2' 21 | }, { 22 | url: '/assets/img/xw0131jy.jpg', 23 | title: 'swipe3' 24 | }], 25 | effect: '@cparagraph(4,7)' 26 | } 27 | }; 28 | data = JSON.stringify(Mock.mock(data)); 29 | res.end(data); 30 | } 31 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_cards.scss: -------------------------------------------------------------------------------- 1 | // Card variants 2 | 3 | @mixin card-variant($background, $border) { 4 | background-color: $background; 5 | border-color: $border; 6 | } 7 | 8 | @mixin card-outline-variant($color) { 9 | background-color: transparent; 10 | border-color: $color; 11 | } 12 | 13 | // 14 | // Inverse text within a card for use with dark backgrounds 15 | // 16 | 17 | @mixin card-inverse { 18 | .card-header, 19 | .card-footer { 20 | border-bottom: $card-border-width solid rgba(255,255,255,.2); 21 | } 22 | .card-header, 23 | .card-footer, 24 | .card-title, 25 | .card-blockquote { 26 | color: #fff; 27 | } 28 | .card-link, 29 | .card-text, 30 | .card-blockquote > footer { 31 | color: rgba(255,255,255,.65); 32 | } 33 | .card-link { 34 | @include hover-focus { 35 | color: $card-link-hover-color; 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_border-radius.scss: -------------------------------------------------------------------------------- 1 | // Single side border-radius 2 | 3 | @mixin border-radius($radius: $border-radius) { 4 | @if $enable-rounded { 5 | border-radius: $radius; 6 | } 7 | } 8 | 9 | @mixin border-top-radius($radius) { 10 | @if $enable-rounded { 11 | border-top-right-radius: $radius; 12 | border-top-left-radius: $radius; 13 | } 14 | } 15 | 16 | @mixin border-right-radius($radius) { 17 | @if $enable-rounded { 18 | border-bottom-right-radius: $radius; 19 | border-top-right-radius: $radius; 20 | } 21 | } 22 | 23 | @mixin border-bottom-radius($radius) { 24 | @if $enable-rounded { 25 | border-bottom-right-radius: $radius; 26 | border-bottom-left-radius: $radius; 27 | } 28 | } 29 | 30 | @mixin border-left-radius($radius) { 31 | @if $enable-rounded { 32 | border-bottom-left-radius: $radius; 33 | border-top-left-radius: $radius; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /src/components/utils/EventListener.js: -------------------------------------------------------------------------------- 1 | const EventListener = { 2 | /** 3 | * Listen to DOM events during the bubble phase. 4 | * 5 | * @param {DOMEventTarget} target DOM element to register listener on. 6 | * @param {string} eventType Event type, e.g. 'click' or 'mouseover'. 7 | * @param {function} callback Callback function. 8 | * @return {object} Object with a `remove` method. 9 | */ 10 | listen(target, eventType, callback) { 11 | if (target.addEventListener) { 12 | target.addEventListener(eventType, callback, false) 13 | return { 14 | remove() { 15 | target.removeEventListener(eventType, callback, false) 16 | } 17 | } 18 | } else if (target.attachEvent) { 19 | target.attachEvent('on' + eventType, callback) 20 | return { 21 | remove() { 22 | target.detachEvent('on' + eventType, callback) 23 | } 24 | } 25 | } 26 | } 27 | } 28 | 29 | export default EventListener 30 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/flexible.css: -------------------------------------------------------------------------------- 1 | @charset "utf-8";html{color:#000;background:#fff;overflow-y:scroll;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}html *{outline:0;-webkit-text-size-adjust:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}html,body{font-family:sans-serif}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td,hr,button,article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{margin:0;padding:0}input,select,textarea{font-size:100%}table{border-collapse:collapse;border-spacing:0}fieldset,img{border:0}abbr,acronym{border:0;font-variant:normal}del{text-decoration:line-through}address,caption,cite,code,dfn,em,th,var{font-style:normal;font-weight:500}ol,ul{list-style:none}caption,th{text-align:left}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:500}q:before,q:after{content:''}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}a:hover{text-decoration:underline}ins,a{text-decoration:none} -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_utilities-responsive.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Responsive utilities 3 | // 4 | 5 | @each $bp in map-keys($grid-breakpoints) { 6 | .hidden-#{$bp}-up { 7 | @include media-breakpoint-up($bp) { 8 | display: none !important; 9 | } 10 | } 11 | .hidden-#{$bp}-down { 12 | @include media-breakpoint-down($bp) { 13 | display: none !important; 14 | } 15 | } 16 | } 17 | 18 | 19 | // Print utilities 20 | // 21 | // Media queries are placed on the inside to be mixin-friendly. 22 | 23 | .visible-print-block { 24 | display: none !important; 25 | 26 | @media print { 27 | display: block !important; 28 | } 29 | } 30 | .visible-print-inline { 31 | display: none !important; 32 | 33 | @media print { 34 | display: inline !important; 35 | } 36 | } 37 | .visible-print-inline-block { 38 | display: none !important; 39 | 40 | @media print { 41 | display: inline-block !important; 42 | } 43 | } 44 | 45 | .hidden-print { 46 | @media print { 47 | display: none !important; 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/main.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Boot up the Vue instance and wire up the router. 3 | */ 4 | 'use strict'; 5 | 6 | import Vue from 'vue'; 7 | import VueRouter from 'vue-router'; 8 | //import vueTouch from 'vue-touch'; 9 | import { configRouter } from './route-config'; 10 | 11 | import './assets/scss/index.scss'; 12 | 13 | import wxApi from './wx-api' 14 | 15 | Vue.use(VueRouter); 16 | Vue.use(require('vue-resource')); 17 | Vue.use(require('vue-validator')); 18 | //Vue.use(vueTouch); 19 | 20 | Vue.http.options.xhr = {withCredentials: true}; 21 | Vue.http.headers['access-control-allow-origin'] = '*'; 22 | 23 | Vue.config.debug = true; 24 | Vue.config.warnExpressionErrors = false 25 | // create router 26 | const router = new VueRouter({ 27 | history: false, 28 | saveScrollPosition: true 29 | }); 30 | 31 | // configure router 32 | configRouter(router); 33 | 34 | // boostrap the app 35 | const App = Vue.extend(require('./app.vue')); 36 | router.start(App, '#app'); 37 | 38 | wxApi.init(Vue); 39 | 40 | // just for debugging 41 | window.router = router; 42 | 43 | -------------------------------------------------------------------------------- /mock/api/course/list.js: -------------------------------------------------------------------------------- 1 | var Mock = require('mockjs'); 2 | 3 | module.exports = function(req, res, next) { 4 | req.setEncoding('utf8'); 5 | var pageSize = req.query.pageSize || 5; 6 | var pageNo = req.query.pageNo || 1; 7 | var listData = []; 8 | for(var i = 0; i < pageSize; i++) { 9 | var id = (pageNo - 1) * pageSize + i + 1; 10 | listData.push({ 11 | 'id|+1': id, 12 | url: '#!/user/' + id, 13 | username: 'Chuck Norris ' + id 14 | }); 15 | } 16 | var data = { 17 | success: true, 18 | data: { 19 | pageNo: pageNo, 20 | totalCount: 20, 21 | 'listData|5': [{ 22 | 'id': '@id', 23 | 'title': '@title(2)', 24 | 'tags': '@cword(2),@cword(2),@cword(2)', 25 | 'timeRange': '10:00-11:00', 26 | 'price': '55', 27 | 'status|1-3': 1, 28 | 'coachAvatar': '/assets/img/heisencat.png', 29 | 'coachId': '@id()', 30 | 'description': '@csentence(5)' 31 | }] 32 | } 33 | }; 34 | data = JSON.stringify(Mock.mock(data)); 35 | res.end(data); 36 | } 37 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_hover.scss: -------------------------------------------------------------------------------- 1 | @mixin hover { 2 | @if $enable-hover-media-query { 3 | // See Media Queries Level 4: http://drafts.csswg.org/mediaqueries/#hover 4 | // Currently shimmed by https://github.com/twbs/mq4-hover-shim 5 | @media (hover: hover) { 6 | &:hover { @content } 7 | } 8 | } 9 | @else { 10 | &:hover { @content } 11 | } 12 | } 13 | 14 | @mixin hover-focus { 15 | @if $enable-hover-media-query { 16 | &:focus { @content } 17 | @include hover { @content } 18 | } 19 | @else { 20 | &:focus, 21 | &:hover { 22 | @content 23 | } 24 | } 25 | } 26 | 27 | @mixin plain-hover-focus { 28 | @if $enable-hover-media-query { 29 | &, 30 | &:focus { 31 | @content 32 | } 33 | @include hover { @content } 34 | } 35 | @else { 36 | &, 37 | &:focus, 38 | &:hover { 39 | @content 40 | } 41 | } 42 | } 43 | 44 | @mixin hover-focus-active { 45 | @if $enable-hover-media-query { 46 | &:focus, 47 | &:active { 48 | @content 49 | } 50 | @include hover { @content } 51 | } 52 | @else { 53 | &:focus, 54 | &:active, 55 | &:hover { 56 | @content 57 | } 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "lib.flexible", 3 | "description": "移动端自适应方案", 4 | "version": "0.3.2", 5 | "homepage": "http://gitlab.alibaba-inc.com/mtb/lib-flexible", 6 | "author": [ 7 | { 8 | "name": "寒泉", 9 | "email": "hanquan.csf@taobao.com" 10 | }, 11 | { 12 | "name": "渚薰", 13 | "email": "zhuxun.jb@taobao.com" 14 | } 15 | ], 16 | "repository": { 17 | "type": "git", 18 | "url": "git@gitlab.alibaba-inc.com:mtb/lib-flexible.git" 19 | }, 20 | "licenses": [ 21 | { 22 | "type": "MIT", 23 | "url": "/blob/master/LICENSE-MIT" 24 | } 25 | ], 26 | "engines": { 27 | "node": ">= 0.8.0" 28 | }, 29 | "devDependencies": { 30 | "grunt": "~0.4.1", 31 | "grunt-contrib-clean": "~0.5.0", 32 | "grunt-contrib-copy": "~0.4.1", 33 | "grunt-contrib-cssmin": "~0.6.0", 34 | "grunt-contrib-less": "~0.6.4", 35 | "grunt-contrib-uglify": "~0.2.0", 36 | "grunt-contrib-watch": "~0.4.0", 37 | "grunt-css2js": "^0.2.4", 38 | "grunt-depcombo": "^0.2.3", 39 | "grunt-depconcat": "^0.2.1" 40 | }, 41 | "dependencies": {}, 42 | "combo": {}, 43 | "keywords": [ 44 | "lib", 45 | "tbm" 46 | ] 47 | } 48 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_pager.scss: -------------------------------------------------------------------------------- 1 | .pager { 2 | padding-left: 0; 3 | margin-top: $spacer-y; 4 | margin-bottom: $spacer-y; 5 | text-align: center; 6 | list-style: none; 7 | @include clearfix(); 8 | 9 | li { 10 | display: inline; 11 | 12 | > a, 13 | > span { 14 | display: inline-block; 15 | padding: 5px 14px; 16 | background-color: $pager-bg; 17 | border: $pager-border-width solid $pager-border-color; 18 | border-radius: $pager-border-radius; 19 | } 20 | 21 | > a { 22 | @include hover-focus { 23 | text-decoration: none; 24 | background-color: $pager-hover-bg; 25 | } 26 | } 27 | } 28 | 29 | .disabled { 30 | > a { 31 | @include plain-hover-focus { 32 | color: $pager-disabled-color; 33 | cursor: $cursor-disabled; 34 | background-color: $pager-bg; 35 | } 36 | } 37 | > span { 38 | color: $pager-disabled-color; 39 | cursor: $cursor-disabled; 40 | background-color: $pager-bg; 41 | } 42 | } 43 | } 44 | 45 | .pager-next { 46 | > a, 47 | > span { 48 | float: right; 49 | } 50 | } 51 | 52 | .pager-prev { 53 | > a, 54 | > span { 55 | float: left; 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_utilities-spacing.scss: -------------------------------------------------------------------------------- 1 | // Margin and Padding 2 | 3 | .m-x-auto { 4 | margin-right: auto !important; 5 | margin-left: auto !important; 6 | } 7 | 8 | @each $prop, $abbrev in (margin: m, padding: p) { 9 | @each $size, $lengths in $spacers { 10 | $length-x: map-get($lengths, x); 11 | $length-y: map-get($lengths, y); 12 | 13 | .#{$abbrev}-a-#{$size} { #{$prop}: $length-y $length-x !important; } // a = All sides 14 | .#{$abbrev}-t-#{$size} { #{$prop}-top: $length-y !important; } 15 | .#{$abbrev}-r-#{$size} { #{$prop}-right: $length-x !important; } 16 | .#{$abbrev}-b-#{$size} { #{$prop}-bottom: $length-y !important; } 17 | .#{$abbrev}-l-#{$size} { #{$prop}-left: $length-x !important; } 18 | 19 | // Axes 20 | .#{$abbrev}-x-#{$size} { 21 | #{$prop}-right: $length-x !important; 22 | #{$prop}-left: $length-x !important; 23 | } 24 | .#{$abbrev}-y-#{$size} { 25 | #{$prop}-top: $length-y !important; 26 | #{$prop}-bottom: $length-y !important; 27 | } 28 | } 29 | } 30 | 31 | // Positioning 32 | 33 | .pos-f-t { 34 | position: fixed; 35 | top: 0; 36 | right: 0; 37 | left: 0; 38 | z-index: $zindex-navbar-fixed; 39 | } 40 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/flexible_css.js: -------------------------------------------------------------------------------- 1 | !function(){var a="@charset \"utf-8\";html{color:#000;background:#fff;overflow-y:scroll;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}html *{outline:0;-webkit-text-size-adjust:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}html,body{font-family:sans-serif}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td,hr,button,article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{margin:0;padding:0}input,select,textarea{font-size:100%}table{border-collapse:collapse;border-spacing:0}fieldset,img{border:0}abbr,acronym{border:0;font-variant:normal}del{text-decoration:line-through}address,caption,cite,code,dfn,em,th,var{font-style:normal;font-weight:500}ol,ul{list-style:none}caption,th{text-align:left}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:500}q:before,q:after{content:''}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}a:hover{text-decoration:underline}ins,a{text-decoration:none}",b=document.createElement("style");if(document.getElementsByTagName("head")[0].appendChild(b),b.styleSheet)b.styleSheet.disabled||(b.styleSheet.cssText=a);else try{b.innerHTML=a}catch(c){b.innerText=a}}(); -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_image.scss: -------------------------------------------------------------------------------- 1 | // Image Mixins 2 | // - Responsive image 3 | // - Retina image 4 | 5 | 6 | // Responsive image 7 | // 8 | // Keep images from scaling beyond the width of their parents. 9 | 10 | @mixin img-fluid($display: block) { 11 | display: $display; 12 | max-width: 100%; // Part 1: Set a maximum relative to the parent 13 | height: auto; // Part 2: Scale the height according to the width, otherwise you get stretching 14 | } 15 | 16 | 17 | // Retina image 18 | // 19 | // Short retina mixin for setting background-image and -size. 20 | 21 | @mixin img-retina($file-1x, $file-2x, $width-1x, $height-1x) { 22 | background-image: url($file-1x); 23 | 24 | // Autoprefixer takes care of adding -webkit-min-device-pixel-ratio and -o-min-device-pixel-ratio, 25 | // but doesn't convert dppx=>dpi. 26 | // There's no such thing as unprefixed min-device-pixel-ratio since it's nonstandard. 27 | // Compatibility info: http://caniuse.com/#feat=css-media-resolution 28 | @media 29 | only screen and (min-resolution: 192dpi), // IE9-11 don't support dppx 30 | only screen and (min-resolution: 2dppx) { // Standardized 31 | background-image: url($file-2x); 32 | background-size: $width-1x $height-1x; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/views/coach.vue: -------------------------------------------------------------------------------- 1 | 23 | 24 | 53 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/bootstrap.scss: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v4.0.0-alpha.2 (http://getbootstrap.com) 3 | * Copyright 2011-2015 Twitter, Inc. 4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 5 | */ 6 | 7 | // Core variables and mixins 8 | @import "variables"; 9 | @import "mixins"; 10 | 11 | // Reset and dependencies 12 | @import "normalize"; 13 | @import "print"; 14 | 15 | // Core CSS 16 | @import "reboot"; 17 | @import "type"; 18 | @import "images"; 19 | @import "code"; 20 | @import "grid"; 21 | @import "tables"; 22 | @import "forms"; 23 | @import "buttons"; 24 | 25 | // Components 26 | @import "animation"; 27 | @import "dropdown"; 28 | @import "button-group"; 29 | @import "input-group"; 30 | @import "custom-forms"; 31 | @import "nav"; 32 | @import "navbar"; 33 | @import "card"; 34 | @import "breadcrumb"; 35 | @import "pagination"; 36 | @import "pager"; 37 | @import "labels"; 38 | @import "jumbotron"; 39 | @import "alert"; 40 | @import "progress"; 41 | @import "media"; 42 | @import "list-group"; 43 | @import "responsive-embed"; 44 | @import "close"; 45 | 46 | // Components w/ JavaScript 47 | @import "modal"; 48 | @import "tooltip"; 49 | @import "popover"; 50 | @import "carousel"; 51 | 52 | // Utility classes 53 | @import "utilities"; 54 | @import "utilities-background"; 55 | @import "utilities-spacing"; 56 | @import "utilities-responsive"; 57 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_code.scss: -------------------------------------------------------------------------------- 1 | // Inline and block code styles 2 | code, 3 | kbd, 4 | pre, 5 | samp { 6 | font-family: $font-family-monospace; 7 | } 8 | 9 | // Inline code 10 | code { 11 | padding: .2rem .4rem; 12 | font-size: 90%; 13 | color: $code-color; 14 | background-color: $code-bg; 15 | @include border-radius($border-radius); 16 | } 17 | 18 | // User input typically entered via keyboard 19 | kbd { 20 | padding: .2rem .4rem; 21 | font-size: 90%; 22 | color: $kbd-color; 23 | background-color: $kbd-bg; 24 | @include border-radius($border-radius-sm); 25 | @include box-shadow(inset 0 -.1rem 0 rgba(0,0,0,.25)); 26 | 27 | kbd { 28 | padding: 0; 29 | font-size: 100%; 30 | font-weight: $nested-kbd-font-weight; 31 | @include box-shadow(none); 32 | } 33 | } 34 | 35 | // Blocks of code 36 | pre { 37 | display: block; 38 | margin-top: 0; 39 | margin-bottom: 1rem; 40 | font-size: 90%; 41 | line-height: $line-height; 42 | color: $pre-color; 43 | 44 | // Account for some code outputs that place code tags in pre tags 45 | code { 46 | padding: 0; 47 | font-size: inherit; 48 | color: inherit; 49 | background-color: transparent; 50 | border-radius: 0; 51 | } 52 | } 53 | 54 | // Enable scrollable blocks of code 55 | .pre-scrollable { 56 | max-height: $pre-scrollable-max-height; 57 | overflow-y: scroll; 58 | } 59 | -------------------------------------------------------------------------------- /src/route-config.js: -------------------------------------------------------------------------------- 1 | export function configRouter (router) { 2 | 3 | router.map({ 4 | 5 | '/course/:type': { 6 | name: 'course', 7 | component: require('./views/course.vue') 8 | }, 9 | 10 | '/coach/:id': { 11 | name: 'coach', 12 | component: require('./views/coach.vue') 13 | }, 14 | 15 | '/wallet': { 16 | name: 'wallet', 17 | component: require('./views/wallet.vue') 18 | }, 19 | 20 | '/order': { 21 | name: 'order', 22 | component: require('./views/order.vue') 23 | }, 24 | 25 | '/about': { 26 | component: require('./views/about.vue') 27 | }, 28 | 29 | 30 | '*': { 31 | component: require('./views/not-found.vue') 32 | } 33 | }); 34 | 35 | // redirect 36 | router.redirect({ 37 | '/': '/course/team' 38 | }); 39 | 40 | // global before 41 | // 3 options: 42 | // 1. return a boolean 43 | // 2. return a Promise that resolves to a boolean 44 | // 3. call transition.next() or transition.abort() 45 | router.beforeEach((transition) => { 46 | if (transition.to.path === '/forbidden') { 47 | router.app.authenticating = true; 48 | setTimeout(() => { 49 | router.app.authenticating = false; 50 | alert('this route is forbidden by a global before hook'); 51 | transition.abort(); 52 | }, 3000); 53 | } else { 54 | transition.next(); 55 | } 56 | }); 57 | } 58 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/bootstrap-grid.scss: -------------------------------------------------------------------------------- 1 | // Bootstrap Grid only 2 | // 3 | // Includes relevant variables and mixins for the regular (non-flexbox) grid 4 | // system, as well as the generated predefined classes (e.g., `.col-4-sm`). 5 | 6 | 7 | // 8 | // Variables 9 | // 10 | 11 | 12 | // Grid breakpoints 13 | // 14 | // Define the minimum and maximum dimensions at which your layout will change, 15 | // adapting to different screen sizes, for use in media queries. 16 | 17 | $grid-breakpoints: ( 18 | // Extra small screen / phone 19 | xs: 0, 20 | // Small screen / phone 21 | sm: 544px, 22 | // Medium screen / tablet 23 | md: 768px, 24 | // Large screen / desktop 25 | lg: 992px, 26 | // Extra large screen / wide desktop 27 | xl: 1200px 28 | ) !default; 29 | 30 | 31 | // Grid containers 32 | // 33 | // Define the maximum width of `.container` for different screen sizes. 34 | 35 | $container-max-widths: ( 36 | sm: 576px, 37 | md: 720px, 38 | lg: 940px, 39 | xl: 1140px 40 | ) !default; 41 | 42 | 43 | // Grid columns 44 | // 45 | // Set the number of columns and specify the width of the gutters. 46 | 47 | $grid-columns: 12 !default; 48 | $grid-gutter-width: 1.875rem !default; // 30px 49 | 50 | 51 | // 52 | // Grid mixins 53 | // 54 | 55 | @import "variables"; 56 | 57 | @import "mixins/clearfix"; 58 | @import "mixins/breakpoints"; 59 | @import "mixins/grid-framework"; 60 | @import "mixins/grid"; 61 | 62 | @import "grid"; 63 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_mixins.scss: -------------------------------------------------------------------------------- 1 | // Toggles 2 | // 3 | // Used in conjunction with global variables to enable certain theme features. 4 | 5 | @mixin box-shadow($shadow...) { 6 | @if $enable-shadows { 7 | box-shadow: $shadow; 8 | } 9 | } 10 | 11 | @mixin transition($transition...) { 12 | @if $enable-transitions { 13 | transition: $transition; 14 | } 15 | } 16 | 17 | // Utilities 18 | @import "mixins/breakpoints"; 19 | @import "mixins/hover"; 20 | @import "mixins/image"; 21 | @import "mixins/label"; 22 | @import "mixins/reset-filter"; 23 | @import "mixins/resize"; 24 | @import "mixins/screen-reader"; 25 | @import "mixins/size"; 26 | @import "mixins/tab-focus"; 27 | @import "mixins/reset-text"; 28 | @import "mixins/text-emphasis"; 29 | @import "mixins/text-hide"; 30 | @import "mixins/text-truncate"; 31 | 32 | // // Components 33 | @import "mixins/alert"; 34 | @import "mixins/buttons"; 35 | @import "mixins/cards"; 36 | @import "mixins/pagination"; 37 | @import "mixins/lists"; 38 | @import "mixins/list-group"; 39 | @import "mixins/nav-divider"; 40 | @import "mixins/forms"; 41 | @import "mixins/progress"; 42 | @import "mixins/table-row"; 43 | 44 | // // Skins 45 | @import "mixins/background-variant"; 46 | @import "mixins/border-radius"; 47 | @import "mixins/gradients"; 48 | 49 | // // Layout 50 | @import "mixins/clearfix"; 51 | @import "mixins/center-block"; 52 | // @import "mixins/navbar-align"; 53 | @import "mixins/grid-framework"; 54 | @import "mixins/grid"; 55 | @import "mixins/pulls"; 56 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_media.scss: -------------------------------------------------------------------------------- 1 | @if $enable-flex { 2 | .media { 3 | display: flex; 4 | margin-bottom: $spacer; 5 | } 6 | .media-body { 7 | flex: 1; 8 | } 9 | .media-middle { 10 | align-self: center; 11 | } 12 | .media-bottom { 13 | align-self: flex-end; 14 | } 15 | } @else { 16 | .media { 17 | margin-top: 15px; 18 | 19 | &:first-child { 20 | margin-top: 0; 21 | } 22 | } 23 | .media, 24 | .media-body { 25 | overflow: hidden; 26 | zoom: 1; 27 | } 28 | .media-body { 29 | width: 10000px; 30 | } 31 | .media-left, 32 | .media-right, 33 | .media-body { 34 | display: table-cell; 35 | vertical-align: top; 36 | } 37 | .media-middle { 38 | vertical-align: middle; 39 | } 40 | .media-bottom { 41 | vertical-align: bottom; 42 | } 43 | } 44 | 45 | 46 | // 47 | // Images/elements as the media anchor 48 | // 49 | 50 | .media-object { 51 | display: block; 52 | 53 | // Fix collapse in webkit from max-width: 100% and display: table-cell. 54 | &.img-thumbnail { 55 | max-width: none; 56 | } 57 | } 58 | 59 | 60 | // 61 | // Alignment 62 | // 63 | 64 | .media-right { 65 | padding-left: 10px; 66 | } 67 | 68 | .media-left { 69 | padding-right: 10px; 70 | } 71 | 72 | 73 | // 74 | // Headings 75 | // 76 | 77 | .media-heading { 78 | margin-top: 0; 79 | margin-bottom: 5px; 80 | } 81 | 82 | 83 | // 84 | // Media list variation 85 | // 86 | 87 | .media-list { 88 | padding-left: 0; 89 | list-style: none; 90 | } 91 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_images.scss: -------------------------------------------------------------------------------- 1 | // Responsive images (ensure images don't scale beyond their parents) 2 | // 3 | // This is purposefully opt-in via an explicit class rather than being the default for all ``s. 4 | // We previously tried the "images are responsive by default" approach in Bootstrap v2, 5 | // and abandoned it in Bootstrap v3 because it breaks lots of third-party widgets (including Google Maps) 6 | // which weren't expecting the images within themselves to be involuntarily resized. 7 | // See also https://github.com/twbs/bootstrap/issues/18178 8 | .img-fluid { 9 | @include img-fluid(); 10 | } 11 | 12 | // Rounded corners 13 | .img-rounded { 14 | @include border-radius($border-radius-lg); 15 | } 16 | 17 | // Image thumbnails 18 | .img-thumbnail { 19 | padding: $thumbnail-padding; 20 | line-height: $line-height; 21 | background-color: $thumbnail-bg; 22 | border: $thumbnail-border-width solid $thumbnail-border-color; 23 | border-radius: $thumbnail-border-radius; 24 | transition: all .2s ease-in-out; 25 | @include box-shadow(0 1px 2px rgba(0,0,0,.075)); 26 | 27 | // Keep them at most 100% wide 28 | @include img-fluid(inline-block); 29 | } 30 | 31 | // Perfect circle 32 | .img-circle { 33 | border-radius: 50%; 34 | } 35 | 36 | // 37 | // Figures 38 | // 39 | 40 | .figure { 41 | // Ensures the caption's text aligns with the image. 42 | display: inline-block; 43 | } 44 | 45 | .figure-img { 46 | margin-bottom: ($spacer-y / 2); 47 | line-height: 1; 48 | } 49 | 50 | .figure-caption { 51 | font-size: 90%; 52 | color: $gray-light; 53 | } 54 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_grid-framework.scss: -------------------------------------------------------------------------------- 1 | // Framework grid generation 2 | // 3 | // Used only by Bootstrap to generate the correct number of grid classes given 4 | // any value of `$grid-columns`. 5 | 6 | @mixin make-grid-columns($columns: $grid-columns, $gutter: $grid-gutter-width, $breakpoints: $grid-breakpoints) { 7 | // Common properties for all breakpoints 8 | %grid-column { 9 | position: relative; 10 | // Prevent columns from collapsing when empty 11 | min-height: 1px; 12 | // Inner gutter via padding 13 | padding-left: ($gutter / 2); 14 | padding-right: ($gutter / 2); 15 | } 16 | @each $breakpoint in map-keys($breakpoints) { 17 | @for $i from 1 through $columns { 18 | .col-#{$breakpoint}-#{$i} { 19 | @extend %grid-column; 20 | } 21 | } 22 | @include media-breakpoint-up($breakpoint) { 23 | // Work around cross-media @extend (https://github.com/sass/sass/issues/1050) 24 | %grid-column-float-#{$breakpoint} { 25 | float: left; 26 | } 27 | @for $i from 1 through $columns { 28 | .col-#{$breakpoint}-#{$i} { 29 | @if not $enable-flex { 30 | @extend %grid-column-float-#{$breakpoint}; 31 | } 32 | @include make-col-span($i, $columns); 33 | } 34 | } 35 | @each $modifier in (pull, push, offset) { 36 | @for $i from 0 through $columns { 37 | .col-#{$breakpoint}-#{$modifier}-#{$i} { 38 | @include make-col-modifier($modifier, $i, $columns) 39 | } 40 | } 41 | } 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/flexible_css.debug.js: -------------------------------------------------------------------------------- 1 | (function () { 2 | // flexible.css 3 | var cssText = "" + 4 | "@charset \"utf-8\";html{color:#000;background:#fff;overflow-y:scroll;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}html *{outline:0;-webkit-text-size-adjust:none;-webkit-tap-highlight-color:rgba(0,0,0,0)}html,body{font-family:sans-serif}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td,hr,button,article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{margin:0;padding:0}input,select,textarea{font-size:100%}table{border-collapse:collapse;border-spacing:0}fieldset,img{border:0}abbr,acronym{border:0;font-variant:normal}del{text-decoration:line-through}address,caption,cite,code,dfn,em,th,var{font-style:normal;font-weight:500}ol,ul{list-style:none}caption,th{text-align:left}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:500}q:before,q:after{content:''}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}a:hover{text-decoration:underline}ins,a{text-decoration:none}"; 5 | // cssText end 6 | 7 | var styleEl = document.createElement("style"); 8 | document.getElementsByTagName("head")[0].appendChild(styleEl); 9 | if (styleEl.styleSheet) { 10 | if (!styleEl.styleSheet.disabled) { 11 | styleEl.styleSheet.cssText = cssText; 12 | } 13 | } else { 14 | try { 15 | styleEl.innerHTML = cssText 16 | } catch(e) { 17 | styleEl.innerText = cssText; 18 | } 19 | } 20 | }()); 21 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_alert.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Base styles 3 | // 4 | 5 | .alert { 6 | padding: $alert-padding; 7 | margin-bottom: $spacer-y; 8 | border: $alert-border-width solid transparent; 9 | @include border-radius($alert-border-radius); 10 | 11 | // Improve alignment and spacing of inner content 12 | > p, 13 | > ul { 14 | margin-bottom: 0; 15 | } 16 | > p + p { 17 | margin-top: 5px; 18 | } 19 | } 20 | 21 | // Headings for larger alerts 22 | .alert-heading { 23 | // Specified to prevent conflicts of changing $headings-color 24 | color: inherit; 25 | } 26 | 27 | // Provide class for links that match alerts 28 | .alert-link { 29 | font-weight: $alert-link-font-weight; 30 | } 31 | 32 | 33 | // Dismissible alerts 34 | // 35 | // Expand the right padding and account for the close button's positioning. 36 | 37 | .alert-dismissible { 38 | padding-right: ($alert-padding + 20); 39 | 40 | // Adjust close link position 41 | .close { 42 | position: relative; 43 | top: -2px; 44 | right: -21px; 45 | color: inherit; 46 | } 47 | } 48 | 49 | 50 | // Alternate styles 51 | // 52 | // Generate contextual modifier classes for colorizing the alert. 53 | 54 | .alert-success { 55 | @include alert-variant($alert-success-bg, $alert-success-border, $alert-success-text); 56 | } 57 | .alert-info { 58 | @include alert-variant($alert-info-bg, $alert-info-border, $alert-info-text); 59 | } 60 | .alert-warning { 61 | @include alert-variant($alert-warning-bg, $alert-warning-border, $alert-warning-text); 62 | } 63 | .alert-danger { 64 | @include alert-variant($alert-danger-bg, $alert-danger-border, $alert-danger-text); 65 | } 66 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/makegrid.js: -------------------------------------------------------------------------------- 1 | !function(a,b){function c(a){var c=parseFloat(a.designWidth),d=parseFloat(a.designUnit),h=parseFloat(a.columnCount),i=parseFloat(a.columnXUnit),j=parseFloat(a.gutterXUnit),k=parseFloat(a.edgeXUnit),l=a.className||"grid";if(!(a.designWidth&&a.designUnit&&a.columnCount&&a.columnXUnit&&a.gutterXUnit&&a.edgeXUnit))throw new Error("参数错误");b.flexible.gridParams=a;for(var m=d/c*10,n=i*m,o=j*m,p=k*m,q=["."+l+" {","box-sizing:content-box;","padding-left: "+p+"rem;","padding-right: "+p+"rem;","margin-left: -"+o+"rem;","}","."+l+":before,","."+l+":after{",'content: " ";',"display: table;","}","."+l+":after {","clear: both;","}","."+l+' [class^="col-"] {',"margin-left: "+o+"rem;","float: left;","}"],r=1;h>=r;r++){var s=n*r+o*(r-1);q.push("."+l+" .col-"+r+" {width: "+s+"rem;}")}e&&e.parentNode&&e.parentNode.removeChild(e),e=f.createElement("style"),e.innerHTML=q.join("");var t=f.querySelector("head")||g.firstElementChild||g;t.appendChild(e)}function d(a){var b=j[a];if(!b)throw new Error("不支持这个预设模式");c(b)}var e,f=a.document,g=f.documentElement,h=f.querySelector('meta[name="grid"]'),i=b.flexible||(b.flexible={}),j={"750-12":{designWidth:750,designUnit:6,columnCount:12,columnXUnit:7,gutterXUnit:3,edgeXUnit:4},"750-6":{designWidth:750,designUnit:6,columnCount:6,columnXUnit:17,gutterXUnit:3,edgeXUnit:4},"640-12":{designWidth:640,designUnit:4,columnCount:12,columnXUnit:11,gutterXUnit:2,edgeXUnit:3},"640-6":{designWidth:640,designUnit:4,columnCount:6,columnXUnit:24,gutterXUnit:2,edgeXUnit:3}};if(h){var k=h.getAttribute("content");if(k){for(var l,m=/([^=]+)=([\d\.\-]+)/g,n={};l=m.exec(k);)n[l[1]]=l[2];n.modeName?d(n.modeName):c(n)}}i.makeGrid=c,i.makeGridMode=d}(window,window.lib||(window.lib={})); -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/flexible.js: -------------------------------------------------------------------------------- 1 | !function(a,b){function c(){var b=f.getBoundingClientRect().width;b/i>540&&(b=540*i);var c=b/10;f.style.fontSize=c+"px",k.rem=a.rem=c}var d,e=a.document,f=e.documentElement,g=e.querySelector('meta[name="viewport"]'),h=e.querySelector('meta[name="flexible"]'),i=0,j=0,k=b.flexible||(b.flexible={});if(g){console.warn("将根据已有的meta标签来设置缩放比例");var l=g.getAttribute("content").match(/initial\-scale=([\d\.]+)/);l&&(j=parseFloat(l[1]),i=parseInt(1/j))}else if(h){var m=h.getAttribute("content");if(m){var n=m.match(/initial\-dpr=([\d\.]+)/),o=m.match(/maximum\-dpr=([\d\.]+)/);n&&(i=parseFloat(n[1]),j=parseFloat((1/i).toFixed(2))),o&&(i=parseFloat(o[1]),j=parseFloat((1/i).toFixed(2)))}}if(!i&&!j){var p=(a.navigator.appVersion.match(/android/gi),a.navigator.appVersion.match(/iphone/gi)),q=a.devicePixelRatio;i=p?q>=3&&(!i||i>=3)?3:q>=2&&(!i||i>=2)?2:1:1,j=1/i}if(f.setAttribute("data-dpr",i),!g)if(g=e.createElement("meta"),g.setAttribute("name","viewport"),g.setAttribute("content","initial-scale="+j+", maximum-scale="+j+", minimum-scale="+j+", user-scalable=no"),f.firstElementChild)f.firstElementChild.appendChild(g);else{var r=e.createElement("div");r.appendChild(g),e.write(r.innerHTML)}a.addEventListener("resize",function(){clearTimeout(d),d=setTimeout(c,300)},!1),a.addEventListener("pageshow",function(a){a.persisted&&(clearTimeout(d),d=setTimeout(c,300))},!1),"complete"===e.readyState?e.body.style.fontSize=12*i+"px":e.addEventListener("DOMContentLoaded",function(){e.body.style.fontSize=12*i+"px"},!1),c(),k.dpr=a.dpr=i,k.refreshRem=c,k.rem2px=function(a){var b=parseFloat(a)*this.rem;return"string"==typeof a&&a.match(/rem$/)&&(b+="px"),b},k.px2rem=function(a){var b=parseFloat(a)/this.rem;return"string"==typeof a&&a.match(/px$/)&&(b+="rem"),b}}(window,window.lib||(window.lib={})); -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_print.scss: -------------------------------------------------------------------------------- 1 | // Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css 2 | 3 | // ========================================================================== 4 | // Print styles. 5 | // Inlined to avoid the additional HTTP request: h5bp.com/r 6 | // ========================================================================== 7 | 8 | @media print { 9 | *, 10 | *::before, 11 | *::after { 12 | text-shadow: none !important; 13 | box-shadow: none !important; 14 | } 15 | 16 | a, 17 | a:visited { 18 | text-decoration: underline; 19 | } 20 | 21 | abbr[title]::after { 22 | content: " (" attr(title) ")"; 23 | } 24 | 25 | pre, 26 | blockquote { 27 | border: $border-width solid #999; 28 | page-break-inside: avoid; 29 | } 30 | 31 | thead { 32 | display: table-header-group; // h5bp.com/t 33 | } 34 | 35 | tr, 36 | img { 37 | page-break-inside: avoid; 38 | } 39 | 40 | img { 41 | max-width: 100% !important; 42 | } 43 | 44 | p, 45 | h2, 46 | h3 { 47 | orphans: 3; 48 | widows: 3; 49 | } 50 | 51 | h2, 52 | h3 { 53 | page-break-after: avoid; 54 | } 55 | 56 | // Bootstrap specific changes start 57 | 58 | // Bootstrap components 59 | .navbar { 60 | display: none; 61 | } 62 | .btn, 63 | .dropup > .btn { 64 | > .caret { 65 | border-top-color: #000 !important; 66 | } 67 | } 68 | .label { 69 | border: $border-width solid #000; 70 | } 71 | 72 | .table { 73 | border-collapse: collapse !important; 74 | 75 | td, 76 | th { 77 | background-color: #fff !important; 78 | } 79 | } 80 | .table-bordered { 81 | th, 82 | td { 83 | border: 1px solid #ddd !important; 84 | } 85 | } 86 | 87 | // Bootstrap specific changes end 88 | } 89 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_labels.scss: -------------------------------------------------------------------------------- 1 | // Base class 2 | // 3 | // Requires one of the contextual, color modifier classes for `color` and 4 | // `background-color`. 5 | 6 | .label { 7 | display: inline-block; 8 | padding: .25em .4em; 9 | font-size: 75%; 10 | font-weight: $label-font-weight; 11 | line-height: 1; 12 | color: $label-color; 13 | text-align: center; 14 | white-space: nowrap; 15 | vertical-align: baseline; 16 | @include border-radius(); 17 | 18 | // Empty labels collapse automatically 19 | &:empty { 20 | display: none; 21 | } 22 | } 23 | 24 | // Quick fix for labels in buttons 25 | .btn .label { 26 | position: relative; 27 | top: -1px; 28 | } 29 | 30 | // Add hover effects, but only for links 31 | a.label { 32 | @include hover-focus { 33 | color: $label-link-hover-color; 34 | text-decoration: none; 35 | cursor: pointer; 36 | } 37 | } 38 | 39 | // Pill labels 40 | // 41 | // Make them extra rounded with a modifier to replace v3's badges. 42 | 43 | .label-pill { 44 | padding-right: .6em; 45 | padding-left: .6em; 46 | // Use a higher than normal value to ensure completely rounded edges when 47 | // customizing padding or font-size on labels. 48 | @include border-radius(10rem); 49 | } 50 | 51 | // Colors 52 | // 53 | // Contextual variations (linked labels get darker on :hover). 54 | 55 | .label-default { 56 | @include label-variant($label-default-bg); 57 | } 58 | 59 | .label-primary { 60 | @include label-variant($label-primary-bg); 61 | } 62 | 63 | .label-success { 64 | @include label-variant($label-success-bg); 65 | } 66 | 67 | .label-info { 68 | @include label-variant($label-info-bg); 69 | } 70 | 71 | .label-warning { 72 | @include label-variant($label-warning-bg); 73 | } 74 | 75 | .label-danger { 76 | @include label-variant($label-danger-bg); 77 | } 78 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_grid.scss: -------------------------------------------------------------------------------- 1 | // Container widths 2 | // 3 | // Set the container width, and override it for fixed navbars in media queries. 4 | 5 | .container { 6 | @include make-container(); 7 | @include make-container-max-widths(); 8 | 9 | } 10 | 11 | 12 | // Fluid container 13 | // 14 | // Utilizes the mixin meant for fixed width containers, but without any defined 15 | // width for fluid, full width layouts. 16 | 17 | .container-fluid { 18 | @include make-container(); 19 | } 20 | 21 | 22 | // Row 23 | // 24 | // Rows contain and clear the floats of your columns. 25 | 26 | @if $enable-grid-classes { 27 | .row { 28 | @include make-row(); 29 | } 30 | } 31 | 32 | 33 | // Columns 34 | // 35 | // Common styles for small and large grid columns 36 | 37 | @if $enable-grid-classes { 38 | @include make-grid-columns(); 39 | } 40 | 41 | 42 | // Flex variation 43 | // 44 | // Custom styles for additional flex alignment options. 45 | 46 | @if $enable-flex and $enable-grid-classes { 47 | 48 | // Flex column reordering 49 | 50 | @each $breakpoint in map-keys($grid-breakpoints) { 51 | @include media-breakpoint-up($breakpoint) { 52 | .col-#{$breakpoint}-first { order: -1; } 53 | .col-#{$breakpoint}-last { order: 1; } 54 | } 55 | } 56 | 57 | // Alignment for every column in row 58 | 59 | @each $breakpoint in map-keys($grid-breakpoints) { 60 | @include media-breakpoint-up($breakpoint) { 61 | .row-#{$breakpoint}-top { align-items: flex-start; } 62 | .row-#{$breakpoint}-center { align-items: center; } 63 | .row-#{$breakpoint}-bottom { align-items: flex-end; } 64 | } 65 | } 66 | 67 | // Alignment per column 68 | 69 | @each $breakpoint in map-keys($grid-breakpoints) { 70 | @include media-breakpoint-up($breakpoint) { 71 | .col-#{$breakpoint}-top { align-self: flex-start; } 72 | .col-#{$breakpoint}-center { align-self: center; } 73 | .col-#{$breakpoint}-bottom { align-self: flex-end; } 74 | } 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_pagination.scss: -------------------------------------------------------------------------------- 1 | .pagination { 2 | display: inline-block; 3 | padding-left: 0; 4 | margin-top: $spacer-y; 5 | margin-bottom: $spacer-y; 6 | @include border-radius(); 7 | } 8 | 9 | .page-item { 10 | display: inline; // Remove list-style and block-level defaults 11 | 12 | &:first-child { 13 | .page-link { 14 | margin-left: 0; 15 | @include border-left-radius($border-radius); 16 | } 17 | } 18 | &:last-child { 19 | .page-link { 20 | @include border-right-radius($border-radius); 21 | } 22 | } 23 | 24 | &.active .page-link { 25 | @include plain-hover-focus { 26 | z-index: 2; 27 | color: $pagination-active-color; 28 | cursor: default; 29 | background-color: $pagination-active-bg; 30 | border-color: $pagination-active-border; 31 | } 32 | } 33 | 34 | &.disabled .page-link { 35 | @include plain-hover-focus { 36 | color: $pagination-disabled-color; 37 | cursor: $cursor-disabled; 38 | background-color: $pagination-disabled-bg; 39 | border-color: $pagination-disabled-border; 40 | } 41 | } 42 | } 43 | 44 | .page-link { 45 | position: relative; 46 | float: left; // Collapse white-space 47 | padding: $pagination-padding-y $pagination-padding-x; 48 | margin-left: -1px; 49 | line-height: $line-height; 50 | color: $pagination-color; 51 | text-decoration: none; 52 | background-color: $pagination-bg; 53 | border: $pagination-border-width solid $pagination-border-color; 54 | 55 | @include hover-focus { 56 | color: $pagination-hover-color; 57 | background-color: $pagination-hover-bg; 58 | border-color: $pagination-hover-border; 59 | } 60 | } 61 | 62 | 63 | // 64 | // Sizing 65 | // 66 | 67 | .pagination-lg { 68 | @include pagination-size($pagination-padding-y-lg, $pagination-padding-x-lg, $font-size-lg, $line-height-lg, $border-radius-lg); 69 | } 70 | 71 | .pagination-sm { 72 | @include pagination-size($pagination-padding-y-sm, $pagination-padding-x-sm, $font-size-sm, $line-height-sm, $border-radius-sm); 73 | } 74 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_grid.scss: -------------------------------------------------------------------------------- 1 | /// Grid system 2 | // 3 | // Generate semantic grid columns with these mixins. 4 | 5 | @mixin make-container($gutter: $grid-gutter-width) { 6 | margin-left: auto; 7 | margin-right: auto; 8 | padding-left: ($gutter / 2); 9 | padding-right: ($gutter / 2); 10 | @if not $enable-flex { 11 | @include clearfix(); 12 | } 13 | } 14 | 15 | 16 | // For each breakpoint, define the maximum width of the container in a media query 17 | @mixin make-container-max-widths($max-widths: $container-max-widths) { 18 | @each $breakpoint, $container-max-width in $max-widths { 19 | @include media-breakpoint-up($breakpoint) { 20 | max-width: $container-max-width; 21 | } 22 | } 23 | } 24 | 25 | @mixin make-row($gutter: $grid-gutter-width) { 26 | @if $enable-flex { 27 | display: flex; 28 | flex-wrap: wrap; 29 | } @else { 30 | @include clearfix(); 31 | } 32 | margin-left: ($gutter / -2); 33 | margin-right: ($gutter / -2); 34 | } 35 | 36 | @mixin make-col($gutter: $grid-gutter-width) { 37 | position: relative; 38 | @if not $enable-flex { 39 | float: left; 40 | } 41 | min-height: 1px; 42 | padding-left: ($gutter / 2); 43 | padding-right: ($gutter / 2); 44 | } 45 | 46 | @mixin make-col-span($size, $columns: $grid-columns) { 47 | @if $enable-flex { 48 | flex: 0 0 percentage($size / $columns); 49 | } @else { 50 | width: percentage($size / $columns); 51 | } 52 | } 53 | 54 | @mixin make-col-offset($size, $columns: $grid-columns) { 55 | margin-left: percentage($size / $columns); 56 | } 57 | 58 | @mixin make-col-push($size, $columns: $grid-columns) { 59 | left: if($size > 0, percentage($size / $columns), auto); 60 | } 61 | 62 | @mixin make-col-pull($size, $columns: $grid-columns) { 63 | right: if($size > 0, percentage($size / $columns), auto); 64 | } 65 | 66 | @mixin make-col-modifier($type, $size, $columns) { 67 | // Work around the lack of dynamic mixin @include support (https://github.com/sass/sass/issues/626) 68 | @if $type == push { 69 | @include make-col-push($size, $columns); 70 | } @else if $type == pull { 71 | @include make-col-pull($size, $columns); 72 | } @else if $type == offset { 73 | @include make-col-offset($size, $columns); 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "wx-vue", 3 | "version": "0.1.0", 4 | "description": "vuejs admin system", 5 | "main": "index.js", 6 | "scripts": { 7 | "start": "serve2 -M mock", 8 | "dev1": "node server", 9 | "dev": "webpack --watch --inline --hot --config build/webpack.dev.config.js", 10 | "build": "webpack --progress --hide-modules --config build/webpack.prod.config.js", 11 | "test": "karma start build/karma.conf.js" 12 | }, 13 | "repository": { 14 | "type": "git", 15 | "url": "github.com/lynzz/wx-vue" 16 | }, 17 | "author": "lynzz", 18 | "license": "MIT", 19 | "bugs": { 20 | "url": "https://github.com/lynzz/wx-vue/issues" 21 | }, 22 | "homepage": "https://github.com/lynzz/wx-vue", 23 | "devDependencies": { 24 | "babel-core": "^6.1.2", 25 | "babel-loader": "^6.1.0", 26 | "babel-plugin-transform-runtime": "^6.1.2", 27 | "babel-preset-es2015": "^6.1.2", 28 | "babel-preset-stage-0": "^6.1.2", 29 | "babel-runtime": "^5.8.0", 30 | "css-loader": "^0.23.0", 31 | "es6-promise": "^3.0.2", 32 | "eslint": "^1.10.3", 33 | "eslint-loader": "^1.1.1", 34 | "file-loader": "^0.8.4", 35 | "function-bind": "^1.0.2", 36 | "inject-loader": "^2.0.1", 37 | "jade": "^1.11.0", 38 | "jasmine-core": "^2.4.1", 39 | "karma": "^0.13.15", 40 | "karma-jasmine": "^0.3.6", 41 | "karma-phantomjs-launcher": "^0.2.1", 42 | "karma-spec-reporter": "0.0.23", 43 | "karma-webpack": "^1.7.0", 44 | "less": "^2.5.3", 45 | "less-loader": "^2.2.2", 46 | "mockjs": "^1.0.1-beta1", 47 | "node-sass": "^3.4.2", 48 | "phantomjs": "^1.9.19", 49 | "sass-loader": "^3.1.2", 50 | "style-loader": "^0.13.0", 51 | "stylus-loader": "^1.4.0", 52 | "template-html-loader": "0.0.3", 53 | "url-loader": "^0.5.7", 54 | "vue": "^1.0.13", 55 | "vue-hot-reload-api": "^1.2.0", 56 | "vue-html-loader": "^1.0.0", 57 | "vue-loader": "^7.3.0", 58 | "vue-resource": "^0.5.1", 59 | "vue-router": "^0.7.7", 60 | "vue-touch": "^0.1.2", 61 | "vue-validator": "^2.0.0-alpha.8", 62 | "webpack": "^1.12.2", 63 | "webpack-dev-server": "^1.12.0", 64 | "wx_jsapi_sign": "^1.0.3" 65 | }, 66 | "dependencies": { 67 | "jssha": "^1.6.0", 68 | "moment": "^2.11.1", 69 | "vue-swipe": "^0.2.0" 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_utilities.scss: -------------------------------------------------------------------------------- 1 | // 2 | // Floats 3 | // 4 | 5 | .clearfix { 6 | @include clearfix(); 7 | } 8 | 9 | .center-block { 10 | @include center-block(); 11 | } 12 | 13 | @each $breakpoint in map-keys($grid-breakpoints) { 14 | @include media-breakpoint-up($breakpoint) { 15 | .pull-#{$breakpoint}-left { 16 | @include pull-left(); 17 | } 18 | .pull-#{$breakpoint}-right { 19 | @include pull-right(); 20 | } 21 | .pull-#{$breakpoint}-none { 22 | float: none !important; 23 | } 24 | } 25 | } 26 | 27 | 28 | // 29 | // Screenreaders 30 | // 31 | 32 | .sr-only { 33 | @include sr-only(); 34 | } 35 | 36 | .sr-only-focusable { 37 | @include sr-only-focusable(); 38 | } 39 | 40 | .invisible { 41 | visibility: hidden !important; 42 | } 43 | 44 | .text-hide { 45 | @include text-hide(); 46 | } 47 | 48 | 49 | // 50 | // Text 51 | // 52 | 53 | // Alignment 54 | 55 | .text-justify { text-align: justify !important; } 56 | .text-nowrap { white-space: nowrap !important; } 57 | .text-truncate { @include text-truncate; } 58 | 59 | // Responsive alignment 60 | 61 | @each $breakpoint in map-keys($grid-breakpoints) { 62 | @include media-breakpoint-up($breakpoint) { 63 | .text-#{$breakpoint}-left { text-align: left !important; } 64 | .text-#{$breakpoint}-right { text-align: right !important; } 65 | .text-#{$breakpoint}-center { text-align: center !important; } 66 | } 67 | } 68 | 69 | // Transformation 70 | 71 | .text-lowercase { text-transform: lowercase !important; } 72 | .text-uppercase { text-transform: uppercase !important; } 73 | .text-capitalize { text-transform: capitalize !important; } 74 | 75 | // Weight and italics 76 | 77 | .font-weight-normal { font-weight: normal; } 78 | .font-weight-bold { font-weight: bold; } 79 | .font-italic { font-style: italic; } 80 | 81 | // Contextual colors 82 | 83 | .text-muted { 84 | color: $text-muted; 85 | } 86 | 87 | @include text-emphasis-variant('.text-primary', $brand-primary); 88 | 89 | @include text-emphasis-variant('.text-success', $brand-success); 90 | 91 | @include text-emphasis-variant('.text-info', $brand-info); 92 | 93 | @include text-emphasis-variant('.text-warning', $brand-warning); 94 | 95 | @include text-emphasis-variant('.text-danger', $brand-danger); 96 | -------------------------------------------------------------------------------- /assets/vendor/lib-flexible/flexible.debug.css: -------------------------------------------------------------------------------- 1 | @charset "utf-8"; 2 | html { 3 | color: #000; 4 | background: #fff; 5 | overflow-y: scroll; 6 | -webkit-text-size-adjust: 100%; 7 | -ms-text-size-adjust: 100%; 8 | } 9 | html * { 10 | outline: none; 11 | -webkit-text-size-adjust: none; 12 | -webkit-tap-highlight-color: rgba(0, 0, 0, 0); 13 | } 14 | html, 15 | body { 16 | font-family: sans-serif; 17 | } 18 | /* 内外边距通常让各个浏览器样式的表现位置不同 */ 19 | body, 20 | div, 21 | dl, 22 | dt, 23 | dd, 24 | ul, 25 | ol, 26 | li, 27 | h1, 28 | h2, 29 | h3, 30 | h4, 31 | h5, 32 | h6, 33 | pre, 34 | code, 35 | form, 36 | fieldset, 37 | legend, 38 | input, 39 | textarea, 40 | p, 41 | blockquote, 42 | th, 43 | td, 44 | hr, 45 | button, 46 | article, 47 | aside, 48 | details, 49 | figcaption, 50 | figure, 51 | footer, 52 | header, 53 | hgroup, 54 | menu, 55 | nav, 56 | section { 57 | margin: 0; 58 | padding: 0; 59 | } 60 | input, 61 | select, 62 | textarea { 63 | font-size: 100%; 64 | } 65 | /* 去掉各 Table cell 的边距并让其边重合 */ 66 | table { 67 | border-collapse: collapse; 68 | border-spacing: 0; 69 | } 70 | /* 去除默认边框 */ 71 | fieldset, 72 | img { 73 | border: 0; 74 | } 75 | /* 去掉 firefox 下此元素的边框 */ 76 | abbr, 77 | acronym { 78 | border: 0; 79 | font-variant: normal; 80 | } 81 | /* 一致的 del 样式 */ 82 | del { 83 | text-decoration: line-through; 84 | } 85 | address, 86 | caption, 87 | cite, 88 | code, 89 | dfn, 90 | em, 91 | th, 92 | var { 93 | font-style: normal; 94 | font-weight: 500; 95 | } 96 | /* 去掉列表前的标识, li 会继承 */ 97 | ol, 98 | ul { 99 | list-style: none; 100 | } 101 | /* 对齐是排版最重要的因素, 别让什么都居中 */ 102 | caption, 103 | th { 104 | text-align: left; 105 | } 106 | /* 来自 yahoo, 让标题都自定义, 适应多个系统应用 */ 107 | h1, 108 | h2, 109 | h3, 110 | h4, 111 | h5, 112 | h6 { 113 | font-size: 100%; 114 | font-weight: 500; 115 | } 116 | q:before, 117 | q:after { 118 | content: ''; 119 | } 120 | /* 统一上标和下标 */ 121 | sub, 122 | sup { 123 | font-size: 75%; 124 | line-height: 0; 125 | position: relative; 126 | vertical-align: baseline; 127 | } 128 | sup { 129 | top: -0.5em; 130 | } 131 | sub { 132 | bottom: -0.25em; 133 | } 134 | /* 正常链接 未访问 */ 135 | /* 鼠标悬停 */ 136 | a:hover { 137 | text-decoration: underline; 138 | } 139 | /* 默认不显示下划线,保持页面简洁 */ 140 | ins, 141 | a { 142 | text-decoration: none; 143 | } 144 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/_tooltip.scss: -------------------------------------------------------------------------------- 1 | // Base class 2 | .tooltip { 3 | position: absolute; 4 | z-index: $zindex-tooltip; 5 | display: block; 6 | // Our parent element can be arbitrary since tooltips are by default inserted as a sibling of their target element. 7 | // So reset our font and text properties to avoid inheriting weird values. 8 | @include reset-text(); 9 | font-size: $font-size-sm; 10 | opacity: 0; 11 | 12 | &.in { opacity: $tooltip-opacity; } 13 | 14 | &.tooltip-top, 15 | &.bs-tether-element-attached-bottom { 16 | padding: $tooltip-arrow-width 0; 17 | margin-top: -3px; 18 | 19 | .tooltip-arrow { 20 | bottom: 0; 21 | left: 50%; 22 | margin-left: -$tooltip-arrow-width; 23 | border-width: $tooltip-arrow-width $tooltip-arrow-width 0; 24 | border-top-color: $tooltip-arrow-color; 25 | } 26 | } 27 | &.tooltip-right, 28 | &.bs-tether-element-attached-left { 29 | padding: 0 $tooltip-arrow-width; 30 | margin-left: 3px; 31 | 32 | .tooltip-arrow { 33 | top: 50%; 34 | left: 0; 35 | margin-top: -$tooltip-arrow-width; 36 | border-width: $tooltip-arrow-width $tooltip-arrow-width $tooltip-arrow-width 0; 37 | border-right-color: $tooltip-arrow-color; 38 | } 39 | } 40 | &.tooltip-bottom, 41 | &.bs-tether-element-attached-top { 42 | padding: $tooltip-arrow-width 0; 43 | margin-top: 3px; 44 | 45 | .tooltip-arrow { 46 | top: 0; 47 | left: 50%; 48 | margin-left: -$tooltip-arrow-width; 49 | border-width: 0 $tooltip-arrow-width $tooltip-arrow-width; 50 | border-bottom-color: $tooltip-arrow-color; 51 | } 52 | } 53 | &.tooltip-left, 54 | &.bs-tether-element-attached-right { 55 | padding: 0 $tooltip-arrow-width; 56 | margin-left: -3px; 57 | 58 | .tooltip-arrow { 59 | top: 50%; 60 | right: 0; 61 | margin-top: -$tooltip-arrow-width; 62 | border-width: $tooltip-arrow-width 0 $tooltip-arrow-width $tooltip-arrow-width; 63 | border-left-color: $tooltip-arrow-color; 64 | } 65 | } 66 | } 67 | 68 | // Wrapper for the tooltip content 69 | .tooltip-inner { 70 | max-width: $tooltip-max-width; 71 | padding: 3px 8px; 72 | color: $tooltip-color; 73 | text-align: center; 74 | background-color: $tooltip-bg; 75 | @include border-radius($border-radius); 76 | } 77 | 78 | // Arrows 79 | .tooltip-arrow { 80 | position: absolute; 81 | width: 0; 82 | height: 0; 83 | border-color: transparent; 84 | border-style: solid; 85 | } 86 | -------------------------------------------------------------------------------- /src/wx-api.js: -------------------------------------------------------------------------------- 1 | const wx = require('wx'); 2 | const jsSHA = require('jssha'); 3 | 4 | const APP_ID = 'wx09f7d37254dfa4d6'; 5 | 6 | const createNonceStr = function () { 7 | return Math.random().toString(36).substr(2, 15); 8 | }; 9 | 10 | const createTimestamp = function () { 11 | return parseInt(new Date().getTime() / 1000) + ''; 12 | }; 13 | 14 | const raw = function (args) { 15 | let keys = Object.keys(args); 16 | keys = keys.sort() 17 | let newArgs = {}; 18 | keys.forEach(function (key) { 19 | newArgs[key.toLowerCase()] = args[key]; 20 | }); 21 | 22 | let string = ''; 23 | for (let k in newArgs) { 24 | string += '&' + k + '=' + newArgs[k]; 25 | } 26 | string = string.substr(1); 27 | return string; 28 | }; 29 | 30 | let timestamp = createTimestamp(); 31 | let nonceStr = createNonceStr(); 32 | 33 | /** 34 | * @synopsis 签名算法 35 | * 36 | * @param jsapi_ticket 用于签名的 jsapi_ticket 37 | * @param url 用于签名的 url ,注意必须动态获取,不能 hardcode 38 | * 39 | * @returns 40 | */ 41 | const sign = function (jsapi_ticket, url) { 42 | let ret = { 43 | jsapi_ticket: jsapi_ticket, 44 | nonceStr: nonceStr, 45 | timestamp: timestamp, 46 | url: url 47 | }; 48 | 49 | let shaObj = new jsSHA(raw(ret), 'TEXT'); 50 | 51 | ret.signature = shaObj.getHash('SHA-1', 'HEX'); 52 | 53 | return ret; 54 | }; 55 | 56 | function wxConfig(ticket) { 57 | wx.config({ 58 | appId: APP_ID, // 必填,公众号的唯一标识 59 | timestamp: timestamp, // 必填,生成签名的时间戳 60 | nonceStr: nonceStr, // 必填,生成签名的随机串 61 | signature: sign(ticket, location.href.split('#')[0]),// 必填,签名,见附录1 62 | jsApiList: [ 63 | 'chooseImage', 64 | 'uploadImage', 65 | 'downloadImage', 66 | 'openLocation', 67 | 'getLocation', 68 | 'chooseWXPay', 69 | 'addCard', 70 | 'chooseCard', 71 | 'openCard', 72 | 'closeWindow' 73 | ] 74 | }); 75 | } 76 | 77 | export default { 78 | init(Vue) { 79 | Vue.http.get('/api/signature', {url: location.href.split('#')[0]}).then(res => { 80 | let data = res.data; 81 | 82 | wx.config({ 83 | appId: data.appId, // 必填,公众号的唯一标识 84 | timestamp: data.timestamp, // 必填,生成签名的时间戳 85 | nonceStr: data.nonceStr, // 必填,生成签名的随机串 86 | signature: data.signature,// 必填,签名,见附录1 87 | jsApiList: [ 88 | 'chooseImage', 89 | 'uploadImage', 90 | 'downloadImage', 91 | 'openLocation', 92 | 'getLocation', 93 | 'chooseWXPay', 94 | 'addCard', 95 | 'chooseCard', 96 | 'openCard', 97 | 'closeWindow' 98 | ] 99 | }); 100 | }); 101 | } 102 | } 103 | 104 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_buttons.scss: -------------------------------------------------------------------------------- 1 | // Button variants 2 | // 3 | // Easily pump out default styles, as well as :hover, :focus, :active, 4 | // and disabled options for all buttons 5 | 6 | @mixin button-variant($color, $background, $border) { 7 | $active-background: darken($background, 10%); 8 | $active-border: darken($border, 12%); 9 | 10 | color: $color; 11 | background-color: $background; 12 | border-color: $border; 13 | @include box-shadow(inset 0 1px 0 rgba(255,255,255,.15), 0 1px 1px rgba(0,0,0,.075)); 14 | 15 | @include hover { 16 | color: $color; 17 | background-color: $active-background; 18 | border-color: $active-border; 19 | } 20 | 21 | &:focus, 22 | &.focus { 23 | color: $color; 24 | background-color: $active-background; 25 | border-color: $active-border; 26 | } 27 | 28 | &:active, 29 | &.active, 30 | .open > &.dropdown-toggle { 31 | color: $color; 32 | background-color: $active-background; 33 | border-color: $active-border; 34 | // Remove the gradient for the pressed/active state 35 | background-image: none; 36 | @include box-shadow(inset 0 3px 5px rgba(0,0,0,.125)); 37 | 38 | &:hover, 39 | &:focus, 40 | &.focus { 41 | color: $color; 42 | background-color: darken($background, 17%); 43 | border-color: darken($border, 25%); 44 | } 45 | } 46 | 47 | &.disabled, 48 | &:disabled { 49 | &:focus, 50 | &.focus { 51 | background-color: $background; 52 | border-color: $border; 53 | } 54 | @include hover { 55 | background-color: $background; 56 | border-color: $border; 57 | } 58 | } 59 | } 60 | 61 | @mixin button-outline-variant($color) { 62 | color: $color; 63 | background-image: none; 64 | background-color: transparent; 65 | border-color: $color; 66 | 67 | &:focus, 68 | &.focus, 69 | &:active, 70 | &.active, 71 | .open > &.dropdown-toggle { 72 | color: #fff; 73 | background-color: $color; 74 | border-color: $color; 75 | } 76 | @include hover { 77 | color: #fff; 78 | background-color: $color; 79 | border-color: $color; 80 | } 81 | 82 | &.disabled, 83 | &:disabled { 84 | &:focus, 85 | &.focus { 86 | border-color: lighten($color, 20%); 87 | } 88 | @include hover { 89 | border-color: lighten($color, 20%); 90 | } 91 | } 92 | } 93 | 94 | // Button sizes 95 | @mixin button-size($padding-y, $padding-x, $font-size, $line-height, $border-radius) { 96 | padding: $padding-y $padding-x; 97 | font-size: $font-size; 98 | line-height: $line-height; 99 | @include border-radius($border-radius); 100 | } 101 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_gradients.scss: -------------------------------------------------------------------------------- 1 | // Gradients 2 | 3 | // Horizontal gradient, from left to right 4 | // 5 | // Creates two color stops, start and end, by specifying a color and position for each color stop. 6 | // Color stops are not available in IE9. 7 | @mixin gradient-horizontal($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) { 8 | background-image: linear-gradient(to right, $start-color $start-percent, $end-color $end-percent); 9 | background-repeat: repeat-x; 10 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=1); // IE9 11 | } 12 | 13 | // Vertical gradient, from top to bottom 14 | // 15 | // Creates two color stops, start and end, by specifying a color and position for each color stop. 16 | // Color stops are not available in IE9. 17 | @mixin gradient-vertical($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) { 18 | background-image: linear-gradient(to bottom, $start-color $start-percent, $end-color $end-percent); 19 | background-repeat: repeat-x; 20 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=0); // IE9 21 | } 22 | 23 | @mixin gradient-directional($start-color: #555, $end-color: #333, $deg: 45deg) { 24 | background-repeat: repeat-x; 25 | background-image: linear-gradient($deg, $start-color, $end-color); 26 | } 27 | @mixin gradient-horizontal-three-colors($start-color: #00b3ee, $mid-color: #7a43b6, $color-stop: 50%, $end-color: #c3325f) { 28 | background-image: linear-gradient(to right, $start-color, $mid-color $color-stop, $end-color); 29 | background-repeat: no-repeat; 30 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=1); // IE9 gets no color-stop at all for proper fallback 31 | } 32 | @mixin gradient-vertical-three-colors($start-color: #00b3ee, $mid-color: #7a43b6, $color-stop: 50%, $end-color: #c3325f) { 33 | background-image: linear-gradient($start-color, $mid-color $color-stop, $end-color); 34 | background-repeat: no-repeat; 35 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=0); // IE9 gets no color-stop at all for proper fallback 36 | } 37 | @mixin gradient-radial($inner-color: #555, $outer-color: #333) { 38 | background-image: radial-gradient(circle, $inner-color, $outer-color); 39 | background-repeat: no-repeat; 40 | } 41 | @mixin gradient-striped($color: rgba(255,255,255,.15), $angle: 45deg) { 42 | background-image: linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent); 43 | } -------------------------------------------------------------------------------- /npm-debug.log: -------------------------------------------------------------------------------- 1 | 0 info it worked if it ends with ok 2 | 1 verbose cli [ '/Users/lzz/.nvm/versions/node/v5.0.0/bin/node', 3 | 1 verbose cli '/Users/lzz/.nvm/versions/node/v5.0.0/bin/npm', 4 | 1 verbose cli 'run', 5 | 1 verbose cli 'start' ] 6 | 2 info using npm@3.3.6 7 | 3 info using node@v5.0.0 8 | 4 verbose run-script [ 'prestart', 'start', 'poststart' ] 9 | 5 info lifecycle wx-vue@0.1.0~prestart: wx-vue@0.1.0 10 | 6 silly lifecycle wx-vue@0.1.0~prestart: no script for prestart, continuing 11 | 7 info lifecycle wx-vue@0.1.0~start: wx-vue@0.1.0 12 | 8 verbose lifecycle wx-vue@0.1.0~start: unsafe-perm in lifecycle true 13 | 9 verbose lifecycle wx-vue@0.1.0~start: PATH: /Users/lzz/.nvm/versions/node/v5.0.0/lib/node_modules/npm/bin/node-gyp-bin:/Users/lzz/github/wx-vue/node_modules/.bin:/Users/lzz/.nvm/versions/node/v5.0.0/bin:/Users/lzz/tools/qiniu-devtools:/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin:/usr/local/Cellar/maven/3.2.3/bin:/opt/subversion/bin:/usr/local/Cellar/mongodb/2.6.5/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/git/bin 14 | 10 verbose lifecycle wx-vue@0.1.0~start: CWD: /Users/lzz/github/wx-vue 15 | 11 silly lifecycle wx-vue@0.1.0~start: Args: [ '-c', 'serve2 -M mock' ] 16 | 12 silly lifecycle wx-vue@0.1.0~start: Returned: code: 1 signal: null 17 | 13 info lifecycle wx-vue@0.1.0~start: Failed to exec start script 18 | 14 verbose stack Error: wx-vue@0.1.0 start: `serve2 -M mock` 19 | 14 verbose stack Exit status 1 20 | 14 verbose stack at EventEmitter. (/Users/lzz/.nvm/versions/node/v5.0.0/lib/node_modules/npm/lib/utils/lifecycle.js:233:16) 21 | 14 verbose stack at emitTwo (events.js:87:13) 22 | 14 verbose stack at EventEmitter.emit (events.js:172:7) 23 | 14 verbose stack at ChildProcess. (/Users/lzz/.nvm/versions/node/v5.0.0/lib/node_modules/npm/lib/utils/spawn.js:24:14) 24 | 14 verbose stack at emitTwo (events.js:87:13) 25 | 14 verbose stack at ChildProcess.emit (events.js:172:7) 26 | 14 verbose stack at maybeClose (internal/child_process.js:818:16) 27 | 14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5) 28 | 15 verbose pkgid wx-vue@0.1.0 29 | 16 verbose cwd /Users/lzz/github/wx-vue 30 | 17 error Darwin 15.0.0 31 | 18 error argv "/Users/lzz/.nvm/versions/node/v5.0.0/bin/node" "/Users/lzz/.nvm/versions/node/v5.0.0/bin/npm" "run" "start" 32 | 19 error node v5.0.0 33 | 20 error npm v3.3.6 34 | 21 error code ELIFECYCLE 35 | 22 error wx-vue@0.1.0 start: `serve2 -M mock` 36 | 22 error Exit status 1 37 | 23 error Failed at the wx-vue@0.1.0 start script 'serve2 -M mock'. 38 | 23 error This is most likely a problem with the wx-vue package, 39 | 23 error not with npm itself. 40 | 23 error Tell the author that this fails on your system: 41 | 23 error serve2 -M mock 42 | 23 error You can get their info via: 43 | 23 error npm owner ls wx-vue 44 | 23 error There is likely additional logging output above. 45 | 24 verbose exit [ 1, true ] 46 | -------------------------------------------------------------------------------- /src/assets/scss/bootstrap/mixins/_forms.scss: -------------------------------------------------------------------------------- 1 | // Form validation states 2 | // 3 | // Used in _forms.scss to generate the form validation CSS for warnings, errors, 4 | // and successes. 5 | 6 | @mixin form-control-validation($color) { 7 | // Color the label and help text 8 | .text-help, 9 | .form-control-label, 10 | .radio, 11 | .checkbox, 12 | .radio-inline, 13 | .checkbox-inline, 14 | &.radio label, 15 | &.checkbox label, 16 | &.radio-inline label, 17 | &.checkbox-inline label { 18 | color: $color; 19 | } 20 | // Set the border and box shadow on specific inputs to match 21 | .form-control { 22 | border-color: $color; 23 | // @include box-shadow(inset 0 1px 1px rgba(0,0,0,.075)); // Redeclare so transitions work 24 | 25 | &:focus { 26 | // border-color: darken($border-color, 10%); 27 | // $shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 6px lighten($border-color, 20%); 28 | // @include box-shadow($shadow); 29 | } 30 | } 31 | 32 | // Set validation states also for addons 33 | .input-group-addon { 34 | color: $color; 35 | border-color: $color; 36 | background-color: lighten($color, 40%); 37 | } 38 | // Optional feedback icon 39 | .form-control-feedback { 40 | color: $color; 41 | } 42 | } 43 | 44 | // Form control focus state 45 | // 46 | // Generate a customized focus state and for any input with the specified color, 47 | // which defaults to the `@input-border-focus` variable. 48 | // 49 | // We highly encourage you to not customize the default value, but instead use 50 | // this to tweak colors on an as-needed basis. This aesthetic change is based on 51 | // WebKit's default styles, but applicable to a wider range of browsers. Its 52 | // usability and accessibility should be taken into account with any change. 53 | // 54 | // Example usage: change the default blue border and shadow to white for better 55 | // contrast against a dark gray background. 56 | @mixin form-control-focus() { 57 | &:focus { 58 | border-color: $input-border-focus; 59 | outline: none; 60 | $shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px $input-box-shadow-focus; 61 | @include box-shadow($shadow); 62 | } 63 | } 64 | 65 | // Form control sizing 66 | // 67 | // Relative text size, padding, and border-radii changes for form controls. For 68 | // horizontal sizing, wrap controls in the predefined grid classes. `