parent
f886f04634
commit
471a81beda
|
@ -10,6 +10,16 @@
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
## 1.6.4
|
||||||
|
|
||||||
|
`2020-07-21`
|
||||||
|
|
||||||
|
- 🐞 Fix breadcrumb `Breadcrumb` duplicate key problem [#2505](https://github.com/vueComponent/ant-design-vue/issues/2505)
|
||||||
|
- 🐞 Fix the Tooltip issue when MenuItem title is empty [#2526](https://github.com/vueComponent/ant-design-vue/issues/2505)
|
||||||
|
- 🐞 Fix the problem that Input textarea cannot be dragged up when allow-clear is activated. [#2563](https://github.com/vueComponent/ant-design-vue/issues/2563)
|
||||||
|
- 🌟 Add less variables @select-item-selected-color [#2458](https://github.com/vueComponent/ant-design-vue/issues/2458)
|
||||||
|
- 🌟 Add flex attribute to Col in Grid [#2558](https://github.com/vueComponent/ant-design-vue/issues/2558)
|
||||||
|
|
||||||
## 1.6.3
|
## 1.6.3
|
||||||
|
|
||||||
`2020-07-05`
|
`2020-07-05`
|
||||||
|
|
|
@ -10,6 +10,16 @@
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
## 1.6.4
|
||||||
|
|
||||||
|
`2020-07-21`
|
||||||
|
|
||||||
|
- 🐞 修复面包屑 `Breadcrumb` 重复 key 问题 [#2505](https://github.com/vueComponent/ant-design-vue/issues/2505)
|
||||||
|
- 🐞 修复 MenuItem title 为空时,依然有 Tooltip 问题 [#2526](https://github.com/vueComponent/ant-design-vue/issues/2505)
|
||||||
|
- 🐞 修复 Input textarea 激活 allow-clear 时无法向上拖动的问题。[#2563](https://github.com/vueComponent/ant-design-vue/issues/2563)
|
||||||
|
- 🌟 添加 less 变量 @select-item-selected-color [#2458](https://github.com/vueComponent/ant-design-vue/issues/2458)
|
||||||
|
- 🌟 Grid 中 Col 添加 flex 属性 [#2558](https://github.com/vueComponent/ant-design-vue/issues/2558)
|
||||||
|
|
||||||
## 1.6.3
|
## 1.6.3
|
||||||
|
|
||||||
`2020-07-05`
|
`2020-07-05`
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 2f5ee1b6c38bdf1c54bf6c5fea8142567a45dd67
|
Subproject commit 5ebfa3218ba2fb568f7cb32d2c6fda8eaf5b3c21
|
|
@ -1,12 +1,12 @@
|
||||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||||
|
|
||||||
exports[`ColorPicker prop locale should works 1`] = `
|
exports[`ColorPicker prop locale should works 1`] = `
|
||||||
<div tabindex="0" class="ant-color-picker ant-color-picker-open">
|
<div tabindex="0" class="ant-color-picker">
|
||||||
<div class="ant-color-picker-selection">
|
<div class="ant-color-picker-selection">
|
||||||
<div id="color-picker-box25">
|
<div id="color-picker-box25">
|
||||||
<div class="pickr">
|
<div class="pickr">
|
||||||
|
|
||||||
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog" style="color: rgb(205, 2, 0);"></button>
|
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog"></button>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -14,20 +14,20 @@ exports[`ColorPicker prop locale should works 1`] = `
|
||||||
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
||||||
</svg></i>
|
</svg></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="pcr-app visible" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window">
|
||||||
<div class="pcr-selection">
|
<div class="pcr-selection">
|
||||||
<div class="pcr-color-preview">
|
<div class="pcr-color-preview">
|
||||||
<button type="button" class="pcr-last-color" aria-label="use previous color" style="color: rgb(205, 2, 0);"></button>
|
<button type="button" class="pcr-last-color" aria-label="use previous color"></button>
|
||||||
<div class="pcr-current-color" style="color: rgb(205, 2, 0);"></div>
|
<div class="pcr-current-color"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="pcr-color-palette">
|
<div class="pcr-color-palette">
|
||||||
<div class="pcr-picker" style="background: rgb(205, 2, 0);"></div>
|
<div class="pcr-picker"></div>
|
||||||
<div class="pcr-palette" tabindex="0" aria-label="color selection area" role="listbox"></div>
|
<div class="pcr-palette" tabindex="0" aria-label="color selection area" role="listbox"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="pcr-color-chooser">
|
<div class="pcr-color-chooser">
|
||||||
<div class="pcr-picker" style="background-color: hsl(0.5853658536585238, 100%, 50%);"></div>
|
<div class="pcr-picker"></div>
|
||||||
<div class="pcr-hue pcr-slider" tabindex="0" aria-label="hue selection slider" role="slider"></div>
|
<div class="pcr-hue pcr-slider" tabindex="0" aria-label="hue selection slider" role="slider"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -57,12 +57,12 @@ exports[`ColorPicker prop locale should works 1`] = `
|
||||||
`;
|
`;
|
||||||
|
|
||||||
exports[`ColorPicker save event should works 1`] = `
|
exports[`ColorPicker save event should works 1`] = `
|
||||||
<div tabindex="0" class="ant-color-picker ant-color-picker-open">
|
<div tabindex="0" class="ant-color-picker">
|
||||||
<div class="ant-color-picker-selection">
|
<div class="ant-color-picker-selection">
|
||||||
<div id="color-picker-box31">
|
<div id="color-picker-box31">
|
||||||
<div class="pickr">
|
<div class="pickr">
|
||||||
|
|
||||||
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog" style="color: rgb(205, 2, 0);"></button>
|
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog" style="color: rgb(0, 0, 0);"></button>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -70,20 +70,20 @@ exports[`ColorPicker save event should works 1`] = `
|
||||||
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
||||||
</svg></i>
|
</svg></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
<div class="pcr-app visible" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
||||||
<div class="pcr-selection">
|
<div class="pcr-selection">
|
||||||
<div class="pcr-color-preview">
|
<div class="pcr-color-preview">
|
||||||
<button type="button" class="pcr-last-color" aria-label="use previous color" style="color: rgb(205, 2, 0);"></button>
|
<button type="button" class="pcr-last-color" aria-label="use previous color" style="color: rgb(0, 0, 0);"></button>
|
||||||
<div class="pcr-current-color" style="color: rgb(205, 2, 0);"></div>
|
<div class="pcr-current-color"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="pcr-color-palette">
|
<div class="pcr-color-palette">
|
||||||
<div class="pcr-picker" style="background: rgb(205, 2, 0);"></div>
|
<div class="pcr-picker"></div>
|
||||||
<div class="pcr-palette" tabindex="0" aria-label="color selection area" role="listbox"></div>
|
<div class="pcr-palette" tabindex="0" aria-label="color selection area" role="listbox"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="pcr-color-chooser">
|
<div class="pcr-color-chooser">
|
||||||
<div class="pcr-picker" style="background-color: hsl(0.5853658536585238, 100%, 50%);"></div>
|
<div class="pcr-picker"></div>
|
||||||
<div class="pcr-hue pcr-slider" tabindex="0" aria-label="hue selection slider" role="slider"></div>
|
<div class="pcr-hue pcr-slider" tabindex="0" aria-label="hue selection slider" role="slider"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -113,12 +113,12 @@ exports[`ColorPicker save event should works 1`] = `
|
||||||
`;
|
`;
|
||||||
|
|
||||||
exports[`ColorPicker should support default value 1`] = `
|
exports[`ColorPicker should support default value 1`] = `
|
||||||
<div tabindex="0" class="ant-color-picker ant-color-picker-open">
|
<div tabindex="0" class="ant-color-picker">
|
||||||
<div class="ant-color-picker-selection">
|
<div class="ant-color-picker-selection">
|
||||||
<div id="color-picker-box1">
|
<div id="color-picker-box1">
|
||||||
<div class="pickr">
|
<div class="pickr">
|
||||||
|
|
||||||
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog" style="color: rgb(205, 2, 0);"></button>
|
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog"></button>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -126,20 +126,20 @@ exports[`ColorPicker should support default value 1`] = `
|
||||||
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
||||||
</svg></i>
|
</svg></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="pcr-app visible" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window">
|
||||||
<div class="pcr-selection">
|
<div class="pcr-selection">
|
||||||
<div class="pcr-color-preview">
|
<div class="pcr-color-preview">
|
||||||
<button type="button" class="pcr-last-color" aria-label="use previous color" style="color: rgb(205, 2, 0);"></button>
|
<button type="button" class="pcr-last-color" aria-label="use previous color"></button>
|
||||||
<div class="pcr-current-color" style="color: rgb(205, 2, 0);"></div>
|
<div class="pcr-current-color"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="pcr-color-palette">
|
<div class="pcr-color-palette">
|
||||||
<div class="pcr-picker" style="background: rgb(205, 2, 0);"></div>
|
<div class="pcr-picker"></div>
|
||||||
<div class="pcr-palette" tabindex="0" aria-label="color selection area" role="listbox"></div>
|
<div class="pcr-palette" tabindex="0" aria-label="color selection area" role="listbox"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="pcr-color-chooser">
|
<div class="pcr-color-chooser">
|
||||||
<div class="pcr-picker" style="background-color: hsl(0.5853658536585238, 100%, 50%);"></div>
|
<div class="pcr-picker"></div>
|
||||||
<div class="pcr-hue pcr-slider" tabindex="0" aria-label="hue selection slider" role="slider"></div>
|
<div class="pcr-hue pcr-slider" tabindex="0" aria-label="hue selection slider" role="slider"></div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -174,7 +174,7 @@ exports[`ColorPicker should support disabled 1`] = `
|
||||||
<div id="color-picker-box13">
|
<div id="color-picker-box13">
|
||||||
<div class="pickr">
|
<div class="pickr">
|
||||||
|
|
||||||
<button type="button" class="pcr-button disabled clear" role="button" aria-label="toggle color picker dialog" style="color: rgba(0, 0, 0, 0.15);"></button>
|
<button type="button" class="pcr-button disabled" role="button" aria-label="toggle color picker dialog"></button>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -182,7 +182,7 @@ exports[`ColorPicker should support disabled 1`] = `
|
||||||
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
||||||
</svg></i>
|
</svg></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window">
|
||||||
<div class="pcr-selection">
|
<div class="pcr-selection">
|
||||||
<div class="pcr-color-preview">
|
<div class="pcr-color-preview">
|
||||||
<button type="button" class="pcr-last-color" aria-label="use previous color"></button>
|
<button type="button" class="pcr-last-color" aria-label="use previous color"></button>
|
||||||
|
@ -225,12 +225,12 @@ exports[`ColorPicker should support disabled 1`] = `
|
||||||
`;
|
`;
|
||||||
|
|
||||||
exports[`ColorPicker should support format 1`] = `
|
exports[`ColorPicker should support format 1`] = `
|
||||||
<div tabindex="0" class="ant-color-picker">
|
<div tabindex="0" class="ant-color-picker ant-color-picker-open">
|
||||||
<div class="ant-color-picker-selection">
|
<div class="ant-color-picker-selection">
|
||||||
<div id="color-picker-box19">
|
<div id="color-picker-box19">
|
||||||
<div class="pickr">
|
<div class="pickr">
|
||||||
|
|
||||||
<button type="button" class="pcr-button clear" role="button" aria-label="toggle color picker dialog" style="color: rgba(0, 0, 0, 0.15);"></button>
|
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog" style="color: rgb(0, 0, 0);"></button>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -238,7 +238,7 @@ exports[`ColorPicker should support format 1`] = `
|
||||||
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
||||||
</svg></i>
|
</svg></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
<div class="pcr-app visible" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
||||||
<div class="pcr-selection">
|
<div class="pcr-selection">
|
||||||
<div class="pcr-color-preview">
|
<div class="pcr-color-preview">
|
||||||
<button type="button" class="pcr-last-color" aria-label="use previous color" style="color: rgb(0, 0, 0);"></button>
|
<button type="button" class="pcr-last-color" aria-label="use previous color" style="color: rgb(0, 0, 0);"></button>
|
||||||
|
@ -286,7 +286,7 @@ exports[`ColorPicker should support v-model 1`] = `
|
||||||
<div id="color-picker-box7">
|
<div id="color-picker-box7">
|
||||||
<div class="pickr">
|
<div class="pickr">
|
||||||
|
|
||||||
<button type="button" class="pcr-button clear" role="button" aria-label="toggle color picker dialog" style="color: rgba(0, 0, 0, 0.15);"></button>
|
<button type="button" class="pcr-button" role="button" aria-label="toggle color picker dialog"></button>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -294,7 +294,7 @@ exports[`ColorPicker should support v-model 1`] = `
|
||||||
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
<path d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"></path>
|
||||||
</svg></i>
|
</svg></i>
|
||||||
</div>
|
</div>
|
||||||
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window" style="left: 512px; top: 384px;">
|
<div class="pcr-app" data-theme="monolith" aria-label="color picker dialog" role="window">
|
||||||
<div class="pcr-selection">
|
<div class="pcr-selection">
|
||||||
<div class="pcr-color-preview">
|
<div class="pcr-color-preview">
|
||||||
<button type="button" class="pcr-last-color" aria-label="use previous color"></button>
|
<button type="button" class="pcr-last-color" aria-label="use previous color"></button>
|
||||||
|
|
|
@ -192,6 +192,32 @@ exports[`renders ./antdv-demo/docs/grid/demo/flex-align.md correctly 1`] = `
|
||||||
</div>
|
</div>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
|
exports[`renders ./antdv-demo/docs/grid/demo/flex-fill.md correctly 1`] = `
|
||||||
|
<div>
|
||||||
|
<div role="separator" class="ant-divider ant-divider-horizontal ant-divider-with-text-left"><span class="ant-divider-inner-text">
|
||||||
|
Percentage columns
|
||||||
|
</span></div>
|
||||||
|
<div class="ant-row-flex">
|
||||||
|
<div class="ant-col" style="flex: 2 2 auto;">2 / 5</div>
|
||||||
|
<div class="ant-col" style="flex: 3 3 auto;">3 / 5</div>
|
||||||
|
</div>
|
||||||
|
<div role="separator" class="ant-divider ant-divider-horizontal ant-divider-with-text-left"><span class="ant-divider-inner-text">
|
||||||
|
Fill rest
|
||||||
|
</span></div>
|
||||||
|
<div class="ant-row-flex">
|
||||||
|
<div class="ant-col" style="flex: 0 0 100px;">100px</div>
|
||||||
|
<div class="ant-col" style="flex-basis: auto;">auto</div>
|
||||||
|
</div>
|
||||||
|
<div role="separator" class="ant-divider ant-divider-horizontal ant-divider-with-text-left"><span class="ant-divider-inner-text">
|
||||||
|
Raw flex style
|
||||||
|
</span></div>
|
||||||
|
<div class="ant-row-flex">
|
||||||
|
<div class="ant-col" style="flex: 1 1 200px;">1 1 200px</div>
|
||||||
|
<div class="ant-col" style="flex: 0 1 300px;">0 1 300px</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
`;
|
||||||
|
|
||||||
exports[`renders ./antdv-demo/docs/grid/demo/flex-order.md correctly 1`] = `
|
exports[`renders ./antdv-demo/docs/grid/demo/flex-order.md correctly 1`] = `
|
||||||
<div>
|
<div>
|
||||||
<div class="ant-row-flex">
|
<div class="ant-row-flex">
|
||||||
|
|
119
examples/App.vue
119
examples/App.vue
|
@ -1,119 +1,24 @@
|
||||||
<template>
|
<template>
|
||||||
<a-config-provider :locale="locale">
|
|
||||||
<div>
|
<div>
|
||||||
<a-radio-group :value="locale" @change="changeLocale">
|
<a-collapse :accordion="true" default-active-key="2" :bordered="false">
|
||||||
<a-radio-button key="en" :value="enUS">
|
<a-collapse-panel key="1" header="This is panel header 1">
|
||||||
English
|
<p>{{ text }}</p>
|
||||||
</a-radio-button>
|
</a-collapse-panel>
|
||||||
<a-radio-button key="cn" :value="zhCN">
|
<a-collapse-panel key="2" header="This is panel header 2" :disabled="false">
|
||||||
中文
|
<p>{{ text }}</p>
|
||||||
</a-radio-button>
|
</a-collapse-panel>
|
||||||
</a-radio-group>
|
<a-collapse-panel key="3" header="This is panel header 3">
|
||||||
<div><h4>v-model: <input v-model="color" type="text"></h4><a-color-picker v-model="color" style="width:130px" @show="changeHandler" /></div>
|
<p>{{ text }}</p>
|
||||||
<div><h4>v-model:{{ color }}</h4><a-color-picker v-model="color" style="width:130px" @show="changeHandler" /></div>
|
</a-collapse-panel>
|
||||||
<div><h4>备选颜色</h4><a-color-picker :config="config1" /></div>
|
</a-collapse>
|
||||||
<div><h4>多种输入格式</h4><a-color-picker :config="config2" :get-popup-container="node=>node.parentNode" /></div>
|
|
||||||
<div>
|
|
||||||
<button @click="config2.components.preview = !config2.components.preview">
|
|
||||||
修改config
|
|
||||||
</button>
|
|
||||||
</div>
|
</div>
|
||||||
<div><h4>多种尺寸</h4><a-color-picker size="large" /></div>
|
|
||||||
<div><a-color-picker size="small" /></div>
|
|
||||||
<div><h4>切换禁用</h4><a-color-picker :disabled="disabled" /></div>
|
|
||||||
<div>
|
|
||||||
<button @click="disabled = !disabled">
|
|
||||||
切换
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
<div><h4>切换格式 [color:{{ color2 }}]</h4><a-color-picker v-model="color2" :locale="zhCN" :format="format" /></div>
|
|
||||||
<div>
|
|
||||||
<button @click="format = 'HEX'">
|
|
||||||
HEX
|
|
||||||
</button>
|
|
||||||
<button @click="format = 'RGBA'">
|
|
||||||
RGBA
|
|
||||||
</button>
|
|
||||||
<button @click="format = 'HSVA'">
|
|
||||||
HSVA
|
|
||||||
</button>
|
|
||||||
<button @click="format = 'HSLA'">
|
|
||||||
HSLA
|
|
||||||
</button>
|
|
||||||
<button @click="format = 'CMYK'">
|
|
||||||
CMYK
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</a-config-provider>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import enUS from 'ant-design-vue/../components/locale/en_US';
|
|
||||||
import zhCN from 'ant-design-vue/../components/locale/zh_CN';
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Demo',
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
color:'#ccc',
|
text: `A dog is a type of domesticated animal. Known for its loyalty and faithfulness, it can be found as a welcome guest in many households across the world.`,
|
||||||
color2:'#ccc',
|
|
||||||
disabled:false,
|
|
||||||
format:'',
|
|
||||||
locale: enUS,
|
|
||||||
enUS,
|
|
||||||
zhCN,
|
|
||||||
config1:{
|
|
||||||
swatches: [
|
|
||||||
'rgba(244, 67, 54, 1)',
|
|
||||||
'rgba(233, 30, 99, 0.95)',
|
|
||||||
'rgba(156, 39, 176, 0.9)',
|
|
||||||
'rgba(103, 58, 183, 0.85)',
|
|
||||||
'rgba(63, 81, 181, 0.8)',
|
|
||||||
'rgba(33, 150, 243, 0.75)',
|
|
||||||
'rgba(3, 169, 244, 0.7)',
|
|
||||||
'rgba(0, 188, 212, 0.7)',
|
|
||||||
'rgba(0, 150, 136, 0.75)',
|
|
||||||
'rgba(76, 175, 80, 0.8)',
|
|
||||||
'rgba(139, 195, 74, 0.85)',
|
|
||||||
'rgba(205, 220, 57, 0.9)',
|
|
||||||
'rgba(255, 235, 59, 0.95)',
|
|
||||||
'rgba(255, 193, 7, 1)',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
config2:{
|
|
||||||
components: {
|
|
||||||
// Main components
|
|
||||||
preview: true,
|
|
||||||
opacity: true,
|
|
||||||
hue: true,
|
|
||||||
interaction: {
|
|
||||||
hex: true,
|
|
||||||
rgba: true,
|
|
||||||
hsla: true,
|
|
||||||
hsva: true,
|
|
||||||
cmyk: true,
|
|
||||||
input: true,
|
|
||||||
clear: true,
|
|
||||||
save: true,
|
|
||||||
},
|
|
||||||
strings: {
|
|
||||||
save: 'Save',
|
|
||||||
clear: 'Clear',
|
|
||||||
cancel: 'Cancel',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
methods:{
|
|
||||||
changeHandler(...arg){
|
|
||||||
arg;
|
|
||||||
// console.log(arg);
|
|
||||||
},
|
|
||||||
changeLocale(e) {
|
|
||||||
const localeValue = e.target.value;
|
|
||||||
this.locale = localeValue;
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "ant-design-vue",
|
"name": "ant-design-vue",
|
||||||
"version": "1.6.3",
|
"version": "1.6.4",
|
||||||
"title": "Ant Design Vue",
|
"title": "Ant Design Vue",
|
||||||
"description": "An enterprise-class UI design language and Vue-based implementation",
|
"description": "An enterprise-class UI design language and Vue-based implementation",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
|
Loading…
Reference in New Issue