prlg-ui 1.8.58 → 1.8.60
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/{eventBus.util-CJIdWFx0.js → eventBus.util-ClEh5UYl.js} +3 -3
- package/dist/{eventBus.util-B6o8_37h.cjs → eventBus.util-DRia0POu.cjs} +1 -1
- package/dist/index.d.ts +90 -5
- package/dist/prlg-ui.cjs.js +1 -1
- package/dist/prlg-ui.css +1 -1
- package/dist/prlg-ui.es.js +3026 -2621
- package/dist/utils/index.cjs.js +1 -1
- package/dist/utils/index.es.js +1 -1
- package/dist/utils.d.ts +3 -3
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const o=require("vue");let s=null;function u(){const e=window.scrollY;return document.body.style.position="fixed",document.body.style.top=`-${e}px`,()=>{document.body.style.position="",document.body.style.top="",window.scrollTo(0,e)}}const d=()=>{s||(s=u())},i=()=>{s&&(s(),s=null)},f=()=>({unlockScroll:i,lockScroll:d}),a={BASE:1e3,DROPDOWN:1010,STICKY:1020,
|
|
1
|
+
"use strict";const o=require("vue");let s=null;function u(){const e=window.scrollY;return document.body.style.position="fixed",document.body.style.top=`-${e}px`,()=>{document.body.style.position="",document.body.style.top="",window.scrollTo(0,e)}}const d=()=>{s||(s=u())},i=()=>{s&&(s(),s=null)},f=()=>({unlockScroll:i,lockScroll:d}),a={BASE:1e3,DROPDOWN:1010,STICKY:1020,TOOLTIP:1030,POPOVER:1040,DRAWER:1050,MODAL:1060,NOTIFICATION:1070,DEBUG:9999},y=Symbol("z-index-context");let c=a.BASE;function p(){const e=o.inject(y,null);return e||{currentLayer:o.ref(c),getNextLayer:()=>(c+=10,c)}}const S=["data-layer"],m=o.defineComponent({__name:"Portal",props:{layer:{default:"BASE"},teleport:{type:Boolean,default:!0},target:{default:"body"},zIndex:{},show:{type:Boolean,default:!0}},setup(e){const t=e,{getNextLayer:l}=p(),n=o.computed(()=>t.zIndex?t.zIndex:t.layer&&t.layer!=="BASE"?a[t.layer]:l());return(r,B)=>r.show?(o.openBlock(),o.createBlock(o.Teleport,{key:0,to:r.target,disabled:!r.teleport},[o.createElementVNode("div",{style:o.normalizeStyle({zIndex:n.value,position:"relative"}),"data-layer":r.layer},[o.renderSlot(r.$slots,"default")],12,S)],8,["to","disabled"])):o.createCommentVNode("",!0)}});function E(){const e=new Map;return{on(t,l){const n=e.get(t)||[];n.push(l),e.set(t,n)},off(t,l){const n=e.get(t);n&&e.set(t,n.filter(r=>r!==l))},emit(t,l){const n=e.get(t);n&&n.forEach(r=>r(l))},clear(){e.clear()}}}exports.EventBus=E;exports._sfc_main=m;exports.useBodyScroll=f;
|
package/dist/index.d.ts
CHANGED
|
@@ -139,7 +139,7 @@ modelValue: boolean;
|
|
|
139
139
|
placement: Placement;
|
|
140
140
|
arrowVisible: boolean;
|
|
141
141
|
closeMode: PopoverCloseMode;
|
|
142
|
-
zIndexLayer: "BASE" | "DROPDOWN" | "STICKY" | "
|
|
142
|
+
zIndexLayer: "BASE" | "DROPDOWN" | "STICKY" | "TOOLTIP" | "POPOVER" | "DRAWER" | "MODAL" | "NOTIFICATION" | "DEBUG";
|
|
143
143
|
withoutStyle: boolean;
|
|
144
144
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {
|
|
145
145
|
reference: HTMLDivElement;
|
|
@@ -237,6 +237,23 @@ declare const __VLS_component_23: DefineComponent<__VLS_Props_33, {}, {}, {}, {}
|
|
|
237
237
|
|
|
238
238
|
declare const __VLS_component_24: DefineComponent<__VLS_Props_34, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props_34> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
239
239
|
|
|
240
|
+
declare const __VLS_component_25: DefineComponent<ScheduleProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {} & {
|
|
241
|
+
clear: () => any;
|
|
242
|
+
change: (value: DayOfWeek[]) => any;
|
|
243
|
+
"update:modelValue": (value: DayOfWeek[]) => any;
|
|
244
|
+
}, string, PublicProps, Readonly<ScheduleProps> & Readonly<{
|
|
245
|
+
onClear?: (() => any) | undefined;
|
|
246
|
+
onChange?: ((value: DayOfWeek[]) => any) | undefined;
|
|
247
|
+
"onUpdate:modelValue"?: ((value: DayOfWeek[]) => any) | undefined;
|
|
248
|
+
}>, {
|
|
249
|
+
disabled: boolean;
|
|
250
|
+
placeholder: string;
|
|
251
|
+
clearable: boolean;
|
|
252
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
253
|
+
scheduleTrigger: HTMLDivElement;
|
|
254
|
+
scheduleOverlay: HTMLDivElement;
|
|
255
|
+
}, HTMLDivElement>;
|
|
256
|
+
|
|
240
257
|
declare const __VLS_component_3: DefineComponent<ColumnProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ColumnProps> & Readonly<{}>, {
|
|
241
258
|
visible: boolean;
|
|
242
259
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
@@ -801,6 +818,26 @@ declare function __VLS_template_24(): {
|
|
|
801
818
|
rootEl: HTMLDivElement;
|
|
802
819
|
};
|
|
803
820
|
|
|
821
|
+
declare function __VLS_template_25(): {
|
|
822
|
+
attrs: Partial<{}>;
|
|
823
|
+
slots: {
|
|
824
|
+
input?(_: {
|
|
825
|
+
value: string;
|
|
826
|
+
}): any;
|
|
827
|
+
content?(_: {
|
|
828
|
+
close: typeof closeSchedule;
|
|
829
|
+
days: DayOfWeek[];
|
|
830
|
+
toggleDay: typeof toggleDay;
|
|
831
|
+
updateDayTime: typeof updateDayTime;
|
|
832
|
+
}): any;
|
|
833
|
+
};
|
|
834
|
+
refs: {
|
|
835
|
+
scheduleTrigger: HTMLDivElement;
|
|
836
|
+
scheduleOverlay: HTMLDivElement;
|
|
837
|
+
};
|
|
838
|
+
rootEl: HTMLDivElement;
|
|
839
|
+
};
|
|
840
|
+
|
|
804
841
|
declare function __VLS_template_3(): {
|
|
805
842
|
attrs: Partial<{}>;
|
|
806
843
|
slots: Readonly<ColumnSlots> & ColumnSlots;
|
|
@@ -903,6 +940,8 @@ declare type __VLS_TemplateResult_23 = ReturnType<typeof __VLS_template_23>;
|
|
|
903
940
|
|
|
904
941
|
declare type __VLS_TemplateResult_24 = ReturnType<typeof __VLS_template_24>;
|
|
905
942
|
|
|
943
|
+
declare type __VLS_TemplateResult_25 = ReturnType<typeof __VLS_template_25>;
|
|
944
|
+
|
|
906
945
|
declare type __VLS_TemplateResult_3 = ReturnType<typeof __VLS_template_3>;
|
|
907
946
|
|
|
908
947
|
declare type __VLS_TemplateResult_4 = ReturnType<typeof __VLS_template_4>;
|
|
@@ -1019,6 +1058,12 @@ declare type __VLS_WithTemplateSlots_24<T, S> = T & {
|
|
|
1019
1058
|
};
|
|
1020
1059
|
};
|
|
1021
1060
|
|
|
1061
|
+
declare type __VLS_WithTemplateSlots_25<T, S> = T & {
|
|
1062
|
+
new (): {
|
|
1063
|
+
$slots: S;
|
|
1064
|
+
};
|
|
1065
|
+
};
|
|
1066
|
+
|
|
1022
1067
|
declare type __VLS_WithTemplateSlots_3<T, S> = T & {
|
|
1023
1068
|
new (): {
|
|
1024
1069
|
$slots: S;
|
|
@@ -1084,7 +1129,9 @@ onChange?: ((value: string | number | AutocompleteOption | (string | number | Au
|
|
|
1084
1129
|
}>, {
|
|
1085
1130
|
label: string;
|
|
1086
1131
|
disabled: boolean;
|
|
1132
|
+
error: boolean;
|
|
1087
1133
|
placeholder: string;
|
|
1134
|
+
errorText: string;
|
|
1088
1135
|
multiple: boolean;
|
|
1089
1136
|
options: AutocompleteOption[];
|
|
1090
1137
|
loading: boolean;
|
|
@@ -1092,6 +1139,7 @@ valueKey: string;
|
|
|
1092
1139
|
labelKey: string;
|
|
1093
1140
|
maxTags: number;
|
|
1094
1141
|
clearable: boolean;
|
|
1142
|
+
required: boolean;
|
|
1095
1143
|
minQueryLength: number;
|
|
1096
1144
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
1097
1145
|
autocompleteTrigger: HTMLDivElement;
|
|
@@ -1119,6 +1167,9 @@ declare interface AutocompleteProps {
|
|
|
1119
1167
|
clearable?: boolean;
|
|
1120
1168
|
minQueryLength?: number;
|
|
1121
1169
|
label?: string;
|
|
1170
|
+
required?: boolean;
|
|
1171
|
+
error?: boolean;
|
|
1172
|
+
errorText?: string;
|
|
1122
1173
|
}
|
|
1123
1174
|
|
|
1124
1175
|
export declare const Badge: DefineComponent<__VLS_Props_20, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<__VLS_Props_20> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
@@ -1157,6 +1208,8 @@ export declare const ChipCheckbox: DefineComponent<__VLS_PublicProps_4, {}, {},
|
|
|
1157
1208
|
"onUpdate:modelValue"?: ((value: any) => any) | undefined;
|
|
1158
1209
|
}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
1159
1210
|
|
|
1211
|
+
declare function closeSchedule(): void;
|
|
1212
|
+
|
|
1160
1213
|
export declare const Column: __VLS_WithTemplateSlots_3<typeof __VLS_component_3, __VLS_TemplateResult_3["slots"]>;
|
|
1161
1214
|
|
|
1162
1215
|
declare type Column_2 = {
|
|
@@ -1293,6 +1346,13 @@ inputRef: HTMLDivElement;
|
|
|
1293
1346
|
popoverRef: HTMLDivElement;
|
|
1294
1347
|
}, HTMLDivElement>;
|
|
1295
1348
|
|
|
1349
|
+
declare interface DayOfWeek {
|
|
1350
|
+
key: string;
|
|
1351
|
+
label: string;
|
|
1352
|
+
enabled: boolean;
|
|
1353
|
+
time?: TimeRange;
|
|
1354
|
+
}
|
|
1355
|
+
|
|
1296
1356
|
export declare const Divider: __VLS_WithTemplateSlots_19<typeof __VLS_component_19, __VLS_TemplateResult_19["slots"]>;
|
|
1297
1357
|
|
|
1298
1358
|
export declare const Drawer: __VLS_WithTemplateSlots_11<typeof __VLS_component_11, __VLS_TemplateResult_11["slots"]>;
|
|
@@ -1342,6 +1402,9 @@ declare interface ICalendarProps {
|
|
|
1342
1402
|
* - day - выбор дня, месяца и года
|
|
1343
1403
|
* - month - выбор месяца и года
|
|
1344
1404
|
* - year - выбор года
|
|
1405
|
+
* - date - только выбор даты
|
|
1406
|
+
* - datetime - выбор даты и времени
|
|
1407
|
+
* - time - только выбор времени
|
|
1345
1408
|
*
|
|
1346
1409
|
* @default 'day'
|
|
1347
1410
|
* */
|
|
@@ -1396,7 +1459,7 @@ declare type ICalendarResult = {
|
|
|
1396
1459
|
|
|
1397
1460
|
declare type ICalendarResultValue = string | ICalendarResult | null;
|
|
1398
1461
|
|
|
1399
|
-
declare type ICalendarType = 'month' | 'year' | 'day';
|
|
1462
|
+
declare type ICalendarType = 'month' | 'year' | 'day' | 'date' | 'datetime' | 'time';
|
|
1400
1463
|
|
|
1401
1464
|
export declare const IconField: __VLS_WithTemplateSlots_7<typeof __VLS_component_7, __VLS_TemplateResult_7["slots"]>;
|
|
1402
1465
|
|
|
@@ -1647,6 +1710,19 @@ declare interface Props_2 {
|
|
|
1647
1710
|
|
|
1648
1711
|
export declare const Radio: __VLS_WithTemplateSlots_5<typeof __VLS_component_5, __VLS_TemplateResult_5["slots"]>;
|
|
1649
1712
|
|
|
1713
|
+
export declare const Schedule: __VLS_WithTemplateSlots_25<typeof __VLS_component_25, __VLS_TemplateResult_25["slots"]>;
|
|
1714
|
+
|
|
1715
|
+
declare interface ScheduleProps {
|
|
1716
|
+
/** Массив дней недели с их состоянием */
|
|
1717
|
+
modelValue?: DayOfWeek[];
|
|
1718
|
+
/** Текст плейсхолдера, отображаемый при отсутствии значения */
|
|
1719
|
+
placeholder?: string;
|
|
1720
|
+
/** Отключает взаимодействие с компонентом */
|
|
1721
|
+
disabled?: boolean;
|
|
1722
|
+
/** Показывает кнопку очистки значения */
|
|
1723
|
+
clearable?: boolean;
|
|
1724
|
+
}
|
|
1725
|
+
|
|
1650
1726
|
export declare const SelectButton: DefineComponent<__VLS_PublicProps_10, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
1651
1727
|
"update:modelValue": (value: any) => any;
|
|
1652
1728
|
}, string, PublicProps, Readonly<__VLS_PublicProps_10> & Readonly<{
|
|
@@ -1863,6 +1939,11 @@ onFocusOut?: ((value: FocusEvent) => any) | undefined;
|
|
|
1863
1939
|
textareaRef: HTMLTextAreaElement;
|
|
1864
1940
|
}, HTMLDivElement>;
|
|
1865
1941
|
|
|
1942
|
+
declare interface TimeRange {
|
|
1943
|
+
from: string;
|
|
1944
|
+
to: string;
|
|
1945
|
+
}
|
|
1946
|
+
|
|
1866
1947
|
export declare const Toast: DefineComponent<ToastProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<ToastProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
1867
1948
|
|
|
1868
1949
|
/**
|
|
@@ -1963,6 +2044,8 @@ declare interface ToastServiceMethods {
|
|
|
1963
2044
|
removeAllGroups(): void;
|
|
1964
2045
|
}
|
|
1965
2046
|
|
|
2047
|
+
declare function toggleDay(dayKey: string): void;
|
|
2048
|
+
|
|
1966
2049
|
export declare const Tooltip: DefineComponent<TooltipProps, {
|
|
1967
2050
|
show: (element: HTMLElement) => void;
|
|
1968
2051
|
hide: () => void;
|
|
@@ -1999,6 +2082,8 @@ declare interface TooltipProps {
|
|
|
1999
2082
|
delay?: number;
|
|
2000
2083
|
}
|
|
2001
2084
|
|
|
2085
|
+
declare function updateDayTime(dayKey: string, timeRange: TimeRange | undefined): void;
|
|
2086
|
+
|
|
2002
2087
|
export declare const useConfirmDialog: () => ConfirmDialogService;
|
|
2003
2088
|
|
|
2004
2089
|
export declare const useConfirmPopup: () => ConfirmPopupService;
|
|
@@ -2009,9 +2094,9 @@ declare const Z_INDEX: {
|
|
|
2009
2094
|
readonly BASE: 1000;
|
|
2010
2095
|
readonly DROPDOWN: 1010;
|
|
2011
2096
|
readonly STICKY: 1020;
|
|
2012
|
-
readonly
|
|
2013
|
-
readonly
|
|
2014
|
-
readonly
|
|
2097
|
+
readonly TOOLTIP: 1030;
|
|
2098
|
+
readonly POPOVER: 1040;
|
|
2099
|
+
readonly DRAWER: 1050;
|
|
2015
2100
|
readonly MODAL: 1060;
|
|
2016
2101
|
readonly NOTIFICATION: 1070;
|
|
2017
2102
|
readonly DEBUG: 9999;
|