@teammodlr/ui-kit 2.1.68 → 2.1.69

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.
@@ -1,9 +1,9 @@
1
- import { type CSSProperties } from "vue";
2
- import type { ComputedRef } from "vue";
3
- import * as style from "./style";
1
+ import { type CSSProperties, type PropType, type Ref } from 'vue';
2
+ import type { ComputedRef } from 'vue';
3
+ import * as style from './style';
4
4
  declare const _default: import("vue").DefineComponent<{
5
5
  title: {
6
- type: StringConstructor;
6
+ type: PropType<string | Ref<string>>;
7
7
  default: string;
8
8
  };
9
9
  draggable: {
@@ -31,15 +31,13 @@ declare const _default: import("vue").DefineComponent<{
31
31
  };
32
32
  open: {
33
33
  type: BooleanConstructor;
34
+ default: boolean;
34
35
  };
35
36
  }, {
36
- slots: Readonly<{
37
- [name: string]: import("vue").Slot<any> | undefined;
38
- }>;
39
- wrapper: import("vue").Ref<HTMLElement | null>;
40
- dialog: import("vue").Ref<HTMLElement | null>;
41
- handle: import("vue").Ref<HTMLElement | null>;
42
- zIndex: import("vue").Ref<number>;
37
+ wrapper: Ref<HTMLElement | null>;
38
+ dialog: Ref<HTMLElement | null>;
39
+ handle: Ref<HTMLElement | null>;
40
+ zIndex: Ref<number>;
43
41
  fade: {
44
42
  enterActive: string;
45
43
  leaveActive: string;
@@ -57,14 +55,16 @@ declare const _default: import("vue").DefineComponent<{
57
55
  backdropClasses: ComputedRef<{
58
56
  [x: string]: boolean;
59
57
  }>;
58
+ resolvedTitle: ComputedRef<string>;
60
59
  wrapperClasses: ComputedRef<{
61
60
  [x: string]: boolean;
62
61
  }>;
62
+ isOpen: Ref<boolean>;
63
63
  close: () => void;
64
64
  onEnter: () => void;
65
65
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:open" | "onClose" | "onOpen")[], "update:open" | "onClose" | "onOpen", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
66
66
  title: {
67
- type: StringConstructor;
67
+ type: PropType<string | Ref<string>>;
68
68
  default: string;
69
69
  };
70
70
  draggable: {
@@ -92,6 +92,7 @@ declare const _default: import("vue").DefineComponent<{
92
92
  };
93
93
  open: {
94
94
  type: BooleanConstructor;
95
+ default: boolean;
95
96
  };
96
97
  }>> & {
97
98
  "onUpdate:open"?: ((...args: any[]) => any) | undefined;
@@ -100,7 +101,7 @@ declare const _default: import("vue").DefineComponent<{
100
101
  }, {
101
102
  width: string | number;
102
103
  open: boolean;
103
- title: string;
104
+ title: string | Ref<string>;
104
105
  modal: boolean;
105
106
  onClose: Function;
106
107
  draggable: boolean;
@@ -0,0 +1,7 @@
1
+ import type { DialogReactive } from './types';
2
+ declare const _default: import("vue").DefineComponent<{}, {
3
+ dialogMap: Record<string, DialogReactive>;
4
+ remove: (key: string) => void;
5
+ setDialogRef: (key: string) => (el: any) => void;
6
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
7
+ export default _default;
@@ -0,0 +1,23 @@
1
+ import type { Ref, VNodeChild } from 'vue';
2
+ export type DialogContent = VNodeChild;
3
+ export interface DialogOptions {
4
+ title?: string | Ref<string>;
5
+ render?: (props: any) => VNodeChild;
6
+ props?: {
7
+ [key: string]: any;
8
+ };
9
+ onClose?: () => void;
10
+ open?: boolean;
11
+ draggable?: boolean;
12
+ modal?: boolean;
13
+ }
14
+ export interface DialogReactive {
15
+ key: string;
16
+ options: DialogOptions;
17
+ open: () => void;
18
+ close: () => void;
19
+ }
20
+ export interface DialogApiInjection {
21
+ create: (key: string, options?: DialogOptions) => DialogReactive;
22
+ remove: (key: string) => void;
23
+ }
@@ -0,0 +1,2 @@
1
+ import type { DialogApiInjection } from "./types";
2
+ export declare function useDialog(): DialogApiInjection;
@@ -48,4 +48,5 @@ export { default as MVirtualScroll } from './virtualscroll/VirtualScroll.vue';
48
48
  export { default as MConfirm } from './confirm/Confirm.vue';
49
49
  export { default as MConfirmProvider } from './confirm/ConfirmProvider.vue';
50
50
  export { default as MDialog } from './dialog/Dialog.vue';
51
+ export { default as MDialogProvider } from './dialogprovider/DialogProvider.vue';
51
52
  export { default as MTree } from './tree/Tree.vue';
@@ -1,6 +1,5 @@
1
1
  import type { MessageType, MessageReactive, MessageApiInjection, ContentType, MessagePlacement } from './types';
2
2
  import type { PropType } from 'vue';
3
- export type MessageProviderInst = MessageApiInjection;
4
3
  interface PrivateMessageRef extends MessageReactive {
5
4
  key: string;
6
5
  hide: () => void;
@@ -1,4 +1,5 @@
1
1
  export { useMessage } from '../components/messageprovider/useMessage';
2
+ export { useDialog } from '../components/dialogprovider/useDialog';
2
3
  export { useConfirm } from '../components/confirm/useConfirm';
3
4
  export { usePopper } from './usePopper';
4
5
  export { useZIndex } from './useZIndex';