Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
91 commits
Select commit Hold shift + click to select a range
7afb7ce
fix(segmented): title property in segmented component slot not effect…
suweite Jan 30, 2024
0cbf3ca
docs: updating the `dropdownRender` description and jumps in the FAQ …
cc-hearts Jan 30, 2024
7c73beb
fix: fixed an error caused by dragging under the `headerCell` slot. (…
cc-hearts Jan 30, 2024
4a2f95f
release 4.1.2
tangjinzhou Jan 30, 2024
ce6b7f3
chore: update pkg
tangjinzhou Mar 3, 2024
9a5f83e
chore: update pkg
tangjinzhou Mar 3, 2024
01300d0
docs: add eth sponsor
tangjinzhou Mar 22, 2024
fa46999
Update ja_JP.ts (#7438)
huyikai Mar 23, 2024
35d1de9
docs: update sandbox
tangjinzhou Apr 19, 2024
49e1323
docs: update codesandbox
tangjinzhou Apr 19, 2024
ffd4d8f
fix: useForm model change validate error
tangjinzhou Apr 19, 2024
2b0c2da
docs: typo error (#7505)
fwd001 Apr 19, 2024
75886a8
docs: match dependencies in package.json instead of simply setting 'l…
aShu-guo Apr 19, 2024
ff184b3
feat: update ru_RU localization (#7497)
SaveliyShutov Apr 19, 2024
457d0fd
fix: remove duplicate style variable (#7490)
wander-sky Apr 19, 2024
966bc10
fix[layout]: in a dark mode layout, the text color should change. (#7…
cc-hearts Apr 19, 2024
85c48c0
feat[tooltip]: add `arrow` attribute (#7459)
cc-hearts Apr 19, 2024
dec67a6
docs: update site
tangjinzhou Apr 19, 2024
4138d3c
fix: tabs size error, close #7491 #7482
tangjinzhou Apr 19, 2024
4a48bfc
fix: a-qrcord component cannot show ts prompt (#7502)
yuantongkang Apr 19, 2024
c25736d
chore: merge duplicate property declarations (#7417)
aShu-guo Apr 19, 2024
a8c72fc
fix[Menu]: fix `menu-item-group` not rendering in SSR (#7349)
cc-hearts Apr 19, 2024
040af82
docs: update table docs (#7400)
txw2018 Apr 19, 2024
4d35b8c
docs(Modal): add simplified descriptions (#7408)
selicens Apr 19, 2024
61ade6b
fix: autoComplete option slot error, close #7396 #7405
tangjinzhou Apr 19, 2024
ab874ff
docs: update tree-select api description (#7388)
inside5545 Apr 19, 2024
2b41e56
fix(Input): autoSize not work when change value in onMounted (#7478)
buqiyuan Apr 19, 2024
4815ee6
fix(Pagination): block default events for the enter key (#7368)
selicens Apr 19, 2024
162d1fc
fix(AutoComplete): #7380 and #7276 (#7391)
aShu-guo Apr 19, 2024
c28c38d
fix[Select|Cascader]: select multiple error & cascader error in ssr m…
cc-hearts Apr 19, 2024
eedd7f3
chore: remove json file type declare (#7514)
Apr 22, 2024
ed27700
style: lint code
tangjinzhou Apr 22, 2024
42d33e9
fix: carousel beforeChange current value not correct (#7419)
24min Apr 22, 2024
9b0f0e7
perf: table hover cell, close #7451
tangjinzhou Apr 22, 2024
752686e
fix: input composing error, close #7516
tangjinzhou Apr 22, 2024
23c620e
fix: select customicon error #7377
tangjinzhou Apr 22, 2024
48a3ceb
chore: remove vetur type generator (#7517)
Apr 22, 2024
9d7c171
release 4.2.0
tangjinzhou Apr 22, 2024
d6cc262
refactor: replement deprecated fields (#7519)
Apr 25, 2024
8e8073d
fix: input clear error (#7523)
hippo2cat Apr 25, 2024
9a45b35
release 4.2.1
tangjinzhou Apr 25, 2024
e01f26c
fix(TreeSelect): placehold slot invalid (#7545)
selicens Apr 30, 2024
54434b0
docs(Select): remove qs dependencie (#7541)
Apr 30, 2024
7ce0f11
fix(cascader): remove outdated compatibility code(#7532) (#7534)
ryne6 Apr 30, 2024
1c82940
docs: add Vite and Rsbuild to getting started (#7556)
chenjiahan May 9, 2024
40ad45b
fix: tree reative data error
tangjinzhou Jun 4, 2024
014e86b
docs: update README-zh_CN (#7584)
lxKylin Jun 4, 2024
9c27414
fix(FloatButton): type prompt error (#7576)
selicens Jun 4, 2024
085eb39
fix(FormItem): class name error (#7582)
selicens Jun 4, 2024
33a0708
docs: upgrade document link direction error (#7602)
selicens Jun 4, 2024
f42d8ad
chore: remove css-animation (#7613)
Jun 4, 2024
aeda263
fix(Input): Chinese input is invalid when the modifier is lazy (#7543)
selicens Jun 4, 2024
afebeb9
docs(DatePicker): updating deprecated API (#7570)
ryne6 Jun 4, 2024
307148e
fix: empty space-item are not been hidden (#7557)
lchrennew Jun 4, 2024
6e2c5a6
fix[select]: fix placeholder error when inputting Chinese (#7611)
cc-hearts Jun 4, 2024
82f28ce
fix: select input
tangjinzhou Jun 4, 2024
6594fe3
fix: textarea
tangjinzhou Jun 4, 2024
312bcc5
docs(collapse): modify the `accordion` attribute text to be easier to…
cc-hearts Jun 4, 2024
4318147
refactor(input): remove unnecessary assertions and use?? instead of t…
lxKylin Jun 4, 2024
1d0fa85
fix: add missing space-evenly alignment for grid rows (#7579)
Aaron-zon Jun 4, 2024
b82d8dd
fix(PresetPanel): preset panel stopPropagation (#7550)
evan-lc Jun 4, 2024
5c7aaf0
fix(FloatButton): type error (#7632)
Aaron-zon Jun 6, 2024
9118d6c
release 4.2.2
tangjinzhou Jun 6, 2024
f41fec2
fix[vc-util]: styleObjectToString filter invalid value (#7642)
cc-hearts Jun 9, 2024
208b8d3
docs: unify the default value of none to - (#7636)
lxKylin Jun 9, 2024
4b7c6ac
feat: TourStep support fn children (#7628)
trry-hub Jun 10, 2024
4492086
release 4.2.3
tangjinzhou Jun 10, 2024
35d5185
docs: update changelog
tangjinzhou Jun 10, 2024
2666cb7
refactor: transition
tangjinzhou Jun 21, 2024
b6ff2cd
Merge branch 'refs/heads/main' into feat-image-preview-toolbar
Jul 26, 2024
c69a6d2
docs(zh-cn): finish translation of float-button (#7811)
jasonren0403 Sep 5, 2024
89eec07
docs: event demo (#7699) (#7728)
5918vo Sep 5, 2024
3a79f72
fix(doc): `positonStyle` typo (#7808)
yyp0716 Sep 13, 2024
bb443a0
fix: button wave memory leak
tangjinzhou Sep 13, 2024
339fb4a
release 4.2.4
tangjinzhou Sep 13, 2024
49d4b31
feat: update type
tangjinzhou Sep 13, 2024
2c7008d
fix: image width & height not work
tangjinzhou Sep 19, 2024
ac9d1b0
fix: empty memory issue
tangjinzhou Sep 19, 2024
e46d537
release 4.2.5
tangjinzhou Sep 19, 2024
12fcfa1
fix: Safari of input IME (#7918)
snoweastcn Nov 7, 2024
4f7bd6f
fix(Dialog): aira error (#7823)
iamnotblank Nov 7, 2024
22dad3b
fix[Select]: fix select losing focus issue (#7829)
cc-hearts Nov 8, 2024
968317c
fix(InputNumber): disabled text clolor (#7776)
selicens Nov 8, 2024
f64d071
docs: Change the default values of attributes (#7744)
selicens Nov 8, 2024
b0d9309
docs: Add custom icons to support Rsbuild documentation (#7743)
shifeng1993 Nov 8, 2024
8884572
fix: modal aria error
tangjinzhou Nov 11, 2024
5d6ebb3
release 4.2.6
tangjinzhou Nov 11, 2024
4a37016
fix: ts type error
tangjinzhou Nov 11, 2024
8509d27
Merge branch 'main' of https://ghgo.xyz/https://github.com/Roywhite/a…
Dec 26, 2024
eb52819
feat(vc-image): 优化图片预览缩放功能
Dec 26, 2024
36243cd
fix(vc-image): improve Preview component behavior and stability
Dec 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ module.exports = {
// ],
plugins: ['markdown', 'jest', '@typescript-eslint', 'import'],
globals: {
h: true,
defineProps: 'readonly',
},
overrides: [
Expand Down Expand Up @@ -108,7 +109,4 @@ module.exports = {
],
'vue/multi-word-component-names': 'off',
},
globals: {
h: true,
},
};
56 changes: 56 additions & 0 deletions CHANGELOG.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,62 @@

---

## 4.2.6

- 🐞 Fix Modal component aria-hidden error problem under chrome [#7823](https://github.com/vueComponent/ant-design-vue/issues/7823)
- 🐞 Fix the problem that the built-in input method of Safari automatically fills in the decimal point when inputting Chinese [#7918](https://github.com/vueComponent/ant-design-vue/issues/7918)
- 🐞 Fix InputNumber component disabled style problem [#7776](https://github.com/vueComponent/ant-design-vue/issues/7776)
- 🐞 Fix Select cannot lose focus problem [#7819](https://github.com/vueComponent/ant-design-vue/issues/7819)

## 4.2.5

- 🐞 Fix Empty component memory leak problem
- 🐞 Fix Image width & height property not working problem

## 4.2.4

- 🐞 Fix Wave memory leak problem

## 4.2.3

- 🌟 TourStep custom Button, support function children [#7628](https://github.com/vueComponent/ant-design-vue/pull/7628)
- 🐞 Fix the problem that the input value is hidden in Select and Cascader search multi-select mode [#7640](https://github.com/vueComponent/ant-design-vue/issues/7640)

## 4.2.2

- 🐞 Fix TreeSelect placeholder slot invalid [#7545](https://github.com/vueComponent/ant-design-vue/issues/7545)
- 🐞 Fix Tree slot responsive invalid issue [40ad45](https://github.com/vueComponent/ant-design-vue/commit/40ad45bc05b2bf9d0a2445d9f6ff365468ba90b7)
- 🐞 Fix FloatButton target type error issue [#7576](https://github.com/vueComponent/ant-design-vue/issues/7576)
- 🐞 Fix FormItem className error issue [#7582](https://github.com/vueComponent/ant-design-vue/issues/7582)
- 🐞 Fix Input Cannot input problem under lazy [#7543](https://github.com/vueComponent/ant-design-vue/issues/7543)
- 🐞 Fix the problem that placeholder is not hidden when inputting Chinese in Select [#7611](https://github.com/vueComponent/ant-design-vue/issues/7611)
- 🐞 Fix the problem that the pop-up window flashes when clicking the preset option in DatePicker [#7550](https://github.com/vueComponent/ant-design-vue/issues/7550)

## 4.2.1

- 🐞 fix Input clear action error [#7523](https://github.com/vueComponent/ant-design-vue/issues/7523)

## 4.2.0

- 🌟 Optimize the textColor change when the layout component switches to dark mode [#7498](https://github.com/vueComponent/ant-design-vue/issues/7498)
- 🌟 Tooltip added arrow hidden configuration [#7459](https://github.com/vueComponent/ant-design-vue/issues/7459)
- 🌟 Optimize Table hover performance [#7451](https://github.com/vueComponent/ant-design-vue/issues/7451)
- 🐞 Fixed the problem of changing the model during useForm verification, resulting in verification errors [#ffd4d8](https://github.com/vueComponent/ant-design-vue/commit/ffd4d8fe927f9ea40cbb6358ad997c447bd9a74e)
- 🐞 Fix Tabs folding calculation error issue [#7491](https://github.com/vueComponent/ant-design-vue/issues/7491)
- 🐞 Fix Qrcode missing type hint issue [#7502](https://github.com/vueComponent/ant-design-vue/issues/7502)
- 🐞 Fix Menu rendering error under SSR [#7349](https://github.com/vueComponent/ant-design-vue/issues/7349)
- 🐞 Fix Select and Cascader rendering errors under SSR [#7377](https://github.com/vueComponent/ant-design-vue/issues/7377)
- 🐞 Fix AutoComplete missing option slot declaration issue [#7396](https://github.com/vueComponent/ant-design-vue/issues/7396)
- 🐞 Fix Textarea autoSize not taking effect [#7478](https://github.com/vueComponent/ant-design-vue/issues/7478)
- 🐞 Fix Pagination’s Enter key triggering two page turns [#7368](https://github.com/vueComponent/ant-design-vue/issues/7368)
- 🐞 Fix the problem of Chinese input in the input box [#7391](https://github.com/vueComponent/ant-design-vue/issues/7391)[#7516](https://github.com/vueComponent/ant- design-vue/issues/7516)
- 🐞 Fix Carousel beforeChange current parameter error issue [#7419](https://github.com/vueComponent/ant-design-vue/issues/7419)

## 4.1.2

- 🐞 Fix table resize error reporting under vue 3.4 [#7291](https://github.com/vueComponent/ant-design-vue/issues/7291)
- 🐞 Fix the problem that the Segmented title attribute is not displayed [#7302](https://github.com/vueComponent/ant-design-vue/issues/7302)

## 4.1.1

- 🌟 QRcode adds scanned status [#7242](https://github.com/vueComponent/ant-design-vue/issues/7242)
Expand Down
56 changes: 56 additions & 0 deletions CHANGELOG.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,62 @@

---

## 4.2.6

- 🐞 修复 Modal 组件在 chrome 下,aria-hidden 报错问题 [#7823](https://github.com/vueComponent/ant-design-vue/issues/7823)
- 🐞 修复 Safari 下自带输入法 input 组件输入中文时,自动填写小数点问题 [#7918](https://github.com/vueComponent/ant-design-vue/issues/7918)
- 🐞 修复 InputNumber 组件 disabled 样式问题 [#7776](https://github.com/vueComponent/ant-design-vue/issues/7776)
- 🐞 修复 Select 无法失焦问题 [#7819](https://github.com/vueComponent/ant-design-vue/issues/7819)

## 4.2.5

- 🐞 修复 Empty 组件内存泄漏问题
- 🐞 修复 Image width & height 属性不生效问题

## 4.2.4

- 🐞 修复 Wave 内存泄漏问题

## 4.2.3

- 🌟 TourStep 自定义 Button,支持函数 children [#7628](https://github.com/vueComponent/ant-design-vue/pull/7628)
- 🐞 修复 Select 和 Cascader 搜索多选模式下,输入值被隐藏问题 [#7640](https://github.com/vueComponent/ant-design-vue/issues/7640)

## 4.2.2

- 🐞 修复 TreeSelect placeholder 插槽无效 [#7545](https://github.com/vueComponent/ant-design-vue/issues/7545)
- 🐞 修复 Tree 插槽响应式无效问题 [40ad45](https://github.com/vueComponent/ant-design-vue/commit/40ad45bc05b2bf9d0a2445d9f6ff365468ba90b7)
- 🐞 修复 FloatButton target 类型错误问题 [#7576](https://github.com/vueComponent/ant-design-vue/issues/7576)
- 🐞 修复 FormItem className 错误问题 [#7582](https://github.com/vueComponent/ant-design-vue/issues/7582)
- 🐞 修复 Input lazy 下无法输入问题 [#7543](https://github.com/vueComponent/ant-design-vue/issues/7543)
- 🐞 修复 Select 输入中文时,placeholder 未隐藏问题 [#7611](https://github.com/vueComponent/ant-design-vue/issues/7611)
- 🐞 修复 DatePicker 点击预设选项时,弹窗闪动问题 [#7550](https://github.com/vueComponent/ant-design-vue/issues/7550)

## 4.2.1

- 🐞 修复 Input 清空操作才报错问题 [#7523](https://github.com/vueComponent/ant-design-vue/issues/7523)

## 4.2.0

- 🌟 优化 layout 组件切换 dark 模式时 textColor 变化 [#7498](https://github.com/vueComponent/ant-design-vue/issues/7498)
- 🌟 Tooltip 新增 arrow 隐藏配置 [#7459](https://github.com/vueComponent/ant-design-vue/issues/7459)
- 🌟 优化 Table hover 性能 [#7451](https://github.com/vueComponent/ant-design-vue/issues/7451)
- 🐞 修复 useForm 校验时更改 model,导致校验错误问题 [#ffd4d8](https://github.com/vueComponent/ant-design-vue/commit/ffd4d8fe927f9ea40cbb6358ad997c447bd9a74e)
- 🐞 修复 Tabs 折叠计算错误问题 [#7491](https://github.com/vueComponent/ant-design-vue/issues/7491)
- 🐞 修复 Qrcode 缺少类型提示问题 [#7502](https://github.com/vueComponent/ant-design-vue/issues/7502)
- 🐞 修复 Menu 在 SSR 下渲染错误问题 [#7349](https://github.com/vueComponent/ant-design-vue/issues/7349)
- 🐞 修复 Select、Cascader 在 SSR 下渲染错误问题 [#7377](https://github.com/vueComponent/ant-design-vue/issues/7377)
- 🐞 修复 AutoComplete 缺少 option slot 声明问题 [#7396](https://github.com/vueComponent/ant-design-vue/issues/7396)
- 🐞 修复 Textarea autoSize 不生效问题 [#7478](https://github.com/vueComponent/ant-design-vue/issues/7478)
- 🐞 修复 Pagination 回车键触发两次翻页问题 [#7368](https://github.com/vueComponent/ant-design-vue/issues/7368)
- 🐞 修复输入框输入中文问题 [#7391](https://github.com/vueComponent/ant-design-vue/issues/7391)[#7516](https://github.com/vueComponent/ant-design-vue/issues/7516)
- 🐞 修复 Carousel beforeChange current 参数错误问题 [#7419](https://github.com/vueComponent/ant-design-vue/issues/7419)

## 4.1.2

- 🐞 修复 table resize 在 vue 3.4 下报错问题 [#7291](https://github.com/vueComponent/ant-design-vue/issues/7291)
- 🐞 修复 Segmented title 属性不显示问题 [#7302](https://github.com/vueComponent/ant-design-vue/issues/7302)

## 4.1.1

- 🌟 QRcode 新增 scanned 状态 [#7242](https://github.com/vueComponent/ant-design-vue/issues/7242)
Expand Down
13 changes: 7 additions & 6 deletions README-zh_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

<div align="center">

An enterprise-class UI components based on Ant Design and Vue 3.
基于 Ant Design Vue 3 的企业级 UI 组件库。

![test](https://github.com/vueComponent/ant-design-vue/workflows/test/badge.svg) [![codecov](https://img.shields.io/codecov/c/github/vueComponent/ant-design-vue/master.svg?style=flat-square)](https://codecov.io/gh/vueComponent/ant-design-vue) [![npm package](https://img.shields.io/npm/v/ant-design-vue.svg?style=flat-square)](https://www.npmjs.org/package/ant-design-vue) [![NPM downloads](http://img.shields.io/npm/dm/ant-design-vue.svg?style=flat-square)](http://www.npmtrends.com/ant-design-vue) [![backers](https://opencollective.com/ant-design-vue/backers/badge.svg)](#backers) [![sponsors](https://opencollective.com/ant-design-vue/sponsors/badge.svg)](#sponsors) [![extension-for-VSCode](https://img.shields.io/badge/extension%20for-VSCode-blue.svg?style=flat-square)](https://marketplace.visualstudio.com/items?itemName=ant-design-vue.vscode-ant-design-vue-helper) [![issues-helper](https://img.shields.io/badge/Issues%20Manage%20By-issues--helper-orange?style=flat-square)](https://github.com/actions-cool/issues-helper)

Expand Down Expand Up @@ -88,22 +88,23 @@ ant-design-vue 是 MIT 协议的开源项目。为了项目能够更好的持续
- [opencollective](https://opencollective.com/ant-design-vue)
- [paypal](https://www.paypal.me/tangjinzhou)
- [支付宝或微信](https://aliyuncdn.antdv.com/alipay-and-wechat.png)
- ETH: 0x30cc48515d8ae9fefa20ab87226ad7e8ab9c3bc2

## Sponsors
## 赞助商

Become a sponsor and get your logo on our README on Github with a link to your site. [[Become a sponsor](https://opencollective.com/ant-design-vue#sponsor)]
成为赞助商,并在 Github 上的自述文件上获得您的徽标,并链接到您的网站。 [[成为赞助商](https://opencollective.com/ant-design-vue#sponsor)]

<a href="http://www.jeecg.com/" target="_blank"><img src="https://aliyuncdn.antdv.com/jeecg-logo.png" height="64"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/0/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/0/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/1/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/1/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/2/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/2/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/3/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/3/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/4/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/4/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/5/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/5/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/6/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/6/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/7/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/7/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/8/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/8/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/9/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/9/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/sponsor/10/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/sponsor/10/avatar.svg"></a>

## Backers
## 支持者

Support us with a monthly donation and help us continue our activities. [[Become a backer](https://opencollective.com/ant-design-vue#backer)]
每月捐款支持我们,帮助我们继续我们的活动。 [[成为支持者](https://opencollective.com/ant-design-vue#backer)]

<a href="https://github.com/chuzhixin/vue-admin-beautiful" target="_blank"><img width="64" style="border-radius: 50%;" src="https://gitee.com/chu1204505056/image/raw/master/vue-admin-beautiful.png" title="vue-admin-beautiful"></a> <a href="https://opencollective.com/ant-design-vue/backer/0/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/0/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/1/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/1/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/2/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/2/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/3/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/3/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/4/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/4/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/5/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/5/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/6/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/6/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/7/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/7/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/8/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/8/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/9/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/9/avatar.svg"></a> <a href="https://opencollective.com/ant-design-vue/backer/10/website" target="_blank"><img src="https://opencollective.com/ant-design-vue/backer/10/avatar.svg"></a>

## Patreon

Support us with a monthly donation and help us continue our activities. [[Become a backer](https://www.patreon.com/tangjinzhou)]
每月捐款支持我们,帮助我们继续我们的活动。 [[成为支持者](https://www.patreon.com/tangjinzhou)]

<a href="https://www.mokeyjay.com" target="_blank"><img width="64" style="border-radius: 50%;" src="https://www.mokeyjay.com/headimg.png" title="donation by Patreon"></a>

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ ant-design-vue is an MIT-licensed open source project. In order to achieve bette
- [opencollective](https://opencollective.com/ant-design-vue)
- [paypal](https://www.paypal.me/tangjinzhou)
- [支付宝或微信](https://aliyuncdn.antdv.com/alipay-and-wechat.png)
- ETH: 0x30cc48515d8ae9fefa20ab87226ad7e8ab9c3bc2

## Sponsors

Expand Down
14 changes: 3 additions & 11 deletions antd-tools/generator-types/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import { genWebTypes } from './web-types';
import { outputFileSync, readFileSync } from 'fs-extra';
import type { Options, VueTag } from './type';
import { getComponentName, normalizePath, toKebabCase } from './utils';
import { genVeturAttributes, genVeturTags } from './vetur';
import { flatMap } from 'lodash';

async function readMarkdown(options: Options): Promise<Map<String, VueTag>> {
Expand All @@ -22,13 +21,13 @@ async function readMarkdown(options: Options): Promise<Map<String, VueTag>> {
return formatter(mdParser(fileContent), componentName, kebabComponentName, options.tagPrefix);
})
.filter(item => item) as VueTag[][];
const tags: Map<String, VueTag> = new Map();
const tags = new Map<String, VueTag>();
flatMap(data, item => item).forEach(mergedTag => mergeTag(tags, mergedTag));
return tags;
}

function readTypings(options: Options): Map<String, VueTag> {
const tags: Map<String, VueTag> = new Map();
const tags = new Map<String, VueTag>();
const fileContent = readFileSync(options.typingsPath, 'utf-8');
fileContent
.split('\n')
Expand Down Expand Up @@ -62,7 +61,7 @@ function mergeTag(tags: Map<String, VueTag>, mergedTag: VueTag) {

function mergeTags(mergedTagsArr: Map<String, VueTag>[]): VueTag[] {
if (mergedTagsArr.length === 1) return [...mergedTagsArr[0].values()];
const tags: Map<String, VueTag> = new Map();
const tags = new Map<String, VueTag>();
if (mergedTagsArr.length === 0) return [];
mergedTagsArr.forEach(mergedTags => {
mergedTags.forEach(mergedTag => mergeTag(tags, mergedTag));
Expand All @@ -78,13 +77,6 @@ export async function parseAndWrite(options: Options): Promise<Number> {
const tagsFromTypings = await readTypings(options);
const tags = mergeTags([tagsFromMarkdown, tagsFromTypings]);
const webTypes = genWebTypes(tags, options);
const veturTags = genVeturTags(tags);
const veturAttributes = genVeturAttributes(tags);
outputFileSync(join(options.outputDir, 'tags.json'), JSON.stringify(veturTags, null, 2));
outputFileSync(
join(options.outputDir, 'attributes.json'),
JSON.stringify(veturAttributes, null, 2),
);
outputFileSync(join(options.outputDir, 'web-types.json'), JSON.stringify(webTypes, null, 2));
return tags.length;
}
Expand Down
8 changes: 4 additions & 4 deletions antd-tools/generator-types/src/parser.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export type Articals = Artical[];
function readLine(input: string) {
const end = input.indexOf('\n');

return input.substr(0, end !== -1 ? end : input.length);
return input.substring(0, end !== -1 ? end : input.length);
}

function splitTableLine(line: string) {
Expand All @@ -47,7 +47,7 @@ function tableParse(input: string) {
};

while (start < end) {
const target = input.substr(start);
const target = input.substring(start);
const line = readLine(target);

if (!/^\|/.test(target)) {
Expand Down Expand Up @@ -79,7 +79,7 @@ export function mdParser(input: string): Articals {
const end = input.length;

while (start < end) {
const target = input.substr(start);
const target = input.substring(start);

let match;
if ((match = TITLE_REG.exec(target))) {
Expand All @@ -91,7 +91,7 @@ export function mdParser(input: string): Articals {

start += match.index + match[0].length;
} else if ((match = TABLE_REG.exec(target))) {
const { table, usedLength } = tableParse(target.substr(match.index));
const { table, usedLength } = tableParse(target.substring(match.index));
artical.push({
type: 'table',
table,
Expand Down
19 changes: 0 additions & 19 deletions antd-tools/generator-types/src/type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,25 +34,6 @@ export type VueTag = {
description?: string;
};

export type VeturTag = {
description?: string;
attributes: string[];
};

export type VeturTags = Record<string, VeturTag>;

export type VeturAttribute = {
type: string;
description: string;
};

export type VeturAttributes = Record<string, VeturAttribute>;

export type VeturResult = {
tags: VeturTags;
attributes: VeturAttributes;
};

export type Options = {
name: string;
path: PathLike;
Expand Down
Loading