@varlet/ui 3.17.0 → 3.18.0-alpha.1781190469654
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/README.md +1 -1
- package/README.zh-CN.md +1 -1
- package/es/action-sheet/style/index.mjs +1 -1
- package/es/app-bar/AppBar.mjs +2 -0
- package/es/app-bar/appBar.css +1 -1
- package/es/app-bar/props.mjs +8 -0
- package/es/badge/badge.css +1 -1
- package/es/bottom-navigation-item/BottomNavigationItem.mjs +1 -1
- package/es/bottom-navigation-item/bottomNavigationItem.css +1 -1
- package/es/button/Button.mjs +13 -6
- package/es/button/button.css +1 -1
- package/es/button/props.mjs +2 -0
- package/es/collapse-transition/useCollapseTransition.mjs +27 -8
- package/es/data-table/DataTable.mjs +656 -0
- package/es/data-table/DataTableBodyCell.mjs +210 -0
- package/es/data-table/DataTableHeaderCell.mjs +237 -0
- package/es/data-table/DataTableSfc.css +0 -0
- package/es/data-table/dataTable.css +1 -0
- package/es/data-table/index.mjs +12 -0
- package/es/data-table/props.mjs +94 -0
- package/es/data-table/span.mjs +29 -0
- package/es/data-table/style/index.mjs +17 -0
- package/es/data-table/useBodyRows.mjs +141 -0
- package/es/data-table/useColumnSizes.mjs +175 -0
- package/es/data-table/useColumnsFixedOffsets.mjs +90 -0
- package/es/data-table/useContainerScroll.mjs +35 -0
- package/es/data-table/useExpandRow.mjs +46 -0
- package/es/data-table/useFootRows.mjs +49 -0
- package/es/data-table/useHeaderRows.mjs +113 -0
- package/es/data-table/usePagination.mjs +101 -0
- package/es/data-table/useSelectionColumn.mjs +242 -0
- package/es/data-table/useSorter.mjs +70 -0
- package/es/data-table/useTreeExpand.mjs +69 -0
- package/es/icon/icon.css +1 -1
- package/es/index.bundle.mjs +25 -1
- package/es/index.mjs +21 -1
- package/es/locale/en-US.mjs +3 -1
- package/es/locale/fa-IR.mjs +3 -1
- package/es/locale/ja-JP.mjs +3 -1
- package/es/locale/zh-CN.mjs +3 -1
- package/es/locale/zh-TW.mjs +3 -1
- package/es/menu/Menu.mjs +1 -0
- package/es/menu/menu.css +1 -1
- package/es/menu-select/MenuSelect.mjs +1 -1
- package/es/menu-select/menuSelect.css +1 -1
- package/es/otp-input/OtpInput.mjs +39 -12
- package/es/pagination/pagination.css +1 -1
- package/es/rail-navigation/RailNavigation.mjs +87 -0
- package/es/rail-navigation/RailNavigationSfc.css +0 -0
- package/es/rail-navigation/index.mjs +12 -0
- package/es/rail-navigation/props.mjs +21 -0
- package/es/rail-navigation/provide.mjs +12 -0
- package/es/rail-navigation/railNavigation.css +1 -0
- package/es/rail-navigation/style/index.mjs +3 -0
- package/es/rail-navigation-item/RailNavigationItem.mjs +177 -0
- package/es/rail-navigation-item/RailNavigationItemSfc.css +0 -0
- package/es/rail-navigation-item/index.mjs +12 -0
- package/es/rail-navigation-item/props.mjs +19 -0
- package/es/rail-navigation-item/provide.mjs +17 -0
- package/es/rail-navigation-item/railNavigationItem.css +1 -0
- package/es/rail-navigation-item/style/index.mjs +6 -0
- package/es/select/Select.mjs +1 -1
- package/es/select/select.css +1 -1
- package/es/style.mjs +4 -0
- package/es/styles/common.css +1 -1
- package/es/table/Table.mjs +22 -9
- package/es/table/props.mjs +3 -1
- package/es/table/table.css +1 -1
- package/es/themes/dark/appBar.mjs +3 -0
- package/es/themes/dark/bottomNavigationItem.mjs +1 -0
- package/es/themes/dark/button.mjs +3 -0
- package/es/themes/dark/dataTable.mjs +31 -0
- package/es/themes/dark/index.mjs +6 -2
- package/es/themes/dark/railNavigation.mjs +12 -0
- package/es/themes/dark/railNavigationItem.mjs +18 -0
- package/es/themes/dark/table.mjs +4 -1
- package/es/themes/dark/treeMenu.mjs +32 -0
- package/es/themes/md3-dark/appBar.mjs +3 -0
- package/es/themes/md3-dark/bottomNavigationItem.mjs +1 -0
- package/es/themes/md3-dark/button.mjs +3 -0
- package/es/themes/md3-dark/dataTable.mjs +31 -0
- package/es/themes/md3-dark/index.mjs +6 -2
- package/es/themes/md3-dark/railNavigation.mjs +12 -0
- package/es/themes/md3-dark/railNavigationItem.mjs +18 -0
- package/es/themes/md3-dark/table.mjs +4 -1
- package/es/themes/md3-dark/treeMenu.mjs +32 -0
- package/es/themes/md3-light/appBar.mjs +3 -0
- package/es/themes/md3-light/bottomNavigationItem.mjs +1 -0
- package/es/themes/md3-light/button.mjs +3 -0
- package/es/themes/md3-light/dataTable.mjs +31 -0
- package/es/themes/md3-light/index.mjs +6 -2
- package/es/themes/md3-light/pagination.mjs +1 -1
- package/es/themes/md3-light/railNavigation.mjs +12 -0
- package/es/themes/md3-light/railNavigationItem.mjs +18 -0
- package/es/themes/md3-light/table.mjs +4 -1
- package/es/themes/md3-light/treeMenu.mjs +32 -0
- package/es/tree-menu/TreeMenu.mjs +223 -0
- package/es/tree-menu/TreeMenuOption.mjs +206 -0
- package/es/tree-menu/TreeMenuSfc.css +0 -0
- package/es/tree-menu/index.mjs +12 -0
- package/es/tree-menu/props.mjs +40 -0
- package/es/tree-menu/style/index.mjs +6 -0
- package/es/tree-menu/treeMenu.css +1 -0
- package/es/varlet.css +1 -1
- package/es/varlet.esm.js +10532 -9190
- package/highlight/web-types.en-US.json +414 -1
- package/highlight/web-types.zh-CN.json +148 -1
- package/lib/varlet.cjs.js +10842 -9190
- package/lib/varlet.css +1 -1
- package/package.json +7 -7
- package/types/appBar.d.ts +6 -0
- package/types/button.d.ts +2 -0
- package/types/buttonGroup.d.ts +1 -1
- package/types/dataTable.d.ts +173 -0
- package/types/index.d.ts +8 -0
- package/types/railNavigation.d.ts +27 -0
- package/types/railNavigationItem.d.ts +38 -0
- package/types/styleVars.d.ts +84 -0
- package/types/table.d.ts +2 -0
- package/types/treeMenu.d.ts +80 -0
- package/umd/varlet.js +7 -7
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@varlet/ui",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.18.0-alpha.1781190469654",
|
|
4
4
|
"description": "A Vue3 component library based on Material Design 2 and 3, supporting mobile and desktop.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Vue3",
|
|
@@ -44,9 +44,9 @@
|
|
|
44
44
|
"@popperjs/core": "^2.11.6",
|
|
45
45
|
"dayjs": "^1.10.4",
|
|
46
46
|
"decimal.js": "^10.2.1",
|
|
47
|
-
"@varlet/icons": "3.
|
|
48
|
-
"@varlet/shared": "3.
|
|
49
|
-
"@varlet/use": "3.
|
|
47
|
+
"@varlet/icons": "3.18.0-alpha.1781190469654",
|
|
48
|
+
"@varlet/shared": "3.18.0-alpha.1781190469654",
|
|
49
|
+
"@varlet/use": "3.18.0-alpha.1781190469654"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
52
|
"@types/node": "^20.19.0",
|
|
@@ -62,9 +62,9 @@
|
|
|
62
62
|
"vue": "3.5.21",
|
|
63
63
|
"vue-router": "4.5.1",
|
|
64
64
|
"zod": "^3.23.8",
|
|
65
|
-
"@varlet/cli": "3.
|
|
66
|
-
"@varlet/ui": "3.
|
|
67
|
-
"@varlet/touch-emulator": "3.
|
|
65
|
+
"@varlet/cli": "3.18.0-alpha.1781190469654",
|
|
66
|
+
"@varlet/ui": "3.18.0-alpha.1781190469654",
|
|
67
|
+
"@varlet/touch-emulator": "3.18.0-alpha.1781190469654"
|
|
68
68
|
},
|
|
69
69
|
"peerDependencies": {
|
|
70
70
|
"vue": "^3.2.0"
|
package/types/appBar.d.ts
CHANGED
|
@@ -5,7 +5,13 @@ export declare const appBarProps: Record<keyof AppBarProps, any>
|
|
|
5
5
|
|
|
6
6
|
export type AppBarTitlePosition = 'left' | 'center' | 'right'
|
|
7
7
|
|
|
8
|
+
export type AppBarType = 'primary' | 'surface'
|
|
9
|
+
|
|
10
|
+
export type AppBarSize = 'normal' | 'large'
|
|
11
|
+
|
|
8
12
|
export interface AppBarProps extends BasicAttributes {
|
|
13
|
+
type?: AppBarType
|
|
14
|
+
size?: AppBarSize
|
|
9
15
|
color?: string
|
|
10
16
|
textColor?: string
|
|
11
17
|
title?: string
|
package/types/button.d.ts
CHANGED
|
@@ -19,9 +19,11 @@ export interface ButtonProps extends BasicAttributes {
|
|
|
19
19
|
size?: ButtonSize
|
|
20
20
|
loading?: boolean
|
|
21
21
|
round?: boolean
|
|
22
|
+
fab?: boolean
|
|
22
23
|
block?: boolean
|
|
23
24
|
text?: boolean
|
|
24
25
|
outline?: boolean
|
|
26
|
+
tonal?: boolean
|
|
25
27
|
iconContainer?: boolean
|
|
26
28
|
disabled?: boolean
|
|
27
29
|
ripple?: boolean
|
package/types/buttonGroup.d.ts
CHANGED
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
|
|
10
10
|
export declare const buttonGroupProps: Record<keyof ButtonGroupProps, any>
|
|
11
11
|
|
|
12
|
-
export type ButtonGroupMode = 'normal' | 'text' | 'outline' | 'icon-container'
|
|
12
|
+
export type ButtonGroupMode = 'normal' | 'text' | 'outline' | 'tonal' | 'icon-container'
|
|
13
13
|
|
|
14
14
|
export interface ButtonGroupProps extends BasicAttributes {
|
|
15
15
|
type?: ButtonGroupType
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
import { HTMLAttributes, VNode, VNodeChild } from 'vue'
|
|
2
|
+
import { BasicAttributes, ListenerProp, SetPropsDefaults, VarComponent } from './varComponent'
|
|
3
|
+
|
|
4
|
+
export declare const dataTableProps: Record<keyof DataTableProps, any>
|
|
5
|
+
|
|
6
|
+
export type DataTableColumnAlign = 'left' | 'center' | 'right'
|
|
7
|
+
|
|
8
|
+
export type DataTableColumnFixed = 'left' | 'right'
|
|
9
|
+
|
|
10
|
+
export type DataTableSurface = 'low'
|
|
11
|
+
|
|
12
|
+
export type DataTableTableLayout = 'auto' | 'fixed'
|
|
13
|
+
|
|
14
|
+
export type DataTableSortMode = 'single' | 'multiple'
|
|
15
|
+
|
|
16
|
+
export type DataTableSorterOrder = 'asc' | 'desc'
|
|
17
|
+
|
|
18
|
+
export type DataTableRowKey<Row = any> = string | number | ((context: DataTableRowBaseContext<Row>) => string | number)
|
|
19
|
+
|
|
20
|
+
export interface DataTableRowBaseContext<Row = any> {
|
|
21
|
+
row: Row
|
|
22
|
+
rowIndex: number
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export interface DataTableColumnRenderContext<Row = any> extends DataTableRowBaseContext<Row> {}
|
|
26
|
+
|
|
27
|
+
export interface DataTableRowPropsContext<Row = any> extends DataTableRowBaseContext<Row> {}
|
|
28
|
+
|
|
29
|
+
export interface DataTableColumnCellPropsContext<Row = any> extends DataTableRowBaseContext<Row> {}
|
|
30
|
+
|
|
31
|
+
export interface DataTableSummaryContext<Row = any> {
|
|
32
|
+
data: Row[]
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export type DataTableColumnCellSpan<Row = any> = number | ((context: DataTableRowBaseContext<Row>) => number)
|
|
36
|
+
|
|
37
|
+
export type DataTableColumnSelectable<Row = any> = boolean | ((context: DataTableRowBaseContext<Row>) => boolean)
|
|
38
|
+
|
|
39
|
+
export type DataTableColumnTitle = VNodeChild | (() => VNodeChild)
|
|
40
|
+
|
|
41
|
+
export type DataTableRowProps<Row = any> =
|
|
42
|
+
| HTMLAttributes
|
|
43
|
+
| ((context: DataTableRowPropsContext<Row>) => HTMLAttributes | undefined)
|
|
44
|
+
|
|
45
|
+
export type DataTableRowClass<Row = any> =
|
|
46
|
+
| HTMLAttributes['class']
|
|
47
|
+
| ((context: DataTableRowPropsContext<Row>) => HTMLAttributes['class'])
|
|
48
|
+
|
|
49
|
+
export type DataTableColumnCellProps<Row = any> =
|
|
50
|
+
| HTMLAttributes
|
|
51
|
+
| ((context: DataTableColumnCellPropsContext<Row>) => HTMLAttributes | undefined)
|
|
52
|
+
|
|
53
|
+
export interface DataTableSummaryCell {
|
|
54
|
+
value?: VNodeChild
|
|
55
|
+
colSpan?: number
|
|
56
|
+
rowSpan?: number
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export type DataTableSummary<Row = any> = (
|
|
60
|
+
context: DataTableSummaryContext<Row>,
|
|
61
|
+
) => Record<string, DataTableSummaryCell> | Array<Record<string, DataTableSummaryCell>>
|
|
62
|
+
|
|
63
|
+
export interface DataTableBaseColumn<Row = any> {
|
|
64
|
+
fixed?: DataTableColumnFixed
|
|
65
|
+
resizable?: boolean
|
|
66
|
+
width?: string | number
|
|
67
|
+
minWidth?: string | number
|
|
68
|
+
maxWidth?: string | number
|
|
69
|
+
align?: DataTableColumnAlign
|
|
70
|
+
titleAlign?: DataTableColumnAlign
|
|
71
|
+
titleColSpan?: number
|
|
72
|
+
colSpan?: DataTableColumnCellSpan<Row>
|
|
73
|
+
rowSpan?: DataTableColumnCellSpan<Row>
|
|
74
|
+
cellProps?: DataTableColumnCellProps<Row>
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export interface DataTableSorter {
|
|
78
|
+
key: string
|
|
79
|
+
order: DataTableSorterOrder
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export interface DataTableFieldColumn<Row = any> extends DataTableBaseColumn<Row> {
|
|
83
|
+
type?: undefined
|
|
84
|
+
key: string
|
|
85
|
+
title: DataTableColumnTitle
|
|
86
|
+
children?: DataTableColumn<Row>[]
|
|
87
|
+
sorter?: boolean
|
|
88
|
+
render?: (context: DataTableColumnRenderContext<Row>) => VNodeChild
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export interface DataTableSelectionColumn<Row = any> extends DataTableBaseColumn<Row> {
|
|
92
|
+
type: 'selection'
|
|
93
|
+
key?: string
|
|
94
|
+
title?: DataTableColumnTitle
|
|
95
|
+
multiple?: boolean
|
|
96
|
+
selectable?: DataTableColumnSelectable<Row>
|
|
97
|
+
render?: never
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export interface DataTableExpandColumn<Row = any> extends DataTableBaseColumn<Row> {
|
|
101
|
+
type: 'expand'
|
|
102
|
+
key?: string
|
|
103
|
+
title?: DataTableColumnTitle
|
|
104
|
+
render?: never
|
|
105
|
+
expandable?: (context: DataTableRowPropsContext<Row>) => boolean
|
|
106
|
+
renderExpand: (context: DataTableRowBaseContext<Row>) => VNodeChild
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
export type DataTableColumn<Row = any> =
|
|
110
|
+
| DataTableFieldColumn<Row>
|
|
111
|
+
| DataTableSelectionColumn<Row>
|
|
112
|
+
| DataTableExpandColumn<Row>
|
|
113
|
+
|
|
114
|
+
export interface DataTablePagination {
|
|
115
|
+
simple?: boolean
|
|
116
|
+
disabled?: boolean
|
|
117
|
+
showSizeChanger?: boolean
|
|
118
|
+
showQuickJumper?: boolean
|
|
119
|
+
maxPagerCount?: number
|
|
120
|
+
sizeOption?: number[]
|
|
121
|
+
showTotal?: (total: number, range: [number, number]) => string
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export interface DataTableProps extends BasicAttributes {
|
|
125
|
+
data?: any[]
|
|
126
|
+
columns?: DataTableColumn[]
|
|
127
|
+
rowKey?: DataTableRowKey
|
|
128
|
+
rowProps?: DataTableRowProps
|
|
129
|
+
rowClass?: DataTableRowClass
|
|
130
|
+
summary?: DataTableSummary
|
|
131
|
+
loading?: boolean
|
|
132
|
+
pagination?: boolean | DataTablePagination
|
|
133
|
+
remote?: boolean
|
|
134
|
+
page?: number
|
|
135
|
+
pageSize?: number
|
|
136
|
+
total?: number
|
|
137
|
+
maxHeight?: number | string
|
|
138
|
+
scrollX?: number | string
|
|
139
|
+
sorters?: DataTableSorter[]
|
|
140
|
+
sortMode?: DataTableSortMode
|
|
141
|
+
tree?: boolean
|
|
142
|
+
surface?: DataTableSurface
|
|
143
|
+
cascade?: boolean
|
|
144
|
+
childrenKey?: string
|
|
145
|
+
plain?: boolean
|
|
146
|
+
elevation?: boolean | string | number
|
|
147
|
+
cellBordered?: boolean
|
|
148
|
+
tableLayout?: DataTableTableLayout
|
|
149
|
+
size?: 'small' | 'normal' | 'large'
|
|
150
|
+
checkedRowKeys?: Array<string | number>
|
|
151
|
+
expandedRowKeys?: Array<string | number>
|
|
152
|
+
expandedTreeRowKeys?: Array<string | number>
|
|
153
|
+
'onUpdate:checkedRowKeys'?: ListenerProp<(checkedRowKeys: Array<string | number>) => void>
|
|
154
|
+
'onUpdate:expandedRowKeys'?: ListenerProp<(expandedRowKeys: Array<string | number>) => void>
|
|
155
|
+
'onUpdate:expandedTreeRowKeys'?: ListenerProp<(expandedTreeRowKeys: Array<string | number>) => void>
|
|
156
|
+
'onUpdate:page'?: ListenerProp<(page: number) => void>
|
|
157
|
+
'onUpdate:pageSize'?: ListenerProp<(pageSize: number) => void>
|
|
158
|
+
'onUpdate:sorters'?: ListenerProp<(sorters: DataTableSorter[]) => void>
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
export class DataTable extends VarComponent {
|
|
162
|
+
static setPropsDefaults: SetPropsDefaults<DataTableProps>
|
|
163
|
+
|
|
164
|
+
$props: DataTableProps
|
|
165
|
+
|
|
166
|
+
$slots: {
|
|
167
|
+
empty(): VNode[]
|
|
168
|
+
loadingDescription(): VNode[]
|
|
169
|
+
footerPrefix(): VNode[]
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
export class _DataTableComponent extends DataTable {}
|
package/types/index.d.ts
CHANGED
|
@@ -31,6 +31,7 @@ export * from './context'
|
|
|
31
31
|
export * from './countTo'
|
|
32
32
|
export * from './countdown'
|
|
33
33
|
export * from './counter'
|
|
34
|
+
export * from './dataTable'
|
|
34
35
|
export * from './datePicker'
|
|
35
36
|
export * from './dialog'
|
|
36
37
|
export * from './divider'
|
|
@@ -70,6 +71,8 @@ export * from './progress'
|
|
|
70
71
|
export * from './pullRefresh'
|
|
71
72
|
export * from './radio'
|
|
72
73
|
export * from './radioGroup'
|
|
74
|
+
export * from './railNavigation'
|
|
75
|
+
export * from './railNavigationItem'
|
|
73
76
|
export * from './rate'
|
|
74
77
|
export * from './result'
|
|
75
78
|
export * from './ripple'
|
|
@@ -98,6 +101,7 @@ export * from './tabsItems'
|
|
|
98
101
|
export * from './themes'
|
|
99
102
|
export * from './timePicker'
|
|
100
103
|
export * from './tooltip'
|
|
104
|
+
export * from './treeMenu'
|
|
101
105
|
export * from './uploader'
|
|
102
106
|
export * from './varComponent'
|
|
103
107
|
export * from './varDirective'
|
|
@@ -133,6 +137,7 @@ declare module 'vue' {
|
|
|
133
137
|
VarCountTo: typeof import('@varlet/ui')['_CountToComponent']
|
|
134
138
|
VarCountdown: typeof import('@varlet/ui')['_CountdownComponent']
|
|
135
139
|
VarCounter: typeof import('@varlet/ui')['_CounterComponent']
|
|
140
|
+
VarDataTable: typeof import('@varlet/ui')['_DataTableComponent']
|
|
136
141
|
VarDatePicker: typeof import('@varlet/ui')['_DatePickerComponent']
|
|
137
142
|
VarDialog: typeof import('@varlet/ui')['_DialogComponent']
|
|
138
143
|
VarDivider: typeof import('@varlet/ui')['_DividerComponent']
|
|
@@ -170,6 +175,8 @@ declare module 'vue' {
|
|
|
170
175
|
VarPullRefresh: typeof import('@varlet/ui')['_PullRefreshComponent']
|
|
171
176
|
VarRadio: typeof import('@varlet/ui')['_RadioComponent']
|
|
172
177
|
VarRadioGroup: typeof import('@varlet/ui')['_RadioGroupComponent']
|
|
178
|
+
VarRailNavigation: typeof import('@varlet/ui')['_RailNavigationComponent']
|
|
179
|
+
VarRailNavigationItem: typeof import('@varlet/ui')['_RailNavigationItemComponent']
|
|
173
180
|
VarRate: typeof import('@varlet/ui')['_RateComponent']
|
|
174
181
|
VarResult: typeof import('@varlet/ui')['_ResultComponent']
|
|
175
182
|
VarRow: typeof import('@varlet/ui')['_RowComponent']
|
|
@@ -197,6 +204,7 @@ declare module 'vue' {
|
|
|
197
204
|
VarThemes: typeof import('@varlet/ui')['_ThemesComponent']
|
|
198
205
|
VarTimePicker: typeof import('@varlet/ui')['_TimePickerComponent']
|
|
199
206
|
VarTooltip: typeof import('@varlet/ui')['_TooltipComponent']
|
|
207
|
+
VarTreeMenu: typeof import('@varlet/ui')['_TreeMenuComponent']
|
|
200
208
|
VarUploader: typeof import('@varlet/ui')['_UploaderComponent']
|
|
201
209
|
VarWatermark: typeof import('@varlet/ui')['_WatermarkComponent']
|
|
202
210
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { VNode } from 'vue'
|
|
2
|
+
import { BasicAttributes, ListenerProp, SetPropsDefaults, VarComponent } from './varComponent'
|
|
3
|
+
|
|
4
|
+
export declare const railNavigationProps: Record<keyof RailNavigationProps, any>
|
|
5
|
+
|
|
6
|
+
export interface RailNavigationProps extends BasicAttributes {
|
|
7
|
+
active?: number | string
|
|
8
|
+
ripple?: boolean
|
|
9
|
+
showLabel?: boolean
|
|
10
|
+
border?: boolean
|
|
11
|
+
onChange?: ListenerProp<(active: number | string) => void>
|
|
12
|
+
'onUpdate:active'?: ListenerProp<(active: number | string) => void>
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export class RailNavigation extends VarComponent {
|
|
16
|
+
static setPropsDefaults: SetPropsDefaults<RailNavigationProps>
|
|
17
|
+
|
|
18
|
+
$props: RailNavigationProps
|
|
19
|
+
|
|
20
|
+
$slots: {
|
|
21
|
+
default(): VNode[]
|
|
22
|
+
start(): VNode[]
|
|
23
|
+
end(): VNode[]
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export class _RailNavigationComponent extends RailNavigation {}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { VNode } from 'vue'
|
|
2
|
+
import { BadgeProps } from './badge'
|
|
3
|
+
import { BasicAttributes, ListenerProp, SetPropsDefaults, VarComponent } from './varComponent'
|
|
4
|
+
|
|
5
|
+
export declare const railNavigationItemProps: Record<keyof RailNavigationItemProps, any>
|
|
6
|
+
|
|
7
|
+
export interface RailNavigationItemData {
|
|
8
|
+
active: boolean
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export interface RailNavigationItemIconData {
|
|
12
|
+
active: boolean
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export interface RailNavigationItemProps extends BasicAttributes {
|
|
16
|
+
name?: number | string
|
|
17
|
+
label?: string
|
|
18
|
+
icon?: string
|
|
19
|
+
namespace?: string
|
|
20
|
+
badge?: boolean | BadgeProps
|
|
21
|
+
disabled?: boolean
|
|
22
|
+
onClick?: ListenerProp<(active: number | string) => void>
|
|
23
|
+
onMouseenter?: ListenerProp<(active: number | string) => void>
|
|
24
|
+
onMouseleave?: ListenerProp<(active: number | string) => void>
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export class RailNavigationItem extends VarComponent {
|
|
28
|
+
static setPropsDefaults: SetPropsDefaults<RailNavigationItemProps>
|
|
29
|
+
|
|
30
|
+
$props: RailNavigationItemProps
|
|
31
|
+
|
|
32
|
+
$slots: {
|
|
33
|
+
default(data: RailNavigationItemData): VNode[]
|
|
34
|
+
icon(data: RailNavigationItemIconData): VNode[]
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export class _RailNavigationItemComponent extends RailNavigationItem {}
|
package/types/styleVars.d.ts
CHANGED
|
@@ -53,6 +53,10 @@ interface BaseStyleVars {
|
|
|
53
53
|
'--app-bar-color'?: string
|
|
54
54
|
'--app-bar-text-color'?: string
|
|
55
55
|
'--app-bar-height'?: string
|
|
56
|
+
'--app-bar-large-height'?: string
|
|
57
|
+
'--app-bar-surface-color'?: string
|
|
58
|
+
'--app-bar-surface-text-color'?: string
|
|
59
|
+
'--app-bar-surface-border-bottom'?: string
|
|
56
60
|
'--app-bar-title-padding'?: string
|
|
57
61
|
'--app-bar-title-font-size'?: string
|
|
58
62
|
'--app-bar-left-gap'?: string
|
|
@@ -108,6 +112,7 @@ interface BaseStyleVars {
|
|
|
108
112
|
'--bottom-navigation-item-icon-size'?: string
|
|
109
113
|
'--bottom-navigation-item-icon-margin-bottom'?: string
|
|
110
114
|
'--bottom-navigation-fab-border-radius'?: string
|
|
115
|
+
'--bottom-navigation-item-variant-icon-margin-bottom'?: string
|
|
111
116
|
'--bottom-navigation-item-variant-icon-container-height'?: string
|
|
112
117
|
'--bottom-navigation-item-variant-icon-container-border-radius'?: string
|
|
113
118
|
'--bottom-navigation-item-variant-icon-container-max-width'?: string
|
|
@@ -124,6 +129,7 @@ interface BaseStyleVars {
|
|
|
124
129
|
'--button-warning-text-color'?: string
|
|
125
130
|
'--button-info-text-color'?: string
|
|
126
131
|
'--button-default-color'?: string
|
|
132
|
+
'--button-default-filled-color'?: string
|
|
127
133
|
'--button-primary-color'?: string
|
|
128
134
|
'--button-danger-color'?: string
|
|
129
135
|
'--button-success-color'?: string
|
|
@@ -149,6 +155,8 @@ interface BaseStyleVars {
|
|
|
149
155
|
'--button-normal-padding'?: string
|
|
150
156
|
'--button-large-padding'?: string
|
|
151
157
|
'--button-round-padding'?: string
|
|
158
|
+
'--button-fab-size'?: string
|
|
159
|
+
'--button-fab-border-radius'?: string
|
|
152
160
|
'--button-mini-height'?: string
|
|
153
161
|
'--button-small-height'?: string
|
|
154
162
|
'--button-normal-height'?: string
|
|
@@ -280,6 +288,32 @@ interface BaseStyleVars {
|
|
|
280
288
|
'--counter-disabled-color'?: string
|
|
281
289
|
'--counter-disabled-opacity'?: string
|
|
282
290
|
'--counter-error-color'?: string
|
|
291
|
+
'--data-table-background'?: string
|
|
292
|
+
'--data-table-header-cell-background'?: string
|
|
293
|
+
'--data-table-surface-low-background'?: string
|
|
294
|
+
'--data-table-header-cell-text-color'?: string
|
|
295
|
+
'--data-table-body-cell-text-color'?: string
|
|
296
|
+
'--data-table-border-color'?: string
|
|
297
|
+
'--data-table-row-hover-background'?: string
|
|
298
|
+
'--data-table-surface-low-row-hover-background'?: string
|
|
299
|
+
'--data-table-plain-row-hover-background'?: string
|
|
300
|
+
'--data-table-sort-trigger-color'?: string
|
|
301
|
+
'--data-table-sort-trigger-active-color'?: string
|
|
302
|
+
'--data-table-sort-trigger-hover-background'?: string
|
|
303
|
+
'--data-table-empty-text-color'?: string
|
|
304
|
+
'--data-table-resize-trigger-color'?: string
|
|
305
|
+
'--data-table-fixed-shadow-color'?: string
|
|
306
|
+
'--data-table-border-radius'?: string
|
|
307
|
+
'--data-table-cell-padding'?: string
|
|
308
|
+
'--data-table-selection-cell-padding'?: string
|
|
309
|
+
'--data-table-expand-cell-padding'?: string
|
|
310
|
+
'--data-table-cell-font-size'?: string
|
|
311
|
+
'--data-table-header-font-size'?: string
|
|
312
|
+
'--data-table-row-height'?: string
|
|
313
|
+
'--data-table-row-small-height'?: string
|
|
314
|
+
'--data-table-row-large-height'?: string
|
|
315
|
+
'--data-table-footer-padding'?: string
|
|
316
|
+
'--data-table-empty-padding'?: string
|
|
283
317
|
'--date-picker-border-radius'?: string
|
|
284
318
|
'--date-picker-font-size'?: string
|
|
285
319
|
'--date-picker-min-width'?: string
|
|
@@ -560,6 +594,26 @@ interface BaseStyleVars {
|
|
|
560
594
|
'--radio-action-padding'?: string
|
|
561
595
|
'--radio-icon-size'?: string
|
|
562
596
|
'--radio-text-color'?: string
|
|
597
|
+
'--rail-navigation-width'?: string
|
|
598
|
+
'--rail-navigation-background'?: string
|
|
599
|
+
'--rail-navigation-border-color'?: string
|
|
600
|
+
'--rail-navigation-padding'?: string
|
|
601
|
+
'--rail-navigation-start-padding'?: string
|
|
602
|
+
'--rail-navigation-end-padding'?: string
|
|
603
|
+
'--rail-navigation-item-gap'?: string
|
|
604
|
+
'--rail-navigation-item-height'?: string
|
|
605
|
+
'--rail-navigation-item-padding'?: string
|
|
606
|
+
'--rail-navigation-item-indicator-width'?: string
|
|
607
|
+
'--rail-navigation-item-indicator-height'?: string
|
|
608
|
+
'--rail-navigation-item-indicator-hover-background'?: string
|
|
609
|
+
'--rail-navigation-item-indicator-pressed-background'?: string
|
|
610
|
+
'--rail-navigation-item-indicator-active-background'?: string
|
|
611
|
+
'--rail-navigation-item-inactive-text-color'?: string
|
|
612
|
+
'--rail-navigation-item-active-text-color'?: string
|
|
613
|
+
'--rail-navigation-item-disabled-opacity'?: string
|
|
614
|
+
'--rail-navigation-item-icon-size'?: string
|
|
615
|
+
'--rail-navigation-item-label-font-size'?: string
|
|
616
|
+
'--rail-navigation-item-label-line-height'?: string
|
|
563
617
|
'--rate-color'?: string
|
|
564
618
|
'--rate-size'?: string
|
|
565
619
|
'--rate-primary-color'?: string
|
|
@@ -749,6 +803,9 @@ interface BaseStyleVars {
|
|
|
749
803
|
'--switch-variant-ripple-left'?: string
|
|
750
804
|
'--switch-variant-ripple-active-left'?: string
|
|
751
805
|
'--table-background'?: string
|
|
806
|
+
'--table-surface-low-background'?: string
|
|
807
|
+
'--table-surface-low-row-hover-background'?: string
|
|
808
|
+
'--table-plain-row-hover-background'?: string
|
|
752
809
|
'--table-border-radius'?: string
|
|
753
810
|
'--table-thead-border-bottom'?: string
|
|
754
811
|
'--table-thead-th-text-color'?: string
|
|
@@ -930,6 +987,33 @@ interface BaseStyleVars {
|
|
|
930
987
|
'--tooltip-success-text-color'?: string
|
|
931
988
|
'--tooltip-warning-text-color'?: string
|
|
932
989
|
'--tooltip-danger-text-color'?: string
|
|
990
|
+
'--tree-menu-background'?: string
|
|
991
|
+
'--tree-menu-item-text-color'?: string
|
|
992
|
+
'--tree-menu-padding'?: string
|
|
993
|
+
'--tree-menu-item-gap'?: string
|
|
994
|
+
'--tree-menu-item-height'?: string
|
|
995
|
+
'--tree-menu-item-padding'?: string
|
|
996
|
+
'--tree-menu-item-border-radius'?: string
|
|
997
|
+
'--tree-menu-item-indent'?: string
|
|
998
|
+
'--tree-menu-item-icon-size'?: string
|
|
999
|
+
'--tree-menu-item-icon-margin-right'?: string
|
|
1000
|
+
'--tree-menu-item-label-font-size'?: string
|
|
1001
|
+
'--tree-menu-item-label-line-height'?: string
|
|
1002
|
+
'--tree-menu-group-label-height'?: string
|
|
1003
|
+
'--tree-menu-group-label-padding'?: string
|
|
1004
|
+
'--tree-menu-group-label-color'?: string
|
|
1005
|
+
'--tree-menu-group-label-font-size'?: string
|
|
1006
|
+
'--tree-menu-divider-margin'?: string
|
|
1007
|
+
'--tree-menu-divider-color'?: string
|
|
1008
|
+
'--tree-menu-item-hover-background'?: string
|
|
1009
|
+
'--tree-menu-item-pressed-background'?: string
|
|
1010
|
+
'--tree-menu-item-active-background'?: string
|
|
1011
|
+
'--tree-menu-item-active-text-color'?: string
|
|
1012
|
+
'--tree-menu-item-disabled-opacity'?: string
|
|
1013
|
+
'--tree-menu-item-indicator-border-radius'?: string
|
|
1014
|
+
'--tree-menu-item-indicator-active-transition-duration'?: string
|
|
1015
|
+
'--tree-menu-expand-icon-color'?: string
|
|
1016
|
+
'--tree-menu-expand-icon-size'?: string
|
|
933
1017
|
'--uploader-action-background'?: string
|
|
934
1018
|
'--uploader-action-icon-color'?: string
|
|
935
1019
|
'--uploader-action-icon-size'?: string
|
package/types/table.d.ts
CHANGED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { VNode, VNodeChild } from 'vue'
|
|
2
|
+
import { BasicAttributes, ListenerProp, SetPropsDefaults, VarComponent } from './varComponent'
|
|
3
|
+
|
|
4
|
+
export declare const treeMenuProps: Record<keyof TreeMenuProps, any>
|
|
5
|
+
|
|
6
|
+
export type TreeMenuOptionValue = string | number
|
|
7
|
+
|
|
8
|
+
export type TreeMenuOptionType = 'group' | 'divider'
|
|
9
|
+
|
|
10
|
+
export type TreeMenuOptionLabelRender = (option: TreeMenuOption, active: boolean) => VNodeChild
|
|
11
|
+
|
|
12
|
+
export type TreeMenuOptionIconRender = (option: TreeMenuOption, active: boolean) => VNodeChild
|
|
13
|
+
|
|
14
|
+
export interface TreeMenuOptionRenderContext {
|
|
15
|
+
node: VNode
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export type TreeMenuOptionRender = (
|
|
19
|
+
context: TreeMenuOptionRenderContext,
|
|
20
|
+
option: TreeMenuOption,
|
|
21
|
+
active: boolean,
|
|
22
|
+
) => VNodeChild
|
|
23
|
+
|
|
24
|
+
export interface TreeMenuBaseOption {
|
|
25
|
+
value?: TreeMenuOptionValue
|
|
26
|
+
label?: string | VNode | TreeMenuOptionLabelRender
|
|
27
|
+
icon?: string | VNode | TreeMenuOptionIconRender
|
|
28
|
+
render?: TreeMenuOptionRender
|
|
29
|
+
namespace?: string
|
|
30
|
+
show?: boolean
|
|
31
|
+
disabled?: boolean
|
|
32
|
+
children?: TreeMenuOption[]
|
|
33
|
+
|
|
34
|
+
[key: PropertyKey]: any
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface TreeMenuItemOption extends TreeMenuBaseOption {
|
|
38
|
+
type?: undefined
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface TreeMenuGroupOption extends TreeMenuBaseOption {
|
|
42
|
+
type: 'group'
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export interface TreeMenuDividerOption extends TreeMenuBaseOption {
|
|
46
|
+
type: 'divider'
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export type TreeMenuOption = TreeMenuItemOption | TreeMenuGroupOption | TreeMenuDividerOption
|
|
50
|
+
|
|
51
|
+
export interface TreeMenuProps extends BasicAttributes {
|
|
52
|
+
active?: TreeMenuOptionValue
|
|
53
|
+
options?: TreeMenuOption[]
|
|
54
|
+
expandedValues?: TreeMenuOptionValue[]
|
|
55
|
+
valueKey?: string
|
|
56
|
+
labelKey?: string
|
|
57
|
+
iconKey?: string
|
|
58
|
+
childrenKey?: string
|
|
59
|
+
accordion?: boolean
|
|
60
|
+
indent?: string | number
|
|
61
|
+
ripple?: boolean
|
|
62
|
+
disabled?: boolean
|
|
63
|
+
onChange?: ListenerProp<(active: TreeMenuOptionValue, option: TreeMenuOption) => void>
|
|
64
|
+
'onUpdate:active'?: ListenerProp<(active: TreeMenuOptionValue) => void>
|
|
65
|
+
'onUpdate:expandedValues'?: ListenerProp<(values: TreeMenuOptionValue[]) => void>
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export class TreeMenu extends VarComponent {
|
|
69
|
+
static setPropsDefaults: SetPropsDefaults<TreeMenuProps>
|
|
70
|
+
|
|
71
|
+
$props: TreeMenuProps
|
|
72
|
+
|
|
73
|
+
$slots: {
|
|
74
|
+
start(): VNode[]
|
|
75
|
+
default(): VNode[]
|
|
76
|
+
end(): VNode[]
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export class _TreeMenuComponent extends TreeMenu {}
|