@pixelium/web-vue 0.0.3-beta → 0.0.4
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.d.ts +10 -1
- package/dist/pixelium-vue.cjs +2 -2
- package/dist/pixelium-vue.css +1 -1
- package/dist/pixelium-vue.js +563 -558
- package/dist/pixelium-vue.umd.cjs +2 -2
- package/es/alert/draw.d.ts +6 -0
- package/es/alert/index.d.ts +29 -0
- package/es/alert/type.d.ts +83 -0
- package/es/aside/index.css +1 -0
- package/es/aside/index.js +1 -1
- package/es/auto-complete/index.css +2 -2
- package/es/auto-complete/index.js +2 -2
- package/es/badge/draw.d.ts +1 -0
- package/es/badge/index.d.ts +25 -0
- package/es/badge/type.d.ts +69 -0
- package/es/button/index.css +1 -8
- package/es/button/index.js +4 -4
- package/es/button-group/index.js +2 -2
- package/es/checkbox/index.js +2 -2
- package/es/checkbox-group/index.js +1 -1
- package/es/col/index.js +1 -1
- package/es/container/index.css +1 -0
- package/es/dialog/dialog-wrapped.d.ts +52 -0
- package/es/dialog/dialog.d.ts +51 -0
- package/es/dialog/index.d.ts +5 -0
- package/es/dialog/type.d.ts +308 -0
- package/es/footer/index.css +1 -0
- package/es/form-item/index.css +0 -3
- package/es/form-item/index.js +1 -1
- package/es/grid-item/index.js +1 -1
- package/es/header/index.css +1 -0
- package/es/index.css +1 -1
- package/es/index.js +9 -8
- package/es/input/index.css +2 -2
- package/es/input/index.js +2 -2
- package/es/input-group/index.js +2 -2
- package/es/input-group-label/index.js +2 -2
- package/es/input-number/index.css +2 -2
- package/es/input-number/index.js +2 -2
- package/es/input-tag/index.css +2 -2
- package/es/input-tag/index.js +2 -2
- package/es/link/index.css +1 -6
- package/es/main/index.css +4 -0
- package/es/main/index.d.ts +4 -1
- package/es/main/index.js +7 -3
- package/es/main/type.d.ts +7 -0
- package/es/message-box/index.js +1 -1
- package/es/popconfirm/index.d.ts +31 -0
- package/es/popconfirm/type.d.ts +199 -0
- package/es/popup-portal/index.d.ts +15 -0
- package/es/popup-portal/type.d.ts +3 -0
- package/es/popup-wrapper/use-popup-wrapper-manager.d.ts +1 -0
- package/es/progress/draw.d.ts +6 -0
- package/es/progress/index.d.ts +31 -0
- package/es/progress/type.d.ts +67 -0
- package/es/radio/index.js +1 -1
- package/es/radio-group/index.js +1 -1
- package/es/select/index.css +2 -2
- package/es/select/index.js +2 -2
- package/es/share/hook/use-dark-mode.js +3 -3
- package/es/share/hook/use-polling.d.ts +2 -0
- package/es/share/hook/use-watch-global-css-var.js +2 -2
- package/es/share/style/index.css +5 -0
- package/es/share/util/locale.d.ts +50 -0
- package/es/slider/index.css +3 -0
- package/es/slider/index.js +1 -1
- package/es/switch/index.js +1 -1
- package/es/textarea/index.css +2 -2
- package/es/textarea/index.js +1 -1
- package/package.json +1 -1
- package/coverage/base.css +0 -224
- package/coverage/block-navigation.js +0 -87
- package/coverage/coverage-final.json +0 -106
- package/coverage/favicon.png +0 -0
- package/coverage/index.html +0 -926
- package/coverage/prettify.css +0 -1
- package/coverage/prettify.js +0 -2
- package/coverage/sort-arrow-sprite.png +0 -0
- package/coverage/sorter.js +0 -210
package/es/link/index.css
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
color: var(--text-color);
|
|
5
5
|
cursor: pointer;
|
|
6
6
|
transition: 0.25s;
|
|
7
|
+
outline-offset: var(--px-bit);
|
|
7
8
|
}
|
|
8
9
|
.px-link-icon-wrapper {
|
|
9
10
|
margin-right: 4px;
|
|
@@ -29,7 +30,6 @@
|
|
|
29
30
|
}
|
|
30
31
|
.px-link.px-link__primary:focus-visible {
|
|
31
32
|
outline-color: var(--px-primary-6);
|
|
32
|
-
outline-offset: var(--px-bit);
|
|
33
33
|
}
|
|
34
34
|
.px-link.px-link__primary.px-link__disabled {
|
|
35
35
|
--text-color: var(--px-primary-2);
|
|
@@ -53,7 +53,6 @@
|
|
|
53
53
|
}
|
|
54
54
|
.px-link.px-link__sakura:focus-visible {
|
|
55
55
|
outline-color: var(--px-sakura-6);
|
|
56
|
-
outline-offset: var(--px-bit);
|
|
57
56
|
}
|
|
58
57
|
.px-link.px-link__sakura.px-link__disabled {
|
|
59
58
|
--text-color: var(--px-sakura-2);
|
|
@@ -77,7 +76,6 @@
|
|
|
77
76
|
}
|
|
78
77
|
.px-link.px-link__success:focus-visible {
|
|
79
78
|
outline-color: var(--px-success-6);
|
|
80
|
-
outline-offset: var(--px-bit);
|
|
81
79
|
}
|
|
82
80
|
.px-link.px-link__success.px-link__disabled {
|
|
83
81
|
--text-color: var(--px-success-2);
|
|
@@ -101,7 +99,6 @@
|
|
|
101
99
|
}
|
|
102
100
|
.px-link.px-link__warning:focus-visible {
|
|
103
101
|
outline-color: var(--px-warning-6);
|
|
104
|
-
outline-offset: var(--px-bit);
|
|
105
102
|
}
|
|
106
103
|
.px-link.px-link__warning.px-link__disabled {
|
|
107
104
|
--text-color: var(--px-warning-2);
|
|
@@ -125,7 +122,6 @@
|
|
|
125
122
|
}
|
|
126
123
|
.px-link.px-link__danger:focus-visible {
|
|
127
124
|
outline-color: var(--px-danger-6);
|
|
128
|
-
outline-offset: var(--px-bit);
|
|
129
125
|
}
|
|
130
126
|
.px-link.px-link__danger.px-link__disabled {
|
|
131
127
|
--text-color: var(--px-danger-2);
|
|
@@ -149,7 +145,6 @@
|
|
|
149
145
|
}
|
|
150
146
|
.px-link.px-link__info:focus-visible {
|
|
151
147
|
outline-color: var(--px-neutral-10);
|
|
152
|
-
outline-offset: var(--px-bit);
|
|
153
148
|
}
|
|
154
149
|
.px-link.px-link__info.px-link__disabled {
|
|
155
150
|
--text-color: var(--px-neutral-6);
|
package/es/main/index.css
CHANGED
package/es/main/index.d.ts
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
|
+
import type { MainProps } from './type';
|
|
1
2
|
declare var __VLS_1: {};
|
|
2
3
|
type __VLS_Slots = {} & {
|
|
3
4
|
default?: (props: typeof __VLS_1) => any;
|
|
4
5
|
};
|
|
5
|
-
declare const __VLS_component: import("vue").DefineComponent<
|
|
6
|
+
declare const __VLS_component: import("vue").DefineComponent<MainProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MainProps> & Readonly<{}>, {
|
|
7
|
+
soft: boolean;
|
|
8
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
6
9
|
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
7
10
|
export default _default;
|
|
8
11
|
type __VLS_WithSlots<T, S> = T & {
|
package/es/main/index.js
CHANGED
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import './css.js'
|
|
2
|
-
import { createElementBlock, defineComponent, openBlock, renderSlot } from "vue";
|
|
3
|
-
var _hoisted_1 = { class: "pixelium px-main" };
|
|
2
|
+
import { createElementBlock, defineComponent, normalizeClass, openBlock, renderSlot } from "vue";
|
|
4
3
|
var main_default = /* @__PURE__ */ defineComponent({
|
|
5
4
|
name: "Main",
|
|
6
5
|
__name: "index",
|
|
6
|
+
props: { soft: {
|
|
7
|
+
type: Boolean,
|
|
8
|
+
default: false
|
|
9
|
+
} },
|
|
7
10
|
setup(__props) {
|
|
11
|
+
const props = __props;
|
|
8
12
|
return (_ctx, _cache) => {
|
|
9
|
-
return openBlock(), createElementBlock("main",
|
|
13
|
+
return openBlock(), createElementBlock("main", { class: normalizeClass(["pixelium px-main", { "px-main__soft": props.soft }]) }, [renderSlot(_ctx.$slots, "default")], 2);
|
|
10
14
|
};
|
|
11
15
|
}
|
|
12
16
|
});
|
package/es/main/type.d.ts
CHANGED
package/es/message-box/index.js
CHANGED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { PopconfirmProps, PopconfirmExpose } from './type';
|
|
2
|
+
type __VLS_Props = PopconfirmProps & {
|
|
3
|
+
onBeforeOk?: () => Promise<boolean | void> | boolean | void;
|
|
4
|
+
};
|
|
5
|
+
declare const _default: import("vue").DefineComponent<__VLS_Props, PopconfirmExpose, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
6
|
+
cancel: (event: MouseEvent | KeyboardEvent) => any;
|
|
7
|
+
close: (e: MouseEvent | TouchEvent) => any;
|
|
8
|
+
open: (e: MouseEvent) => any;
|
|
9
|
+
"update:visible": (value: boolean) => any;
|
|
10
|
+
ok: (event: MouseEvent) => any;
|
|
11
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
12
|
+
onCancel?: ((event: MouseEvent | KeyboardEvent) => any) | undefined;
|
|
13
|
+
onClose?: ((e: MouseEvent | TouchEvent) => any) | undefined;
|
|
14
|
+
onOpen?: ((e: MouseEvent) => any) | undefined;
|
|
15
|
+
"onUpdate:visible"?: ((value: boolean) => any) | undefined;
|
|
16
|
+
onOk?: ((event: MouseEvent) => any) | undefined;
|
|
17
|
+
}>, {
|
|
18
|
+
variant: "dark" | "light";
|
|
19
|
+
loading: boolean;
|
|
20
|
+
placement: "top" | "right" | "bottom" | "left" | "top-start" | "top-end" | "right-start" | "right-end" | "bottom-start" | "bottom-end" | "left-start" | "left-end";
|
|
21
|
+
root: HTMLElement | string;
|
|
22
|
+
offset: number;
|
|
23
|
+
visible: boolean | null;
|
|
24
|
+
defaultVisible: boolean | null;
|
|
25
|
+
arrow: boolean;
|
|
26
|
+
destroyOnHide: boolean;
|
|
27
|
+
showCancel: boolean;
|
|
28
|
+
showFooter: boolean;
|
|
29
|
+
showIcon: boolean;
|
|
30
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
31
|
+
export default _default;
|
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
import type { ButtonProps, ButtonEvents } from '../button/type';
|
|
2
|
+
import type { PopoverEvents, PopoverProps } from '../popover/type';
|
|
3
|
+
import type { EmitEvent, RestAttrs } from '../share/type';
|
|
4
|
+
export type PopconfirmProps = {
|
|
5
|
+
/**
|
|
6
|
+
* @property {string} [content]
|
|
7
|
+
* @version 0.0.4
|
|
8
|
+
*/
|
|
9
|
+
content?: string;
|
|
10
|
+
/**
|
|
11
|
+
* @property {boolean | null} [visible]
|
|
12
|
+
* @version 0.0.4
|
|
13
|
+
*/
|
|
14
|
+
visible?: boolean | null;
|
|
15
|
+
/**
|
|
16
|
+
* @property {boolean | null} [defaultVisible]
|
|
17
|
+
* @version 0.0.4
|
|
18
|
+
*/
|
|
19
|
+
defaultVisible?: boolean | null;
|
|
20
|
+
/**
|
|
21
|
+
* @property {boolean} [loading=false]
|
|
22
|
+
* @version 0.0.4
|
|
23
|
+
*/
|
|
24
|
+
loading?: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* @property {'top' | 'right' | 'bottom' | 'left' | 'top-start' | 'top-end' | 'right-start' | 'right-end' | 'bottom-start' | 'bottom-end' | 'left-start' | 'left-end'} [placement='top']
|
|
27
|
+
* @version 0.0.4
|
|
28
|
+
*/
|
|
29
|
+
placement?: 'top' | 'right' | 'bottom' | 'left' | 'top-start' | 'top-end' | 'right-start' | 'right-end' | 'bottom-start' | 'bottom-end' | 'left-start' | 'left-end';
|
|
30
|
+
/**
|
|
31
|
+
* @property {string} [okText]
|
|
32
|
+
* @version 0.0.4
|
|
33
|
+
*/
|
|
34
|
+
okText?: string;
|
|
35
|
+
/**
|
|
36
|
+
* @property {string} [cancelText]
|
|
37
|
+
* @version 0.0.4
|
|
38
|
+
*/
|
|
39
|
+
cancelText?: string;
|
|
40
|
+
/**
|
|
41
|
+
* @property {boolean} [showIcon=true]
|
|
42
|
+
* @version 0.0.4
|
|
43
|
+
*/
|
|
44
|
+
showIcon?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* @property {boolean} [showCancel=true]
|
|
47
|
+
* @version 0.0.4
|
|
48
|
+
*/
|
|
49
|
+
showCancel?: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* @property {boolean} [showFooter=true]
|
|
52
|
+
* @version 0.0.4
|
|
53
|
+
*/
|
|
54
|
+
showFooter?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* @property {number} [offset=8]
|
|
57
|
+
* @version 0.0.4
|
|
58
|
+
*/
|
|
59
|
+
offset?: number;
|
|
60
|
+
/**
|
|
61
|
+
* @property {'dark' | 'light'} [variant='light']
|
|
62
|
+
* @version 0.0.4
|
|
63
|
+
*/
|
|
64
|
+
variant?: 'dark' | 'light';
|
|
65
|
+
/**
|
|
66
|
+
* @property {boolean} [arrow=true]
|
|
67
|
+
* @version 0.0.4
|
|
68
|
+
*/
|
|
69
|
+
arrow?: boolean;
|
|
70
|
+
/**
|
|
71
|
+
* @property {boolean} [disabled=false]
|
|
72
|
+
* @version 0.0.4
|
|
73
|
+
*/
|
|
74
|
+
disabled?: boolean;
|
|
75
|
+
/**
|
|
76
|
+
* @property {number} [zIndex]
|
|
77
|
+
* @version 0.0.4
|
|
78
|
+
*/
|
|
79
|
+
zIndex?: number;
|
|
80
|
+
/**
|
|
81
|
+
* @property { HTMLElement | string} [root='body']
|
|
82
|
+
* @version 0.0.4
|
|
83
|
+
*/
|
|
84
|
+
root?: HTMLElement | string;
|
|
85
|
+
/**
|
|
86
|
+
* @property {boolean} [destroyOnHide=false]
|
|
87
|
+
* @version 0.0.4
|
|
88
|
+
*/
|
|
89
|
+
destroyOnHide?: boolean;
|
|
90
|
+
/**
|
|
91
|
+
* @property {Omit<PopoverProps, 'visible' | 'content' | 'defaultVisible'> & EmitEvent<PopoverEvents>} [popoverProps]
|
|
92
|
+
* @version 0.0.4
|
|
93
|
+
*/
|
|
94
|
+
popoverProps?: Omit<PopoverProps, 'visible' | 'content' | 'defaultVisible'> & EmitEvent<PopoverEvents>;
|
|
95
|
+
/**
|
|
96
|
+
* @property {ButtonProps & EmitEvent<ButtonEvents> & RestAttrs} [okButtonProps]
|
|
97
|
+
* @version 0.0.4
|
|
98
|
+
*/
|
|
99
|
+
okButtonProps?: ButtonProps & EmitEvent<ButtonEvents> & RestAttrs;
|
|
100
|
+
/**
|
|
101
|
+
* @property {ButtonProps & EmitEvent<ButtonEvents> & RestAttrs} [cancelButtonProps]
|
|
102
|
+
* @version 0.0.4
|
|
103
|
+
*/
|
|
104
|
+
cancelButtonProps?: ButtonProps & EmitEvent<ButtonEvents> & RestAttrs;
|
|
105
|
+
/**
|
|
106
|
+
* @property {RestAttrs} [containerProps]
|
|
107
|
+
* @version 0.0.4
|
|
108
|
+
*/
|
|
109
|
+
containerProps?: RestAttrs;
|
|
110
|
+
/**
|
|
111
|
+
* @property {RestAttrs} [contentProps]
|
|
112
|
+
* @version 0.0.4
|
|
113
|
+
*/
|
|
114
|
+
contentProps?: RestAttrs;
|
|
115
|
+
/**
|
|
116
|
+
* @property {RestAttrs} [footerProps]
|
|
117
|
+
* @version 0.0.4
|
|
118
|
+
*/
|
|
119
|
+
footerProps?: RestAttrs;
|
|
120
|
+
};
|
|
121
|
+
export type PopconfirmEvents = {
|
|
122
|
+
/**
|
|
123
|
+
* @event update:visible
|
|
124
|
+
* @param {boolean} value
|
|
125
|
+
* @version 0.0.2
|
|
126
|
+
*/
|
|
127
|
+
'update:visible': [value: boolean];
|
|
128
|
+
/**
|
|
129
|
+
* @event beforeOk
|
|
130
|
+
* @version 0.0.4
|
|
131
|
+
*/
|
|
132
|
+
beforeOk: [];
|
|
133
|
+
/**
|
|
134
|
+
* @event ok
|
|
135
|
+
* @param {MouseEvent} event
|
|
136
|
+
* @version 0.0.4
|
|
137
|
+
*/
|
|
138
|
+
ok: [event: MouseEvent];
|
|
139
|
+
/**
|
|
140
|
+
* @event cancel
|
|
141
|
+
* @param {MouseEvent | KeyboardEvent} event
|
|
142
|
+
* @version 0.0.4
|
|
143
|
+
*/
|
|
144
|
+
cancel: [event: MouseEvent | KeyboardEvent];
|
|
145
|
+
/**
|
|
146
|
+
* @event close
|
|
147
|
+
* @param {MouseEvent} e
|
|
148
|
+
* @version 0.0.2
|
|
149
|
+
*/
|
|
150
|
+
close: [e: MouseEvent | TouchEvent];
|
|
151
|
+
/**
|
|
152
|
+
* @event open
|
|
153
|
+
* @param {MouseEvent} e
|
|
154
|
+
* @version 0.0.2
|
|
155
|
+
*/
|
|
156
|
+
open: [e: MouseEvent];
|
|
157
|
+
};
|
|
158
|
+
export type PopconfirmSlots = {
|
|
159
|
+
/**
|
|
160
|
+
* @slot default
|
|
161
|
+
* @version 0.0.4
|
|
162
|
+
*/
|
|
163
|
+
default: {};
|
|
164
|
+
/**
|
|
165
|
+
* @slot content
|
|
166
|
+
* @version 0.0.4
|
|
167
|
+
*/
|
|
168
|
+
content: {};
|
|
169
|
+
/**
|
|
170
|
+
* @slot icon
|
|
171
|
+
* @version 0.0.4
|
|
172
|
+
*/
|
|
173
|
+
icon: {};
|
|
174
|
+
/**
|
|
175
|
+
* @slot footer
|
|
176
|
+
* @version 0.0.4
|
|
177
|
+
*/
|
|
178
|
+
footer: {};
|
|
179
|
+
};
|
|
180
|
+
export type PopconfirmExpose = {
|
|
181
|
+
/**
|
|
182
|
+
* @property {() => void} open
|
|
183
|
+
* @version 0.0.4
|
|
184
|
+
*/
|
|
185
|
+
open: () => void;
|
|
186
|
+
/**
|
|
187
|
+
* @property {() => void} close
|
|
188
|
+
* @version 0.0.4
|
|
189
|
+
*/
|
|
190
|
+
close: () => void;
|
|
191
|
+
/**
|
|
192
|
+
* @ignore
|
|
193
|
+
*/
|
|
194
|
+
updateRenderState: () => void;
|
|
195
|
+
/**
|
|
196
|
+
* @ignore
|
|
197
|
+
*/
|
|
198
|
+
triggerContent: any;
|
|
199
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { PopupPortalProps } from './type';
|
|
2
|
+
declare var __VLS_6: {};
|
|
3
|
+
type __VLS_Slots = {} & {
|
|
4
|
+
default?: (props: typeof __VLS_6) => any;
|
|
5
|
+
};
|
|
6
|
+
declare const __VLS_component: import("vue").DefineComponent<PopupPortalProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<PopupPortalProps> & Readonly<{}>, {
|
|
7
|
+
root: HTMLElement | string;
|
|
8
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
10
|
+
export default _default;
|
|
11
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
12
|
+
new (): {
|
|
13
|
+
$slots: S;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const usePopupWrapperManager: (id: string) => readonly [() => void, () => void];
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { RgbaColor } from '../share/type';
|
|
2
|
+
import type { ProgressProps } from './type';
|
|
3
|
+
export declare function getBackgroundColor(theme: ProgressProps['theme'], palette: RgbaColor[] | null): RgbaColor | null;
|
|
4
|
+
export declare function getGradientColor(theme: ProgressProps['theme'], palette: RgbaColor[] | null): RgbaColor | null;
|
|
5
|
+
export declare const drawBorder: (ctx: CanvasRenderingContext2D, width: number, height: number, borderColor: RgbaColor, pixelSize: number) => void;
|
|
6
|
+
export declare const drawChecker: (ctx: CanvasRenderingContext2D, width: number, height: number, checkerWidth: number, gradientColor: string, borderWidth: number, padding: number, progress: number) => void;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { ProgressProps } from './type';
|
|
2
|
+
declare var __VLS_1: {
|
|
3
|
+
percentage: number;
|
|
4
|
+
}, __VLS_3: {
|
|
5
|
+
percentage: number;
|
|
6
|
+
}, __VLS_5: {
|
|
7
|
+
percentage: number;
|
|
8
|
+
};
|
|
9
|
+
type __VLS_Slots = {} & {
|
|
10
|
+
prepend?: (props: typeof __VLS_1) => any;
|
|
11
|
+
} & {
|
|
12
|
+
indicator?: (props: typeof __VLS_3) => any;
|
|
13
|
+
} & {
|
|
14
|
+
append?: (props: typeof __VLS_5) => any;
|
|
15
|
+
};
|
|
16
|
+
declare const __VLS_component: import("vue").DefineComponent<ProgressProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<ProgressProps> & Readonly<{}>, {
|
|
17
|
+
size: "medium" | "large" | "small" | number;
|
|
18
|
+
variant: "solid" | "checker";
|
|
19
|
+
theme: "primary" | "sakura" | "success" | "warning" | "danger";
|
|
20
|
+
pollSizeChange: boolean;
|
|
21
|
+
gap: number;
|
|
22
|
+
percentage: number;
|
|
23
|
+
indicatorPlacement: "inside" | "outside";
|
|
24
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
25
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
26
|
+
export default _default;
|
|
27
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
28
|
+
new (): {
|
|
29
|
+
$slots: S;
|
|
30
|
+
};
|
|
31
|
+
};
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
export type ProgressProps = {
|
|
2
|
+
/**
|
|
3
|
+
* @property {number} [percentage=0]
|
|
4
|
+
* @version 0.0.4
|
|
5
|
+
*/
|
|
6
|
+
percentage?: number;
|
|
7
|
+
/**
|
|
8
|
+
* @property {'solid' | 'checker'} [variant='solid']
|
|
9
|
+
* @version 0.0.4
|
|
10
|
+
*/
|
|
11
|
+
variant?: 'solid' | 'checker';
|
|
12
|
+
/**
|
|
13
|
+
* @property {'primary' | 'sakura' | 'success' | 'warning' | 'danger'} [theme='primary']
|
|
14
|
+
* @version 0.0.4
|
|
15
|
+
*/
|
|
16
|
+
theme?: 'primary' | 'sakura' | 'success' | 'warning' | 'danger';
|
|
17
|
+
/**
|
|
18
|
+
* @property {'medium' | 'large' | 'small'} [size='medium']
|
|
19
|
+
* @version 0.0.4
|
|
20
|
+
*/
|
|
21
|
+
size?: 'medium' | 'large' | 'small' | number;
|
|
22
|
+
/**
|
|
23
|
+
* @property {number} [gap=2]
|
|
24
|
+
* @version 0.0.4
|
|
25
|
+
*/
|
|
26
|
+
gap?: number;
|
|
27
|
+
/**
|
|
28
|
+
* @property {'inside' | 'outside'} [indicatorPlacement='inside']
|
|
29
|
+
* @version 0.0.4
|
|
30
|
+
*/
|
|
31
|
+
indicatorPlacement?: 'inside' | 'outside';
|
|
32
|
+
/**
|
|
33
|
+
* @property {string} [color]
|
|
34
|
+
* @version 0.0.4
|
|
35
|
+
*/
|
|
36
|
+
color?: string;
|
|
37
|
+
/**
|
|
38
|
+
* @property {string} [color]
|
|
39
|
+
* @version 0.0.4
|
|
40
|
+
*/
|
|
41
|
+
trackColor?: string;
|
|
42
|
+
/**
|
|
43
|
+
* @property {boolean} [pollSizeChange=false]
|
|
44
|
+
* @version 0.0.4
|
|
45
|
+
*/
|
|
46
|
+
pollSizeChange?: boolean;
|
|
47
|
+
};
|
|
48
|
+
export type ProgressSlots = {
|
|
49
|
+
/**
|
|
50
|
+
* @slot append
|
|
51
|
+
* @param {number} percentage
|
|
52
|
+
* @version 0.0.4
|
|
53
|
+
*/
|
|
54
|
+
append: {};
|
|
55
|
+
/**
|
|
56
|
+
* @slot prepend
|
|
57
|
+
* @param {number} percentage
|
|
58
|
+
* @version 0.0.4
|
|
59
|
+
*/
|
|
60
|
+
prepend: {};
|
|
61
|
+
/**
|
|
62
|
+
* @slot indicator
|
|
63
|
+
* @param {number} percentage
|
|
64
|
+
* @version 0.0.4
|
|
65
|
+
*/
|
|
66
|
+
indicator: {};
|
|
67
|
+
};
|
package/es/radio/index.js
CHANGED
|
@@ -58,7 +58,7 @@ var radio_default = /* @__PURE__ */ defineComponent({
|
|
|
58
58
|
transform: (val) => !!val
|
|
59
59
|
});
|
|
60
60
|
const formItemProvide = inject(FORM_ITEM_PROVIDE, void 0);
|
|
61
|
-
const radioGroupProvide = inject(RADIO_GROUP_PROVIDE);
|
|
61
|
+
const radioGroupProvide = inject(RADIO_GROUP_PROVIDE, void 0);
|
|
62
62
|
const sizeComputed = createProvideComputed("size", () => [
|
|
63
63
|
radioGroupProvide,
|
|
64
64
|
props.size && props,
|
package/es/radio-group/index.js
CHANGED
|
@@ -29,7 +29,7 @@ var radio_group_default = /* @__PURE__ */ defineComponent({
|
|
|
29
29
|
setup(__props, { emit: __emit }) {
|
|
30
30
|
const props = __props;
|
|
31
31
|
const emits = __emit;
|
|
32
|
-
const formItemProvide = inject(FORM_ITEM_PROVIDE);
|
|
32
|
+
const formItemProvide = inject(FORM_ITEM_PROVIDE, void 0);
|
|
33
33
|
const disabledComputed = createProvideComputed("disabled", [formItemProvide, props], "or");
|
|
34
34
|
const readonlyComputed = createProvideComputed("readonly", [formItemProvide, props], "or");
|
|
35
35
|
const [modelValue, updateModelValue] = useControlledMode("modelValue", props, emits, {
|
package/es/select/index.css
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
min-height: var(--select-size);
|
|
13
13
|
cursor: text;
|
|
14
14
|
transition: 0.25s;
|
|
15
|
+
flex-grow: 1;
|
|
15
16
|
}
|
|
16
17
|
.px-select.px-select__small {
|
|
17
18
|
padding-right: 8px;
|
|
@@ -133,8 +134,7 @@
|
|
|
133
134
|
flex-shrink: 0;
|
|
134
135
|
}
|
|
135
136
|
.px-select-inner:focus-visible {
|
|
136
|
-
outline
|
|
137
|
-
outline-offset: var(--px-bit);
|
|
137
|
+
outline: none;
|
|
138
138
|
}
|
|
139
139
|
.px-select-label,
|
|
140
140
|
.px-select-content,
|
package/es/select/index.js
CHANGED
|
@@ -119,8 +119,8 @@ var select_default = /* @__PURE__ */ defineComponent({
|
|
|
119
119
|
ref(false),
|
|
120
120
|
ref(false)
|
|
121
121
|
];
|
|
122
|
-
const inputGroupProvide = inject(INPUT_GROUP_PROVIDE);
|
|
123
|
-
const formItemProvide = inject(FORM_ITEM_PROVIDE);
|
|
122
|
+
const inputGroupProvide = inject(INPUT_GROUP_PROVIDE, void 0);
|
|
123
|
+
const formItemProvide = inject(FORM_ITEM_PROVIDE, void 0);
|
|
124
124
|
const borderRadiusComputed = createProvideComputed("borderRadius", [innerInputGroup.value && inputGroupProvide, props]);
|
|
125
125
|
const sizeComputed = createProvideComputed("size", () => [
|
|
126
126
|
innerInputGroup.value && inputGroupProvide,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as inBrowser } from "../util/env.js";
|
|
1
|
+
import { n as inVitest, t as inBrowser } from "../util/env.js";
|
|
2
2
|
import { computed, onBeforeUnmount, onMounted, ref } from "vue";
|
|
3
3
|
var observerMap = /* @__PURE__ */ new WeakMap();
|
|
4
4
|
var observerCallbacksMap = /* @__PURE__ */ new WeakMap();
|
|
@@ -14,7 +14,7 @@ const useDarkMode = () => {
|
|
|
14
14
|
function handleDarkModeChange(e) {
|
|
15
15
|
darkMode.value = e.matches;
|
|
16
16
|
}
|
|
17
|
-
if (inBrowser()) {
|
|
17
|
+
if (inBrowser() && !inVitest()) {
|
|
18
18
|
const darkModeQuery = window.matchMedia("(prefers-color-scheme: dark)");
|
|
19
19
|
handleDarkModeChange(darkModeQuery);
|
|
20
20
|
darkModeQuery.addEventListener("change", handleDarkModeChange);
|
|
@@ -32,7 +32,7 @@ const useDarkMode = () => {
|
|
|
32
32
|
darkModeHtml.value = hasDark ? true : hasLight ? false : void 0;
|
|
33
33
|
}
|
|
34
34
|
};
|
|
35
|
-
if (inBrowser()) {
|
|
35
|
+
if (inBrowser() && !inVitest()) {
|
|
36
36
|
onMounted(() => {
|
|
37
37
|
const observer = observerMap.get(document.documentElement) || new MutationObserver(runCallbacks(document.documentElement));
|
|
38
38
|
observerMap.set(document.documentElement, observer);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { t as inBrowser } from "../util/env.js";
|
|
1
|
+
import { n as inVitest, t as inBrowser } from "../util/env.js";
|
|
2
2
|
import { t as EventBus } from "../util/event-bus.js";
|
|
3
3
|
import { n as GLOBAL_CSS_VAR_CHANGE } from "../const/event-bus-key.js";
|
|
4
4
|
import { onBeforeUnmount } from "vue";
|
|
5
5
|
const useWatchGlobalCssVal = (callback) => {
|
|
6
|
-
if (!inBrowser()) return;
|
|
6
|
+
if (!inBrowser() || inVitest()) return;
|
|
7
7
|
const cb = () => {
|
|
8
8
|
callback();
|
|
9
9
|
};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
// Generated by dts-bundle-generator v9.5.1
|
|
2
|
+
|
|
3
|
+
import { Emitter } from 'mitt';
|
|
4
|
+
|
|
5
|
+
declare const _default: {
|
|
6
|
+
dialog: {
|
|
7
|
+
confirm: string;
|
|
8
|
+
cancel: string;
|
|
9
|
+
infoTitle: string;
|
|
10
|
+
successTitle: string;
|
|
11
|
+
warningTitle: string;
|
|
12
|
+
errorTitle: string;
|
|
13
|
+
confirmTitle: string;
|
|
14
|
+
};
|
|
15
|
+
popconfirm: {
|
|
16
|
+
confirm: string;
|
|
17
|
+
cancel: string;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
export type DeepPartial<T> = {
|
|
21
|
+
[K in keyof T]?: T[K] extends object ? DeepPartial<T[K]> : T[K];
|
|
22
|
+
};
|
|
23
|
+
export type Events = {
|
|
24
|
+
"lang-change": string;
|
|
25
|
+
};
|
|
26
|
+
export type LangMessages = typeof _default;
|
|
27
|
+
declare class LocaleManager {
|
|
28
|
+
private currentLang;
|
|
29
|
+
private emitter;
|
|
30
|
+
constructor();
|
|
31
|
+
getCurrentLang(): string;
|
|
32
|
+
setLocale(lang: string): void;
|
|
33
|
+
addMessages(lang: string, msg: DeepPartial<LangMessages>): void;
|
|
34
|
+
t(path: string, fallback?: string): string;
|
|
35
|
+
getMessages(lang: string): LangMessages;
|
|
36
|
+
getEmitter(): Emitter<Events>;
|
|
37
|
+
}
|
|
38
|
+
declare const localeManager: LocaleManager;
|
|
39
|
+
export declare const t: (path: string, fallback?: string) => string;
|
|
40
|
+
export declare function useLocale(): readonly [
|
|
41
|
+
(path: string, fallback?: string) => string,
|
|
42
|
+
(lang: string) => void,
|
|
43
|
+
import("vue").Ref<string, string>
|
|
44
|
+
];
|
|
45
|
+
|
|
46
|
+
export {
|
|
47
|
+
localeManager as locale,
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
export {};
|
package/es/slider/index.css
CHANGED
package/es/slider/index.js
CHANGED
|
@@ -72,7 +72,7 @@ var slider_default = /* @__PURE__ */ defineComponent({
|
|
|
72
72
|
setup(__props, { emit: __emit }) {
|
|
73
73
|
const props = __props;
|
|
74
74
|
const emits = __emit;
|
|
75
|
-
const formItemProvide = inject(FORM_ITEM_PROVIDE);
|
|
75
|
+
const formItemProvide = inject(FORM_ITEM_PROVIDE, void 0);
|
|
76
76
|
const disabledComputed = createProvideComputed("disabled", [formItemProvide, props], "or");
|
|
77
77
|
const readonlyComputed = createProvideComputed("readonly", [formItemProvide, props], "or");
|
|
78
78
|
const [modelValue, updateModelValue] = useControlledMode("modelValue", props, emits, {
|
package/es/switch/index.js
CHANGED
|
@@ -81,7 +81,7 @@ var switch_default = /* @__PURE__ */ defineComponent({
|
|
|
81
81
|
return !!nextValue;
|
|
82
82
|
}
|
|
83
83
|
});
|
|
84
|
-
const formItemProvide = inject(FORM_ITEM_PROVIDE);
|
|
84
|
+
const formItemProvide = inject(FORM_ITEM_PROVIDE, void 0);
|
|
85
85
|
const disabledComputed = createProvideComputed("disabled", [formItemProvide, props], "or");
|
|
86
86
|
const readonlyComputed = createProvideComputed("readonly", [formItemProvide, props], "or");
|
|
87
87
|
const sizeComputed = createProvideComputed("size", () => [
|