@v1nt1248/3nclient-lib 0.3.9 → 0.3.11
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 +3 -2
- package/dist/components/ui3n-autocomplete/types.d.ts +100 -0
- package/dist/components/ui3n-badge/types.d.ts +14 -0
- package/dist/components/ui3n-badge/ui3n-badge.vue.d.ts +2 -4
- package/dist/components/ui3n-breadcrumbs/types.d.ts +50 -0
- package/dist/components/ui3n-breadcrumbs/ui3n-breadcrumbs.vue.d.ts +2 -4
- package/dist/components/ui3n-button/types.d.ts +21 -0
- package/dist/components/ui3n-button/ui3n-button.vue.d.ts +2 -4
- package/dist/components/ui3n-checkbox/types.d.ts +44 -0
- package/dist/components/ui3n-chip/types.d.ts +49 -0
- package/dist/components/ui3n-dialog/types.d.ts +103 -0
- package/dist/components/ui3n-drop-files/types.d.ts +31 -0
- package/dist/components/ui3n-editable/types.d.ts +102 -0
- package/dist/components/ui3n-emoji/types.d.ts +13 -0
- package/dist/components/ui3n-icon/types.d.ts +10 -0
- package/dist/components/ui3n-input/types.d.ts +85 -0
- package/dist/components/ui3n-input-file/types.d.ts +29 -0
- package/dist/components/ui3n-list/types.d.ts +35 -0
- package/dist/components/ui3n-menu/types.d.ts +89 -0
- package/dist/components/ui3n-notification/types.d.ts +28 -0
- package/dist/components/ui3n-progress/types.d.ts +49 -0
- package/dist/components/ui3n-radio-group/types.d.ts +78 -0
- package/dist/components/ui3n-selector/types.d.ts +95 -0
- package/dist/components/ui3n-slider/types.d.ts +51 -0
- package/dist/components/ui3n-step-line-bar/types.d.ts +12 -0
- package/dist/components/ui3n-switch/types.d.ts +31 -0
- package/dist/components/ui3n-table/types.d.ts +198 -0
- package/dist/components/ui3n-tabs/types.d.ts +38 -0
- package/dist/components/ui3n-text/types.d.ts +56 -0
- package/dist/components/ui3n-tooltip/types.d.ts +69 -0
- package/dist/components/ui3n-virtual-scroll/types.d.ts +18 -0
- package/dist/constants/general.d.ts +0 -1
- package/dist/constants/plugins-keys.d.ts +0 -2
- package/dist/index.d.ts +0 -8
- package/dist/plugins/index.d.ts +1 -4
- package/dist/style.css +1 -1
- package/dist/ui3n-components.js +5521 -5527
- package/dist/ui3n-plugins.d.ts +3 -11
- package/dist/ui3n-plugins.js +338 -366
- package/dist/ui3n-utils.js +422 -439
- package/dist/utils/copy-to-clipboard.d.ts +1 -0
- package/dist/utils/execute-function.d.ts +29 -0
- package/dist/utils/index.d.ts +3 -0
- package/dist/utils/remove-whitespace-in-string.d.ts +1 -0
- package/dist/utils/ui/get-element-color.d.ts +1 -1
- package/package.json +25 -22
- package/src/components/ui3n-autocomplete/types.ts +100 -0
- package/src/components/ui3n-badge/types.ts +16 -0
- package/src/components/ui3n-badge/ui3n-badge-simple.vue +10 -9
- package/src/components/ui3n-badge/ui3n-badge.vue +37 -36
- package/src/components/ui3n-breadcrumbs/types.ts +51 -0
- package/src/components/ui3n-breadcrumbs/ui3n-breadcrumb.vue +69 -69
- package/src/components/ui3n-breadcrumbs/ui3n-breadcrumbs.vue +7 -8
- package/src/components/ui3n-button/types.ts +23 -0
- package/src/components/ui3n-button/ui3n-button.vue +27 -29
- package/src/components/ui3n-checkbox/types.ts +44 -0
- package/src/components/ui3n-checkbox/ui3n-checkbox.vue +16 -23
- package/src/components/ui3n-chip/types.ts +51 -0
- package/src/components/ui3n-dialog/types.ts +103 -0
- package/src/components/ui3n-drop-files/types.ts +31 -0
- package/src/components/ui3n-editable/types.ts +102 -0
- package/src/components/ui3n-editable/useContentEditable.ts +4 -2
- package/src/components/ui3n-emoji/types.ts +13 -0
- package/src/components/ui3n-icon/types.ts +10 -0
- package/src/components/ui3n-input/types.ts +85 -0
- package/src/components/ui3n-input-file/types.ts +29 -0
- package/src/components/ui3n-list/types.ts +35 -0
- package/src/components/ui3n-menu/types.ts +89 -0
- package/src/components/ui3n-notification/types.ts +28 -0
- package/src/components/ui3n-progress/types.ts +49 -0
- package/src/components/ui3n-radio-group/types.ts +78 -0
- package/src/components/ui3n-selector/types.ts +96 -1
- package/src/components/ui3n-slider/types.ts +51 -0
- package/src/components/ui3n-step-line-bar/types.ts +12 -0
- package/src/components/ui3n-switch/types.ts +31 -0
- package/src/components/ui3n-table/types.ts +204 -0
- package/src/components/ui3n-tabs/types.ts +38 -0
- package/src/components/ui3n-text/types.ts +56 -0
- package/src/components/ui3n-tooltip/types.ts +69 -0
- package/src/components/ui3n-virtual-scroll/types.ts +18 -0
- package/dist/plugins/i18n/i18n.d.ts +0 -9
- package/dist/plugins/i18n/store-i18n.d.ts +0 -7
- package/dist/plugins/i18n/types.d.ts +0 -9
|
@@ -1,16 +1,54 @@
|
|
|
1
1
|
import { VNode } from 'vue';
|
|
2
|
+
/**
|
|
3
|
+
* Tabs component properties
|
|
4
|
+
*/
|
|
2
5
|
export interface Ui3nTabsProps {
|
|
6
|
+
/**
|
|
7
|
+
* Current active tab index
|
|
8
|
+
*/
|
|
3
9
|
modelValue: number;
|
|
10
|
+
/**
|
|
11
|
+
* Direction of tabs
|
|
12
|
+
* @default 'horizontal'
|
|
13
|
+
*/
|
|
4
14
|
itemDirection?: 'horizontal' | 'vertical';
|
|
15
|
+
/**
|
|
16
|
+
* Active tab color
|
|
17
|
+
*/
|
|
5
18
|
activeColor?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Inactive tab color
|
|
21
|
+
*/
|
|
6
22
|
inactiveColor?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Indicator color
|
|
25
|
+
*/
|
|
7
26
|
indicatorColor?: string;
|
|
27
|
+
/**
|
|
28
|
+
* Indicator size
|
|
29
|
+
*/
|
|
8
30
|
indicatorSize?: number | string;
|
|
31
|
+
/**
|
|
32
|
+
* Indicator position
|
|
33
|
+
* @default 'normal'
|
|
34
|
+
*/
|
|
9
35
|
indicatorPosition?: 'normal' | 'reverse';
|
|
10
36
|
}
|
|
37
|
+
/**
|
|
38
|
+
* Tabs component emits
|
|
39
|
+
*/
|
|
11
40
|
export interface Ui3nTabsEmits {
|
|
41
|
+
/**
|
|
42
|
+
* Emitted when model value updates
|
|
43
|
+
*/
|
|
12
44
|
(ev: 'update:modelValue', val: number): void;
|
|
13
45
|
}
|
|
46
|
+
/**
|
|
47
|
+
* Tabs component slots
|
|
48
|
+
*/
|
|
14
49
|
export interface Ui3nTabsSlots {
|
|
50
|
+
/**
|
|
51
|
+
* Default slot
|
|
52
|
+
*/
|
|
15
53
|
default: () => VNode;
|
|
16
54
|
}
|
|
@@ -1,18 +1,59 @@
|
|
|
1
1
|
export interface Ui3nTextProps {
|
|
2
|
+
/**
|
|
3
|
+
* Text value
|
|
4
|
+
*/
|
|
2
5
|
modelValue: string;
|
|
6
|
+
/**
|
|
7
|
+
* Number of rows
|
|
8
|
+
*/
|
|
3
9
|
rows?: number;
|
|
10
|
+
/**
|
|
11
|
+
* Maximum number of rows
|
|
12
|
+
*/
|
|
4
13
|
maxRows?: number;
|
|
14
|
+
/**
|
|
15
|
+
* Text label
|
|
16
|
+
*/
|
|
5
17
|
label?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Text placeholder
|
|
20
|
+
*/
|
|
6
21
|
placeholder?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Validation rules
|
|
24
|
+
*/
|
|
7
25
|
rules?: Array<(v: string) => string | boolean>;
|
|
26
|
+
/**
|
|
27
|
+
* Whether to validate at startup
|
|
28
|
+
* @default false
|
|
29
|
+
*/
|
|
8
30
|
validateAtStartup?: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Whether text is disabled
|
|
33
|
+
* @default false
|
|
34
|
+
*/
|
|
9
35
|
disabled?: boolean;
|
|
10
36
|
}
|
|
11
37
|
export interface Ui3nTextEmits {
|
|
38
|
+
/**
|
|
39
|
+
* Called when text is initialized
|
|
40
|
+
*/
|
|
12
41
|
(event: 'init', value: HTMLTextAreaElement): void;
|
|
42
|
+
/**
|
|
43
|
+
* Called when text value changes
|
|
44
|
+
*/
|
|
13
45
|
(event: 'input', value: string): void;
|
|
46
|
+
/**
|
|
47
|
+
* Called when text value changes
|
|
48
|
+
*/
|
|
14
49
|
(event: 'change', value: string): void;
|
|
50
|
+
/**
|
|
51
|
+
* Called when key is pressed
|
|
52
|
+
*/
|
|
15
53
|
(event: 'keydown', value: KeyboardEvent): void;
|
|
54
|
+
/**
|
|
55
|
+
* Called when Enter key is pressed
|
|
56
|
+
*/
|
|
16
57
|
(event: 'enter', value: {
|
|
17
58
|
value: string;
|
|
18
59
|
altKey: boolean;
|
|
@@ -20,9 +61,24 @@ export interface Ui3nTextEmits {
|
|
|
20
61
|
shiftKey: boolean;
|
|
21
62
|
metaKey: boolean;
|
|
22
63
|
}): void;
|
|
64
|
+
/**
|
|
65
|
+
* Called when Escape key is pressed
|
|
66
|
+
*/
|
|
23
67
|
(event: 'escape', value: Event): void;
|
|
68
|
+
/**
|
|
69
|
+
* Called when text is focused
|
|
70
|
+
*/
|
|
24
71
|
(event: 'focus', value: Event): void;
|
|
72
|
+
/**
|
|
73
|
+
* Called when text loses focus
|
|
74
|
+
*/
|
|
25
75
|
(event: 'blur', value: Event): void;
|
|
76
|
+
/**
|
|
77
|
+
* Called when model value updates
|
|
78
|
+
*/
|
|
26
79
|
(event: 'update:modelValue', value: string): void;
|
|
80
|
+
/**
|
|
81
|
+
* Called when validation status updates
|
|
82
|
+
*/
|
|
27
83
|
(event: 'update:valid', value: boolean): void;
|
|
28
84
|
}
|
|
@@ -1,26 +1,95 @@
|
|
|
1
1
|
import { VNode } from 'vue';
|
|
2
|
+
/**
|
|
3
|
+
* Tooltip placement types
|
|
4
|
+
*/
|
|
2
5
|
export type Ui3nTooltipPlacement = 'top' | 'top-start' | 'top-end' | 'bottom' | 'bottom-start' | 'bottom-end' | 'right' | 'right-start' | 'right-end' | 'left' | 'left-start' | 'left-end';
|
|
6
|
+
/**
|
|
7
|
+
* Tooltip component properties
|
|
8
|
+
*/
|
|
3
9
|
export interface Ui3nTooltipProps {
|
|
10
|
+
/**
|
|
11
|
+
* Whether tooltip is open
|
|
12
|
+
*/
|
|
4
13
|
modelValue?: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Tooltip content
|
|
16
|
+
*/
|
|
5
17
|
content?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Maximum content width
|
|
20
|
+
*/
|
|
6
21
|
maxContentWidth?: number | string;
|
|
22
|
+
/**
|
|
23
|
+
* Tooltip color
|
|
24
|
+
*/
|
|
7
25
|
color?: string;
|
|
26
|
+
/**
|
|
27
|
+
* Tooltip text color
|
|
28
|
+
*/
|
|
8
29
|
textColor?: string;
|
|
30
|
+
/**
|
|
31
|
+
* Tooltip placement
|
|
32
|
+
*/
|
|
9
33
|
placement?: Ui3nTooltipPlacement;
|
|
34
|
+
/**
|
|
35
|
+
* Position strategy
|
|
36
|
+
* @default 'absolute'
|
|
37
|
+
*/
|
|
10
38
|
positionStrategy?: 'absolute' | 'fixed';
|
|
39
|
+
/**
|
|
40
|
+
* Offset X
|
|
41
|
+
*/
|
|
11
42
|
offsetX?: string | number;
|
|
43
|
+
/**
|
|
44
|
+
* Offset Y
|
|
45
|
+
*/
|
|
12
46
|
offsetY?: string | number;
|
|
47
|
+
/**
|
|
48
|
+
* Trigger type
|
|
49
|
+
* @default 'hover'
|
|
50
|
+
*/
|
|
13
51
|
trigger?: 'click' | 'hover' | 'manual';
|
|
52
|
+
/**
|
|
53
|
+
* Whether tooltip is disabled
|
|
54
|
+
* @default false
|
|
55
|
+
*/
|
|
14
56
|
disabled?: boolean;
|
|
15
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* Tooltip component emits
|
|
60
|
+
*/
|
|
16
61
|
export interface Ui3nTooltipEmits {
|
|
62
|
+
/**
|
|
63
|
+
* Called when tooltip is opening
|
|
64
|
+
*/
|
|
17
65
|
(ev: 'open'): void;
|
|
66
|
+
/**
|
|
67
|
+
* Called when tooltip is opened
|
|
68
|
+
*/
|
|
18
69
|
(ev: 'opened'): void;
|
|
70
|
+
/**
|
|
71
|
+
* Called when tooltip is closing
|
|
72
|
+
*/
|
|
19
73
|
(ev: 'close'): void;
|
|
74
|
+
/**
|
|
75
|
+
* Called when tooltip is closed
|
|
76
|
+
*/
|
|
20
77
|
(ev: 'closed'): void;
|
|
78
|
+
/**
|
|
79
|
+
* Emitted when model value updates
|
|
80
|
+
*/
|
|
21
81
|
(ev: 'update:modelValue', value: boolean): void;
|
|
22
82
|
}
|
|
83
|
+
/**
|
|
84
|
+
* Tooltip component slots
|
|
85
|
+
*/
|
|
23
86
|
export interface Ui3nTooltipSlots {
|
|
87
|
+
/**
|
|
88
|
+
* Default slot
|
|
89
|
+
*/
|
|
24
90
|
default: () => VNode;
|
|
91
|
+
/**
|
|
92
|
+
* Content slot
|
|
93
|
+
*/
|
|
25
94
|
content?: () => VNode;
|
|
26
95
|
}
|
|
@@ -1,10 +1,28 @@
|
|
|
1
1
|
import { VNode } from 'vue';
|
|
2
|
+
/**
|
|
3
|
+
* Virtual scroll component properties
|
|
4
|
+
*/
|
|
2
5
|
export interface Ui3nVirtualScrollProps<T> {
|
|
6
|
+
/**
|
|
7
|
+
* List of items to render
|
|
8
|
+
*/
|
|
3
9
|
items: T[];
|
|
10
|
+
/**
|
|
11
|
+
* Minimum height of child element
|
|
12
|
+
*/
|
|
4
13
|
minChildHeight: number;
|
|
14
|
+
/**
|
|
15
|
+
* Number of items to render ahead
|
|
16
|
+
*/
|
|
5
17
|
renderAhead?: number;
|
|
6
18
|
}
|
|
19
|
+
/**
|
|
20
|
+
* Virtual scroll component slots
|
|
21
|
+
*/
|
|
7
22
|
export interface Ui3nVirtualScrollSlots<T> {
|
|
23
|
+
/**
|
|
24
|
+
* Item slot
|
|
25
|
+
*/
|
|
8
26
|
item: ({ value, index }: {
|
|
9
27
|
value: T;
|
|
10
28
|
index: number;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { InjectionKey } from 'vue';
|
|
2
2
|
import { DialogsPlugin } from '../plugins/dialogs/types';
|
|
3
|
-
import { I18nPlugin } from '../plugins/i18n/types';
|
|
4
3
|
import { NotificationsPlugin } from '../plugins/notifications/types';
|
|
5
4
|
import { VueBusPlugin } from '../plugins/vue-bus/types';
|
|
6
5
|
export declare const DIALOGS_KEY: InjectionKey<DialogsPlugin>;
|
|
7
|
-
export declare const I18N_KEY: InjectionKey<I18nPlugin>;
|
|
8
6
|
export declare const NOTIFICATIONS_KEY: InjectionKey<NotificationsPlugin>;
|
|
9
7
|
export declare const VUEBUS_KEY: InjectionKey<VueBusPlugin<any>>;
|
package/dist/index.d.ts
CHANGED
|
@@ -59,9 +59,6 @@ declare module 'vue' {
|
|
|
59
59
|
$closeDialogs: () => void;
|
|
60
60
|
dialogStack: Ref<DialogOptions<any>[]>;
|
|
61
61
|
$createNotice: (params: Ui3nNotificationProps) => void;
|
|
62
|
-
$locale: string;
|
|
63
|
-
$tr: (key: string, placeholders?: Record<string, string>) => string;
|
|
64
|
-
$changeLocale: (lang: string) => void;
|
|
65
62
|
$emitter: VueEventBus<any>;
|
|
66
63
|
}
|
|
67
64
|
interface GlobalComponents {
|
|
@@ -121,10 +118,5 @@ declare module 'pinia' {
|
|
|
121
118
|
};
|
|
122
119
|
$createNotice: (params: Ui3nNotificationProps) => void;
|
|
123
120
|
$emitter: VueEventBus<any>;
|
|
124
|
-
$i18n: {
|
|
125
|
-
locale: string;
|
|
126
|
-
changeLocale: (lang: string) => void;
|
|
127
|
-
tr: (key: string, placeholders?: Record<string, string>) => string;
|
|
128
|
-
};
|
|
129
121
|
}
|
|
130
122
|
}
|
package/dist/plugins/index.d.ts
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
import { i18n } from './i18n/i18n';
|
|
2
|
-
import { I18nOptions, I18nPlugin } from './i18n/types';
|
|
3
1
|
import { notifications } from './notifications/notifications';
|
|
4
2
|
import { NotificationsPlugin } from './notifications/types';
|
|
5
3
|
import { vueBus } from './vue-bus/vue-bus';
|
|
6
4
|
import { VueBusPlugin } from './vue-bus/types';
|
|
7
5
|
import { default as dialogs } from './dialogs/dialogs';
|
|
8
6
|
import { DialogsPlugin, DialogOptions } from './dialogs/types';
|
|
9
|
-
import { storeI18n } from './i18n/store-i18n';
|
|
10
7
|
import { storeNotifications } from './notifications/store-notifications';
|
|
11
8
|
import { storeVueBus } from './vue-bus/store-vue-bus';
|
|
12
9
|
import { storeDialogs } from './dialogs/store-dialog';
|
|
13
|
-
export {
|
|
10
|
+
export { notifications, NotificationsPlugin, vueBus, VueBusPlugin, dialogs, DialogsPlugin, DialogOptions, storeNotifications, storeVueBus, storeDialogs, };
|