Skip to content

Commit

Permalink
feat: release v3.0.12
Browse files Browse the repository at this point in the history
  • Loading branch information
xupaopaopaopao committed Jul 14, 2017
1 parent 9543271 commit 8a0ed78
Show file tree
Hide file tree
Showing 103 changed files with 11,465 additions and 1,702 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ npm-debug.log
/demo
style/page
style/export
/gulp
/gulpfile.js

# component构建目录
/component
Expand Down
7 changes: 7 additions & 0 deletions How-To-Release.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@

与此同时 `Yo3` 有一个对应的 Demo 工程,它的分支命名规则与 `Yo3` 保持一致。

需要 check 版本号的地方:
- bower.json 中的 version
- package.json 中的 version
- style/lib/core/variables.scss 中的 version
- ydoc.json 中的 version
- changelog 是否有新版本的变更

发布流程如下:
- diff dev分支和master分支的改动。
- 在当前dev分支上调用 `release`,发布一个`rc tag`,版本号规则为 `3.x.y-rc.z`。然后手动到 `qnpm` sync这个版本。
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "yo",
"version": "3.0.11",
"version": "3.0.12",
"homepage": "https://github.com/doyoe/Yo",
"authors": [
"Joy Du"
Expand Down
3 changes: 0 additions & 3 deletions builder/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,6 @@ function replaceStyleRefRootPath(code, path, styleFolderPath, componentName) {
var yoRefs = (scssImports ? scssImports.filter(function (imp) {
return rroot.test(imp);
}) : []).concat(componentRef);
var otherRefs = scssImports ? scssImports.filter(function (imp) {
return !rroot.test(imp);
}) : [];
var renderedScssImports = yoRefs.map(function (imp) {
return {
src: imp,
Expand Down
9 changes: 9 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
## v3.0.12 (2017-07-14)

### New Features
* `Scroller` 新增 `refreshLazyImage` 方法,在页面内容变化时,手动刷新 LazyImage。

### Bug Fixes
* 修复 当元素宽度出现小数时,使用 `border` 方法边框可能显示不全的问题。
* 修复 `LazyImage` 在频繁更新图片地址时,有可能加载顺序出现混乱的问题。

## v3.0.11 (2017-06-24)

### New Features
Expand Down
32 changes: 17 additions & 15 deletions component_dev/actionsheet/demo/demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,23 @@ class ActionSheetDemo extends React.Component {
render() {
return (
<div className="test-wrap">
<button onClick={() => {
ActionSheet({
menu: [{
text: '存储图像',
onTap() {
Toast.show('存储图像');
}
}, {
text: '拷贝',
onTap() {
Toast.show('拷贝');
}
}], title: '保存图片?', cancelText: 'cancel'
});
}}>Open ActionSheet</button>
<button
onClick={() => {
ActionSheet({
menu: [{
text: '存储图像',
onTap() {
Toast.show('存储图像');
}
}, {
text: '拷贝',
onTap() {
Toast.show('拷贝');
}
}], title: '保存图片?', cancelText: 'cancel'
});
}}
>Open ActionSheet</button>
</div >
);
}
Expand Down
2 changes: 1 addition & 1 deletion component_dev/calendar/__tests__/calendar.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ test('the allowSelectionBeforeToday is true, the range of selection is only depe

class ChangeDuration extends Component {
state = {
duration: ['2017-2-10', '2017-3-10'],
duration: ['2017-2-10', '2017-3-10']
};

render() {
Expand Down
2 changes: 1 addition & 1 deletion component_dev/calendar/demo/demo.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class CalendarDemo extends Component {
componentDidMount() {
setTimeout(() => {
this.setState({
duration: 100,
duration: 100
});
}, 5000);
}
Expand Down
2 changes: 1 addition & 1 deletion component_dev/calendar/src/CalendarCore.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ const getDateInfoArr = (date = new Date()) => [
date.getFullYear(),
date.getMonth() + 1,
date.getDate(),
date.getDay(),
date.getDay()
];

/**
Expand Down
3 changes: 0 additions & 3 deletions component_dev/carousel/__tests__/carousel.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,21 +59,18 @@ describe("aniObj's functino has been called", () => {
});

test('invoke touchstart', () => {
const dom = wrapper.find('.cont');
const mockTouch = createTouchE('touchstart', 100, 100, 100, 100, 100, 100);
wrapper.find('.cont').simulate('touchstart', mockTouch);
expect(spyObj.touchstart).toHaveBeenCalled();
});

test('invoke touchmove', () => {
const dom = wrapper.find('.cont');
const mockTouch = createTouchE('touchmove', 100, 100, 100, 100, 100, 100);
wrapper.find('.cont').simulate('touchmove', mockTouch);
expect(spyObj.touchmove).toHaveBeenCalled();
});

test('invoke touchend', () => {
const dom = wrapper.find('.cont');
const mockTouch = createTouchE('touchend', 200, 200, 200, 200, 200, 200);
wrapper.find('.cont').simulate('touchend', mockTouch);
expect(spyObj.touchend).toHaveBeenCalled();
Expand Down
12 changes: 4 additions & 8 deletions component_dev/carousel/__tests__/testData.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ export default [{
onTap: () => {
console.log('tap listener');
}
}
, {
}, {
img: 'http://gw.alicdn.com/tps/TB1gQjnKVXXXXXPXXXXXXXXXXXX-1125-352.jpg_q50.jpg',
onTap: () => {
console.log('tap listener');
Expand All @@ -19,14 +18,12 @@ export default [{
onTap: () => {
console.log('tap listener');
}
}
,{
}, {
img: 'http://gma.alicdn.com/simba/img/TB14ab1KpXXXXclXFXXSutbFXXX.jpg_q50.jpg',
onTap: () => {
console.log('tap listener');
}
}
, {
}, {
img: 'http://gw.alicdn.com/tps/TB1gQjnKVXXXXXPXXXXXXXXXXXX-1125-352.jpg_q50.jpg',
onTap: () => {
console.log('tap listener');
Expand All @@ -36,5 +33,4 @@ export default [{
onTap: () => {
console.log('tap listener');
}
},
];
}];
104 changes: 52 additions & 52 deletions component_dev/carousel/demo/demo3.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,58 +160,58 @@ class Container extends React.Component {
}
</Carousel>
);
let infinateCarousel = (
<Carousel
key={5}
beforeChange={(page)=>{this.beforeChange(page,'infinatePage')}}
afterChange={(page)=>{this.updateChange(page,'infinatePage')}}
dots={true}
aniObj={AniInfinate}
autoplay={false}
loop={false}
defaultPage={this.state.infinatePage}
>
{
dataList.map((item, index)=>{
return (
<CarouselItem
index = {index + 1}
key = {index + 1}
currentPage = {this.state.infinatePage}
{...item}
lazyload={false}
extraClass ={'scale'}
pagesNum = {dataList.length}
></CarouselItem>
)
})
}
</Carousel>
);
const verticalCarousel = (
<Carousel
key={6}
beforeChange={(page)=>{this.beforeChange(page,'pageNow')}}
afterChange={(page)=>{this.updateChange(page,'pageNow')}}
dots={true}
autoplay={true}
isVertical={true}
>
{
dataList.map((item, index)=>{
return (
<CarouselItem
index = {index + 1}
key = {index + 1}
currentPage={this.state.pageNow}
{...item}
pagesNum = {dataList.length}
lazyload={false}
></CarouselItem>);
})
}
</Carousel>
);
// let infinateCarousel = (
// <Carousel
// key={5}
// beforeChange={(page)=>{this.beforeChange(page,'infinatePage')}}
// afterChange={(page)=>{this.updateChange(page,'infinatePage')}}
// dots={true}
// aniObj={AniInfinate}
// autoplay={false}
// loop={false}
// defaultPage={this.state.infinatePage}
// >
// {
// dataList.map((item, index)=>{
// return (
// <CarouselItem
// index = {index + 1}
// key = {index + 1}
// currentPage = {this.state.infinatePage}
// {...item}
// lazyload={false}
// extraClass ={'scale'}
// pagesNum = {dataList.length}
// ></CarouselItem>
// )
// })
// }
// </Carousel>
// );
// const verticalCarousel = (
// <Carousel
// key={6}
// beforeChange={(page)=>{this.beforeChange(page,'pageNow')}}
// afterChange={(page)=>{this.updateChange(page,'pageNow')}}
// dots={true}
// autoplay={true}
// isVertical={true}
// >
// {
// dataList.map((item, index)=>{
// return (
// <CarouselItem
// index = {index + 1}
// key = {index + 1}
// currentPage={this.state.pageNow}
// {...item}
// pagesNum = {dataList.length}
// lazyload={false}
// ></CarouselItem>);
// })
// }
// </Carousel>
// );

return (
<div>
Expand Down
12 changes: 4 additions & 8 deletions component_dev/carousel/demo/testData.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ export default [{
onTap: () => {
console.log('tap listener');
}
}
, {
}, {
img: 'http://gw.alicdn.com/tps/TB1gQjnKVXXXXXPXXXXXXXXXXXX-1125-352.jpg_q50.jpg',
onTap: () => {
console.log('tap listener');
Expand All @@ -19,14 +18,12 @@ export default [{
onTap: () => {
console.log('tap listener');
}
}
,{
}, {
img: 'http://gma.alicdn.com/simba/img/TB14ab1KpXXXXclXFXXSutbFXXX.jpg_q50.jpg',
onTap: () => {
console.log('tap listener');
}
}
, {
}, {
img: 'http://gw.alicdn.com/tps/TB1gQjnKVXXXXXPXXXXXXXXXXXX-1125-352.jpg_q50.jpg',
onTap: () => {
console.log('tap listener');
Expand All @@ -36,5 +33,4 @@ export default [{
onTap: () => {
console.log('tap listener');
}
},
];
}];
Loading

0 comments on commit 8a0ed78

Please sign in to comment.