Skip to content

Commit 42510d6

Browse files
committed
docs: add changelog
1 parent 0d38219 commit 42510d6

File tree

8 files changed

+93
-33
lines changed

8 files changed

+93
-33
lines changed

CHANGELOG.en-US.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,40 @@
22

33
---
44

5+
## 1.2.0
6+
`2018-12-16`
7+
### Synchronize with antd 3.10.x
8+
9+
- 🔥🔥🔥 replaced font icons with svg icons which bring benefits below::
10+
- Complete offline usage of icon, no dependency of alipay cdn font icon file and no more empty square during downloading than no need to deploy icon font files locally either.
11+
- Much more display accuracy in lower-level screens.
12+
- Support multiple colors for icon.
13+
- No need to change built-in icons with overriding styles by providing more props in component.
14+
- 🌟 Add the `theme` attribute to set the theme style of the icon.
15+
- 🌟 Added `component` attribute, you can externally pass a component to customize the control rendering result.
16+
- 🌟 The `twoToneColor` property is added to control the theme color of the two-color icon.
17+
- 🌟 Added static methods `Icon.getTowToneColor()` and `Icon.setTwoToneColor(...)` to globally get and set the theme color of all two-color icons.
18+
- 🌟 The new static method `Icon.createFromIconfontCN({...})` is added to make it easier to use icons hosted on [`iconfont.cn`](http://iconfont.cn/).
19+
- 🔥 Added a new component `Skeleton`.
20+
- 🔥 Menu will automatically close up to fit width in `horizontal` mode.
21+
- 🔥 The `placement` of the drawer supports `top` and `bottom` to accommodate more scenes.
22+
- 🌟 The following components add a `suffixIcon` prop, which is used to set the icon behind the input box. For details, please refer to the documentation.
23+
- Cascader
24+
- DatePicker
25+
- Select
26+
- TreeSelect
27+
- TimePicker
28+
- 🌟 Added Modal.open for optional icon dialog.
29+
- 🌟 Modal.info adds the configuration of `getContainer`.
30+
- 🌟 Improve RangePicker footer UI by merging them.
31+
- 🌟 The Anchor component adds `onClick` property.
32+
- 🌟 The Tab component adds the `renderTabBar` property.
33+
- 🌟 The Input component adds the `select` method.
34+
- 🌟 Steps adds the `initial` attribute.
35+
- 🌟 Upload adds `openFileDialogOnClick` prop to allow setting whether to open the upload dialog when the component is clicked.
36+
- 🌟 InputNumber adds `decimalSeparator` prop to allow setting a custom decimal.
37+
- 🐞 Fix a lot of hidden bugs that have not yet been issued, and then not list them one by one.
38+
539
## 1.1.10
640

741
`2018-12-7`

CHANGELOG.zh-CN.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# 更新日志
22

33
---
4+
45
## 1.2.0
56
`2018-12-16`
67
### 与antd 3.10.x同步
Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
1+
export function antDecorator (Vue) {
2+
return Vue.directive('decorator', {
3+
})
4+
}
5+
16
export default {
27
// just for tag
38
install: (Vue, options) => {
4-
Vue.directive('decorator', {
5-
})
9+
antDecorator(Vue)
610
},
711
}

components/_util/antDirective.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { antInput } from './antInputDirective'
2+
import { antRef } from './antRefDirective'
3+
import { antDecorator } from './FormDecoratorDirective'
4+
5+
export default {
6+
install: (Vue, options) => {
7+
antInput(Vue)
8+
antRef(Vue)
9+
antDecorator(Vue)
10+
},
11+
}

components/_util/antInputDirective.js

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -49,26 +49,30 @@ if (isIE9) {
4949
})
5050
}
5151

52-
export default {
53-
install: (Vue, options) => {
54-
Vue.directive('ant-input', {
55-
inserted (el, binding, vnode, oldVnode) {
56-
if (vnode.tag === 'textarea' || isTextInputType(el.type)) {
57-
if (!binding.modifiers || !binding.modifiers.lazy) {
58-
el.addEventListener('compositionstart', onCompositionStart)
59-
el.addEventListener('compositionend', onCompositionEnd)
60-
// Safari < 10.2 & UIWebView doesn't fire compositionend when
61-
// switching focus before confirming composition choice
62-
// this also fixes the issue where some browsers e.g. iOS Chrome
63-
// fires "change" instead of "input" on autocomplete.
64-
el.addEventListener('change', onCompositionEnd)
65-
/* istanbul ignore if */
66-
if (isIE9) {
67-
el.vmodel = true
68-
}
52+
export function antInput (Vue) {
53+
return Vue.directive('ant-input', {
54+
inserted (el, binding, vnode, oldVnode) {
55+
if (vnode.tag === 'textarea' || isTextInputType(el.type)) {
56+
if (!binding.modifiers || !binding.modifiers.lazy) {
57+
el.addEventListener('compositionstart', onCompositionStart)
58+
el.addEventListener('compositionend', onCompositionEnd)
59+
// Safari < 10.2 & UIWebView doesn't fire compositionend when
60+
// switching focus before confirming composition choice
61+
// this also fixes the issue where some browsers e.g. iOS Chrome
62+
// fires "change" instead of "input" on autocomplete.
63+
el.addEventListener('change', onCompositionEnd)
64+
/* istanbul ignore if */
65+
if (isIE9) {
66+
el.vmodel = true
6967
}
7068
}
71-
},
72-
})
69+
}
70+
},
71+
})
72+
}
73+
74+
export default {
75+
install: (Vue, options) => {
76+
antInput(Vue)
7377
},
7478
}

components/_util/antRefDirective.js

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,18 @@
1+
export function antRef (Vue) {
2+
return Vue.directive('ant-ref', {
3+
bind: function (el, binding, vnode) {
4+
binding.value(vnode.componentInstance ? vnode.componentInstance : vnode.elm)
5+
},
6+
update: function (el, binding, vnode) {
7+
binding.value(vnode.componentInstance ? vnode.componentInstance : vnode.elm)
8+
},
9+
unbind: function (el, binding, vnode) {
10+
binding.value(null)
11+
},
12+
})
13+
}
114
export default {
215
install: (Vue, options) => {
3-
Vue.directive('ant-ref', {
4-
bind: function (el, binding, vnode) {
5-
binding.value(vnode.componentInstance ? vnode.componentInstance : vnode.elm)
6-
},
7-
update: function (el, binding, vnode) {
8-
binding.value(vnode.componentInstance ? vnode.componentInstance : vnode.elm)
9-
},
10-
unbind: function (el, binding, vnode) {
11-
binding.value(null)
12-
},
13-
})
16+
antRef(Vue)
1417
},
1518
}

components/form/index.jsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import FormDecoratorDirective from '../_util/FormDecoratorDirective'
55

66
Vue.use(ref, { name: 'ant-ref' })
77
Vue.use(FormDecoratorDirective)
8+
Vue.prototype.$form = Form
89

910
export { FormProps, FormCreateOption, ValidationRule } from './Form'
1011
export { FormItemProps } from './FormItem'

site/components/demoBox.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,9 @@
1313
<section class="code-box-meta markdown">
1414
<slot v-if="isZhCN" name="description"></slot>
1515
<slot v-else name="us-description"></slot>
16-
<span class="btn-toggle" :class="{open: isOpen}" @click="toggle"><i class="anticon anticon-down-circle-o"></i></span>
16+
<span class="btn-toggle" :class="{open: isOpen}" @click="toggle">
17+
<a-icon type="down" />
18+
</span>
1719
</section>
1820
<transition appear :css="false" @enter="enter" @leave="leave">
1921
<section class="highlight-wrapper" style="position: relative;" v-show="isOpen">

0 commit comments

Comments
 (0)