Skip to content

Commit

Permalink
doc: update doc
Browse files Browse the repository at this point in the history
  • Loading branch information
tangjinzhou committed Aug 12, 2019
1 parent ad81186 commit d232bf6
Show file tree
Hide file tree
Showing 6 changed files with 176 additions and 145 deletions.
8 changes: 2 additions & 6 deletions antd-tools/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,14 +145,10 @@ function tag() {
execSync(`git config --global user.name ${process.env.GITHUB_USER_NAME}`);
execSync(`git tag ${version}`);
execSync(
`git push https://${
process.env.GITHUB_TOKEN
}@github.com/vueComponent/ant-design-vue.git ${version}:${version}`,
`git push https://${process.env.GITHUB_TOKEN}@github.com/vueComponent/ant-design-vue.git ${version}:${version}`,
);
execSync(
`git push https://${
process.env.GITHUB_TOKEN
}@github.com/vueComponent/ant-design-vue.git master:master`,
`git push https://${process.env.GITHUB_TOKEN}@github.com/vueComponent/ant-design-vue.git master:master`,
);
console.log('tagged');
}
Expand Down
12 changes: 3 additions & 9 deletions components/vc-slick/src/slider.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,7 @@ export default {
if (settings.centerMode) {
if (settings.slidesToScroll > 1 && process.env.NODE_ENV !== 'production') {
console.warn(
`slidesToScroll should be equal to 1 in centerMode, you are using ${
settings.slidesToScroll
}`,
`slidesToScroll should be equal to 1 in centerMode, you are using ${settings.slidesToScroll}`,
);
}
settings.slidesToScroll = 1;
Expand All @@ -121,16 +119,12 @@ export default {
if (settings.fade) {
if (settings.slidesToShow > 1 && process.env.NODE_ENV !== 'production') {
console.warn(
`slidesToShow should be equal to 1 when fade is true, you're using ${
settings.slidesToShow
}`,
`slidesToShow should be equal to 1 when fade is true, you're using ${settings.slidesToShow}`,
);
}
if (settings.slidesToScroll > 1 && process.env.NODE_ENV !== 'production') {
console.warn(
`slidesToScroll should be equal to 1 when fade is true, you're using ${
settings.slidesToScroll
}`,
`slidesToScroll should be equal to 1 when fade is true, you're using ${settings.slidesToScroll}`,
);
}
settings.slidesToShow = 1;
Expand Down
4 changes: 1 addition & 3 deletions components/vc-tree-select/src/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -376,9 +376,7 @@ function processEntity(entity, wrapper) {
if (currentEntity) {
warning(
false,
`Conflict! value of node '${entity.key}' (${value}) has already used by node '${
currentEntity.key
}'.`,
`Conflict! value of node '${entity.key}' (${value}) has already used by node '${currentEntity.key}'.`,
);
}
wrapper.valueEntities[value] = entity;
Expand Down
58 changes: 31 additions & 27 deletions site/components/CarbonAds.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
<script>
import axios from 'axios';
const carbonUrls = {
'vuecomponent.github.io': '//cdn.carbonads.com/carbon.js?serve=CK7DL2JW&placement=vuecomponentgithubio',
'tangjinzhou.gitee.io':'//cdn.carbonads.com/carbon.js?serve=CK7DL2JN&placement=tangjinzhougiteeio',
'ant-design-vue.gitee.io':'//cdn.carbonads.com/carbon.js?serve=CK7DL2JN&placement=antdesignvuegiteeio',
'vuecomponent.github.io':
'//cdn.carbonads.com/carbon.js?serve=CK7DL2JW&placement=vuecomponentgithubio',
'tangjinzhou.gitee.io':
'//cdn.carbonads.com/carbon.js?serve=CK7DL2JN&placement=tangjinzhougiteeio',
'ant-design-vue.gitee.io':
'//cdn.carbonads.com/carbon.js?serve=CK7DL2JN&placement=antdesignvuegiteeio',
'vue.ant.design': '//cdn.carbonads.com/carbon.js?serve=CK7DL2JW&placement=vueantdesign',
};
const carbonUrl = carbonUrls[location.host] || '//cdn.carbonads.com/carbon.js?serve=CK7DL2JW&placement=vueantdesign';
const carbonUrl =
carbonUrls[location.host] ||
'//cdn.carbonads.com/carbon.js?serve=CK7DL2JW&placement=vueantdesign';
export default {
props: {
isMobile: Boolean,
Expand All @@ -17,18 +22,17 @@ export default {
// if(isGitee) {
// adId = '#cf';
// }
if(e.path !== t.path && this.$el.querySelector(adId)){
this.$el.innerHTML = "";
if (e.path !== t.path && this.$el.querySelector(adId)) {
this.$el.innerHTML = '';
this.load();
}
this.adInterval && clearInterval(this.adInterval);
this.adInterval = setInterval(()=>{
if(!this.$el.querySelector(adId)){
this.$el.innerHTML = "";
this.adInterval = setInterval(() => {
if (!this.$el.querySelector(adId)) {
this.$el.innerHTML = '';
this.load();
}
}, 20000);
},
},
mounted() {
Expand All @@ -41,35 +45,35 @@ export default {
// .then(function (response) {
// document.getElementById("codefund-ads").innerHTML = response.data;
// });
// } else
if(carbonUrl) {
const e = document.createElement("script");
e.id = "_carbonads_js";
// } else
if (carbonUrl) {
const e = document.createElement('script');
e.id = '_carbonads_js';
e.src = carbonUrl;
this.$el.appendChild(e);
}
},
},
render () {
return (
<div id="carbon-ads" class={this.isMobile ? 'carbon-mobile':''}/>
);
render() {
return <div id="carbon-ads" class={this.isMobile ? 'carbon-mobile' : ''} />;
},
};
</script>
<style lang="less">
#carbon-ads {
width: 266px;
position: fixed;
left: 0;
bottom: 0px;
#carbon-ads {
width: 280px;
float: right;
position: relative;
right: 0;
bottom: 0;
padding: 0;
overflow: hidden;
z-index: 9;
background-color: #fff;
border-radius: 3px;
font-size: 13px;
background: #f5f5f5;
font-family: "Source Sans Pro", "Helvetica Neue", Arial, sans-serif;
font-family: 'Source Sans Pro', 'Helvetica Neue', Arial, sans-serif;
}
#carbonads {
overflow: hidden;
Expand Down Expand Up @@ -100,9 +104,9 @@ export default {
overflow: hidden;
}
#carbon-ads .carbon-poweredby {
color: #aaa ;
font-weight: normal ;
line-height: 1.2 ;
color: #aaa;
font-weight: normal;
line-height: 1.2;
margin-top: 6px;
}
#carbon-ads.carbon-mobile {
Expand Down
12 changes: 5 additions & 7 deletions site/components/geektime_ads.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
height="100"
alt="浏览器工作原理与实践"
src="http://pvrd7go2h.bkt.clouddn.com/geektime-browser.jpeg"
>
/>
</a>
</div>
</template>
Expand Down Expand Up @@ -40,12 +40,10 @@ export default {

<style lang="less" scoped>
#geektime-ads {
max-width: 280px;
height: 100px;
float: right;
position: relative;
right: 0;
bottom: 0;
width: 266px;
position: fixed;
left: 0;
bottom: 0px;
padding: 0;
overflow: hidden;
z-index: 9;
Expand Down
Loading

0 comments on commit d232bf6

Please sign in to comment.