diff --git a/one/docs/components/lightbox.md b/one/docs/components/lightbox.md index 8d3b498..f2371dc 100644 --- a/one/docs/components/lightbox.md +++ b/one/docs/components/lightbox.md @@ -64,7 +64,7 @@ ^^^ ^^^before-close -在将触发浮层关闭的操作发生后执行,类型为 `function(type: string): boolean=|Promise`。`type` 为触发关闭的类型,默认情况下可选值为 `'ok'|'cancel'`。返回值可以是一个 `boolean`,也可以是一个 resolve `boolean` 的 `Promise`,用来处理可能需要异步决定浮层关闭状态的情况。返回值或 resolve 值非 `false` 时才会关闭浮层。 +在将触发浮层关闭的操作发生后执行,类型为 `function(): boolean=|Promise`。返回值可以是一个 `boolean`,也可以是一个 resolve `boolean` 的 `Promise`,用来处理可能需要异步决定浮层关闭状态的情况。返回值或 resolve 值非 `false` 时才会关闭浮层。 +++调用示例 ```html @@ -99,7 +99,7 @@ | 名称 | 描述 | | -- | -- | -| ``cancel`` | 灯箱关闭后触发。 | +| ``close`` | 进行触发关闭操作的动作时触发。 | ### 图标 diff --git a/one/docs/components/select.md b/one/docs/components/select.md index 75f9e62..3b3b87a 100644 --- a/one/docs/components/select.md +++ b/one/docs/components/select.md @@ -53,7 +53,7 @@ | ``placeholder`` | `string` | `select.placeholder` | 未选择时的占位文本。 | | ``clearable`` | `boolean` | `false` | 是否可以清除已选内容。 | | ``searchable`` | `boolean` | `false` | 是否允许搜索选项。 | -| ``filter`` | `function` | - | 选项过滤函数,签名为 `function(option: Object): boolean`。`option` 类型与 [`options`](#props-options) 属性中的项相同。返回值表示是否将结果保留在下拉选项列表中。 | +| ``show-select-all`` | `boolean` | `false` | 多选模式下是否显示“全选”选项。 | | ``expanded`` | `boolean=` | `false` | [^expanded] | | ``disabled`` | `boolean=` | `false` | 是否为禁用状态。 | | ``readonly`` | `boolean=` | `false` | 是否为只读状态。 | diff --git a/one/docs/en-US/components/select.md b/one/docs/en-US/components/select.md index a8fa71c..e0eda0b 100644 --- a/one/docs/en-US/components/select.md +++ b/one/docs/en-US/components/select.md @@ -44,12 +44,14 @@ Use the [`multiple`](#props-multiple) prop to enable multiple selections. | ``placeholder`` | `string` | `select.placeholder` | Placeholder text when no option is selected. | | ``clearable`` | `boolean` | `false` | Whether the select is clearable. | | ``searchable`` | `boolean` | `false` | Whether the options are searchable. | -| ``filter`` | `function` | - | Filter function for the options. The type is `function(option: Object): boolean`. The type of `option` is the same as the [`options`](#props-options) prop. The return value denotes whether the option is shown inside the options dropdown. | +| ``show-select-all`` | `boolean` | `false` | Whether to display the “Select All” option in multi-select mode. | | ``expanded`` | `boolean=` | `false` | [^expanded] | | ``disabled`` | `boolean=` | `false` | Whether the select is disabled. | | ``readonly`` | `boolean=` | `false` | Whether the select is read-only. | | ``overlay-class`` | `string | Array | Object=` | - | See the [`overlay-class`](./overlay#props-overlay-class) prop of the [`Overlay`](./overlay) component. | | ``overlay-style`` | `string | Array | Object=` | - | See the [`overlay-style`](./overlay#props-overlay-style) prop of the [`Overlay`](./overlay) component. | +| ``match`` | `(item, keyword, { ancestors }) => boolean | [number, number] | Array<[number, number]>` | - | Custom highlighting logic, case insensitive by default. See [`Autocomplete`](./Autocomplete#customizing-search). | +| ``filter`` | `(item, keyword, { ancestors, offsets }) => boolean` | - | Custom hit logic, case insensitive by default. See [`Autocomplete`](./Autocomplete#customizing-search). | ^^^ui Style variants. diff --git a/package-lock.json b/package-lock.json index e45cf48..76dc62d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -17,7 +17,7 @@ "@stackblitz/sdk": "^1.5.2", "babel-eslint": "^10.1.0", "babel-plugin-lodash": "^3.3.4", - "babel-plugin-veui": "^2.5.4", + "babel-plugin-veui": "^2.5.5", "cheerio": "^1.0.0-rc.10", "dls-graphics": "^1.0.0-alpha.3", "dls-icons-vue": "^0.14.0", @@ -75,10 +75,10 @@ "stylus-loader": "^3.0.2", "unist-util-remove": "^1.0.1", "unist-util-visit": "^1.4.0", - "veui": "^2.5.4", - "veui-loader": "^2.5.4", - "veui-theme-dls": "^2.5.4", - "veui-theme-dls-icons": "^2.5.4", + "veui": "^2.5.5", + "veui-loader": "^2.5.5", + "veui-theme-dls": "^2.5.5", + "veui-theme-dls-icons": "^2.5.5", "vue-awesome": "^4.5.0", "vue-i18n": "^8.16.0", "vue-live": "^1.17.2", @@ -5246,9 +5246,9 @@ } }, "node_modules/babel-plugin-veui": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/babel-plugin-veui/-/babel-plugin-veui-2.5.4.tgz", - "integrity": "sha512-DPku/pDI6KMPUC746OBr5+TqRJV+xP+qc+2rG0rFBTIohX+0bmWi3/Jm9adluzuQbSu6ZVlZo3QR0IgE7QCuRg==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/babel-plugin-veui/-/babel-plugin-veui-2.5.5.tgz", + "integrity": "sha512-fkEJVCLbAKrVgUB+S5ZiwvSrdjj/SxIxlyiz+yByN1lMokyHWrqDFe0HEaEPS8NRMi67puIoq4AAgYCbFWRP4A==", "dev": true, "peerDependencies": { "veui": "*" @@ -8020,9 +8020,9 @@ "dev": true }, "node_modules/dls-icons-data": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/dls-icons-data/-/dls-icons-data-2.4.2.tgz", - "integrity": "sha512-lDA5bJfbABykamS3Uw7FeOvMjyzmDAix4T1+dVF2ZqDKGg4LDJFIt5apDagiJLXxNuqTIhVhDMa7f0AhnmAMnQ==", + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/dls-icons-data/-/dls-icons-data-2.6.0.tgz", + "integrity": "sha512-EO4V+UCW52LB4UP4ml/XfNO3Cew6r7shRNaBTx3MCNMSDSiESLltdEH76ojhYW19Vo6JYhqTj0i4KZN/+Ax4sQ==", "dev": true }, "node_modules/dls-icons-vue": { @@ -20981,9 +20981,9 @@ } }, "node_modules/veui": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui/-/veui-2.5.4.tgz", - "integrity": "sha512-znLtHtbApkCqgp7TXEgr8zifTkk4AhTEusb/MO5wHB/y+2BbwSbiUxY+IzT2S6OB/HR2oneEKHVJWEUOoSJDlw==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui/-/veui-2.5.5.tgz", + "integrity": "sha512-ikWZHvyfdGpyAt2SPuv1hOCTnRxj1NwPA1JP7PLsnTYcjYyw8pxmztCRdVLYYLmbC4ioEkrP/rBDLjer1pg5gw==", "dev": true, "dependencies": { "bytes": "^3.0.0", @@ -21008,9 +21008,9 @@ } }, "node_modules/veui-loader": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui-loader/-/veui-loader-2.5.4.tgz", - "integrity": "sha512-RDKimRY9r4rHVEUCLu8w8UCVGpyCDekbc1fXMrEZcVmnsTikPQA0HKxXWZMdEqCYzdTDgCNsGVLfna7psW1zmA==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui-loader/-/veui-loader-2.5.5.tgz", + "integrity": "sha512-hYqI1ibjn9mlwYXMi4UhC+juseujQeuU4ecBTLyr2LAF3Dd6P1+u55U5KfxcEzU5ru+hATKem6w4ErFW26mDzg==", "dev": true, "dependencies": { "loader-utils": "^2.0.0", @@ -21134,53 +21134,53 @@ } }, "node_modules/veui-theme-dls": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui-theme-dls/-/veui-theme-dls-2.5.4.tgz", - "integrity": "sha512-3erexvNLr/nEUnSrtSxESvbQ3uaJotjitU8F6OHXu91g3BxufN1CFEPNHa8sXFXZ9wnmyI1ub8cr/UBXwBXM6w==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui-theme-dls/-/veui-theme-dls-2.5.5.tgz", + "integrity": "sha512-DMS97paGf54AZAb5Zy+gbedvNBTef4+v4J5oSnf64YWu0kqBESwgKMQ+OeQ8AZkvQBtYwMkCZPIB51JgA2Qa0Q==", "dev": true, "dependencies": { "classlist-polyfill": "^1.2.0", - "dls-icons-vue": "~2.4.2", + "dls-icons-vue": "~2.5.0", "focus-visible": "^4.1.0", "less-plugin-dls": "^5.1.0", "less-plugin-est": "^3.0.0", - "veui-theme-dls-icons": "^2.5.4" + "veui-theme-dls-icons": "^2.5.5" }, "peerDependencies": { - "veui": "2.5.4" + "veui": "2.5.5" } }, "node_modules/veui-theme-dls-icons": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui-theme-dls-icons/-/veui-theme-dls-icons-2.5.4.tgz", - "integrity": "sha512-Uv/niScsg3cQtrfY973wk/wKoOxjDM4HyQXRo02dn6t/yTQ4Xkcai7CEyUtbWgS2tQRnboMBDPU1B6miWJicXw==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui-theme-dls-icons/-/veui-theme-dls-icons-2.5.5.tgz", + "integrity": "sha512-fZXhiFYHPsZiZZ2dHAb53MlwQ0zy6Y69FpznMxLsdRaAQfAhZF5KjDb2kyGuMXMcRDZLGyMwJtQfh7UCMXBpMw==", "dev": true, "dependencies": { - "dls-icons-vue": "~2.4.2" + "dls-icons-vue": "~2.5.0" }, "peerDependencies": { - "veui": "2.5.4" + "veui": "2.5.5" } }, "node_modules/veui-theme-dls-icons/node_modules/dls-icons-vue": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.4.2.tgz", - "integrity": "sha512-O4j1qcSvM4GAHz7eqC0+uOR3Yaa/C2xAiYTQMQBvZ6+aSjPkGLMpLgYqDdcAy5N6esb754j/SEeKH3X+uKFUng==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.5.0.tgz", + "integrity": "sha512-23r8e5XCWgchj3N/XhMItKymvCKQ0gqjShU8/SUrziyNDgs7fghM5ZK0Hgn+ciKW2OKiKJlxU1hK5BrD6KsbAg==", "dev": true, "dependencies": { - "dls-icons-data": "^2.4.2" + "dls-icons-data": "^2.5.0" }, "peerDependencies": { "vue": "2.x" } }, "node_modules/veui-theme-dls/node_modules/dls-icons-vue": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.4.2.tgz", - "integrity": "sha512-O4j1qcSvM4GAHz7eqC0+uOR3Yaa/C2xAiYTQMQBvZ6+aSjPkGLMpLgYqDdcAy5N6esb754j/SEeKH3X+uKFUng==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.5.0.tgz", + "integrity": "sha512-23r8e5XCWgchj3N/XhMItKymvCKQ0gqjShU8/SUrziyNDgs7fghM5ZK0Hgn+ciKW2OKiKJlxU1hK5BrD6KsbAg==", "dev": true, "dependencies": { - "dls-icons-data": "^2.4.2" + "dls-icons-data": "^2.5.0" }, "peerDependencies": { "vue": "2.x" @@ -26943,9 +26943,9 @@ } }, "babel-plugin-veui": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/babel-plugin-veui/-/babel-plugin-veui-2.5.4.tgz", - "integrity": "sha512-DPku/pDI6KMPUC746OBr5+TqRJV+xP+qc+2rG0rFBTIohX+0bmWi3/Jm9adluzuQbSu6ZVlZo3QR0IgE7QCuRg==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/babel-plugin-veui/-/babel-plugin-veui-2.5.5.tgz", + "integrity": "sha512-fkEJVCLbAKrVgUB+S5ZiwvSrdjj/SxIxlyiz+yByN1lMokyHWrqDFe0HEaEPS8NRMi67puIoq4AAgYCbFWRP4A==", "dev": true, "requires": {} }, @@ -29164,9 +29164,9 @@ "dev": true }, "dls-icons-data": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/dls-icons-data/-/dls-icons-data-2.4.2.tgz", - "integrity": "sha512-lDA5bJfbABykamS3Uw7FeOvMjyzmDAix4T1+dVF2ZqDKGg4LDJFIt5apDagiJLXxNuqTIhVhDMa7f0AhnmAMnQ==", + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/dls-icons-data/-/dls-icons-data-2.6.0.tgz", + "integrity": "sha512-EO4V+UCW52LB4UP4ml/XfNO3Cew6r7shRNaBTx3MCNMSDSiESLltdEH76ojhYW19Vo6JYhqTj0i4KZN/+Ax4sQ==", "dev": true }, "dls-icons-vue": { @@ -39559,9 +39559,9 @@ "dev": true }, "veui": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui/-/veui-2.5.4.tgz", - "integrity": "sha512-znLtHtbApkCqgp7TXEgr8zifTkk4AhTEusb/MO5wHB/y+2BbwSbiUxY+IzT2S6OB/HR2oneEKHVJWEUOoSJDlw==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui/-/veui-2.5.5.tgz", + "integrity": "sha512-ikWZHvyfdGpyAt2SPuv1hOCTnRxj1NwPA1JP7PLsnTYcjYyw8pxmztCRdVLYYLmbC4ioEkrP/rBDLjer1pg5gw==", "dev": true, "requires": { "bytes": "^3.0.0", @@ -39585,9 +39585,9 @@ } }, "veui-loader": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui-loader/-/veui-loader-2.5.4.tgz", - "integrity": "sha512-RDKimRY9r4rHVEUCLu8w8UCVGpyCDekbc1fXMrEZcVmnsTikPQA0HKxXWZMdEqCYzdTDgCNsGVLfna7psW1zmA==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui-loader/-/veui-loader-2.5.5.tgz", + "integrity": "sha512-hYqI1ibjn9mlwYXMi4UhC+juseujQeuU4ecBTLyr2LAF3Dd6P1+u55U5KfxcEzU5ru+hATKem6w4ErFW26mDzg==", "dev": true, "requires": { "loader-utils": "^2.0.0", @@ -39677,46 +39677,46 @@ } }, "veui-theme-dls": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui-theme-dls/-/veui-theme-dls-2.5.4.tgz", - "integrity": "sha512-3erexvNLr/nEUnSrtSxESvbQ3uaJotjitU8F6OHXu91g3BxufN1CFEPNHa8sXFXZ9wnmyI1ub8cr/UBXwBXM6w==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui-theme-dls/-/veui-theme-dls-2.5.5.tgz", + "integrity": "sha512-DMS97paGf54AZAb5Zy+gbedvNBTef4+v4J5oSnf64YWu0kqBESwgKMQ+OeQ8AZkvQBtYwMkCZPIB51JgA2Qa0Q==", "dev": true, "requires": { "classlist-polyfill": "^1.2.0", - "dls-icons-vue": "~2.4.2", + "dls-icons-vue": "~2.5.0", "focus-visible": "^4.1.0", "less-plugin-dls": "^5.1.0", "less-plugin-est": "^3.0.0", - "veui-theme-dls-icons": "^2.5.4" + "veui-theme-dls-icons": "^2.5.5" }, "dependencies": { "dls-icons-vue": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.4.2.tgz", - "integrity": "sha512-O4j1qcSvM4GAHz7eqC0+uOR3Yaa/C2xAiYTQMQBvZ6+aSjPkGLMpLgYqDdcAy5N6esb754j/SEeKH3X+uKFUng==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.5.0.tgz", + "integrity": "sha512-23r8e5XCWgchj3N/XhMItKymvCKQ0gqjShU8/SUrziyNDgs7fghM5ZK0Hgn+ciKW2OKiKJlxU1hK5BrD6KsbAg==", "dev": true, "requires": { - "dls-icons-data": "^2.4.2" + "dls-icons-data": "^2.5.0" } } } }, "veui-theme-dls-icons": { - "version": "2.5.4", - "resolved": "https://registry.npmjs.org/veui-theme-dls-icons/-/veui-theme-dls-icons-2.5.4.tgz", - "integrity": "sha512-Uv/niScsg3cQtrfY973wk/wKoOxjDM4HyQXRo02dn6t/yTQ4Xkcai7CEyUtbWgS2tQRnboMBDPU1B6miWJicXw==", + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/veui-theme-dls-icons/-/veui-theme-dls-icons-2.5.5.tgz", + "integrity": "sha512-fZXhiFYHPsZiZZ2dHAb53MlwQ0zy6Y69FpznMxLsdRaAQfAhZF5KjDb2kyGuMXMcRDZLGyMwJtQfh7UCMXBpMw==", "dev": true, "requires": { - "dls-icons-vue": "~2.4.2" + "dls-icons-vue": "~2.5.0" }, "dependencies": { "dls-icons-vue": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.4.2.tgz", - "integrity": "sha512-O4j1qcSvM4GAHz7eqC0+uOR3Yaa/C2xAiYTQMQBvZ6+aSjPkGLMpLgYqDdcAy5N6esb754j/SEeKH3X+uKFUng==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/dls-icons-vue/-/dls-icons-vue-2.5.0.tgz", + "integrity": "sha512-23r8e5XCWgchj3N/XhMItKymvCKQ0gqjShU8/SUrziyNDgs7fghM5ZK0Hgn+ciKW2OKiKJlxU1hK5BrD6KsbAg==", "dev": true, "requires": { - "dls-icons-data": "^2.4.2" + "dls-icons-data": "^2.5.0" } } } diff --git a/package.json b/package.json index d907f8d..1cfffe9 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "@stackblitz/sdk": "^1.5.2", "babel-eslint": "^10.1.0", "babel-plugin-lodash": "^3.3.4", - "babel-plugin-veui": "^2.5.4", + "babel-plugin-veui": "^2.5.5", "cheerio": "^1.0.0-rc.10", "dls-graphics": "^1.0.0-alpha.3", "dls-icons-vue": "^0.14.0", @@ -83,10 +83,10 @@ "stylus-loader": "^3.0.2", "unist-util-remove": "^1.0.1", "unist-util-visit": "^1.4.0", - "veui": "^2.5.4", - "veui-loader": "^2.5.4", - "veui-theme-dls": "^2.5.4", - "veui-theme-dls-icons": "^2.5.4", + "veui": "^2.5.5", + "veui-loader": "^2.5.5", + "veui-theme-dls": "^2.5.5", + "veui-theme-dls-icons": "^2.5.5", "vue-awesome": "^4.5.0", "vue-i18n": "^8.16.0", "vue-live": "^1.17.2",