diff --git a/.babelrc b/.babelrc index bdb1a6b4db6..26a2fac61f1 100644 --- a/.babelrc +++ b/.babelrc @@ -1,16 +1,43 @@ { - "presets": [["es2015", { "loose": true }]], + "presets": [ + [ + "env", + { + "loose": true, + "modules": false, + "targets": { + "browsers": ["> 1%", "last 2 versions", "not ie <= 8"] + } + } + ], + "stage-2" + ], "plugins": ["transform-vue-jsx"], "env": { "utils": { + "presets": [ + [ + "env", + { + "loose": true, + "modules": "commonjs", + "targets": { + "browsers": ["> 1%", "last 2 versions", "not ie <= 8"] + } + } + ], + ], "plugins": [ ["module-resolver", { "root": ["element-ui"], "alias": { - "element-ui/src": "element-ui/lib" + "element-ui/src": "@femessage/element-ui/lib" } }] ] + }, + "test": { + "plugins": ["istanbul"] } } } diff --git a/.eslintrc b/.eslintrc index 2a84035cf0e..ad4aa56f7fb 100644 --- a/.eslintrc +++ b/.eslintrc @@ -1,10 +1,7 @@ { - "env": { - "mocha": true - }, "globals": { - "expect": true, - "sinon": true + "ga": true, + "chrome": true }, "plugins": ["html", "json"], "extends": "elemefe", @@ -12,8 +9,8 @@ "no-restricted-globals": ["error", "event", "fdescribe"] }, "parserOptions": { + "ecmaVersion": 6, "ecmaFeatures": { - "experimentalObjectRestSpread": true, "jsx": true } } diff --git a/.github/CONTRIBUTING.en-US.md b/.github/CONTRIBUTING.en-US.md index 0a8c357e640..ee651f77d43 100644 --- a/.github/CONTRIBUTING.en-US.md +++ b/.github/CONTRIBUTING.en-US.md @@ -43,6 +43,8 @@ npm run dev # open http://localhost:8085 ``` +> **Notice**: modify `examples/play/index.vue` file, use the component you contribute, then run `npm run dev:play`, go ahead [http://localhost:8085](http://localhost:8085), get result, more quickly and friendly. + To build: ```shell diff --git a/.github/CONTRIBUTING.es.md b/.github/CONTRIBUTING.es.md index 177e0ca0918..d5c6022a5ff 100644 --- a/.github/CONTRIBUTING.es.md +++ b/.github/CONTRIBUTING.es.md @@ -37,7 +37,7 @@ Estamos orgullosos de que usted esta interesado en contribuir al proyecto `Eleme - Fusión de un PR requiere dos mantenedores: el primero aprueba los cambios después de revisar, y entonces el segundo mantenedor revisa los cambios y hace la fusión. -## Requerimientos Técnicos +## Requerimientos Técnicos `Node.js 4+`, `yarn` y `npm 3+` son requisitos. Nota: Usamos yarn para bloquear versiones de dependencias, por lo que debería instalar dependencias usando `yarn` en lugar de `npm install`. . ```shell @@ -47,6 +47,8 @@ npm run dev # abra http://localhost:8085 ``` +> **Notice**: modify `examples/play/index.vue` file, use the component you contribute, then run `npm run dev:play`, go ahead [http://localhost:8085](http://localhost:8085), get result, more quickly and friendly. + Para armar: ``` diff --git a/.github/CONTRIBUTING.fr-FR.md b/.github/CONTRIBUTING.fr-FR.md new file mode 100644 index 00000000000..f8112be219d --- /dev/null +++ b/.github/CONTRIBUTING.fr-FR.md @@ -0,0 +1,60 @@ +# Guide à destination des contributeurs d'Element UI + +Bonjour! Merci d'avoir choisi Element UI. + +Element UI est une bibliothèque de composants basée sur Vue 2.0 pour les développeurs, les designers et les chefs de produits. + +Nous sommes ravis que vous souhaitiez contribuer à Element. Avant de soumettre votre contribution, veuillez vous assurer de prendre un moment pour lire les indications suivantes. + +## Concernant les issues + +- Les issues concernent exclusivement les bugs, les demandes de fonctionnalités et les sujets liés à la conception. Les questions concernant d'autres sujets peuvent être fermées directement. Si vous avez des questions à propos de l'utilisation d'Element, veuillez vous rendre sur [Gitter](https://gitter.im/element-en/Lobby) pour obtenir de l'aide. + +- Avant de soumettre une issue, veuillez vérifier si des problèmes similaires n'ont pas déjà été signalés. + +- Veuillez spécifier la version de `Element` et `Vue` que vous utilisez, et fournir des informations sur le système d'exploitation et le navigateur. [JSFiddle](https://jsfiddle.net/) est recommandé afin de construire une démo pour que votre problème puisse être reproduit clairement. + +## Concernant les pull requests + +- Faites un fork de ce dépôt vers votre compte. Ne créez pas de branches ici. + +- Les informations de validation doivent être formatées en tant que `[Nom du composant] : Info à propos de ce commit` (par exemple `Button : Fix xxx bug`) + +- **NE PAS** inclure de fichiers dans le répertoire `lib`. + +- Assurez-vous que l'exécution de `npm run dist` génère les bons fichiers. + +- Pour des raisons de compatibilité et de taille de fichier, notre configuration babel n'importait que `preset-2015`, donc les API comme `Array.prototype.find` et `Object.assign` dans `ES2015` ne sont pas recommandées. Vous pouvez importer des polyfills si nécessaire. + +- Faites un rebase avant la création d'une PR pour garder l'historique clair. + +- Assurez-vous que les PRs sont créés dans la branche `dev` au lieu de la branche `master`. + +- Si votre PR corrige un bug, veuillez fournir une description du bug en question. + +- La fusion d'un PR nécessite deux responsables: l'un approuve les modifications après révision, puis l'autre les révise et les fusionne. + +## Pré-requis +`Node.js 4+`, `yarn` et `npm 3+` sont requis. Note: nous utilisons yarn pour verrouiller les versions des dépendances, donc vous devriez installer les dépendances en utilisant `yarn` au lieu de `npm install`. +```shell +git clone git@github.com:ElemeFE/element.git +npm run dev + +# open http://localhost:8085 +``` + +> **Remarque** : modifiez le fichier `examples/play/index.vue`, utilisez le composant auquel vous contribuez, puis lancez `npm run dev:play`, allez sur [http://localhost:8085](http://localhost:8085), regardez le résultat rapidement et facilement. + +Pour le build: + +```shell +npm run dist +``` + +## Concernant le développement de composants +- Exécutez `make new ` pour créer un répertoire pour le nouveau composant. Les tests, le fichier d'entrée et la documentation sont inclus. +- Reportez-vous au `Button` pour les composants imbriqués. +- Reportez-vous à `Select` pour connaître les composants qui dépendent d'autres composants. + +## Style du code +Il suffit de se conformer à la configuration [ESLint](https://github.com/ElemeFE/eslint-config-elemefe) de [ElemeFE](https://github.com/elemefe). diff --git a/.github/CONTRIBUTING.zh-CN.md b/.github/CONTRIBUTING.zh-CN.md index ce07fd8ea03..eaeffe12d17 100644 --- a/.github/CONTRIBUTING.zh-CN.md +++ b/.github/CONTRIBUTING.zh-CN.md @@ -1,4 +1,4 @@ -# Element UI 贡献指南 +# @femessage/element-ui 贡献指南 Hi! 首先感谢你使用 Element UI。 @@ -7,7 +7,7 @@ Element UI 是一套为开发者、设计师和产品经理准备的开源组件 Element UI 的成长离不开大家的支持,如果你愿意为 Element UI 贡献代码或提供建议,请阅读以下内容。 ## Issue 规范 -- issue 仅用于提交 Bug 或 Feature 以及设计相关的内容,其它内容可能会被直接关闭。如果你在使用时产生了疑问,请到 Slack 或 [Gitter](https://gitter.im/ElemeFE/element) 里咨询。 +- issue 仅用于提交 Bug 或 Feature 以及设计相关的内容,其它内容可能会被直接关闭。 - 在提交 issue 之前,请搜索相关内容是否已被提出。 @@ -16,7 +16,15 @@ Element UI 的成长离不开大家的支持,如果你愿意为 Element UI 贡 ## Pull Request 规范 - 请先 fork 一份到自己的项目下,不要直接在仓库下建分支。 -- commit 信息要以`[组件名]: 描述信息` 的形式填写,例如 `Button: fix xxx bug`。 +- commit 信息遵循 [commitlint-config-conventional](https://github.com/conventional-changelog/commitlint/tree/master/%40commitlint/config-conventional#type-enum) + +- 修改主题请使用 `theme` 作为 commit type + +- 由于本仓库的主题会随着业务不断更新,为了防止不必要的主题样式污染。自定义主题需要根据 `only-component` 分支生成主题 + +- 于此同时,除了修改主题的 PR,其他改动请务必额外增加一个合并到 `only-component` 的 PR,保持 `only-component` 和 `master` 只有主题上的差异 + +- [具体规范链接](https://www.yuque.com/docs/share/eeff5604-1163-47c1-b979-65373b1d9467) - **不要提交** `lib` 里面打包的文件。 @@ -41,6 +49,8 @@ npm run dev # open http://localhost:8085 ``` +> **提示**:可以运行 `npm run dev:play`,修改 `examples/play/index.vue` 文件,调用你修改后的组件,仍然访问 [http://localhost:8085](http://localhost:8085),查看修改效果,更快更方便。 + 打包代码: ```shell diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 239cdb19b0a..4fc57e6d79a 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,5 +1,5 @@ Please make sure these boxes are checked before submitting your PR, thank you! -* [ ] Make sure you follow Element's contributing guide ([中文](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.zh-CN.md) | [English](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.en-US.md) | [Español](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.es.md)). +* [ ] Make sure you follow Element's contributing guide ([中文](https://github.com/femessage/element/blob/master/.github/CONTRIBUTING.zh-CN.md) | [English](https://github.com/femessage/element/blob/master/.github/CONTRIBUTING.en-US.md) | [Español](https://github.com/femessage/element/blob/master/.github/CONTRIBUTING.es.md) | [Français](https://github.com/femessage/element/blob/master/.github/CONTRIBUTING.fr-FR.md)). * [ ] Make sure you are merging your commits to `dev` branch. * [ ] Add some descriptions and refer relative issues for you PR. diff --git a/.github/stale.yml b/.github/stale.yml new file mode 100644 index 00000000000..9f728c5752c --- /dev/null +++ b/.github/stale.yml @@ -0,0 +1,17 @@ +# Number of days of inactivity before an issue becomes stale +daysUntilStale: 365 +# Number of days of inactivity before a stale issue is closed +daysUntilClose: 7 +# Issues with these labels will never be considered stale +# exemptLabels: + # - pinned + # - security +# Label to use when marking an issue as stale +staleLabel: stale +# Comment to post when marking an issue as stale. Set to `false` to disable +markComment: > + This issue has been automatically marked as stale because it has not had + recent activity. It will be closed if no further activity occurs. Thank you + for your contributions. +# Comment to post when closing a stale issue. Set to `false` to disable +closeComment: false \ No newline at end of file diff --git a/.gitignore b/.gitignore index 25e89649030..a9b3749c717 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,12 @@ node_modules .DS_Store npm-debug.log +yarn-debug.log +yarn-error.log lerna-debug.log npm-debug.log.* +yarn-debug.log.* +yarn-error.log.* lerna-debug.log.* lib .idea @@ -11,6 +15,7 @@ examples/element-ui examples/pages/en-US examples/pages/zh-CN examples/pages/es +examples/pages/fr-FR fe.element/element-ui .npmrc coverage diff --git a/.travis.yml b/.travis.yml index bac947919c8..abe7e6ce55a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,13 +1,31 @@ -sudo: false +branches: + only: + - master language: node_js -node_js: 8 -before_install: -- export CHROME_BIN=chromium-browser -- export DISPLAY=:99.0 -- sh -e /etc/init.d/xvfb start -- export TRAVIS_COMMIT_MSG="[deploy] $(git log --format='%h - %B' --no-merges -n 1)" -- export TRAVIS_COMMIT_USER="$(git log --no-merges -n 1 --format=%an)" -- export TRAVIS_COMMIT_EMAIL="$(git log --no-merges -n 1 --format=%ae)" -after_success: -- sh build/deploy-ci.sh -- cat ./test/unit/coverage/lcov.info | ./node_modules/.bin/coveralls +node_js: + - 10 +git: + depth: 30 +install: + - yarn --frozen-lockfile + - yarn lint --fix + - yarn test +script: + - yarn stdver + # deploy 和 dist 之前必须生成一些必要文件 + - yarn build:file + - yarn deploy:build + - yarn dist +cache: yarn +deploy: + - provider: pages + skip-cleanup: true + keep-history: true + local-dir: examples/element-ui + github-token: $GITHUB_TOKEN + - provider: npm + email: levy9527@qq.com + api_key: $NPM_TOKEN + skip-cleanup: true +after_script: + - ./notify.sh diff --git a/CHANGELOG.en-US.md b/CHANGELOG.en-US.md index 394ba83e86d..1bc6382d253 100644 --- a/CHANGELOG.en-US.md +++ b/CHANGELOG.en-US.md @@ -1,5 +1,903 @@ ## Changelog +### 2.13.0 + +*2019-11-26* + +#### New features + +- Popconfirm + - Add popconfirm component (#17548 by @iamkun) + +#### Bug fixes + +- BackTop + - Use cubic bezier scrolling (by @lon) +- DatePicker + - Fix bug of only select min date of date range problem (#17191 by @smk0621) +- Select + - Fix select test cases by (@msidolphin) +- Tree + - Add font-size for the style of tree empty-text (#17094 by @spengjie) +- Table + - Column header can be costumed (#17291 by @ziyoung) + - Update table header cell style (#17284 by @ziyoung) + - Fix table header height after filter (#17348 by @ziyoung) + - Fixed row-style with display not work (#17002 by @a631807682) + - Fix header table not display (#17341 by @ziyoung) +- Calendar + - Import el-button and el-button-group (#17376 by @masongzhi) +- MessageBox + - Fix icon position error (#17410 by @nullptru) +- TimePicker + - Set the selection range after scrolling up or down (#16868 by @mattheyan) +- Message + - Fix close instace offsetHeight(#17564) (#17852 by @gzwgq222) +- Form + - Callback of validateField should be optional (#17314 by @CarterLi) +- Cascader + - Fix TypeScript 3.7 compatibility (#17881 by @CarterLi) +- Menu + - Fix router NavigationDuplicated error when using vue-router@^3.1.0 (#17269 by @iamkun) +- Dropdown + - Update type file (#17550 by @iamkun) +- Progress + - Add strokeLinecap prop (#17552 by @iamkun) +- InfiniteScroll + - Skip trigger event on invisible element (#17553 by @iamkun) +- Image + - Perfect picture preview behavior (#16985 by @luckyCao) + - Fix shield the page when preview big image (#16796 by @luckyCao) +- Drawer + - Bugfix drawer-append-to-body-not-working (#16953 by @JeremyWuuuuu) +- Select + - Fix tag show value or empty issue (17199 by @luckyCao) +- Scrollbar + - Fix FireFox scroll bar width (#18091 by @iamkun) + +#### Optimization + +- I18n + - Update sv-SE.js (#17926 by @FOLLGAD) + - Update avatar component fr doc (#17762 by @blombard) +- Docs + - Fix time-select typo (#17250 by @wacky6) + - Fix Drawer attribute accepted value typo in es (#17122 by @haoranyu) + - Update Spanish changelog 2.12.0 (#17364 by @Gonzalo2310) + - Fix Changelog typo (#17874 by @renlixin) + - Fix Loading demo (#17862 by @MBearo) + - Add input event in input Events Table (#18061 by @zhouxinyong) + - Delete Input repeat change event (#18085 by @zhouxinyong) + +### 2.12.0 + +*2019-08-29* + +#### New features + +- Popover + - Add close-delay prop (#16671 by @LachlanStuart) +- Theme + - Add Chrome Extension: Element Theme Extension (#16686 by @iamkun) +- Icon + - Add font-display to @font-face declaration (#16805 by @iamfaizalandyka) + +#### Bug fixes + +- Carousel + - Fix onChange emit value (#16705 by @iamkun) +- Notification + - Fix modifying incoming option object (#16704 by @iamkun) +- DatePicker + - Add className for picker option (#16632 by @iamkun) +- DateTimePicker + - Fix time-spinner not scroll to right position (#16854 by @jesse-li) +- Table + - Prevent click handler after drag (#16850 by @ziyoung) + - Fix chrome crash when set thead css display to none (#16956 by @luckyCao) + - Fix wrong empty block height (#16861 by @ziyoung) + - Not throw error when calling toggleExpansion (#16304 by @yyjjqq94) + - Not trigger sort-change event when mounted (#17113 by @a631807682) + - Fix setCurrentRow unable to clear highlight row (#16879 by @ziyoung) + - Fix expand-row-keys not work when data is loaded asynchronously (#16899 by @ziyoung) + - set toggleAllSelection as instance property (#17137 by @ziyoung) +- Tree + - Fix distance between label and checkbox (#16799 by @Hazlank) +- Tabs + - Fix incorrect TabItem's position (#16520 by @victorting) + - Fix activated tab is out of visual range bug (#17033 by @nullptru) +- Calendar + - Fix weekdays i18n issue (#16772 by @ubitoffee) + - fix locale error (#17208 by @iamkun) +- Cascader + - Fix CascaderPanel display error (#16716 by @zhangHongEn) + - Fix disable status and close button issue (#16224 by @yyjjqq94) +- Input + - Fix Korean composition event (#15069 by @MoonHyuk) + - Fix click event of clear button not trigger when using v-loading (#16576 by @a631807682) +- Select + - Not toggle dropdown when filtering (#17205 by @luckyCao) +- Transfer + - Fix style error (#17206 by @iamkun) +- Dialog + - update sass var (#16365 by @haoranyu) +- RadioGroup + - Not produce invalid HTML in table if "is" attribute is specify (#17070 by @nullptru) +- Divider + - Support custom classes (#17078 by @island205) + +#### Optimization + +- Checkbox + - Improve screen reader experience (#16575 by @tylertrotter) +- Docs + - Update changelog (#16773 by @SimonaliaChen) + - Update contributing guide (#14800 by @sinchang) + - Fix typo in Drawer docs (#16848 by @winkay) + - Update custom theme (#16983 by @iamkun) + - Add Esperanto translation (#16955 by @maxkoryukov) + - Update input-number document about change event (#16316 by @luckyCao) + - Update spanish doc 2.11.1 (#16961 by @Gonzalo2310) +- I18n + - Remove translation of 'year' in catalan language as in the other languages (#14722 by @oscaralbareda) + - Update spanish changelog 2.10.0 and 2.10.1 (#16548 by @Gonzalo2310) + - Update ar.js (#16653 by @l3op) +- Test + - Correct spelling error (#16672 by @boomler) + - Refactor unit test to use data-uri (#16847 by @a631807682) +- Types + - Fix httprequest type (#16633 by @luckyCao) + +### 2.11.1 + +*2019-07-26* + +#### Bug fixes + +- Image + - Fix Image component SSR compatibility (#16737 by @luckyCao) +- Chore + - Update dart-sass compatibility (#16744 by @LewisChennnnn) + +### 2.11.0 + +*2019-07-25* + +#### New features + +- Drawer + - Add drawer component (#16577 by @JeremyWuuuuu) + +#### Bug fixes + +- Checkbox + - Enhance css selector (#16006 by @Hazlank) +- Tree + - Make el-tree generic (#15934 by @JeremyWuuuuu) + - Set isCurrent prop to False (#15870 by @kkkisme) +- Dropdown + - Fix split-button caret default color (#15931 by @JuniorTour) +- Cascader + - Fix level 1 children is empty update problem (#16399 by @luckyCao) + - Add sets default values when lazy is true (#16420 by @luckyCao) + - Fix display errors when node value is duplicate (#15935 by @junyiz) + - Expose getCheckedNodes and fix options change bug (#16709 by @SimonaliaChen) +- Calendar + - Display correct header when range is specified (#16354 by @ziyoung) +- Submenu + - Fix prop append-to-body (#16289 by @a631807682) +- Table + - Fix tree table when updating data (#16481 by @island205) +- Select + - Fix memory leak issue (#16463 by @island205) +- InfiniteScroll + - Update naming & doc (#16698 by @iamkun) +- Avatar + - Fix image not center vertically issue (#16489 by @luckyCao) +- Dialog + - Add destroyOnClose attribute (#16455 by @ziyoung) +- Image + - Add big Image preview feature (#16333 by @luckyCao) + +#### Optimization + +- Docs + - Fix dropdown demo (#16193 by @webxmsj) + - Fix typo in table documents (#15971 by @howiefh) +- I18n + - Update translation of Thai language (#16689 by @ponkrit) +- Chore + - Update theme base api (#16607 by @iamkun) + - Add form theme token (#16699 by @iamkun) + - Mark ali inner user's access (#16609 by @iamkun) + - Fix doc anchor bug (#16692 by @iamkun) + +### 2.10.1 + +*2019-07-02* + +#### Bug fixes + +- Table + - Fix sort icon (#15439 by @bezany) + - Fix layout breaks when append slot exists (#16332 by @ziyoung) + - Fix showOverflowTooltip not reactive (#16295 by @a631807682) + - Register scrollbar in filter-panel (#16246 by @ziyoung) +- Chore + - Fix 2.9 docs (#16233 by @ziyoung) + - Fix index page theme intro english css style issue (#16254 by @iamkun) + +#### Optimization + +- Tag + - Compatible with IE (#16334 by @ziyoung) +- Chore + - Update Dingtalk Group QR image (#16236 by @iamkun) +- Doc + - Update online theme roller doc (#16244 by @iamkun) + +### 2.10.0 + +*2019-06-25* + +#### New features + +- I18n + - Added Uzbek language (#15796 by @ogabek96) +- Calendar + - Add first-day-of-week attribute (#16047 by @ziyoung) +- Avatar + - Add avatar component (#16144 by @luckyCao) +- Upload: + - Add capability to customize thumbnail template (#13192 by @victorzhuk) + +#### Bug fixes + +- Tree + - Not highlight tree node when currentKey is null (#15668 by @yyjjqq94) + - Fix issue #15538 caused by two Tree sharing the same data (#15615 by @VanMess) +- Upload + - Update the parameter `fileList` type (#15716 by @underfin) +- Table + - Fix loading icon not display (#15868 by @ziyoung) + - Fix background color of complex table when hovering (#15504 by @cnlon) + - Fix current-row-key and select event bug (#15983 by @ziyoung) + - Height accepts more units (#16013 by @ziyoung) + - Fix reserve-selection not work (#16135 by @ziyoung) +- Docs + - Fix Divider attribute type in zh-cn (#15889 by @haoranyu) +- Menu + - Fixed submenu hidden bug after adding popper-append-to-body (#15391 by @PanJiaChen) +- Select + - Fix initialInputHeight (#15989 by @yyjjqq94) + - Fix default-first-option behavior when typing Chinese (#15431 by @VanMess) + - fix double import problem (#16215 by @lengband) +- Message + - Add type def for offset option (#16027 by @matjaz) +- Timeline + - Fix reverse broken (#16091 by @ziyoung) +- Slider + - Fix #15545 by adding explains about "input" event in Chinese (#15588 by @VanMess) +- InfiniteScroll + - Update package name (#16125 by @iamkun) +- MessageBox + - Fix  distinguishCancelAndClose action not same as docs bug (#15438 by @qingdengyue) +- PopupManager + - Fix z-index cannot be rewritten at first using (#15738 by @luckyCao) +- Docs + - Delete an incorrect closing html tag and empty block code (#16194 by @Alexeykhr) +- Chore + - Update test api host (#15807 by @iamkun) + +#### Optimization + +- Tree + - Modify loop conditions to improve performance (#15699 by @KingJeason) +- Theme + - Refine GA track & Update footer link forward to online theme roller (#16007 by @island205) +- Badge + - Update badge prop check (#16198 by @iamkun) +- Avatar + - Update theme config var (#16202 by @luckyCao) +- I18n + - Update pt-br.js (#15776 by @gigioSouza) + - Update Farsi translation (#15881 by @pamenary) +- Docs + - Add missing components in quickstart (#16063 by @pape2016) + - Update french translation (#16208 by @blombard) + - Add description $slots.default (#15444 by @Alexeykhr) + - Update Spanish Doc 2.9.1 (#15840 by @Gonzalo2310) + - Fix spelling mistakes in fr (#15837 by @blombard) + - Update changelog 2.9.2 Spanish (#16185 by @Gonzalo2310) + +#### Breaking changes + +- Form + - Remove success status (#16159 by @ziyoung) + +### 2.9.2 + +*2019-06-21* + +#### Bug fixes + +- Chore + - Fix TS definitions file (#15805 by @NateScarlet) + +### 2.9.1 + +*2019-05-30* + +#### New features + +- Table + - default-expand-all, expand-row-keys, toggle-row-expansion method and expand-change event are supported in Tree Table (#15709 by @ziyoung) + +#### Bug fixes + +- Table + - Fix some bugs (#15709 by @ziyoung) +- Theme + - Update api host (#15784 by @iamkun) + +#### Optimization + +- Chore + - Update InfiniteScroll type (#15794 by @iamkun) + +### 2.9.0 + +*2019-05-30* + +#### New features + +- Backtop + - Add Backtop component (#15541 by @iamkun) +- PageHeader + - Add PageHeader component (#15714 by @ziyoung) +- InfiniteScroll + - Add InfiniteScroll directive (#15567 by @iamkun) +- Cascader + - Add multiple mode and filter-method (#15611 by @SimonaliaChen) +- Message + - Display in stack mode (#15639 by @island205) +- Tag + - Add prop effect (#15725 by @SimonaliaChen) +- Tabs + - Left align title when type is card (#15695 by @luckyCao) +- DatePicker + - Support literal strings (#15525 by island205) +- Image + - Add support for transmit attrs and listeners (#15578 by @VanMess) +- Theme + - Add popup background (#15412 by @iamkun) +- Chore + - Update new 2.9.0 index page (#15682 by @iamkun) + +#### Bug fixes + +- Table + - Fix sort-change behaviour when sort condition is null (#15012 by @joelxr) +- Image + - Fix ssr and object-fit compatibility (#15346 by @SimonaliaChen) +- Input + - Fix show-word-count style in el-form (#15359 by @lvjiaxuan) + - Fix clear icon is not centered (#15354 by @YiiGuxing) +- Calendar + - Fix not correct day of week when the day is Sunday (#15399 by @qingdengyue) + - Fix October disappear bug (#15394 by @qingdengyue) +- Tabs + - Fix basic tab nested in card tab padding error (#15461 by @SimonaliaChen) +- Tag + - Fix stop propagation problem (#15150 by @infjer) +- Form + - Fix input-group within form-item height error (#15457 by @SimonaliaChen) + - Fix resetFields issue (15181 by @luckyCao) +- Tooltip + - Fix custom tabindex not work (#15619 by @SimonaliaChen ) +- Link + - Fix link icon style class (#15752 by @iamkun) +- Select + - Revert set value to null when cleared (#15447 by @iamkun) +- Loading + - Fix dom not change when loading state change quickly (#15123 by @FAKER-A) +- Switch + - Label with el-switch repeating event (#15178 by @FAKER-A) +- Slider + - Fix style problem when clicking slider bar(#15561 by @luckyCao) +- Radio + - Fix issue 14808 (#14809 by @OverTree) +- Form + - Fix resetFields issue (15181 by @luckyCao) +- Chore + - Upgrade dependencies and fix demo bug (#15324 by ziyoung) +- Type + - Fix loading type definition (#15635 by @iamkun) + - Fix Icon type (#15634 by @iamkun) + - Fix Link type definition (#15402 by @iamkun) + +#### Optimization + +- Cascader + - Refactor (#15611 by @SimonaliaChen) +- Chore + - Update make new component logic (by @iamkun) +- Docs + - Rename variable in docs (#15185 by @liupl) + - Fix image attribute type and default value (#15423 by @haoranyu) + - Fix form doc bug (#15228 by @SHERlocked93) + +### 2.8.2 + +*2019-04-25* + +#### Bug fixes + +- Icon + - Update icon (#15272 by @iamkun) +- Docs + - Fix Form and Input doc style (#15273 by @ziyoung) + +### 2.8.1 + +*2019-04-25* + +#### Bug fixes + +- Icon + - Update icon of cascader and select (#15264 by @SimonaliaChen) + - Update icon (#15258 #15268 by @iamkun) + +#### Optimization + +- Chore + - Update build script (#15267 by @ziyoung) +- Docs + - Fix link underline color (#15265 by @iamkun) +- Other + - Fix migrating config not compatible with camel case props and events (#15260 by @SimonaliaChen) + +### 2.8.0 + +*2019-04-25* + +#### New features + +- Divider + - Add divider component (#15055 by @island205) +- Rate + - Add custom colors and icon-classes by passing a object (#15051 by @SimonaliaChen) +- Link + - Add link component (#15052 by @iamkun) +- Calendar + - Add calendar component (#14908 by @ziyoung) +- Icon + - Add icon (#15214 by @iamkun) +- Alert + - Add dark theme (#15041 by @island205) +- Image + - Add image component (#15117 by @SimonaliaChen) +- Collapse + - CollapseItem can be disabled (#15076 by @ziyoung) +- Carousel + - Add direction attribute and support vertical direction (#15122 by @ziyoung) +- Pagination + - Add hide-on-single-page attribute (#15096 by @ziyoung) +- Slider + - Add marks attribute (#15133 by @luckyCao) +- Input + - Add show-word-count attribute (#15075 by @luckyCao) +- InputNumber + - Add step-strictly attribute (#15050 by @luckyCao) +- Tooltip, Dropdown, Popover + - Support tabindex attribute (#15167 by @ziyoung) + +#### Bug fixes + +- Notification + - Fix title word break (#15008 by @iamkun) +- Form + - Fix switching the rules in el-form not work (#14985 by @luckyCao) + - Fix label style (#14969 by @ziyoung) + - Required FormItem displays asterisk when label is auto (#15144 by @ziyoung) +- Pagination + - Fix slot not updated (#14711 by @lucyhao) +- Table + - Fix load bug in lazy mode (#15101 by @ziyoung) + - Fix cell width when colspan is grater than 1 (#15196 by @ziyoung) + - Improve performance (#14868 by @ziyoung) + - Don't emit triggers sort-change during initialization (#14625 by @PeanutWatson) + - Equal behaviour for height and max-height (#14660 by @arthurdenner) +- Dialog + - Fix dialog body correctly break long words (#15027 by @iamkun) +- Alert + - update type definition (#15186 by @ziyoung) +- Tabs + - Fix issue where Promise rejection was hitting application (#14816 by @ffxsam) + - Rerender when slot changes (#15238 by @ziyoung) +- Message + - Fix type definition (#14968 by @agoni1212) +- Select + - Fix error when value is undefined or null (#15022 by @luckyCao) +- Tree + - Delete current node after it removed (#14604 by @sinchang) + - Improve performance (#14881 by @ChenZhuoSteve) +- Dropdown + - Fix style (#14907 by @doing123) +- Slider + - Fix broken keyboard a11y bug (#14792 by @erezsob) +- Menu + - ActiveIndex value shall be null if defaultIndex does not exist(#14074 by @hoythan) +- Directive + - RepeatClick: use Date.now() instead of new Date() (#14776 by @pavelmash) +- Upload + - Fix Upload transparent picture display style (#15039 by @iamkun) +- Theme + - Add zero border (#15256 by @iamkun) + +#### Optimization + +- Chore + - Update changelog zh-cn (#14965 by @iamkun) + - Hide demo description when it's empty (#15014 by @ziyoung) + - Display dev server info by default by @iamkun) + - Fix 2.6.0 changelog error (#15026 by @iamkun) + - Update build config (#14821 by @abc3660170) + - Add hmr (#15221 by @SimonaliaChen) + - Use sourcemap in dev environment (#15087 by @ibufu) +Docs + - Rename variable in docs (#14602 #15003 #15094 #15105 by @liupl) + - Fix upload doc error (#15023 by @iamkun) + - Update Form custom validator doc (#15040 by @iamkun) + - Update Tabs docs to display vertical tabs (#15053 by @iamkun) + - Use eleme.cn as domain (#15139 by @ziyoung) + - Fix Image route name (#15194 by @iamkun) + - Remove duplicated fr translation (#15207 by @iamkun) + +#### Breaking changes + +- Rate + - Fix decimal display support in disabled mode (#15089 by @haoranyu) +- Select + - Use placeholder option label to set placeholder in filter mode (#14989 by @ibufu) + +### 2.7.2 + +*2019-04-03* + +#### Bug fixes + +- Form + - Fix auto `label-width` style (#14955 by @ziyoung) + +#### Optimization +- Docs + - Fix doc img link error (#14957 by @iamkun) +- Chore + - Fix deploy mkdir error (#14952 by @iamkun) + +### 2.7.1 + +*2019-04-03* + +#### Bug fixes + +- Select + - Set value to null when cleared (#14322 by @aaronfulkerson) +- Input + - Update DOM dependent values on type change (#14889 by @wacky6) +- Table + - Make `defaultExpandAll` works when expanded column exists (#14935 by @ziyoung) +- Dialog + - Background color can be configured (#14939 by @ziyoung) +- Form + - `label-width` supports auto width (#14944 by @ziyoung) + +#### Optimization +- Docs + - Update Spanish docs (#14913 by @Gonzalo2310) + - Add French doc for new component (#14924 by @ziyoung) + - Optimize Tabs docs (#14938 by @ziyoung) + +### 2.7.0 + +*2019-03-28* + +#### New features + +- Table + - Add support tree structure data (#14632 by @ziyoung) + +#### Bug fixes + +- Tabs + - Use primary color as boxShadow color (#14558 by @Richard-Choooou) + - Rerender when label changes (#14496 by @akki-jat) +- Table + - Footer follows body cell align (#14730 by @ziyoung) +- NavMenu + - Fix click el-submenu trigger childMenu pop again bug (#14443 by @PanJiaChen) +- Dropdown + - Make compatible with 2.6 new v-slot syntax (#14832 by @ziyoung) +- ColorPicker + - Fix handle error hex color string (#14793 by @iamkun) +- Tree + - Revert pr #13349 (#14847 by @ziyoung) +- Tooltip + - Display when initial value is true (#14826 by @ziyoung) +- Docs + - Update cascader docs (#14442 by @panhezeng) +- Style + - Fix media query in sm-only, md-only, lg-only (#14611 by @sinchang) + +#### Optimization + +- Chore + - Add webpage description (#14802 by @iamkun) + +### 2.6.3 + +*2019-03-21* + +#### Bug fixes + +- Fix Cascader demo style (#14789 by @ziyoung) +- Remove unnecessary DOM operation (#14788 by @ziyoung) +- Fix DatePicker default-value DST (#14562 by @wacky6) + +### 2.6.2 + +*2019-03-21* + +#### New features + +- DatePicker + - Add monthrange for type attribute (#14487 by @zxyRealm) +- i18n + - Add Croatian locale (#14360 by @danijelh) + +#### Bug fixes + +- Input + - Fix regression (#14572 by @wacky6) +- DatePicker + - Fix first-day-of-week computation (#14523 by @sinchang) + - Fix week picker's value-format (#13754 by @wacky6) +- Steps + - Fix issue #14502 (#14596 by @sinchang) + - Fix style with simple theme (#14610 by @sinchang) +- Docs + - Update french doc for 2.6.1 and fix typos (#14555 by @smalesys) + - Rename variable in Table docs (#14587 by @likwotsing) + - Add french search index (#14565 by @iamkun) + - Fix TimePicker page style (#14579 by @ziyoung) + - Rename variable in Upload docs (#14593 by @liupl) + - French translation update (#14643 by @smalesys) + - Update Form async validator docs (#14694 by @iamkun) + - Fix tooltip doc error (#14748 by @iamkun) + - Fix typo (#14751 by @2bj) + - Fix highlighting control elements for Webkit touch (#14703 by @VladG0r) + +#### Optimization + +- Chore + - Update ci build script (#14600 by @ziyoung) + - Update ga tracking (#14560 by @iamkun) + - Add more ga event (#14633 by @iamkun) + - Update discusion group (#14741 by @iamkun) + - Update test deps and conf (#14735 by @wacky6) + - Upgrade gulp (#14745 by @ziyoung) + - Use codepen to display demo & fix doc error (#14747 by @ziyoung) + +### 2.6.1 + +*2019-03-03* + +#### Bug fixes + +- **Don't specify node version** (by @iamkun in #14546) +- Fix doc directory in `deloy-faas.sh` (by @ziyoung in #14553) +- Fix date style issue in changelog for 2.6.0 (by @island205 in #14547) +- Fix doc typo (by @wack6 in #14552) + +### 2.6.0 + +*2019-03-01* + +#### New features +- Timeline + - Add timeline component (by @jikkai in #14248) +- DropdownItem + - Add icon prop to `el-dropdown-item` (by @gabrielboliveira in #14088) +- Input + - Add show-password props (by @phshy0607 in #13966) +- Select + - Add slot `empty` (by @elfman in #13785) +- Autocomplete + - Add highlight-first-item prop (by @YamenSharaf in #14269) +- I18n + - Created Armenian locale (by @hamletbarsamyan in #14214) +- Docs + - French translation (by @smalesys in #12153, #14418, #14434) + +#### Optimization +- Alert + - Update alert description default slot class (by @iamkun in #14488) +- Input + - Update input password (by @iamkun in #14480) +- InputNumber + - Remove unnecessary parseFloat (by @JuniorTour in #14172) +- Menu + - Add support for `el-menu-item` without index (by @georgyfarniev in #13298) +- Table + - Remove some html DOM operations (by @elfman in #13643) +- Upload + - Optimize code (by @elfman in #13973) +- Popup + - Optimize code (by @KAionro in #14413) +- Docs + - Add more detail about how to run play mode for contribution (by @island205 in #14355) + - Warn input as a controlled component (by @wacky6 in #14463) + - Update Table doc (by @luguokong in #14329) + - Update input doc (by @iamkun in #14437) + - Update custom-theme docs (by @wangguohao in #14297) + - Make the icon style change when hover on it (by @tuxinghuan in #14295) +- Build + - Minimizing css and js for Element doc site (by @iamkun in #14430) + - Speeding up webpack (by @hetech in #14484) + - Use cli to select release version (by @hetech in #14354) +- Install stale for issue handling (by @island205 in #14392) + +#### Bug fixes +- Menu + - Fix subMenu focus bug when switch browser tab (by @liupl in #13976) +- MessageBox + - Fix type definition (by @NateScarlet in #14278) +- ScrollBar + - Prevent right button click on thumb (by @xifeiwu in #14196) +- Switch + - Trigger form validation if value changes (by @hetech in #14426) +- Table + - Make toggleAllSelection method an instance method (by @letanure in #14075) +- Tabs & Dropdown + - Fix style (by @hetech in #14452) +- Tree + - Empty-text tips are different from tables (by @ColinCll in #14331) +- Docs + - Fix DatetimePicker format doc error (by @iamkun in #14290) + - Spelling issue in datepicker documentation (by @helmut in #14481) + - Fix pagination doc style (by @liuchuzhang in #14451) + +#### Breaking changes +- Table + - Fix params order of row events (by @jikkai in #12086) + +### 2.5.4 + +*2019-02-01* + +#### Bug fixes + +- Build: Fix babel config issue which lead to collapse transition broken (by @island205 in #14282) + +### 2.5.3 + +*2019-01-31* + +#### Optimization + +- Optimize code of Message (by @vok123 in #14029) +- Retire gh-pages (by @ziyoung in #14266) +- Add IssueHunt link (by @island205 in #14261) + +#### Bug fixes + +- Fix UMD module error on server side (by @island205 in #14242) +- Fix active TabBar style (by @iamkun in #14240) +- Fix Table demo code error (by @xunmeng in #14253) + +### 2.5.2 + +*2019-01-27* + +#### Optimization +- Docs: + - Update ChangeLog ES 2.5.1 (by @Gonzalo2310 in #14231) + +#### Bug fixes +- Build: + - Delete unremoved comments in umd module `lib/index.js` (by @island205 in #14233) + - Fix export error fired in commonjs module used in nuxt.js (by @island205 in #14232) + - Fix 2.5.1 build issues (by @iamkun in #14228) + +### 2.5.1 + +*2019-01-26* + +#### Optimization +- DatePicker: highlight current month and year (by @Debiancc in #14211) +- Update 2.5.0 changelog (by @wacky6 in #14217) + +#### Bug fixes +- Fix export issue generate by webpack upgrading (by @island205 in #14220) +- Keep 2.4.11 docs && new sub folder for 2.5+ (by @iamkun in #14222) + +### 2.5.0 + +*2019-01-25* + +#### New features +- DatePicker + - Add `validate-event` attribute (by @ziyoung in #13531) +- DateTimePicker + - `pickerOptions` support `selectableRange` option (by @eeeeeeeason) +- Tag + - Add `click` event (by @licdream in #14106) +- I18n + - support Kyrgyz language (by @zzjframework in #14174) + +#### Optimization +- Upgrade to webpack@4 (by @jikkai in #14173) +- Input + - Simplify implementation, follow one-way data flow. Fix several related bugs (by @wacky6 in #13471) +- Update Axure file,add new components (by @ziyoung in #13773) + +#### Bug fixes +- Autocomplete + - Fix dropdown's last line beging clipped (by @ziyoung in #13597) + - Fix missing popper arrow (by @liuchuzhang in #13762) +- Carousel + - Cleanup timer when component is destroyed (by @elfman in #13820) +- Cascader + - Remove deprecated property of computed props (by @iamkun in #13737) + - Fix CascaderOption's type definition in TypeScript (by @NateScarlet in #13613) + - Fix icon covering the text (by @ziyoung in #13596) +- Checkbox + - Refine style (by @PanJiaChen) +- DatePicker + - Add missing v-for `key` in TimeSpinner (by @Ende93 in #13547) + - Fix week highlight on year boundary (by @suyi91 in #13883) +- Input + - Fix textarea DOM node reference (by @laomu1988 @island205 in #13803) +- Pagination + - Input value won't be less than 1 (by @elfman in #13727) +- Popover + - Fix popover issues with hover trigger (by @goldengecko in #13104) + - Fix popper instance memory leak (by @qpxtWhite in #13988) +- Radio + - Refine style (by @ohhoney1) +- Table + - Enhanced table sorting when clicking on the sorting arrow (by @ohhoney1 in #12890) + - Fix empty text vertical alignment issue on IE10+ (by @imzjy in #13638) + - Fix index type documentation (by @ilovefafa in #13628) + - Fix `show-summary` display issue when multilevel header has fixed attr (by @luckyCao in #13914) +- Tabs + - Fix auto scroll bug (by @iamkun in #13696) + - Get the correct tab through tab name (by @iamkun in #13705) + - Use paneName instead of name to determine pane style (by @iamkun in #13733) +- Tree + - Fix `showCheckbox` prop on `Tree` can not affect their children `tree-node` (by @KidneyFlower) + - Update doc and definition file (by @ziyoung in #13540) +- Upload + - Add `url` prop to upload file when `list-type` changed (by @elfman in #13771) +- Slider + - Fix source code indentation (by @wacky6 in #13955) +- I18n + - Add missing Catalan translations (by @jaumesala) + - Add missing ru translation (by @justlp in #13658) + - Fix Finnish translations (by @jenkrisu in #14137) +- Doc + - Update Spanish doc 2.4.11 (by @Gonzalo2310 in #13522) +- Others + - Remove unnecessary script (by @ziyoung) + - Fix error anchor link (by @iamkun in #13753) + - Fix inconsistent capitalization in documentation (by @wonderjar) + - Add DingDing chat group qr code to readme (by @iamkun in #13957) + - Add yarn logs to .gitignore (by @mimimi in #13922) + - Remove sponsor duotai (by @island205 in #14156) + - Update readme qr code src (by @iamkun in #13960) + - Update CDN link, fix typo (by @ziyoung) + ### 2.4.11 *2018-11-21* @@ -35,7 +933,7 @@ *2018-10-26* -- The parameter of Form's `clearValidate` supports string, #12990 (by @codinglobster) +- The parameter of Form's `clearValidate` supports string, #12990 (by @codinglobster) - Added type attribute for Badge, #12991 - Users can use scoped-slot to customize table column header #13012 (by @ivanseidel) - Fixed the input box of Select unable to type text under IE, #13034 (by @GaliMU) @@ -66,17 +964,17 @@ *2018-09-14* -- Fixed DatePicker not triggering form validation, #12328 #12348 -- Fixed DatePicker throwing errors in multiple mode, #12347 +- Fixed DatePicker not triggering form validation, #12328 #12348 +- Fixed DatePicker throwing errors in multiple mode, #12347 - Fixed incorrect position of DatePicker spinner, #12415 (by @rang-ali) - Fixed automatic filling of DatePicker input box, #12521 (by @abdallanayer) - Fixed Input not highlighted in Cascader, #12341 -- Fixed wrong order of Tabpane, #12346 +- Fixed wrong order of Tabpane, #12346 - Fixed incorrect position of ColorPicker cursor, #12376 (by @cnwhy) - Fixed the style of Submenu, #2457 - Fixed not highlighted after Submenu is selected, #12479 - Fixed incorrect values selected by Cascader, #12508 (by @huangjinqiang) -- Fixed incorrect value of Pagination input box, #12525 +- Fixed incorrect value of Pagination input box, #12525 - Fixed order that Pagination triggers events, #12530 - Fixed Table Filter not displayed, #12539 - Fixed Tree unable to delete nodes, #12684 @@ -111,7 +1009,7 @@ - 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 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 @@ -188,7 +1086,7 @@ - Added `precision` attribute, #11281 - Tabs - Added `before-leave` attribute, #11259 - - Added `lazy` attribute, #11167(by @Kingwl) + - Added `lazy` attribute, #11167(by @Kingwl) - Table - Added `sort` method to manually sort the table, #11311 @@ -237,7 +1135,7 @@ - Fixed closing the DatePicker panel without changing the value incorrectly triggering the `change` event, #11017 - Fixed keyboard navigation not working properly when Select has grouped options, #11058 - Added `prefix` named slot for Select, #11063 -- Added 'clearValidate` method for FormItem, #11076 +- Added `clearValidate` method for FormItem, #11076 - Added `checkOnClickNode` attribute for Tree, #11111 ### 2.3.7 @@ -343,7 +1241,7 @@ - Pagination - Fixed `current-change` event wrongly triggering without user interaction, #10247 - DatePicker - - Now the date and time value in the dropdown panel are correctly formatted based on the `format` attribute, #10174(by @remizovvv) + - Now the date and time value in the dropdown panel are correctly formatted based on the `format` attribute, #10174(by @remizovvv) - Upload - Fixed `accept` attribute not working when `drag` is true, #10278 @@ -436,7 +1334,7 @@ - Dropdown - Fixed dropdown menu incorrect positioning when the page only has a horizontal scrollbar in some browsers, #9138 (by @banzhuanmei) - Table - - Fixed an error in calculating number of fixed columns after the column data changes, #9188(by @kolesoffac) + - Fixed an error in calculating number of fixed columns after the column data changes, #9188(by @kolesoffac) - Fixed the border of the last column of the grouped header not properly displayed, #9326 - Fixed incorrect positioning of table header in Safari, #9327 - Fixed expanded row collapsing when the table data changes, #9462 diff --git a/CHANGELOG.es.md b/CHANGELOG.es.md index 84fd0b60cb4..db7fcd6e691 100644 --- a/CHANGELOG.es.md +++ b/CHANGELOG.es.md @@ -1,11 +1,909 @@ ## Changelog +### 2.13.0 + +*2019-11-26* + +#### New features + +- Popconfirm + - Add popconfirm component (#17548 by @iamkun) + +#### Bug fixes + +- BackTop + - Use cubic bezier scrolling (by @lon) +- DatePicker + - Fix bug of only select min date of date range problem (#17191 by @smk0621) +- Select + - Fix select test cases by (@msidolphin) +- Tree + - Add font-size for the style of tree empty-text (#17094 by @spengjie) +- Table + - Column header can be costumed (#17291 by @ziyoung) + - Update table header cell style (#17284 by @ziyoung) + - Fix table header height after filter (#17348 by @ziyoung) + - Fixed row-style with display not work (#17002 by @a631807682) + - Fix header table not display (#17341 by @ziyoung) +- Calendar + - Import el-button and el-button-group (#17376 by @masongzhi) +- MessageBox + - Fix icon position error (#17410 by @nullptru) +- TimePicker + - Set the selection range after scrolling up or down (#16868 by @mattheyan) +- Message + - Fix close instace offsetHeight(#17564) (#17852 by @gzwgq222) +- Form + - Callback of validateField should be optional (#17314 by @CarterLi) +- Cascader + - Fix TypeScript 3.7 compatibility (#17881 by @CarterLi) +- Menu + - Fix router NavigationDuplicated error when using vue-router@^3.1.0 (#17269 by @iamkun) +- Dropdown + - Update type file (#17550 by @iamkun) +- Progress + - Add strokeLinecap prop (#17552 by @iamkun) +- InfiniteScroll + - Skip trigger event on invisible element (#17553 by @iamkun) +- Image + - Perfect picture preview behavior (#16985 by @luckyCao) + - Fix shield the page when preview big image (#16796 by @luckyCao) +- Drawer + - Bugfix drawer-append-to-body-not-working (#16953 by @JeremyWuuuuu) +- Select + - Fix tag show value or empty issue (17199 by @luckyCao) +- Scrollbar + - Fix FireFox scroll bar width (#18091 by @iamkun) + +#### Optimization + +- I18n + - Update sv-SE.js (#17926 by @FOLLGAD) + - Update avatar component fr doc (#17762 by @blombard) +- Docs + - Fix time-select typo (#17250 by @wacky6) + - Fix Drawer attribute accepted value typo in es (#17122 by @haoranyu) + - Update Spanish changelog 2.12.0 (#17364 by @Gonzalo2310) + - Fix Changelog typo (#17874 by @renlixin) + - Fix Loading demo (#17862 by @MBearo) + - Add input event in input Events Table (#18061 by @zhouxinyong) + - Delete Input repeat change event (#18085 by @zhouxinyong) + +### 2.12.0 + +*2019-08-29* + +#### Nuevas características + +- Popover + - Agregada la prop close-delay (#16671 by @LachlanStuart) +- Theme + - Añadida la extensión Chrome: Element Theme Extensión (#16686 by @iamkun) +- Icon + - Añadido font-display a la declaración @font-face (#16805 by @iamfaizalandyka) + +#### Corrección de errores + +- Carousel + - Corregido el valor emitido por onChange (#16705 by @iamkun) +- Notification + - Corrección de la modificación del objeto de opción entrante (#16704 by @iamkun) +- DatePicker + - Agregado el className para la opción picker (#16632 by @iamkun) +- DateTimePicker + - Corrección del time-spinner que no se desplazaba a la posición correcta (#16854 by @jesse-li) +- Table + - Evitar la propagación del click después del arrastre (#16850 by @ziyoung) + - Corregido una error en chrome que se producía cuando el css de thead tenia display: none (#16956 by @luckyCao) + - Corregida la altura incorrecta de los bloques vacíos (#16861 by @ziyoung) + - No hay lanzamiento de error cuando se llama a toggleExpansion (#16304 by @yyjjqq94) + - No se lanza el evento sort-change cuando esta montado (#17113 by @a631807682) + - Corregido que el setCurrentRow no borraba la linea resaltada (#16879 by @ziyoung) + - Corregido que expand-row-keys no funcionaba cuando los datos eran cargados asincrónicamente (#16899 by @ziyoung) + - Establecido toggleAllSelection como propiedad instanciada (#17137 by @ziyoung) +- Tree + - Corregida la distancia entre label y checkbox (#16799 by @Hazlank) +- Tabs + - Corregida la posición incorrecta de los item's del Tab (#16520 by @victorting) + - Corregido el error de que la pestaña activada estaba fuera del rango visual (#17033 by @nullptru) +- Calendar + - Arreglado el problema de los días de la semana con i18n (#16772 by @ubitoffee) + - Corregido el error de localización (#17208 by @iamkun) +- Cascader + - Corregido un error de visualización del CascaderPanel (#16716 by @zhangHongEn) + - Corregido el problema de disable status y close button (#16224 by @yyjjqq94) +- Input + - Arreglado el evento de composición coreana (#15069 by @MoonHyuk) + - Arreglado el evento click del botón clear que no se lanzaba cuando se usaba v-loading (#16576 by @a631807682) +- Select + - No cambiaba el dropdown cuando se filtraba (#17205 by @luckyCao) +- Transfer + - Arreglado un error de estilo (#17206 by @iamkun) +- Dialog + - Actualizada las variables Sass (#16365 by @haoranyu) +- RadioGroup + - No produce HTML invalido en la tabla si el atributo 'is' es especificado (#17070 by @nullptru) +- Divider + - Soporta clases personalizadas (#17078 by @island205) + +#### Optimización + +- Checkbox + - Mejorada la experiencia del lector de pantalla (#16575 by @tylertrotter) +- Docs + - Actualizado changelog (#16773 by @SimonaliaChen) + - Actualizada la guía de contribución (#14800 by @sinchang) + - Arreglado typo en la documentación de Drawer (#16848 by @winkay) + - Actualizado el tema personalizado (#16983 by @iamkun) + - Agregada traducción en Esperanto (#16955 by @maxkoryukov) + - Actualizada la documentación de input-number sobre el evento change (#16316 by @luckyCao) + - Actualizada la documentación en Español 2.11.1 (#16961 by @Gonzalo2310) +- I18n + - Eliminada la traducción de 'year' en idioma Catalán como en otros idiomas (#14722 by @oscaralbareda) + - Actualizado el changelog de las versiones 2.10.0 y 2.10.1 en Español (#16548 by @Gonzalo2310) + - Actualizado ar.js (#16653 by @l3op) +- Test + - Corregir error ortográfico (#16672 by @boomler) + - Refractorizacion del unit test para usar data-uri (#16847 by @a631807682) +- Types + - Corrección del tipo httprequest (#16633 by @luckyCao) + +### 2.11.1 + +*2019-07-26* + +#### Corrección de errores + +- Image + - Corregido el componente Image para compatibilidad SSR (#16737 by @luckyCao) +- Tarea + - Actualizado para compatibilidad con dart-sass by @LewisChennnnn) + +### 2.11.0 + +*2019-07-25* + +#### Nuevas características + +- Drawer + - Agregado componente drawer (#16577 by @JeremyWuuuuu) + +#### Corrección de errores + +- Checkbox + - Mejora del selector css (#16006 by @Hazlank) +- Tree + - Establecido el el-tree como genérico (#15934 by @JeremyWuuuuu) + - Establecido la prop isCurrent como False (#15870 by @kkkisme) +- Dropdown + - Corregido el color predeterminado de los split-button (#15931 by @JuniorTour) +- Cascader + - Corregido un problema de actualización cuando el nivel 1 de children estaba vació (#16399 by @luckyCao) + - Ahora se muestra correctamente header cuando range esta especificado (#16354 by @ziyoung) + - Agregados valores por defecto cuando lazy es true (#16420 by @luckyCao) + - Solucionado problemas de visualización (#15935 by @junyiz) + - Expuestos los getCheckedNodes y corrección de errores en el cambio de opciones (#16709 by @SimonaliaChen) +- Submenu + - Corregida la prop append-to-body (#16289 by @a631807682) +- Table + - Arreglado un fallo en la actualizacion de los datos de tree table (#16481 by @island205) +- Select + - Arreglado un problema de fuga de memoria (#16463 by @island205) +- InfiniteScroll + - Actualizada la nomenclatura y la documentacion (#16698 by @iamkun) +- Avatar + - Arreglado que la imagen no se centraba verticalmente (#16489 by @luckyCao) +- Dialog + - Agregado el atributo destroyOnClosee (#16455 by @ziyoung) +- Image + - Agregada la función de vista previa grande de imágenes (#16333 by @luckyCao) + +#### Optimización + +- Documentación + - Arreglada la demo de dropdown (#16193 by @webxmsj) + - Corrección de errores tipográficos en las tablas de documentos (#15971 by @howiefh) +- I18n + - Actualizada la traduccion del lenguage Thai (#16689 by @ponkrit) +- Tareas + - Actualizada la api base del tema (#16607 by @iamkun) + - Añadido token del formulario del tema (#16699 by @iamkun) + - Marcar todos los accesos internos del usuario (#16609 by @iamkun) + - Corrección del error de anclaje del documento (#16692 by @iamkun) + +### 2.10.1 + +*2019-07-02* + +#### Corrección de errores + + +- Table + - Corregido el icono de ordenación (#15439 by @bezany) + - Corregidas las rupturas del layout cuando existía un slot (#16332 by @ziyoung) + - Corregido showOverflowTooltip no era reactivo (#16295 by @a631807682) + - Registrada la scrollbar en el panel de filtro (#16246 by @ziyoung) +- Tareas + - Arreglada la documentación 2.9 (#16233 by @ziyoung) + - Corregido el índice de la página de introducción del tema en inglés que tenia un error en los estilos css (#16254 by @iamkun) + +#### Optimización + +- Tag + - Compatible con IE (#16334 by @ziyoung) +- Tarea + - Actualizada la imagen QR de Dingtalk Group (#16236 by @iamkun) +- Doc + - Actualizada la documentación online del theme roller (#16244 by @iamkun) + +### 2.10.0 + +*2019-06-25* + +#### Nuevas características + +- I18n + - Añadido idioma Uzbeko (#15796 by @ogabek96) +- Calendar + - Añadido el atributo del primer día de la semana (#16047 by @ziyoung) +- Avatar + - Agregado componente Avatar (#16144 by @luckyCao) +- Upload: + - Añade capacidad para personalizar la plantilla de miniaturas (#13192 by @victorzhuk) + +#### Corrección de errores + +- Tree + - No resaltar el nodo de árbol cuando currentKey es nulo (#15668 by @yyjjqq94) + - Solucionado el problema #15538 causado por dos Tree que compartian los mismos datos.(#15615 by @VanMess) +- Upload + - Actualizado el tipo del parámetro `fileList` (#15716 by @underfin) +- Table + - Solucionado que el icono de loading no se mostraba (#15868 by @ziyoung) + - Corregido el color de fondo de una tabla compleja cuando se desplaza el cursor (#15504 by @cnlon) + - Corregido current-row-key y el bug del evento select (#15983 by @ziyoung) + - Height acepta más unidades (#16013 by @ziyoung) + - Solucionado reserve-selection no funcionaba (#16135 by @ziyoung) +- Docs + - Corregido el tipo de atributo Divider en zh-cn (#15889 by @haoranyu) + - Se elimina una etiqueta html de cierre incorrecta y el código de bloque vacío (#16194 por @Alexeykhr) +- Menu + - Corregido un error oculto en el submenú después de añadir popper-append-to-body (#15391 by @PanJiaChen) +- Select + - Arreglado initialInputHeight (#15989 by @yyjjqq94) + - Corregido el comportamiento de default-first-option cuando se escribe chino (#15431 by @VanMess) + - Corregido el problema de importación doble (#16215 by @lengband) +- Message + - Añadida la opción type def para offset (#16027 by @matjaz) +- Timeline + - Arreglado reverso roto (#16091 by @ziyoung) +- Slider + - Corregido #15545 agregando explicaciones sobre el evento "input" en chino (#15588 by @VanMess) +- InfiniteScroll + - Actualización del nombre del paquete (#16125 by @iamkun) +- MessageBox + - Arreglado el bug de distinguishCancelAndClose, la acción no era la misma que la documentada (#15438 by @qingdengyue) +- PopupManager + - Arreglado que el z-index no podía ser reescrito la primera vez que se usaba (#15738 by @luckyCao) +- Tarea + - Actualizado el test del api host (#15807 by @iamkun) + +#### Optimizacion + +- Tree + - Modificar las condiciones del bucle para mejorar el rendimiento (#15699 by @KingJeason) +- Theme + - Refinado GA track & actualizado el link del pie que lleva al theme roller online (#16007 by @island205) +- Badge + - Actualizado el check del prop badge (#16198 by @iamkun) +- Avatar + - Actualizado el var del config del theme (#16202 by @luckyCao) +- I18n + - Actualizada la traducción del portugués (#15776 by @gigioSouza) + - Actualizada la traducción del idioma Farsi (#15881 by @pamenary) +- Docs + - Agregado componentes faltantes en el quick start (#16063 by @pape2016) + - Actualizada la traducción al francés (#16208 by @blombard) + - Agregada descripción $slots.default (#15444 by @Alexeykhr) + - Actualizada la Doc en Español 2.9.1 (#15840 by @Gonzalo2310) + - Corrección de errores ortográficos en fr (#15837 by @blombard) + - Actualizado el changelog 2.9.2 en español (#16185 by @Gonzalo2310) + +#### Breaking changes + +- Form + - Eliminado el estado success (#16159 by @ziyoung) + +### 2.9.2 + +*2019-06-21* + +#### Corrección de errores + +- Tareas + - Solucionadas las definiciones de archivos TS (#15805 by @NateScarlet) + +### 2.9.1 + +*2019-05-30* + +#### Nuevas características + +- Table + - Los metodos tree-props,default-expand-all, expand-row-keys, toggle-row-expansion y el evento expand-change son compatibles con Tree Table (#15709 by @ziyoung) + +#### Corrección de errores + +- Table + - Corrección de algunos errores (#15709 by @ziyoung) +- Theme + - Actualización del host de la api (#15784 by @iamkun) + +#### Optimización + +- Tarea + - Una actualización del tipo InfiniteScroll (#15794 by @iamkun) + +### 2.9.0 + +*2019-05-30* + +#### Nuevas características + +- Backtop + - Añadido componente Backtop (#15541 by @iamkun) +- PageHeader + - Añadido el componente PageHeader (#15714 by @ziyoung) +- InfiniteScroll + - Añadida la directiva InfiniteScroll (#15567 by @iamkun) +- Cascader + - Agregado modo múltiple y método de filtro (#15611 by @SimonaliaChen) +- Message + - Visualización en modo stack (#15639 by @island205) +- Tag + - Añadido prop effect (#15725 by @SimonaliaChen) +- Tabs + - Alinea el título a la izquierda cuando el tipo es card (#15695 by @luckyCao) +- DatePicker + - Soporta cadenas literales (#15525 by island205) +- Image + - Añadido soporte para transmitir attrs y listeners (#15578 by @VanMess) +- Theme + - Añadido fondo al popup (#15412 by @iamkun) +- Tarea + - Actualizada la nueva página de índice 2.9.0 (#15682 by @iamkun) + +#### Corrección de errores + +- Table + - Corregido el comportamiento de cambio de orden cuando la condición de orden es nula (#15012 by @joelxr) +- Image + - Corregido ssr y compatibilidad de ajuste de objetos (#15346 by @SimonaliaChen) +- Input + - Corregido estilo show-word-count en el-form (#15359 by @lvjiaxuan) + - Corregido el icono de borrar que no estaba centrado (#15354 by @YiiGuxing) +- Calendar + - Corregido día de la semana no correcto cuando el día es domingo (#15399 by @qingdengyue) + - Corregido error de desaparición de octubre (#15394 by @qingdengyue) +- Tabs + - Corrección de la pestaña básica anidada en el error de relleno de la pestaña de la tarjeta (#15461 by @SimonaliaChen) +- Tag + - Corregido problema de propagación de stop (#15150 by @infjer) +- Form + - Corregido el error de grupo de entrada dentro de la altura del elemento de formulario (#15457 by @SimonaliaChen) + - Solucionado el problema de resetFields (15181 by @luckyCao) +- Tooltip + - Corregido tabindex personalizado no funcionaba (#15619 by @SimonaliaChen ) +- Link + - Arreglada la clase de estilo del icono de enlace (#15752 by @iamkun) +- Select + - Revertir el valor establecido a nulo cuando se borra (#15447 by @iamkun) +- Loading + - Corregido dom no cambia cuando el estado de carga cambia rápidamente (#15123 by @FAKER-A) +- Switch + - Etiqueta con el evento de repetición del interruptor (#15178 by @FAKER-A) +- Slider + - Arreglado el problema de estilo al hacer clic en la barra deslizante (#15561 by @luckyCao) +- Radio + - Solucionado el problema 14808 (#14809 by @OverTree) +- Form + - Solucionado el problema de resetFields (15181 by @luckyCao) +- Tarea + - Se actualizaron las dependencias y se corrigió el error de demostración (#15324 by ziyoung) + - Type + - Corregida la definición del tipo de carga (#15635 by @iamkun) + - Corregido tipo Icono (#15634 by @iamkun) + - Corregida la definición del tipo de enlace (#15402 by @iamkun) + +#### Optimización + +- Cascader + - Refractorización (#15611 by @SimonaliaChen) +- Tarea + - Actualización hacer nueva lógica de componentes (by @iamkun) +- Documentación + - Renombrar variable en docs (#15185 by @liupl) + - Corregido el atributo type de imagen y el valor por defecto (#15423 by @haoranyu) + - Corregido error en la doc de form (#15228 by @SHERlocked93) + +### 2.8.2 + +*2019-04-25* + +#### Corrección de errores + +- Icon + - Actualizado icon (#15272 by @iamkun) +- Docs + - Arreglada la documentacion de Form e Input (#15273 by @ziyoung) + +### 2.8.1 + +*2019-04-25* + +#### Corrección de errores + +- Icon + - Actualizado el icono de cascader y select (#15264 by @SimonaliaChen) + - Actualizado icon (#15258 #15268 by @iamkun) + +#### Optimización + +- Chore + - Actualizado build script (#15267 by @ziyoung) +- Docs + - Arreglado el color underline de link (#15265 by @iamkun) +- Other + - Arreglada la migracion de la configuracion no compatible con camel case props y eventos (#15260 by @SimonaliaChen) + +### 2.8.0 + +*2019-04-25* + +#### Nuevas características + +- Divider + - Agregado el componente Divider (#15055 by @island205) +- Rate + - Agregados colores personalizados y clases de iconos pasando un objeto (#15051 by @SimonaliaChen) +- Link + - Agregado componente Link (#15052 by @iamkun) +- Calendar + - Agregado el componente Calendar (#14908 by @ziyoung) +- Icon + - Agregado Icon (#15214 by @iamkun) +- Alert + - Agregado tema dark (#15041 by @island205) +- Image + - Agregado componente image (#15117 by @SimonaliaChen) +- Collapse + - CollapseItem puede ser disabled (#15076 by @ziyoung) +- Carousel + - Agregado atributo direction y soporte para la direccion vertical (#15122 by @ziyoung) +- Pagination + - Agregado atributo hide-on-single-page (#15096 by @ziyoung) +- Slider + - Agregado atributo marks (#15133 by @luckyCao) +- Input + - Agregado attributo show-word-count (#15075 by @luckyCao) +- InputNumber + - Agregado atributo step-strictly (#15050 by @luckyCao) +- Tooltip, Dropdown, Popover + - Soporte para el atributo tabindex (#15167 by @ziyoung) + +#### Corrección de errores + +- Notification + - Arreglado el word break del titulo (#15008 by @iamkun) +- Form + - Arreglado que cuando se cambiaban las reglas en el-form no funcionaba (#14985 by @luckyCao) + - Arreglado el estilo del label (#14969 by @ziyoung) + - Los FormItem requeridos muestran astericos cuando el label es auto (#15144 by @ziyoung) +- Pagination + - Arreglado que el slot no se actualizaba (#14711 by @lucyhao) +- Table + - Arreglado un bug del load en el modo lazy (#15101 by @ziyoung) + - Arreglado el ancho de la celda cuando colspan es mayor que 1 (#15196 by @ziyoung) + - Mejora en el rendimiento (#14868 by @ziyoung) + - No se emiten disparadores del evento sort-change durante la inicializacion (#14625 by @PeanutWatson) + - Igual comportamiento para height y max-height (#14660 by @arthurdenner) +- Dialog + - Arreglado que el cuerpo del dialog quiebre las palabras correctamente en las palabras largas (#15027 by @iamkun) +- Alert + - Actualizada la definicion de type (#15186 by @ziyoung) +- Tabs + - Solucionado el problema por el que el rechazo de la promesa estaba afectando a la aplicación (#14816 by @ffxsam) + - Rerender cuando hay cambios en el slot (#15238 by @ziyoung) +- Message + - Actualizada la definicion de type (#14968 by @agoni1212) +- Select + - Solucionado el error cuando value es undefined o null (#15022 by @luckyCao) +- Tree + - Eliminar el nodo actual despues de removido (#14604 by @sinchang) + - Mejora en el rendimiento (#14881 by @ChenZhuoSteve) +- Dropdown + - Estilo arreglado (#14907 by @doing123) +- Slider + - Corrección de un fallo en el teclado a11y (#14792 by @erezsob) +- Menu + - El valor de ActiveIndex será nulo si el defaultIndex no existe (#14074 by @hoythan) +- Directive + - RepeatClick: usa Date.now() en lugar de new Date() (#14776 by @pavelmash) +- Upload + - Arreglado el estilo para mostrar imagenes transparentes (#15039 by @iamkun) +- Theme + - Agregado zero border (#15256 by @iamkun) + +#### Optimización + +- Tareas + - Actualizado changelog zh-cn (#14965 by @iamkun) + + - Ocultar la descripcion de la demo cuando esta vacia (#15014 by @ziyoung) + + - Muestra la info dev del server por defecto @iamkun) + + - Arreglado un error del changelog v2.6.0 (#15026 by @iamkun) + + - Actualizado build config (#14821 by @abc3660170) + + - Agregado hmr (#15221 by @SimonaliaChen) + + - Uso de sourcemap en entorno dev (#15087 by @ibufu) Docs + + - Cambio de nombre de variable en docs (#14602 #15003 #15094 #15105 by @liupl) + + - Arreglado un error en la documentacion de upload (#15023 by @iamkun) + + - Actualizada la documentacion del custom validator del Form (#15040 by @iamkun) + + - Actualizada la documentacion de Tabs de como mostrar tabs verticales (#15053 by @iamkun) + + - Uso del dominio eleme.cn (#15139 by @ziyoung) + + - Arreglado el nombre de la ruta de imágenes (#15194 by @iamkun) + + - Eliminada la traducción duplicada en francés (#15207 by @iamkun) + + + +#### Breaking changes + +- Rate + - Arreglado Fix decimal display support in disabled mode (#15089 by @haoranyu) +- Select + - Se usa la opcion placeholder del label para poner el placeholder en el modo filter (#14989 by @ibufu) + +### 2.7.2 + +*2019-04-03* + +#### Corrección de errores + +- Form + - Arreglado el estilo auto `label-width` (#14955 by @ziyoung) + +#### Optimización +- Docs + - Arreglado un error de link de una imagen (#14957 by @iamkun) +- Chore + - Arreglado un error de mkdir en el deploy (#14952 by @iamkun) + +### 2.7.1 + +*2019-04-03* + +#### Corrección de errores + +- Select + - Se asigna null a value cuando se limpia (#14322 by @aaronfulkerson) +- Input + - Actualiza los valores dependientes en el DOM cuando el tipo cambia (#14889 by @wacky6) +- Table + - Hacer que defaultExpandAll funcione cuando exista una columna expandida (#14935 by @ziyoung) +- Dialog + - El color de fondo puede ser configurado (#14939 by @ziyoung) +- Form + - `label-width` soporta auto width (#14944 by @ziyoung) + +#### Optimización +- Docs + - Actualización de la documentación en español (#14913 by @Gonzalo2310) + - Agregada documentación en francés para el nuevo componente (#14924 by @ziyoung) + - Documentación de los Tabs optimizada (#14938 by @ziyoung) + +### 2.7.0 + +*2019-03-28* + +#### Nuevas características + +- Table + - Agregado soporte de datos con estructura tree (#14632 by @ziyoung) + +#### Corrección de errores + +- Tabs + - Uso de color primario como boxShadow color (#14558 by @Richard-Choooou) + - Renderización cuando cambia la etiqueta (#14496 by @akki-jat) +- Table + - El pie de página sigue la alineación de las celdas del body (#14730 by @ziyoung) +- NavMenu + - Se ha corregido que al hacer click en el el-submenu se disparaba childMenu nuevamente (#14443 by @PanJiaChen) +- Dropdown + - Compatible con la nueva sintaxis de v-slot en V 2.6 (#14832 by @ziyoung) +- ColorPicker + - Corregido el manejo de error de string en hex color (#14793 by @iamkun) +- Tree + - Revertido pr #13349 (#14847 by @ziyoung) +- Tooltip + - Muestra cuando el valor inicial es verdadero (#14826 by @ziyoung) +- Docs + - Actualización de documentos de cascader (#14442 by @panhezeng) +- Style + - Corrección de la media query en sm-only, md-only, lg-only (#14611 by @sinchang) + +#### Optimización + +- Chore + - Añadido descripción de la página web (#14802 by @iamkun) + +### 2.6.3 + +*2019-03-21* + +#### Corrección de errores + +- Corrección del estilo de demostración de Cascader (#14789 by @ziyoung) +- Eliminación de la operación DOM innecesaria (#14788 by @ziyoung) +- Corrección del valor predeterminado del DST de DatePicker (#14562 by @wacky6) + +### 2.6.2 + +*2019-03-21* + +#### Nuevas características + +- DatePicker + - Añadido monthrange para el atributo type (#14487 by @zxyRealm) +- i18n + - Añadido Locale Croata (#14360 by @danijelh) +- Docs + - Actualización del documento en francés para 2.6.1 y corrección de errores tipográficos (#14555 by @smalesys) + - Actualización de la traducción al francés (#14643 by @smalesys) + +#### Corrección de errores + +- Input + - Corregida regresión (#14572 by @wacky6) +- DatePicker + - Corrección del cálculo del primer día de la semana (#14523 by @sinchang) + - Corregido el formato de valor del selector de semana (#13754 by @wacky6) +- Steps + - Corregida issue #14502 (#14596 by @sinchang) + - Arreglado estilo con tema simple (#14610 by @sinchang) +- Docs + - Renombrada variable en documentos de Table (#14587 by @likwotsing) + - Añadido índice de búsqueda en francés (#14565 by @iamkun) + - Corrección del estilo de página TimePicker (#14579 by @ziyoung) + - Renombrada variable en Upload docs (#14593 by @liupl) + - Actualización de los documentos del Form async validator (#14694 by @iamkun) + - Solucionado el error de tooltip doc (#14748 by @iamkun) + - Corregido error tipográfico (#14751 by @2bj) + - Corregido los elementos de control de resaltado para Webkit touch (#14703 by @VladG0r) + + +#### Optimización + +- Chore + - Actualización del script de construcción de ci (#14600 by @ziyoung) + - Actualización ga tracking (#14560 por @iamkun) + - Añadido más evento ga (#14633 by @iamkun) + - Actualización del grupo de discusión (#14741 por @iamkun) + - Actualización de los deps y conf de las pruebas (#14735 by @wacky6) + - Actualización gulp (#14745 by @ziyoung) + - Uso de codepen para mostrar la demo y corregir el error doc (#14747 por @ziyoung) + +### 2.6.1 + +*2019-03-03* + +#### Corrección de errores + +- **Don't specify node version** (by @iamkun in #14546) +- Corrección del directorio doc en `deloy-faas.sh` (by @ziyoung in #14553) +- Arreglado el estilo de date en changelog para 2.6.0 (by @island205 in #14547) +- Corregido error tipográfico en doc (by @wack6 in #14552) + +### 2.6.0 + +*2019-03-01* + +#### Nuevas características +- Timeline + - Agregado componente timeline (by @jikkai in #14248) +- DropdownItem + - Añadida la prop icon a `el-dropdown-item` (by @gabrielboliveira in #14088) +- Input + - Añadida la prop show-password (by @phshy0607 in #13966) +- Select + - Añadido el slot `empty` (by @elfman in #13785) +- Autocomplete + - Añadida la prop highlight-first-item (by @YamenSharaf in #14269) +- I18n + - Locale Armenio creado (by @hamletbarsamyan in #14214) +- Docs + - Traducción al francés (by @smalesys in #12153, #14418, #14434) + +#### Optimización +- Alert + - Actualizada la descripción de Alert (by @iamkun in #14488) +- Input + - Actualizado input password (by @iamkun in #14480) +- InputNumber + - Removido parseFloat innecesario (by @JuniorTour in #14172) +- Menu + - Añadido soporte para `el-menu-item` sin índice (by @georgyfarniev in #13298) +- Table + - Eliminadas algunas operaciones DOM html (by @elfman in #13643) +- Upload + - Optimizado el código (by @elfman in #13973) +- Popup + - Optimizado el código (by @KAionro in #14413) +- Docs + - Se han agregado más detalles sobre cómo ejecutar el modo de play para contribuir (by @island205 in #14355) + - Warn input como componente de control. (by @wacky6 in #14463) + - Actualizacion de la documentacion de Table (by @luguokong in #14329) + - Actualizacion de la documentacion de input (by @iamkun in #14437) + - Actualizacion de la documentacion de custom-theme (by @wangguohao in #14297) + - Se ha hecho que el icono cambie de estilo en hover (by @tuxinghuan in #14295) +- Build + - Minimización de css y js para la doc del sitio de Element (by @iamkun in #14430) + - Aceleración de webpack (by @hetech in #14484) + - Uso de cli para seleccionar la versión de lanzamiento (by @hetech in #14354) +- Instalación de stale para el manejo de issues (by @island205 in #14392) + +#### Corrección de errores +- Menu + - Corregido el error de focus del submenú cuando se cambiaba la pestaña del navegador (by @liupl in #13976) +- MessageBox + - Corregida la definicion de type (by @NateScarlet in #14278) +- ScrollBar + - Prevenido el clic del botón derecho en la miniatura (by @xifeiwu in #14196) +- Switch + - Activación de la validación de formularios si el valor cambia (by @hetech in #14426) +- Table + - Se ha convertido el método toggleAllSelection en un método de instancia (by @letanure in #14075) +- Tabs & Dropdown + - Estilo arreglado (by @hetech in #14452) +- Tree + - Los tips de texto vacío son diferentes de las tablas (by @ColinCll in #14331) +- Docs + - Corregido el error de formato de la documentacion de DatetimePicker (by @iamkun in #14290) + - Problema de ortografía en la documentación de datepicker (by @helmut in #14481) + - Arreglado estilo doc de paginación (by @liuchuzhang in #14451) + +#### Breaking changes +- Table + - Cambiar el orden de los parámetros enviados en los eventos de las filas (by @jikkai in #12086) + +### 2.5.4 + +*2019-02-01* + +#### Corrección de errores + +- Build: Se ha solucionado el problema de configuración de babel que provocaba que el efecto de transicion de collpase se rompiera (por @island205 en #14282) + +### 2.5.3 + +*2019-01-31* + +#### Optimización + +- Optimización del código de Message (por @vok123 en #14029) +- Retirada de gh-pages (por @ziyoung en #14266) +- Añadido enlace IssueHunt (por @island205 en #14261) + +#### Corrección de errores + +- Corregido el error del módulo UMD en el lado del servidor (por @island205 en #14242) +- Corregido el estilo activo de TabBar (por @iamkun en #14240) +- Corregido el error de código de demo de la tabla (por @xunmeng en #14253) + + +### 2.5.2 + +*2019-01-27* + +#### Optimización +- Docs: + - Actualizacion ChangeLog ES 2.5.1 (by @Gonzalo2310 in #14231) + +#### Corrección de errores +- Build: + - Eliminar comentarios no borrados en el módulo umd `lib/index.js` (por @island205 en #14233) + - Corregido el error de exportación disparado en el módulo commonjs usado en nuxt.js (por @island205 en #14232) + - Corrección de problemas de compilación de 2.5.1 (por @iamkun en #14228) + +### 2.5.1 + +*2019-01-26* + +#### Optimización +- DatePicker: resalta el mes y año actual (por @Debiancc en #14211) +- Actualizacion del changelog 2.5.0 (por @wacky6 en #14217) + +#### Corrección de errores +- Arreglado el problema de exportación generado por la actualización de webpack (por @island205 en #14220) +- Guardados los documentos 2.4.11 y la nueva subcarpeta para 2.5+ (por @iamkun en #14222) + +### 2.5.0 + +*2019-01-25* + +#### Corrección de errores +- Autocompletar + - Corregida la última línea del menú desplegable que comenzaba recortada (#13597) (por @ziyoung) + - Arreglada la popper arrow que faltaba (#13762) (por @liuchuzhang) +- Carrusel + - Contador de limpieza cuando el componente es destruido (#13820) (por @elfman) +- Cascader + - Retirada de los props computados obsoletos (#13737) (por @iamkun) + - Se corrigió la definición de tipo de las opciónes de Cascader en TypeScript (#13613) (por @NateScarlet) + - Corregido icono que cubre el texto (#13596) (por @ziyoung) +- Checkbox + - Refinado el estilo (por @PanJiaChen) +- DatePicker + - Añade el `key` en v-for de TimeSpinner (#13547) (por @Ende93) + - Corregido el resaltado de la semana en el límite del año (#13883) (por @suyi91) +- Input + - Corregida la referencia del nodo DOM del textarea (#13803) (por @laomu1988 @island205) +- Pagination + - El valor de entrada no será menor que 1 (#13727) (por @elfman) +- Popover + - Corrección de problemas de popover con el disparador de hover (#13104) (por @goldengecko) + - Corregido el fallo de memoria de instancia de popper (#13988) (por @qpxtWhite) +- Radio + - Refinado el estilo (por @ohhoney1) +- Table + - Mejorada la ordenación de tablas al hacer clic en la flecha de ordenación (#12890) (por @ohhoney1) + - Solucionado el problema de alineación vertical de texto vacío en IE10+ (#13638) (por @imzjjy) + - Corregida la documentación del tipo de índice (#13628) (por @ilovefafa) + - Corrección del problema de visualización de `show-summary` cuando el encabezado multinivel tiene el attr fixed (#13914) (por @luckyCao) +- Tabs + - Corregido error de autodesplazamiento (#13696) (por @iamkun) + - Obtener la tab correcta a través del nombre de tab (#13705) (por @iamkun) + - Uso de paneName en lugar de name para determinar el estilo del panel (#13733) (por @iamkun) +- Tree + - Corregido que `showCheckbox` prop en `Tree` no puede afectar a los hijos `tree-node` (por @KidneyFlower) + - Actualizado documento y archivo de definición (#13540) (por @ziyoung) +- Upload + - Agregada la prop `url` para subir el archivo cuando `list-type` cambia (#13771) (por @elfman) +- Slider + - Corrección de la sangría del código fuente (#13955) (por @wacky6) +- I18n + - Añadidas las traducciones de catalán que faltaban (por @jaumesala) + - Añadidas las traducciónes de ruso que faltaban (#13658) (por @justlp) + - Corrección de las traducciones al finés (#14137) (por @jenkrisu) +- Doc + - Actualización del documento 2.4.11 (#13522) (por @Gonzalo2310) +- Otros + - Eliminar scripts innecesarios (por @ziyoung) + - Corregido el error de anchor link (#13753) (por @iamkun) + - Corrección de la capitalización inconsistente en la documentación (por @wonderjar) + - Añadido código qr del grupo de chat DingDing al readme (by @iamkun in #13957) + - Añadido logs de hilo a .gitignore (#13922) (por @mimimi) + - Eliminada la cuota de patrocinadores (#14156) (por @island205) + - Actualizado readme qr code src (#13960) (por @iamkun) + - Actualizado enlace CDN, corregido error tipográfico (por @ziyoung) + ### 2.4.11 *2018-11-21* -- Revert pr #13296. Fixed clicking on Menu external causing Submenu collapsed, #13478 -- Adjust small screen (xs) media query breakpoints, #13468 (by @alekoshen712) +- Revertido pr #13296. Arreglado que al hacer clic fuera del Menú causaba que el Submenú colapsara, #13478 +- Ajustados los media query breakpoints de las pantallas pequeñas (xs), #13468 (por @alekoshen712) ### 2.4.10 @@ -67,17 +965,17 @@ *2018-09-14* -- Corregido que DatePicker no activaba la validación del Form, #12328 #12348 -- Corregidos el lanzamiento de errores del DatePicker en modo múltiple, #12347 +- Corregido que DatePicker no activaba la validación del Form, #12328 #12348 +- Corregidos el lanzamiento de errores del DatePicker en modo múltiple, #12347 - Corregida la posición incorrecta del spinner del DatePicker, #12415 (por @rang-ali) - Se ha corregido el llenado automático del input del DatePicker, #12521 (por @abdallanayer) - Corregida el input no resaltada en Cascader, #12341 -- Corregido el orden incorrecto de Tabpane, #12346 +- Corregido el orden incorrecto de Tabpane, #12346 - Corregida la posición incorrecta del cursor de ColorPicker, #12376 (por @cnwhy) - Corregido el estilo del Submenú, #2457 - Corregido el resaltado después de seleccionar el Submenú, #12479 - Corregidos los valores incorrectos seleccionados por Cascader, #12508 (por @huangjinqiang) -- Corregido el valor incorrecto del input de Paginación, #12525 +- Corregido el valor incorrecto del input de Paginación, #12525 - Se ha corregido el orden en que la paginación desencadena los eventos, #12530 - Corregido que no se mostraba el Table Filter, #12539 - Corregido Tree que era incapaz de borrar nodos, #12684 @@ -90,7 +988,7 @@ *2018-08-09* -- Arreglada la tabla que no mostraba el ícono del filtro cuando a `filter` se les asignaba un array vacío, #12165 +- Arreglada la tabla que no mostraba el ícono del filtro cuando a `filter` se les asignaba un array vacío, #12165 - Arreglado Menu que no guardaba el estado activo cuando cambiaba `collapse` #12178 (por @elfman) - Se ha corregido que Cascader no escapaba a los caracteres especiales para Regexp, #12248 - Se ha corregido que el RadioBotón deshabilitado mostraba la sombra de la caja cuando se hacía clic, #12262 @@ -112,7 +1010,7 @@ - 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 +- 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 @@ -124,10 +1022,10 @@ *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 +- 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 `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 @@ -147,10 +1045,10 @@ *2018-06-26* - 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 +- 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 +- 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 @@ -168,7 +1066,7 @@ - Añadido el atributo `stretch` para Tabs, #11476 - Arreglado el problema de orden de renderizado de TabPane cuando Tabs es `lazy`, #11461 - Arreglado que Table no retenia la fila actual de resaltados cuando se expandia, #11464 -- Arreglado que focusing state cuando `before-leave` devolvia una promesa resuelta, #11386 +- Arreglado que focusing state cuando `before-leave` devolvia una promesa resuelta, #11386 - Arreglado que Popover deshabilitado seguia creando poppers, #11426 - Arreglado el bucle sin fin de Tree cuando se añadia un nuevo nodo en modo `lazy`, #11430 (por @wangjingf) - Añadido el evento `closed` para Dialog, #11490 @@ -203,9 +1101,9 @@ - Upload - Corregido el error de la consola cuando se resolvia el Archivo en la Promesa devuelta del método `beforeUpload`, #11297 (por @qusiba) - Tooltip - - Solucionado que la flecha no se posicionaba correctamente cuando el contenido estaba vacío, #11335 + - Solucionado que la flecha no se posicionaba correctamente cuando el contenido estaba vacío, #11335 - Autocompletar - - Corregido que las sugerencias de entrada eran incorrectas después de eliminar la palabra clave rápidamente, #11323 + - Corregido que las sugerencias de entrada eran incorrectas después de eliminar la palabra clave rápidamente, #11323 - ColorPicker - Corregido el evento `active-change` que se disparaba incorrectamente cuando el menú desplegable del picker estaba cerrado, #11304 - Table @@ -238,7 +1136,7 @@ - Arreglado que al cerrar el panel DatePicker sin modificar el valor se desencadenaba incorrectamente el evento `change`, #11017 - Arreglado que la navegación por el teclado no funcionaba correctamente cuando Select tenia opciones agrupadas, #11058 - Agregado el `slot named` `prefix` para Select, #11063 -- Agregado el metodo `clearValidate` para FormItem, #11076 +- Agregado el metodo `clearValidate` para FormItem, #11076 - Agregado el atributo `checkOnClickNode` para Tree, #11111 ### 2.3.7 @@ -254,7 +1152,7 @@ *2018-04-21* -- Corregido el comportamiento incorrecto del callback `allow-drop` de Tree cuando se usaba el parámetro `type`, #10821 +- Corregido el comportamiento incorrecto del callback `allow-drop` de Tree cuando se usaba el parámetro `type`, #10821 - Ahora puede introducir correctamente las palabras clave en filterable Single Select en IE11, #10822 - Corregido Single Select activaba incorrectamente el evento `blur` después de hacer clic en una opción, #10822 @@ -264,24 +1162,24 @@ - Arreglado los incorrectos realces en el panel de DatePicker cuando `type` es week, #10712 - Arreglado que InputNumber comenzaba vacio cuando el valor inicial era 0, #10714 -- Agregado el atributo `automatic-dropdown` para Select, #10042 (by @Seebiscuit) +- Agregado el atributo `automatic-dropdown` para Select, #10042 (by @Seebiscuit) - Arreglado que el valor del Rate pasaba a `disabled` cuando se comenzaba a actualizar con las teclas de navegacion, #10726 (by @Richard-Choooou) -- Ahora el atributo `type` de DatePicker's puede ser `'dates'`, donde puede elegir varias fechas en un solo picker, #10650 (by @Mini256) -- Agregados los eventos `prev-click` y `next-click` para Pagination, #10755 +- Ahora el atributo `type` de DatePicker's puede ser `'dates'`, donde puede elegir varias fechas en un solo picker, #10650 (by @Mini256) +- Agregados los eventos `prev-click` y `next-click` para Pagination, #10755 - Agregado el atributo `pager-count` para Pagination, #10493 (by @chongjohn716) -- Agregado `type` como 3rd parametro del atributo `allow-drop` de Tree, #10792 +- Agregado `type` como 3rd parametro del atributo `allow-drop` de Tree, #10792 - Ahora usamos ResizeObserver para detectar el redimensionamiento de elementos DOM, #10779 ### 2.3.4 *2018-04-12* -- Eliminado el atributo duplicado `showTimeout` en SubMenu's en la declaracion TypeScript, #10566 (by @kimond) +- Eliminado el atributo duplicado `showTimeout` en SubMenu's en la declaracion TypeScript, #10566 (by @kimond) - Ahora se puede personalizar los datos de los items de Transfer usando scoped slot, #10577 -- Arreglado que los click de los botones `next` y `prev` en Pagination se deshabilitaban cuando se disparaba el evento `current-change`, #10628 +- Arreglado que los click de los botones `next` y `prev` en Pagination se deshabilitaban cuando se disparaba el evento `current-change`, #10628 - Arreglado que Textarea mostraba `undefined` en SSR cuando el valor no era asignado, #10630 -- Arreglado que se deshabilitaba el estilo del TabItem cuando `type` era border-card, #10640 -- Agregado `$index` como cuarto parametro en el atributo de las columnas de Table `formatter` , #10645 +- Arreglado que se deshabilitaba el estilo del TabItem cuando `type` era border-card, #10640 +- Agregado `$index` como cuarto parametro en el atributo de las columnas de Table `formatter` , #10645 - Arreglado que CheckboxButton no se exportaba en la declaracion de TypeScript, #10666 ### 2.3.3 @@ -318,7 +1216,7 @@ #### Nuevas características - Table - Ahora `formatter` de TableColumn puede ser actualizado dinámicamente, #10184 (by @elfman) - - Agregado el atributo `select-on-indeterminate`, #9924 (by @syn-zeta) + - Agregado el atributo `select-on-indeterminate`, #9924 (by @syn-zeta) - Menu - Agregado el atributo `collapse-transition`, #8809 (by @limichange) - Input @@ -329,8 +1227,8 @@ - Tree - Agregados los atributos `draggable`, `allow-drop` y `allow-drag`, y los eventos `node-drag-start`, `node-drag-enter`, `node-drag-leave`, `node-drag-over`, `node-drag-end` y `node-drop`, #9251 #10372 (by @elfman) - Form - - El metodo `validate` ahora acepta un segundo parametro, que contiene información de los ítems del formulario que no superaron la validación, #10279 - - Agregado el evento `validate`, #10351 + - El metodo `validate` ahora acepta un segundo parametro, que contiene información de los ítems del formulario que no superaron la validación, #10279 + - Agregado el evento `validate`, #10351 - Progress - Agregado el atributo `color`, #10352 (by @YunYouJun) - Button @@ -342,7 +1240,7 @@ - Menu - Ahora collapsed Menu sólo mostrará el Tooltip cuando el slot `title` de MenuItem esté configurado, #10193 (by @PanJiaChen) - Pagination - - Corregido el evento `current-change` que se disparaba erróneamente sin interacción del usuario, #10247 + - Corregido el evento `current-change` que se disparaba erróneamente sin interacción del usuario, #10247 - DatePicker - Ahora la fecha y la hora en el panel desplegable están correctamente formateadas según el atributo `format`, #10174(by @remizovvv) - Upload @@ -364,18 +1262,18 @@ - Arreglado anchos incorrectos de columnas fijas de Table en algunos casos, #10130 - Corregido MessageBox heredaba el atributo `title` de su instancia anterior cuando se llamaba sin `title`, #10126 (by @Pochodaydayup) - Agregado el atributo `input-size` para Slider, #10154 -- Agregados los eventos `left-check-change` y `right-check-change` para Transfer, #10156 +- Agregados los eventos `left-check-change` y `right-check-change` para Transfer, #10156 ### 2.2.1 *2018-03-02* - Corregido Aside, Header y Footer que se contraia en algunos layout, #9812 -- Corregido Table con un atributo `height` no renderizaba en SSR, #9876 +- Corregido Table con un atributo `height` no renderizaba en SSR, #9876 - Corregido Table con fila expandible no calculaba la altura cuando la fila era expandida, #9484 -- Corregido que cuando se escribia la fecha de forma manual en DateTimePicker no se disparaba el evento `change`, #9913 +- Corregido que cuando se escribia la fecha de forma manual en DateTimePicker no se disparaba el evento `change`, #9913 - Corregido que Select mostraba sus opciones cuando se hacia click con el botón derecho del mouse en el Input, #9894 (by @openks) -- Agregado el atributo `tooltip-class` para Slider, #9957 +- Agregado el atributo `tooltip-class` para Slider, #9957 - Ahora Select permanecera enfocado despues de la selección, #9857 (by @Seebiscuit) - Agregado el atributo `target-order` para Transfer, #9960 @@ -385,12 +1283,12 @@ #### New features - Menu - - Agregados los atributos `popper-class` y `disabled` para SubMenu, #9604 #9771 + - Agregados los atributos `popper-class` y `disabled` para SubMenu, #9604 #9771 - Menu Horizontal ahora soporta SubMenu multi-capas, #9741 - Tree - Agregado el evento `node-contextmenu`, #9678 - Ahora se puede personalizar el template del nodo usando scoped slot, #9686 - - Agregados los metodos `getNode`, `remove`, `append`, `insertBefore`, `insertAfter`, `getCheckedKeys`, `getHalfCheckedNodes`, `getHalfCheckedKeys` y el evento `check`, #9718 #9730 + - Agregados los metodos `getNode`, `remove`, `append`, `insertBefore`, `insertAfter`, `getCheckedKeys`, `getHalfCheckedNodes`, `getHalfCheckedKeys` y el evento `check`, #9718 #9730 - Transfer - Agregado el metodo `clearQuery`, #9753 - Select @@ -406,11 +1304,11 @@ - Corregido componentes del Container que no se estiraban en IE11, #9655 - Loading - - Corregido Loading no se mostraba cuando el valor de `v-loading` era cambiado a true en el `hook` `mounted`, #9722 + - Corregido Loading no se mostraba cuando el valor de `v-loading` era cambiado a true en el `hook` `mounted`, #9722 - Switch - Corregido se disparaban los dos eventos nativos de click cuando se hacia click en el Switch, #9760 - ​ + ### 2.1.0 Charcoal @@ -470,11 +1368,11 @@ *2018-01-08* -- Corregido el problema de color del borde del Select cuando está el slot `prepend` o `append` del Input, #9089 -- Corregido el parámetro `remove-tag` de Select, #9090 +- Corregido el problema de color del borde del Select cuando está el slot `prepend` o `append` del Input, #9089 +- Corregido el parámetro `remove-tag` de Select, #9090 - Añadido los atributos `show-timeout` y `hide-timeout` para SubMenu, #8934 (por @HugoLew) -- Corregido el estilo de Tooltip de `show-overflow-tooltip` que faltaba cuando Table era importada bajo demanda, #9130 -- Se ha corregido el mal funcionamiento de ordenación de la columna de Table despues que `clearSort` era ejecutado en esa columna, #9100 (por @zEmily) +- Corregido el estilo de Tooltip de `show-overflow-tooltip` que faltaba cuando Table era importada bajo demanda, #9130 +- Se ha corregido el mal funcionamiento de ordenación de la columna de Table despues que `clearSort` era ejecutado en esa columna, #9100 (por @zEmily) - El fichero de configuración i18n para el checo se renombra de `cz` a `cs-CZ`, #9164 ### 2.0.10 @@ -490,7 +1388,7 @@ *2017-12-24* -- Añadida la función de enganche (hook) `before-remove` para Upload, #8788 (by @firesh) +- Añadida la función de enganche (hook) `before-remove` para Upload, #8788 (by @firesh) - Arreglado el valor inicial de error que no funcionaba para FormItem, #8840 - Ahora la directiva Loading soporta nombre de clase personalizado asignando el atributo `element-loading-custom-class`, #8826 (por @earlymeme) - Arreglado CarouselItem que se ponía invisible cuando los datos eran actualizados asincrónicamente, #8921 @@ -518,7 +1416,7 @@ - Corregido error de estilo de los iconos de ordenación de Table, #8405 - Corregido activacion para Popover cuando `trigger` es manual, #8467 -- Añadidos los atributos `prefix-icon` y `suffix-icon` para Autocomplete, #8446 (por @liyanlong) +- Añadidos los atributos `prefix-icon` y `suffix-icon` para Autocomplete, #8446 (por @liyanlong) - Añadido el atributo `separator` para Cascader, #8501 - Añadido atributo `clearable` para Input, #8509 (por @lbogdan) - Añadido atributo `background` para Pagination, #8553 @@ -530,7 +1428,7 @@ - Solucionado regresion en 2.0.4 de Popover, Tree, Breadcrumb and Cascader, #8188 #8217 #8283 - Solucionado Fuga de memoria de la directiva clickoutside, #8168 #8225 (por @badpunman @STLighter) - Solucionada la altura en multiple Select cuando se borra su valor, #8317 (por @luciy) -- Añadido el atributo `collapse-tags` para multiple Select para reemplazar las tags con una línea de texto, #8190 +- Añadido el atributo `collapse-tags` para multiple Select para reemplazar las tags con una línea de texto, #8190 - Solucionado el alto consumo de CPU causado por Table cuando esta oculta, #8351 - Ahora puede usar el método `doLayout` de Table para actualizar su diseño, #8351 @@ -551,7 +1449,7 @@ - Solucionado atributos `editable` and `readonly` de DatePicker de los rangos, #7922 - Corregido error de estilo de los Tabs anidados, #7941 - Corregido error de estilo del último Step de Steps verticales, #7980 -- Corregido el tiempo de activación del evento `current-change` para Pagination, #7995 +- Corregido el tiempo de activación del evento `current-change` para Pagination, #7995 - Corregido Tooltip no registrado en el Menu, #7995 ### 2.0.2 @@ -582,7 +1480,7 @@ #### New features - General - - Un nuevo tema: `theme-chalk` + - Un nuevo tema: `theme-chalk` - Se ha mejorado la accesibilidad de los siguientes componentes: Alert, AutoComplete, Breadcrumb, Button, Checkbox, Collapse, Input, InputNumber, Menu, Progress, Radio, Rate, Slider, Switch, Upload - Añadido tipografías TypeScript - Todos los iconos existentes son rediseñados. Se han añadido algunos iconos nuevos @@ -592,9 +1490,9 @@ - Button - Atributo `round` añadido. Se usa para botones de esquinas redondas #6643 - TimeSelect - - Ahora puede ser navegado por `Up` y `Down`, y presionando `Enter` selecciona la hora #6023 + - Ahora puede ser navegado por `Up` y `Down`, y presionando `Enter` selecciona la hora #6023 - TimePicker - - Ahora puede ser navegado por `Up` y `Down`, y presionando `Enter` selecciona la hora #6050 + - Ahora puede ser navegado por `Up` y `Down`, y presionando `Enter` selecciona la hora #6050 - Añadido `start-placeholder` y `end-placeholder`. Son placeholder's para las dos casillas de input en modo range #7169 - Añadido el atributo `arrow-control` para hacer girar el tiempo con las flechas #7438 - Tree @@ -611,19 +1509,19 @@ - Añadido el atributo `closeOnHashChange` #6043 - Atributo `center` agregado para que el contenido pueda ser centrado #7029 - Añadido atributo `roundButton` para mostrar Botones redondeados #7029 - - Añadido atributo `dangerouslyUseHTMLString`. Cuando está configurado en true, el mensaje será analizado como cadena HTML* #6043 + - Añadido atributo `dangerouslyUseHTMLString`. Cuando está configurado en true, el mensaje será analizado como cadena HTML* #6043 - Añadido atributo `inputType` para asignar el tipo para el input interno, #7651 - Dialog - Añadidos los atributos `width`, `fullscreen`, `append-to-body`. Ahora Dialog puede ser anidado - Atributo `center` agregado para que el contenido pueda ser centrado #7042 - - Añadidos `focus-after-closed`, `focus-after-open` para mejorar la accesibilidad #6511 + - Añadidos `focus-after-closed`, `focus-after-open` para mejorar la accesibilidad #6511 - ColorPicker - Ahora puede escribir colores en el input #6167 - Añadidos atributos `size` y `disabled` #7026 - Añadido atributo `popper-class` #7351 - Message - Ahora el color de los iconos puede ser sustituido por CSS #6207 - - Añadido atributo `dangerouslyUseHTMLString`. Cuando está configurado en true, el mensaje será analizado como cadena HTML* #6207 + - Añadido atributo `dangerouslyUseHTMLString`. Cuando está configurado en true, el mensaje será analizado como cadena HTML* #6207 - Atributo `center` agregado para que el contenido pueda ser centrado #6875 - Notification - Añadido atributo `position` para configurar donde aparece Notification #6231 @@ -632,24 +1530,24 @@ - Rate - Añadido el atributo `show-score` para determinar si la puntuación actual se muestra #6295 - Tabs - - Añadido el atributo `tab-position` #6096 + - Añadido el atributo `tab-position` #6096 - Radio - - Añadidos los atributos `border` y `size` #6690 + - Añadidos los atributos `border` y `size` #6690 - Checkbox - - Añadidos los atributos `border` y `size` #6690 + - Añadidos los atributos `border` y `size` #6690 - Alert - Atributo `center` agregado para que el contenido pueda ser centrado #6876 - Menu - - Añadidos los atributos `background-color`, `text-color` y `active-text-color` #7064 - - Añadidos los methods `open` and `close` para abrir y cerrar los SubMenu con programación, #7412 + - Añadidos los atributos `background-color`, `text-color` y `active-text-color` #7064 + - Añadidos los methods `open` and `close` para abrir y cerrar los SubMenu con programación, #7412 - Form - - Añadido el atributo `inline-message` para determinar si el mensaje de validación se muestra inline #7032 + - Añadido el atributo `inline-message` para determinar si el mensaje de validación se muestra inline #7032 - Añadido el atributo `status-icon` para mostrar un icono de retroalimentación cuando se valida #7032 - Form y FormItem ahora tienen un atributo `size`. Los componentes internos heredarán este tamaño si no se especifica en ellos mismos, #7428 - Método `validate` devolverá ahora una promesa si se omite la llamada de retorno, #7405 - Añadido método `clearValidate` para limpiar los resultados de las validaciones de todos los form items, #7623 - Input - - Añadido slots con nombres `suffix` y `prefix` y atributos `suffixIcon` y `prefixIcon` para añadir contenido dentro del input #7032 + - Añadido slots con nombres `suffix` y `prefix` y atributos `suffixIcon` y `prefixIcon` para añadir contenido dentro del input #7032 - Breadcrumb - Añadido el atributo `separator-class` para dar soporte a los iconos como separadores de items #7203 - Steps @@ -657,7 +1555,7 @@ - Pagination - Añadidos los atributos `prev-text` y `next-text` para personalizar los textos de la página anterior y de la página siguiente #7005 - Loading - - Ahora usted puede personalizar el ícono del spinner y el color de fondo con los props `spinner` y `background` , #7390 + - Ahora usted puede personalizar el ícono del spinner y el color de fondo con los props `spinner` y `background` , #7390 - Autocomplete - Añadido atributo `debounce`, #7413 - Upload @@ -679,7 +1577,7 @@ - Añadido un atributo `header-row-style` para el estilo de encabezado - Añadido el atributo `header-cell-class-name` para asignar el nombre de la clase para las celdas de encabezado. - Añadido el atributo `header-cell-style` a las celdas de encabezado de estilo - - El atributo prop de TableColumn ahora acepta las notaciones `object[key]` + - El atributo prop de TableColumn ahora acepta las notaciones `object[key]` - Atributo de `index` añadido para TableColumn para personalizar índices de filas - Select - Añadido el atributo `reserve-keyword` para reservar la palabra clave de búsqueda actual después de seleccionar una opción. @@ -687,8 +1585,8 @@ #### Bug fixes - DatePicker - - Arreglado `v-model` que devolvia el segundo día de la semana seleccionada en modo week #6038 - - Arreglado el primer input comenzaba borrado con el type `daterange` #6021 + - Arreglado `v-model` que devolvia el segundo día de la semana seleccionada en modo week #6038 + - Arreglado el primer input comenzaba borrado con el type `daterange` #6021 - DateTimePicker - Arreglado DateTimePicker y TimePicker que se afectaban entre sí cuando se seleccionaban #6090 - Arreglado la hora y el segundo podian estar más allá del límite al seleccionar el tiempo #6076 @@ -699,9 +1597,9 @@ - Select - Rendimiento mejorado. Ahora Vue dev-tool no se bloqueará cuando un gran número de Selects sean destruidos #6151 - Table - - Corregido un bug de Table permanecía oculto cuando su elemento padre tenia el atributo `display: none` + - Corregido un bug de Table permanecía oculto cuando su elemento padre tenia el atributo `display: none` - Arreglado Table ahora amplia su ancho cuando el elemento padre tiene `display: flex` - - Arreglado un bug que corregía las columnas de una tabla con slot con nombre `append` que desaparecia cuando los datos eran recuperados dinámicamente. + - Arreglado un bug que corregía las columnas de una tabla con slot con nombre `append` que desaparecia cuando los datos eran recuperados dinámicamente. - Arreglado el atributo `expand-row-keys` que no funcionan con el valor inicial - Fallo del filtro corregido al actualizar los datos - Se ha corregido un error de cálculo de la disposición de columnas fijas con cabeceras agrupadas. @@ -713,11 +1611,11 @@ - General - Eliminado `theme-default` - Compatible con Vue 2.5.2+ e IE 10+ - - Evento `change` de componentes del formulario y evento `current-change` de Pagination ahora sólo se activa en la interacción del usuario. + - Evento `change` de componentes del formulario y evento `current-change` de Pagination ahora sólo se activa en la interacción del usuario. - El atributo `size` del botón y los componentes del formulario aceptan ahora los tamaños `medium`, `small` y `mini`. - - Para facilitar el uso de iconos de terceros, los atributos `icon` de Button y Steps y los atributos `prefix-icon` y `suffix-icon` del input ahora requieren un nombre de clase completo. + - Para facilitar el uso de iconos de terceros, los atributos `icon` de Button y Steps y los atributos `prefix-icon` y `suffix-icon` del input ahora requieren un nombre de clase completo. - Dialog - - Atributo `size` eliminado. Ahora el tamaño de Dialog se puede configurar con `width` y `fullscreen` + - Atributo `size` eliminado. Ahora el tamaño de Dialog se puede configurar con `width` y `fullscreen` - Ahora la visibilidad del Diálogo no puede ser controlada por `v-model` - Rate - `text-template` a sido renombrado a `score-template` @@ -726,19 +1624,19 @@ - Transfer - `footer-format` a sido renombrado a `format` - Switch - - Los atributos que comienzan con `on*` serán analizados en eventos en JSX, haciendo que todos los atributos `on*` de Switch no puedan trabajar en JSX. Por lo tanto, los atributos `on*` se renombran a `active-*`, y por consiguiente los atributos `off-*` se renombran a `inactivado-*`. Este cambio afecta a los siguientes atributos: `on-icon-class`, `off-icon-class`, `on-text`, `off-text`, `on-color`, `off-color`, `on-value`, `off-value`. - - Los atributos `active-text` y `inactive-text` ahora no tienen valores por defecto. + - Los atributos que comienzan con `on*` serán analizados en eventos en JSX, haciendo que todos los atributos `on*` de Switch no puedan trabajar en JSX. Por lo tanto, los atributos `on*` se renombran a `active-*`, y por consiguiente los atributos `off-*` se renombran a `inactivado-*`. Este cambio afecta a los siguientes atributos: `on-icon-class`, `off-icon-class`, `on-text`, `off-text`, `on-color`, `off-color`, `on-value`, `off-value`. + - Los atributos `active-text` y `inactive-text` ahora no tienen valores por defecto. - Tag - - El atributo type acepta ahora `success`, `info`, `warning` y `danger` + - El atributo type acepta ahora `success`, `info`, `warning` y `danger` - Menu - - Atributo `theme` eliminado. El color de Menu se puede configurar utilizando `background-color`, `text-color` y `active-text-color` + - Atributo `theme` eliminado. El color de Menu se puede configurar utilizando `background-color`, `text-color` y `active-text-color` - Input - - Atributo `icon` eliminado. Ahora el icono del sufijo puede configurarse usando el atributo `suffix-icon` o el slot con nombre `suffix`. - - Eliminado el atributo `on-icon-click` y el evento `click`. Ahora para añadir el manejador de clics en los iconos, por favor use los slots con nombre. + - Atributo `icon` eliminado. Ahora el icono del sufijo puede configurarse usando el atributo `suffix-icon` o el slot con nombre `suffix`. + - Eliminado el atributo `on-icon-click` y el evento `click`. Ahora para añadir el manejador de clics en los iconos, por favor use los slots con nombre. - El evento `change` se comporta ahora como el nativo, que se activa sólo en la perdida del foco o presionando enter. Si necesita responder a las entradas de usuario en tiempo real, puede utilizar el evento `input`. - Autocomplete - Atributo `custom-item` eliminado. Ahora la plantilla de sugerencias del input se puede personalizar utilizando `scoped slot` - - Atributo `props` eliminado. Ahora puede utilizar el atributo `value-key` para designar el nombre de la clave del objeto de sugerencia del input para su visualización. + - Atributo `props` eliminado. Ahora puede utilizar el atributo `value-key` para designar el nombre de la clave del objeto de sugerencia del input para su visualización. - Steps - Atributo `center` eliminado - Ahora Steps llenara su contenedor padre por defecto @@ -747,10 +1645,10 @@ - Table - Soporte eliminado para personalizar la plantilla de columnas mediante `inline-template` - `sort-method` ahora se alinea con `Array.sort`. Debería devolver un número en lugar de un booleano - - El slot `append` se desplazo fuera del elemento `tbody` para evitar múltiples renderizados. + - El slot `append` se desplazo fuera del elemento `tbody` para evitar múltiples renderizados. - Evento `expand` se renombro a `expand-change` - - Los parametros de los métodos `row-class-name` y `row-style` son ahora un objeto + - Los parametros de los métodos `row-class-name` y `row-style` son ahora un objeto # # -* El procesamiento dinámico de HTML arbitrario en su sitio web puede ser muy peligroso porque puede conducir fácilmente a [ataques XSS](https://en.wikipedia.org/wiki/Cross-site_scripting). Por lo tanto, cuando `dangerouslyUseHTMLString` está encendido, por favor asegúrese de que el contenido de `message` es confiable, y **nunca** asigne el `message` al contenido proporcionado por el usuario. +* El procesamiento dinámico de HTML arbitrario en su sitio web puede ser muy peligroso porque puede conducir fácilmente a [ataques XSS](https://en.wikipedia.org/wiki/Cross-site_scripting). Por lo tanto, cuando `dangerouslyUseHTMLString` está encendido, por favor asegúrese de que el contenido de `message` es confiable, y **nunca** asigne el `message` al contenido proporcionado por el usuario.`` diff --git a/CHANGELOG.fr-FR.md b/CHANGELOG.fr-FR.md new file mode 100644 index 00000000000..d1e570f9b7e --- /dev/null +++ b/CHANGELOG.fr-FR.md @@ -0,0 +1,1645 @@ +## Changelog + +### 2.13.0 + +*2019-11-26* + +#### New features + +- Popconfirm + - Add popconfirm component (#17548 by @iamkun) + +#### Bug fixes + +- BackTop + - Use cubic bezier scrolling (by @lon) +- DatePicker + - Fix bug of only select min date of date range problem (#17191 by @smk0621) +- Select + - Fix select test cases (by @msidolphin) +- Tree + - Add font-size for the style of tree empty-text (#17094 by @spengjie) +- Table + - Column header can be costumed (#17291 by @ziyoung) + - Update table header cell style (#17284 by @ziyoung) + - Fix table header height after filter (#17348 by @ziyoung) + - Fixed row-style with display not work (#17002 by @a631807682) + - Fix header table not display (#17341 by @ziyoung) +- Calendar + - Import el-button and el-button-group (#17376 by @masongzhi) +- MessageBox + - Fix icon position error (#17410 by @nullptru) +- TimePicker + - Set the selection range after scrolling up or down (#16868 by @mattheyan) +- Message + - Fix close instace offsetHeight(#17564) (#17852 by @gzwgq222) +- Form + - Callback of validateField should be optional (#17314 by @CarterLi) +- Cascader + - Fix TypeScript 3.7 compatibility (#17881 by @CarterLi) +- Menu + - Fix router NavigationDuplicated error when using vue-router@^3.1.0 (#17269 by @iamkun) +- Dropdown + - Update type file (#17550 by @iamkun) +- Progress + - Add strokeLinecap prop (#17552 by @iamkun) +- InfiniteScroll + - Skip trigger event on invisible element (#17553 by @iamkun) +- Image + - Perfect picture preview behavior (#16985 by @luckyCao) + - Fix shield the page when preview big image (#16796 by @luckyCao) +- Drawer + - Bugfix drawer-append-to-body-not-working (#16953 by @JeremyWuuuuu) +- Select + - Fix tag show value or empty issue (17199 by @luckyCao) +- Scrollbar + - Fix FireFox scroll bar width (#18091 by @iamkun) + +#### Optimization + +- I18n + - Update sv-SE.js (#17926 by @FOLLGAD) + - Update avatar component fr doc (#17762 by @blombard) +- Docs + - Fix time-select typo (#17250 by @wacky6) + - Fix Drawer attribute accepted value typo in es (#17122 by @haoranyu) + - Update Spanish changelog 2.12.0 (#17364 by @Gonzalo2310) + - Fix Changelog typo (#17874 by @renlixin) + - Fix Loading demo (#17862 by @MBearo) + - Add input event in input Events Table (#18061 by @zhouxinyong) + - Delete Input repeat change event (#18085 by @zhouxinyong) + +### 2.12.0 + +*2019-08-29* + +#### New features + +- Popover + - Add close-delay prop (#16671 by @LachlanStuart) +- Theme + - Add Chrome Extension: Element Theme Extension (#16686 by @iamkun) +- Icon + - Add font-display to @font-face declaration (#16805 by @iamfaizalandyka) + +#### Bug fixes + +- Carousel + - Fix onChange emit value (#16705 by @iamkun) +- Notification + - Fix modifying incoming option object (#16704 by @iamkun) +- DatePicker + - Add className for picker option (#16632 by @iamkun) +- DateTimePicker + - Fix time-spinner not scroll to right position (#16854 by @jesse-li) +- Table + - Prevent click handler after drag (#16850 by @ziyoung) + - Fix chrome crash when set thead css display to none (#16956 by @luckyCao) + - Fix wrong empty block height (#16861 by @ziyoung) + - Not throw error when calling toggleExpansion (#16304 by @yyjjqq94) + - Not trigger sort-change event when mounted (#17113 by @a631807682) + - Fix setCurrentRow unable to clear highlight row (#16879 by @ziyoung) + - Fix expand-row-keys not work when data is loaded asynchronously (#16899 by @ziyoung) + - set toggleAllSelection as instance property (#17137 by @ziyoung) +- Tree + - Fix distance between label and checkbox (#16799 by @Hazlank) +- Tabs + - Fix incorrect TabItem's position (#16520 by @victorting) + - Fix activated tab is out of visual range bug (#17033 by @nullptru) +- Calendar + - Fix weekdays i18n issue (#16772 by @ubitoffee) + - fix locale error by (#17208 by @iamkun) +- Cascader + - Fix CascaderPanel display error (#16716 by @zhangHongEn) + - Fix disable status and close button issue (#16224 by @yyjjqq94) +- Input + - Fix Korean composition event (#15069 by @MoonHyuk) + - Fix click event of clear button not trigger when using v-loading (#16576 by @a631807682) +- Select + - Not toggle dropdown when filtering (#17205 by @luckyCao) +- Transfer + - Fix style error (#17206 by @iamkun) +- Dialog + - update sass var (#16365 by @haoranyu) +- RadioGroup + - Not produce invalid HTML in table if "is" attribute is specify (#17070 by @nullptru) +- Divider + - Support custom classes (#17078 by @island205) + +#### Optimization + +- Checkbox + - Improve screen reader experience (#16575 by @tylertrotter) +- Docs + - Update changelog (#16773 by @SimonaliaChen) + - Update contributing guide (#14800 by @sinchang) + - Fix typo in Drawer docs (#16848 by @winkay) + - Update custom theme (#16983 by @iamkun) + - Add Esperanto translation (#16955 by @maxkoryukov) + - Update input-number document about change event (#16316 by @luckyCao) + - Update spanish doc 2.11.1 (#16961 by @Gonzalo2310) +- I18n + - Remove translation of 'year' in catalan language as in the other languages (#14722 by @oscaralbareda) + - Update spanish changelog 2.10.0 and 2.10.1 (#16548 by @Gonzalo2310) + - Update ar.js (#16653 by @l3op) +- Test + - Correct spelling error (#16672 by @boomler) + - Refactor unit test to use data-uri (#16847 by @a631807682) +- Types + - Fix httprequest type (#16633 by @luckyCao) + +### 2.11.1 + +*2019-07-26* + +#### Bug fixes + +- Image + - Fix Image component SSR compatibility (#16737 by @luckyCao) +- Chore + - Update dart-sass compatibility (#16744 by @LewisChennnnn) + +### 2.11.0 + +*2019-07-25* + +#### New features + +- Drawer + - Add drawer component (#16577 by @JeremyWuuuuu) + +#### Bug fixes + +- Checkbox + - Enhance css selector (#16006 by @Hazlank) +- Tree + - Make el-tree generic (#15934 by @JeremyWuuuuu) + - Set isCurrent prop to False (#15870 by @kkkisme) +- Dropdown + - Fix split-button caret default color (#15931 by @JuniorTour) +- Cascader + - Fix level 1 children is empty update problem (#16399 by @luckyCao) + - Add sets default values when lazy is true (#16420 by @luckyCao) + - Fix display errors when node value is duplicate (#15935 by @junyiz) + - Expose getCheckedNodes and fix options change bug (#16709 by @SimonaliaChen) +- Calendar + - Display correct header when range is specified (#16354 by @ziyoung) +- Submenu + - Fix prop append-to-body (#16289 by @a631807682) +- Table + - Fix tree table when updating data (#16481 by @island205) +- Select + - Fix memory leak issue (#16463 by @island205) +- InfiniteScroll + - Update naming & doc (#16698 by @iamkun) +- Avatar + - Fix image not center vertically issue (#16489 by @luckyCao) +- Dialog + - Add destroyOnClose attribute (#16455 by @ziyoung) +- Image + - Add big Image preview feature (#16333 by @luckyCao) + +#### Optimization + +- Docs + - Fix dropdown demo (#16193 by @webxmsj) + - Fix typo in table documents (#15971 by @howiefh) +- I18n + - Update translation of Thai language (#16689 by @ponkrit) +- Chore + - Update theme base api (#16607 by @iamkun) + - Add form theme token (#16699 by @iamkun) + - Mark ali inner user's access (#16609 by @iamkun) + - Fix doc anchor bug (#16692 by @iamkun) + +### 2.10.1 + +*2019-07-02* + +#### Bug fixes + +- Table + - Fix sort icon (#15439 by @bezany) + - Fix layout breaks when append slot exists (#16332 by @ziyoung) + - Fix showOverflowTooltip not reactive (#16295 by @a631807682) + - Register scrollbar in filter-panel (#16246 by @ziyoung) +- Chore + - Fix 2.9 docs (#16233 by @ziyoung) + - Fix index page theme intro english css style issue (#16254 by @iamkun) + +#### Optimization + +- Tag + - Compatible with IE (#16334 by @ziyoung) +- Chore + - Update Dingtalk Group QR image (#16236 by @iamkun) +- Doc + - Update online theme roller doc (#16244 by @iamkun) + +### 2.10.0 + +*2019-06-25* + +#### New features + +- I18n + - Added Uzbek language (#15796 by @ogabek96) +- Calendar + - Add first-day-of-week attribute (#16047 by @ziyoung) +- Avatar + - Add avatar component (#16144 by @luckyCao) +- Upload: + - Add capability to customize thumbnail template (#13192 by @victorzhuk) + +#### Bug fixes + +- Tree + - Not highlight tree node when currentKey is null (#15668 by @yyjjqq94) + - Fix issue #15538 caused by two Tree sharing the same data. (#15615 by @VanMess) +- Upload + - Update the parameter `fileList` type (#15716 by @underfin) +- Table + - Fix loading icon not display (#15868 by @ziyoung) + - Fix background color of complex table when hovering (#15504 by @cnlon) + - Fix current-row-key and select event bug (#15983 by @ziyoung) + - Height accepts more units (#16013 by @ziyoung) + - Fix reserve-selection not work (#16135 by @ziyoung) +- Docs + - Fix Divider attribute type in zh-cn (#15889 by @haoranyu) +- Menu + - Fixed submenu hidden bug after adding popper-append-to-body (#15391 by @PanJiaChen) +- Select + - Fix initialInputHeight (#15989 by @yyjjqq94) + - Fix default-first-option behavior when typing Chinese (#15431 by @VanMess) + - fix double import problem (#16215 by @lengband) +- Message + - Add type def for offset option (#16027 by @matjaz) +- Timeline + - Fix reverse broken (#16091 by @ziyoung) +- Slider + - Fix #15545 by adding explains about "input" event in Chinese (#15588 by @VanMess) +- InfiniteScroll + - Update package name (#16125 by @iamkun) +- MessageBox + - Fix  distinguishCancelAndClose action not same as docs bug (#15438 by @qingdengyue) +- PopupManager + - Fix z-index cannot be rewritten at first using (#15738 by @luckyCao) +- Docs + - Delete an incorrect closing html tag and empty block code (#16194 by @Alexeykhr) +- Chore + - Update test api host (#15807 by @iamkun) + +#### Optimization + +- Tree + - Modify loop conditions to improve performance (#15699 by @KingJeason) +- Theme + - Refine GA track & Update footer link forward to online theme roller (#16007 by @island205) +- Badge + - Update badge prop check (#16198 by @iamkun) +- Avatar + - Update theme config var (#16202 by @luckyCao) +- I18n + - Update pt-br.js (#15776 by @gigioSouza) + - Update Farsi translation (#15881 by @pamenary) +- Docs + - Add missing components in quickstart (#16063 by @pape2016) + - Update french translation (#16208 by @blombard) + - Add description $slots.default (#15444 by @Alexeykhr) + - Update Spanish Doc 2.9.1 (#15840 by @Gonzalo2310) + - Fix spelling mistakes in fr (#15837 by @blombard) + - Update changelog 2.9.2 Spanish (#16185 by @Gonzalo2310) + +#### Breaking changes + +- Form + - Remove success status (#16159 by @ziyoung) + +### 2.9.2 + +*2019-06-21* + +#### Correction de bugs + +- Chore + - Correction du fichier de définitions TS (#15805 by @NateScarlet) + +### 2.9.1 + +*2019-05-30* + +#### Nouvelles fonctionnalités + +- Table + - les événements tree-props,default-expand-all, expand-row-keys, toggle-row-expansion method and expand-change sont pris en charge dans Tree Table (#15709 by @ziyoung) + +#### Correction de bugs + +- Table + - Correction de quelques bugs (#15709 by @ziyoung) +- Theme + - Mise à jour de l'hôte api (#15784 by @iamkun) + +#### Optimisation + +- Chore + - Mise à jour de InfiniteScroll type (#15794 by @iamkun) + +### 2.9.0 + +*2019-05-30* + +#### Nouvelles fonctionnalités + +- Backtop + - Ajout du composant Backtop (#15541 by @iamkun) +- PageHeader + - Ajout du composant PageHeader (#15714 by @ziyoung) +- InfiniteScroll + - Ajout de la directive InfiniteScroll (#15567 by @iamkun) +- Cascader + - Ajouter plusieurs mode et filter-method (#15611 by @SimonaliaChen) +- Message + - Affichage en mode pile (#15639 by @island205) +- Tag + - Ajout d'un effet de prop (#15725 by @SimonaliaChen) +- Tabs + - Aligner le titre à gauche lorsque le type est carte (#15695 by @luckyCao) +- DatePicker + - Supporte les chaînes de caractères littérales (#15525 by island205) +- Image + - Ajout du support pour les attributs de transmission et listeners (#15578 by @VanMess) +- Theme + - Ajout d'un popup en arrière plan (#15412 by @iamkun) +- Chore + - Mise à jour de la nouvelle page d'index 2.9.0 (#15682 by @iamkun) + +#### Correction de bugs + +- Table + - Correction du comportement de sort-change lorsque la condition de tri est nulle (#15012 by @joelxr) +- Image + - Correction de la compatibilité ssr et object-fit (#15346 by @SimonaliaChen) +- Input + - Correction du style de show-word-count dans el-form (#15359 by @lvjiaxuan) + - Correction de l'icône d'erreur pas centrée (#15354 by @YiiGuxing) +- Calendar + - Correction du mauvais jour de la semaine quand le jour est dimanche (#15399 by @qingdengyue) + - Correction du bug de disparition d'octobre (#15394 by @qingdengyue) +- Tabs + - Correction de l'onglet de base imbriqué dans l'erreur de remplissage de card (#15461 by @SimonaliaChen) +- Tag + - Correction du problème de propagation d'arrêt (#15150 by @infjer) +- Form + - Correction de input-group dans l'erreur de hauteur de form-item (#15457 by @SimonaliaChen) + - Résolution de l'issue de resetFields (15181 by @luckyCao) +- Tooltip + - Correction de tabindex personnalisé ne fonctionnant pas (#15619 by @SimonaliaChen ) +- Link + - Correction de la classe de style d'icône (#15752 by @iamkun) +- Select + - Revert définit la valeur à null une fois effacée (#15447 by @iamkun) +- Loading + - Résolution du problème de mise à jour de dom lorsque l'état de chargement change rapidement (#15123 by @FAKER-A) +- Switch + - Label avec les événements récurrents el-switch (#15178 by @FAKER-A) +- Slider + - Correction d'un problème de style lorsque la barre de défilement est cliquée (#15561 by @luckyCao) +- Radio + - Résolution de l'issue 14808 (#14809 by @OverTree) +- Form + - Résolution du problème de resetFields (15181 by @luckyCao) +- Chore + - Mise à jour des dépendances et corrige le bug de démonstration (#15324 by ziyoung) +- Type + - Correction du type de chargement (#15635 by @iamkun) + - Correction du type d'icône (#15634 by @iamkun) + - Fixe la définition du type de lien (#15402 by @iamkun) + +#### Optimisation + +- Cascader + - Refactor (#15611 by @SimonaliaChen) +- Chore + - Mise à jour de la logique du nouveau composant (by @iamkun) +- Docs + - Renommage de variables dans la documentation (#15185 by @liupl) + - Correction du type d'attribut d'image et de la valeur par défaut (#15423 by @haoranyu) + - Correction d'un bug de formulaire (#15228 by @SHERlocked93) + +### 2.8.2 + +*2019-04-25* + +#### Corrections de bugs + +- Icon + - Mise à jour (#15272 par @iamkun) +- Docs + - Correction du style de Form et Input (#15273 par @ziyoung) + +### 2.8.1 + +*2019-04-25* + +#### Corrections de bugs + +- Icon + - Mise à jour de l'icône du cascadeur et du select (#15264 par @SimonaliaChen) + - Mise à jour (#15258 #15268 par @iamkun) + +#### Optimisation + +- Chore + - Mise à jour du script de build (#15267 par @ziyoung) +- Docs + - Correction de la couleur de souslignage d'un lien (#15265 par @iamkun) +- Autre + - Correction d'une configuration de migration non compatible avec les propriétés et évènements en camelCase (#15260 par @SimonaliaChen) + +### 2.8.0 + +*2019-04-25* + +#### Nouvelles fonctionnalités + +- Divider + - Ajout du composant divider (#15055 par @island205) +- Rate + - Ajout des couleurs et des classes d'icônes personnalisées en passant un objet (#15051 par @SimonaliaChen) +- Link + - Ajout du composant Link (#15052 par @iamkun) +- Calendar + - Ajout du composant calendar (#14908 by @ziyoung) +- Icon + - Ajout d'une icône (#15214 par @iamkun) +- Alert + - Ajout d'un thème sombre (#15041 par @island205) +- Image + - Ajout du composant image (#15117 par @SimonaliaChen) +- Collapse + - CollapseItem peut être désactivé (#15076 par @ziyoung) +- Carousel + - Ajout d'un attribut de direction et support de la direction verticale (#15122 by @ziyoung) +- Pagination + - Ajout d'un attribut caché sur une seule page (#15096 par @ziyoung) +- Slider + - Ajout des marqueurs (#15133 par @luckyCao) +- Input + - Ajout de l'attribut show-word-count (#15075 par @luckyCao) +- InputNumber + - Ajout de l'attribut step-strictly (#15050 par @luckyCao) +- Tooltip, Dropdown, Popover + - Support de l'attribut tabindex (#15167 by @ziyoung) + +#### Corrections de bugs + +- Notification + - Correction du word-break du titre (#15008 par @iamkun) +- Form + - Correction d'une erreur dans les règles de validation (#14985 par @luckyCao) + - Correction du style du label (#14969 par @ziyoung) + - Les FormItem requis affiche un astérisque lorsque le label est auto (#15144 by @ziyoung) +- Pagination + - Fix du slot non mis à jour (#14711 par @lucyhao) +- Table + - Correction d'un bug de chargement en mode lazy (#15101 by @ziyoung) + - Correction de la largeur des cellules lorsque colspan est supérieur à 1 (#15196 by @ziyoung) + - Amélioration des performances (#14868 by @ziyoung) + - Ne pas émettre de déclencheurs de changement de tri pendant l'initialisation (#14625 by @PeanutWatson) + - Comportement égal pour height et max-height (#14660 by @arthurdenner) +- Dialog + - Correction de la casse des longs mots (#15027 par @iamkun) +- Alert + - Mise à jour (#15186 par @ziyoung) +- Tabs + - Correction d'un problème où le rejet d'une promesse touchait l'application (#14816 par @ffxsam) + - Rerendu lors d'un changement de slots (#1523238 by @ziyoung) +- Message + - Mise à jour (#14968 par @agoni121212) +- Select + - Correction d'une erreur lorsque la valeur est indéfinie ou nulle (#15022 par @luckyCao) +- Tree + - Détruire le noeud courant après sa suppression (#14604 par @sinchang) + - Amélioration des performances (#14881 par @ChenZhuoSteve) +- Dropdown + - Correction de style (#14907 par @doing123) +- Slider + - Correction d'un bug clavier a11y cassé (#14792 by @erezsob) +- Menu + - La valeur ActiveIndex sera nulle si defaultIndex n'existe pas (#14074 par @hoythan) +- Directive + - RepeatClick : utilisation de Date.now() au lieu de Date() (#14776 par @pavelmash) +- Upload + - Correction du style d'affichage des images transparentes (#15039 par @iamkun) +- Thème + - Ajout d'une bordure (#1525256 par @iamkun) + +#### Optimisation + +- Chore + - Mise à jour du changelog zh-cn (#14965 par @iamkun) + - Masquer la description de la démo quand elle est vide (#15014 par @ziyoung) + - Afficher les informations du serveur de développement par défaut par @iamkun) + - Correction d'une erreur de changelog 2.6.0 (#15026 par @iamkun) + - Mise à jour de la configuration de compilation (#14821 par @abc3660170) + - Ajout d'hmr (#15221 par @SimonaliaChen) + - Utilisation de sourcemap dans l'environnement dev (#15087 par @ibufu) +Docs + - Renommage de la variable dans docs (#14602 #15003 #15094 #15105 par @liupl) + - Correction d'une erreur de téléchargement de doc (#15023 par @iamkun) + - Mise à jour du validateur de formulaire personnalisé doc (#15040 par @iamkun) + - Mise à jour des onglets docs pour afficher les onglets verticaux (#15053 par @iamkun) + - Utiliser eleme.cn comme domaine (#15139 par @ziyoung) + - Correction du nom de route Image (#15194 par @iamkun) + - Suppression de la traduction en double (#15207 par @iamkun) + +#### Breaking changes + +- Rate + - Correction du support de l'affichage décimal en mode désactivé (#15089 par @haoranyu) +- Select + - Utiliser le label de l'option pour régler le placeholder en mode filtre (#14989 par @ibufu) + +### 2.7.2 + +*2019-04-03* + +#### Corrections de bugs + +- Form + - Correction du style de `label-width` auto (#14955 par @ziyoung) + +#### Optimisation +- Docs + - Correction d'une erreur de lien img (#14957 par @iamkun) +- Chore + - Correction d'une erreur de déploiement mkdir (#14952 par @iamkun) + +### 2.7.1 + +*2019-04-03* + +#### Corrections de bugs + +- Select + - Définir la valeur à null lorsqu'elle est effacée (#14322 par @aaronfulkerson) +- Input + - Mise à jour des valeurs dépendantes du DOM lors d'un changement de type (#14889 par @wacky6) +- Table + - Faire fonctionner `defaultExpandAll' lorsqu'une colonne étendue existe (#14935 par @ziyoung) +- Dialog + - Couleur d'arrière-plan configurable (#14939 par @ziyoung) +- Form + - `label-width` supporte la largeur automatique (#14944 by @ziyoung) + +#### Optimisation +- Docs + - Mise à jour de la documentation en espagnol (#14913 par @Gonzalo2310) + - Ajout d'un document en français pour le nouveau composant (#14924 by @ziyoung) + - Optimiser la documentation des onglets (#14938 by @ziyoung) + +### 2.7.0 + +*2019-03-28* + +#### Nouvelles fonctionnalités + +- Table + - Ajout du support de l'arborescence des données (#14632 by @ziyoung) + +#### Corrections de bugs + +- Tabs + - Utilise la couleur primaire comme couleur de l'ombre (#14558 par @Richard-Choooou) + - Rerendu lorsque label change (#14496 par @akki-jat) +- Table + - Le pied de page suit l'alignement des cellules du corps (#14730 by @ziyoung) +- NavMenu + - Correction d'un bug de clic sur el-submenu (#14443 par @PanJiaChen) +- Dropdown + - Compatible avec la nouvelle syntaxe v-slot 2.6 (#14832 by @ziyoung) +- ColorPicker + - Correction d'une erreur de couleur hexadécimale (#14793 par @iamkun) +- Tree + - Revert pr #13349 (#14847 par @ziyoung) +- Tooltip + - Affichage lorsque la valeur initiale est vraie (#14826 by @ziyoung) +- Docs + - Mise à jour de la documentation du cascader (#14442 par @panhezeng) +- Style + - Correction des media queries dans sm-only, md-only, lg-only (#14611 by @sinchang) + +#### Optimisation + +- Chore + - Ajouter la description de la page web (#14802 par @iamkun) + +### 2.6.3 + +*2019-03-21* + +#### Corrections de bugs + +- Correction du style de la démo de Cascader (#14789 par @ziyoung) +- Suppression des opérations DOM inutiles (#14788 by @ziyoung) +- Correction DatePicker valeur par défaut DST (#14562 par @wacky6) + +### 2.6.2 + +*2019-03-21* + +##### Nouvelles fonctionnalités + +- DatePicker + - Ajout d'une plage de mois pour l'attribut type (#14487 par @zxyRealm) +- i18n + - Ajout de la locale croate (#14360 par @danijelh) + +##### Corrections de bugs + +- Input + - Correction d'un régression (#14572 par @wacky6) +- DatePicker + - Correction du calcul du premier jour de la semaine (#14523 par @sinchang) + - Correction du format de valeur du sélecteur de semaine (#13754 par @wacky6) +- Steps + - Correction du problème #14502 (#14596 par @sinchang) + - Correction du style avec le thème simple (#14610 par @sinchang) +- Docs + - Mise à jour de la doc française pour la 2.6.1 et correction de fautes de frappe (#1455555 par @smalesys) + - Renommage d'une variable dans la documentation de la table (#14587 par @likwotsing) + - Ajout de l'index de recherche en français (#14565 par @iamkun) + - Correction du style de la page TimePicker (#14579 par @ziyoung) + - Renommage d'une variable dans la page Upload (#14593 par @liupl) + - Mise à jour de la traduction française (#14643 par @smalesys) + - Mise à jour de la documentation du validateur de formulaire asynchrone (#14694 par @iamkun) + - Correction d'une erreur de doc tooltip (#14748 par @iamkun) + - Correction d'une coquille (#14751 par @2bj) + - Correction de la surbrillance pour Webkit touch (#14703 by @VladG0r) + +##### Optimisation + +- Tâche + - Mise à jour du script de build dans le ci (#14600 par @ziyoung) + - Mise à jour du tracking ga (#14560 par @iamkun) + - Ajout d'un événement ga supplémentaire (#14633 par @iamkun) + - Mise à jour du groupe de discussion (#14741 par @iamkun) + - Mise à jour des deps de test et conf (#14735 par @wacky6) + - Mise à jour de Gulp (#14745 by @ziyoung) + - Utilisez le codepen pour afficher les démos et correction d'une erreur de doc (#14747 by @ziyoung) + +### 2.6.1 + +*2019-03-03* + +#### Corrections de bugs + +- **Ne pas spécifier la version de node** (par @iamkun dans #14546) +- Correction du répertoire doc dans `deloy-faas.sh` (par @ziyoung dans #14553) +- Correction d'un problème de style de date dans le changelog de la 2.6.0 (par @island205 dans #14547) +- Correction d'une typo dans la doc (par @wack6 dans #14552) + +### 2.6.0 + +*2019-03-01* + +#### Nouvelles fonctionnalités +- Timeline + - Ajout d'un composant timeline (par @jikkai dans #14248) +- DropdownItem + - Ajout de la propriété `icon` à `el-dropdown-item` (par @gabrielboliveira dans #14088) +- Input + - Ajout de propriétés pour afficher les mots de passe (par @phshy0607 dans #13966) +- Select + - Ajout du slot `empty` (par @elfman au #13785) +- Autocomplete + - Ajout de la propriété `highlight-first-item` (par @YamenSharaf dans #14269) +- I18n + - Création de la locale Arménienne (par @hamletbarsamyan dans #14214) +- Docs + - Traduction française (par @smalesys dans #12153, #14418, #14434) + +#### Optimisation +- Alert + - Mise à jour de la classe du slot par défaut de la description de Alert (par @iamkun dans #14488) +- Input + - Mise à jour de l'input de type password (par @iamkun dans #14480) +- InputNumber + - Retrait d'un parseFloat inutile (par @JuniorTour au #14172) +- Menu + - Ajout du support de `el-menu-item` sans index (par @georgyfarniev dans #13298) +- Table + - Suppression de certaines opérations du DOM (par @elfman dans #13643) +- Upload + - Optimisation du code (par @elfman dans #13973) +- Popup + - Optimisation du code (par @KAionro dans #14413) +- Docs + - Ajout de détails sur la façon d'exécuter le mode play pour les contributeurs (par @island205 dans #14355) + - Ajout d'un avertissement concernant Input (par @wacky6 dans #14463) + - Mise à jour de la doc de Table (par @luguokong dans #14329) + - Mise à jour de la doc d'Input (par @iamkun dans #14437) + - Mise à jour de la doc sur le thème (par @wangguohaohao dans #14297) + - Le style de l'icône change lorsque vous passez dessus (par @tuxinghuan dans #14295) +- Build + - Minification du CSS et du JS pour le site d'Element (par @iamkun dans #14430) + - Accélération de webpack (par @hetech dans #14484) + - Utilisation du cli pour sélectionner la version de publication (par @hetech dans #14354) +- Installation de stale pour la gestion des issues (par @island205 dans #14392) + +#### Corrections de bugs +- Menu + - Correction d'un bug de focus des sous-menus lors du changement d'onglet du navigateur (par @liupl dans #13976) +- MessageBox + - Correction de la définition du type (par @NateScarlet dans #14278) +- ScrollBar + - Empêche le clic droit sur le bouton du pouce (par @xifeiwu dans #14196) +- Switch + - Déclenchement de la validation du formulaire si la valeur change (par @hetech dans #14426) +- Table + - La méthode toggleAllSelection est maintenant une méthode d'instance (par @letanure dans #14075) +- Tabs & Dropdown + - Correction du style (par @hetech dans #14452) +- Tree + - Les tips sont différents des tableaux (par @ColinCll dans #14331) +- Docs + - Correction d'une erreur de doc du DatetimePicker (par @iamkun dans #14290) + - Problème d'orthographe dans la documentation du DatePicker (par @helmut dans #14481) + - Correction du style de la doc de Pagination(par @liuchuzhang dans #14451) + +#### Breaking changes +- Table + - Fix params order of row events (by @jikkai in #12086) + +### 2.5.4 + +*2019-02-01* + +#### Corrections de bugs + +- Build: Correction d'un problème de configuration de babel qui cassait la transition collapse (par @island205 dans #14282) + +### 2.5.3 + +*2019-01-31* + +#### Optimisation + +- Optimisation du code de Message (par @vok123 dans #14029) +- Suppression des gh-pages (par @ziyoung dans #14266) +- Ajout du lien IssueHunt (par @island205 dans #14261) + +#### Corrections de bugs + +- Correction d'une erreur du module UMD côté serveur (par @island205 dans #14242) +- Correction du style du TabBar actif (par @iamkun dans #14240) +- Correction d'une erreur de code dans la démo de Table (par @xunmeng dans #14253) + +### 2.5.2 + +*2019-01-27* + +#### Optimisation +- Docs: + - Mise à jour du ChangeLog ES 2.5.1 (par @Gonzalo2310 dans #14231) + +#### Corrections de bugs +- Build: + - Suppression des commentaires non supprimés dans le module umd `lib/index.js` (par @island205 dans #14233) + - Correction d'une erreur d'exportation dans le module commonjs utilisé dans nuxt.js (par @island205 dans #14232) + - Correction des problèmes de build 2.5.1 (par @iamkun dans #14228) + +### 2.5.1 + +*2019-01-26* + +#### Optimisation +- DatePicker: surbrillance du mois et de l'année courants (par @Debiancc dans #14211) +- Mise à jour du changelog 2.5.0 (par @wacky6 dans #14217) + +#### Corrections de bugs +- Correction d'un problème d'exportation due par la mise à jour du webpack (par @island205 dans #14220) +- Conservation de la docs 2.4.11 && nouveau sous-dossier pour 2.5+ (par @iamkun dans #14222) + +### 2.5.0 + +*2019-01-25* + +#### Nouvelles fonctionnalités +- DatePicker + - Ajout de l'attribut `validate-event` (par @ziyoung dans #13531) +- DateTimePicker + - `pickerOptions` supporte l'option `selectableRange` (par @eeeeeeeeeeeason) +- Tag + - Ajout de l'événement `click` (par @licdream dans #14106) +- I18n + - Support de la langue kirghize (par @zzjframework dans #14174) + +#### Optimisation +- Mise à niveau vers webpack@4 (par @jikkai dans #14173) +- Input + - Simplification de l'implémentation, suivant un flux de données à sens unique. Correction de plusieurs bugs liés. (par @wacky6 dans #13471) +- Mise à jour du fichier Axure avec de nouveaux composants (par @ziyoung dans #13773) + +#### Corrections de bugs +- Autocomplete + - Correction de la dernière ligne du menu déroulant qui était coupée (#13597) (par @ziyoung) + - Correction d'une flèche de popper manquante (#13762) (par @liuchuzhang) +- Carrousel + - Nettoyage du timer lorsque le composant est détruit (#13820) (par @elfman) +- Cascader + - Suppression de la propriété obsolète des props calculées (#13737) (par @iamkun) + - Correction de la définition du type CascaderOption dans TypeScript (#13613) (par @NateScarlet) + - Correction de l'icône couvrant le texte (#13596) (par @ziyoung) +- Checkbox + - Refonte du style (par @PanJiaChen) +- DatePicker + - Ajout d'un `key` de v-for manquant dans TimeSpinner (#13547) (par @Ende93) + - Correction du surlignage de la semaine dans la bordure de l'année (#13883) (par @suyi91) +- Input + - Correction de la référence de textarea dans le DOM (#13803) (par @laomu1988 @island205) +- Pagination + - La valeur d'entrée ne sera pas inférieure à 1 (#13727) (par @elfman) +- Popover + - Correction d'un problème de popover avec le déclencheur de hover (#13104) (par @goldengecko) + - Correction d'une fuite de mémoire de l'instance popper (#13988) (par @qpxtWhite) +- Radio + - Refonte du style (par @ohhhoney1) +- Table + - Amélioration du tri des tables en cliquant sur la flèche de tri (#12890) (par @ohhoney1) + - Correction d'un problème d'alignement vertical du texte vide sur IE10+ (#13638) (par @imzjy) + - Correction de la documentation sur le type d'index (#13628) (par @ilovefafafa) + - Correction du problème d'affichage `show-summary` lorsque le header multi-niveaux est fixe (#13914) (par @luckyCao) +- Tabs + - Correction d'un bug de défilement automatique (#13696) (par @iamkun) + - Obtenir l'onglet correct par le nom de l'onglet (#13705) (par @iamkun) + - Utilisez paneName au lieu de name pour déterminer le style du panneau (#13733) (par @iamkun) +- Tree + - Correction de la propriété `showCheckbox` sur `Tree` qui ne pouvait pas affecter leurs `tree-node` enfants(par @KidneyFlower) + - Mise à jour des fichiers de doc et de définition (#13540) (par @ziyoung) +- Upload + - Ajout de le propriété `url` au fichier uploadé lorsque `list-type` est modifié (#13771) (par @elfman) +- Slider + - Correction de l'indentation du code source (#13955) (par @wacky6) +- I18n + - Ajout des traductions manquantes en catalan (par @jaumesala) + - Ajout de la traduction russe manquante (#13658) (par @justlp) + - Correction des traductions en finnois (#14137) (par @jenkrisu) +- Doc + - Mise à jour de la documentation espagnol depuis la 2.4.11 (#13522) (par @Gonzalo2310) +- Autres + - Suppression d'un script inutile (par @ziyoung) + - Correction des ancres (#13753) (par @iamkun) + - Correction de l'incohérence des majuscules dans la documentation (par @wonderjar) + - Ajout du QR code du chat DingDing au readme (#13957) (par @iamkun) + - Ajout des logs yarn au .gitignore (#13922) (par @mimimi) + - Suppression du sponsor duotai (#14156) (par @island205) + - Mise à jour du QR code dans le readme (#13960) (par @iamkun) + - Mise à jour du lien CDN, correction d'une typo (par @ziyoung) + +### 2.4.11 + +*2018-11-21* + +- Revert pr #13296. Correction d'un clic sur Menu externe causant l'effondrement du SubMenu, #13478 +- Ajustement des points de rupture media query sur petit écran (xs), #13468 (par @alekoshen712) + +### 2.4.10 + +*2018-11-16* + +- Correction des clics multiples sur Select pour afficher la liste déroulante, #13268 +- L'icône d'effacement des champs n'est pas affichée lorsque Form est désactivé, #13208 +- Ajustement des styles de Select, Progress, Autocomplete, Tooltip, Collaspe, TimePicker, #13188 (par @porcelainHeart) #13210 #13266 #13266 #13257 #13290 #13347 (par @PanJiaChen) +- Ajout de l'attribut `loop` dans le composant Carrousel, #13217 +- Lorsque les données de Table changent, la ligne en surbrillance reste, #13200 +- Le slot du header de Table peut recevoir des paramètres, #13263 +- La méthode `clearFilter` de Table peut recevoir des arguments, #13176 +- La bulle d'aide n'est plus créée lorsqu'il n'y a pas de contenu dans la cellule de Table, #13152 (par @rongxingsun) +- Le contenu de la zone de saisie du panneau ColorPicker peut être affiché correctement, #13278 +- ColorPicker ne déclenche plus la validation des formulaires lors du glisser-déposer, #13299 +- InputNumber: ajout de la méthode `select`, #13286 (par @st-sloth) +- AutoComplete: ajout de l'événement `clear`, #12171(par arthurdenner) #13326 +- Vous pouvez fermer Menu en cliquant à l'extérieur, #13296 +- La méthode `validateField` du formulaire peut recevoir des arguments, #13319 +- Cascader: ajout de l'événement `visible-change`, #13415 +- DatePicker: a ajout d'un slot pour les séparateurs d'intervalle, #13272 (par @milworm) +- Tree: ajout des propriétés `iconClass` et `currentNodeKey`, #13337 #13197 (par @isnifer) +- Progress: ajout du texte de statut #13198 (par @ali-master) +- Correction de `defaultCheckedKeys` de Tree, #13349 (par @dive2Pro) + +### 2.4.9 + +*2018-10-26* + +- Le paramètre `clearValidate` de Form supporte les strings #12990 (par @codinglobster) +- Ajout de l'attribut `type` pour Badge, #12991 +- Les utilisateurs peuvent utiliser scoped-slot pour personnaliser l'en-tête de colonne de Table #13012 (par @ivanseidel) +- Correction du champ de Select incapable d'entrer du texte sous IE, #13034 (par @GaliMU) +- Les options Select ne s'enroule pas lorsque l'espace est suffisant, #12329 (par @akki-jat) +- Lorsque la liste déroulante de Select est ouverte, l'icône de la flèche s'affichera également correctement, #12353 (par @firesh) +- Correction de l'attribut de taille de Select qui ne fonctionnait pas, #13070 +- La sélection de plusieurs valeurs peut aussi être effacée, #13049 (par @ZSkycat) +- Correction du dernier TabNav qui ne pouvait pas être supprimé, #13039 +- Correction d'un problème d'affichage du label TabNav, #13178 +- Ajout d'un slot de titre pour Alert, #13082 (par @Kingwl) +- Correction d'un problème où le contenu de l'infobulle de Table était incorrect, #13159 (par @elfman) +- Optimisation de l'animation de Upload lorsque le fichier est supprimé, #12987 +- Style ajusté pour InputNumber lorsque le bouton de commande n'est pas affiché, #13052 + +### 2.4.8 + +- Ne pas afficher le contour lorsque le Switch est focus, #12771 +- Correction du style de Dropdown dans ButtonGroup, #12819 (par @bluejfox) +- Ajout d'un événement d'ouverture pour Dialog, #12828 +- Correction de l'ordre d'affichage incorrect de TabNav, #12846 +- Correction d'un problème qui empêchait les Tabs de défiler jusqu'à l'onglet sélectionné, #12948 +- Correction d'un problème de l'identificateur qui ne s'affiche pas lorsque le noeud de Tree est glissé, #12854 +- Le paramètre de l'événement validation du formulaire contient le message de validation #12860 (par @YamenSharaf). +- Correction de DatePicker pour ne pas vérifier la validité du temps d'entrée de l'utilisateur, #12898 +- Correction d'un problème avec l'attribut `render-header` de l'en-tête de table qui ne fonctionnait pas, #12914 + +### 2.4.7 + +*2018-09-14* + +- Correction de DatePicker ne déclenchant pas la validation du formulaire, #12328 #12348 +- Correction des erreurs lancées par DatePicker en mode multiple, #12347 +- Correction d'une position incorrecte du spinner de DatePicker, #12415 (par @rang-ali) +- Correction du remplissage automatique de la zone de saisie de DatePicker, #12521 (par @abdallanayer) +- Correction du champ non-subrillant dans Cascader, #12341 +- Correction d'un mauvais ordre de Tabpane, #12346 +- Correction d'une position incorrecte du curseur ColorPicker, #12376 (par @cnwhy) +- Correction du style de SubMenu, #2457 +- Correction de la surbrillance après la sélection de SubMenu, #12479 +- Correction des valeurs incorrectes sélectionnées par Cascader, #12508 (par @huangjinqiang) +- Correction d'une valeur incorrecte dans le champ d'entrée Pagination, #12525 +- Correction de l'ordre dans lequel la Pagination déclenche les événements, #12530 +- Correction des filtres de table non-affichés, #12539 +- Correction de l'arbre incapable de supprimer des nœuds, #12684 +- Correction de la hauteur de Select Input changeant en mode simple, #12719 +- Correction d'un style du label de FormItem sous forme imbriquée, #12748 +- Ajout de l'attribut `autocomplete` pour Input, `auto-complete` devenant obsolète, #12514 (par @axetroy) +- Ajout des slots-scope pour Form pour afficher les informations de validation, #12715 (par @YamenSharaf) + +### 2.4.6 + +*2018-08-09* + +- Correction de Table n'affichant pas l'icône de filtre lorsque `filters` est un tableau vide, #12165 +- Correction de Menu ne sauvegardant pas l'état actif lorsque `collapse` change, #12178 (par @elfman) +- Correction du Cascader n'échappant pas les caractères spéciaux poue les Regexp, #12248 +- Correction d'un bouton Radio désactivé affichant l'ombre d'une case lorsqu'on clique dessus, #12262 +- Correction de arrow key qui n'a pas d'effet lorsque la valeur par défaut est `undefined`, #12322 +- Correction de la fonction de requête de Select non-stabilisée en mode multi, #12181 +- Correction du mot-clé de la requête Select disparaissant en mode multi, #12304 +- Correction d'une largeur incorrecte de Dialog lorsqu'il est affiché en plein écran, #12203 +- Correction de l'affichage incorrect de Main sur IE, #12237 +- Correction de Input déclenchant deux validations de formulaire, #12260 +- Correction de l'ajout d'un nouveau nœud d'arborescence provoquant la disparition des nœuds, #12256 +- Correction d'un nœud d'arborescence non supprimé après avoir glissé, #12279 +- Correction du Popover non-visible quand InputNumber a le focus, #12284 +- Ajout de l'attribut `popper-append-to-body` pour Autocomplete, #12241 +- Ajout du support du modificateur `sync` pour l'attribut `page-size` de Pagination, #12281 + +### 2.4.5 + +*2018-07-26* + +- Correction du réglage de Table `class-name` qui ne fonctionne pas pour les colonnes `expand`, #12006 +- Ajout de la méthode `toggleAllSelection` pour Table, #12047 +- Correction d'une mauvaise position du slot de suffixe lorsque Input contient Select, #12108 +- Correction de `line-height` de l'option impossible à régler, #12120 +- Correction de TimeSelect avec la valeur par défaut `null` ne pouvant être assigné après avoir exécuté `resetField`, #12010 +- Correction d'un événement keydown qui n'étant pas arrow key ne fonctionne pas dans Tree, #12008 +- Correction d'un nœud parent vérifié en mode lazy, #12106 +- Ajout du paramètre `includeHalfChecked` pour getCheckedNodes de Tree, #12014 + +### 2.4.4 + +*2018-07-13* + +- Correction du déclenchement de la validation de Select après la réinitialisation du formulaire, #11837 +- Correction d'une mauvaise position du slot `suffix` de Input lorsque le slot `suffixe` est avec le slot `append`, #11951 +- Correction de Input affichant toujours l'icône clear même en lecture seule, #11967 +- Correction d'un nœud d'arborescence coché lorsqu'il est désactivé, #11847 +- Correction des `default-checked-keys` qui ne fonctionnait pas, #11971 +- Correction de `empty-text` non visible lorsque le noeud de Tree est filtré, #11971 +- Correction de la position du `empty-text` surdimensionné dans Table, #11965 +- Correction de la surbrillance de la ligne de Table lorsque `current-row-key` est assignée à `null`, #11866 +- Correction de l'affichage de la liste déroulante des filtres lorsque `filters` est un tableau vide, #11864 +- Correction du label de Radio qui n'arrête pas la propagation des événements, #11912 + +### 2.4.3 + +*2018-07-03* + +- Correction de `allow-drop` qui ne fonctionnait pas correctement lorsque les nœuds de Tree avaient une hauteur personnalisée, #11797 +- Maintenant vous pouvez passer un paramètre à la méthode `clearValidate` du formulaire, en spécifiant quels résultats de validation FormItems doivent être effacés, #11821 +- Ajout de l'attribut `distinguishCancelAndClose` pour MessageBox, #11831 + +### 2.4.2 + +*2018-06-26* + +- Maintenant `class-name` et `label-class-name` de Table sont réactifs, #11626 +- Correction de Table qui mettait toujours en surbrillance la ligne cliquée lorsque `highlight-current-row` était `false`, #11646 +- Correction d'un bug de style de ButtonGroup lorsqu'il n'a qu'un seul bouton `round` ou `circle`, #11605 +- Correction du style du Select de Pagination, #11622 +- Correction de la méthode `open` du menu quand `collapse` est dynamiquement changé, #11646 +- Ajout des paramètres `activeName` et `oldActiveName` au hook before-leave de Tabs, #11713 +- Correction de Cascader ayant le focus après avoir cliqué à l'extérieur, #11588 +- Correction de Cascader ne se fermant pas quand l'option est cliquée quand `change-on-select` est `true`, #11623 +- La mise à jour programmatique de la valeur de Select déclenchera la validation du formulaire, #11672 + +### 2.4.1 + +*2018-06-08* + +- Suppression du duplicata de la déclaration de type pour Autocomplete, #11388 +- Correction du style de flèche déroulante de Select dans FireFox lorsqu'il est imbriqué dans Form, #11427 +- Correction de l'icône de l'option de Select qui s'affiche toujours lorsque la valeur initiale est `null`, #11460 +- Correction d'un Radio désactivé affichant l'ombre de la boîte quand on clique dessus, #11462 +- Ajout de l'attribut `iconClass` pour MessageBox, #11499 +- Ajout de l'attribut `stretch` pour Tabs, #11476 +- Correction d'un problème d'ordre de rendu de TabPane lorsque Tabs est `lazy`, #11461 +- Correction de Table ne conservant pas la surbrillance de la ligne actuelle lors de son ouverture, #11464 +- Correction de l'état de la mise au point lorsque `before-leave` renvoie une promesse résolue, #11386 +- Correction de la désactivation du Popover qui créait encore des poppers, #11426 +- Correction de la boucle sans fin de Tree lorsqu'un nouveau noeud est ajouté en mode lazy, #11430 (par @wangjingf) +- Ajout de l'événement `closed` pour Dialog, #11490 + +### 2.4.0 Fullerene + +*2018-05-28* + +#### Nouvelles fonctionnalités +- Général + - L'outil de développement et le bundler sont basculés vers le webpack natif, #11216 + - Vous pouvez maintenant définir globalement l'index z initial des popups, #11257 +- Autocomplete + - Ajout de l'attribut `hide-loading`, #11260 +- Button + - Vous pouvez maintenant utiliser l'attribut `size` sur les boutons circulaires pour contrôler leur taille, #11275 +- InputNumber + - Ajout de l'attribut `precision`, #11281 +- Tabs + - Ajout de l'attribut `before-leave`, #11259 + - Ajout de l'attribut `lazy`, #11167(by @Kingwl) +- Table + - Ajout de la méthode `sort` pour trier manuellement la table, #11311 + +#### Corrections de bugs +- Input + - Correction d'un problème qui provoquait un re-rendu lors de l'utilisation de l'IME chinois pour saisir rapidement du texte, #11235 (par @STLighter) +- Popover + - Correction de l'erreur de console lorsque l'élément déclencheur est Radio ou Checkbox, #11265 +- Breadcrumb + - Correction de l'attribut `to` ne supportant pas la mise à jour dynamique, #11286 +- Upload + - Correction de l'erreur de console lorsqu'un fichier est résolu dans la promesse retournée de la méthode `beforeUpload`, #11297 (par @qusiba) +- Infobulle + - Correction d'une flèche mal positionnée lorsque le contenu est vide, #11335 +- Autocomplete + - Correction de suggestions d'entrée incorrectes après la suppression rapide d'un mot-clé, #11323 +- ColorPicker + - Correction d'un événement `active-change` se déclenchant incorrectement lorsque le menu déroulant du picker est fermé, #11304 +- Table + - Correction d'une erreur de style du panneau de filtre surdimensionné, #11314 + - Correction de la ligne actuellement sélectionnée qui n'était pas conservée lors du tri de la table, #11348 +- Checkbox + - Correction d'une checkbox unique ne supportant pas la validation, #11271 +- Radio + - Correction du Radio désactivé quand même sélectionné en appuyant sur la touche espace, #11303 +- MessageBox + - Correction de la classe `el-popup-parent-hidden` qui n'était pas supprimée à l'ouverture successive de MessageBox, #11371 + +### 2.3.9 + +*2018-05-18* + +- Correction d'une erreur lorsque les données source n'ont pas le champ spécifié par l'attribut `prop` d'une TableColumn, lorsque la souris se déplace dans les cellules de cette colonne, #11137 +- L'attribut `lockScroll` des composants popup n'ajoute plus un style en ligne à l'élément parent, mais ajoute un nom de classe, #1111114 +- Correction de l'icône de Progression qui ne s'affichait pas quand son `status` était une exception, #11172 +- Correction de l'attribut `désactivé` qui ne fonctionnait pas dans la liste des résultats de filtrage du Cascader filtrable, #11185 +- Correction d'un problème où la ligne étendue de la table ne peut pas être réduite si la source de données est mise à jour après son extension, #11186 +- `setCurrentKey` de Tree accepte maintenant `null` comme paramètre pour annuler le noeud actuellement mis en surbrillance, #11205 + +### 2.3.8 + +*2018-05-11* + +- Correction du saut du panneau DatePicker au mois courant après avoir choisi une date dans un mois non courant quand `type` est dates, #10973 +- Correction de l'Input effaçable affichant toujours l'icône d'effacement en lecture seule, #10912 +- Correction de la fermeture du panneau DatePicker sans changer la valeur déclenchant incorrectement l'événement `change`, #11017 +- Correction d'un problème de navigation du clavier lorsque Select a regroupé les options, #11058 +- Ajout du slot nommé `préfixe` pour Select, #11063 +- Ajout de la méthode `clearValidate` pour FormItem, #11076 +- Ajout de l'attribut `checkOnClickNode` pour Tree, #1111111 + +### 2.3.7 + +*2018-04-29* + +- Correction d'une table qui ne mettait pas à jour ses largeurs de headers lorsque la barre de défilement disparaissait à cause du filtrage, #10834 +- Correction de l'Input effaçable affichant toujours l'icône d'effacement lorsque sa valeur initiale est `null`, #10912 +- Correction d'un déclencheur incorrect de l'événement `active-change` après avoir changé la valeur liée de ColorPicker par programmation, #10903 (par @zhangbobell) +- Correction du Select filtrable qui provoquait une boucle infinie lors de la navigation dans les options à l'aide du clavier si toutes les options sont désactivées, #10945 + +### 2.3.6 + +*2018-04-21* + +- Correction d'un comportement incorrect du callback `allow-drop` de Tree lorsque le paramètre `type` est utilisé, #10821 +- Maintenant vous pouvez entrer correctement les mots-clés dans le Select simple filtrable dans IE11, #10822 +- Correction d'un Select simple déclenchant incorrectement un événement `blur` après avoir cliqué sur une option, #10822 + +### 2.3.5 + +*2018-04-20* + +- Correction d'une surbrillance incorrecte dans le panneau DatePicker lorsque `type` est la semaine, #10712 +- Correction d'un InputNumber vide lorsque sa valeur initiale est 0, #10714 +- Ajout de l'attribut `automatic-dropdown` pour Select, #10042 (par @Seebiscuit) +- Correction de Rate désactivé quand même mis à jour par les touches de navigation, #10726 (par @Richard-Choooou) +- L'attribut `type` de DatePicker peut être `dates`, où vous pouvez choisir plusieurs dates dans un sélecteur, #10650 (par @Mini256) +- Ajout des événements `prev-click` et `next-click` pour Pagination, #10755 +- Ajout de l'attribut `pager-count` pour Pagination, #10493 (par @chongjohn716) +- Ajout de `type` comme 3ème paramètre de l'attribut `allow-drop` de Tree, #10792 +- Nous utilisons maintenant ResizeObserver pour détecter le redimensionnement des éléments DOM, #10779 + +### 2.3.4 + +*2018-04-12* + +- Suppression du double de l'attribut `showTimeout` dans la déclaration TypeScript de SubMenu, #10566 (par @kimond) +- Vous pouvez maintenant personnaliser les éléments de Transfert en utilisant le scoped slot, #10577 +- Correction d'un clic sur le bouton précédent désactivé et le bouton suivant de la pagination déclenchant toujours l'événement `current-current-change`, #10628 +- Correction de Textarea affichant `undefined` dans le SSR lorsque sa valeur n'est pas définie, #10630 +- Correction de la désactivation du style TabItem lorsque `type` est border-card, #10640 +- Ajout de `$index` comme quatrième paramètre du `formatter` de la Table, #10645 +- Correction de CheckboxButton non exporté dans la déclaration TypeScript, #10666 + +### 2.3.3 + +*2018-04-04* + +- Ajout de l'attribut `shadow` pour Card, #10418 (par @YunYouJun) +- Correction de Badge masqué lorsque `value` est `0`, #10470 +- Correction de quelques bugs de Tree, #10474 #10494 +- Ajout de `placement` pour Autocomplete, #10475 +- L'attribut `default-time` fonctionne également dans DateTimePicker, #10321 (par @RickMacTurk) +- Suppression du contour bleu de TabItem après que le navigateur n'ait plus le focus ou soit minimisé, #10503 +- Ajout de l'attribut `popper-append-to-body` pour SubMenu, #10515 +- Suppression du feedback visuel lors du survol d'un élément BreadcrumbItem non lié, #10551 +- Correction de l'événement `change` d'InputNumber pour s'assurer que la valeur liée du composant est mise à jour dans le gestionnaire d'événements, #10553 + +### 2.3.2 + +*2018-03-29* + +- Correction d'une régression d'Autocomplete, #10442 + +### 2.3.1 + +*2018-03-29* + +- Correction d'une régression de `type` d'Inputqui n'était pas transmis à l'élément natif, #10415 +- Ajout de la méthode `blur` pour Select, #10416 + +#### 2.3.0 Diamant + +*2018-03-28* + +#### Nouvelles fonctionnalités +- Table + - Maintenant le `formatter` de TableColumn peut être mis à jour dynamiquement, #10184 (par @elfman) + - Ajout de l'attribut `select-on-indeterminate`, #9924 (par @syn-zeta) +- Menu + - Ajout de l'attribut `collapse-transition`, #8809 (par @limichange) +- Input + - Ajout de la méthode `select`, #10229 + - Ajout de la méthode `blur`, #10356 +- ColorPicker + - Ajout de l'attribut `predefine`, #10170 (par @elfman) +- Tree + - Ajout des attributs `draggable`, `allow-drop` et `allow-drag`, et `node-drag-start`, `node-drag-enter`, `node-drag-leave`, `node-drag-leave`, `node-drag-over`, `node-drag-end` et `node-drop`, #9251 #10372 (par @elfman) +- Form + - La méthode `validate` a maintenant un deuxième paramètre, contenant l'information des éléments de formulaire qui ont échoué à la validation, #10279 + - Ajout de l'événement `validate`, #10351 +- Progress + - Ajout de l'attribut `color`, #10352 (par @YunYouJun) +- Button + - Ajout de l'attribut `circle`, #10359 (par @YunYouJun) + +#### Corrections de bugs +- Form + - Correction du label de FormItem non aligné avec l'Input mixte, #10189 +- Menu + - Désormais, le menu réduit n'affichera la bulle d'aide que lorsque le slot `title` de l'élément MenuItem est défini, #10193 (par @PanJiaChen). +- Pagination + - Correction d'un événement `current-current-change` qui se déclenchait incorrectement sans interaction de l'utilisateur, #10247 +- DatePicker + - Maintenant, la date et l'heure dans le panneau déroulant sont correctement formatées en fonction de l'attribut `format`, #10174(by @remizovvv) +- Upload + - Correction de l'attribut `accept` qui ne fonctionnait pas quand `drag` est vrai, #10278 + +### 2.2.2 + +*2018-03-14* + +- Ajout de l'événement `clear` pour Input, #9988 (par @blackmiaool) +- Maintenant la saisie manuelle de ColorPicker supporte les modes `hsl`, `hsv` et `rgb`, #9991 +- Correction de DatePicker ne déclenchant pas l'événement `change` lorsque sa valeur initiale est effacée, #9986 +- Maintenant les attributs liés à la classe d'icônes de Rate supportent les mises à jour dynamiques, #10003 +- Correction de Table avec des colonnes fixes dont la hauteur n'est pas mise à jour correctement si `max-height` est réglé, #10034 +- Maintenant le mode plage de DatePicker supporte la sélection inverse (en cliquant sur la date de fin, puis sur la date de début), #8156 (par @earlymeme) +- Ajout de l'attribut `désactivé` pour Pagination, #10006 +- Ajout des événements `after-enter` et `after-leave` pour Popover, #10047 +- Correction de Select ne déclenchant pas la validation lorsque l'utilisateur sélectionne une option après avoir exécuté `resetFields` du formulaire, #10105 +- Correction des largeurs incorrectes des colonnes fixes de Table dans certains cas, #10130 +- Correction de MessageBox héritant de l'attribut `title` de son instance précédente lorsqu'il était appelé sans `title`, #10126 (par @Pochodaydaydayup) +- Ajout de l'attribut `input-size` pour Slider, #10154 +- Ajout des événements `left-check-change` et `right-check-change` pour Transfer, #10156 + +### 2.2.1 + +*2018-03-02* + +- Correction d'un rétrécissement de Aside, Header et Footer dans certaines mises en page, #9812 +- Correction de Table avec un attribut `height` qui ne rendait pas dans SSR, #9876 +- Correction d'une Table extensible ne calculant pas sa hauteur lorsqu'une rangée est agrandie, #9848 +- Correction d'un événement `change` qui ne se déclenchait pas lors de la saisie manuelle de la date dans DateTimePicker, #9913 +- Correction de Select affichant ses options lorsque la boîte de saisie est cliquée avec le bouton droit de la souris, #9894 (par @openks) +- Ajout de l'attribut `tooltip-class` pour Slider, #9957 +- Maintenant Select garde le focus après la sélection, #9857 (par @Seebiscuit) +- Ajout de l'attribut `target-order` pour Transfer, #9960 + +### 2.2.0 Graphite + +*2018-02-12* + +#### Nouvelles fonctionnalités +- Menu + - Ajout des attributs `popper-class` et `disabled` pour le sous-menu, #9604 #9771 + - Le menu horizontal prend maintenant en charge le sous-menu multicouche, #9741 +- Tree + - Ajout de l'évènement `node-contextmenu`, #9678 + - Vous pouvez maintenant personnaliser le modèle de nœud en utilisant un slot avec portée, #9686 + - Ajout des méthodes `getNode`, `remove`, `remove`, `append`, `insertBefore`, `insertAfter`, `getCheckedKeys`, `getHalfCheckedNodes`, `getHalfCheckedNodes`, `getHalfCheckedKeys` et de l'événement `check`, #9718 #9730 +- Transfer + - Ajout de la méthode `clearQuery`, #9753 +- Select + - Ajout de l'attribut `popper-append-to-body`, #9782 + +#### Corrections de bugs +- Table + - Correction d'un clic sur l'icône d'expansion d'une ligne extensible qui déclenche l'événement `row-click`, #9654 + - Correction de la mise en page non mise à jour lorsque la largeur des colonnes est modifiée par glisser-déposer de l'utilisateur, #9668 + - Correction d'un problème de style lorsque la ligne de résumé coexiste avec des colonnes fixes, #9667 +- Container + - Les composants fixes de Container ne s'étirent pas dans IE11, #9655 +- Loading + - Correction du chargement n'apparaissant pas lorsque la valeur de `v-loading` est changée en true dans le hook `mounted`, #9722 +- Switch + - Correction de deux événements de clics natifs déclenchés lorsque Switch est cliqué, #9760 + +### 2.1.0 Charcoal + +*2018-01-31* + +#### Nouvelles fonctionnalités +- Cascader + - Ajout des événements `focus` et `blur`, #9184 (par @viewweiwu) +- Table + - La méthode `filter-method` a maintenant un troisième paramètre `column`, #9196 (par @liyanlong) +- DatePicker + - Ajout des attributs `prefix-icon` et `clear-icon`, #9237 (par @AdamSGit) + - Ajout de l'attribut `default-time`, #9094 (par @nighca) + - Le format `value-format` supporte maintenant `timestamp`, #9319 (par @wacky6) +- InputNumber + - Maintenant la valeur liée peut être `undefined`, #9361 +- Select + - Ajouté l'attribut `auto-complete`, #9388 +- Form + - Ajout de l'attribut `désactivé`, #9529 + - Ajout de l'attribut `validateOnRuleChange`, #8141 +- Notification + - Ajout de la méthode `closeAll`, #9514 + +#### Corrections de bugs +- InputNumber + - Correstion du reset lors de la saisie du point des nombres décimaux, #9116 +- Dropdown + - Correction du mauvais positionnement du menu déroulant lorsque la page n'a qu'une barre de défilement horizontale dans certains navigateurs, #9138 (par @banzhuanmei) +- Table + - Correction d'une erreur dans le calcul du nombre de colonnes fixes après les changements de données des colonnes, #9188(by @kolesoffac) + - Correction de la bordure de la dernière colonne de l'en-tête groupé qui n'était pas correctement affichée, #9326 + - Correction d'un positionnement incorrect de l'en-tête du tableau dans Safari, #9327 + - Correction de la réduction des lignes extensibles lorsque les données de la table changent, #9462 + - Correction de rendus multiples inutiles dans certaines conditions, #9426 + - Correction d'une erreur de calcul de la largeur de colonne lors de la modification de `width` de TableColumn, #9426 +- Loading + - Correction de Loading ne se cachant pas correctement dans certaines conditions, #9313 +- DatePicker + - Correction de la méthode `focus` qui ne fonctionnait pas en mode "range", #9437 + - Correction du clic sur le bouton "now" qui sélectionnait toujours la date actuelle même si elle était désactivée, #9470 (par @wacky6) + - Correction d'une date trop serrée lors de la navigation, #9577 (par @wacky6) +- Steps + - Correction d'une erreur de style dans IE 11, #9454 + +#### Changements +- Menu + - Le menu contextuel en mode `collapse` s'ajoute maintenant directement à `body`, de sorte qu'il est visible lorsqu'il est imbriqué dans Aside, #9263 +- Table + - Maintenant, cocher les cases dans la Table multi-sélection ne déclenche pas l'événement `row-click`, #9467 +- Loading + - Le `z-index` du masque de chargement non plein écran est changé à 2000. Le `z-index` du masque de chargement plein écran se mettra à jour dynamiquement avec les composants popup, #9522 +- Dropdown + - Les attributs `show-timeout` et `hide-timeout` ne fonctionnent maintenant que lorsque le déclencheur est `hover`, #9573 + +### 2.0.11 + +*2018-01-08* + +- Correction d'un problème de couleur de bordure de Select dans les slots `prepend` ou `append` de Input, #9089 +- Correction du paramètre `remove-tag` de l'événement Select, #909090 +- Ajout des attributs `show-timeout` et `hide-timeout` pour le sous-menu, #8934 (par @HugoLew) +- Correction d'un style Tooltip manquant de `show-overflow-tooltip` lors de l'importation de Table sur demande, #9130 +- Correction d'un dysfonctionnement du tri des colonnes de la table après l'exécution de `clearSort` sur cette colonne, #9100 (par @zEmily) +- Le fichier de configuration i18n pour le tchèque est renommé de `cz` en `cs-CZ`, #9164 + +### 2.0.10 + +*2017-12-29* + +- Calcul erroné de la hauteur du tableau lorsque la colonne fixe et la ligne de somme coexistent, #9026 +- Correction d'un style de couleur non compilé du texte vide dans le tableau, #9028 +- Maintenant, DatePicker n'émet que l'événement `change` quand la valeur est vraiment changée, #9029 (par @remizovvvv) +- Ajout de l'attribut `tabindex` pour Input, #9041 (par @dicklwm) + +### 2.0.9🎄 + +*2017-12-24* + +- Ajouté la fonction de hook "avant suppression" pour Upload, #8788 (par @firesh) +- Correction de la valeur initiale de `error` qui ne fonctionnait pas pour FormItem, #8840 +- La directive Loading prend maintenant en charge le nom de classe personnalisé grâce à l'attribut `element-loading-custom-class`, #8826 (par @earlymeme) +- Correction CarouselItem devenant invisible lorsque les données sont mises à jour de manière asynchrone, #8921 +- Ajout de l'attribut `renderAfterExpand` pour Tree, #8972 + +### 2.0.8 + +*2017-12-12* + +- Ajout de la documentation en espagnol +- Correction du `show-timeout` de Dropdown qui ne fonctionnait pas quand le déclencheur est click, #8734 (par @presidenten) +- Correction du temps de validation des formulaires pour les règles dont le déclencheur est blur, #8776 +- Correction d'un événement de blur de DatePicker avec intervalle, #8784 +- L'attribut `format` de TimePicker supporte maintenant AM/PM, #8620 (par @firesh) + +### 2.0.7 + +*2017-11-29* + +- Correction du style du bouton de type texte désactivé, #8570 + +### 2.0.6 + +*2017-11-29* + +- Correction d'un bug de style des icônes de tri de la table, #8405 +- Correction du mécanisme de déclenchement de Popover lorsque son `trigger` est manuel, #8467 +- Ajout des attributs `prefix-icon` et `suffix-icon` pour Autocomplete, #8446 (par @liyanlong) +- Ajout de l'attribut `separator` pour Cascader, #8501 +- Ajout de l'attribut `clearable` pour Input, #8509 (par @lbogdan) +- Ajout de l'attribut `background` pour Pagination, #8553 + +### 2.0.5 + +*2017-11-17* + +- Correction de la régression Popover, Tree, Breadcrumb et Cascader dans 2.0.4, #8188 #8217 #8283 +- Correction d'une fuite de mémoire de la directive `clickoutside`, #8168 #8225 (par @badpunman @STLighter) +- Correction de la hauteur du Select multiple lorsque sa valeur est effacée, #8317 (par @luciy) +- Ajout de l'attribut `collapse-tags` pour plusieurs Sélectionner pour remplacer les balises par une ligne de texte, #8190 +- Correction d'une consommation CPU élevée causée par la table cachée, #8351 +- Maintenant vous pouvez utiliser la méthode `doLayout` de la Table pour mettre à jour sa disposition, #8351 + +### 2.0.4 + +*2017-11-10* + +- Accessibilité améliorée pour Cascader, Dropdown, Message, Notification, Popover, Tooltip et Tree. +- Correction du redimensionnement de Container lorsque la largeur de la fenêtre d'affichage diminue, #8042 +- Correction de la suppression incorrecte de `updateKeyChildren` dans Tree, #8100 +- Correction de la hauteur de la CheckboxButton avec bordure lorsque le bouton est imbriqué dans un formulaire, #8100 +- Correction d'une erreur d'analyse du menu pour les couleurs personnalisées, #8153 (par @zhouyixiang) + +### 2.0.3 + +*2017-11-03* + +- Correction des attributs `éditable` et `readonly` pour DatePicker avec intervalle, #7922 +- Correction d'une erreur de style des Tabs imbriqués, #7941 +- Correction d'une erreur de style de la dernière étape des Steps verticales, #7980 +- Correction de la synchronisation du déclenchement de l'événement `current-current-change` pour Pagination, #7995 +- Correction d'une infobulle non enregistrée dans Menu, #7995 + +### 2.0.2 + +*2017-10-31* + +- Un clic droit sur les boutons de InputNumber ne changera pas sa valeur, #7817 +- La méthode `validate` de Form peut maintenant attendre des validations asynchrones avant d'exécuter son callback, #7774 (par @Allenice) +- Correction de la plage de sélection de DatePicker ne fonctionnant pas dans les navigateurs Chromium 53-57, #7838 +- Correction des icônes manquantes de prévisualisation et de suppression de Upload lorsque son `list-type` est picture-card, #7857 +- Ajout de l'attribut `sort-by` pour TableColumn, #7828 (par @wangfengming) +- Correction de DatePicker affichant parfois un mauvais numéro d'année lors de la sélection de la première semaine en mode semaine, #7860 (par @hhh23485) +- Correction d'une erreur de style d'icône des Steps verticales, #7891 +- La 'hot area' pour les flèches de nœud dans Tree est étendue, #7891 + +### 2.0.1 + +*2017-10-28* + +- Correction d'une erreur de style de RadioButton et CheckboxButton, #7793 +- Correction de TimePicker qui ne répondait pas au défilement de la souris dans certaines conditions, #7811 +- Correction des styles incomplets de certains composants lors de l'importation à la demande, #7811 + +### 2.0.0 Carbon + +*2017-10-27* + +#### Nouvelles fonctionnalités +- Général + - Un nouveau thème : `theme-chalk`. + - L'accessibilité des éléments suivants est améliorée : Alert, AutoComplete, Breadcrumb, Button, Checkbox, Collapse, Input, InputNumber, Menu, Progress, Radio, Rate, Slider, Switch, Upload + - Ajout du typage TypeScript + - Toutes les icônes existantes sont redessinées. De nouvelles icônes sont ajoutées + - Ajout d'une série de classes basées sur les breakpoints qui masquent les éléments lorsque la taille de la fenêtre remplit certaines conditions + - Ajout des composants de mise en page : Container, Header, Aside, Main, Footer + - Vous pouvez maintenant configurer la taille des composants de manière globale. Lors de l'importation d'un élément, vous pouvez ajouter un objet de configuration global avec une propriété `size` pour configurer les tailles par défaut pour tous les composants. +- Button + - Ajout de l'attribut `round`. Il est utilisé pour les boutons à coins ronds #6643 +- TimeSelect + - Vous pouvez maintenant naviguer en appuyant sur les touches `Up` et `Down`, et en appuyant sur `Enter` vous sélectionnez l'heure #6023. +- TimePicker + - Vous pouvez maintenant naviguer à l'aide des touches fléchées, et en appuyant sur `Entrée` vous sélectionnez l'heure #6050. + - Ajout de `start-placeholder` et de `end-placeholder`. Ce sont des placeholders pour les deux champs en mode intervalle #7169 + - Ajout de l'attribut `farrow-control` pour faire tourner le temps avec les flèches #7438 +- Tree + - Maintenant les noeuds enfants ne font pas de rendu avant la première ouverture #6257 + - Ajout de l'attribut `check-descendants`. Il détermine si les nœuds enfants sont vérifiés lors du contrôle de leur nœud parent en mode `lazy` #6235 +- Tag + - Ajouté l'attribut `size` #7203 +- Datepicker + - Maintenant `timeFormat` peut formater le TimePicker quand le type est réglé sur `datetimerange` #6052 + - Ajout de `start-placeholder` et de `end-placeholder`. Ce sont des placeholders pour les deux champs en mode intervalle #7169 + - Ajout de l'attribut `value-format` pour personnaliser le format de la valeur liée, #7367 + - Ajout de l'attribut `unlink-panels` pour dissocier les deux panneaux de date lors de la sélection d'une plage de dates +- MessageBox + - Ajout de l'attribut `closeOnHashChange` #6043 + - Ajout de l'attribut `center` pour que le contenu puisse être centré #7029 + - Ajout de l'attribut `roundButton` pour afficher les boutons ronds #7029 + - Ajout de l'attribut `dangerouslyUseHTMLString`. Lorsqu'il est réglé sur `true`, `message` sera interprété comme une chaîne HTML\* #6043 + - Ajout de l'attribut `inputType` pour assigner le type de l'input intérieur, #7651 +- Dialog + - Ajout des attributs `width`、`fullscreen`、`append-to-body`. La boîte de dialogue peut maintenant être imbriquée + - Ajout de l'attribut `center` pour que le contenu puisse être centré #7042 + - Ajout de `focus-after-closed`、`focus-after-open` pour améliorer l'accessibilité #6511 +- ColorPicker + - Maintenant vous pouvez taper les couleurs dans le champ de saisie #6167 + - Ajout des attributs `size` et `disabled` #7026 + - Ajout de l'attribut `popper-class` #7351 +- Message + - Maintenant la couleur des icônes peut être modifiée par CSS #6207 + - Ajout de l'attribut `dangerouslyUseHTMLString`. Lorsqu'il est réglé sur `true`, `message` sera interprété comme une chaîne HTML\* #6207 + - Ajout de l'attribut `center` pour que le contenu puisse être centré #6875 +- Notification + - Ajout de l'attribut `position` pour configurer où Notification apparaît #6231 + - Ajout de l'attribut `dangerouslyUseHTMLString`. Lorsqu'il est réglé sur `true`, `message` sera interprété comme une chaîne HTML\* #6231 + - Ajout de l'attribut `showClose` pour cacher le bouton de fermeture #6402 +- Rate + - Ajout de l'attribut `show-score` pour déterminer si le score actuel est affiché #6295 +- Tabs + - Ajout de l'attribut `tab-position` #6096 +- Radio + - Ajout des attributs `border` et `size` #6690 +- Checkbox + - Ajout des attributs `border` et `size` #6690 +- Alert + - Ajout de l'attribut `center` pour que le contenu puisse être centré #6876 +- Menu + - Ajout des attributs `background-color`, `text-color` et `active-text-color` #7064 + - Ajout des méthodes `open` et `close` pour ouvrir et fermer les sous-menus par programmation, #7412 +- Form + - Ajout de l'attribut `inline-message` pour déterminer si le message de validation est affiché en ligne #7032 + - Ajout de l'attribut `status-icon` pour afficher une icône de feedback après validation #7032 + - Form et FormItem ont maintenant un attribut `size`. Les composants internes hériteront de cette taille s'ils ne sont pas spécifiés sur eux-mêmes, #7428 + - La méthode `validate` retournera maintenant une promesse si le rappel est omis, #7405 + - Ajout de la méthode `clearValidate` pour la validation des résultats pour tous les éléments de formulaire, #7623 +- Input + - Ajout des attributs `suffixe` et `préfixe` des slots nommés, `suffixIcon` et `prefixIcon` pour ajouter du contenu dans la zone de saisie #7032 +- Breadcrumb + - Ajout de l'attribut `separator-class` pour supporter les icônes comme séparateurs d'éléments #7203 +- Steps + - Ajout de l'attribut `simple` pour activer les étapes de style simple #7274 +- Pagination + - Ajout des attributs `prev-text` et `next-text` pour personnaliser les textes des pages précédente et suivante #7005 +- Loading + - Maintenant vous pouvez personnaliser l'icône et la couleur de fond avec les propriétés `spinner` et `background` #7390 +- Autocomplete + - Ajout de l'attribut `debounce`, #7413 +- Upload + - Ajout des attributs `limit` et `on-exceed` pour limiter le nombre de fichiers, #7405 +- DateTimePicker + - Ajout de l'attribut `time-arrow-control` pour activer `arrow-control` du TimePicker imbriqué, #743838 +- Layout + - Ajout d'un nouveau point d'arrêt `xl` pour les fenêtres plus larges que 1920px +- Table + - Ajout de l'attribut `span-method` pour la fusion de cellules + - Ajout de la méthode `clearSort` pour effacer le tri par programmation + - Ajout de la méthode `clearFilter` pour effacer le filtre par programmation + - Pour les lignes extensibles, lorsqu'une ligne est étendue, une classe `.expanded` sera ajoutée à sa liste de classes, afin que vous puissiez personnaliser son style + - Ajout de l'attribut `size` + - Ajout de la méthode `toggleRowExpansionRowExpansion` pour ouvrir ou réduire les lignes extensibles par programmation + - Ajout de l'attribut `cell-class-name` pour assigner un nom de classe aux cellules + - Ajout de l'attribut `cell-style` pour le style des cellules + - Ajout de l'attribut `header-row-class-name` pour assigner un nom de classe aux lignes d'en-tête + - Ajout de l'attribut `header-row-style` pour le style d'en-tête + - Ajout de l'attribut `header-cell-class-name` pour assigner un nom de classe aux cellules d'en-tête + - Ajout de l'attribut `header-cell-style` pour le style des cellules d'en-tête + - L'attribut `prop` de la tableColumn accepte maintenant les notations `object[key]` + - Ajout de l'attribut `index` pour TableColumn pour personnaliser les index de lignes +- Select + - Ajout de l'attribut `reserve-keyword` pour réserver le mot-clé de la recherche courante après avoir sélectionné une option. + +#### Corrections de bugs +- DatePicker + - Correction de `v-model` retournant le deuxième jour de la semaine sélectionnée en mode semaine #6038 + - Correction de la première entrée effacée dans le type `daterange` #6021 +- DateTimePicker + - Correction de DateTimePicker et TimePicker s'affectant l'un l'autre lors de la sélection #6090 + - Correction de l'heure et de la seconde qui peuvent être au-delà de la limite en sélectionnant l'heure #6076 +- TimePicker + - Correction de `v-model` qui ne se mettait pas à jour correctement lors du blur #6023 +- Dialog + - Correction des textes ayant des bords flous lors de l'ouverture et de la fermeture des listes déroulantes imbriquées #6088 +- Select + - Performances améliorées. Maintenant Vue dev-tool ne crashera pas quand un grand nombre de Select sont détruits #6151 +- Table + - Correction d'un bug ou la table reste masquée lorsque son élément parent apparaît depuis `display : none` + - Correction de l'extension de la largeur de la table lorsque l'élément parent a `display : flex` + - Correction d'un bug qui corrigeait le fait que les colonnes d'une table avec l'emplacement `append` disparaissaient lorsque les données étaient récupérées dynamiquement + - Correction de l'attribut `expand-row-keys` qui ne fonctionnait pas avec la valeur initiale + - Correction d'une défaillance du filtre lors de la mise à jour de `data` + - Correction d'une erreur de calcul dans la mise en page des colonnes fixes avec en-têtes groupés + - Correction d'un bug dynamique de `max-height` + - Correction de quelques erreurs de calcul de style + +#### Breaking changes +- Général + - Suppression de `theme-default`. + - Compatible avec Vue 2.5.2+ et IE 10+ + - L'événement `change` des composants de formulaire et l'événement `current-current-change` de la pagination ne se déclenchent plus que lors de l'interaction de l'utilisateur + - L'attribut `size` de Button et les composants de formulaire acceptent maintenant `medium`, `small` et `mini` + - Pour faciliter l'utilisation d'icônes tierces, les attributs `icon` du bouton et des étapes, `prefix-icon` et `suffix-icon` d'Input nécessitent maintenant un nom de classe complet +- Dialog + - Suppression de l'attribut `taille`. Maintenant la taille de Dialog peut être configurée par `width` et `fullscreen` + - Maintenant la visibilité de Dialog ne peut plus être contrôlée par `v-model` +- Rate + - Le `text-template` est renommé `score-template` +- Dropdown + - `menu-align` est renommé en `placement`. Maintenant il supporte plus de positions +- Transfert + - le `footer-format` est renommé en `format` +- Switch + - Les attributs commençant par `on-**` seront analysés pour les événements dans JSX, ce qui rend tous les attributs `on-*` de Switch incapable de fonctionner en JSX. Ainsi, les attributs `on-**` sont renommés en `active-*`, et par conséquent les attributs `off-*` sont renommés en `inactive-*`. Cette modification affecte les attributs suivants: `on-icon-class`, `off-icon-class`, `on-text`, `off-text`, `off-text`, `on-color`, `off-color`, `on-value`, `off-value` + - Les attributs `active-text` et `inactive-text` n'ont plus de valeurs par défaut +- Tag + - L'attribut `type` accepte maintenant `success`, `info`, ` warning` et `danger` +- Menu + - Suppression de l'attribut `theme`. La couleur du menu peut être configurée en utilisant `background-color`, `text-color` et `active-text-color` +- Input + - Suppression de l'attribut `icon`. L'icône du suffixe peut maintenant être configurée à l'aide de l'attribut `suffix-icon` ou du slot `suffix-icon` + - Suppression de l'attribut `on-icon-click` et de l'événement `click`. Maintenant pour ajouter le gestionnaire de clic sur les icônes, veuillez utiliser les slots nommés + - L'événement `change` se comporte maintenant comme dans l'input natif, qui ne se déclenche qu'en cas de blur ou en appuyant sur Entrée. Si vous avez besoin de répondre à l'entrée de l'utilisateur en temps réel, vous pouvez utiliser l'événement `input` +- Autocomplete + - Suppression de l'attribut `custom-item`. Le template de suggestions d'entrée peut maintenant être personnalisé en utilisant `scoped slot`. + - Suppression de l'attribut `props`. Vous pouvez maintenant utiliser l'attribut `value-key` pour désigner le nom de clé de l'objet de suggestion d'entrée pour l'affichage. +- Steps + - Suppression de l'attribut `center` + - Maintenant le Steps va remplir son conteneur parent par défaut +- DatePicker + - Le paramètre de l'événement `change` de DatePicker est maintenant la valeur liée elle-même. Son format est contrôlé par `value-format` +- Table + - Suppression de la prise en charge de la personnalisation du modèle de colonne à l'aide de `inline-template` + - `sort-method` s'aligne maintenant avec `Array.sort`. Il devrait retourner un nombre au lieu d'un booléen + - L'emplacement `append` est déplacé à l'extérieur de l'élément `tbody` pour éviter les rendus multiples + - L'événement `expand` est renommé en `expand-change` + - Les paramètres de la méthode `row-class-name` et `row-style` sont maintenant un objet + +## +* Rendre du HTML arbitraire de façon dynamique sur votre site Web peut être très dangereux car cela peut facilement mener à[des attaques XSS](https://en.wikipedia.org/wiki/Cross-site_scripting). Donc quand `dangerouslyUseHTMLString' est activé, assurez-vous que le contenu du `message' est fiable, et **ne jamais** assigner `message` au contenu fourni par l'utilisateur.. diff --git a/CHANGELOG.zh-CN.md b/CHANGELOG.zh-CN.md index a75557ab2e1..5b801c2b10c 100644 --- a/CHANGELOG.zh-CN.md +++ b/CHANGELOG.zh-CN.md @@ -1,5 +1,903 @@ ## 更新日志 +### 2.13.0 + +*2019-11-26* + +#### 新特性 + +- Popconfirm + - 新增 Popconfirm 组件 (#17548 by @iamkun) + +#### Bug fixes + +- BackTop + - 平滑过渡动画 (by @lon) +- DatePicker + - 修复选择最小日期的 bug (#17191 by @smk0621) +- Select + - 修复测试用例 (by @msidolphin) +- Tree + - 增加 font-size 样式 (#17094 by @spengjie) +- Table + - 头部可自定义 (#17291 by @ziyoung) + - 更新头部样式 (#17284 by @ziyoung) + - 修复时候 filter 之后高度问题 (#17348 by @ziyoung) + - 修复 row-style 失效的 bug (#17002 by @a631807682) + - 修复头部消失的 bug (#17341 by @ziyoung) +- Calendar + - 导入 el-button 和 el-button-group (#17376 by @masongzhi) +- MessageBox + - 修复图表位置 (#17410 by @nullptru) +- TimePicker + - 滚动后设置正确的位置 (#16868 by @mattheyan) +- Message + - 修复关闭的 offsetHeight(#17564) (#17852 by @gzwgq222) +- Form + - ValidateField 的回调应为可选项 (#17314 by @CarterLi) +- Cascader + - 修复 TypeScript 3.7 的兼容问题 (#17881 by @CarterLi) +- Menu + - 修复 NavigationDuplicated 在 vue-router@^3.1.0 的报错 (#17269 by @iamkun) +- Dropdown + - 更新类型文件 (#17550 by @iamkun) +- Progress + - 增加 strokeLinecap 属性 (#17552 by @iamkun) +- InfiniteScroll + - 跳过不可见元素触发 (#17553 by @iamkun) +- Image + - 优化用户体验 (#16985 by @luckyCao) + - 优化大图片展示问题 (#16796 by @luckyCao) +- Drawer + - 修复 drawer-append-to-body 失效的 bug (#16953 by @JeremyWuuuuu) +- Select + - 修复空 tag 的 bug (17199 by @luckyCao) +- Scrollbar + - 修复 FireFox 双滚动条的 bug (#18091 by @iamkun) + +#### Optimization + +- I18n + - 更新 sv-SE.js (#17926 by @FOLLGAD) + - 更新 avatar 组件法语文档 (#17762 by @blombard) +- Docs + - 修复 time-select 文档错误 (#17250 by @wacky6) + - 修复 Drawer 文档错误 (#17122 by @haoranyu) + - 更新 Spanish changelog 2.12.0 (#17364 by @Gonzalo2310) + - 修复 Changelog 文档错误 (#17874 by @renlixin) + - 修复 Loading 示例 (#17862 by @MBearo) + - 增加 input event 相关文档 (#18061 by @zhouxinyong) + - 移除 Input repeat change event 相关文档 (#18085 by @zhouxinyong) + +### 2.12.0 + +*2019-08-29* + +#### 新特性 + +- Popover + - 添加 close-delay 属性 (#16671 by @LachlanStuart) +- Theme + - 增加 Chrome 插件: Element Theme Extension (#16686 by @iamkun) +- Icon + - 支持 font-display 属性的配置 (#16805 by @iamfaizalandyka) + +#### Bug fixes + +- Table + - 在表头拖拽后阻止 click 事件的触发 (#16850 by @ziyoung) + - 修复表头 display 为 none 造成浏览器崩溃的问题 (#16956 by @luckyCao) + - 修复没有数据的时表格高度问题 (#16861 by @ziyoung) + - 调用 toggleExpansion 不再抛出异常 (#16304 by @yyjjqq94) + - 挂载时不再触发 sort-change 事件 (#17113 by @a631807682) + - 修复 setCurrentRow 方法不生效的问题 (#16879 by @ziyoung) + - 修复当数据异步加载时,expand-row-keys 不生效的问题 (#16899 by @ziyoung) + - 把 toggleAllSelection 设置为 Table 示例的属性 (#17137 by @ziyoung) +- Tree + - 修复文字与复选框之间的距离 (#16799 by @Hazlank) +- Tabs + - 修复 TabItem 位置不正确的问题 (#16520 by @victorting) + - 修复高亮的 Tab 不在可视区的问题 (#17033 by @nullptru) +- Calendar + - 修复日期的显示问题 (#16772 by @ubitoffee) + - 修复在夏令时的显示问题 (#17208 by @iamkun) +- Cascader + - 修复 CascaderPanel 的显示问题 (#16716 by @zhangHongEn) + - 禁用状态下,关闭按钮不显示 (#16224 by @yyjjqq94) +- Input + - 修复韩语输入问题 (#15069 by @MoonHyuk) + - 触发清除按钮的点击事件 (#16576 by @a631807682) +- Select + - 过滤时,不收起下拉框 (#17205 by @luckyCao) +- Transfer + - 修复样式问题 (#17206 by @iamkun) +- Dialog + - 添加 SCSS 变量 (#16365 by @haoranyu) +- RadioGroup + - is 指定时,不产生非法的 HTML 片段 (#17070 by @nullptru) +- Divider + - 支持自定义类 (#17078 by @island205) +- Carousel + - 修复 change 的触发时机 (#16705 by @iamkun) +- Notification + - 不修改传入的 option (#16704 by @iamkun) +- DatePicker + - 给 picker-option 添加 className 属性 (#16632 by @iamkun) +- DateTimePicker + - 修复时间选择滚动条的问题 (#16854 by @jesse-li) + +#### Optimization + +- Checkbox + - 提高可访问性 (#16575 by @tylertrotter) +- Docs + - 更新 changelog (#16773 by @SimonaliaChen) + - 更新贡献指南 (#14800 by @sinchang) + - 修复 Drawer 文档中的拼写错误 (#16848 by @winkay) + - 更新自定义主题 (#16983 by @iamkun) + - 新增 Esperanto 翻译 (#16955 by @maxkoryukov) + - 更新 input-number 文档 (#16316 by @luckyCao) + - 更新 Spanish 文档 (#16961 #16548 by @Gonzalo2310) +- I18n + - 更新加泰罗尼亚语翻译 (#14722 by @oscaralbareda) + - 更新阿拉伯语翻译 (#16653 by @l3op) +- Test + - 修复拼写错误 (#16672 by @boomler) + - 优化 image 的单元测试 (#16847 by @a631807682) +- Types + - 修复 httprequest 的类型 (#16633 by @luckyCao) + +### 2.11.1 + +*2019-07-26* + +#### Bug 修复 + +- Image + - 修复 Image 组件 SSR 兼容性 (#16737 by @luckyCao) +- Chore + - 更新 dart-sass 的兼容性 (#16744 by @LewisChennnnn) + +### 2.11.0 + +*2019-07-25* + +#### 新特性 + +- Drawer + - 新增抽屉组件 (#16577 by @JeremyWuuuuu) + +#### Bug 修复 + +- Checkbox + - 修复 CSS 样式问题 (#16006 by @Hazlank) +- Tree + - 更新类型定义为泛类型 (#15934 by @JeremyWuuuuu) + - 修复设置节点 isCurrent 的为 false 的问题 (#15870 by @kkkisme) +- Dropdown + - 更新 split-button 默认颜色 (#15931 by @JuniorTour) +- Cascader + - 修复一级菜单更新问题 (#16399 by @luckyCao) + - 懒加载时设默认值 (#16420 by @luckyCao) + - 修复当节点值重复时的显示问题 (#15935 by @junyiz) + - 对外暴露 getCheckedNodes 和修复 options 改变会影响选中的问题 (#16709 by @SimonaliaChen) +- Calendar + - 更新显示正确的 header 的逻辑 (#16354 by @ziyoung) +- Submenu + - 修复 append-to-body 问题 (#16289 by @a631807682) +- Table + - 修复 tree table 数据更新问题 (#16481 by @island205) +- Select + - 修复内存泄漏问题 (#16463 by @island205) +- InfiniteScroll + - 更新命名和说明 (#16698 by @iamkun) +- Avatar + - 修复图片不居中的问题 (#16489 by @luckyCao) +- Dialog + - 增加 destroyOnClose 属性 (#16455 by @ziyoung) +- Image + - 增加大图预览 (#16333 by @luckyCao) + +#### 优化 + +- Docs + - 修复 dropdown 示例 (#16193 by @webxmsj) + - 修正笔误 (#15971 by @howiefh) +- I18n + - 更新泰文翻译 (#16689 by @ponkrit) +- Chore + - 更新基础 API 地址 (#16607 by @iamkun) + - 增加 Form 的主题 token (#16699 by @iamkun) + - 更新统计 (#16609 by @iamkun) + - 修复文档锚点问题 (#16692 by @iamkun) + +### 2.10.1 + +*2019-07-02* + +#### Bug 修复 + +- Table + - 排序 icon 问题修复 (#15439 by @bezany) + - 修复 `append` slot 存在时布局错位问题 (#16332 by @ziyoung) + - 修复 `showOverflowTooltip` 更新无效的问题 (#16295 by @a631807682) + - 修复 `FilterPanel` 中 `Scrollbar` 未注册问题 (#16246 by @ziyoung) +- Chore + - 更新版本号,修复文档问题 (#16233 by @ziyoung) + - 修复英文首页样式问题 (#16254 by @iamkun) + +#### 优化 + +- Tag + - 兼容 IE (#16334 by @ziyoung) +- Chore + - 更新钉钉3群二维码 (#16236 by @iamkun) +- Doc + - 更新主题编辑器文档 (#16244 by @iamkun) + +### 2.10.0 + +*2019-06-25* + +#### 新特性 + +- I18n + - 支持乌兹别克语 (#15796 by @ogabek96) +- Calendar + - 支持 `first-day-of-week` 配置 (#16047 by @ziyoung) +- Avatar + - 新增 `Avatar` 组件 (#16144 by @luckyCao) +- Upload: + - 支持自定义缩略图模版 (#13192 by @victorzhuk) + + +#### Bug 修复 + +- Tree + - 当 `currentKey` 为 `null` 时取消对树节点的高亮 (#15668 by @yyjjqq94) + - 修复多实例共享数据的问题 #15538 (#15615 by @VanMess) +- Upload + - 更新 `fileList` 的类型定义 (#15716 by @underfin) +- Table + - 修复加载 icon 不显示的问题 (#15868 by @ziyoung) + - 修复复杂表格中 hover 行背景色问题 (#15504 by @cnlon) + - 修复 `current-row-key` 和选择事件的问题 (#15983 by @ziyoung) + - `height` 属性接受更多单位 (#16013 by @ziyoung) + - 修复 `reserve-selection` 无效的问题 (#16135 by @ziyoung) +- Menu + - 修复 `popper-append-to-body` 设置后,子菜单无法收起的问题 (#15391 by @PanJiaChen) +- Select + - 修复 `initialInputHeight` 问题 (#15989 by @yyjjqq94) + - 修复输入中文时 `default-first-option` 的行为问题 (#15431 by @VanMess) + - `import` 重复 (#16215 by @lengband) +- Message + - 类型定义中添加 `offset` 属性 (#16027 by @matjaz) +- Timeline + - 修复逆序问题 (#16091 by @ziyoung) +- Slider + - 补充 `input` 事件文档 (#15588 by @VanMess) +- InfiniteScroll + - 更新包名 (#16125 by @iamkun) +- MessageBox + - 修复 `distinguishCancelAndClose` 行为与文档不符的问题 (#15438 by @qingdengyue) +- PopupManager + - 修复无法复写 `z-index` 的问题 (#15738 by @luckyCao) +- Docs + - 删除不必要的内容 (#16194 by @Alexeykhr) + - 更正 `Divider` 属性类型 (#15889 by @haoranyu) +- Chore + - 更新测试 API 地址 (#15807 by @iamkun) + +#### 优化 + +- Tree + -优化循环性能 (#15699 by @KingJeason) +- Theme + - 更新 GA 打点,修改页底地址链接到主题编辑器 (#16007 by @island205) +- Badge + - 更新类型定义 (#16198 by @iamkun) +- Avatar + - 更新主题变量配置 (#16202 by @luckyCao) +- I18n + - 更新葡萄牙语 (#15776 by @gigioSouza) + - 更新波斯语 (#15881 by @pamenary) +- Docs + - 补充入门文档中的组件列表 (#16063 by @pape2016) + - 更新法语文档 (#16208 by @blombard) + - 为 `Alert` 添加 默认插槽文档 (#15444 by @Alexeykhr) + - 更新西班牙语文档 (#15840 by @Gonzalo2310) + - 更新法语文档中的拼写错误 (#15837 by @blombard) + - 更新 2.9.2 西班牙文档 (#16185 by @Gonzalo2310) + +#### 非兼容性更新 + +- Form + - 移除输入框的成功状态 (#16159 by @ziyoung) + +### 2.9.2 + +*2019-06-21* + +#### Bug 修复 + +- Chore + - 修复 TS 定义文件 (#15805 by @NateScarlet) + +### 2.9.1 + +*2019-05-30* + +#### 新特性 + +- Table + - Tree Table 支持 tree-props,default-expand-all,expand-row-keys 属性, toggle-row-expansion 方法,expand-change 事件 (#15709 by @ziyoung) + +#### Bug 修复 + +- Table + - 修复了一些问题 (#15709 by @ziyoung) +- Theme + - 更新接口域名 (#15784 by @iamkun) + +#### 优化 + +- Chore + - 更新 InfiniteScroll 组件定义文件 (#15794 by @iamkun) + +### 2.9.0 + +*2019-05-30* + +#### 新特性 + +- Backtop + - 新增 Backtop 组件 (#15541 by @iamkun) +- PageHeader + - 新增 PageHeader 组件 (#15714 by @ziyoung) +- InfiniteScroll + - 新增 InfiniteScroll 指令 (#15567 by @iamkun) +- Cascader + - 新增多选模式和 filter-method 方法 (#15611 by @SimonaliaChen) +- Message + - 信息依次展示 (#15639 by @island205) +- Tag + - 新增 effect 属性 (#15725 by @SimonaliaChen) +- Tabs + - 卡片模式下标题左对齐 (#15695 by @luckyCao) +- DatePicker + - 支持字符串常量 (#15525 by island205) +- Image + - 支持 attrs 和 listeners (#15578 by @VanMess) +- Theme + - 新增 popup 背景配置 (#15412 by @iamkun) +- Chore + - 更新文档首页 (#15682 by @iamkun) + +#### Bug 修复 + +- Table + - 修复排序条件为空时的排序问题 (#15012 by @joelxr) +- Image + - 修复 ssr 问题和 object-fit 的兼容性 (#15346 by @SimonaliaChen) +- Input + - 修复 show-word-count 样式问题 (#15359 by @lvjiaxuan) + - 修复删除图标样式 (#15354 by @YiiGuxing) +- Calendar + - 修复星期展示错误 (#15399 by @qingdengyue) + - 修复十月展示问题 (#15394 by @qingdengyue) +- Tabs + - 修复 padding 问题 (#15461 by @SimonaliaChen) +- Tag + - 修复阻止冒泡问题 (#15150 by @infjer) +- Form + - 修复 form-item 的高度错误 (#15457 by @SimonaliaChen) + - 修复 resetFields 问题 (15181 by @luckyCao) +- Tooltip + - 修复自定义 tabindex 不生效问题 (#15619 by @SimonaliaChen) +- Link + - 修复图标 class 问题 (#15752 by @iamkun) +- Select + - 回滚清除时,设置 value 为 null 的修改 (#15447 by @iamkun) +- Loading + - 修复 Dom 不更新的问题 (#15123 by @FAKER-A) +- Switch + - 修复事件重复触发问题 (#15178 by @FAKER-A) +- Slider + - 修复点击时样式问题 (#15561 by @luckyCao) +- Radio + - 修复 value 不更新的问题 (#14809 by @OverTree) +- Form + - 修复 resetFields 问题 (15181 by @luckyCao) +- Chore + - 更新依赖 (#15324 by ziyoung) +- Type + - 修复 Loading 定义文件 (#15635 by @iamkun) + - 修复 Icon 定义文件 (#15634 by @iamkun) + - 修复 Link 定义文件 (#15402 by @iamkun) + +#### 优化 + +- Cascader + - 重构 (#15611 by @SimonaliaChen) +- Chore + - 更新新建组件的脚本 (by @iamkun) +- Docs + - 重新命名文档变量 (#15185 by @liupl) + - 更新 Image 组件文档 (#15423 by @haoranyu) + - 修复 Form 组件文档错误 (#15228 by @SHERlocked93) + +### 2.8.2 + +*2019-04-25* + +#### Bug 修复 + +- Icon + - 更新 icon (#15272 by @iamkun) +- 文档 + - 修复 Form 与 Input 文档样式 (#15273 by @ziyoung) + +### 2.8.1 + +*2019-04-25* + +#### Bug 修复 + +- Icon + - 更新 Select 与 Cascader 的 icon (#15264 by @SimonaliaChen) + - 更新 icon (#15258 by @iamkun) + +#### 优化 + +- Chore + - 更新构建脚本 (#15267 by @ziyoung) +- Docs + - 修复 link 的样式 (#15265 by @iamkun) +- 其他 + - migrating 配置兼容驼峰名称 (#15260 by @SimonaliaChen) + +### 2.8.0 + +*2019-04-25* + +#### 新特性 + +- Divider + - 新增 Divider 组件 (#15055 by @island205) +- Rate + - 支持通过对象自定义 colors 与 icon-classes 属性 (#15051 by @SimonaliaChen) +- Link + - 新增 Link 组件 (#15052 by @iamkun) +- Calendar + - 新增 Calendar 组件 (#14908 by @ziyoung) +- Icon + - 新增图标 (#15214 by @iamkun) +- Alert + - 新增高饱和度主题 (#15041 by @island205) +- Image + - 新增 Image 组件 (#15117 by @SimonaliaChen) +- Collapse + - CollapseItem 支持禁用 (#15076 by @ziyoung) +- Carousel + - 新增 direction 属性,支持垂直方向切换 (#15122 by @ziyoung) +- Pagination + - 新增 hide-on-single-page 属性 (#15096 by @ziyoung) +- Slider + - 新增 marks 属性 (#15133 by @luckyCao) +- Input + - 新增 show-word-count 属性 (#15075 by @luckyCao) +- InputNumber + - 新增 step-strictly 属性 (#15050 by @luckyCao) +- Tooltip, Dropdown, Popover + - 新增 tabindex 属性 (#15167 by @ziyoung) + +#### Bug 修复 + +- Notification + - 修复标题不换行的问题 (#15008 by @iamkun) +- Form + - 修复动态表单校验规则不生效的问题 (#14985 by @luckyCao) + - 修复 label 的样式 (#14969 by @ziyoung) + - 当 required 为 true 时,显示星号 (#15144 by @ziyoung) +- Pagination + - 修复 slot 未更新的问题 (#14711 by @lucyhao) +- Table + - 修复懒加载时加载数据的 bug (#15101 by @ziyoung) + - 在合并单元格时,修复单元格的宽度计算不正确的问题 (#15196 by @ziyoung) + - 提升表格的性能 (#14868 by @ziyoung) + - 初始化时不再触发 sort-change 事件 (#14625 by @PeanutWatson) + - 让 height 与 max-height 属性的行为保持一致 (#14660 by @arthurdenner) +- Dialog + - 修复内容不换行的问题 (#15027 by @iamkun) +- Alert + - 更新 typescript 定义文件 (#15186 by @ziyoung) +- Tabs + - Fix issue where Promise rejection was hitting application (#14816 by @ffxsam) + - slot 改变时,重新渲染 (#15238 by @ziyoung) +- Message + - 修复 typescript 定义文件 (#14968 by @agoni1212) +- Select + - 修复当 value 为 undefined 或者 null 的报错 (#15022 by @luckyCao) +- Tree + - 当前节点被删除后,选中的节点也应该删除 (#14604 by @sinchang) + - 提升性能 (#14881 by @ChenZhuoSteve) +- Dropdown + - 修复样式 (#14907 by @doing123) +- Slider + - 修复可访问性问题 (#14792 by @erezsob) +- Menu + - 如果 defaultIndex 不存在,activeIndex 应该为空 (#14074 by @hoythan) +- Directive + - RepeatClick: 使用 Date.now 提升性能 (#14776 by @pavelmash) +- Upload + - 修复 Upload 的背景颜色 (#15039 by @iamkun) +- Theme + - 添加无圆角变量 (#15256 by @iamkun) + +#### 优化 + +- Chore + - 更新中文 changelog (#14965 by @iamkun) + - 当 demo 描述为空时,不再显示 (#15014 by @ziyoung) + - 显示 DevServer 的信息 (#15028 by @iamkun) + - 修复 2.6 changelog 的 bug (#15026 by @iamkun) + - 更新构建脚本 (#14821 by @abc3660170) + - 本次开发时支持热更新 (#15221 by @SimonaliaChen) + - 本地开发时,加载 sourcemap (#15087 by @ibufu) +Docs + - 重命名 demo 中的变量 (#14602 #15003 #15094 #15105 by @liupl) + - 修复 upload 文档中的错误 (#15023 by @iamkun) + - 更新 Form 文档 (#15040 by @iamkun) + - 更新 Tabs 文档 (#15053 by @iamkun) + - 使用 eleme.cn 作为新域名 (#15139 by @ziyoung) + - 修复 Image 组件的路由名 (#15194 by @iamkun) + - 删除多余的法语翻译 (#15207 by @iamkun) + +#### 非兼容性更新 + +- Rate + - 禁用情况下,显示小位数 (#15089 by @haoranyu) +- Select + - 过滤情况下,placeholder 为选中选项的 label (#14989 by @ibufu) + +### 2.7.2 + +*2019-04-03* + +#### 修复 + +- Form + - 修复 `label-width` 为 `auto` 的样式 (#14955 by @ziyoung) + +#### 优化 +- Docs + - 修复文档内图片链接错误 (#14957 by @iamkun) +- Chore + - 修复发布时 mkdir 异常 (#14952 by @iamkun) + +### 2.7.1 + +*2019-04-03* + +#### 修复 + +- Select + - 清空时设置 value 为 null (#14322 by @aaronfulkerson) +- Input + - 当类型改变时更新 DOM (#14889 by @wacky6) +- Table + - 修复当有展开列时 `defaultExpandAll` 的行为 (#14935 by @ziyoung) +- Dialog + - 可以设置背景色 (#14939 by @ziyoung) +- Form + - `label-width` 支持自动宽度 (#14944 by @ziyoung) + +#### 优化 +- Docs + - 更新西班牙语文档 (#14913 by @Gonzalo2310) + - 新增组件自动生成法语文档 (#14924 by @ziyoung) + - 更新 Tabs 文档 (#14938 by @ziyoung) + +### 2.7.0 + +*2019-03-28* + +#### 新特性 + +- Table + - 增加对树形结构数据的支持 (#14632 by @ziyoung) + +#### 修复 + +- Tabs + - 阴影样式使用全局主颜色 (#14558 by @Richard-Choooou) + - 当 label 改变时触发更新 (#14496 by @akki-jat) +- Table + - Table footer 与 body 的对齐一致 (#14730 by @ziyoung) +- NavMenu + - 修复点击 el-submenu 多次触发 childMenu 问题 (#14443 by @PanJiaChen) +- Dropdown + - 兼容 Vue 2.6 新 v-slot 语法 (#14832 by @ziyoung) +- ColorPicker + - 修复十六进制颜色字符串解析问题 (#14793 by @iamkun) +- Tree + - 恢复 pr #13349 (#14847 by @ziyoung) +- Tooltip + - 当初始值为 true 时默认显示 (#14826 by @ziyoung) +- Docs + - 更新 Cascader 文档 (#14442 by @panhezeng) +- Style + - 修复媒体查询 sm-only, md-only, lg-only 问题 (#14611 by @sinchang) + +#### 优化 + +- Chore + - 增加网页描述信息 (#14802 by @iamkun) + +### 2.6.3 + +*2019-03-21* + +#### 修复 + +- 修复 Cascader 文档页的样式 (#14789 by @ziyoung) +- 移除 Cascader 中多余的 DOM 操作 (#14788 by @ziyoung) +- DateRange 支持夏令时 (#14562 by @wacky6) + +### 2.6.2 + +*2019-03-21* + +#### 新特性 + +- DatePicker + - 支持 monthrange 类型 (#14487 by @zxyRealm) +- i18n + - 添加 Croatian 语言包 (#14360 by @danijelh) +- Docs + - 更新 2.6.1 法语文档,修复笔误 (#14555 by @smalesys) + - 更新法语翻译 (#14643 by @smalesys) + +#### 修复 + +- Input + - Fix regression (#14572 by @wacky6) +- DatePicker + - 修复 first-day-of-week 的计算 (#14523 by @sinchang) + - 修复 WeekPicker value-format 的问题 (#13754 by @wacky6) +- Steps + - 修复 #14502 (#14596 by @sinchang) + - 修复简单模式下的样式 (#14610 by @sinchang) +- Docs + - 重命名 Table 文档中的变量 (#14587 by @likwotsing) + - 添加法语文档索引 (#14565 by @iamkun) + - 修复 TimePicker 文档页的样式 (#14579 by @ziyoung) + - 重命名 Upload 文档中的变量 (#14593 by @liupl) + - 在 Form 文档中 添加的 async-validator 文档 (#14694 by @iamkun) + - 修复 Tooltip 文档的 bug (#14748 by @iamkun) + - 修复笔误 (#14751 by @2bj) + - 修复 Switch 在移动端 Webkit 浏览器的高亮问题 (#14703 by @VladG0r) + +#### 优化 + +- Chore: + - 更新 ci 构建脚本 (#14600 by @ziyoung) + - 更新谷歌统计 (#14560 by @iamkun) + - 添加更多谷歌统计事件 (#14633 by @iamkun) + - 更新聊天组信息 (#14741 by @iamkun) + - 升级测试依赖 (#14735 by @wacky6) + - 升级 gulp (#14745 by @ziyoung) + - 使用 codepen 显示 demo,修复文档中的错误 (#14747 by @ziyoung) + +### 2.6.1 + +*2019-03-03* + +#### 修复 + +- **不再指定 node 版本** (by @iamkun in #14546) +- 调整 `deloy-faas.sh` 中的文档目录 (by @ziyoung in #14553) +- 调整 2.6.0 中 changelog 日期样式 (by @island205 in #14547) +- 修复拼写错误 (by @wack6 in #14552) + +### 2.6.0 + +*2019-03-01* + +#### 新特性 +- Timeline + - 添加 Timeline 组件 (by @jikkai in #14248) +- DropdownItem + - `el-dropdown-item` 支持添加 icon (by @gabrielboliveira in #14088) +- Input + - 添加 `show-password` 属性,支持配置显示密码按钮 (by @phshy0607 in #13966) +- Select + - 添加 slot `empty` (by @elfman in #13785) +- Autocomplete + - 添加 `highlight-first-item` 属性,控制是否默认突出显示远程搜索建议中的第一项 (by @YamenSharaf in #14269) +- I18n + - 添加亚美尼亚语支持 (by @hamletbarsamyan in #14214) +- Docs + - 新增法语文档 (by @smalesys in #12153, #14418, #14434) + +#### 优化 +- Alert + - 组件对通过 slot 传入的 description 也应用默认样式类 (by @iamkun in #14488) +- InputNumber + -移除多余的 `parseFloat` (by @JuniorTour in #14172) +- Menu + - 支持 `el-menu-item` 不添加 index (by @georgyfarniev in #13298) +- Table + - 移除无用的 DOM 操作 (by @elfman in #13643) +- Upload + - 代码优化 (by @elfman in #13973) +- Popup + - 移除无用代码 (by @KAionro in #14413) +- Docs + - 添加更多文档说明如何贡献代码 (by @island205 in #14355) + - 添加 `el-input` 是受控组件的警示 (by @wacky6 in #14463) + - 优化 Table 的文档 (by @luguokong in #14329) + - 更新 Input 文档 (by @iamkun in #14437) + - 优化自定义主题文档 (by @wangguohao in #14297) + - 为 Icon 文档添加 hover 效果 (by @tuxinghuan in #14295) +- Build + - 压缩 Element 文档站的 JS 和 CSS 文件 (by @iamkun in #14430) + - 优化 Webpack 打包速度,从6分钟优化到1分多 (by @hetech in #14484) + - 添加 CLI 工具,选择版本号 (by @hetech in #14354) +- 使用 Stale 来管理过时(暂定1年)的 Issue 和 PR (by @island205 in #14392) + +#### 问题修复 +- Menu + - 修复浏览器标签切换引起的 focus 问题 (by @liupl in #13976) +- MessageBox + - 修复 TS 定义 (by @NateScarlet in #14278) +- ScrollBar + - 修复点击鼠标右键导致拖动的问题 (by @xifeiwu in #14196) +- Switch + - 添加 `validate-event` 属性,设置改变 Switch 状态时是否触发表单的校验 (by @hetech in #14426) +- Table + - 修复多 Table 实例共享 `toggleAllSelection` 方法,造成无法切换问题 (by @letanure in #14075) +- Tabs & Dropdown + - 修复样式问题 (by @hetech in #14452) +- Tree + - 与 Table 统一占位文样式 (by @ColinCll in #14331) +- Docs + - 修复 DatetimePicker 文档问题 (by @iamkun in #14290) + - 修复 DatePicker 文档拼写问题 (by @helmut in #14481) + - 修复分页组件文档样式问题 (by @liuchuzhang in #14451) + +#### 非兼容性更新 +- Table + - 修复 row 事件的参数顺序 (by @jikkai in #12086) + +### 2.5.4 + +*2019-02-01* + +#### 修复 + +- 构建: 修复 `.babelrc` 配置问题——导致 Tree 等组件没有动画 (by @island205 in #14282) + +### 2.5.3 + +*2019-01-31* + +#### 优化 + +- 优化 Message 的代码 (by @vok123 in #14029) +- 移除 gh-pages (by @ziyoung in #14266) +- 添加 IssueHunt 的链接 (by @island205 in #14261) + +#### 修复 + +- 修复 UMD 包在服务器端运行出错的问题 (by @island205 in #14242) +- 修复 Tabbar 高亮时的样式 (by @iamkun in #14240) +- 修复 Table 示例代码的错误 (by @xunmeng in #14253) + +### 2.5.2 + +*2019-01-27* + +#### 优化 +- 文档: + - 2.5.1 版本西班牙语文档更新 (by @Gonzalo2310 in #14231) + +#### 修复 +- 构建: + - 删除 umd 模块 `lib/index.js` 中本没有的注释 (by @island205 in #14233) + - 修复 nuxt.js 中关于 `export` 关键字的报错 (by @island205 in #14232) + - 修复发布 2.5.1 过程中的错误 (by @iamkun in #14228) + +### 2.5.1 + +*2019-01-26* + +#### 优化 +- DatePicker:添加月、年高亮的样式(by @Debiancc in #14211) +- 更新 2.5.0 changelog (by @wacky6 in #14217) + + +#### 修复 +- 修复升级 Webpack 4 产生的问题,无法具名 `import` 组件,`ELEMENT.locale()` 调用报错。(by @island205 in #14220) +- 恢复 2.4.11 文档 (by @iamkun in #14222) + + +### 2.5.0 + +*2019-01-25* + +#### 新特性 +- DatePicker + - 新增 `validate-event` 属性 (by @ziyoung in #13531) +- DateTimePicker + - `pickerOptions` 支持 `selectableRange` 选项 (by @eeeeeeeason) +- Tag + - 新增 `click` 事件 (by @licdream in #14106) +- I18n + - 新增 柯尔克孜语 (Kyrgyz) (by @zzjframework in #14174) + +#### 优化 +- 升级到 webpack@4 (by @jikkai in #14173) +- Input + - 简化内部实现,遵循单向数据流;修复若干相关 Bug (by @wacky6 in #13471) +- 更新 Axure 文件,增加新组件 (by @ziyoung in #13773) + +#### 修复 +- Autocomplete + - 修正下拉框最后一行显示不完整的问题 (by @ziyoung in #13597) + - 修正下拉框箭头 (by @liuchuzhang in #13762) +- Carousel + - 组件销毁时释放内部 Timer (by @elfman in #13820) +- Cascader + - 移除已废弃的计算属性的 cache 属性 (by @iamkun in #13737) + - 修正 TypeScript 中 CascaderOption 类型定义 (by @NateScarlet in #13613) + - 修正图标覆盖文字的问题 (by @ziyoung in #13596) +- Checkbox + - 改进显示样式 (by @PanJiaChen) +- DatePicker + - 修正 TimeSpinner 中缺失的 v-for `key` 属性 (by @Ende93 in #13547) + - 修正周选择器在跨年时的高亮行为 (by @suyi91 in #13883) +- Input + - 修复 textarea 时的 DOM 节点引用 (by @laomu1988 @island205 in #13803) +- Pagination + - 输入框的值不会小于 1 (by @elfman in #13727) +- Popover + - 修正 hover 的触发行为 (by @goldengecko in #13104) + - 修正弹出框的内存泄漏 (by @qpxtWhite in #13988) +- Radio + - 改进显示样式 (by @ohhoney1) +- Table + - 改进点击排序箭头时的行为 (by @ohhoney1 in #12890) + - 修正 IE10+ 中 “暂无数据” 提示的垂直布局 (by @imzjy in #13638) + - 修正文档中 `index` 的类型说明 (by @ilovefafa in #13628) + - 修正多级表头使用 `fixed` 属性时,表尾合计行的显示样式 (by @luckyCao in #13914) +- Tabs + - 修正自动滚动 (by @iamkun in #13696) + - 通过面板名称查找面板 (by @iamkun in #13705) + - 使用 `paneName` 计算面板样式 (by @iamkun in #13733) +- Tree + - 修正 `showCheckbox` 不能影响子节点的问题 (by @KidneyFlower) + - 更新文档和 TypeScript 定义 (by @ziyoung in #13540) +- Upload + - `list-type` 改变时,保留 `url` 属性 (by @elfman in #13771) +- Slider + - 修正源代码缩进 (by @wacky6 in #13955) +- I18n + - 补充加泰罗尼亚语 (Catalan) 翻译 (by @jaumesala) + - 补充俄语 (Russian) 翻译 (by @justlp in #13658) + - 补充芬兰语 (Finnish) 翻译 (by @jenkrisu in #14137) +- Doc + - 更新西班牙语文档至 2.4.11 (by @Gonzalo2310 in #13522) +- 其它 + - 移除多余的构建脚本 (by @ziyoung) + - 修正文档超链接 (by @iamkun in #13753) + - 修正文档中不一致的大小写 (by @wonderjar) + - 增加钉钉群的二维码 (by @iamkun in #13957) + - .gitignore 增加 yarn 日志文件 (by @mimimi in #13922) + - 移除赞助商 多态 (by @island205 in #14156) + - Update readme qr code src (by @iamkun in #13960) + - 更新 CDN 链接,修正错别字 (by @ziyoung) + ### 2.4.11 *2018-11-21* @@ -40,7 +938,7 @@ - 用户可以使用 scoped-slot 来自定义表头,#13012(by @ivanseidel) - 修复 IE 下 Select 输入框不能输入的问题,#13034(by @GaliMU) - Select 多选时,选项不换行,#12329 (by @akki-jat) -- Select 下拉列表展开后,箭头图标也可以正确显示,#12353(by @firesh) +- Select 下拉列表展开后,箭头图标也可以正确显示,#12353(by @firesh) - 修复 Select 的 size 属性不生效的问题,#13070 - 多选时可以清除 Select 已选中的值,#13049(by @ZSkycat) - 修复最后一个 TabNav 不能删除的问题,#13039 diff --git a/FAQ.md b/FAQ.md index 841d7f01321..00a264e0495 100644 --- a/FAQ.md +++ b/FAQ.md @@ -45,7 +45,7 @@
你们的文档怎么偷偷更新了? - 我们只会在 Element 发布新版本时同步更新文档,以体现最新的变化。详细的更新内容可以查看 [changelog](https://github.com/ElemeFE/element/blob/master/CHANGELOG.zh-CN.md)。 + 我们只会在 Element 发布新版本时同步更新文档,以体现最新的变化。详细的更新内容可以查看 [changelog](https://github.com/femessage/element/blob/master/CHANGELOG.zh-CN.md)。
@@ -117,7 +117,7 @@
When do you update documentations of Element? - We update documentations only when a new version of Element is published so that it reflects all the changes introduced in that version. Updated changed can be found in the [changelog](https://github.com/ElemeFE/element/blob/master/CHANGELOG.en-US.md)。 + We update documentations only when a new version of Element is published so that it reflects all the changes introduced in that version. Updated changed can be found in the [changelog](https://github.com/femessage/element/blob/master/CHANGELOG.en-US.md)。
@@ -191,7 +191,7 @@
¿Cuando añaden a la documentación de `Element`? - Añadamos la documentación con cada versión nueva de `Element` y los cambios reflejan los cambios del software de esa versión. Los cambios actuales y históricos se encuentran [aquí](https://github.com/ElemeFE/element/blob/master/CHANGELOG.en-US.md). + Añadamos la documentación con cada versión nueva de `Element` y los cambios reflejan los cambios del software de esa versión. Los cambios actuales y históricos se encuentran [aquí](https://github.com/femessage/element/blob/master/CHANGELOG.en-US.md).
diff --git a/README.md b/README.md index d0d228033b0..f2c67e512f0 100644 --- a/README.md +++ b/README.md @@ -2,102 +2,27 @@

-

- - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - -

- -

- Special thanks to the generous sponsorship by: -

- - - - - - - - - -
- - - - - - - - - - - - - - - -
- -> A Vue.js 2.0 UI Toolkit for Web. +[![Build Status](https://badgen.net/travis/FEMessage/element/master)](https://travis-ci.com/FEMessage/element) +[![NPM Download](https://badgen.net/npm/dm/@femessage/element-ui)](https://www.npmjs.com/package/@femessage/element-ui) +[![NPM Version](https://badgen.net/npm/v/@femessage/element-ui)](https://www.npmjs.com/package/@femessage/element-ui) +[![NPM License](https://badgen.net/npm/license/@femessage/element-ui)](https://github.com/FEMessage/element/blob/master/LICENSE) +[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](https://github.com/FEMessage/element/pulls) +[![Automated Release Notes by gren](https://img.shields.io/badge/%F0%9F%A4%96-release%20notes-00B2EE.svg)](https://github-tools.github.io/github-release-notes/) -## Links -- Homepage and documentation - - [International users](http://element.eleme.io/#/en-US) - - [Chinese users](http://element-cn.eleme.io/#/zh-CN) - - [Spanish users](http://element.eleme.io/#/es) -- [awesome-element](https://github.com/ElementUI/awesome-element) -- [FAQ](./FAQ.md) -- [Customize theme](http://element.eleme.io/#/en-US/component/custom-theme) -- [Preview and generate theme online](https://elementui.github.io/theme-chalk-preview) -- [Element for React](https://github.com/elemefe/element-react) -- [Element for Angular](https://github.com/ElemeFE/element-angular) -- [Atom helper](https://github.com/ElemeFE/element-helper) -- [Visual Studio Code helper](https://github.com/ElemeFE/vscode-element-helper) -- Starter kit - - [element-starter](https://github.com/ElementUI/element-starter) - - [element-in-laravel-starter](https://github.com/ElementUI/element-in-laravel-starter) -- [Design resources](https://github.com/ElementUI/Resources) -- Gitter - - [International users](https://gitter.im/element-en/Lobby) - - [Chinese users](https://gitter.im/ElemeFE/element) +--- ## Install ```shell -npm install element-ui -S +npm install @femessage/element-ui -S + +#or +yarn add @femessage/element-ui ``` ## Quick Start ``` javascript import Vue from 'vue' -import Element from 'element-ui' +import Element from '@femessage/element-ui' Vue.use(Element) @@ -106,132 +31,90 @@ import { Select, Button // ... -} from 'element-ui' +} from '@femessage/element-ui' Vue.component(Select.name, Select) Vue.component(Button.name, Button) ``` -For more information, please refer to [Quick Start](http://element.eleme.io/#/en-US/component/quickstart) in our documentation. +For more information, please refer to [Quick Start](http://femessgae.github.io/#/zh-CN/component/quickstart) in our documentation. -## Browser Support -Modern browsers and Internet Explorer 10+. +## Generate Theme +```sh +# fork this repository + +git clone https://github/{ user || owner }/element.git + +# remember: if want to update your component and its css, must merge latest only-component branch into your repository +git checkout -b only-component new-theme + +# modify packages/theme-chalk/src/common/var.scss + +# modify package name in packages/theme-chalk/package.json + +sh ./publish-theme.sh + +# now a new theme publish to npm for your own +``` + +The reason to checkout from branch `only-component`, can be found in [Contributing Guide](https://github.com/femessage/element/blob/master/.github/CONTRIBUTING.zh-CN.md) ## Development -Skip this part if you just want to use Element. +```sh +# install dependence +yarn bootstrap + +# generate files for examples site +yarn build:file + +# generate theme files +yarn build:theme + +# generate utils files +yarn build:utils + +# generate files about locale +yarn build:umd + +# clean files from yarn dist +yarn clean + +# bundle examples site +yarn deploy:build + +# bundle extension files +yarn deploy:extension -For those who are interested in contributing to Element, please refer to our contributing guide ([中文](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.zh-CN.md) | [English](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.en-US.md) | [Español](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.es.md)) to see how to run this project. +# extension local dev +yarn dev:extension -## Changelog -Detailed changes for each release are documented in the [release notes](https://github.com/ElemeFE/element/releases). +# local dev and preview examples site +yarn dev -## FAQ -We have collected some [frequently asked questions](https://github.com/ElemeFE/element/blob/master/FAQ.md). Before reporting an issue, please search if the FAQ has the answer to your problem. +# local dev single component +yarn dev:play + +# bundle all lib +yarn dist + +# generate i18n files +yarn i18n + +# using eslint to check code style +yarn lint + +# run unit test +yarn test +``` ## Contribution -Please make sure to read the contributing guide ([中文](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.zh-CN.md) | [English](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.en-US.md) | [Español](https://github.com/ElemeFE/element/blob/master/.github/CONTRIBUTING.es.md)) before making a pull request. - -## Special Thanks -English documentation is brought to you by SwiftGG Translation Team: -- [raychenfj](https://github.com/raychenfj) -- [kevin](http://thekevin.cn/) -- [曾小涛](https://github.com/zengxiaotao) -- [湾仔王二](https://github.com/wanzaiwanger) -- [BlooDLine](http://www.ibloodline.com/) -- [陈铭嘉](https://chenmingjia.github.io/) -- [千叶知风](http://mpc6.com/) -- [梁杰](http://numbbbbb.com) -- [Changing](https://github.com/sunzhuo11) -- [mmoaay](https://github.com/mmoaay) - -Spanish documentation is made possible by these community developers: -- [adavie1](https://github.com/adavie1) -- [carmencitaqiu](https://github.com/carmencitaqiu) -- [coderdiaz](https://github.com/coderdiaz) -- [fedegar33](https://github.com/fedegar33) -- [Gonzalo2310](https://github.com/Gonzalo2310) -- [lesterbx](https://github.com/lesterbx) -- [ProgramerGuy](https://github.com/ProgramerGuy) -- [SantiagoGdaR](https://github.com/SantiagoGdaR) -- [sigfriedCub1990](https://github.com/sigfriedCub1990) -- [thechosenjuan](https://github.com/thechosenjuan) - -## Donation -If you find Element useful, you can buy us a cup of coffee - -donation - -## Backers - -Support us with a monthly donation and help us continue our activities. [[Become a backer](https://opencollective.com/element#backer)] - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -## 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/element#sponsor)] - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Please make sure to read the [Contributing Guide](https://github.com/femessage/element/blob/master/.github/CONTRIBUTING.zh-CN.md) before making a pull request. +## Browser Support +Modern browsers and Internet Explorer 10+. +## Links +- [Documentation](https://femessage.github.io/element) +- [ChangeLog](https://github.com/FEMessage/element/releases) ## LICENSE [MIT](LICENSE) diff --git a/build/bin/build-entry.js b/build/bin/build-entry.js index 4958573e7f3..0da9efa2e32 100644 --- a/build/bin/build-entry.js +++ b/build/bin/build-entry.js @@ -27,6 +27,7 @@ const install = function(Vue, opts = {}) { Vue.component(component.name, component); }); + Vue.use(InfiniteScroll); Vue.use(Loading.directive); Vue.prototype.$ELEMENT = { @@ -41,6 +42,8 @@ const install = function(Vue, opts = {}) { Vue.prototype.$prompt = MessageBox.prompt; Vue.prototype.$notify = Notification; Vue.prototype.$message = Message; + Vue.prototype.$alertCenter = MessageBoxCenter.alert; + Vue.prototype.$confirmCenter = MessageBoxCenter.confirm; }; @@ -49,7 +52,7 @@ if (typeof window !== 'undefined' && window.Vue) { install(window.Vue); } -module.exports = { +export default { version: '{{version}}', locale: locale.use, i18n: locale.i18n, @@ -58,8 +61,6 @@ module.exports = { Loading, {{list}} }; - -module.exports.default = module.exports; `; delete Components.font; @@ -78,7 +79,7 @@ ComponentNames.forEach(name => { package: name })); - if (['Loading', 'MessageBox', 'Notification', 'Message'].indexOf(componentName) === -1) { + if (['Loading', 'MessageBox', 'Notification', 'Message', 'InfiniteScroll', 'MessageBoxCenter'].indexOf(componentName) === -1) { installTemplate.push(render(INSTALL_COMPONENT_TEMPLATE, { name: componentName, component: name diff --git a/build/bin/gen-indices.js b/build/bin/gen-indices.js index 3bffdc7b8c7..ee15913b096 100644 --- a/build/bin/gen-indices.js +++ b/build/bin/gen-indices.js @@ -10,10 +10,11 @@ const client = algoliasearch('4C63BTGP6S', key); const langs = { 'zh-CN': 'element-zh', 'en-US': 'element-en', - 'es': 'element-es' + 'es': 'element-es', + 'fr-FR': 'element-fr' }; -['zh-CN', 'en-US', 'es'].forEach(lang => { +['zh-CN', 'en-US', 'es', 'fr-FR'].forEach(lang => { const indexName = langs[lang]; const index = client.initIndex(indexName); index.clearIndex(err => { diff --git a/build/bin/iconInit.js b/build/bin/iconInit.js index ea55eff5a1b..40691ccee7e 100644 --- a/build/bin/iconInit.js +++ b/build/bin/iconInit.js @@ -17,4 +17,6 @@ nodes.forEach((node) => { } }); +classList.reverse(); // 希望按 css 文件顺序倒序排列 + fs.writeFile(path.resolve(__dirname, '../../examples/icon.json'), JSON.stringify(classList), () => {}); diff --git a/build/bin/new.js b/build/bin/new.js index 00d2ffaf842..8f1694a7464 100644 --- a/build/bin/new.js +++ b/build/bin/new.js @@ -11,6 +11,7 @@ if (!process.argv[2]) { } const path = require('path'); +const fs = require('fs'); const fileSave = require('file-save'); const uppercamelcase = require('uppercamelcase'); const componentname = process.argv[2]; @@ -53,6 +54,10 @@ export default { filename: path.join('../../examples/docs/es', `${componentname}.md`), content: `## ${ComponentName}` }, + { + filename: path.join('../../examples/docs/fr-FR', `${componentname}.md`), + content: `## ${ComponentName}` + }, { filename: path.join('../../test/unit/specs', `${componentname}.spec.js`), content: `import { createTest, destroyVM } from '../util'; @@ -100,6 +105,29 @@ fileSave(path.join(__dirname, '../../components.json')) .write(JSON.stringify(componentsFile, null, ' '), 'utf8') .end('\n'); +// 添加到 index.scss +const sassPath = path.join(__dirname, '../../packages/theme-chalk/src/index.scss'); +const sassImportText = `${fs.readFileSync(sassPath)}@import "./${componentname}.scss";`; +fileSave(sassPath) + .write(sassImportText, 'utf8') + .end('\n'); + +// 添加到 element-ui.d.ts +const elementTsPath = path.join(__dirname, '../../types/element-ui.d.ts'); + +let elementTsText = `${fs.readFileSync(elementTsPath)} +/** ${ComponentName} Component */ +export class ${ComponentName} extends El${ComponentName} {}`; + +const index = elementTsText.indexOf('export') - 1; +const importString = `import { El${ComponentName} } from './${componentname}'`; + +elementTsText = elementTsText.slice(0, index) + importString + '\n' + elementTsText.slice(index); + +fileSave(elementTsPath) + .write(elementTsText, 'utf8') + .end('\n'); + // 创建 package Files.forEach(file => { fileSave(path.join(PackagePath, file.filename)) diff --git a/build/bin/version.js b/build/bin/version.js index 4a75cde247c..2220a2691d2 100644 --- a/build/bin/version.js +++ b/build/bin/version.js @@ -1,6 +1,6 @@ var fs = require('fs'); var path = require('path'); -var version = process.env.VERSION || require('../../package.json').version; -var content = { '1.4.13': '1.4', '2.0.11': '2.0', '2.1.0': '2.1', '2.2.2': '2.2', '2.3.9': '2.3' }; -if (!content[version]) content[version] = '2.4'; +var version = process.env.VERSION || require('../../packages/theme-chalk/package.json').version; +var content = {}; +if (!content[version]) content[version] = '2.13'; fs.writeFileSync(path.resolve(__dirname, '../../examples/versions.json'), JSON.stringify(content)); diff --git a/build/config.js b/build/config.js index 27b84cea421..d04e25fbfce 100644 --- a/build/config.js +++ b/build/config.js @@ -2,29 +2,29 @@ var path = require('path'); var fs = require('fs'); var nodeExternals = require('webpack-node-externals'); var Components = require('../components.json'); -var saladConfig = require('./salad.config.json'); var utilsList = fs.readdirSync(path.resolve(__dirname, '../src/utils')); var mixinsList = fs.readdirSync(path.resolve(__dirname, '../src/mixins')); var transitionList = fs.readdirSync(path.resolve(__dirname, '../src/transitions')); var externals = {}; +var packageName = require('../package.json').name; Object.keys(Components).forEach(function(key) { - externals[`element-ui/packages/${key}`] = `element-ui/lib/${key}`; + externals[`element-ui/packages/${key}`] = `${packageName}/lib/${key}`; }); -externals['element-ui/src/locale'] = 'element-ui/lib/locale'; +externals['element-ui/src/locale'] = `${packageName}/lib/locale`; utilsList.forEach(function(file) { file = path.basename(file, '.js'); - externals[`element-ui/src/utils/${file}`] = `element-ui/lib/utils/${file}`; + externals[`element-ui/src/utils/${file}`] = `${packageName}/lib/utils/${file}`; }); mixinsList.forEach(function(file) { file = path.basename(file, '.js'); - externals[`element-ui/src/mixins/${file}`] = `element-ui/lib/mixins/${file}`; + externals[`element-ui/src/mixins/${file}`] = `${packageName}/lib/mixins/${file}`; }); transitionList.forEach(function(file) { file = path.basename(file, '.js'); - externals[`element-ui/src/transitions/${file}`] = `element-ui/lib/transitions/${file}`; + externals[`element-ui/src/transitions/${file}`] = `${packageName}/lib/transitions/${file}`; }); externals = [Object.assign({ @@ -47,13 +47,4 @@ exports.vue = { amd: 'vue' }; -exports.jsexclude = /node_modules|utils\/popper\.js|utils\/date.\js/; - -exports.postcss = function(webapck) { - saladConfig.features.partialImport = { - addDependencyTo: webapck - }; - return [ - require('postcss-salad')(saladConfig) - ]; -}; +exports.jsexclude = /node_modules|utils\/popper\.js|utils\/date\.js/; diff --git a/build/deploy-ci.sh b/build/deploy-ci.sh index bfccde8706e..76117e3668e 100644 --- a/build/deploy-ci.sh +++ b/build/deploy-ci.sh @@ -40,7 +40,7 @@ if [ "$TRAVIS_TAG" ]; then # build sub folder echo $TRAVIS_TAG - SUB_FOLDER='2.4' + SUB_FOLDER='2.13' mkdir $SUB_FOLDER rm -rf *.js *.css *.map static rm -rf $SUB_FOLDER/** diff --git a/build/deploy-faas.sh b/build/deploy-faas.sh index ed6e892c497..708fd18d9b2 100644 --- a/build/deploy-faas.sh +++ b/build/deploy-faas.sh @@ -1,12 +1,13 @@ #! /bin/sh +set -ex mkdir temp_web npm run deploy:build cd temp_web git clone --depth 1 -b gh-pages --single-branch https://github.com/ElemeFE/element.git && cd element # build sub folder -SUB_FOLDER='2.4' -mkdir $SUB_FOLDER +SUB_FOLDER='2.13' +mkdir -p $SUB_FOLDER rm -rf *.js *.css *.map static rm -rf $SUB_FOLDER/** cp -rf ../../examples/element-ui/** . @@ -14,5 +15,5 @@ cp -rf ../../examples/element-ui/** $SUB_FOLDER/ cd ../.. # deploy domestic site -faas deploy alpha -rm -rf temp_web \ No newline at end of file +faas deploy alpha -P element +rm -rf temp_web diff --git a/build/md-loader/config.js b/build/md-loader/config.js new file mode 100644 index 00000000000..b491c538b2d --- /dev/null +++ b/build/md-loader/config.js @@ -0,0 +1,26 @@ +const Config = require('markdown-it-chain'); +const anchorPlugin = require('markdown-it-anchor'); +const slugify = require('transliteration').slugify; +const containers = require('./containers'); +const overWriteFenceRule = require('./fence'); + +const config = new Config(); + +config + .options.html(true).end() + + .plugin('anchor').use(anchorPlugin, [ + { + level: 2, + slugify: slugify, + permalink: true, + permalinkBefore: true + } + ]).end() + + .plugin('containers').use(containers).end(); + +const md = config.toMd(); +overWriteFenceRule(md); + +module.exports = md; diff --git a/build/md-loader/containers.js b/build/md-loader/containers.js new file mode 100644 index 00000000000..4be9010e7ac --- /dev/null +++ b/build/md-loader/containers.js @@ -0,0 +1,24 @@ +const mdContainer = require('markdown-it-container'); + +module.exports = md => { + md.use(mdContainer, 'demo', { + validate(params) { + return params.trim().match(/^demo\s*(.*)$/); + }, + render(tokens, idx) { + const m = tokens[idx].info.trim().match(/^demo\s*(.*)$/); + if (tokens[idx].nesting === 1) { + const description = m && m.length > 1 ? m[1] : ''; + const content = tokens[idx + 1].type === 'fence' ? tokens[idx + 1].content : ''; + return ` + ${description ? `
${md.render(description)}
` : ''} + + `; + } + return '
'; + } + }); + + md.use(mdContainer, 'tip'); + md.use(mdContainer, 'warning'); +}; diff --git a/build/md-loader/fence.js b/build/md-loader/fence.js new file mode 100644 index 00000000000..d32862391ea --- /dev/null +++ b/build/md-loader/fence.js @@ -0,0 +1,14 @@ +// 覆盖默认的 fence 渲染策略 +module.exports = md => { + const defaultRender = md.renderer.rules.fence; + md.renderer.rules.fence = (tokens, idx, options, env, self) => { + const token = tokens[idx]; + // 判断该 fence 是否在 :::demo 内 + const prevToken = tokens[idx - 1]; + const isInDemoContainer = prevToken && prevToken.nesting === 1 && prevToken.info.trim().match(/^demo\s*(.*)$/); + if (token.info === 'html' && isInDemoContainer) { + return ``; + } + return defaultRender(tokens, idx, options, env, self); + }; +}; diff --git a/build/md-loader/index.js b/build/md-loader/index.js new file mode 100644 index 00000000000..2ef0e55ceed --- /dev/null +++ b/build/md-loader/index.js @@ -0,0 +1,67 @@ +const { + stripScript, + stripTemplate, + genInlineComponentText +} = require('./util'); +const md = require('./config'); + +module.exports = function(source) { + const content = md.render(source); + + const startTag = ''; + const endTagLen = endTag.length; + + let componenetsString = ''; + let id = 0; // demo 的 id + let output = []; // 输出的内容 + let start = 0; // 字符串开始位置 + + let commentStart = content.indexOf(startTag); + let commentEnd = content.indexOf(endTag, commentStart + startTagLen); + while (commentStart !== -1 && commentEnd !== -1) { + output.push(content.slice(start, commentStart)); + + const commentContent = content.slice(commentStart + startTagLen, commentEnd); + const html = stripTemplate(commentContent); + const script = stripScript(commentContent); + let demoComponentContent = genInlineComponentText(html, script); + const demoComponentName = `element-demo${id}`; + output.push(``); + componenetsString += `${JSON.stringify(demoComponentName)}: ${demoComponentContent},`; + + // 重新计算下一次的位置 + id++; + start = commentEnd + endTagLen; + commentStart = content.indexOf(startTag, start); + commentEnd = content.indexOf(endTag, commentStart + startTagLen); + } + + // 仅允许在 demo 不存在时,才可以在 Markdown 中写 script 标签 + // todo: 优化这段逻辑 + let pageScript = ''; + if (componenetsString) { + pageScript = ``; + } else if (content.indexOf('') + ''.length; + pageScript = content.slice(0, start); + } + + output.push(content.slice(start)); + return ` + + ${pageScript} + `; +}; diff --git a/build/md-loader/util.js b/build/md-loader/util.js new file mode 100644 index 00000000000..a9572aa40fe --- /dev/null +++ b/build/md-loader/util.js @@ -0,0 +1,79 @@ +const { compileTemplate } = require('@vue/component-compiler-utils'); +const compiler = require('vue-template-compiler'); + +function stripScript(content) { + const result = content.match(/<(script)>([\s\S]+)<\/\1>/); + return result && result[2] ? result[2].trim() : ''; +} + +function stripStyle(content) { + const result = content.match(/<(style)\s*>([\s\S]+)<\/\1>/); + return result && result[2] ? result[2].trim() : ''; +} + +// 编写例子时不一定有 template。所以采取的方案是剔除其他的内容 +function stripTemplate(content) { + content = content.trim(); + if (!content) { + return content; + } + return content.replace(/<(script|style)[\s\S]+<\/\1>/g, '').trim(); +} + +function pad(source) { + return source + .split(/\r?\n/) + .map(line => ` ${line}`) + .join('\n'); +} + +function genInlineComponentText(template, script) { + // https://github.com/vuejs/vue-loader/blob/423b8341ab368c2117931e909e2da9af74503635/lib/loaders/templateLoader.js#L46 + const finalOptions = { + source: `
${template}
`, + filename: 'inline-component', // TODO:这里有待调整 + compiler + }; + const compiled = compileTemplate(finalOptions); + // tips + if (compiled.tips && compiled.tips.length) { + compiled.tips.forEach(tip => { + console.warn(tip); + }); + } + // errors + if (compiled.errors && compiled.errors.length) { + console.error( + `\n Error compiling template:\n${pad(compiled.source)}\n` + + compiled.errors.map(e => ` - ${e}`).join('\n') + + '\n' + ); + } + let demoComponentContent = ` + ${compiled.code} + `; + // todo: 这里采用了硬编码有待改进 + script = script.trim(); + if (script) { + script = script.replace(/export\s+default/, 'const democomponentExport ='); + } else { + script = 'const democomponentExport = {}'; + } + demoComponentContent = `(function() { + ${demoComponentContent} + ${script} + return { + render, + staticRenderFns, + ...democomponentExport + } + })()`; + return demoComponentContent; +} + +module.exports = { + stripScript, + stripStyle, + stripTemplate, + genInlineComponentText +}; diff --git a/build/release.sh b/build/release.sh index 1f6dccc2efc..29711a2e990 100644 --- a/build/release.sh +++ b/build/release.sh @@ -1,10 +1,10 @@ +#!/usr/bin/env sh +set -e + git checkout master git merge dev -#!/usr/bin/env sh -set -e -echo "Enter release version: " -read VERSION +VERSION=`npx select-version-cli` read -p "Releasing $VERSION - are you sure? (y/n)" -n 1 -r echo # (optional) move to a new line @@ -15,6 +15,9 @@ then # build VERSION=$VERSION npm run dist + # ssr test + node test/ssr/require.test.js + # publish theme echo "Releasing theme-chalk $VERSION ..." cd packages/theme-chalk diff --git a/build/salad.config.json b/build/salad.config.json deleted file mode 100644 index 1d82ab8c332..00000000000 --- a/build/salad.config.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "browsers": ["ie > 8", "last 2 versions"], - "features": { - "bem": { - "shortcuts": { - "component": "b", - "modifier": "m", - "descendent": "e" - }, - "separators": { - "descendent": "__", - "modifier": "--" - } - } - } -} diff --git a/build/strip-tags.js b/build/strip-tags.js deleted file mode 100644 index bbb719c19a7..00000000000 --- a/build/strip-tags.js +++ /dev/null @@ -1,34 +0,0 @@ -/*! - * strip-tags - * - * Copyright (c) 2015 Jon Schlinkert, contributors. - * Licensed under the MIT license. - */ - -'use strict'; - -var cheerio = require('cheerio'); - -exports.strip = function(str, tags) { - var $ = cheerio.load(str, {decodeEntities: false}); - - if (!tags || tags.length === 0) { - return str; - } - - tags = !Array.isArray(tags) ? [tags] : tags; - var len = tags.length; - - while (len--) { - $(tags[len]).remove(); - } - - return $.html(); -}; - -exports.fetch = function(str, tag) { - var $ = cheerio.load(str, {decodeEntities: false}); - if (!tag) return str; - - return $(tag).html(); -}; diff --git a/build/webpack.common.js b/build/webpack.common.js index e9a6085c82a..9cc65567094 100644 --- a/build/webpack.common.js +++ b/build/webpack.common.js @@ -1,10 +1,11 @@ const path = require('path'); -const webpack = require('webpack'); const ProgressBarPlugin = require('progress-bar-webpack-plugin'); +const VueLoaderPlugin = require('vue-loader/lib/plugin'); const config = require('./config'); module.exports = { + mode: 'production', entry: { app: ['./src/index.js'] }, @@ -13,6 +14,8 @@ module.exports = { publicPath: '/dist/', filename: 'element-ui.common.js', chunkFilename: '[id].js', + libraryExport: 'default', + library: 'ELEMENT', libraryTarget: 'commonjs2' }, resolve: { @@ -21,6 +24,15 @@ module.exports = { modules: ['node_modules'] }, externals: config.externals, + performance: { + hints: false + }, + stats: { + children: false + }, + optimization: { + minimize: false + }, module: { rules: [ { @@ -33,43 +45,17 @@ module.exports = { test: /\.vue$/, loader: 'vue-loader', options: { - preserveWhitespace: false + compilerOptions: { + preserveWhitespace: false + } } }, - { - test: /\.json$/, - loader: 'json-loader' - }, { test: /\.css$/, - loaders: ['style-loader', 'css-loader', 'postcss-loader'] - }, - { - test: /\.scss$/, - loaders: ['style-loader', 'css-loader', 'sass-loader'] - }, - { - test: /\.html$/, - loader: 'html-loader?minimize=false' - }, - { - test: /\.otf|ttf|woff2?|eot(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } - }, - { - test: /\.svg(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } + loaders: ['style-loader', 'css-loader'] }, { - test: /\.(gif|png|jpe?g)(\?\S*)?$/, + test: /\.(svg|otf|ttf|woff2?|eot|gif|png|jpe?g)(\?\S*)?$/, loader: 'url-loader', query: { limit: 10000, @@ -80,11 +66,6 @@ module.exports = { }, plugins: [ new ProgressBarPlugin(), - new webpack.DefinePlugin({ - 'process.env.NODE_ENV': JSON.stringify('production') - }), - new webpack.LoaderOptionsPlugin({ - minimize: true - }) + new VueLoaderPlugin() ] }; diff --git a/build/webpack.component.js b/build/webpack.component.js index e4d4fa6b7ca..2ea8c5ae80b 100644 --- a/build/webpack.component.js +++ b/build/webpack.component.js @@ -1,11 +1,12 @@ const path = require('path'); -const webpack = require('webpack'); const ProgressBarPlugin = require('progress-bar-webpack-plugin'); +const VueLoaderPlugin = require('vue-loader/lib/plugin'); const Components = require('../components.json'); const config = require('./config'); const webpackConfig = { + mode: 'production', entry: Components, output: { path: path.resolve(process.cwd(), './lib'), @@ -20,6 +21,13 @@ const webpackConfig = { modules: ['node_modules'] }, externals: config.externals, + performance: { + hints: false + }, + stats: 'none', + optimization: { + minimize: false + }, module: { rules: [ { @@ -32,43 +40,17 @@ const webpackConfig = { test: /\.vue$/, loader: 'vue-loader', options: { - preserveWhitespace: false + compilerOptions: { + preserveWhitespace: false + } } }, - { - test: /\.json$/, - loader: 'json-loader' - }, { test: /\.css$/, - loaders: ['style-loader', 'css-loader', 'postcss-loader'] - }, - { - test: /\.scss$/, - loaders: ['style-loader', 'css-loader', 'sass-loader'] - }, - { - test: /\.html$/, - loader: 'html-loader?minimize=false' - }, - { - test: /\.otf|ttf|woff2?|eot(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } - }, - { - test: /\.svg(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } + loaders: ['style-loader', 'css-loader'] }, { - test: /\.(gif|png|jpe?g)(\?\S*)?$/, + test: /\.(svg|otf|ttf|woff2?|eot|gif|png|jpe?g)(\?\S*)?$/, loader: 'url-loader', query: { limit: 10000, @@ -79,12 +61,7 @@ const webpackConfig = { }, plugins: [ new ProgressBarPlugin(), - new webpack.DefinePlugin({ - 'process.env.NODE_ENV': JSON.stringify('production') - }), - new webpack.LoaderOptionsPlugin({ - minimize: true - }) + new VueLoaderPlugin() ] }; diff --git a/build/webpack.conf.js b/build/webpack.conf.js index 1f730012657..2c792af0597 100644 --- a/build/webpack.conf.js +++ b/build/webpack.conf.js @@ -1,10 +1,12 @@ const path = require('path'); -const webpack = require('webpack'); const ProgressBarPlugin = require('progress-bar-webpack-plugin'); +const VueLoaderPlugin = require('vue-loader/lib/plugin'); +const TerserPlugin = require('terser-webpack-plugin'); const config = require('./config'); module.exports = { + mode: 'production', entry: { app: ['./src/index.js'] }, @@ -14,8 +16,10 @@ module.exports = { filename: 'index.js', chunkFilename: '[id].js', libraryTarget: 'umd', + libraryExport: 'default', library: 'ELEMENT', - umdNamedDefine: true + umdNamedDefine: true, + globalObject: 'typeof self !== \'undefined\' ? self : this' }, resolve: { extensions: ['.js', '.vue', '.json'], @@ -24,6 +28,23 @@ module.exports = { externals: { vue: config.vue }, + optimization: { + minimizer: [ + new TerserPlugin({ + terserOptions: { + output: { + comments: false + } + } + }) + ] + }, + performance: { + hints: false + }, + stats: { + children: false + }, module: { rules: [ { @@ -36,67 +57,19 @@ module.exports = { test: /\.vue$/, loader: 'vue-loader', options: { - preserveWhitespace: false - } - }, - { - test: /\.json$/, - loader: 'json-loader' - }, - { - test: /\.css$/, - loaders: ['style-loader', 'css-loader', 'postcss-loader'] - }, - { - test: /\.scss$/, - loaders: ['style-loader', 'css-loader', 'sass-loader'] - }, - { - test: /\.html$/, - loader: 'html-loader?minimize=false' - }, - { - test: /\.otf|ttf|woff2?|eot(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') + compilerOptions: { + preserveWhitespace: false + } } }, { - test: /\.svg(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } - }, - { - test: /\.(gif|png|jpe?g)(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } + test: /\.svg$/, + loader: 'svg-inline-loader' } ] }, plugins: [ new ProgressBarPlugin(), - new webpack.DefinePlugin({ - 'process.env.NODE_ENV': JSON.stringify('production') - }), - new webpack.optimize.UglifyJsPlugin({ - compress: { - warnings: false - }, - output: { - comments: false - }, - sourceMap: false - }), - new webpack.LoaderOptionsPlugin({ - minimize: true - }) + new VueLoaderPlugin() ] }; diff --git a/build/webpack.demo.js b/build/webpack.demo.js index e341926c2f4..4ad30ae1f85 100644 --- a/build/webpack.demo.js +++ b/build/webpack.demo.js @@ -1,38 +1,22 @@ const path = require('path'); const webpack = require('webpack'); +const MiniCssExtractPlugin = require('mini-css-extract-plugin'); const CopyWebpackPlugin = require('copy-webpack-plugin'); const HtmlWebpackPlugin = require('html-webpack-plugin'); -const ExtractTextPlugin = require('extract-text-webpack-plugin'); const ProgressBarPlugin = require('progress-bar-webpack-plugin'); -const md = require('markdown-it')(); -const slugify = require('transliteration').slugify; +const VueLoaderPlugin = require('vue-loader/lib/plugin'); +const OptimizeCSSAssetsPlugin = require('optimize-css-assets-webpack-plugin'); +const UglifyJsPlugin = require('uglifyjs-webpack-plugin'); -const striptags = require('./strip-tags'); const config = require('./config'); const isProd = process.env.NODE_ENV === 'production'; -const isDev = process.env.NODE_ENV === 'development'; const isPlay = !!process.env.PLAY_ENV; -function convert(str) { - str = str.replace(/(&#x)(\w{4});/gi, function($0) { - return String.fromCharCode(parseInt(encodeURIComponent($0).replace(/(%26%23x)(\w{4})(%3B)/g, '$2'), 16)); - }); - return str; -} - -function wrap(render) { - return function() { - return render.apply(this, arguments) - .replace('', ''); - }; -} - const webpackConfig = { + mode: process.env.NODE_ENV, entry: isProd ? { - docs: './examples/entry.js', - 'element-ui': './src/index.js' + docs: './examples/entry.js' } : (isPlay ? './examples/play.js' : './examples/entry.js'), output: { path: path.resolve(process.cwd(), './examples/element-ui/'), @@ -49,20 +33,20 @@ const webpackConfig = { host: '0.0.0.0', port: 8085, publicPath: '/', - noInfo: true + hot: true + }, + performance: { + hints: false + }, + stats: { + children: false }, module: { rules: [ { enforce: 'pre', - test: /\.jsx?$/, - exclude: /node_modules|bower_components/, - loader: 'eslint-loader' - }, - { - enforce: 'pre', - test: /\.vue$/, - exclude: /node_modules|bower_components/, + test: /\.(vue|jsx?)$/, + exclude: /node_modules/, loader: 'eslint-loader' }, { @@ -72,87 +56,42 @@ const webpackConfig = { loader: 'babel-loader' }, { - test: /\.md$/, - loader: 'vue-markdown-loader', + test: /\.vue$/, + loader: 'vue-loader', options: { - use: [ - [require('markdown-it-anchor'), { - level: 2, - slugify: slugify, - permalink: true, - permalinkBefore: true - }], - [require('markdown-it-container'), 'demo', { - validate: function(params) { - return params.trim().match(/^demo\s*(.*)$/); - }, - - render: function(tokens, idx) { - var m = tokens[idx].info.trim().match(/^demo\s*(.*)$/); - if (tokens[idx].nesting === 1) { - var description = (m && m.length > 1) ? m[1] : ''; - var content = tokens[idx + 1].content; - var html = convert(striptags.strip(content, ['script', 'style'])).replace(/(<[^>]*)=""(?=.*>)/g, '$1'); - var script = striptags.fetch(content, 'script'); - var style = striptags.fetch(content, 'style'); - var jsfiddle = { html: html, script: script, style: style }; - var descriptionHTML = description - ? md.render(description) - : ''; - - jsfiddle = md.utils.escapeHtml(JSON.stringify(jsfiddle)); - - return ` -
${html}
- ${descriptionHTML} -
`; - } - return '
\n'; - } - }], - [require('markdown-it-container'), 'tip'], - [require('markdown-it-container'), 'warning'] - ], - preprocess: function(MarkdownIt, source) { - MarkdownIt.renderer.rules.table_open = function() { - return ''; - }; - MarkdownIt.renderer.rules.fence = wrap(MarkdownIt.renderer.rules.fence); - return source; + compilerOptions: { + preserveWhitespace: false } } }, { - test: /\.json$/, - loader: 'json-loader' - }, - { - test: /\.scss$/, - loaders: ['style-loader', 'css-loader', 'sass-loader'] - }, - { - test: /\.html$/, - loader: 'html-loader?minimize=false' - }, - { - test: /\.otf|ttf|woff2?|eot(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } + test: /\.(scss|css)$/, + use: [ + isProd ? MiniCssExtractPlugin.loader : 'style-loader', + 'css-loader', + 'sass-loader' + ] }, { - test: /\.svg(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } + test: /\.md$/, + use: [ + { + loader: 'vue-loader', + options: { + compilerOptions: { + preserveWhitespace: false + } + } + }, + { + loader: path.resolve(__dirname, './md-loader/index.js') + } + ] }, { - test: /\.(gif|png|jpe?g)(\?\S*)?$/, + test: /\.(svg|otf|ttf|woff2?|eot|gif|png|jpe?g)(\?\S*)?$/, loader: 'url-loader', + // todo: 这种写法有待调整 query: { limit: 10000, name: path.posix.join('static', '[name].[hash:7].[ext]') @@ -161,6 +100,7 @@ const webpackConfig = { ] }, plugins: [ + new webpack.HotModuleReplacementPlugin(), new HtmlWebpackPlugin({ template: './examples/index.tpl', filename: './index.html', @@ -170,82 +110,54 @@ const webpackConfig = { { from: 'examples/versions.json' } ]), new ProgressBarPlugin(), + new VueLoaderPlugin(), + new webpack.DefinePlugin({ + 'process.env.FAAS_ENV': JSON.stringify(process.env.FAAS_ENV) + }), new webpack.LoaderOptionsPlugin({ - minimize: true, vue: { - preserveWhitespace: false + compilerOptions: { + preserveWhitespace: false + } } }) - ] + ], + optimization: { + minimizer: [] + }, + devtool: '#eval-source-map' }; if (isProd) { webpackConfig.externals = { vue: 'Vue', - 'vue-router': 'VueRouter' + 'vue-router': 'VueRouter', + 'highlight.js': 'hljs' }; - webpackConfig.module.rules.push( - { - test: /\.vue$/, - loader: 'vue-loader', - options: { - extractCSS: true, - preserveWhitespace: false - } - }, - { - test: /\.css$/, - loader: ExtractTextPlugin.extract({ - fallback: 'style-loader', - use: [ - { loader: 'css-loader', options: { importLoaders: 1 } }, - 'postcss-loader' - ] - }) - } - ); webpackConfig.plugins.push( - new webpack.optimize.UglifyJsPlugin({ - compress: { - warnings: false - }, - output: { - comments: false - }, - sourceMap: false - }), - new ExtractTextPlugin({ + new MiniCssExtractPlugin({ filename: '[name].[contenthash:7].css' - }), - new webpack.DefinePlugin({ - 'process.env.NODE_ENV': JSON.stringify('production') - }), - new webpack.optimize.CommonsChunkPlugin({ - name: ['element-ui', 'manifest'] }) ); -} -if (isDev) { - webpackConfig.module.rules.push( - { - test: /\.vue$/, - loader: 'vue-loader', - options: { - preserveWhitespace: false + webpackConfig.optimization.minimizer.push( + new UglifyJsPlugin({ + cache: true, + parallel: true, + sourceMap: false + }), + new OptimizeCSSAssetsPlugin({}) + ); + // https://webpack.js.org/configuration/optimization/#optimizationsplitchunks + webpackConfig.optimization.splitChunks = { + cacheGroups: { + vendor: { + test: /\/src\//, + name: 'element-ui', + chunks: 'all' } - }, - { - test: /\.css$/, - loaders: ['style-loader', 'css-loader', 'postcss-loader'] } - ); - webpackConfig.plugins.push( - new webpack.HotModuleReplacementPlugin(), - new webpack.NamedModulesPlugin(), - new webpack.DefinePlugin({ - 'process.env.NODE_ENV': JSON.stringify('development') - }) - ); + }; + webpackConfig.devtool = false; } module.exports = webpackConfig; diff --git a/build/webpack.extension.js b/build/webpack.extension.js new file mode 100644 index 00000000000..2f8752c5956 --- /dev/null +++ b/build/webpack.extension.js @@ -0,0 +1,33 @@ +const path = require('path'); +const CopyWebpackPlugin = require('copy-webpack-plugin'); +const demoConfig = require('./webpack.demo'); +const webpack = require('webpack'); +const ProgressBarPlugin = require('progress-bar-webpack-plugin'); +const VueLoaderPlugin = require('vue-loader/lib/plugin'); + +demoConfig.entry = { + background: path.join(process.cwd(), './examples/extension/src/background'), + entry: path.join(process.cwd(), './examples/extension/src/entry') +}; +demoConfig.output = { + path: path.join(process.cwd(), './examples/extension/dist'), + filename: '[name].js' +}; +demoConfig.plugins = [ + new CopyWebpackPlugin([ + { from: 'examples/extension/src/manifest.json' }, + { from: 'examples/extension/src/icon.png' } + ]), + new VueLoaderPlugin(), + new ProgressBarPlugin(), + new webpack.LoaderOptionsPlugin({ + vue: { + compilerOptions: { + preserveWhitespace: false + } + } + }), + new webpack.HotModuleReplacementPlugin() +]; +demoConfig.module.rules.find(a => a.loader === 'url-loader').query = {}; +module.exports = demoConfig; diff --git a/build/webpack.test.js b/build/webpack.test.js index 54f4f515c57..e8f78cb7c65 100644 --- a/build/webpack.test.js +++ b/build/webpack.test.js @@ -1,9 +1,11 @@ const path = require('path'); const ProgressBarPlugin = require('progress-bar-webpack-plugin'); +const VueLoaderPlugin = require('vue-loader/lib/plugin'); const config = require('./config'); const webpackConfig = { + mode: 'development', entry: { app: ['./src/index.js'] }, @@ -20,17 +22,8 @@ const webpackConfig = { }), modules: ['node_modules'] }, - devtool: '#inline-source-map', module: { rules: [ - { - enforce: 'post', - test: /\.jsx?$/, - loader: 'isparta-loader', - options: { esModules: true }, - exclude: config.jsexclude, - include: /src|packages/ - }, { test: /\.(jsx?|babel|es6)$/, include: process.cwd(), @@ -41,42 +34,17 @@ const webpackConfig = { test: /\.vue$/, loader: 'vue-loader', options: { - loaders: { - js: process.env.CI_ENV ? 'isparta-loader' : 'isparta-loader!eslint-loader' - }, - preserveWhitespace: false + compilerOptions: { + preserveWhitespace: false + } } }, - { - test: /\.json$/, - loader: 'json-loader' - }, { test: /\.css$/, - loaders: ['style-loader', 'css-loader', 'postcss-loader'] - }, - { - test: /\.html$/, - loader: 'html-loader?minimize=false' - }, - { - test: /\.otf|ttf|woff2?|eot(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } - }, - { - test: /\.svg(\?\S*)?$/, - loader: 'url-loader', - query: { - limit: 10000, - name: path.posix.join('static', '[name].[hash:7].[ext]') - } + loaders: ['style-loader', 'css-loader'] }, { - test: /\.(gif|png|jpe?g)(\?\S*)?$/, + test: /\.(svg|otf|ttf|woff2?|eot|gif|png|jpe?g)(\?\S*)?$/, loader: 'url-loader', query: { limit: 10000, @@ -86,6 +54,7 @@ const webpackConfig = { ] }, plugins: [ + new VueLoaderPlugin() ] }; diff --git a/commitlint.config.js b/commitlint.config.js new file mode 100644 index 00000000000..a072cbbc879 --- /dev/null +++ b/commitlint.config.js @@ -0,0 +1,6 @@ +module.exports = { + extends: ['@commitlint/config-conventional'], + rules: { + 'type-enum': [0, 'always', ['merge', 'theme']] + } +}; diff --git a/components.json b/components.json index 7e8b58a93aa..ab1f9ab411f 100644 --- a/components.json +++ b/components.json @@ -67,5 +67,38 @@ "header": "./packages/header/index.js", "aside": "./packages/aside/index.js", "main": "./packages/main/index.js", - "footer": "./packages/footer/index.js" + "footer": "./packages/footer/index.js", + "timeline": "./packages/timeline/index.js", + "timeline-item": "./packages/timeline-item/index.js", + "link": "./packages/link/index.js", + "divider": "./packages/divider/index.js", + "image": "./packages/image/index.js", + "calendar": "./packages/calendar/index.js", + "backtop": "./packages/backtop/index.js", + "infinite-scroll": "./packages/infinite-scroll/index.js", + "page-header": "./packages/page-header/index.js", + "cascader-panel": "./packages/cascader-panel/index.js", + "avatar": "./packages/avatar/index.js", + "drawer": "./packages/drawer/index.js", + "popconfirm": "./packages/popconfirm/index.js", + "lr-container": "./packages/lr-container/index.js", + "loading-button": "./packages/loading-button/index.js", + "message-box-center": "./packages/message-box-center/index.js", + "tabs-dotted": "./packages/tabs-dotted/index.js", + "data-mapper": "./packages/data-mapper/index.js", + "checkbox-img-button": "./packages/checkbox-img-button/index.js", + "radio-img-button": "./packages/radio-img-button/index.js", + "icon-checkbox": "./packages/icon-checkbox/index.js", + "status-steps": "./packages/status-steps/index.js", + "panel": "./packages/panel/index.js", + "skeleton": "./packages/skeleton/index.js", + "empty": "./packages/empty/index.js", + "affix": "./packages/affix/index.js", + "input-id-card": "./packages/input-id-card/index.js", + "input-phone": "./packages/input-phone/index.js", + "input-email": "./packages/input-email/index.js", + "switch-enhance": "./packages/switch-enhance/index.js", + "input-url": "./packages/input-url/index.js", + "edit-table": "./packages/edit-table/index.js", + "button-group-enhance": "./packages/button-group-enhance/index.js" } diff --git a/deploy.sh b/deploy.sh new file mode 100755 index 00000000000..91f62735679 --- /dev/null +++ b/deploy.sh @@ -0,0 +1,8 @@ +#! /bin/sh +#yarn deploy:build +cd examples/element-ui +git init +git add . +git commit -m 'pages' +git remote add origin https://github.com/FEMessage/element.git +git push origin master:gp-pages diff --git a/examples/app.vue b/examples/app.vue index b74619c2a56..7321d6cbd43 100644 --- a/examples/app.vue +++ b/examples/app.vue @@ -1,178 +1,3 @@ - - - + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/borderRadius.vue b/examples/components/theme-configurator/editor/borderRadius.vue new file mode 100644 index 00000000000..8ee85f267ac --- /dev/null +++ b/examples/components/theme-configurator/editor/borderRadius.vue @@ -0,0 +1,89 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/boxShadow.vue b/examples/components/theme-configurator/editor/boxShadow.vue new file mode 100644 index 00000000000..dd6a4a8a440 --- /dev/null +++ b/examples/components/theme-configurator/editor/boxShadow.vue @@ -0,0 +1,158 @@ + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/color-picker/index.js b/examples/components/theme-configurator/editor/color-picker/index.js new file mode 100644 index 00000000000..d79e21e0892 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/index.js @@ -0,0 +1,8 @@ +import ColorPicker from './src/main'; + +/* istanbul ignore next */ +ColorPicker.install = function(Vue) { + Vue.component(ColorPicker.name, ColorPicker); +}; + +export default ColorPicker; diff --git a/examples/components/theme-configurator/editor/color-picker/src/color.js b/examples/components/theme-configurator/editor/color-picker/src/color.js new file mode 100644 index 00000000000..8dee3c84df8 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/color.js @@ -0,0 +1,316 @@ +const hsv2hsl = function(hue, sat, val) { + return [ + hue, + (sat * val / ((hue = (2 - sat) * val) < 1 ? hue : 2 - hue)) || 0, + hue / 2 + ]; +}; + +// Need to handle 1.0 as 100%, since once it is a number, there is no difference between it and 1 +// +const isOnePointZero = function(n) { + return typeof n === 'string' && n.indexOf('.') !== -1 && parseFloat(n) === 1; +}; + +const isPercentage = function(n) { + return typeof n === 'string' && n.indexOf('%') !== -1; +}; + +// Take input from [0, n] and return it as [0, 1] +const bound01 = function(value, max) { + if (isOnePointZero(value)) value = '100%'; + + const processPercent = isPercentage(value); + value = Math.min(max, Math.max(0, parseFloat(value))); + + // Automatically convert percentage into number + if (processPercent) { + value = parseInt(value * max, 10) / 100; + } + + // Handle floating point rounding errors + if ((Math.abs(value - max) < 0.000001)) { + return 1; + } + + // Convert into [0, 1] range if it isn't already + return (value % max) / parseFloat(max); +}; + +const INT_HEX_MAP = { 10: 'A', 11: 'B', 12: 'C', 13: 'D', 14: 'E', 15: 'F' }; + +const toHex = function({ r, g, b }) { + const hexOne = function(value) { + value = Math.min(Math.round(value), 255); + const high = Math.floor(value / 16); + const low = value % 16; + return '' + (INT_HEX_MAP[high] || high) + (INT_HEX_MAP[low] || low); + }; + + if (isNaN(r) || isNaN(g) || isNaN(b)) return ''; + + return '#' + hexOne(r) + hexOne(g) + hexOne(b); +}; + +const HEX_INT_MAP = { A: 10, B: 11, C: 12, D: 13, E: 14, F: 15 }; + +const parseHexChannel = function(hex) { + if (hex.length === 2) { + return (HEX_INT_MAP[hex[0].toUpperCase()] || +hex[0]) * 16 + (HEX_INT_MAP[hex[1].toUpperCase()] || +hex[1]); + } + + return HEX_INT_MAP[hex[1].toUpperCase()] || +hex[1]; +}; + +const hsl2hsv = function(hue, sat, light) { + sat = sat / 100; + light = light / 100; + let smin = sat; + const lmin = Math.max(light, 0.01); + let sv; + let v; + + light *= 2; + sat *= (light <= 1) ? light : 2 - light; + smin *= lmin <= 1 ? lmin : 2 - lmin; + v = (light + sat) / 2; + sv = light === 0 ? (2 * smin) / (lmin + smin) : (2 * sat) / (light + sat); + + return { + h: hue, + s: sv * 100, + v: v * 100 + }; +}; + +// `rgbToHsv` +// Converts an RGB color value to HSV +// *Assumes:* r, g, and b are contained in the set [0, 255] or [0, 1] +// *Returns:* { h, s, v } in [0,1] +const rgb2hsv = function(r, g, b) { + r = bound01(r, 255); + g = bound01(g, 255); + b = bound01(b, 255); + + const max = Math.max(r, g, b); + const min = Math.min(r, g, b); + let h, s; + let v = max; + + const d = max - min; + s = max === 0 ? 0 : d / max; + + if (max === min) { + h = 0; // achromatic + } else { + switch (max) { + case r: + h = (g - b) / d + (g < b ? 6 : 0); + break; + case g: + h = (b - r) / d + 2; + break; + case b: + h = (r - g) / d + 4; + break; + } + h /= 6; + } + + return { h: h * 360, s: s * 100, v: v * 100 }; +}; + +// `hsvToRgb` +// Converts an HSV color value to RGB. +// *Assumes:* h is contained in [0, 1] or [0, 360] and s and v are contained in [0, 1] or [0, 100] +// *Returns:* { r, g, b } in the set [0, 255] +const hsv2rgb = function(h, s, v) { + h = bound01(h, 360) * 6; + s = bound01(s, 100); + v = bound01(v, 100); + + const i = Math.floor(h); + const f = h - i; + const p = v * (1 - s); + const q = v * (1 - f * s); + const t = v * (1 - (1 - f) * s); + const mod = i % 6; + const r = [v, q, p, p, t, v][mod]; + const g = [t, v, v, q, p, p][mod]; + const b = [p, p, t, v, v, q][mod]; + + return { + r: Math.round(r * 255), + g: Math.round(g * 255), + b: Math.round(b * 255) + }; +}; + +export default class Color { + constructor(options) { + this._hue = 0; + this._saturation = 100; + this._value = 100; + this._alpha = 100; + + this.enableAlpha = false; + this.format = 'hex'; + this.value = ''; + + options = options || {}; + + for (let option in options) { + if (options.hasOwnProperty(option)) { + this[option] = options[option]; + } + } + + this.doOnChange(); + } + + set(prop, value) { + if (arguments.length === 1 && typeof prop === 'object') { + for (let p in prop) { + if (prop.hasOwnProperty(p)) { + this.set(p, prop[p]); + } + } + + return; + } + + this['_' + prop] = value; + this.doOnChange(); + } + + get(prop) { + return this['_' + prop]; + } + + toRgb() { + return hsv2rgb(this._hue, this._saturation, this._value); + } + + fromString(value) { + if (!value) { + this._hue = 0; + this._saturation = 100; + this._value = 100; + + this.doOnChange(); + return; + } + + const fromHSV = (h, s, v) => { + this._hue = Math.max(0, Math.min(360, h)); + this._saturation = Math.max(0, Math.min(100, s)); + this._value = Math.max(0, Math.min(100, v)); + + this.doOnChange(); + }; + + if (value.indexOf('hsl') !== -1) { + const parts = value.replace(/hsla|hsl|\(|\)/gm, '') + .split(/\s|,/g).filter((val) => val !== '').map((val, index) => index > 2 ? parseFloat(val) : parseInt(val, 10)); + + if (parts.length === 4) { + this._alpha = Math.floor(parseFloat(parts[3]) * 100); + } else if (parts.length === 3) { + this._alpha = 100; + } + if (parts.length >= 3) { + const { h, s, v } = hsl2hsv(parts[0], parts[1], parts[2]); + fromHSV(h, s, v); + } + } else if (value.indexOf('hsv') !== -1) { + const parts = value.replace(/hsva|hsv|\(|\)/gm, '') + .split(/\s|,/g).filter((val) => val !== '').map((val, index) => index > 2 ? parseFloat(val) : parseInt(val, 10)); + + if (parts.length === 4) { + this._alpha = Math.floor(parseFloat(parts[3]) * 100); + } else if (parts.length === 3) { + this._alpha = 100; + } + if (parts.length >= 3) { + fromHSV(parts[0], parts[1], parts[2]); + } + } else if (value.indexOf('rgb') !== -1) { + const parts = value.replace(/rgba|rgb|\(|\)/gm, '') + .split(/\s|,/g).filter((val) => val !== '').map((val, index) => index > 2 ? parseFloat(val) : parseInt(val, 10)); + + if (parts.length === 4) { + this._alpha = Math.floor(parseFloat(parts[3]) * 100); + } else if (parts.length === 3) { + this._alpha = 100; + } + if (parts.length >= 3) { + const { h, s, v } = rgb2hsv(parts[0], parts[1], parts[2]); + fromHSV(h, s, v); + } + } else if (value.indexOf('#') !== -1) { + const hex = value.replace('#', '').trim(); + let r, g, b; + + if (hex.length === 3) { + r = parseHexChannel(hex[0] + hex[0]); + g = parseHexChannel(hex[1] + hex[1]); + b = parseHexChannel(hex[2] + hex[2]); + } else if (hex.length === 6 || hex.length === 8) { + r = parseHexChannel(hex.substring(0, 2)); + g = parseHexChannel(hex.substring(2, 4)); + b = parseHexChannel(hex.substring(4, 6)); + } + + if (hex.length === 8) { + this._alpha = Math.floor(parseHexChannel(hex.substring(6)) / 255 * 100); + } else if (hex.length === 3 || hex.length === 6) { + this._alpha = 100; + } + + const { h, s, v } = rgb2hsv(r, g, b); + fromHSV(h, s, v); + } + } + + compare(color) { + return Math.abs(color._hue - this._hue) < 2 && + Math.abs(color._saturation - this._saturation) < 1 && + Math.abs(color._value - this._value) < 1 && + Math.abs(color._alpha - this._alpha) < 1; + } + + doOnChange() { + const { _hue, _saturation, _value, _alpha, format } = this; + + if (this.enableAlpha) { + switch (format) { + case 'hsl': + const hsl = hsv2hsl(_hue, _saturation / 100, _value / 100); + this.value = `hsla(${ _hue }, ${ Math.round(hsl[1] * 100) }%, ${ Math.round(hsl[2] * 100) }%, ${ _alpha / 100})`; + break; + case 'hsv': + this.value = `hsva(${ _hue }, ${ Math.round(_saturation) }%, ${ Math.round(_value) }%, ${ _alpha / 100})`; + break; + default: + const { r, g, b } = hsv2rgb(_hue, _saturation, _value); + this.value = `rgba(${r}, ${g}, ${b}, ${ _alpha / 100 })`; + } + } else { + switch (format) { + case 'hsl': + const hsl = hsv2hsl(_hue, _saturation / 100, _value / 100); + this.value = `hsl(${ _hue }, ${ Math.round(hsl[1] * 100) }%, ${ Math.round(hsl[2] * 100) }%)`; + break; + case 'hsv': + this.value = `hsv(${ _hue }, ${ Math.round(_saturation) }%, ${ Math.round(_value) }%)`; + break; + case 'rgb': + const { r, g, b } = hsv2rgb(_hue, _saturation, _value); + this.value = `rgb(${r}, ${g}, ${b})`; + break; + default: + this.value = toHex(hsv2rgb(_hue, _saturation, _value)); + } + } + } +}; diff --git a/examples/components/theme-configurator/editor/color-picker/src/components/alpha-slider.vue b/examples/components/theme-configurator/editor/color-picker/src/components/alpha-slider.vue new file mode 100644 index 00000000000..efeb87fe72a --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/components/alpha-slider.vue @@ -0,0 +1,132 @@ + + + diff --git a/examples/components/theme-configurator/editor/color-picker/src/components/color-list.vue b/examples/components/theme-configurator/editor/color-picker/src/components/color-list.vue new file mode 100644 index 00000000000..0230eed8985 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/components/color-list.vue @@ -0,0 +1,111 @@ + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/color-picker/src/components/hue-slider.vue b/examples/components/theme-configurator/editor/color-picker/src/components/hue-slider.vue new file mode 100644 index 00000000000..c93e42c0649 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/components/hue-slider.vue @@ -0,0 +1,123 @@ + + + diff --git a/examples/components/theme-configurator/editor/color-picker/src/components/picker-dropdown.vue b/examples/components/theme-configurator/editor/color-picker/src/components/picker-dropdown.vue new file mode 100644 index 00000000000..1c16839da14 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/components/picker-dropdown.vue @@ -0,0 +1,135 @@ + + + diff --git a/examples/components/theme-configurator/editor/color-picker/src/components/predefine.vue b/examples/components/theme-configurator/editor/color-picker/src/components/predefine.vue new file mode 100644 index 00000000000..1387c48a257 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/components/predefine.vue @@ -0,0 +1,61 @@ + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/color-picker/src/components/sv-panel.vue b/examples/components/theme-configurator/editor/color-picker/src/components/sv-panel.vue new file mode 100644 index 00000000000..66676a608c8 --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/components/sv-panel.vue @@ -0,0 +1,100 @@ + + + diff --git a/examples/components/theme-configurator/editor/color-picker/src/draggable.js b/examples/components/theme-configurator/editor/color-picker/src/draggable.js new file mode 100644 index 00000000000..339a4852c6a --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/draggable.js @@ -0,0 +1,36 @@ +import Vue from 'vue'; +let isDragging = false; + +export default function(element, options) { + if (Vue.prototype.$isServer) return; + const moveFn = function(event) { + if (options.drag) { + options.drag(event); + } + }; + const upFn = function(event) { + document.removeEventListener('mousemove', moveFn); + document.removeEventListener('mouseup', upFn); + document.onselectstart = null; + document.ondragstart = null; + + isDragging = false; + + if (options.end) { + options.end(event); + } + }; + element.addEventListener('mousedown', function(event) { + if (isDragging) return; + document.onselectstart = function() { return false; }; + document.ondragstart = function() { return false; }; + + document.addEventListener('mousemove', moveFn); + document.addEventListener('mouseup', upFn); + isDragging = true; + + if (options.start) { + options.start(event); + } + }); +} diff --git a/examples/components/theme-configurator/editor/color-picker/src/main.vue b/examples/components/theme-configurator/editor/color-picker/src/main.vue new file mode 100644 index 00000000000..21f9caeb0cb --- /dev/null +++ b/examples/components/theme-configurator/editor/color-picker/src/main.vue @@ -0,0 +1,190 @@ + + + diff --git a/examples/components/theme-configurator/editor/color.vue b/examples/components/theme-configurator/editor/color.vue new file mode 100644 index 00000000000..90705d6f2d4 --- /dev/null +++ b/examples/components/theme-configurator/editor/color.vue @@ -0,0 +1,93 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/fontLineHeight.vue b/examples/components/theme-configurator/editor/fontLineHeight.vue new file mode 100644 index 00000000000..ef7455f5ea7 --- /dev/null +++ b/examples/components/theme-configurator/editor/fontLineHeight.vue @@ -0,0 +1,104 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/fontSize.vue b/examples/components/theme-configurator/editor/fontSize.vue new file mode 100644 index 00000000000..f78fd06cbee --- /dev/null +++ b/examples/components/theme-configurator/editor/fontSize.vue @@ -0,0 +1,105 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/fontWeight.vue b/examples/components/theme-configurator/editor/fontWeight.vue new file mode 100644 index 00000000000..9a30581fabc --- /dev/null +++ b/examples/components/theme-configurator/editor/fontWeight.vue @@ -0,0 +1,109 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/input.vue b/examples/components/theme-configurator/editor/input.vue new file mode 100644 index 00000000000..548a1ee27e3 --- /dev/null +++ b/examples/components/theme-configurator/editor/input.vue @@ -0,0 +1,45 @@ + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/mixin.vue b/examples/components/theme-configurator/editor/mixin.vue new file mode 100644 index 00000000000..f898eef5532 --- /dev/null +++ b/examples/components/theme-configurator/editor/mixin.vue @@ -0,0 +1,81 @@ + + \ No newline at end of file diff --git a/examples/components/theme-configurator/editor/simpleText.vue b/examples/components/theme-configurator/editor/simpleText.vue new file mode 100644 index 00000000000..f0628c480e3 --- /dev/null +++ b/examples/components/theme-configurator/editor/simpleText.vue @@ -0,0 +1,41 @@ + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/index.vue b/examples/components/theme-configurator/index.vue new file mode 100644 index 00000000000..6e7483bdeef --- /dev/null +++ b/examples/components/theme-configurator/index.vue @@ -0,0 +1,195 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/main.vue b/examples/components/theme-configurator/main.vue new file mode 100644 index 00000000000..5acbc9c99d2 --- /dev/null +++ b/examples/components/theme-configurator/main.vue @@ -0,0 +1,130 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme-configurator/shortcut.vue b/examples/components/theme-configurator/shortcut.vue new file mode 100644 index 00000000000..7a77098d8af --- /dev/null +++ b/examples/components/theme-configurator/shortcut.vue @@ -0,0 +1,27 @@ + + \ No newline at end of file diff --git a/examples/components/theme-configurator/utils/boxShadow.js b/examples/components/theme-configurator/utils/boxShadow.js new file mode 100644 index 00000000000..382aa4b60d2 --- /dev/null +++ b/examples/components/theme-configurator/utils/boxShadow.js @@ -0,0 +1,59 @@ +const VALUES_REG = /,(?![^\(]*\))/; +const PARTS_REG = /\s(?![^(]*\))/; +const LENGTH_REG = /^[0-9]+[a-zA-Z%]+?$/; + +const parseValue = str => { + const parts = str.split(PARTS_REG); + const inset = parts.includes('inset'); + const last = parts.slice(-1)[0]; + const color = !isLength(last) ? last : undefined; + + const nums = parts + .filter(n => n !== 'inset') + .filter(n => n !== color) + .map(toNum); + const [ offsetX, offsetY, blurRadius, spreadRadius ] = nums; + + return { + inset, + offsetX, + offsetY, + blurRadius, + spreadRadius, + color + }; +}; + +const stringifyValue = obj => { + const { + inset, + offsetX = 0, + offsetY = 0, + blurRadius = 0, + spreadRadius, + color + } = obj || {}; + + return [ + (inset ? 'inset' : null), + offsetX, + offsetY, + blurRadius, + spreadRadius, + color + ].filter(v => v !== null && v !== undefined) + .map(toPx) + .map(s => ('' + s).trim()) + .join(' '); +}; + +const isLength = v => v === '0' || LENGTH_REG.test(v); +const toNum = v => { + if (!/px$/.test(v) && v !== '0') return v; + const n = parseFloat(v); + return !isNaN(n) ? n : v; +}; +const toPx = n => typeof n === 'number' && n !== 0 ? (n + 'px') : n; + +export const parse = str => str.split(VALUES_REG).map(s => s.trim()).map(parseValue); +export const stringify = arr => arr.map(stringifyValue).join(', '); diff --git a/examples/components/theme-configurator/utils/utils.js b/examples/components/theme-configurator/utils/utils.js new file mode 100644 index 00000000000..1068a8d5293 --- /dev/null +++ b/examples/components/theme-configurator/utils/utils.js @@ -0,0 +1,68 @@ +import deepmerge from 'deepmerge'; +import constant from '../../../i18n/theme-editor.json'; + +export const filterConfigType = (name) => { + switch (name) { + case 'color': + case 'typography': + case 'border': + return 'global'; + default: + return 'local'; + } +}; + +export const filterGlobalValue = (defaultConfig, userConfig) => { + const valueObject = {}; + const globalArr = ['color', 'typography', 'border']; + globalArr.forEach((global) => { + const configObj = {}; + defaultConfig + .find(config => (config.name === global)) + .config.forEach(c => (configObj[c.key] = deepmerge({}, c))); + valueObject[global] = configObj; + Object.keys(configObj).forEach((c) => { + if (userConfig.global[c]) { + configObj[c].value = userConfig.global[c]; + } + }); + }); + return valueObject; +}; + +export const getStyleDisplayValue = (displayValue, global) => { + if (displayValue.startsWith('$')) { + return global[displayValue].value; + } + return displayValue; +}; + +const getLang = () => { + return location.hash.replace('#', '').split('/')[1] || 'zh-CN'; +}; + +const getNameFromI18N = (name) => { + const lang = getLang(); + return constant.filter(config => config.lang === lang)[0][name]; +}; + +export const getVariableDisplayName = (key) => { + return getNameFromI18N('variable-name')[key] || key; +}; + +export const getStyleDisplayName = (config, componentName) => { + const displayNameMap = getNameFromI18N('display-name'); + if (config.name) { + return getVariableDisplayName(config.key.replace('$--', '')); + } + let displayName = config.key.replace(`$--${componentName}-`, ''); + Object.keys(displayNameMap).forEach((name) => { + displayName = displayName.replace(name, displayNameMap[name]); + }); + displayName = displayName.replace(/-/g, ' '); + return displayName.trim(); +}; + +export const getActionDisplayName = (key) => { + return getNameFromI18N('action')[key] || key; +}; diff --git a/examples/components/theme-picker.vue b/examples/components/theme-picker.vue index c6c4b500586..3fd147c2583 100644 --- a/examples/components/theme-picker.vue +++ b/examples/components/theme-picker.vue @@ -5,11 +5,11 @@ v-model="theme"> - diff --git a/examples/components/theme/components-preview.vue b/examples/components/theme/components-preview.vue new file mode 100644 index 00000000000..58aa5b420f6 --- /dev/null +++ b/examples/components/theme/components-preview.vue @@ -0,0 +1,539 @@ + + + diff --git a/examples/components/theme/constant.js b/examples/components/theme/constant.js new file mode 100644 index 00000000000..6730aa97642 --- /dev/null +++ b/examples/components/theme/constant.js @@ -0,0 +1,16 @@ +export const DEFAULT_THEME_CONFIG = { + global: {}, + local: {} +}; + +export const ELEMENT_THEME_USER_CONFIG = 'ELEMENT_THEME_USER_CONFIG'; + +export const ELEMENT_THEME_PREVIEW_CONFIG = 'ELEMENT_THEME_PREVIEW_CONFIG'; + +export const ACTION_DOWNLOAD_THEME = 'ELEMENT_THEME_ACTION_DOWNLOAD'; + +export const ACTION_APPLY_THEME = 'ELEMENT_THEME_ACTION_ALLPY_CSS'; + +export const ACTION_COMPONECT_SELECT = 'ELEMENT_THEME_ACTION_COMPONECT_SELECT'; + +export const ACTION_USER_CONFIG_UPDATE = 'ELEMENT_THEME_USER_CONFIG_UPDATE'; diff --git a/examples/components/theme/loader/ajax.js b/examples/components/theme/loader/ajax.js new file mode 100644 index 00000000000..ce248e558d9 --- /dev/null +++ b/examples/components/theme/loader/ajax.js @@ -0,0 +1,65 @@ +const defaultError = 'Server Error 500'; +const defaultTimeout = 'Request Timeout'; +const xhr = (method, url, data = null, cb) => { + return new window.Promise((resolve, reject) => { + const xhr = new XMLHttpRequest(); + const doReject = (xhr) => { + reject(xhr.response || xhr.statusText || defaultError); + }; + xhr.open(method, url); + xhr.setRequestHeader('Content-Type', 'application/json'); + xhr.timeout = 10000; + if (cb) cb(xhr); + xhr.onload = () => { + if (xhr.readyState === 4) { + if ((xhr.status >= 200 && xhr.status < 300) || xhr.status === 304) { + let response = xhr.response; + const type = xhr.getResponseHeader('Content-Type'); + if (type.indexOf('zip') > -1) { + let filename = 'style.zip'; + const disposition = xhr.getResponseHeader('content-disposition'); + if (disposition && disposition.indexOf('attachment') !== -1) { + var filenameRegex = /filename[^;=\n]*=((['"]).*?\2|[^;\n]*)/; + var matches = filenameRegex.exec(disposition); + if (matches != null && matches[1]) { + filename = matches[1].replace(/['"]/g, ''); + } + } + var blob = new Blob([response], { type }); + var zipUrl = URL.createObjectURL(blob); + var link = document.createElement('a'); + link.href = zipUrl; + link.download = filename; + link.click(); + resolve(response); + return; + } + try { + response = JSON.parse(xhr.response); + } catch (e) {} + resolve(response); + } else { + doReject(xhr); + } + } else { + doReject(xhr); + } + }; + xhr.onerror = () => { + doReject(xhr); + }; + xhr.ontimeout = () => { + xhr.abort(); + reject(defaultTimeout); + }; + xhr.send(JSON.stringify(data)); + }); +}; + +export const post = (url, data, cb) => { + return xhr('POST', url, data, cb); +}; + +export const get = (url) => { + return xhr('GET', url); +}; diff --git a/examples/components/theme/loader/api.js b/examples/components/theme/loader/api.js new file mode 100644 index 00000000000..450786d3c4b --- /dev/null +++ b/examples/components/theme/loader/api.js @@ -0,0 +1,24 @@ +import Element from 'main/index.js'; +import { post, get } from './ajax'; + +const { version } = Element; + +const hostList = { + local: 'http://localhost:3008/', + alpha: 'https://element-api.ar.elenet.me/element/theme/', + production: 'https://element-api.ele.me/element/theme/' +}; + +const host = hostList[process.env.FAAS_ENV] || hostList.production; + +export const getVars = () => { + return get(`${host}getVariable?version=${version}`); +}; + +export const getTestEle = () => { + return get(`${hostList.alpha}getVariable`); +}; + +export const updateVars = (data, cb) => { + return post(`${host}updateVariable?version=${version}`, data, cb); +}; diff --git a/examples/components/theme/loader/docStyle.vue b/examples/components/theme/loader/docStyle.vue new file mode 100644 index 00000000000..07aa433153c --- /dev/null +++ b/examples/components/theme/loader/docStyle.vue @@ -0,0 +1,62 @@ + diff --git a/examples/components/theme/loader/index.vue b/examples/components/theme/loader/index.vue new file mode 100644 index 00000000000..e078d11589d --- /dev/null +++ b/examples/components/theme/loader/index.vue @@ -0,0 +1,106 @@ + \ No newline at end of file diff --git a/examples/components/theme/loader/loading/index.vue b/examples/components/theme/loader/loading/index.vue new file mode 100644 index 00000000000..1f597e1acc7 --- /dev/null +++ b/examples/components/theme/loader/loading/index.vue @@ -0,0 +1,35 @@ + + diff --git a/examples/components/theme/loader/loading/progress.js b/examples/components/theme/loader/loading/progress.js new file mode 100644 index 00000000000..54ba20d6517 --- /dev/null +++ b/examples/components/theme/loader/loading/progress.js @@ -0,0 +1,6 @@ +import Vue from 'vue'; +import ProgressBar from './progress.vue'; + +Vue.prototype.$bar = new Vue(ProgressBar).$mount(); + +document.body.appendChild(Vue.prototype.$bar.$el); diff --git a/examples/components/theme/loader/loading/progress.vue b/examples/components/theme/loader/loading/progress.vue new file mode 100644 index 00000000000..6deabaf7d4d --- /dev/null +++ b/examples/components/theme/loader/loading/progress.vue @@ -0,0 +1,108 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme/localstorage.js b/examples/components/theme/localstorage.js new file mode 100644 index 00000000000..7d330e6ba34 --- /dev/null +++ b/examples/components/theme/localstorage.js @@ -0,0 +1,38 @@ +import { + ELEMENT_THEME_PREVIEW_CONFIG, + ELEMENT_THEME_USER_CONFIG +} from './constant'; + +export const saveToLocal = (key, value) => { + localStorage.setItem(key, JSON.stringify(value)); +}; + +export const loadFromLocal = (key) => { + try { + return JSON.parse(localStorage.getItem(key)); + } catch (e) { + console.error(e); + return null; + } +}; + +export const savePreviewToLocal = (value) => { + saveToLocal(ELEMENT_THEME_PREVIEW_CONFIG, value); +}; + +export const loadPreviewFromLocal = () => { + return loadFromLocal(ELEMENT_THEME_PREVIEW_CONFIG) || {}; +}; + +export const removePreviewFromLocal = () => { + return localStorage.removeItem(ELEMENT_THEME_PREVIEW_CONFIG); +}; + +export const saveUserThemeToLocal = (value) => { + saveToLocal(ELEMENT_THEME_USER_CONFIG, value); +}; + +export const loadUserThemeFromLocal = () => { + return loadFromLocal(ELEMENT_THEME_USER_CONFIG); +}; + diff --git a/examples/components/theme/theme-card.vue b/examples/components/theme/theme-card.vue new file mode 100644 index 00000000000..f2ca31d7698 --- /dev/null +++ b/examples/components/theme/theme-card.vue @@ -0,0 +1,406 @@ + + + + + \ No newline at end of file diff --git a/examples/components/theme/theme-list.js b/examples/components/theme/theme-list.js new file mode 100644 index 00000000000..00e219dcc3c --- /dev/null +++ b/examples/components/theme/theme-list.js @@ -0,0 +1,15 @@ +export const themeList = [ + { + name: 'Element', + author: 'Element', + theme: '{"global":{"$--color-primary":"#2460e0"},"local":{}}' + } +]; + +export const eleThemeList = [ + { + name: 'Kiwi', + author: 'Element', + theme: '{"global":{"$--color-primary":"#1989FA","$--color-success":"#5CB87A","$--color-warning":"#F5A623","$--color-danger":"#FF4D4F","$--color-info":"#8896B3","$--font-size-small":"13px","$--font-size-base":"14px","$--font-size-medium":"16px","$--font-size-large":"22px","$--font-size-extra-large":"28px","$--font-line-height-secondary":"20px"},"local":{"$--button-primary-background-color":"$--color-primary","$--switch-font-size":"14px","$--datepicker-active-color":"$--color-primary","$--tooltip-border-color":"$--border-color-base","$--tooltip-color":"#FFFFFF","$--tooltip-padding":"10px","$--collapse-header-font-size":"14px","$--collapse-content-font-size":"14px","$--collapse-content-font-color":"$--color-text-regular","$--radio-input-background-color":"#FFFFFF","$--radio-icon-color":"$--color-warning","$--radio-button-checked-background-color":"$--color-primary","$--input-border-radius":"$--border-radius-base","$--select-input-focus-border-color":"$--color-primary","$--select-font-size":"14px","$--select-option-selected-font-color":"$--color-primary","$--select-input-font-size":"14px","$--select-option-height":"34px","$--slider-main-background-color":"$--color-primary","$--tag-font-color":"$--color-primary","$--tag-default-hover-background-color":"$--color-primary","$--message-warning-font-color":"$--color-warning","$--alert-title-font-size":"14px","$--alert-icon-size":"14px","$--alert-icon-large-size":"22px","$--alert-close-customed-font-size":"12px","$--notification-title-font-size":"16px","$--notification-content-font-size":"14px","$--menu-item-font-color":"$--color-primary"}}' + } +]; diff --git a/examples/components/theme/utils.js b/examples/components/theme/utils.js new file mode 100644 index 00000000000..7a6de22d8d9 --- /dev/null +++ b/examples/components/theme/utils.js @@ -0,0 +1,24 @@ +export const isEmptyObject = (obj) => (JSON.stringify(obj) === '{}'); + +export const getThemeConfigObject = (config) => { + try { + const conf = JSON.parse(config); + const { global, local } = conf; + if (!isEmptyObject(global) || !isEmptyObject(local)) { + return conf; + } + return false; + } catch (e) { + return false; + } +}; + +export const updateDomHeadStyle = (id, styleContent) => { + let styleTag = document.getElementById(id); + if (!styleTag) { + styleTag = document.createElement('style'); + styleTag.setAttribute('id', id); + document.head.appendChild(styleTag); + } + styleTag.innerText = styleContent.replace(/@font-face{[^}]+}/, ''); +}; diff --git a/examples/demo-styles/alert.scss b/examples/demo-styles/alert.scss new file mode 100644 index 00000000000..dae5f062a57 --- /dev/null +++ b/examples/demo-styles/alert.scss @@ -0,0 +1,7 @@ +.demo-block.demo-alert .el-alert { + margin: 20px 0 0; +} + +.demo-block.demo-alert .el-alert:first-child { + margin: 0; +} diff --git a/examples/demo-styles/avatar.scss b/examples/demo-styles/avatar.scss new file mode 100644 index 00000000000..d655db787af --- /dev/null +++ b/examples/demo-styles/avatar.scss @@ -0,0 +1,62 @@ +.demo-avatar { + + &.demo-basic { + text-align: center; + + .demo-basic--circle, .demo-basic--square { + display: flex; + justify-content: space-between; + align-items: center; + .block { + flex: 1; + } + + .block:not(:last-child) { + border-right: 1px solid rgba(224, 230, 237, 0.5); + } + } + + } + + .sub-title { + margin-bottom: 10px; + font-size: 14px; + color: #8492a6; + } + + .el-col:not(:last-child) { + border-right: 1px solid rgba(224,230,237,.5); + } + + .demo-type { + display: flex; + + >div { + flex: 1; + text-align: center; + } + + >div:not(:last-child) { + border-right: 1px solid rgba(224,230,237,.5); + } + } + + .demo-fit { + display: flex; + text-align: center; + justify-content: space-between; + + .block { + flex: 1; + display: flex; + flex-direction: column; + flex-grow: 0; + } + + .title { + margin-bottom: 10px; + font-size: 14px; + color: #8492a6; + } + } +} diff --git a/examples/demo-styles/badge.scss b/examples/demo-styles/badge.scss new file mode 100644 index 00000000000..494dacdedc5 --- /dev/null +++ b/examples/demo-styles/badge.scss @@ -0,0 +1,19 @@ +.demo-badge.demo-block .el-dropdown { + vertical-align: middle; +} +.demo-badge.demo-block { + .share-button { + width: 36px; + padding: 10px; + } + + .mark { + margin-top: 8px; + line-height: 1; + float: right; + } + + .item { + margin-right: 40px; + } +} diff --git a/examples/demo-styles/border.scss b/examples/demo-styles/border.scss new file mode 100644 index 00000000000..57df6833217 --- /dev/null +++ b/examples/demo-styles/border.scss @@ -0,0 +1,44 @@ +.demo-border .text { + width: 15%; +} +.demo-border .line { + width: 70%; +} +.demo-border .line div { + width: 100%; + height: 0; + border-top: 1px solid #eee; +} +.demo-border .line .dashed { + border-top: 2px dashed #eee; +} +.demo-shadow { + height: 100px; + width: 50%; + border: 1px solid #eee; +} +.demo-shadow-text { + line-height: 50px; + color: #666; + font-size: 14px; +} +.demo-radius .title { + color: #666; + font-size: 18px; + margin: 10px 0; +} +.demo-radius .value { + color: #333; + font-size: 16px; + margin: 10px 0; +} +.demo-radius .radius { + height: 60px; + width: 70%; + border: 1px solid #d7dae2; + border-radius: 0; + margin-top: 20px; +} +.demo-radius .radius-30 { + border-radius: 30px; +} diff --git a/examples/demo-styles/button-group-enhance.scss b/examples/demo-styles/button-group-enhance.scss new file mode 100644 index 00000000000..ee72bc03c4d --- /dev/null +++ b/examples/demo-styles/button-group-enhance.scss @@ -0,0 +1,19 @@ +.el-card .el-card__body { + padding: 0; + + .content { + padding: 20px; + } + .el-button-group-enhance { + .el-button { + border-bottom: none; + border-radius: 0; + &:first-child { + border-left: none; + } + &.el-dropdown__caret-button { + border-right: none; + } + } + } +} diff --git a/examples/demo-styles/button.scss b/examples/demo-styles/button.scss new file mode 100644 index 00000000000..bc8b7881a28 --- /dev/null +++ b/examples/demo-styles/button.scss @@ -0,0 +1,21 @@ +.demo-block.demo-button { + .el-row { + margin-bottom: 20px; + + &:last-child { + margin-bottom: 0; + } + } + .el-button + .el-button { + margin-left: 10px; + } + .el-button-group { + .el-button + .el-button { + margin-left: 0; + } + + & + .el-button-group { + margin-left: 10px; + } + } +} diff --git a/examples/demo-styles/calendar.scss b/examples/demo-styles/calendar.scss new file mode 100644 index 00000000000..62198bd1c82 --- /dev/null +++ b/examples/demo-styles/calendar.scss @@ -0,0 +1,5 @@ +.demo-calendar.demo-block { + .is-selected { + color: #1989FA; + } +} diff --git a/examples/demo-styles/card.scss b/examples/demo-styles/card.scss new file mode 100644 index 00000000000..a558b149621 --- /dev/null +++ b/examples/demo-styles/card.scss @@ -0,0 +1,33 @@ +.demo-block.demo-card { + .text { + font-size: 14px; + } + + .time { + font-size: 13px; + color: #999; + } + + .bottom { + margin-top: 13px; + line-height: 12px; + } + + .item { + margin-bottom: 18px; + } + + .button { + padding: 0; + float: right; + } + + .image { + width: 100%; + display: block; + } + + .box-card { + width: 480px; + } +} diff --git a/examples/demo-styles/carousel.scss b/examples/demo-styles/carousel.scss new file mode 100644 index 00000000000..dc5295a2989 --- /dev/null +++ b/examples/demo-styles/carousel.scss @@ -0,0 +1,46 @@ +.demo-carousel .block { + padding: 30px; + text-align: center; + border-right: solid 1px #eff2f6; + display: inline-block; + width: 49%; + box-sizing: border-box; + &:last-child { + border-right: none; + } +} + +.demo-carousel .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} + +.demo-carousel .el-carousel__container { + text-align: center; +} + +.demo-carousel .el-carousel__item { + h3 { + color: #fff; + font-size: 18px; + line-height: 300px; + margin: 0; + &.small { + font-size: 14px; + line-height: 150px; + } + &.medium { + font-size: 14px; + line-height: 200px; + } + } + &:nth-child(2n) { + background-color: #99a9bf; + } + &:nth-child(2n + 1) { + background-color: #d3dce6; + } +} + diff --git a/examples/demo-styles/cascader.scss b/examples/demo-styles/cascader.scss new file mode 100644 index 00000000000..765676c909b --- /dev/null +++ b/examples/demo-styles/cascader.scss @@ -0,0 +1,30 @@ +.demo-cascader { + .el-cascader { + width: 222px; + } +} +.demo-cascader-size { + .el-cascader { + vertical-align: top; + margin-right: 15px; + } +} +.demo-cascader .source > div { + display: flex; +} +.demo-cascader .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + width: 50%; + box-sizing: border-box; + &:last-child { + border-right: none; + } +} +.demo-cascader .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} diff --git a/examples/demo-styles/collapse.scss b/examples/demo-styles/collapse.scss new file mode 100644 index 00000000000..11c0d36f69c --- /dev/null +++ b/examples/demo-styles/collapse.scss @@ -0,0 +1,7 @@ +.demo-collapse { + .el-collapse-item__header { + .header-icon { + margin-left: 5px; + } + } +} diff --git a/examples/demo-styles/color-picker.scss b/examples/demo-styles/color-picker.scss new file mode 100644 index 00000000000..621cc8accf3 --- /dev/null +++ b/examples/demo-styles/color-picker.scss @@ -0,0 +1,20 @@ +.demo-color-picker .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + display: inline-block; + width: 50%; + box-sizing: border-box; + &:last-child { + border-right: none; + } +} +.demo-color-picker .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} +.demo-color-picker .el-color-picker + .el-color-picker { + margin-left: 20px; +} diff --git a/examples/demo-styles/color.scss b/examples/demo-styles/color.scss new file mode 100644 index 00000000000..c8a145700d3 --- /dev/null +++ b/examples/demo-styles/color.scss @@ -0,0 +1,72 @@ +.demo-color-box { + position: relative; + border-radius: 4px; + padding: 20px; + margin: 5px 0; + height: 114px; + box-sizing: border-box; + color: #fff; + font-size: 14px; + + & .value { + font-size: 12px; + opacity: 0.69; + line-height: 24px; + } +} +.demo-color-box-other { + height: 74px; + margin: 10px 0 !important; + border-radius: 4px 4px 4px 4px !important; + padding: 15px 20px; +} +.demo-color-box-group { + .demo-color-box { + border-radius: 0; + margin: 0; + } + .demo-color-box:first-child { + border-radius: 4px 4px 0 0; + } + .demo-color-box:last-child { + border-radius: 0 0 4px 4px; + } +} +.bg-color-sub { + width: 100%; + height: 40px; + left: 0; + bottom: 0; + position: absolute; + border-radius: 0 0 4px 4px; +} +.bg-blue-sub-item { + width: 11.1111111%; + height: 100%; + display: inline-block; +} +.bg-blue-sub-item:first-child { + border-radius: 0 0 0 4px; +} +.bg-success-sub-item { + width: 50%; + height: 100%; + display: inline-block; +} +.bg-success-sub-item:first-child { + border-radius: 0 0 0 4px; +} +.bg-success-sub-item:last-child { + border-radius: 0 0 4px 0; +} +.bg-transparent { + border: 1px solid #fcc3c3; + color: #303133; + background: url("data:image/svg+xml;utf8,"); + background-repeat: no-repeat; + background-position: center center; + background-size: 100% 100%, auto; +} +.demo-color-box-lite { + color: #303133; +} diff --git a/examples/demo-styles/container.scss b/examples/demo-styles/container.scss new file mode 100644 index 00000000000..f97fc74e947 --- /dev/null +++ b/examples/demo-styles/container.scss @@ -0,0 +1,43 @@ +.el-header, +.el-footer { + background-color: #b3c0d1; + color: #333; + line-height: 60px; +} + +.el-aside { + color: #333; +} + +#chang-jian-ye-mian-bu-ju + .demo-container { + .el-header, + .el-footer { + text-align: center; + } + + .el-aside { + background-color: #d3dce6; + text-align: center; + line-height: 200px; + } + + .el-main { + background-color: #e9eef3; + color: #333; + text-align: center; + line-height: 160px; + } + + & > .source > .el-container { + margin-bottom: 40px; + + &:nth-child(5) .el-aside, + &:nth-child(6) .el-aside { + line-height: 260px; + } + + &:nth-child(7) .el-aside { + line-height: 320px; + } + } +} diff --git a/examples/demo-styles/date-picker.scss b/examples/demo-styles/date-picker.scss new file mode 100644 index 00000000000..96bee1a421b --- /dev/null +++ b/examples/demo-styles/date-picker.scss @@ -0,0 +1,36 @@ +.demo-block.demo-date-picker .source > div { + padding: 0; + display: flex; + flex-wrap: wrap; +} + +.demo-date-picker .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + flex: 1; + &:last-child { + border-right: none; + } +} + +.demo-date-picker .container { + flex: 1; + border-right: solid 1px #eff2f6; + .block { + border-right: none; + &:last-child { + border-top: solid 1px #eff2f6; + } + } + &:last-child { + border-right: none; + } +} + +.demo-date-picker .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} diff --git a/examples/demo-styles/datetime-picker.scss b/examples/demo-styles/datetime-picker.scss new file mode 100644 index 00000000000..bec439b74e2 --- /dev/null +++ b/examples/demo-styles/datetime-picker.scss @@ -0,0 +1,21 @@ +.demo-block.demo-datetime-picker .source > div { + padding: 0; + display: flex; +} + +.demo-datetime-picker .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + flex: 1; + &:last-child { + border-right: none; + } +} + +.demo-datetime-picker .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} diff --git a/examples/demo-styles/dialog.scss b/examples/demo-styles/dialog.scss new file mode 100644 index 00000000000..ddf104332cc --- /dev/null +++ b/examples/demo-styles/dialog.scss @@ -0,0 +1,20 @@ +.demo-block.demo-dialog { + .dialog-footer button:first-child { + margin-right: 10px; + } + .full-image { + width: 100%; + } + .el-dialog__wrapper { + margin: 0; + } + .el-select { + width: 300px; + } + .el-input { + width: 300px; + } + .el-button--text { + margin-right: 15px; + } +} diff --git a/examples/demo-styles/divider.scss b/examples/demo-styles/divider.scss new file mode 100644 index 00000000000..a4cd0c07cb4 --- /dev/null +++ b/examples/demo-styles/divider.scss @@ -0,0 +1,9 @@ +.demo-divider-container-1 { + display: inline-block; + width: 33%; +} + +.demo-divider-container-2 { + display: inline-block; + width: 50%; +} \ No newline at end of file diff --git a/examples/demo-styles/drawer.scss b/examples/demo-styles/drawer.scss new file mode 100644 index 00000000000..117136171f8 --- /dev/null +++ b/examples/demo-styles/drawer.scss @@ -0,0 +1,21 @@ +.demo-drawer { + &__content { + display: flex; + flex-direction: column; + height: 100%; + form { + flex: 1; + } + } + + &__footer { + display: flex; + button { + flex: 1; + } + } +} + +.el-drawer__body { + padding: 20px; +} diff --git a/examples/demo-styles/dropdown.scss b/examples/demo-styles/dropdown.scss new file mode 100644 index 00000000000..0b648618aab --- /dev/null +++ b/examples/demo-styles/dropdown.scss @@ -0,0 +1,37 @@ +.demo-block { + .el-dropdown { + vertical-align: top; + + & + .el-dropdown { + margin-left: 15px; + } + } + .el-dropdown-link { + cursor: pointer; + color: #2460e0; + } + .el-icon-arrow-down { + font-size: 12px; + } +} + +.block-col-2 { + margin: -24px; + + .el-col { + padding: 30px 0; + text-align: center; + border-right: 1px solid #eff2f6; + + &:last-child { + border-right: 0; + } + } +} + +.demo-dropdown .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} diff --git a/examples/demo-styles/form.scss b/examples/demo-styles/form.scss new file mode 100644 index 00000000000..6d04bc83e0e --- /dev/null +++ b/examples/demo-styles/form.scss @@ -0,0 +1,73 @@ +.demo-form { + .el-select .el-input { + width: 380px; + } + .el-form { + width: 460px; + } + + .line { + text-align: center; + } + + .el-checkbox-group { + width: 320px; + margin: 0; + padding: 0; + list-style: none; + + &:after, + &:before { + content: " "; + display: table; + } + &:after { + clear: both; + visibility: hidden; + font-size: 0; + height: 0; + } + + .el-checkbox { + float: left; + width: 160px; + padding-right: 20px; + margin: 0; + padding: 0; + + + .el-checkbox { + margin-left: 0; + } + } + } + .demo-form-normal { + width: 460px; + } + .demo-form-inline { + width: auto; + + .el-input { + width: 150px; + } + > * { + margin-right: 10px; + } + } + .demo-ruleForm { + width: 460px; + + .el-select .el-input { + width: 360px; + } + } + .demo-dynamic { + .el-input { + margin-right: 10px; + width: 270px; + vertical-align: top; + } + } + .fr { + float: right; + } +} diff --git a/examples/demo-styles/i18n.scss b/examples/demo-styles/i18n.scss new file mode 100644 index 00000000000..eabe9ce05b3 --- /dev/null +++ b/examples/demo-styles/i18n.scss @@ -0,0 +1,8 @@ +ul.language-list { + color: #5e6d82; + font-size: 14px; + padding-left: 20px; + li { + line-height: 1.8; + } +} diff --git a/examples/demo-styles/icon.scss b/examples/demo-styles/icon.scss new file mode 100644 index 00000000000..3f670b440ef --- /dev/null +++ b/examples/demo-styles/icon.scss @@ -0,0 +1,69 @@ +.demo-icon .source > div > i { + color: #606266; + margin: 0 20px; + font-size: 1.5em; + vertical-align: middle; +} + +.demo-icon .source button { + margin: 0 20px; +} + +.page-component .content > ul.icon-list { + overflow: hidden; + list-style: none; + padding: 0!important; + border: solid 1px #eaeefb; + border-radius: 4px; +} +.icon-list li { + float: left; + width: 16.66%; + text-align: center; + height: 120px; + line-height: 120px; + color: #666; + font-size: 13px; + border-right: 1px solid #eee; + border-bottom: 1px solid #eee; + margin-right: -1px; + margin-bottom: -1px; + + &::after { + display: inline-block; + content: ""; + height: 100%; + vertical-align: middle; + } + + span { + display: inline-block; + line-height: normal; + vertical-align: middle; + font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", + "Microsoft YaHei", SimSun, sans-serif; + color: #99a9bf; + transition: color 0.15s linear; + } + + i { + display: block; + font-size: 32px; + margin-bottom: 15px; + color: #606266; + transition: color 0.15s linear; + } + + .icon-name { + display: inline-block; + padding: 0 3px; + height: 1em; + } + + &:hover { + span, + i { + color: rgb(92, 182, 255); + } + } +} diff --git a/examples/demo-styles/image.scss b/examples/demo-styles/image.scss new file mode 100644 index 00000000000..40659922358 --- /dev/null +++ b/examples/demo-styles/image.scss @@ -0,0 +1,78 @@ +@keyframes dot { + 0% { width: 0; margin-right: 1em; } + 100% { width: 1em; margin-right: 0; } +} + +.demo-image { + .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + display: inline-block; + width: 20%; + box-sizing: border-box; + vertical-align: top; + &:last-child { + border-right: none; + } + } + + .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; + } +} + +.demo-image__placeholder, .demo-image__error { + @extend .demo-image; + + .block { + width: 49%; + } + + .el-image { + width: 300px; + height: 200px; + } + + .image-slot { + display: flex; + justify-content: center; + align-items: center; + width: 100%; + height: 100%; + background: #f5f7fa; + color: #A7A8AD; + font-size: 14px; + } +} + +.demo-image__placeholder { + .dot { + animation: dot 2s infinite steps(3, start); + overflow: hidden; + } +} + +.demo-image__error { + .image-slot { + font-size: 30px; + } +} + +.demo-image__lazy { + height: 400px; + overflow-y: auto; + + .el-image { + display: block; + min-height: 200px; + margin-bottom: 10px; + + &:last-child { + margin-bottom: 0; + } + } +} diff --git a/examples/demo-styles/index.scss b/examples/demo-styles/index.scss new file mode 100644 index 00000000000..7d88b1adf6f --- /dev/null +++ b/examples/demo-styles/index.scss @@ -0,0 +1,47 @@ +@import "./alert.scss"; +@import "./badge.scss"; +@import "./border.scss"; +@import "./button.scss"; +@import "./calendar.scss"; +@import "./card.scss"; +@import "./carousel.scss"; +@import "./cascader.scss"; +@import "./collapse.scss"; +@import "./color-picker.scss"; +@import "./color.scss"; +@import "./container.scss"; +@import "./date-picker.scss"; +@import "./datetime-picker.scss"; +@import "./dialog.scss"; +@import "./dropdown.scss"; +@import "./form.scss"; +@import "./i18n.scss"; +@import "./icon.scss"; +@import "./input-number.scss"; +@import "./input.scss"; +@import "./layout.scss"; +@import "./loading.scss"; +@import "./menu.scss"; +@import "./pagination.scss"; +@import "./popover.scss"; +@import "./progress.scss"; +@import "./rate.scss"; +@import "./select.scss"; +@import "./slider.scss"; +@import "./switch.scss"; +@import "./table.scss"; +@import "./tag.scss"; +@import "./time-picker.scss"; +@import "./timeline.scss"; +@import "./tooltip.scss"; +@import "./transition.scss"; +@import "./transfer.scss"; +@import "./tree.scss"; +@import "./typography.scss"; +@import "./upload.scss"; +@import "./divider.scss"; +@import "./image.scss"; +@import "./infinite-scroll.scss"; +@import "./avatar.scss"; +@import "./drawer.scss"; +@import "./button-group-enhance.scss"; diff --git a/examples/demo-styles/infinite-scroll.scss b/examples/demo-styles/infinite-scroll.scss new file mode 100644 index 00000000000..a63f9eb5cd0 --- /dev/null +++ b/examples/demo-styles/infinite-scroll.scss @@ -0,0 +1,46 @@ +.infinite-list { + height: 300px; + padding: 0; + margin: 0; + list-style: none; + + .infinite-list-item { + display: flex; + align-items: center; + justify-content: center; + height: 50px; + background: #e8f3fe; + margin: 10px; + color: lighten(#1989fa, 20%); + & + .list-item { + margin-top: 10px + } + } +} + +.infinite-list-wrapper { + height: 300px; + text-align: center; + + .list{ + padding: 0; + margin: 0; + list-style: none; + } + + + .list-item{ + display: flex; + align-items: center; + justify-content: center; + height: 50px; + background: #fff6f6; + color: #ff8484; + & + .list-item { + margin-top: 10px + } + } +} + + + diff --git a/examples/demo-styles/input-number.scss b/examples/demo-styles/input-number.scss new file mode 100644 index 00000000000..b85cff7081f --- /dev/null +++ b/examples/demo-styles/input-number.scss @@ -0,0 +1,5 @@ +.demo-block.demo-input-number { + .el-input-number + .el-input-number { + margin-left: 10px; + } +} diff --git a/examples/demo-styles/input.scss b/examples/demo-styles/input.scss new file mode 100644 index 00000000000..88b51b942f5 --- /dev/null +++ b/examples/demo-styles/input.scss @@ -0,0 +1,65 @@ +.demo-input { + .el-select .el-input { + width: 130px; + } + .el-input { + width: 180px; + } + .el-textarea { + width: 414px; + } + .el-input-group { + width: 100%; + } + .demo-input-size { + .el-input { + vertical-align: top; + margin: 0 10px 10px 0; + } + } + .input-with-select .el-input-group__prepend { + background-color: #fff; + } + .demo-autocomplete { + text-align: center; + + .sub-title { + margin-bottom: 10px; + font-size: 14px; + color: #8492a6; + } + + .el-col:not(:last-child) { + border-right: 1px solid rgba(224, 230, 237, 0.5); + } + + .el-autocomplete { + text-align: left; + } + } +} +.el-autocomplete-suggestion.my-autocomplete { + li { + line-height: normal; + padding-top: 7px; + padding-bottom: 7px; + + .name { + text-overflow: ellipsis; + overflow: hidden; + } + .addr { + font-size: 12px; + color: #b4b4b4; + } + .highlighted .addr { + color: #ddd; + } + } +} +.demo-input-suffix { + margin-bottom: 15px; + .el-input { + margin-right: 15px; + } +} diff --git a/examples/demo-styles/layout.scss b/examples/demo-styles/layout.scss new file mode 100644 index 00000000000..df639344fc7 --- /dev/null +++ b/examples/demo-styles/layout.scss @@ -0,0 +1,28 @@ +.demo-layout { + .el-row { + margin-bottom: 20px; + &:last-child { + margin-bottom: 0; + } + } + .el-col { + border-radius: 4px; + } + .bg-purple-dark { + background: #99a9bf; + } + .bg-purple { + background: #d3dce6; + } + .bg-purple-light { + background: #e5e9f2; + } + .grid-content { + border-radius: 4px; + min-height: 36px; + } + .row-bg { + padding: 10px 0; + background-color: #f9fafc; + } +} diff --git a/examples/demo-styles/loading.scss b/examples/demo-styles/loading.scss new file mode 100644 index 00000000000..0fd6e26dc3a --- /dev/null +++ b/examples/demo-styles/loading.scss @@ -0,0 +1,3 @@ +.demo-loading .el-table { + border: none; +} diff --git a/examples/demo-styles/menu.scss b/examples/demo-styles/menu.scss new file mode 100644 index 00000000000..3b350216f86 --- /dev/null +++ b/examples/demo-styles/menu.scss @@ -0,0 +1,27 @@ +.demo-block.demo-menu { + .el-menu-demo { + padding-left: 55px; + } + .el-menu-vertical-demo:not(.el-menu--collapse) { + width: 240px; + min-height: 400px; + } + .line { + height: 1px; + background-color: #e0e6ed; + margin: 35px -24px; + } + h5 { + font-size: 14px; + color: #8492a6; + margin-top: 10px; + } + .tac { + text-align: center; + + .el-menu-vertical-demo { + display: inline-block; + text-align: left; + } + } +} diff --git a/examples/demo-styles/pagination.scss b/examples/demo-styles/pagination.scss new file mode 100644 index 00000000000..09f751d66fc --- /dev/null +++ b/examples/demo-styles/pagination.scss @@ -0,0 +1,46 @@ +.demo-pagination .source.first { + padding: 0; +} + +.demo-pagination .first .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + display: inline-block; + width: 50%; + box-sizing: border-box; + + &:last-child { + border-right: none; + } +} + +.demo-pagination .first .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} + +.demo-pagination .source.last { + padding: 0; +} + +.demo-pagination .last .block { + padding: 30px 24px; + border-bottom: solid 1px #eff2f6; + &:last-child { + border-bottom: none; + } +} + +.demo-pagination .last .demonstration { + font-size: 14px; + color: #8492a6; + line-height: 44px; +} + +.demo-pagination .last .demonstration + .el-pagination { + width: 70%; + margin: 5px 20px 0 0; +} diff --git a/examples/demo-styles/popover.scss b/examples/demo-styles/popover.scss new file mode 100644 index 00000000000..ee18df753ef --- /dev/null +++ b/examples/demo-styles/popover.scss @@ -0,0 +1,11 @@ +.demo-block.demo-popover { + .el-popover + .el-popover { + margin-left: 10px; + } + .el-input { + width: 360px; + } + .el-button { + margin-left: 10px; + } +} diff --git a/examples/demo-styles/progress.scss b/examples/demo-styles/progress.scss new file mode 100644 index 00000000000..216c8d8aef1 --- /dev/null +++ b/examples/demo-styles/progress.scss @@ -0,0 +1,9 @@ +.demo-block.demo-progress { + .el-progress--line { + margin-bottom: 15px; + width: 350px; + } + .el-progress--circle { + margin-right: 15px; + } +} diff --git a/examples/demo-styles/rate.scss b/examples/demo-styles/rate.scss new file mode 100644 index 00000000000..b82b355200e --- /dev/null +++ b/examples/demo-styles/rate.scss @@ -0,0 +1,18 @@ +.demo-rate .block { + padding: 30px 0; + text-align: center; + border-right: solid 1px #eff2f6; + display: inline-block; + width: 49%; + box-sizing: border-box; + &:last-child { + border-right: none; + } +} + +.demo-rate .demonstration { + display: block; + color: #8492a6; + font-size: 14px; + margin-bottom: 20px; +} diff --git a/examples/demo-styles/select.scss b/examples/demo-styles/select.scss new file mode 100644 index 00000000000..3d3c8e97fb8 --- /dev/null +++ b/examples/demo-styles/select.scss @@ -0,0 +1,3 @@ +.demo-select .el-select { + width: 240px; +} diff --git a/examples/demo-styles/slider.scss b/examples/demo-styles/slider.scss new file mode 100644 index 00000000000..1b600a2c79d --- /dev/null +++ b/examples/demo-styles/slider.scss @@ -0,0 +1,24 @@ +.demo-block.demo-slider .source { + padding: 0; +} + +.demo-block.demo-slider .block { + padding: 30px 24px; + overflow: hidden; + border-bottom: solid 1px #eff2f6; + &:last-child { + border-bottom: none; + } +} + +.demo-block.demo-slider .demonstration { + font-size: 14px; + color: #8492a6; + line-height: 44px; +} + +.demo-block.demo-slider .demonstration + .el-slider { + float: right; + width: 70%; + margin-right: 20px; +} diff --git a/examples/demo-styles/switch.scss b/examples/demo-styles/switch.scss new file mode 100644 index 00000000000..d62bb64587b --- /dev/null +++ b/examples/demo-styles/switch.scss @@ -0,0 +1,5 @@ +.demo-block.demo-switch { + .el-switch { + margin: 20px 20px 20px 0; + } +} diff --git a/examples/demo-styles/table.scss b/examples/demo-styles/table.scss new file mode 100644 index 00000000000..ccd16e6e6fe --- /dev/null +++ b/examples/demo-styles/table.scss @@ -0,0 +1,23 @@ +.el-table .warning-row { + background: oldlace; +} + +.el-table .success-row { + background: #f0f9eb; +} + +.demo-table .name-wrapper { + display: inline-block; +} + +.demo-table .demo-table-expand { + label { + width: 90px; + color: #99a9bf; + } + .el-form-item { + margin-right: 0; + margin-bottom: 0; + width: 50%; + } +} diff --git a/examples/demo-styles/tag.scss b/examples/demo-styles/tag.scss new file mode 100644 index 00000000000..967d05bddff --- /dev/null +++ b/examples/demo-styles/tag.scss @@ -0,0 +1,34 @@ +.demo-block.demo-tag { + .el-tag + .el-tag { + margin-left: 10px; + } + + .button-new-tag { + margin-left: 10px; + height: 32px; + line-height: 30px; + padding-top: 0; + padding-bottom: 0; + } + + .input-new-tag { + width: 90px; + margin-left: 10px; + vertical-align: bottom; + } + + .tag-group { + display: flex; + align-items: center; + + &__title { + width: 45px; + font-size: 14px; + color: #606266; + } + + &+.tag-group { + margin-top: 10px; + } + } +} diff --git a/examples/demo-styles/time-picker.scss b/examples/demo-styles/time-picker.scss new file mode 100644 index 00000000000..f3c19a6acc7 --- /dev/null +++ b/examples/demo-styles/time-picker.scss @@ -0,0 +1,5 @@ +.demo-block { + .el-date-editor + .el-date-editor { + margin-left: 10px; + } +} diff --git a/examples/demo-styles/timeline.scss b/examples/demo-styles/timeline.scss new file mode 100644 index 00000000000..0a50028f023 --- /dev/null +++ b/examples/demo-styles/timeline.scss @@ -0,0 +1,6 @@ +.demo-timeline .source .radio { + margin-bottom: 20px; +} +.demo-timeline .source .radio .el-radio-group { + margin-left: 20px; +} diff --git a/examples/demo-styles/tooltip.scss b/examples/demo-styles/tooltip.scss new file mode 100644 index 00000000000..74e3e238b79 --- /dev/null +++ b/examples/demo-styles/tooltip.scss @@ -0,0 +1,39 @@ +.demo-tooltip { + .el-tooltip + .el-tooltip { + margin-left: 15px; + } + .box { + width: 400px; + + .top { + text-align: center; + } + + .left { + float: left; + width: 60px; + } + + .right { + float: right; + width: 60px; + } + + .bottom { + clear: both; + text-align: center; + } + + .item { + margin: 4px; + } + + .left .el-tooltip__popper, + .right .el-tooltip__popper { + padding: 8px 10px; + } + .el-tooltip { + margin-left: 0; + } + } +} diff --git a/examples/demo-styles/transfer.scss b/examples/demo-styles/transfer.scss new file mode 100644 index 00000000000..a5b49433ff0 --- /dev/null +++ b/examples/demo-styles/transfer.scss @@ -0,0 +1,6 @@ +.demo-transfer { + .transfer-footer { + margin-left: 15px; + padding: 6px 5px; + } +} diff --git a/examples/demo-styles/transition.scss b/examples/demo-styles/transition.scss new file mode 100644 index 00000000000..c889e2ab6c0 --- /dev/null +++ b/examples/demo-styles/transition.scss @@ -0,0 +1,14 @@ +.demo-transition { + .transition-box { + margin-bottom: 10px; + width: 200px; + height: 100px; + border-radius: 4px; + background-color: #2460e0; + text-align: center; + color: #fff; + padding: 40px 20px; + margin-right: 20px; + box-sizing: border-box; + } +} diff --git a/examples/demo-styles/tree.scss b/examples/demo-styles/tree.scss new file mode 100644 index 00000000000..286b0f3bdd3 --- /dev/null +++ b/examples/demo-styles/tree.scss @@ -0,0 +1,48 @@ +.demo-tree { + .leaf { + width: 20px; + background: #ddd; + } + + .folder { + width: 20px; + background: #888; + } + + .buttons { + margin-top: 20px; + } + + .filter-tree { + margin-top: 20px; + } + + .custom-tree-container { + display: flex; + margin: -24px; + } + + .block { + flex: 1; + padding: 8px 24px 24px; + + &:first-child { + border-right: solid 1px #eff2f6; + } + + > p { + text-align: center; + margin: 0; + line-height: 4; + } + } + + .custom-tree-node { + flex: 1; + display: flex; + align-items: center; + justify-content: space-between; + font-size: 14px; + padding-right: 8px; + } +} diff --git a/examples/demo-styles/typography.scss b/examples/demo-styles/typography.scss new file mode 100644 index 00000000000..ff9c0a26149 --- /dev/null +++ b/examples/demo-styles/typography.scss @@ -0,0 +1,30 @@ +.demo-typo-size { + .color-dark-light { + color: #99a9bf; + } +} +.demo-term-box img { + width: 24%; + margin: 0 4% 20px 0; +} + +.lineH-left { + display: inline-block; + height: 80px; +} +.lineH-right { + display: inline-block; + list-style: none; + padding: 0 0 0 90px; + margin: 0; + vertical-align: top; +} +.lineH-right li { + font-size: 13px; + color: #666; + height: 20px; + line-height: 20px; +} +.lineH-right li span { + padding-left: 40px; +} diff --git a/examples/demo-styles/upload.scss b/examples/demo-styles/upload.scss new file mode 100644 index 00000000000..7eb6297c7ea --- /dev/null +++ b/examples/demo-styles/upload.scss @@ -0,0 +1,39 @@ +.upload-tip { + color: #8492a6; + font-size: 12px; + margin-top: 7px; +} +.demo-block { + margin-bottom: 24px; + + .upload-demo { + width: 360px; + } + .avatar-uploader { + .el-upload { + border: 1px dashed #d9d9d9; + border-radius: 6px; + cursor: pointer; + position: relative; + overflow: hidden; + + &:hover, + &:focus { + border-color: #2460e0; + } + } + .avatar-uploader-icon { + font-size: 28px; + color: #8c939d; + width: 178px; + height: 178px; + line-height: 178px; + text-align: center; + } + .avatar { + width: 178px; + height: 178px; + display: block; + } + } +} diff --git a/examples/docs/en-US/affix.md b/examples/docs/en-US/affix.md new file mode 100644 index 00000000000..b0b148f0525 --- /dev/null +++ b/examples/docs/en-US/affix.md @@ -0,0 +1 @@ +## Affix diff --git a/examples/docs/en-US/alert.md b/examples/docs/en-US/alert.md index 5eb3bdbd9eb..3db4f3284c2 100644 --- a/examples/docs/en-US/alert.md +++ b/examples/docs/en-US/alert.md @@ -1,22 +1,3 @@ - - - ## Alert Displays important alert messages. @@ -49,6 +30,37 @@ Alert components are non-overlay elements in the page that does not disappear au ``` ::: +### Theme + +Alert provide two different themes, `light` and `dark`. + +:::demo Set `effect` to change theme, default is `light`. +```html + +``` +::: + ### Customizable close button Customize the close button as texts or other symbols. @@ -209,17 +221,19 @@ Description includes a message with more detailed information. | Attribute | Description | Type | Accepted Values | Default | |---------- |-------------- |---------- |-------------------------------- |-------- | | title | title | string | — | — | -| type | component type | string | success/warning/info/error | info | -| description | descriptive text. Can also be passed with the default slot | string | — | — | -| closable | if closable or not | boolean | — | true | -| center | whether to center the text | boolean | — | false | -| close-text | customized close button text | string | — | — | -| show-icon | if a type icon is displayed | boolean | — | false | +| type | Component type | string | success/warning/info/error | info | +| description | Descriptive text. Can also be passed with the default slot | string | — | — | +| closable | If closable or not | boolean | — | true | +| center | Whether to center the text | boolean | — | false | +| close-text | Customized close button text | string | — | — | +| show-icon | If a type icon is displayed | boolean | — | false | +| effect | Choose theme | string | light/dark | light | ### Slot | Name | Description | |------|--------| +| — | description | | title | content of the Alert title | ### Events diff --git a/examples/docs/en-US/avatar.md b/examples/docs/en-US/avatar.md new file mode 100644 index 00000000000..2923280bb17 --- /dev/null +++ b/examples/docs/en-US/avatar.md @@ -0,0 +1,253 @@ +## Avatar avatar + +Avatars can be used to represent people or objects. It supports images, Icons, or characters. + +### Basic + +use `shape` and `size` prop to set avatar's shape and size + +:::demo + +```html + + +``` + +::: + +### Types + +It supports images, Icons, or characters + +:::demo + +```html + +``` + +::: + +### Tooltip + +If `text` or `tooltip` exist, The tooltips can be displayed when the mouse hovers + +:::demo + +```html + + +``` + +::: + +### Fallback when image load error + +fallback when image load error or src is empty + +customize the display via the default slot, or by using `text` as a placeholder. + +:::demo + +```html + + +``` + +::: + +### Custom Text Formatter + +When using text as a placeholder, the last two characters are displayed by default, and hover displayed the full text. + +You can also customize how to abbreviate it via the `textFormatter` method. + +:::demo + +```html + +``` + +::: + +### How the image fit its container + +Set how the image fit its container for an image avatar, same as [object-fit](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit). + +:::demo + +```html + + +``` + +::: + +### Attributes + +| Attribute | Description | Type | Accepted Values | Default | +| ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------- | ------------------------------------------ | ---------------------- | +| icon | set representation type to Icon, more info on Icon Component | string | | | +| size | set avatar size | number/string | number / large / medium / small | large | +| shape | set avatar shape | string | circle / square | circle | +| src | the address of the image for an image avatar | string | | | +| srcSet | A list of one or more strings separated by commas indicating a set of possible image sources for the user agent to use | string | | | +| alt | This attribute defines an alternative text description of the image | string | | | +| fit | set how the image fit its container for an image avatar | string | fill / contain / cover / none / scale-down | cover | +| text | When images cannot be loaded and no default slot is not used, will take the result of the textFormatter and use it as a text placeholder. will also be used for the default content of the tooltip | string | | | +| fontSize | set text placeholders size | number | | 12 | +| bgColor | set background color | string | | #c0c4cc | +| textFormatter | format `text` to show the abbreviation in the avatar placeholder, last two characters by default | function | | (str) => str.slice(-2) | +| tooltip | set tooltip content, if empty, take `text` as the tooltip content. | string | | | + +### Events + +| Event Name | Description | Parameters | +| ---------- | ------------------------------------------------------------------------------ | ---------- | +| error | handler when img load error, return false to prevent default fallback behavior | (e: Event) | + +### Slot + +| Slot Name | Description | +| --------- | ------------------------ | +| default | customize avatar content | diff --git a/examples/docs/en-US/backtop.md b/examples/docs/en-US/backtop.md new file mode 100644 index 00000000000..faadfe35259 --- /dev/null +++ b/examples/docs/en-US/backtop.md @@ -0,0 +1,60 @@ +## Backtop + +A button to back to top + +### Basic usage + +Scroll down to see the bottom-right button. +:::demo + +```html + +``` + +::: + +### Customizations + +Display area is 40px \* 40px. +:::demo + +```html + +``` + +::: + +### Attributes + +| Attribute | Description | Type | Accepted Values | Default | +| ----------------- | ------------------------------------------------------------------- | --------------- | --------------- | ------- | +| target | the target to trigger scroll | string | | | +| visibility-height | the button will not show until the scroll height reaches this value | number | | 200 | +| right | right distance | number | | 40 | +| bottom | bottom distance | number | | 40 | + +### Events + +| Event Name | Description | Parameters | +| ---------- | ------------------- | ----------- | +| click | triggers when click | click event | diff --git a/examples/docs/en-US/badge.md b/examples/docs/en-US/badge.md index 0636dd0efbd..9f9a687d701 100644 --- a/examples/docs/en-US/badge.md +++ b/examples/docs/en-US/badge.md @@ -114,27 +114,6 @@ Use a red dot to mark content that needs to be noticed. ``` ::: - - ### Attributes | Attribute | Description | Type | Accepted Values | Default | |------------- |---------------- |---------------- |---------------------- |-------- | diff --git a/examples/docs/en-US/border.md b/examples/docs/en-US/border.md new file mode 100644 index 00000000000..540a522b26b --- /dev/null +++ b/examples/docs/en-US/border.md @@ -0,0 +1,135 @@ + + +## Border + +We standardize the borders that can be used in buttons, cards, pop-ups and other components. + +### Border + +There are few border styles to choose. + +
+ + + + + + + + + + + + + + + + + +
NameThicknessDemo
Solid1px +
+
Dashed2px +
+
+ +### Radius + +There are few radius styles to choose. + + + +
No Radius
+
border-radius: 0px
+
+
+ +
Small Radius
+
border-radius: {{borderRadiusSmall}}
+
+
+ +
Large Radius
+
border-radius: {{borderRadiusBase}}
+
+
+ +
Round Radius
+
border-radius: 30px
+
+
+
+ +### Shadow + +There are few shadow styles to choose. + +
+Basic Shadow box-shadow: {{boxShadowBase}} + +
+Light Shadow box-shadow: {{boxShadowLight}} diff --git a/examples/docs/en-US/button-group-enhance.md b/examples/docs/en-US/button-group-enhance.md new file mode 100644 index 00000000000..188c81b7813 --- /dev/null +++ b/examples/docs/en-US/button-group-enhance.md @@ -0,0 +1 @@ +## ButtonGroupEnhance diff --git a/examples/docs/en-US/button.md b/examples/docs/en-US/button.md index 6bad26ba809..9c00fff0eb7 100644 --- a/examples/docs/en-US/button.md +++ b/examples/docs/en-US/button.md @@ -1,27 +1,3 @@ - - ## Button Commonly used button. diff --git a/examples/docs/en-US/calendar.md b/examples/docs/en-US/calendar.md new file mode 100644 index 00000000000..4516c59ee7a --- /dev/null +++ b/examples/docs/en-US/calendar.md @@ -0,0 +1,66 @@ +## Calendar + +Display date. + +### Basic + +:::demo Set `value` to specify the currently displayed month. If `value` is not specified, current month is displayed. `value` supports two-way binding. +```html + + + + +``` +::: + +### Custom Content + +:::demo Customize what is displayed in the calendar cell by setting `scoped-slot` named `dateCell`. In `scoped-slot` you can get the date (the date of the current cell), data (including the type, isSelected, day attribute). For details, please refer to the API documentation below. +```html + + + + + +``` +::: + +### Range + +:::demo Set the `range` attribute to specify the display range of the calendar. Start time must be Monday, end time must be Sunday, and the time span cannot exceed two months. +```html + + +``` +::: + +### Attributes +| Attribute | Description | Type | Accepted Values | Default | +|-----------------|------------------- |---------- |---------------------- |--------- | +| value / v-model | binding value | Date/string/number | — | — | +| range | time range, including start time and end time. Start time must be start day of week, end time must be end day of week, the time span cannot exceed two months. | Array | — | — | +| first-day-of-week | fisrt day of week| Number | 1 to 7 | 1 | + +### dateCell scoped slot 参数 +| Attribute | Description | Type | Accepted Values | Default | +|-----------------|-------------- |---------- |---------------------- |--------- | +| date | date the cell represents | Date | — | — | +| data | { type, isSelected, day}. `type` indicates which month the date belongs, optional values are prev-month, current-month, next-month; `isSelected` indicates whether the date is selected; `day` is the formatted date in the format yyyy-MM-dd | Object | — | — | diff --git a/examples/docs/en-US/card.md b/examples/docs/en-US/card.md index d657fc85e7c..0abfb460066 100644 --- a/examples/docs/en-US/card.md +++ b/examples/docs/en-US/card.md @@ -1,51 +1,3 @@ - - - ## Card Integrate information in a card container. @@ -127,12 +79,12 @@ Display richer content by adding some configs. - +
Yummy hamburger
- Operating button + Operating
diff --git a/examples/docs/en-US/carousel.md b/examples/docs/en-US/carousel.md index 8d391945163..36ed9f98054 100644 --- a/examples/docs/en-US/carousel.md +++ b/examples/docs/en-US/carousel.md @@ -1,64 +1,3 @@ - - ## Carousel Loop a series of images or texts in a limited space @@ -72,7 +11,7 @@ Loop a series of images or texts in a limited space Switch when indicator is hovered (default) -

{{ item }}

+

{{ item }}

@@ -80,7 +19,7 @@ Loop a series of images or texts in a limited space Switch when indicator is clicked -

{{ item }}

+

{{ item }}

@@ -183,7 +122,7 @@ When a page is wide enough but has limited height, you can activate card mode fo @@ -208,6 +147,38 @@ When a page is wide enough but has limited height, you can activate card mode fo ``` ::: +By default, `direction` is `horizontal`. Let carousel be displayed in the vertical direction by setting `direction` to `vertical`. + +:::demo +```html + + + +``` +::: + ### Carousel Attributes | Attribute | Description | Type | Accepted Values | Default | |---------- |-------------- |---------- |-------------------------------- |-------- | @@ -220,6 +191,7 @@ When a page is wide enough but has limited height, you can activate card mode fo | arrow | when arrows are shown | string | always/hover/never | hover | | type | type of the Carousel | string | card | — | | loop | display the items in loop | boolean | - | true | +| direction | display direction | string | horizontal/vertical | horizontal | ### Carousel Events | Event Name | Description | Parameters | diff --git a/examples/docs/en-US/cascader.md b/examples/docs/en-US/cascader.md index b063a1d7dd1..4761aaa8061 100644 --- a/examples/docs/en-US/cascader.md +++ b/examples/docs/en-US/cascader.md @@ -1,18 +1,34 @@ +## Cascader + +If the options have a clear hierarchical structure, Cascader can be used to view and select them. + +### Basic usage + +There are two ways to expand child option items. + +:::demo Assigning the `options` attribute to an array of options renders a Cascader. The `props.expandTrigger` attribute defines how child options are expanded. +```html +
+ Child options expand when clicked (default) + +
+
+ Child options expand when hovered + +
+ +``` +::: - - -## Cascader - -If the options have a clear hierarchical structure, Cascader can be used to view and select them. - -### Basic usage +### Disabled option -There are two ways to expand child option items. +Disable an option by setting a `disabled` field in the option object. -:::demo Assigning the `options` attribute to an array of options renders a Cascader. The `expand-trigger` attribute defines how child options are expanded. This example also demonstrates the `change` event, whose parameter is the value of Cascader, an array made up of the values of each selected level. +:::demo In this example, the first item in `options` array has a `disabled: true` field, so it is disabled. By default, Cascader checks the `disabled` field in each option object; if you are using another field name to indicate whether an option is disabled, you can assign it in the `props.disabled` attribute (see the API table below for details). And of course, field name `value`, `label` and `children` can also be customized in the same way. ```html -
- Child options expand when clicked (default) - - -
-
- Child options expand when hovered - - -
+ ``` ::: -### Disabled option +### Clearable -Disable an option by setting a `disabled` field in the option object. +Set `clearable` attribute for `el-cascader` and a clear icon will appear when selected and hovered -:::demo In this example, the first item in `options` array has a `disabled: true` field, so it is disabled. By default, Cascader checks the `disabled` field in each option object; if you are using another field name to indicate whether an option is disabled, you can assign it in the `props` attribute (see the API table below for details). And of course, field name `value`, `label` and `children` can also be customized in the same way. +:::demo ```html - + + ``` ::: @@ -741,10 +671,7 @@ The input can display only the last level instead of all levels. :::demo The `show-all-levels` attribute defines if all levels are displayed. If it is `false`, only the last level is displayed. ```html - + +``` +::: + + +### Select any level of options + +In single selection, only the leaf nodes can be checked, and in multiple selection, check parent nodes will lead to leaf nodes be checked eventually. When enable this feature, it can make parent and child nodes unlinked and you can select any level of options. + +:::demo Set `props.checkStrictly = true` to make checked state of a node not affects its parent nodes and child nodes, and then you can select any level of options. +```html +
+ Select any level of options (Single selection) + +
+
+ Select any level of options (Multiple selection) + +
+ +``` +::: + +### Filterable + +Search and select options with a keyword. + +:::demo Adding `filterable` to `el-cascader` enables filtering. Cascader will match nodes whose label or parent's label (according to `show-all-levels`) includes input keyword. Of course, you can customize search logic by `filter-method` which accepts a function, the first parameter is `node`, the second is `keyword`, and need return a boolean value indicating whether it hits. +```html +
+ Filterable (Single selection) + +
+
+ Filterable (Multiple selection) + +
+ ``` ::: -### Filterable +### Cascader panel -Search and select options with a keyword. +`CascaderPanel` is the core component of `Cascader` which has various of features such as single selection, multiple selection, dynamic loading and so on. -:::demo Adding `filterable` to `el-cascader` enables filtering +:::demo Just like `el-cascader`, you can set alternative options by `options`, and enable other features by `props`, see the API form below for details. ```html -
- Only options of the last level can be selected - -
-
- Options of all levels can be selected - -
+ - ## Checkbox A group of options for multiple choices. @@ -173,7 +128,7 @@ The `min` and `max` properties can help you to limit the number of checked items ```html @@ -278,7 +166,7 @@ Picking a date range is supported. export default { data() { return { - pickerOptions2: { + pickerOptions: { shortcuts: [{ text: 'Last week', onClick(picker) { @@ -305,8 +193,8 @@ Picking a date range is supported. } }] }, - value6: '', - value7: '' + value1: '', + value2: '' }; } }; @@ -315,6 +203,74 @@ Picking a date range is supported. ::: +### Month Range + +Picking a month range is supported. + +:::demo When in range mode, the left and right panels are linked by default. If you want the two panels to switch current years independently, you can use the `unlink-panels` attribute. +```html + + + +``` +::: + ### Default Value If user hasn't picked a date, shows today's calendar by default. You can use `default-value` to set another date. Its value should be parsable by `new Date()`. @@ -327,7 +283,7 @@ If type is `daterange`, `default-value` sets the left side calendar.
date @@ -336,7 +292,7 @@ If type is `daterange`, `default-value` sets the left side calendar.
daterange
Emits Date object -
Value: {{ value10 }}
+
Value: {{ value1 }}
@@ -404,9 +363,9 @@ Pay attention to capitalization
Use value-format -
Value: {{ value11 }}
+
Value: {{ value2 }}
Timestamp -
Value:{{ value12 }}
+
Value:{{ value3 }}
-

Component value:{{ value13 }}

+

Component value:{{ value }}

- module.exports = { - data() { - return { - pickerOptions1: { - shortcuts: [{ - text: 'Today', - onClick(picker) { - picker.$emit('pick', new Date()); - } - }, { - text: 'Yesterday', - onClick(picker) { - const date = new Date(); - date.setTime(date.getTime() - 3600 * 1000 * 24); - picker.$emit('pick', date); - } - }, { - text: 'A week ago', - onClick(picker) { - const date = new Date(); - date.setTime(date.getTime() - 3600 * 1000 * 24 * 7); - picker.$emit('pick', date); - } - }] - }, - pickerOptions2: { - shortcuts: [{ - text: 'Last week', - onClick(picker) { - const end = new Date(); - const start = new Date(); - start.setTime(start.getTime() - 3600 * 1000 * 24 * 7); - picker.$emit('pick', [start, end]); - } - }, { - text: 'Last month', - onClick(picker) { - const end = new Date(); - const start = new Date(); - start.setTime(start.getTime() - 3600 * 1000 * 24 * 30); - picker.$emit('pick', [start, end]); - } - }, { - text: 'Last 3 months', - onClick(picker) { - const end = new Date(); - const start = new Date(); - start.setTime(start.getTime() - 3600 * 1000 * 24 * 90); - picker.$emit('pick', [start, end]); - } - }] - }, - value1: '', - value2: '', - value3: '', - value4: [new Date(2000, 10, 10, 10, 10), new Date(2000, 10, 11, 10, 10)], - value5: '', - value6: '', - value7: '' - }; - } - }; - - - - ## DateTimePicker Select date and time in one picker. @@ -115,7 +26,7 @@ DateTimePicker is derived from DatePicker and TimePicker. For a more detailed ex v-model="value2" type="datetime" placeholder="Select date and time" - :picker-options="pickerOptions1"> + :picker-options="pickerOptions">
@@ -133,7 +44,7 @@ DateTimePicker is derived from DatePicker and TimePicker. For a more detailed ex export default { data() { return { - pickerOptions1: { + pickerOptions: { shortcuts: [{ text: 'Today', onClick(picker) { @@ -174,7 +85,7 @@ DateTimePicker is derived from DatePicker and TimePicker. For a more detailed ex
Default With shortcuts Start date time 12:00:00 Start date time 12:00:00, end date time 08:00:00 - module.exports = { - data() { - return { - gridData: [{ - date: '2016-05-02', - name: 'John Smith', - address: 'No.1518, Jinshajiang Road, Putuo District' - }, { - date: '2016-05-04', - name: 'John Smith', - address: 'No.1518, Jinshajiang Road, Putuo District' - }, { - date: '2016-05-01', - name: 'John Smith', - address: 'No.1518, Jinshajiang Road, Putuo District' - }, { - date: '2016-05-03', - name: 'John Smith', - address: 'No.1518, Jinshajiang Road, Putuo District' - }], - dialogVisible: false, - dialogTableVisible: false, - dialogFormVisible: false, - outerVisible: false, - innerVisible: false, - centerDialogVisible: false, - form: { - name: '', - region: '', - date1: '', - date2: '', - delivery: false, - type: [], - resource: '', - desc: '' - }, - formLabelWidth: '120px' - }; - }, - methods: { - handleClose(done) { - this.$confirm('Are you sure to close this dialog?') - .then(_ => { - done(); - }) - .catch(_ => {}); - } - } - }; - - - - ## Dialog Informs users while preserving the current page state. @@ -296,6 +221,7 @@ If the variable bound to `visible` is managed in Vuex store, the `.sync` can not | show-close | whether to show a close button | boolean | — | true | | before-close | callback before Dialog closes, and it will prevent Dialog from closing | function(done),done is used to close the Dialog | — | — | | center | whether to align the header and footer in center | boolean | — | false | +| destroy-on-close | Destroy elements in Dialog when closed | boolean | — | false | ### Slot diff --git a/examples/docs/en-US/divider.md b/examples/docs/en-US/divider.md new file mode 100644 index 00000000000..d419c9bd95d --- /dev/null +++ b/examples/docs/en-US/divider.md @@ -0,0 +1,61 @@ +## Divider + +The dividing line that separates the content. + +### Basic usage + +Divide the text of different paragraphs. + +:::demo +```html + +``` +::: + +### Custom content + +You can customize the content on the divider line. + + +:::demo +```html + +``` +::: + +### Vertical divider + +:::demo +```html + +``` +::: + +### Divider Attributes +| Attribute | Description | Type | Accepted Values | Default | +|------------- |---------------- |---------------- |---------------------- |-------- | +| direction | Set divider's direction | string | horizontal / vertical | horizontal | +| content-position | customize the content on the divider line | String | left / right / center | center | \ No newline at end of file diff --git a/examples/docs/en-US/drawer.md b/examples/docs/en-US/drawer.md new file mode 100644 index 00000000000..7e99cdd7807 --- /dev/null +++ b/examples/docs/en-US/drawer.md @@ -0,0 +1,305 @@ +## Drawer + +Sometimes, `Dialog` does not always satisfy our requirements, let's say you have a massive form, or you need space to display something like `terms & conditions`, `Drawer` has almost identical API with `Dialog`, but it introduces different user experience. + +### Basic Usage + +Callout a temporary drawer, from multiple direction + +:::demo You must set `visible` for `Drawer` like `Dialog` does to control the visibility of `Drawer` itself, it's `boolean` type. `Drawer` has to parts: `title` & `body`, the `title` is a named slot, you can also set the title through attribute named `title`, default to an empty string, the `body` part is the main area of `Drawer`, which contains user defined content. When opening, `Drawer` expand itself from the **right corner to left** which size is **30%** of the browser window by default. You can change that default behavior by setting `direction` and `size` attribute. This show case also demonstrated how to use the `before-close` API, check the Attribute section for more detail + +```html + + left to right + right to left + top to bottom + bottom to top + + + + open + + + + Hi, there! + + + +``` +::: + +### No Title + +When you no longer need a title, you can remove title from drawer. + +:::demo Set the `withHeader` attribute to **false**, you can remove the title from drawer, thus your drawer can have more space on screen. If you want to be accessible, make sure to set the `title` attribute. + +```html + + open + + + + Hi there! + + + +``` +::: + +### Customization Content + +Like `Dialog`, `Drawer` can do many diverse interaction as you wanted. + +:::demo + +```html +Open Drawer with nested table +Open Drawer with nested form + + + + + + + + + +
+ + + + + + + + + + + + +
+
+ + +``` +::: + +### Nested Drawer + +You can also have multiple layer of `Drawer` just like `Dialog`. +:::demo If you need multiple Drawer in different layer, you must set the `append-to-body` attribute to **true** + +```html + + + open + + + +
+ Click me! + +

_(:зゝ∠)_

+
+
+
+ + + +``` +::: + +:::tip + +The content inside Drawer should be lazy rendered, which means that the content inside Drawer will not impact the initial render performance, therefore any DOM operation should be performed through `ref` or after `open` event emitted. + +::: + +:::tip + +Drawer provides an API called `destroyOnClose`, which is a flag variable that indicates should destroy the children content inside Drawer after Drawer was closed. You can use this API when you need your `mounted` life cycle to be called every time the Drawer opens. + +::: + +:::tip + +If the variable bound to `visible` is managed in Vuex store, the `.sync` can not work properly. In this case, please remove the `.sync` modifier, listen to `open` and `close` events of Dialog, and commit Vuex mutations to update the value of that variable in the event handlers. + +::: + +### Drawer Attributes + +| Parameter| Description | Type | Acceptable Values | Defaults | +|---------- |-------------- |---------- |-------------------------------- |-------- | +| append-to-body | Controls should Drawer be inserted to DocumentBody Element, nested Drawer must assign this param to **true**| boolean | — | false | +| before-close | If set, closing procedure will be halted | function(done), done is function type that accepts a boolean as parameter, calling done with true or without parameter will abort the close procedure | — | — | +| close-on-press-escape | Indicates whether Drawer can be closed by pressing ESC | boolean | — | true | +| custom-class | Extra class names for Drawer | string | — | — | +| destroy-on-close | Indicates whether children should be destroyed after Drawer closed | boolean | - | false | +| modal | Should show shadowing layer | boolean | — | true | +| modal-append-to-body | Indicates should shadowing layer be insert into DocumentBody element | boolean | — | true | +| direction | Drawer's opening direction | Direction | rtl / ltr / ttb / btt | rtl | +| show-close | Should show close button at the top right of Drawer | boolean | — | true | +| size | Drawer's size, if Drawer is horizontal mode, it effects the width property, otherwise it effects the height property, when size is `number` type, it describes the size by unit of pixels; when size is `string` type, it should be used with `x%` notation, other wise it will be interpreted to pixel unit | number / string | - | '30%' | +| title | Drawer's title, can also be set by named slot, detailed descriptions can be found in the slot form | string | — | — | +| visible | Should Drawer be displayed, also support the `.sync` notation | boolean | — | false | +| wrapperClosable | Indicates whether user can close Drawer by clicking the shadowing layer. | boolean | - | true | +| withHeader | Flag that controls the header section's existance, default to true, when withHeader set to false, both `title attribute` and `title slot` won't work | boolean | - | true | + +### Drawer Slot + +| Name | Description | +|------|--------| +| — | Drawer's Content | +| title | Drawer Title Section | + +### Drawer Methods + +| Name | Description | +| ---- | --- | +| closeDrawer | In order to close Drawer, this method will call `before-close`. | + +### Drawer Events + +| Event Name | Description | Parameter | +|---------- |-------- |---------- | +| open | Triggered before Drawer opening animation begins | — | +| opened | Triggered after Drawer opening animation ended | — | +| close | Triggered before Drawer closing animation begins | — | +| closed | Triggered after Drawer closing animation ended | — | diff --git a/examples/docs/en-US/dropdown.md b/examples/docs/en-US/dropdown.md index 9b66fa02583..abae2634b1d 100644 --- a/examples/docs/en-US/dropdown.md +++ b/examples/docs/en-US/dropdown.md @@ -1,55 +1,3 @@ - - - ## Dropdown Toggleable menu for displaying lists of links and actions. @@ -75,7 +23,7 @@ Hover on the dropdown menu to unfold it for more actions. - ## Form Form consists of `input`, `radio`, `select`, `checkbox` and so on. With form, you can collect, verify and submit data. @@ -272,7 +25,7 @@ It includes all kinds of input items, such as `input`, `select`, `radio` and `ch - - + @@ -441,7 +194,7 @@ Form component allows you to verify your data, helping you find and correct erro - - + @@ -536,19 +289,19 @@ This example shows how to customize your own validation rules to finish a two-fa :::demo Here we use `status-icon` to reflect validation result as an icon. ```html - + - + - + - + - Submit - Reset + Submit + Reset - - + + - - - + + + - - - ## Icon Element provides a set of common icons. @@ -93,7 +20,7 @@ Just assign the class name to `el-icon-iconName`. ### Icons
    -
  • +
  • {{'el-icon-' + name}} diff --git a/examples/docs/en-US/image.md b/examples/docs/en-US/image.md new file mode 100644 index 00000000000..92dc90a8208 --- /dev/null +++ b/examples/docs/en-US/image.md @@ -0,0 +1,163 @@ +## Image +Besides the native features of img, support lazy load, custom placeholder and load failure, etc. + +### Basic Usage + +:::demo Indicate how the image should be resized to fit its container by `fit`, same as native [object-fit](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit)。 +```html +
    +
    + {{ fit }} + +
    +
    + + +``` +::: + +### Placeholder + +:::demo Custom placeholder content when image hasn't loaded yet by `slot = placeholder` +```html +
    +
    + Default + +
    +
    + Custom + +
    + Loading... +
    +
    +
    +
    + + +``` +::: + +### Load Failed + +:::demo Custom failed content when error occurs to image load by `slot = error` +```html +
    +
    + Default + +
    +
    + Custom + +
    + +
    +
    +
    +
    +``` +::: + +### Lazy Load + +:::demo Use lazy load by `lazy = true`. Image will load until scroll into view when set. You can indicate scroll container that adds scroll listener to by `scroll-container`. If undefined, will be the nearest parent container whose overflow property is auto or scroll. +```html +
    + +
    + + +``` +::: + +### Image Preview + +:::demo allow big image preview by setting `previewSrcList` prop. +```html +
    + + +
    + + +``` +::: + +### Attributes +| Attribute | Description | Type | Accepted values | Default | +|---------- |-------- |---------- |------------- |-------- | +| src | Image source, same as native | string | — | - | +| fit | Indicate how the image should be resized to fit its container, same as [object-fit](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit) | string | fill / contain / cover / none / scale-down | - | +| alt | Native alt | string | - | - | +| referrer-policy | Native referrerPolicy | string | - | - | +| lazy | Whether to use lazy load | boolean | — | false | +| scroll-container | The container to add scroll listener when using lazy load | string / HTMLElement | — | The nearest parent container whose overflow property is auto or scroll | +| preview-src-list | allow big image preview | Array | — | - | +| z-index | set image preview z-index | Number | — | 2000 | + +### Events +| Event Name | Description | Parameters | +|---------- |-------- |---------- | +| load | Same as native load | (e: Event) | +| error | Same as native error | (e: Error) | + +### Slots +| Slot Name | Description | +|---------|-------------| +| placeholder | Triggers when image load | +| error | Triggers when image load failed | + + diff --git a/examples/docs/en-US/infiniteScroll.md b/examples/docs/en-US/infiniteScroll.md new file mode 100644 index 00000000000..1e8657c0ba7 --- /dev/null +++ b/examples/docs/en-US/infiniteScroll.md @@ -0,0 +1,87 @@ +## InfiniteScroll + +Load more data while reach bottom of the page + +### Basic usage +Add `v-infinite-scroll` to the list to automatically execute loading method when scrolling to the bottom. +:::demo +```html + + + +``` +::: + +### Disable Loading + +:::demo +```html + + + +``` +::: + + +### Attributes + +| Attribute | Description | Type | Accepted values | Default | +| -------------- | ------------------------------ | --------- | ------------------------------------ | ------- | +| infinite-scroll-disabled | is disabled | boolean | - |false | +| infinite-scroll-delay | throttle delay (ms) | number | - |200 | +| infinite-scroll-distance| trigger distance (px) | number |- |0 | +| infinite-scroll-immediate |Whether to execute the loading method immediately, in case the content cannot be filled up in the initial state. | boolean | - |true | diff --git a/examples/docs/en-US/input-email.md b/examples/docs/en-US/input-email.md new file mode 100644 index 00000000000..b7d6d9f8798 --- /dev/null +++ b/examples/docs/en-US/input-email.md @@ -0,0 +1 @@ +## InputEmail diff --git a/examples/docs/en-US/input-id-card.md b/examples/docs/en-US/input-id-card.md new file mode 100644 index 00000000000..ab7abe5624d --- /dev/null +++ b/examples/docs/en-US/input-id-card.md @@ -0,0 +1 @@ +## InputIdCard diff --git a/examples/docs/en-US/input-number.md b/examples/docs/en-US/input-number.md index bc6d5b0b3d8..369829d1242 100644 --- a/examples/docs/en-US/input-number.md +++ b/examples/docs/en-US/input-number.md @@ -1,34 +1,3 @@ - - - - ## InputNumber Input numerical values with a customizable range. @@ -39,13 +8,13 @@ Input numerical values with a customizable range. ```html +``` +::: + +### Step strictly + +:::demo The `step-strictly` attribute accepts a `boolean`. if this attribute is `true`, input value can only be multiple of step. + +```html + + - - - -## Input +Do not support `v-model` modifiers. +::: -Input data using mouse or keyboard. ### Basic usage @@ -173,7 +37,7 @@ export default { ```html @@ -181,7 +45,7 @@ export default { export default { data() { return { - input1: '' + input: '' } } } @@ -196,7 +60,7 @@ export default { ```html @@ -204,7 +68,7 @@ export default { export default { data() { return { - input10: '' + input: '' } } } @@ -212,6 +76,25 @@ export default { ``` ::: +### Password box + +:::demo Make a toggleable password Input with the `show-password` attribute. + +```html + + + +``` +::: + ### Input with icon Add an icon to indicate input type. @@ -223,24 +106,24 @@ Add an icon to indicate input type. + v-model="input1"> + v-model="input2">
Using slots + v-model="input3"> + v-model="input4">
@@ -256,10 +139,10 @@ Add an icon to indicate input type. export default { data() { return { + input1: '', input2: '', - input21: '', - input22: '', - input23: '' + input3: '', + input4: '' } } } @@ -304,22 +187,22 @@ Setting the `autosize` prop for a textarea type of Input makes the height to aut type="textarea" autosize placeholder="Please input" - v-model="textarea2"> + v-model="textarea1">
+ v-model="textarea2"> +``` +::: + ### Input Attributes | Attribute | Description | Type | Accepted Values | Default | | ----| ----| ----| ---- | ----- | |type| type of input | string | text, textarea and other [native input types](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#Form_%3Cinput%3E_types) | text | -|value| binding value | string / number| — | — | +|value / v-model| binding value | string / number| — | — | |maxlength| same as `maxlength` in native input | number| — | — | |minlength| same as `minlength` in native input | number | — | — | +|show-word-limit | whether show word count,only works when `type` is 'text' or 'textarea' | boolean | — | false | |placeholder| placeholder of Input| string | — | — | | clearable | whether to show clear button | boolean | — | false | +| show-password | whether to show toggleable password input| boolean | — | false | |disabled | whether Input is disabled | boolean | — | false | |size | size of Input, works when `type` is not 'textarea' | string | medium / small / mini | — | | prefix-icon | prefix icon class | string | — | — | @@ -666,7 +587,7 @@ Search data from server-side. |form | same as `form` in native input | string | — | — | | label | label text | string | — | — | | tabindex | input tabindex | string | - | - | -| validate-event | whether to trigger form validation | boolean | - | - | +| validate-event | whether to trigger form validation | boolean | - | true | ### Input slots @@ -683,7 +604,8 @@ Search data from server-side. |----| ----| ----| | blur | triggers when Input blurs | (event: Event) | | focus | triggers when Input focuses | (event: Event) | -| change | triggers when the icon inside Input value change | (value: string \| number) | +| change | triggers only when the input box loses focus or the user presses Enter | (value: string \| number) | +| input | triggers when the Input value change | (value: string \| number) | | clear | triggers when the Input is cleared by clicking the clear button | — | ### Input Methods @@ -716,6 +638,7 @@ Attribute | Description | Type | Options | Default | 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 | +| highlight-first-item | whether to highlight first item in remote search suggestions by default | boolean | — | false | ### Autocomplete Slots diff --git a/examples/docs/en-US/installation.md b/examples/docs/en-US/installation.md index 6bcad9919eb..93d51a34d96 100644 --- a/examples/docs/en-US/installation.md +++ b/examples/docs/en-US/installation.md @@ -10,13 +10,13 @@ npm i element-ui -S ### CDN -Get the latest version from [unpkg.com/element-ui](https://unpkg.com/element-ui/) , and import JavaScript and CSS file in your page. +Get the latest version from [unpkg.com/element-ui](https://unpkg.com/@femessage/element-ui/) , and import JavaScript and CSS file in your page. ```html - + - + ``` :::tip @@ -25,8 +25,11 @@ We recommend our users to lock Element's version when using CDN. Please refer to ### Hello world -If you are using CDN, a hello-world page is easy with Element. [Online Demo](https://jsfiddle.net/hzfpyvg6/14/) +If you are using CDN, a hello-world page is easy with Element. [Online Demo](https://codepen.io/ziyoung/pen/rRKYpd) - + If you are using npm and wish to apply webpack, please continue to the next page: [Quick Start](/#/en-US/component/quickstart). diff --git a/examples/docs/en-US/layout.md b/examples/docs/en-US/layout.md index fa6bf95e84f..daa540ee08b 100644 --- a/examples/docs/en-US/layout.md +++ b/examples/docs/en-US/layout.md @@ -1,34 +1,3 @@ - - ## Layout Quickly and easily create layouts with the basic 24-column. @@ -346,7 +315,7 @@ Taking example by Bootstrap's responsive design, five breakpoints are preset: xs Additionally, Element provides a series of classes for hiding elements under certain conditions. These classes can be added to any DOM elements or custom components. You need to import the following CSS file to use these classes: ```js -import 'element-ui/lib/theme-chalk/display.css'; +import '@femessage/element-ui/lib/theme-chalk/display.css'; ``` The classes are: diff --git a/examples/docs/en-US/link.md b/examples/docs/en-US/link.md new file mode 100644 index 00000000000..66859fa8967 --- /dev/null +++ b/examples/docs/en-US/link.md @@ -0,0 +1,77 @@ +## Link + +Text hyperlink + +### Basic + +Basic text link +:::demo + +```html +
+ default + primary + success + warning + danger + info +
+``` + +::: + +### Disabled + +Disabled state of link +:::demo + +```html +
+ default + primary + success + warning + danger + info +
+``` + +::: + +### Underline + +Underline of link +:::demo + +```html +
+ Without Underline + With Underline +
+``` + +::: + +### Icon + +Link with icon +:::demo + +```html +
+ Edit + Check +
+``` + +::: + +### Attributes + +| Attribute | Description | Type | Options | Default | +| --------- | ----------------------------------- | ------- | ------------------------------------------- | ------- | +| type | type | string | primary / success / warning / danger / info | default | +| underline | whether the component has underline | boolean | — | true | +| disabled | whether the component is disabled | boolean | — | false | +| href | same as native hyperlink's `href` | string | — | - | +| icon | class name of icon | string | — | - | diff --git a/examples/docs/en-US/loading-button.md b/examples/docs/en-US/loading-button.md new file mode 100644 index 00000000000..53b7e055691 --- /dev/null +++ b/examples/docs/en-US/loading-button.md @@ -0,0 +1 @@ +## LoadingButton diff --git a/examples/docs/en-US/loading.md b/examples/docs/en-US/loading.md index c355a7bb32e..af8016b3b7d 100644 --- a/examples/docs/en-US/loading.md +++ b/examples/docs/en-US/loading.md @@ -1,54 +1,3 @@ - - - - ## Loading Show animation while loading data. @@ -121,7 +70,7 @@ You can customize loading text, loading spinner and background color. ```html