Skip to content

Feat 1.5.0 #1853

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 123 commits into from
Mar 7, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
123 commits
Select commit Hold shift + click to select a range
ba6757e
feat: add Result component
sendya Oct 10, 2019
5a1b0bc
fix: update md template tag html>tpl
sendya Oct 10, 2019
7fd8df7
refactor: svg file to functional component icon
sendya Oct 10, 2019
1e9fabc
feat: add Result component
tangjinzhou Oct 10, 2019
237b620
feat: add result
tangjinzhou Oct 10, 2019
dff0951
Feat descriptions (#1251)
zkwolf Oct 11, 2019
568c593
test: add descriptions test
tangjinzhou Oct 11, 2019
db7f0ef
fix: descriptions demo (#1498)
zkwolf Dec 4, 2019
4fdf0f0
feat: add page header (#1250)
drafish Dec 19, 2019
5da7644
merge master
tangjinzhou Dec 30, 2019
7cbba0a
style: format code
tangjinzhou Dec 30, 2019
f44df36
Merge branch 'master' into feat-1.5.0
tangjinzhou Feb 7, 2020
f773c06
feat: update style to 3.23.6 from 2.13.6
tangjinzhou Feb 7, 2020
37c6293
feat: update style to 3.26.8 from 3.23.6
tangjinzhou Feb 7, 2020
92dcc1b
chore: update util
tangjinzhou Feb 7, 2020
48444c6
chore: update util
tangjinzhou Feb 7, 2020
d0c839e
feat: update affix
tangjinzhou Feb 7, 2020
2ab5d86
feat: update alert
tangjinzhou Feb 8, 2020
22b28b3
feat: update anchor
tangjinzhou Feb 8, 2020
7a8bef0
feat: update auto-complete
tangjinzhou Feb 8, 2020
2394d9f
feat: update avatar
tangjinzhou Feb 8, 2020
20d11c8
feat: update back-top
tangjinzhou Feb 8, 2020
0ddb385
feat: update badge
tangjinzhou Feb 8, 2020
7b2fdd9
feat: update button
tangjinzhou Feb 9, 2020
a1cfa89
feat: update breadcrumb
tangjinzhou Feb 9, 2020
4915b66
feat: update ts
tangjinzhou Feb 9, 2020
e895ec0
docs: update doc
tangjinzhou Feb 9, 2020
958f3c4
feat: update calendat
tangjinzhou Feb 10, 2020
43c7c72
feat: update card
tangjinzhou Feb 10, 2020
c499aab
feat: update carousel
tangjinzhou Feb 11, 2020
81e6391
feat: update carousel
tangjinzhou Feb 11, 2020
c0b92c6
feat: update checkbox
tangjinzhou Feb 11, 2020
2875d57
feat: update comment
tangjinzhou Feb 11, 2020
5001832
feat: update config-provider
tangjinzhou Feb 11, 2020
a53dd83
docs: update doc
tangjinzhou Feb 11, 2020
465b894
feat: update collapse
tangjinzhou Feb 11, 2020
b9a1baf
feat: update locale
tangjinzhou Feb 11, 2020
1d54ebe
feat: update date-picker
tangjinzhou Feb 12, 2020
2ee50b4
feat: update divider
tangjinzhou Feb 12, 2020
e7c8060
feat: update drawer
tangjinzhou Feb 13, 2020
ce07ea3
feat: update dropdown
tangjinzhou Feb 14, 2020
1848a5e
feat: update rc-trigger
tangjinzhou Feb 14, 2020
b388379
feat: update dropdown
tangjinzhou Feb 14, 2020
2e61889
feat: update empty
tangjinzhou Feb 14, 2020
e8f5b5a
test: add empty test
tangjinzhou Feb 14, 2020
894f954
feat: update form
tangjinzhou Feb 15, 2020
e5a8952
feat: update form
tangjinzhou Feb 16, 2020
c91f709
feat: update spin
tangjinzhou Feb 17, 2020
7abdcc6
feat: update grid
tangjinzhou Feb 17, 2020
1fffe0d
docs: update grid doc
tangjinzhou Feb 17, 2020
4efc509
feat: update icon
tangjinzhou Feb 17, 2020
f39da91
feat: update slider
tangjinzhou Feb 18, 2020
356e60a
feat: update textarea
tangjinzhou Feb 20, 2020
6b6bacc
feat: update input-number
tangjinzhou Feb 20, 2020
45ff670
feat: update layout
tangjinzhou Feb 20, 2020
c7b0cb0
feat: update list
tangjinzhou Feb 20, 2020
b85bc0e
feat: update menu
tangjinzhou Feb 21, 2020
078a3e4
feat: meaage add key for update content
tangjinzhou Feb 22, 2020
e43f690
feat: modal add closeIcon support
tangjinzhou Feb 22, 2020
b95760b
feat: update notification
tangjinzhou Feb 22, 2020
2200cf0
feat: add pagination disabled support
tangjinzhou Feb 22, 2020
e7d935c
feat: popconfirm add disabled support
tangjinzhou Feb 22, 2020
c250fbf
test: update popover
tangjinzhou Feb 22, 2020
f7ad7de
feat: progress support custom line-gradiend
tangjinzhou Feb 22, 2020
601f9c1
feat: update radio
tangjinzhou Feb 22, 2020
88f2859
test: update radio test
tangjinzhou Feb 22, 2020
19354b0
docs: update rate demo
tangjinzhou Feb 22, 2020
68014c6
feat: skeleton add avatar support number type
tangjinzhou Feb 22, 2020
ed2b541
test: add switch test
tangjinzhou Feb 22, 2020
98a5907
test: update statistic test
tangjinzhou Feb 23, 2020
7c7b416
fix: input clear icon event
tangjinzhou Feb 23, 2020
f88ce93
feat: steps add type、 v-model、subTitle
tangjinzhou Feb 23, 2020
ec3978e
feat: delete typography component
tangjinzhou Feb 23, 2020
147f153
feat: delete Typography style
tangjinzhou Feb 23, 2020
3e8e90d
perf: update select
tangjinzhou Feb 23, 2020
5485959
feat: add download transformFile previewFile actio
tangjinzhou Feb 23, 2020
10b9189
docs: update upload
tangjinzhou Feb 24, 2020
747d549
feat: update tree-select
tangjinzhou Feb 25, 2020
a078105
docs: update tree-select
tangjinzhou Feb 25, 2020
5cf57f4
feat: tree add blockNode selectable
tangjinzhou Feb 26, 2020
3caabb6
docs: add tree demo
tangjinzhou Feb 26, 2020
fce1856
test: update snap
tangjinzhou Feb 26, 2020
c816086
docs: updatedoc
tangjinzhou Feb 26, 2020
93cf802
feat: update tag
tangjinzhou Feb 26, 2020
05658b7
docs: update ad doc
tangjinzhou Feb 26, 2020
ab8768b
feat: update tooltip
tangjinzhou Feb 26, 2020
00a41f5
feat: update timeline
tangjinzhou Feb 26, 2020
1d5e5b1
feat: time-picker add clearIcon
tangjinzhou Feb 27, 2020
e097546
docs: update tabs
tangjinzhou Feb 27, 2020
8f732fc
feat: transfer support custom children
tangjinzhou Feb 28, 2020
292e2bc
test: update transfer test
tangjinzhou Feb 28, 2020
9077e18
feat: update table
tangjinzhou Mar 1, 2020
35ffd2b
test: update table test
tangjinzhou Mar 2, 2020
9f7d24d
test: update test
tangjinzhou Mar 2, 2020
738d2f4
feat: calendar update locale
tangjinzhou Mar 3, 2020
d025dd7
Merge branch 'feat-1.5.0' of https://github.com/vueComponent/ant-desi…
tangjinzhou Mar 3, 2020
a04b35f
test: update test snap
tangjinzhou Mar 3, 2020
16e0755
feat: add mentions (#1790)
Amour1688 Mar 4, 2020
a98f513
feat: update mentions
tangjinzhou Mar 4, 2020
1572e8e
Merge branch 'master' into feat-1.5.0
tangjinzhou Mar 4, 2020
a1151d7
bump 1.5.0-alpha.1
tangjinzhou Mar 5, 2020
6b93aaf
feat: pageheader add ghost prop
tangjinzhou Mar 5, 2020
2bc489b
docs: update descriptions demo
tangjinzhou Mar 5, 2020
3f9fd16
chore: page-header add ghost type
tangjinzhou Mar 5, 2020
b6e9667
fix: color error
tangjinzhou Mar 5, 2020
135b87c
feat: update to 3.26.12
tangjinzhou Mar 5, 2020
449c021
fix: some prop default value
tangjinzhou Mar 5, 2020
7a93fa4
fix(typo): form, carousel, upload. duplicate identifier (#1848)
sendya Mar 6, 2020
92639ff
Add Mentions Type (#1845)
Amour1688 Mar 6, 2020
550edd2
docs: update doc
tangjinzhou Mar 6, 2020
ae60571
docs: add changelog
tangjinzhou Mar 6, 2020
d4b69be
fix: mentions getPopupCotainer value (#1850)
zkwolf Mar 6, 2020
16ca56b
Merge branch 'feat-1.5.0' of https://github.com/vueComponent/ant-desi…
tangjinzhou Mar 7, 2020
7fcbc34
docs: update doc
tangjinzhou Mar 7, 2020
d01934c
docs: uptate demo
tangjinzhou Mar 7, 2020
110511f
docs: update demo
tangjinzhou Mar 7, 2020
6c088fc
docs: delete demo
tangjinzhou Mar 7, 2020
410646a
docs: delete doc
tangjinzhou Mar 7, 2020
c5b7ce6
test: update snapshots
tangjinzhou Mar 7, 2020
ec1892f
style: format code
tangjinzhou Mar 7, 2020
a1f0472
chore: update travis
tangjinzhou Mar 7, 2020
845cf15
docs: update demo
tangjinzhou Mar 7, 2020
f73f5d8
Merge branch 'master' into feat-1.5.0
tangjinzhou Mar 7, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "antdv-demo"]
path = antdv-demo
url = https://github.com/tangjinzhou/antdv-demo.git
2 changes: 1 addition & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@ components/style/color/*.less
.gitattributes
.stylelintrc
.vcmrc
logo.png
.png
.npmrc.template
.huskyrc
6 changes: 5 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
language: node_js
sudo: required
git:
submodules: false
node_js:
- 12.4.0
before_install:
- echo -e "[submodule "antdv-demo"]\n path = antdv-demo\n https://[email protected]/tangjinzhou/antdv-demo.git" >~/.gitmodules
- git submodule update --init --recursive
before_script:
- npm install vue vue-template-compiler
script:
- if [[ $TRAVIS_BRANCH == "master" && $TRAVIS_PULL_REQUEST == "false" ]]; then cp ./scripts/.npmrc.template $HOME/.npmrc; fi
- COVERAGE=true npm run test
- npm run codecov
- if [[ $TRAVIS_BRANCH == "master" && $TRAVIS_PULL_REQUEST == "false" ]]; then npm run pub-with-ci; fi
- bash ./scripts/deploy-to-gh-pages.sh
env:
matrix:
secure: PBbJaS48HA/mkj9PuGuRxs00DEJR77XfuPdSlTvCq0QxLIR6wIO+t3LLJdOQctZIX6KWBR/Zq3zSn5bRxgPIaRcoyuEU25ga4cexJMEh1ymE23uTiDcnWwWN0X1jZKGuHPvqVKjyToAv6XW24mTXNvEAqD2uL101JxBseoWJ/2VtyOjJFJwcGbw+MTLymWCZiAF10w+k0SyigawaxZLlYL9LZXv4w3oCjCwuiTD/T6rvyT3wGQzXx7/P7XQGL4el4lE7leuK5m2PhWvX2S3t2FRpoZPw0DINJu5XzuBr3DSMErQjCrP4Ep8iqW8pGGLkoXbcxK3/K+uSy0k+DdBN7jRgnnOeLpqeVUSMaM6LRnl2XyDWL3dKpVbEzZaFkRTmAwdbgYjI+7Enn3/GtseMASo/gK47m2k+kE/msoqwpTGLC5DBOBKxdNShdFnEbOxLUUiVNgoZRXbj6VhdueqK89LsMDsnxzmFtrU8Ytgv8wJsFd5IkIhCStmQ9bdTqER659hd1Qqdh6Qe36AfpZcetOLr86Z++CSwA/pZbLPeEVrfCHDh6V3DPQXG+Zlf/m60OAmhosJ+4dxZwRnR8LnaDFZ+uLYMz+vJGeOtFHvczz7TW4mznjguLE51crG+mkBGT2dx1UUg7zs41lz3GtH9WY8cSG4y5ryjDl6YkXwoiZI=
2 changes: 1 addition & 1 deletion BACKERS.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@

<h2 align="center">支付宝/微信</h2>

### 使用支付宝/微信的赞助的用户,如需要添加名单,赞助后可发 github 账号到邮箱(415800467@qq.com)
### 使用支付宝/微信的赞助的用户,如需要添加名单,赞助后可发 github 账号到邮箱(antdv@foxmail.com)

- [fastgoo](https://github.com/fastgoo)
- [sendya](https://github.com/sendya)
Expand Down
75 changes: 74 additions & 1 deletion CHANGELOG.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,85 @@

#### Release Schedule

- Weekly release: patch version at the end of every week for routine bugfix (anytime for urgent bugfix).
- Weekly release: patch version for routine bugfix.
- Monthly release: minor version for new features.
- Major version release is not included in this schedule for breaking change and new features.

---

## 1.5.0

`2020-03-06`

### Component features and styles are synchronized to antd version 3.26.12.

- Four new components have been added:
- 🔥🔥🔥 [Mentions](https://antdv.com/components/mentions-cn/) Added mentioned components and discarded the original Mention components.
- 🔥🔥🔥 [Descriptions](https://antdv.com/components/descriptions-cn/) Display multiple read-only fields in groups.
- 🔥🔥🔥 [PageHeader](https://antdv.com/components/page-header-cn/) can be used to declare the topic of the page, display important information about the page that the user is concerned about, and carry the operation items related to the current page.
- 🔥🔥🔥 [Result](https://antdv.com/components/result) is used to feedback the processing results of a series of operation tasks.
- 🔥 Descriptions supports vertical layout.
- 🔥 Progress.Circle supports gradient colors.
- 🔥 Progress.Line supports gradient colors.
- Breadcrumb
- 🎉 Breadcrumb.Item supports the `overlay` property to define drop-down menus.
- 🌟 Added `Breadcrumb.Separator` component, you can customize`separator`.
- 🌟 TreeSelect's `showSearch` supports multiple selection mode.
- 🌟 Timeline.Item adds `gray` color type, which can be used in incomplete or invalid state.
- 🌟 Modal supports `closeIcon` property for customizing the close icon.
- Upload
- 🌟 Upload provides `previewFile` property to customize the preview logic.
- 🌟 Upload adds `transformFile` to support converting files before uploading.
- 🌟 Upload supports previewing pictures in jfif format.
- 🌟 Added `showDownloadIcon` property for displaying download icons.
- 🌟 Input.Search adds `loading` property, which is used to display the loading status.
- 🌟 Grid's `gutter` property adds support for vertical spacing. Now you can set an array for`gutter`, the second value of the array represents the vertical spacing.
- 🌟 message Added support for updating content with unique `key`.
- 🌟 TextArea supports `allowClear`.
- 🌟 Dropdown.Button supports `icon` property to customize the icon.
- Drawer
- 🌟 Support `afterVisibleChange` property, which is triggered after the drawer animation is completed.
- 🌟 Support `ESC` shutdown.
- 🌟 Added `keyboard`, which allows the response to keyboard events to be turned on and off.
- 🌟 TreeNode supports `checkable` property.
- 🌟 Transfer supports `children` custom rendering list.
- 🌟 Pagination supports `disabled` property.
- 🌟 Steps support click to switch function.
- Slider
- 🌟 Support `tooltipPlacement` to define the location of the tip.
- 🌟 Support `getTooltipPopupContainer` to allow custom container for the prompt.
- 🌟 Flip `trigger` direction when Sider is on the right.
- 🌟 Calendar supports `headerRender` to customize header.
- 🌟 Carousel supports custom panel pointing point locations.
- 🌟 Collapse supports `expandIconPosition` property.
- 🌟 Popconfirm adds `disabled` props, which are used to control whether clicking child elements pop up.
- 🌟 Select supports `showArrow` in multi-select mode.
- 🌟 Collapse.Panel added `extra`.
- Card
- 🌟 Card component added `tabBarExtraContent` property.
- 🌟 Card.Grid added a hoverable property to allow floating effects to be disabled.
- 🌟 Anchor.Link adds `target` attribute.
- 🌟 TimePicker added `clearIcon` prop for custom clear icon.
- Form
- 🌟 Support to configure the `colon` property directly on the Form.
- 🌟 Support `labelAlign` property.
- Table
- 🌟 Table adds `getPopupContainer` property for setting various floating layer rendering nodes in the table.
- 💄 Adjust the style of the Table expand button.
- 🌟 Added `tableLayout` property, supports setting the table's`table-layout` layout, and enables `tableLayout =" fixed "` by default under fixed headers / columns, to solve the column alignment problem caused by the table layout automatically based on content .
- 🌟 Added `column.ellipsis` to support automatic omission of cell contents.
- 🌟 Added `scroll.scrollToFirstRowOnChange` property, which is used to set whether to scroll to the top of the table after page turning.   -Filter `filterDropdown` Added`visible` parameter to get the display status of the drop-down box.
- 🌟 The `title` method adds a`sortColumn` parameter to get the currently sorted column.   -Sort When sorting, the `sorter` parameter of`onChange` will always contain `column` information.
- 🌟 Tree component supports `blockNode` property.
- 🌟 RangePicker adds `separator` definition.
- Empty
- 🌟 Empty supports the `imageStyle` property.
- 🌟 Empty `description` supports`false`.
- 🌟 Empty Supports access to preset pictures via `Empty.PRESENTED_IMAGE_DEFAULT` and`Empty.PRESENTED_IMAGE_SIMPLE`
- 🌟 Badge supports custom colors.
- 🐞 Fix the problem that the label of Steps is not centered.
- 🐞 Fix cursor style problem of DatePicker and TimePicker.

## 1.4.12

`2020-03-03`
Expand Down
77 changes: 76 additions & 1 deletion CHANGELOG.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,87 @@

#### 发布周期

- 修订版本号:每周末会进行日常 bugfix 更新。(如果有紧急的 bugfix,则任何时候都可发布)
- 修订版本号:日常 bugfix 更新
- 次版本号:带有新特性的向下兼容的版本。
- 主版本号:含有破坏性更新和新特性,不在发布周期内。

---

## 1.5.0

`2020-03-06`

### 组件功能和样式同步到 antd 3.26.12 版本。

- 新增了四个组件:
- 🔥🔥🔥 [Mentions](https://antdv.com/components/mentions-cn/) 新增提及组件并废弃原有 Mention 组件。
- 🔥🔥🔥 [Descriptions](https://antdv.com/components/descriptions-cn/) 成组展示多个只读字段。
- 🔥🔥🔥 [PageHeader](https://antdv.com/components/page-header-cn/) 可用于声明页面主题、展示用户所关注的页面重要信息,以及承载与当前页相关的操作项。
- 🔥🔥🔥 [Result](https://antdv.com/components/result) 用于反馈一系列操作任务的处理结果。
- 🔥 Descriptions 支持垂直布局。
- 🔥 Progress.Circle 支持渐变色。
- 🔥 Progress.Line 支持渐变色。
- Breadcrumb
- 🎉 Breadcrumb.Item 支持 `overlay` 属性来定义下拉菜单。
- 🌟 新增 `Breadcrumb.Separator` 组件,可进行 `separator` 自定义。
- 🌟 TreeSelect 的 `showSearch` 支持多选模式。
- 🌟 Timeline.Item 新增 `gray` 色彩类型,可用于未完成或失效状态。
- 🌟 Modal 支持 `closeIcon` 属性用于自定义关闭图标。
- 🌟 Upload
- 🌟 Upload 提供 `previewFile` 属性以自定义预览逻辑。
- 🌟 Upload 新增 `transformFile` 支持上传之前转换文件。
- 🌟 Upload 支持预览 `jfif` 格式图片。
- 🌟 新增 `showDownloadIcon` 属性,用于展示下载图标。
- 🌟 Input.Search 新增 `loading` 属性,用于展示加载中的状态。
- 🌟 Grid 的 `gutter` 属性新增垂直间距的支持,现在你可以给 `gutter` 设置一个数组,数组的第二个值就表示垂直间距。
- 🌟 message 新增支持通过唯一的 `key` 来更新内容。
- 🌟 TextArea 支持 `allowClear`。
- 🌟 Dropdown.Button 支持 `icon` 属性来自定义图标。
- Drawer
- 🌟 支持 `afterVisibleChange` 属性,在抽屉动画完成后触发。
- 🌟 支持 `ESC` 关闭。
- 🌟 新增 `keyboard`,允许打开关闭对键盘事件的响应。
- 🌟 TreeNode 支持 `checkable` 属性。
- 🌟 Transfer 支持 `children` 来自定义渲染列表。
- 🌟 Pagination 支持 `disabled` 属性。
- 🌟 Steps 支持点击切换功能。
- Slider
- 🌟 支持 `tooltipPlacement` 以定义提示所在位置。
- 🌟 支持 `getTooltipPopupContainer` 以允许自定义提示所在容器。
- 🌟 当 Sider 在右边时,翻转 `trigger` 方向。
- 🌟 Calendar 支持 `headerRender` 以自定义头部。
- 🌟 Carousel 支持自定义面板指示点的位置。
- 🌟 Collapse 支持 `expandIconPosition` 属性。
- 🌟 Popconfirm 增加 `disabled` props,用于控制点击子元素是否弹出。
- 🌟 Select 在多选模式下支持 `showArrow`。
- 🌟 Collapse.Panel 新增了 `extra`。
- Card
- 🌟 Card 组件新增了 `tabBarExtraContent` 属性。
- 🌟 Card.Grid 新增 `hoverable` 属性允许禁用浮动效果。
- 🌟 Anchor.Link 增加 `target` 属性。
- 🌟 TimePicker 新增了 `clearIcon` prop,用于自定义清除图标。
- Form
- 🌟 支持直接在 Form 上面配置 `colon` 属性。
- 🌟 支持 `labelAlign` 属性。
- Table
- 🌟 Table 新增 `getPopupContainer` 属性用于设置表格内的各类浮层渲染节点。
- 💄 调整 Table 展开按钮的样式。
- 🌟 新增 `tableLayout` 属性,支持设置表格的 `table-layout` 布局,并在固定表头/列下默认开启 `tableLayout="fixed"`,解决因为表格自动根据内容排版造成的列对齐问题。
- 🌟 新增 `column.ellipsis` 支持单元格内容自动省略。
- 🌟 新增 `scroll.scrollToFirstRowOnChange` 属性,用于设置在翻页后是否滚动到表格顶部。
- 🌟 `filterDropdown` 新增 `visible` 参数,用于获取下拉框的显示状态。
- 🌟 `title` 方法新增 `sortColumn` 参数,用于获取当前排序的列。
- 🌟 排序时 `onChange` 的 `sorter` 参数将始终包含 `column` 信息。
- 🌟 Tree 组件支持 `blockNode` 属性。
- 🌟 RangePicker 添加 `separator` 定义。
- Empty
- 🌟 Empty 支持 `imageStyle` 属性。
- 🌟 Empty `description` 支持 `false`。
- 🌟 Empty 支持通过 `Empty.PRESENTED_IMAGE_DEFAULT` 和 `Empty.PRESENTED_IMAGE_SIMPLE` 访问预置图片。
- 🌟 Badge 支持自定义颜色。
- 🐞 修复 Steps 的 label 不居中的问题。
- 🐞 修复 DatePicker 和 TimePicker 的 cursor 样式问题。

## 1.4.12

`2020-03-03`
Expand Down
11 changes: 6 additions & 5 deletions antd-tools/gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -295,11 +295,12 @@ gulp.task(
gulp.task(
'pub',
gulp.series('check-git', 'compile', done => {
if (!process.env.GITHUB_TOKEN) {
console.log('no GitHub token found, skip');
} else {
pub(done);
}
// if (!process.env.GITHUB_TOKEN) {
// console.log('no GitHub token found, skip');
// } else {
// pub(done);
// }
pub(done);
}),
);

Expand Down
1 change: 1 addition & 0 deletions antdv-demo
Submodule antdv-demo added at 805d32
2 changes: 1 addition & 1 deletion build/config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
dev: {
componentName: 'tree', // dev components
componentName: 'badge', // dev components
},
};
12 changes: 7 additions & 5 deletions build/dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ let { componentName } = require('./config').dev;
const componentsInPrototype = ['Modal', 'message', 'notification'];

const MAIN_TEMPLATE = `import 'babel-polyfill';
import './index.less';
import 'highlight.js/styles/solarized-light.css';
import Vue from 'vue';
import Vuex from 'vuex';
Expand All @@ -38,6 +37,7 @@ import VueClipboard from 'vue-clipboard2';
import Md from './components/md';
import Api from './components/api';
import demoBox from './components/demoBox';
import demoSort from './components/demoSort';
import demoContainer from './components/demoContainer';
import Modal from '../components/modal';
import message from '../components/message';
Expand All @@ -47,9 +47,10 @@ import notification from '../components/notification';
import '../components/modal/style';
import '../components/message/style';
import '../components/notification/style';
import Test from '../components/{{name}}/demo/index.vue';
import Test from '../antdv-demo/{{name}}/demo/index.vue';
import zhCN from './theme/zh-CN';
import enUS from './theme/en-US';
import './index.less';

Vue.use(Vuex);
Vue.use(VueClipboard);
Expand All @@ -58,6 +59,7 @@ Vue.use(VueI18n);
Vue.component(Md.name, Md);
Vue.component(Api.name, Api);
Vue.component('demo-box', demoBox);
Vue.component('demo-sort', demoSort);
Vue.component('demo-container', demoContainer);

Vue.prototype.$message = message;
Expand Down Expand Up @@ -132,8 +134,8 @@ const renderTemplate = name => {
};

const demoPaths = fs
.readdirSync(path.join(__dirname, `../components/${name}/demo`))
.map(p => `../components/${name}/demo/${p}`);
.readdirSync(path.join(__dirname, `../antdv-demo/${name}/demo`))
.map(p => `../antdv-demo/${name}/demo/${p}`);
const testPaths = fs
.readdirSync(path.join(__dirname, `../components/test`))
.map(p => `../components/test/${p}`);
Expand Down Expand Up @@ -194,7 +196,7 @@ chokidar.watch(configPath, { ignoreInitial: true }).on('change', async () => {

demoWatcher && (await demoWatcher.close());

demoWatcher = chokidar.watch(path.join(__dirname, `../components/${componentName}/demo`));
demoWatcher = chokidar.watch(path.join(__dirname, `../antdv-demo/${componentName}/demo`));
demoWatcher.on('change', () => {
renderTemplate(componentName);
});
Expand Down
2 changes: 1 addition & 1 deletion build/webpack.dev.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ module.exports = merge(baseWebpackConfig, {
],
},
devServer: {
port: 3000,
port: process.env.PORT || 3000,
host: '0.0.0.0',
historyApiFallback: {
rewrites: [{ from: /./, to: '/index.html' }],
Expand Down
58 changes: 58 additions & 0 deletions components/__tests__/util/domHook.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
const __NULL__ = { notExist: true };

export function spyElementPrototypes(Element, properties) {
const propNames = Object.keys(properties);
const originDescriptors = {};

propNames.forEach(propName => {
const originDescriptor = Object.getOwnPropertyDescriptor(Element.prototype, propName);
originDescriptors[propName] = originDescriptor || __NULL__;

const spyProp = properties[propName];

if (typeof spyProp === 'function') {
// If is a function
Element.prototype[propName] = function spyFunc(...args) {
return spyProp.call(this, originDescriptor, ...args);
};
} else {
// Otherwise tread as a property
Object.defineProperty(Element.prototype, propName, {
...spyProp,
set(value) {
if (spyProp.set) {
return spyProp.set.call(this, originDescriptor, value);
}
return originDescriptor.set(value);
},
get() {
if (spyProp.get) {
return spyProp.get.call(this, originDescriptor);
}
return originDescriptor.get();
},
});
}
});

return {
mockRestore() {
propNames.forEach(propName => {
const originDescriptor = originDescriptors[propName];
if (originDescriptor === __NULL__) {
delete Element.prototype[propName];
} else if (typeof originDescriptor === 'function') {
Element.prototype[propName] = originDescriptor;
} else {
Object.defineProperty(Element.prototype, propName, originDescriptor);
}
});
},
};
}

export function spyElementPrototype(Element, propName, property) {
return spyElementPrototypes(Element, {
[propName]: property,
});
}
1 change: 1 addition & 0 deletions components/_util/BaseMixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export default {
// Object.assign(newState, this.getDerivedStateFromProps(getOptionProps(this), { ...this.$data, ...newState }, true) || {})
// }
Object.assign(this.$data, newState);
this.$forceUpdate();
this.$nextTick(() => {
callback && callback();
});
Expand Down
Loading