vue3-smart-table 2.0.1 → 2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/README.md +250 -1454
- package/dist/types/components/SmartTable/config.d.ts +9 -0
- package/dist/types/components/SmartTable/index.vue.d.ts +20 -73
- package/dist/types/components/SmartTable/renderers/index.d.ts +3 -3
- package/dist/types/components/SmartTable/types.d.ts +121 -66
- package/dist/types/types/enhanced.d.ts +2 -2
- package/dist/vue3-smart-table.cjs.js +1 -1
- package/dist/vue3-smart-table.cjs.js.map +1 -1
- package/dist/vue3-smart-table.es.js +557 -465
- package/dist/vue3-smart-table.es.js.map +1 -1
- package/dist/vue3-smart-table.umd.js +2 -2
- package/dist/vue3-smart-table.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/components/SmartTable/config.ts +20 -0
- package/src/components/SmartTable/index.vue +174 -193
- package/src/components/SmartTable/renderers/index.ts +140 -73
- package/src/components/SmartTable/renderers/input.vue +44 -5
- package/src/components/SmartTable/renderers/inputNumber.vue +35 -5
- package/src/components/SmartTable/renderers/select.vue +51 -6
- package/src/components/SmartTable/types.ts +182 -89
- package/src/types/enhanced.ts +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,33 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [2.1.1] - 2025-12-30
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- **操作列宽度计算优化** - 调整 operation 列逻辑代码顺序,确保在 visibleColumns 之前定义
|
|
12
|
+
- **代码结构优化** - 优化 isOperationVisible 函数位置,提升代码可读性
|
|
13
|
+
- **类型引用修复** - 修复 RendererName -> ColumnType 类型引用
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
- 重构代码组织结构,提升可维护性
|
|
17
|
+
|
|
18
|
+
## [2.1.0] - 2025-12-30
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
- **统一 type 字段** - 合并原 `type` 和 `render` 为单一 `type` 字段,更简洁
|
|
22
|
+
- **重命名 renderProps 为 props** - 与 SmartForm 保持一致
|
|
23
|
+
- **列顺序可控** - 所有列类型(selection/index/operation/数据列)按配置顺序渲染
|
|
24
|
+
- **Props 定义优化** - 改用 `defineProps<SmartTableProps>()` + `withDefaults`
|
|
25
|
+
- **Emits 定义优化** - 改用 `defineEmits<SmartTableEmits>()`
|
|
26
|
+
|
|
27
|
+
### Added
|
|
28
|
+
- **props 事件回调** - 可编辑渲染器支持 `props.onChange`、`props.onBlur` 等事件,方便 columns 抽离到独立 ts 文件
|
|
29
|
+
- **属性透传增强** - 所有渲染器支持透传 Element Plus 原生属性和事件
|
|
30
|
+
|
|
31
|
+
### Fixed
|
|
32
|
+
- 修复 el-switch 在页面加载时立即触发 change 事件的问题(el-table 预渲染 slot 导致)
|
|
33
|
+
- 修复 SSR 安全问题,`isInitialized` 改为 `ref()`
|
|
34
|
+
|
|
8
35
|
## [2.0.0] - 2025-12-29
|
|
9
36
|
|
|
10
37
|
### ⚠️ Breaking Changes
|