@rotki/ui-library 0.14.0 → 0.15.0
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/dist/{index-4pX97qAk.js → Accordion-BFcz_iFc.js} +3648 -3352
- package/dist/breakpoint-CRvqq4aP.js +37 -0
- package/dist/components/buttons/button/Button.vue.d.ts +4 -4
- package/dist/components/buttons/button-group/ButtonGroup.vue.d.ts +3 -3
- package/dist/components/forms/checkbox/Checkbox.vue.d.ts +9 -9
- package/dist/components/forms/radio-button/radio/Radio.vue.d.ts +9 -9
- package/dist/components/forms/radio-button/radio-group/RadioGroup.vue.d.ts +9 -9
- package/dist/components/forms/revealable-text-field/RevealableTextField.vue.d.ts +9 -9
- package/dist/components/forms/select/RuiMenuSelect.vue.d.ts +155 -0
- package/dist/components/forms/slider/Slider.vue.d.ts +9 -9
- package/dist/components/forms/switch/Switch.vue.d.ts +9 -9
- package/dist/components/forms/text-field/TextField.vue.d.ts +9 -9
- package/dist/components/index.d.ts +2 -2
- package/dist/components/index.es.js +7 -7
- package/dist/components/logos/Logo.vue.d.ts +42 -4
- package/dist/components/overlays/dialog/Dialog.vue.d.ts +5 -5
- package/dist/components/overlays/menu/Menu.vue.d.ts +85 -2
- package/dist/components/tables/DataTable.vue.d.ts +9 -6
- package/dist/components/tables/TableHead.vue.d.ts +15 -3
- package/dist/composables/dropdown-menu.d.ts +40 -0
- package/dist/composables/index.es.js +5 -81
- package/dist/consts/forms/auto-complete/index.d.ts +3 -3
- package/dist/index-x2urm9HD.js +176 -0
- package/dist/index.es.js +6 -6
- package/dist/style.css +1 -1
- package/dist/theme/index.es.js +1 -1
- package/dist/utils/assert.d.ts +1 -0
- package/dist/utils/helpers.d.ts +7 -0
- package/package.json +39 -41
- package/dist/components/forms/select/MenuSelect.vue.d.ts +0 -62
- package/dist/theme-DT8UjYf9.js +0 -124
- /package/dist/{colors-ikihApJv.js → colors-D563Ic3q.js} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { x as u, w as s, A as e, a as R, B as o, b as t, c as r, l, m as d, C as p, d as n, D as T, k as b, u as c, F as S, I as x, _ as g, i as m, M as A, P as C, R as h, e as B, f as D, j as F, s as I, v as k, S as v, g as w, o as M, q as P, p as f, r as E, E as G, n as L, t as j, h as q, T as H } from "../Accordion-BFcz_iFc.js";
|
|
2
2
|
export {
|
|
3
3
|
u as RuiAccordion,
|
|
4
4
|
s as RuiAccordions,
|
|
@@ -28,13 +28,13 @@ export {
|
|
|
28
28
|
k as RuiSlider,
|
|
29
29
|
v as RuiStepper,
|
|
30
30
|
w as RuiSwitch,
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
31
|
+
M as RuiTab,
|
|
32
|
+
P as RuiTabItem,
|
|
33
|
+
f as RuiTabItems,
|
|
34
|
+
E as RuiTablePagination,
|
|
35
|
+
G as RuiTableRowExpander,
|
|
36
36
|
L as RuiTabs,
|
|
37
37
|
j as RuiTextArea,
|
|
38
38
|
q as RuiTextField,
|
|
39
|
-
|
|
39
|
+
H as RuiTooltip
|
|
40
40
|
};
|
|
@@ -1,27 +1,65 @@
|
|
|
1
|
+
interface ExternalLinks {
|
|
2
|
+
drawer?: string;
|
|
3
|
+
app?: string;
|
|
4
|
+
website?: string;
|
|
5
|
+
about?: string;
|
|
6
|
+
emptyScreen?: string;
|
|
7
|
+
[key: string]: string | undefined;
|
|
8
|
+
}
|
|
1
9
|
export interface Props {
|
|
2
10
|
text?: boolean;
|
|
3
|
-
|
|
11
|
+
branch?: 'develop' | 'main' | string;
|
|
12
|
+
logo?: keyof ExternalLinks;
|
|
13
|
+
size?: string | number;
|
|
14
|
+
uniqueKey?: string | number;
|
|
4
15
|
}
|
|
5
16
|
declare const _default: import("vue").DefineComponent<{
|
|
17
|
+
size: {
|
|
18
|
+
type: globalThis.PropType<string | number>;
|
|
19
|
+
default: number;
|
|
20
|
+
};
|
|
6
21
|
text: {
|
|
7
22
|
type: globalThis.PropType<boolean>;
|
|
8
23
|
default: boolean;
|
|
9
24
|
};
|
|
10
|
-
|
|
25
|
+
branch: {
|
|
11
26
|
type: globalThis.PropType<string>;
|
|
27
|
+
default: string;
|
|
28
|
+
};
|
|
29
|
+
logo: {
|
|
30
|
+
type: globalThis.PropType<keyof ExternalLinks>;
|
|
31
|
+
default: undefined;
|
|
32
|
+
};
|
|
33
|
+
uniqueKey: {
|
|
34
|
+
type: globalThis.PropType<string | number>;
|
|
12
35
|
default: undefined;
|
|
13
36
|
};
|
|
14
37
|
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
38
|
+
size: {
|
|
39
|
+
type: globalThis.PropType<string | number>;
|
|
40
|
+
default: number;
|
|
41
|
+
};
|
|
15
42
|
text: {
|
|
16
43
|
type: globalThis.PropType<boolean>;
|
|
17
44
|
default: boolean;
|
|
18
45
|
};
|
|
19
|
-
|
|
46
|
+
branch: {
|
|
20
47
|
type: globalThis.PropType<string>;
|
|
48
|
+
default: string;
|
|
49
|
+
};
|
|
50
|
+
logo: {
|
|
51
|
+
type: globalThis.PropType<keyof ExternalLinks>;
|
|
52
|
+
default: undefined;
|
|
53
|
+
};
|
|
54
|
+
uniqueKey: {
|
|
55
|
+
type: globalThis.PropType<string | number>;
|
|
21
56
|
default: undefined;
|
|
22
57
|
};
|
|
23
58
|
}>>, {
|
|
59
|
+
size: string | number;
|
|
24
60
|
text: boolean;
|
|
25
|
-
|
|
61
|
+
branch: string;
|
|
62
|
+
logo: keyof ExternalLinks;
|
|
63
|
+
uniqueKey: string | number;
|
|
26
64
|
}, {}>;
|
|
27
65
|
export default _default;
|
|
@@ -13,11 +13,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
13
13
|
type: globalThis.PropType<boolean>;
|
|
14
14
|
required: true;
|
|
15
15
|
};
|
|
16
|
-
|
|
16
|
+
persistent: {
|
|
17
17
|
type: globalThis.PropType<boolean>;
|
|
18
18
|
default: boolean;
|
|
19
19
|
};
|
|
20
|
-
|
|
20
|
+
dismissible: {
|
|
21
21
|
type: globalThis.PropType<boolean>;
|
|
22
22
|
default: boolean;
|
|
23
23
|
};
|
|
@@ -32,11 +32,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
32
32
|
type: globalThis.PropType<boolean>;
|
|
33
33
|
required: true;
|
|
34
34
|
};
|
|
35
|
-
|
|
35
|
+
persistent: {
|
|
36
36
|
type: globalThis.PropType<boolean>;
|
|
37
37
|
default: boolean;
|
|
38
38
|
};
|
|
39
|
-
|
|
39
|
+
dismissible: {
|
|
40
40
|
type: globalThis.PropType<boolean>;
|
|
41
41
|
default: boolean;
|
|
42
42
|
};
|
|
@@ -44,8 +44,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
44
44
|
"onUpdate:model-value"?: ((modelValue: boolean) => any) | undefined;
|
|
45
45
|
}, {
|
|
46
46
|
size: "sm" | "md" | "lg";
|
|
47
|
-
dismissible: boolean;
|
|
48
47
|
persistent: boolean;
|
|
48
|
+
dismissible: boolean;
|
|
49
49
|
}, {}>, {
|
|
50
50
|
description?(_: {}): any;
|
|
51
51
|
title?(_: {}): any;
|
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
import { type PopperOptions } from '../../../composables/popper';
|
|
2
|
-
export interface
|
|
2
|
+
export interface MenuProps {
|
|
3
3
|
modelValue?: boolean;
|
|
4
4
|
openOnHover?: boolean;
|
|
5
|
+
fullWidth?: boolean;
|
|
5
6
|
disabled?: boolean;
|
|
6
7
|
openDelay?: number;
|
|
7
8
|
closeDelay?: number;
|
|
8
9
|
popper?: PopperOptions;
|
|
10
|
+
wrapperClass?: string;
|
|
9
11
|
menuClass?: string;
|
|
10
12
|
closeOnContentClick?: boolean;
|
|
13
|
+
hint?: string;
|
|
14
|
+
errorMessages?: string | string[];
|
|
15
|
+
successMessages?: string | string[];
|
|
16
|
+
showDetails?: boolean;
|
|
17
|
+
dense?: boolean;
|
|
18
|
+
persistent?: boolean;
|
|
11
19
|
}
|
|
12
20
|
declare function checkClick(): void;
|
|
13
21
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
@@ -19,6 +27,21 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
19
27
|
type: globalThis.PropType<boolean>;
|
|
20
28
|
default: boolean;
|
|
21
29
|
};
|
|
30
|
+
errorMessages: {
|
|
31
|
+
type: globalThis.PropType<string | string[]>;
|
|
32
|
+
default: () => never[];
|
|
33
|
+
};
|
|
34
|
+
successMessages: {
|
|
35
|
+
type: globalThis.PropType<string | string[]>;
|
|
36
|
+
default: () => never[];
|
|
37
|
+
};
|
|
38
|
+
hint: {
|
|
39
|
+
type: globalThis.PropType<string>;
|
|
40
|
+
default: undefined;
|
|
41
|
+
};
|
|
42
|
+
dense: {
|
|
43
|
+
type: globalThis.PropType<boolean>;
|
|
44
|
+
};
|
|
22
45
|
openDelay: {
|
|
23
46
|
type: globalThis.PropType<number>;
|
|
24
47
|
default: number;
|
|
@@ -35,6 +58,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
35
58
|
type: globalThis.PropType<boolean>;
|
|
36
59
|
default: boolean;
|
|
37
60
|
};
|
|
61
|
+
fullWidth: {
|
|
62
|
+
type: globalThis.PropType<boolean>;
|
|
63
|
+
default: boolean;
|
|
64
|
+
};
|
|
65
|
+
wrapperClass: {
|
|
66
|
+
type: globalThis.PropType<string>;
|
|
67
|
+
default: string;
|
|
68
|
+
};
|
|
38
69
|
menuClass: {
|
|
39
70
|
type: globalThis.PropType<string>;
|
|
40
71
|
default: string;
|
|
@@ -43,6 +74,13 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
43
74
|
type: globalThis.PropType<boolean>;
|
|
44
75
|
default: boolean;
|
|
45
76
|
};
|
|
77
|
+
showDetails: {
|
|
78
|
+
type: globalThis.PropType<boolean>;
|
|
79
|
+
};
|
|
80
|
+
persistent: {
|
|
81
|
+
type: globalThis.PropType<boolean>;
|
|
82
|
+
default: boolean;
|
|
83
|
+
};
|
|
46
84
|
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
47
85
|
"update:model-value": (value: boolean) => void;
|
|
48
86
|
}, string, import("vue").PublicProps, Readonly<globalThis.ExtractPropTypes<{
|
|
@@ -54,6 +92,21 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
54
92
|
type: globalThis.PropType<boolean>;
|
|
55
93
|
default: boolean;
|
|
56
94
|
};
|
|
95
|
+
errorMessages: {
|
|
96
|
+
type: globalThis.PropType<string | string[]>;
|
|
97
|
+
default: () => never[];
|
|
98
|
+
};
|
|
99
|
+
successMessages: {
|
|
100
|
+
type: globalThis.PropType<string | string[]>;
|
|
101
|
+
default: () => never[];
|
|
102
|
+
};
|
|
103
|
+
hint: {
|
|
104
|
+
type: globalThis.PropType<string>;
|
|
105
|
+
default: undefined;
|
|
106
|
+
};
|
|
107
|
+
dense: {
|
|
108
|
+
type: globalThis.PropType<boolean>;
|
|
109
|
+
};
|
|
57
110
|
openDelay: {
|
|
58
111
|
type: globalThis.PropType<number>;
|
|
59
112
|
default: number;
|
|
@@ -70,6 +123,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
70
123
|
type: globalThis.PropType<boolean>;
|
|
71
124
|
default: boolean;
|
|
72
125
|
};
|
|
126
|
+
fullWidth: {
|
|
127
|
+
type: globalThis.PropType<boolean>;
|
|
128
|
+
default: boolean;
|
|
129
|
+
};
|
|
130
|
+
wrapperClass: {
|
|
131
|
+
type: globalThis.PropType<string>;
|
|
132
|
+
default: string;
|
|
133
|
+
};
|
|
73
134
|
menuClass: {
|
|
74
135
|
type: globalThis.PropType<string>;
|
|
75
136
|
default: string;
|
|
@@ -78,27 +139,49 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
|
78
139
|
type: globalThis.PropType<boolean>;
|
|
79
140
|
default: boolean;
|
|
80
141
|
};
|
|
142
|
+
showDetails: {
|
|
143
|
+
type: globalThis.PropType<boolean>;
|
|
144
|
+
};
|
|
145
|
+
persistent: {
|
|
146
|
+
type: globalThis.PropType<boolean>;
|
|
147
|
+
default: boolean;
|
|
148
|
+
};
|
|
81
149
|
}>> & {
|
|
82
150
|
"onUpdate:model-value"?: ((value: boolean) => any) | undefined;
|
|
83
151
|
}, {
|
|
84
152
|
disabled: boolean;
|
|
85
153
|
modelValue: boolean;
|
|
154
|
+
errorMessages: string | string[];
|
|
155
|
+
successMessages: string | string[];
|
|
156
|
+
hint: string;
|
|
86
157
|
openDelay: number;
|
|
87
158
|
closeDelay: number;
|
|
88
159
|
popper: PopperOptions;
|
|
89
160
|
openOnHover: boolean;
|
|
161
|
+
fullWidth: boolean;
|
|
162
|
+
wrapperClass: string;
|
|
90
163
|
menuClass: string;
|
|
91
164
|
closeOnContentClick: boolean;
|
|
165
|
+
persistent: boolean;
|
|
92
166
|
}, {}>, {
|
|
93
167
|
activator?(_: {
|
|
94
168
|
on: {
|
|
169
|
+
mouseover?: undefined;
|
|
170
|
+
mouseleave?: undefined;
|
|
171
|
+
click?: undefined;
|
|
172
|
+
} | {
|
|
95
173
|
mouseover: () => void;
|
|
96
174
|
mouseleave: () => void;
|
|
97
175
|
click: typeof checkClick;
|
|
98
176
|
};
|
|
99
177
|
open: boolean;
|
|
178
|
+
disabled: boolean;
|
|
179
|
+
hasError: boolean;
|
|
180
|
+
hasSuccess: boolean;
|
|
181
|
+
}): any;
|
|
182
|
+
default?(_: {
|
|
183
|
+
width: number;
|
|
100
184
|
}): any;
|
|
101
|
-
default?(_: {}): any;
|
|
102
185
|
}>;
|
|
103
186
|
export default _default;
|
|
104
187
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
@@ -130,8 +130,11 @@ export interface Props<T, K extends keyof T> {
|
|
|
130
130
|
* @example v-model:group="['name', 'country']"
|
|
131
131
|
*/
|
|
132
132
|
group?: TableRowKeyData<T>;
|
|
133
|
+
groupExpandButtonPosition?: 'start' | 'end';
|
|
133
134
|
collapsed?: T[];
|
|
134
135
|
disabledRows?: T[];
|
|
136
|
+
multiPageSelect?: boolean;
|
|
137
|
+
scroller?: HTMLElement | null;
|
|
135
138
|
}
|
|
136
139
|
declare const _default: <T extends object, IdType extends keyof T = keyof T>(__VLS_props: Props<T, IdType> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, __VLS_ctx?: Pick<{
|
|
137
140
|
props: Props<T, IdType>;
|
|
@@ -169,13 +172,13 @@ declare const _default: <T extends object, IdType extends keyof T = keyof T>(__V
|
|
|
169
172
|
tfoot: () => any;
|
|
170
173
|
}>;
|
|
171
174
|
emit: {
|
|
172
|
-
(e: 'update:model-value', value?: T[IdType][]
|
|
175
|
+
(e: 'update:model-value', value?: T[IdType][]): void;
|
|
173
176
|
(e: 'update:expanded', value: T[]): void;
|
|
174
177
|
(e: 'update:pagination', value: TablePaginationData): void;
|
|
175
178
|
(e: 'update:sort', value?: TableSortData<T>): void;
|
|
176
179
|
(e: 'update:options', value: TableOptions<T>): void;
|
|
177
180
|
(e: 'update:group', value?: GroupKeys<T>): void;
|
|
178
|
-
(e: 'update:collapsed', value?: T[]
|
|
181
|
+
(e: 'update:collapsed', value?: T[]): void;
|
|
179
182
|
(e: 'copy:group', value: GroupData<T>): void;
|
|
180
183
|
};
|
|
181
184
|
}, "attrs" | "emit" | "slots"> | undefined, __VLS_expose?: ((exposed: {}) => void) | undefined, __VLS_setup?: Promise<{
|
|
@@ -214,13 +217,13 @@ declare const _default: <T extends object, IdType extends keyof T = keyof T>(__V
|
|
|
214
217
|
tfoot: () => any;
|
|
215
218
|
}>;
|
|
216
219
|
emit: {
|
|
217
|
-
(e: 'update:model-value', value?: T[IdType][]
|
|
220
|
+
(e: 'update:model-value', value?: T[IdType][]): void;
|
|
218
221
|
(e: 'update:expanded', value: T[]): void;
|
|
219
222
|
(e: 'update:pagination', value: TablePaginationData): void;
|
|
220
223
|
(e: 'update:sort', value?: TableSortData<T>): void;
|
|
221
224
|
(e: 'update:options', value: TableOptions<T>): void;
|
|
222
225
|
(e: 'update:group', value?: GroupKeys<T>): void;
|
|
223
|
-
(e: 'update:collapsed', value?: T[]
|
|
226
|
+
(e: 'update:collapsed', value?: T[]): void;
|
|
224
227
|
(e: 'copy:group', value: GroupData<T>): void;
|
|
225
228
|
};
|
|
226
229
|
}>) => globalThis.VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
@@ -262,13 +265,13 @@ declare const _default: <T extends object, IdType extends keyof T = keyof T>(__V
|
|
|
262
265
|
tfoot: () => any;
|
|
263
266
|
}>;
|
|
264
267
|
emit: {
|
|
265
|
-
(e: 'update:model-value', value?: T[IdType][]
|
|
268
|
+
(e: 'update:model-value', value?: T[IdType][]): void;
|
|
266
269
|
(e: 'update:expanded', value: T[]): void;
|
|
267
270
|
(e: 'update:pagination', value: TablePaginationData): void;
|
|
268
271
|
(e: 'update:sort', value?: TableSortData<T>): void;
|
|
269
272
|
(e: 'update:options', value: TableOptions<T>): void;
|
|
270
273
|
(e: 'update:group', value?: GroupKeys<T>): void;
|
|
271
|
-
(e: 'update:collapsed', value?: T[]
|
|
274
|
+
(e: 'update:collapsed', value?: T[]): void;
|
|
272
275
|
(e: 'copy:group', value: GroupData<T>): void;
|
|
273
276
|
};
|
|
274
277
|
} | undefined;
|
|
@@ -71,12 +71,16 @@ declare const _default: <T extends object, K extends keyof T = keyof T>(__VLS_pr
|
|
|
71
71
|
attrs: any;
|
|
72
72
|
slots: Partial<Record<string, (_: {
|
|
73
73
|
column: TableColumn<T>;
|
|
74
|
+
}) => any>> & Partial<Record<string, (_: {
|
|
75
|
+
column: SortableTableColumn<T>;
|
|
76
|
+
}) => any>> & Partial<Record<string, (_: {
|
|
77
|
+
column: NoneSortableTableColumn<T>;
|
|
74
78
|
}) => any>>;
|
|
75
79
|
emit: {
|
|
76
80
|
(e: 'select:all', value: boolean): void;
|
|
77
81
|
(e: 'sort', value: {
|
|
78
82
|
key: TableRowKey<T>;
|
|
79
|
-
direction?:
|
|
83
|
+
direction?: 'asc' | 'desc';
|
|
80
84
|
}): void;
|
|
81
85
|
};
|
|
82
86
|
}, "attrs" | "emit" | "slots"> | undefined, __VLS_expose?: ((exposed: {}) => void) | undefined, __VLS_setup?: Promise<{
|
|
@@ -85,12 +89,16 @@ declare const _default: <T extends object, K extends keyof T = keyof T>(__VLS_pr
|
|
|
85
89
|
attrs: any;
|
|
86
90
|
slots: Partial<Record<string, (_: {
|
|
87
91
|
column: TableColumn<T>;
|
|
92
|
+
}) => any>> & Partial<Record<string, (_: {
|
|
93
|
+
column: SortableTableColumn<T>;
|
|
94
|
+
}) => any>> & Partial<Record<string, (_: {
|
|
95
|
+
column: NoneSortableTableColumn<T>;
|
|
88
96
|
}) => any>>;
|
|
89
97
|
emit: {
|
|
90
98
|
(e: 'select:all', value: boolean): void;
|
|
91
99
|
(e: 'sort', value: {
|
|
92
100
|
key: TableRowKey<T>;
|
|
93
|
-
direction?:
|
|
101
|
+
direction?: 'asc' | 'desc';
|
|
94
102
|
}): void;
|
|
95
103
|
};
|
|
96
104
|
}>) => globalThis.VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
@@ -102,12 +110,16 @@ declare const _default: <T extends object, K extends keyof T = keyof T>(__VLS_pr
|
|
|
102
110
|
attrs: any;
|
|
103
111
|
slots: Partial<Record<string, (_: {
|
|
104
112
|
column: TableColumn<T>;
|
|
113
|
+
}) => any>> & Partial<Record<string, (_: {
|
|
114
|
+
column: SortableTableColumn<T>;
|
|
115
|
+
}) => any>> & Partial<Record<string, (_: {
|
|
116
|
+
column: NoneSortableTableColumn<T>;
|
|
105
117
|
}) => any>>;
|
|
106
118
|
emit: {
|
|
107
119
|
(e: 'select:all', value: boolean): void;
|
|
108
120
|
(e: 'sort', value: {
|
|
109
121
|
key: TableRowKey<T>;
|
|
110
|
-
direction?:
|
|
122
|
+
direction?: 'asc' | 'desc';
|
|
111
123
|
}): void;
|
|
112
124
|
};
|
|
113
125
|
} | undefined;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import type { Ref } from 'vue';
|
|
2
|
+
export interface DropdownOptions<T, K extends keyof T = keyof T> {
|
|
3
|
+
options: Ref<T[]>;
|
|
4
|
+
dense?: Ref<boolean>;
|
|
5
|
+
value: Ref<T | undefined>;
|
|
6
|
+
menuRef: Ref<HTMLElement>;
|
|
7
|
+
keyAttr?: K;
|
|
8
|
+
textAttr?: keyof T;
|
|
9
|
+
appendWidth?: number;
|
|
10
|
+
prependWidth?: number;
|
|
11
|
+
itemHeight?: number;
|
|
12
|
+
overscan?: number;
|
|
13
|
+
}
|
|
14
|
+
export declare function useDropdownMenu<T extends object | string, K extends keyof T>({ appendWidth, dense, itemHeight, keyAttr, menuRef, options, overscan, prependWidth, textAttr, value, }: DropdownOptions<T, K>): {
|
|
15
|
+
containerProps: {
|
|
16
|
+
ref: Ref<HTMLElement | null>;
|
|
17
|
+
onScroll: () => void;
|
|
18
|
+
style: import("vue").StyleValue;
|
|
19
|
+
};
|
|
20
|
+
getIdentifier: (item: T) => T[K] | T;
|
|
21
|
+
getText: (item: T) => T[keyof T] | T;
|
|
22
|
+
isActiveItem: (item: T) => boolean;
|
|
23
|
+
isOpen: Ref<boolean>;
|
|
24
|
+
menuWidth: globalThis.ComputedRef<string>;
|
|
25
|
+
renderedData: globalThis.ComputedRef<T[]>;
|
|
26
|
+
toggle: (state?: boolean) => void;
|
|
27
|
+
valueKey: globalThis.ComputedRef<T | T[K] | undefined>;
|
|
28
|
+
wrapperProps: globalThis.ComputedRef<{
|
|
29
|
+
style: {
|
|
30
|
+
width: string;
|
|
31
|
+
height: string;
|
|
32
|
+
marginTop: string;
|
|
33
|
+
} | {
|
|
34
|
+
width: string;
|
|
35
|
+
height: string;
|
|
36
|
+
marginLeft: string;
|
|
37
|
+
display: string;
|
|
38
|
+
};
|
|
39
|
+
}>;
|
|
40
|
+
};
|
|
@@ -1,83 +1,7 @@
|
|
|
1
|
-
import { u as
|
|
2
|
-
import {
|
|
3
|
-
import { computed as _ } from "vue";
|
|
4
|
-
import { get as h } from "@vueuse/shared";
|
|
5
|
-
const C = /\d/, g = ["-", "_", "/", "."];
|
|
6
|
-
function E(e = "") {
|
|
7
|
-
if (!C.test(e))
|
|
8
|
-
return e !== e.toLowerCase();
|
|
9
|
-
}
|
|
10
|
-
function S(e, n) {
|
|
11
|
-
const o = n ?? g, r = [];
|
|
12
|
-
if (!e || typeof e != "string")
|
|
13
|
-
return r;
|
|
14
|
-
let t = "", i, p;
|
|
15
|
-
for (const c of e) {
|
|
16
|
-
const f = o.includes(c);
|
|
17
|
-
if (f === !0) {
|
|
18
|
-
r.push(t), t = "", i = void 0;
|
|
19
|
-
continue;
|
|
20
|
-
}
|
|
21
|
-
const u = E(c);
|
|
22
|
-
if (p === !1) {
|
|
23
|
-
if (i === !1 && u === !0) {
|
|
24
|
-
r.push(t), t = c, i = u;
|
|
25
|
-
continue;
|
|
26
|
-
}
|
|
27
|
-
if (i === !0 && u === !1 && t.length > 1) {
|
|
28
|
-
const s = t.at(-1);
|
|
29
|
-
r.push(t.slice(0, Math.max(0, t.length - 1))), t = s + c, i = u;
|
|
30
|
-
continue;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
t += c, i = u, p = f;
|
|
34
|
-
}
|
|
35
|
-
return r.push(t), r;
|
|
36
|
-
}
|
|
37
|
-
function y(e) {
|
|
38
|
-
return e ? e[0].toUpperCase() + e.slice(1) : "";
|
|
39
|
-
}
|
|
40
|
-
function z(e) {
|
|
41
|
-
return e ? e[0].toLowerCase() + e.slice(1) : "";
|
|
42
|
-
}
|
|
43
|
-
function R(e, n) {
|
|
44
|
-
return e ? (Array.isArray(e) ? e : S(e)).map((o) => y(n != null && n.normalize ? o.toLowerCase() : o)).join("") : "";
|
|
45
|
-
}
|
|
46
|
-
function l(e, n) {
|
|
47
|
-
return z(R(e || "", n));
|
|
48
|
-
}
|
|
49
|
-
function L() {
|
|
50
|
-
const { width: e } = m(), n = {
|
|
51
|
-
xs: 0,
|
|
52
|
-
...d
|
|
53
|
-
}, o = w(n), r = Object.keys, t = r(n), i = t.map(
|
|
54
|
-
(s, a) => [
|
|
55
|
-
s,
|
|
56
|
-
a < t.length - 1 ? o.between(s, t[a + 1]) : o[s]
|
|
57
|
-
]
|
|
58
|
-
), p = i.map(([s, a]) => [
|
|
59
|
-
l(`is_${s}`),
|
|
60
|
-
a
|
|
61
|
-
]), c = t.map((s) => [
|
|
62
|
-
l(`is_${s}_and_up`),
|
|
63
|
-
o.greaterOrEqual(s)
|
|
64
|
-
]), f = t.map((s) => [
|
|
65
|
-
l(`is_${s}_and_down`),
|
|
66
|
-
o.smaller(s)
|
|
67
|
-
]), u = _(() => {
|
|
68
|
-
var s;
|
|
69
|
-
return ((s = i.find((a) => h(a[1]))) == null ? void 0 : s[0]) || "";
|
|
70
|
-
});
|
|
71
|
-
return {
|
|
72
|
-
...Object.fromEntries(p),
|
|
73
|
-
...Object.fromEntries(c),
|
|
74
|
-
...Object.fromEntries(f),
|
|
75
|
-
name: u,
|
|
76
|
-
width: e
|
|
77
|
-
};
|
|
78
|
-
}
|
|
1
|
+
import { u as s, a } from "../index-x2urm9HD.js";
|
|
2
|
+
import { u } from "../breakpoint-CRvqq4aP.js";
|
|
79
3
|
export {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
4
|
+
u as useBreakpoint,
|
|
5
|
+
s as useIcons,
|
|
6
|
+
a as useRotkiTheme
|
|
83
7
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const defaultTextProp
|
|
2
|
-
declare const defaultKeyProp
|
|
3
|
-
declare const defaultDisabledProp
|
|
1
|
+
declare const defaultTextProp = "text";
|
|
2
|
+
declare const defaultKeyProp = "id";
|
|
3
|
+
declare const defaultDisabledProp = "disabled";
|
|
4
4
|
export { defaultKeyProp, defaultDisabledProp, defaultTextProp, };
|