Skip to content

Commit

Permalink
同步至Element UI 2.4.6版本
Browse files Browse the repository at this point in the history
Merge commit 'ceee9bcad11ac8a7bee05dfefdd0f0f45f3bef84' into current

* commit 'ceee9bcad11ac8a7bee05dfefdd0f0f45f3bef84': (86 commits)
  [release] 2.4.6
  [build] 2.4.6
  Changelog: update for 2.4.6 (ElemeFE#12325)
  Tree: fix add node bug in lazy mode (ElemeFE#12265)
  Select & Cascader: add default value for query string (ElemeFE#12322)
  Select: not clear text when filtering (ElemeFE#12304)
  Menu: fix docs (ElemeFE#12299)
  Pagination: make page-size attribute supports .sync (ElemeFE#12281)
  Popover: show popper when InputNumber focused (ElemeFE#12284)
  Tree: register node after dragging (ElemeFE#12279)
  Input: not trigger form validation when input (ElemeFE#12260)
  Radio: fix focus style (ElemeFE#12262)
  Slider: avoid NaN when min and max values ​​are equal (ElemeFE#12256)
  Cascader: escape special characters for regexp (ElemeFE#12248)
  Autocomplete: add `popper-append-to-body` attribute (ElemeFE#12241)
  Menu: make font-size constant into variable (ElemeFE#12239)
  Main: fix IE compatibility issues (ElemeFE#12237)
  Tree & MessageBox: fix type definition (ElemeFE#12214)
  Select: debounce query (ElemeFE#12181)
  Table: fix async filters (ElemeFE#12165)
  ...

# Conflicts:
#	CHANGELOG.zh-CN.md
#	README.md
#	examples/versions.json
#	package.json
#	packages/cascader/src/main.vue
#	packages/form/src/form-item.vue
#	packages/select/src/option.vue
#	packages/theme-chalk/package.json
#	src/index.js
  • Loading branch information
bluejfox committed Aug 10, 2018
2 parents 3482873 + ceee9bc commit c978e0f
Show file tree
Hide file tree
Showing 113 changed files with 1,256 additions and 524 deletions.
56 changes: 56 additions & 0 deletions CHANGELOG.en-US.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,61 @@
## Changelog

### 2.4.6

*2018-08-09*

- Fixed Table not showing filter icon when `filters` is assigned empty array, #12165
- Fixed Menu not saving active state when `collapse` is changed, #12178 (by @elfman)
- Fixed Cascader not escaping special characters for Regexp, #12248
- Fixed disabled RadioButton showing box-shadow when clicked, #12262
- Fixed arrow key not effect when default value is `undefined`,#12322
- Fixed query function of Select not debounced in multi mode, #12181
- Fixed query keyword of Select disappearing in multi mode, #12304
- Fixed incorrect width of Dialog when it is displayed in full screen, #12203
- Fixed incorrect display of Main on IE, #12237
- Fixed Input triggering two form validations, #12260
- Fixed adding new Tree node causing nodes to disappear, #12256
- Fixed Tree node not deleted after dragging, #12279
- Fixed Popover not visible when InputNumber focuses, #12284
- Added `popper-append-to-body` attribute for Autocomplete, #12241
- Added `sync` modifier support for Pagination's `page-size` attribute, #12281

### 2.4.5

*2018-07-26*

- Fixed Table setting `class-name` does not work for `expand` column, #12006
- Added `toggleAllSelection` method for Table, #12047
- Fixed wrong position of suffix slot when Input contains Select, #12108
- Fixed `line-height` of Option unable to set, #12120
- Fixed TimeSelect with default value of `null` could not be assigned after executing `resetField`, #12010
- Fixed keydown event which is not arrow key does not work in Tree, #12008
- Fixed parent node checked in lazy mode, #12106
- Added `includeHalfChecked` parameter for getCheckedNodes of Tree, #12014

### 2.4.4

*2018-07-13*

- Fixed triggering Select validation after Form resetting, #11837
- Fixed wrong position of Input `suffix` slot when `suffix` slot with `append` slot, #11951
- Fixed clearable Input still displaying the clear icon when readonly, #11967
- Fixed Tree node checked when it's disabled, #11847
- Fixed Tree's `default-checked-keys` not working, #11971
- Fixed `empty-text` not visible when Tree node filtered, #11971
- Fixed the position of oversized `empty-text` in Table, #11965
- Fixed Table row not be unhighlighted when `current-row-key` is assigned to `null`, #11866
- Fixed showing filter dropdown when `filters` is an empty array, #11864
- Fixed Radio's label does not stop event propagation, #11912

### 2.4.3

*2018-07-03*

- Fixed `allow-drop` not working properly when Tree nodes have a custom height, #11797
- Now you can pass a parameter to the `clearValidate` method of Form, specifying which FormItems' validation results need to be cleared, #11821
- Added `distinguishCancelAndClose` attribute for MessageBox, #11831

### 2.4.2

*2018-06-26*
Expand Down
74 changes: 65 additions & 9 deletions CHANGELOG.es.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,74 @@
## Changelog

### 2.4.6

*2018-08-09*

- Fixed Table not showing filter icon when `filters` is assigned empty array, #12165
- Fixed Menu not saving active state when `collapse` is changed, #12178 (by @elfman)
- Fixed Cascader not escaping special characters for Regexp, #12248
- Fixed disabled RadioButton showing box-shadow when clicked, #12262
- Fixed arrow key not effect when default value is `undefined`,#12322
- Fixed query function of Select not debounced in multi mode, #12181
- Fixed query keyword of Select disappearing in multi mode, #12304
- Fixed incorrect width of Dialog when it is displayed in full screen, #12203
- Fixed incorrect display of Main on IE, #12237
- Fixed Input triggering two form validations, #12260
- Fixed adding new Tree node causing nodes to disappear, #12256
- Fixed Tree node not deleted after dragging, #12279
- Fixed Popover not visible when InputNumber focuses, #12284
- Added `popper-append-to-body` attribute for Autocomplete, #12241
- Added `sync` modifier support for Pagination's `page-size` attribute, #12281

### 2.4.5

*2018-07-26*

- Se ha corregido en Table que `class-name` no funcionaba para las columnas `expand`, #12006
- Se ha añadido el método `toggleAllSelection` para Table, #12047
- Corregida la posición incorrecta del `suffix slot` cuando Input contiene Select, #12108
- Corregido que el `line-height` de Option no se establecia, #12120
- Corregido que TimeSelect con valor por defecto `null` no podia ser asignado después de ejecutar `resetField`, #12010
- Arreglado el evento `keydown` que cuando no era una tecla de flecha no funciona en Tree, #12008
- Corregido nodo padre checked en modo lazy, #12106
- Añadido el parámetro `includeHalfChecked` para getCheckedNodes de Tree, #12014

### 2.4.4

*2018-07-13*

- Corregido que se disparaba la validacion del Select después de reajustar el formulario, #11837
- Corregida la posición incorrecta del slot Input `suffix` cuando se usaba el slot `suffix` con el slot `append` , #11951
- Corregido el clearable Input que muestraba el icono de borrado cuando era readonly, #11967
- Arreglado el nodo Tree checked cuando estaba disabled, #11847
- Corregido que `default-checked-keys` no funcionaba en Tree, #11971
- Corregido que el `empty-text` no era visible cuando el nodo Tree se filtraba, #11971
- Arreglada la posición de texto vacío sobredimensionado en Table, #11965
- Corregido que la fila de la tabla no se modificado el resaltado cuando `current-row-key` era asignada a null, #11866
- Arreglado que mostraba el filtro del dropdown cuando los filtros eran un array vacío, #11864
- Corregido que el cambio de label de Radio no detenia propagacion de eventos, #11912

### 2.4.3

*2018-07-03*

- Corregido `allow-drop` que no funcionaba correctamente cuando los nodos de árbol tenian una altura personalizada, #11797
- Ahora puede pasar un parámetro al método `clearValidate` de Form, especificando qué resultados de validación de `FormItems` necesita borrar, #11821
- Añadido el atributo `distinguishCancelAndClose` para MessageBox, #11831

### 2.4.2

*2018-06-26*

- Now `class-name` and `label-class-name` of Table are reactive, #11626
- Fixed Table still highlighting clicked row when `highlight-current-row` is `false`, #11646
- Fixed a style bug of ButtonGroup when it has only one `round` or `circle` Button, #11605
- Fixed style of page size Select of Pagination, #11622
- Fixed Menu's `open` method error when `collapse` is dynamically changed, #11646
- Added `activeName` and `oldActiveName` parameters to the before-leave hook of Tabs, #11713
- Fixed Cascader focused after outside clicked, #11588
- Fixed Cascader not closing when option is clicked when `change-on-select` is true, #11623
- Now updating Select's value programmatically will trigger form validation, #11672
- Ahora el `class-name` y el `label-class-name` de la tabla son reactivos, #11626
- Arreglado que Table seguia resaltando la fila en la que se había hecho clic cuando `highlight-current-row` era `false`, #11646
- Corregido un error de estilo de ButtonGroup cuando sólo habia un botón `round` o `circle`, #11605
- Arreglado estilo del tamaño de página del Select de Pagination, #11622
- Corregido un error del método `open` de los Menús cuando se cambiaba dinámicamente `collapse`, #11646
- Añadidos los parámetros `activeName` y `oldActiveName` al gancho before-leave de Tabs, #11713
- Arreglado el focus en Cascader después de hacer clic fuera, #11588
- Arreglado que Cascader no se cerraba cuando se hacia clic en la opción estando `change-on-select` como `true`, #11623
- Ahora la actualización del valor de Select programáticamente activará la validación de formulario, #11672

### 2.4.1

Expand Down
65 changes: 65 additions & 0 deletions CHANGELOG.zh-CN.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,70 @@
## 更新日志

### 1.4.10
*2018-08-10*

同步至Element-UI 2.4.6版本

#### 新特性

- Autocomplete
- 添加 `popper-append-to-body` 属性,#12241
- Form
- 现在 Form 的 `clearValidate` 方法支持传入参数,指定需要清空校验结果的 FormItem,#11821
- MessageBox
- 新增 MessageBox 的 `distinguishCancelAndClose` 属性,#11831
- Pagination
- 添加 `page-size` 属性 `sync` 修饰符的支持,#12281
- Table
- 新增 `toggleAllSelection` 方法,#12047

#### 修复

- Cascader
- 修复 Cascader 未转义特殊字符的问题,#12248
- DatePicker
- 修复初始值为 `null` 的 TimeSelect 在执行 `resetField` 后无法再赋值的问题,#12010
- Dialog
- 修复 Dialog 在全屏显示时宽度不正确的问题,#12203
- Input
- 修复 Input 触发两次表单校验的问题,#12260
- 修复 Input 包含 Select 时,suffix 插槽位置显示不正确的问题,#12108
- 修复 Input 组件 `suffix``append` 共存时样式错乱问题,#11951
- 修复可清空的只读 Input 仍会显示清空图标的问题,#11967
- Menu
- 修复 Menu 在更改 `collapse` 时不保存菜单激活状态的问题,#12178 (by @elfman)
- Popover
- 修复 Popover 在 InputNumber 聚焦时不显示的问题,#12284
- Radio
- 修复禁用的 RadioButton 在点击时显示 box-shadow 的问题,#12262
- 修复 Radio 的 label 不阻止事件冒泡的问题,#11912
- Select
- 修复 Select 初始值为 `undefined` 时方向键失效的问题,#12322
- 修复 Select 多选时输入的关键字消失的问题,#12304
- 修复 Select 多选时查询函数没有去抖的问题,#12181
- 修复 Option 的 `line-height` 无法设置的问题,#12120
- 修复重置表单后触发 Select 组件校验问题,#11837
- Table
- 修复 Table 的 filter 初始值为空数组时不显示筛选图标的问题,#12165
- 修复 Table 设置 `class-name``expand` 列不生效的问题,#12006
- 修复 Table 的 `empty-text` 过长时的位置样式问题,#11965
- 修复 Table 的 `current-row-key` 设置为 `null` 时高亮行不清除的问题,#11866
- 修复当 `filters` 为空数组时显示过滤器下拉列表的问题,#11864
- Tree
- 修复 Tree 在懒加载时添加节点导致节点消失的问题,#12256
- 修复 Tree 节点在拖拽后无法删除的问题,#12279
- 修复 Tree 组件中不响应方向键以外 keydown 事件的问题,#12008
- 修复 Tree 在懒加载情况下选中父节点的问题,#12106
- 修复 Tree 节点禁用时仍可以选中的问题,#11847
- 修复 Tree `default-checked-keys` 属性不生效的问题,#11971
- 修复 Tree 在过滤节点时下 `empty-text` 不显示的问题,#11971
- 修复当自定义 Tree 节点高度时,`allow-drop` 不能正常工作的问题,#11797

#### 其他

- ThemeChalk
- 修复 Main 在 IE 下的显示不正确的问题,#12237

### 1.4.9
*2018-08-10*

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Fork自[element-ui](https://github.com/ElemeFE/element)

**同步至Element-UI 2.4.2**
**同步至Element-UI 2.4.6**

基于Vue和Element UI,结合其他优秀组件库([Ant Design](https://ant.design/index-cn)[Material Deisgn](https://material.angular.io/)等),加速业务级应用页面开发。

Expand Down
2 changes: 1 addition & 1 deletion build/bin/build-entry.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const install = function(Vue, opts = {}) {
locale.use(opts.locale);
locale.i18n(opts.i18n);
components.map(component => {
components.forEach(component => {
Vue.component(component.name, component);
});
Expand Down
2 changes: 1 addition & 1 deletion build/bin/gen-indices.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const algoliasearch = require('algoliasearch');
const slugify = require('transliteration').slugify;
const key = require('./algolia-key');

const client = algoliasearch('9NLTR1QH8B', key);
const client = algoliasearch('4C63BTGP6S', key);
const langs = {
'zh-CN': 'element-zh',
'en-US': 'element-en',
Expand Down
4 changes: 4 additions & 0 deletions build/bin/new.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ export default {
filename: path.join('../../examples/docs/en-US', `${componentname}.md`),
content: `## ${ComponentName}`
},
{
filename: path.join('../../examples/docs/es', `${componentname}.md`),
content: `## ${ComponentName}`
},
{
filename: path.join('../../test/unit/specs', `${componentname}.spec.js`),
content: `import { createTest, destroyVM } from '../util';
Expand Down
2 changes: 1 addition & 1 deletion examples/components/search.vue
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@
methods: {
initIndex() {
const client = algoliasearch('9NLTR1QH8B', 'a75cbec97cda75ab7334fed9219ecc57');
const client = algoliasearch('4C63BTGP6S', '0729c3c7f4dc8db7395ad0b19c0748d2');
this.index = client.initIndex(`element-${ this.lang ? this.langs[this.lang].index : 'zh' }`);
},
Expand Down
21 changes: 16 additions & 5 deletions examples/components/side-nav.vue
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,10 @@
</li>
</ul>
</li>
<li class="nav-item" v-for="item in data">
<li
class="nav-item"
v-for="(item, key) in data"
:key="key">
<a v-if="!item.path && !item.href" @click="expandMenu">{{item.name}}</a>
<a v-if="item.href" :href="item.href" target="_blank">{{item.name}}</a>
<router-link
Expand All @@ -153,7 +156,10 @@
v-text="item.title || item.name">
</router-link>
<ul class="pure-menu-list sub-nav" v-if="item.children">
<li class="nav-item" v-for="navItem in item.children">
<li
class="nav-item"
v-for="(navItem, key) in item.children"
:key="key">
<router-link
class=""
active-class="active"
Expand All @@ -164,13 +170,18 @@
</li>
</ul>
<template v-if="item.groups">
<div class="nav-group" v-for="group in item.groups">
<div
class="nav-group"
v-for="(group, key) in item.groups"
:key="key"
>
<div class="nav-group__title" @click="expandMenu">{{group.groupName}}</div>
<ul class="pure-menu-list">
<li
class="nav-item"
v-for="navItem in group.list"
v-if="!navItem.disabled">
v-for="(navItem, key) in group.list"
v-if="!navItem.disabled"
:key="key">
<router-link
active-class="active"
:to="base + navItem.path"
Expand Down
2 changes: 1 addition & 1 deletion examples/docs/en-US/cascader.md
Original file line number Diff line number Diff line change
Expand Up @@ -1694,6 +1694,6 @@ Search and select options with a keyword.
| Event Name | Description | Parameters |
|---------- |-------- |---------- |
| change | triggers when the binding value changes | value |
| active-item-change | triggers when active option changes, only works when `change-on-select` is `false` | an array of active options |
| active-item-change | triggers when active option of its parent changes, only works when `change-on-select` is `false` | an array of active options |
| blur | triggers when Cascader blurs | (event: Event) |
| focus | triggers when Cascader focuses | (event: Event) |
2 changes: 1 addition & 1 deletion examples/docs/en-US/form.md
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,7 @@ All components in a Form inherit their `size` attribute from that Form. Similarl
| validate | validate the whole form. Takes a callback as a param. After validation, the callback will be executed with two params: a boolean indicating if the validation has passed, and an object containing all fields that fail the validation. Returns a promise if callback is omitted | Function(callback: Function(boolean, object)) |
| validateField | validate a certain form item | Function(prop: string, callback: Function(errorMessage: string)) |
| resetFields | reset all the fields and remove validation result ||
| clearValidate | clear validation message for all fields | -
| clearValidate | clear validation message for certain fields. The parameter is an array of prop names of the form items whose validation messages will be removed. When omitted, all fields' validation messages will be cleared | Function(props: array)

### Form Events
| Event Name | Description | Parameters |
Expand Down
2 changes: 1 addition & 1 deletion examples/docs/en-US/input-number.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ Allows you to define incremental steps.
:::

:::tip
The value of `precision` must be a positive integer and should not be less than the decimal places of `step`.
The value of `precision` must be a non negative integer and should not be less than the decimal places of `step`.
:::

### Size
Expand Down
1 change: 1 addition & 0 deletions examples/docs/en-US/input.md
Original file line number Diff line number Diff line change
Expand Up @@ -712,6 +712,7 @@ Attribute | Description | Type | Options | Default
| prefix-icon | prefix icon class | string |||
| suffix-icon | suffix icon class | string |||
| hide-loading | whether to hide the loading icon in remote search | boolean || false |
| popper-append-to-body | whether to append the dropdown to body. If the positioning of the dropdown is wrong, you can try to set this prop to false | boolean | - | true |

### Autocomplete Slots

Expand Down
2 changes: 1 addition & 1 deletion examples/docs/en-US/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ If you are using CDN, a hello-world page is easy with Element. [Online Demo](htt

<iframe width="100%" height="600" src="//jsfiddle.net/hzfpyvg6/1213/embedded/html,result/" allowpaymentrequest allowfullscreen="allowfullscreen" frameborder="0"></iframe>

If you are using npm and wish to apply webpack, please continue to the next page: Quick Start.
If you are using npm and wish to apply webpack, please continue to the next page: [Quick Start](/#/en-US/component/quickstart).
2 changes: 1 addition & 1 deletion examples/docs/en-US/menu.md
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ Vertical NavMenu could be collapsed.
| default-active | index of currently active menu | string |||
| default-openeds | array that contains indexes of currently active sub-menus | Array |||
| unique-opened | whether only one sub-menu can be active | boolean || false |
| menu-trigger | how sub-menus are triggered, only works when `mode` is 'horizontal' | string | | hover |
| menu-trigger | how sub-menus are triggered, only works when `mode` is 'horizontal' | string | hover / click | hover |
| router | whether `vue-router` mode is activated. If true, index will be used as 'path' to activate the route action | boolean || false |
| collapse-transition | whether to enable the collapse transition | boolean || true |

Expand Down
Loading

0 comments on commit c978e0f

Please sign in to comment.