Authored by 陈轩

Merge remote-tracking branch 'origin/develop' into develop

... ... @@ -30,10 +30,12 @@ iconfont 新建项目,使用 class 控制图标样式,不要用 unicode<br>
<button class="button">空心</button>
<button class="button button-solid">实心</button>
<hr>
<button class="button button-round">圆角</button>
<button class="button button-round button-solid">圆角,实心</button>
<hr>
<button class="button button-large"></button>
<hr>
<button class="button button-small"></button>
<hr>
<button class="button button-large button-round button-solid">大,圆角,实心</button>
... ... @@ -103,8 +105,12 @@ iconfont 新建项目,使用 class 控制图标样式,不要用 unicode<br>
每个按钮支持自定义事件
<h2>Vue 示例</h2>
<h2>Vue 示例(大展示,使用新路由)</h2>
<div id="app">
<app></app>
</div>
<h2>Handlebars 示例</h2>
<div id="hbs-placeholder">
</div>
... ...
... ... @@ -12,7 +12,7 @@
<link rel="dns-prefetch" href="//cdn.yoho.cn">
<link rel="dns-prefetch" href="//static.yohobuy.com">
<script type="text/javascript">
(function(d,c){var e=d.documentElement,a="orientationchange" in window?"orientationchange":"resize",b=function(){var f=e.clientWidth;if(!f){return}if(f>=640){e.style.fontSize="40px"}else{e.style.fontSize=40*(f/640)+"px"}};if(!d.addEventListener){return}b();c.addEventListener(a,b,false);d.addEventListener("DOMContentLoaded",b,false)})(document,window);
(function(d,c){var e=d.documentElement,a="orientationchange" in window?"orientationchange":"resize",b=function(){var f=e.clientWidth;if(!f){return}if(f>=750){e.style.fontSize="40px"}else{e.style.fontSize=40*(f/750)+"px"}};if(!d.addEventListener){return}b();c.addEventListener(a,b,false);d.addEventListener("DOMContentLoaded",b,false)})(document,window);
</script>
{{#if devEnv}}
<link rel="stylesheet" href="//localhost:5004/css/index.css">
... ...
<span>Hello {{text}}</span>
... ...
var tpl = require('./hello.hbs');
var Vue = require('yoho-vue');
var app = require('example/home.vue');
var tpl = require('example/hello.hbs');
var vm = new Vue({
el: '#app',
... ... @@ -25,6 +24,7 @@ var cookie = require('yoho-cookie');
console.log(cookie.all());
// ES6 test
var test = {
data() {
return {
... ...
.button {
display: inline-block;
min-width: 100px;
height: 40px;
min-width: 310px;
min-height: 100px;
border: 1px solid $black;
background: $white;
color: $black;
font-size: 20px;
padding: 0 10px;
-webkit-appearance: button;
&.button-solid {
background: $black;
... ... @@ -17,11 +19,13 @@
}
&.button-small {
min-width: 50px;
min-width: 180px;
min-height: 70px;
}
&.button-large {
min-width: 300px;
min-width: 700px;
min-height: 100px;
}
&:disabled {
... ...
... ... @@ -41,6 +41,6 @@ a {
position: relative;
margin-right: auto;
margin-left: auto;
max-width: 640px;
max-width: 750px;
width: 100%;
}
... ...
... ... @@ -55,11 +55,10 @@ module.exports = {
loader: 'style!css?-url'
}, {
test: /\.hbs$/, loader: 'handlebars-loader'
}
]
}]
},
resolve: {
modulesDirectories: ['node_modules', './vue']
modulesDirectories: ['node_modules', './vue', './hbs']
},
plugins: [
new webpack.optimize.OccurenceOrderPlugin(),
... ...