bkui-vue 1.0.3-beta.68 → 1.0.3-beta.68.dialog.2

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.
Files changed (102) hide show
  1. package/dist/index.cjs.js +70 -70
  2. package/dist/index.esm.js +20267 -19318
  3. package/dist/index.umd.js +67 -67
  4. package/dist/style.css +1 -1
  5. package/dist/style.variable.css +1 -1
  6. package/lib/components.d.ts +1 -0
  7. package/lib/components.js +1 -0
  8. package/lib/dialog/dialog.css +139 -84
  9. package/lib/dialog/dialog.d.ts +32 -133
  10. package/lib/dialog/dialog.less +9 -76
  11. package/lib/dialog/dialog.variable.css +139 -84
  12. package/lib/dialog/index.d.ts +84 -314
  13. package/lib/dialog/index.js +197 -221
  14. package/lib/dialog/props.d.ts +8 -48
  15. package/lib/info-box/index.d.ts +2 -2
  16. package/lib/info-box/index.js +328 -173
  17. package/lib/info-box/info-box.css +63 -7
  18. package/lib/info-box/info-box.d.ts +18 -16
  19. package/lib/info-box/info-box.less +76 -14
  20. package/lib/info-box/info-box.variable.css +63 -7
  21. package/lib/info-box/render-component.d.ts +4 -0
  22. package/lib/input/index.js +2 -1
  23. package/lib/modal/hooks.d.ts +1 -1
  24. package/lib/modal/index.d.ts +16 -350
  25. package/lib/modal/index.js +218 -703
  26. package/lib/modal/mask.d.ts +6 -0
  27. package/lib/modal/modal.css +135 -32
  28. package/lib/modal/modal.d.ts +6 -134
  29. package/lib/modal/modal.less +88 -29
  30. package/lib/modal/modal.variable.css +135 -32
  31. package/lib/modal/props.mixin.d.ts +2 -53
  32. package/lib/overflow-title/index.js +46 -52
  33. package/lib/pop-confirm/index.js +5 -8
  34. package/lib/radio/index.d.ts +15 -0
  35. package/lib/radio/index.js +21 -13
  36. package/lib/radio/radio.d.ts +10 -0
  37. package/lib/scrollbar/index.d.ts +15 -0
  38. package/lib/scrollbar/index.js +18763 -0
  39. package/lib/scrollbar/scrollbar-core/can-use-dom.d.ts +2 -0
  40. package/lib/scrollbar/scrollbar-core/helpers.d.ts +5 -0
  41. package/lib/scrollbar/scrollbar-core/index.d.ts +241 -0
  42. package/lib/scrollbar/scrollbar-core/mouse-wheel.d.ts +5 -0
  43. package/lib/scrollbar/scrollbar-core/scrollbar-width.d.ts +1 -0
  44. package/lib/scrollbar/scrollbar.css +75 -0
  45. package/lib/scrollbar/scrollbar.less +94 -0
  46. package/lib/scrollbar/scrollbar.variable.css +204 -0
  47. package/lib/shared/index.d.ts +0 -1
  48. package/lib/shared/index.js +1 -48
  49. package/lib/sideslider/index.d.ts +31 -222
  50. package/lib/sideslider/index.js +65 -40
  51. package/lib/sideslider/sideslider.css +17 -86
  52. package/lib/sideslider/sideslider.d.ts +14 -105
  53. package/lib/sideslider/sideslider.less +27 -107
  54. package/lib/sideslider/sideslider.variable.css +17 -86
  55. package/lib/slider/index.d.ts +19 -0
  56. package/lib/slider/index.js +45 -5
  57. package/lib/slider/slider.css +14 -0
  58. package/lib/slider/slider.d.ts +9 -0
  59. package/lib/slider/slider.less +15 -0
  60. package/lib/slider/slider.variable.css +14 -0
  61. package/lib/table/components/table-cell.d.ts +3 -2
  62. package/lib/table/components/table-column.d.ts +2 -2
  63. package/lib/table/const.d.ts +1 -1
  64. package/lib/table/index.d.ts +25 -2
  65. package/lib/table/index.js +237 -85
  66. package/lib/table/plugins/head-filter.css +8 -4
  67. package/lib/table/plugins/head-filter.less +6 -3
  68. package/lib/table/plugins/head-filter.variable.css +8 -4
  69. package/lib/table/plugins/use-fixed-column.d.ts +1 -1
  70. package/lib/table/plugins/use-pagination.d.ts +3 -1
  71. package/lib/table/plugins/use-shift-key.d.ts +11 -0
  72. package/lib/table/props.d.ts +11 -3
  73. package/lib/table/table.css +106 -46
  74. package/lib/table/table.d.ts +11 -0
  75. package/lib/table/table.less +43 -58
  76. package/lib/table/table.variable.css +106 -46
  77. package/lib/table/use-attributes.d.ts +2 -1
  78. package/lib/table/use-column.d.ts +6 -6
  79. package/lib/table/use-render.d.ts +1 -1
  80. package/lib/table-column/index.d.ts +6 -6
  81. package/lib/table-column/index.js +6 -2
  82. package/lib/tree/constant.d.ts +3 -1
  83. package/lib/tree/index.d.ts +44 -0
  84. package/lib/tree/index.js +17548 -25
  85. package/lib/tree/props.d.ts +18 -0
  86. package/lib/tree/tree.css +76 -2
  87. package/lib/tree/tree.d.ts +28 -2
  88. package/lib/tree/tree.variable.css +76 -2
  89. package/lib/tree/use-intersection-observer.d.ts +27 -0
  90. package/lib/tree/use-node-attribute.d.ts +9 -0
  91. package/lib/virtual-render/index.d.ts +27 -0
  92. package/lib/virtual-render/index.js +295 -80
  93. package/lib/virtual-render/props.d.ts +16 -0
  94. package/lib/virtual-render/use-fix-top.d.ts +2 -7
  95. package/lib/virtual-render/use-scrollbar.d.ts +24 -0
  96. package/lib/virtual-render/v-virtual-render.d.ts +2 -1
  97. package/lib/virtual-render/virtual-render.css +76 -2
  98. package/lib/virtual-render/virtual-render.d.ts +13 -0
  99. package/lib/virtual-render/virtual-render.less +3 -3
  100. package/lib/virtual-render/virtual-render.variable.css +76 -2
  101. package/package.json +1 -1
  102. package/lib/shared/mask.d.ts +0 -11
@@ -1,33 +1,35 @@
1
1
  import { VNode } from 'vue';
2
- export interface ModalFuncProps {
2
+ export interface Props {
3
3
  isShow?: boolean;
4
4
  width?: string | number;
5
- height?: string | number;
6
- 'ext-cls': string | string[];
7
- theme?: 'primary' | 'warning' | 'success' | 'danger';
5
+ extCls?: string | string[];
6
+ class?: string | string[];
8
7
  infoType?: 'success' | 'danger' | 'warning' | 'loading';
8
+ type?: 'success' | 'danger' | 'warning' | 'loading';
9
9
  title?: string | (() => VNode | string) | VNode;
10
10
  subTitle?: string | (() => VNode) | VNode;
11
- confirmText?: string | (() => VNode) | VNode;
12
- cancelText?: string | (() => VNode) | VNode;
13
- onConfirm?: (...args: any[]) => any;
14
- onClosed?: (...args: any[]) => any;
15
- boundary?: HTMLElement;
16
- draggable?: boolean;
17
- maskClose?: boolean;
18
- escClose?: boolean;
19
- closeIcon?: boolean;
11
+ content?: string | (() => VNode) | VNode;
12
+ footer?: string | (() => VNode) | VNode;
20
13
  headerAlign?: 'left' | 'center' | 'right';
21
14
  footerAlign?: 'left' | 'center' | 'right';
22
15
  contentAlign?: 'left' | 'center' | 'right';
23
- dialogType?: 'show' | 'operation' | 'confirm';
24
16
  showMask?: boolean;
25
17
  quickClose?: boolean;
18
+ escClose?: boolean;
19
+ closeIcon?: boolean;
20
+ confirmText?: string | (() => VNode) | VNode;
21
+ theme?: 'primary' | 'warning' | 'success' | 'danger';
22
+ confirmButtonTheme?: 'primary' | 'warning' | 'success' | 'danger';
23
+ cancelText?: string | (() => VNode) | VNode;
24
+ beforeClose?: (action: string) => boolean | Promise<boolean>;
25
+ onConfirm?: () => void;
26
+ onCancel?: () => void;
27
+ onClose?: () => void;
26
28
  }
27
- declare const InfoBox: (config: Partial<ModalFuncProps>) => {
29
+ declare const InfoBox: (config: Partial<Props>) => {
28
30
  show: () => void;
29
31
  hide: () => void;
30
- update: (config: Partial<ModalFuncProps>) => void;
32
+ update: (config: Partial<Props>) => void;
31
33
  destroy: () => void;
32
34
  };
33
35
  export default InfoBox;
@@ -1,24 +1,86 @@
1
1
  @import '../styles/themes/themes.less';
2
2
 
3
- &.@{bk-prefix}-info-wrapper {
3
+ .@{bk-prefix}-infobox {
4
+ font-size: 12px;
5
+
4
6
  .@{bk-prefix}-modal-wrapper {
5
- width: 440px;
7
+ top: 50%;
8
+ left: 50%;
9
+ transform: translate(-50%, -50%);
10
+ }
11
+ }
6
12
 
7
- .@{bk-prefix}-dialog-header {
8
- .@{bk-prefix}-dialog-title {
9
- margin-top: 16px;
10
- }
11
- }
13
+ .@{bk-prefix}-infobox-header {
14
+ padding-top: 24px;
15
+ }
16
+
17
+ .@{bk-prefix}-infobox-type {
18
+ display: flex;
19
+ justify-content: center;
20
+ align-items: center;
21
+ }
22
+
23
+ .@{bk-prefix}-infobox-icon {
24
+ width: 42px;
25
+ height: 42px;
26
+ font-size: 42px;
27
+
28
+ &.success {
29
+ color: @success-color;
12
30
  }
13
31
 
14
- .@{bk-prefix}-dialog-footer {
15
- button {
16
- min-width: 88px;
17
- }
32
+ &.warning {
33
+ color: @warning-color;
34
+ }
35
+
36
+ &.danger {
37
+ color: @danger-color;
38
+ }
39
+
40
+ &.loading {
41
+ color: @primary-color;
18
42
  }
19
43
  }
20
44
 
21
- .@{bk-prefix}-info-sub-title {
22
- text-align: center;
23
- word-break: break-all;
45
+ .@{bk-prefix}-infobox-title {
46
+ padding-right: 24px;
47
+ padding-left: 24px;
48
+ margin-top: 24px;
49
+ font-size: 20px;
50
+ line-height: 32px;
51
+ color: #313238;
52
+ }
53
+
54
+ .@{bk-prefix}-infobox-content {
55
+ padding-right: 24px;
56
+ padding-left: 24px;
57
+ margin-top: 16px;
58
+ }
59
+
60
+ .@{bk-prefix}-infobox-footer {
61
+ display: flex;
62
+ padding-right: 24px;
63
+ padding-bottom: 24px;
64
+ padding-left: 24px;
65
+ margin-top: 24px;
66
+ align-content: center;
67
+
68
+ &.is-position-right {
69
+ justify-content: right;
70
+ }
71
+
72
+ &.is-position-center {
73
+ justify-content: center;
74
+ }
75
+
76
+ &.is-position-left {
77
+ justify-content: left;
78
+ }
79
+
80
+ .@{bk-prefix}-button {
81
+ min-width: 88px;
82
+ & ~ .@{bk-prefix}-button {
83
+ margin-left: 8px;
84
+ }
85
+ }
24
86
  }
@@ -127,16 +127,72 @@
127
127
  --select-active-color: #e1ecff;
128
128
  --select-hover-color: #f5f7fa;
129
129
  }
130
- .bk-info-wrapper .bk-modal-wrapper {
131
- width: 440px;
130
+ .bk-infobox {
131
+ font-size: 12px;
132
132
  }
133
- .bk-info-wrapper .bk-modal-wrapper .bk-dialog-header .bk-dialog-title {
133
+ .bk-infobox .bk-modal-wrapper {
134
+ top: 50%;
135
+ left: 50%;
136
+ transform: translate(-50%, -50%);
137
+ }
138
+ .bk-infobox-header {
139
+ padding-top: 24px;
140
+ }
141
+ .bk-infobox-type {
142
+ display: flex;
143
+ justify-content: center;
144
+ align-items: center;
145
+ }
146
+ .bk-infobox-icon {
147
+ width: 42px;
148
+ height: 42px;
149
+ font-size: 42px;
150
+ }
151
+ .bk-infobox-icon.success {
152
+ color: var(--success-color);
153
+ }
154
+ .bk-infobox-icon.warning {
155
+ color: var(--warning-color);
156
+ }
157
+ .bk-infobox-icon.danger {
158
+ color: var(--danger-color);
159
+ }
160
+ .bk-infobox-icon.loading {
161
+ color: var(--primary-color);
162
+ }
163
+ .bk-infobox-title {
164
+ padding-right: 24px;
165
+ padding-left: 24px;
166
+ margin-top: 24px;
167
+ font-size: 20px;
168
+ line-height: 32px;
169
+ color: #313238;
170
+ }
171
+ .bk-infobox-content {
172
+ padding-right: 24px;
173
+ padding-left: 24px;
134
174
  margin-top: 16px;
135
175
  }
136
- .bk-info-wrapper .bk-dialog-footer button {
176
+ .bk-infobox-footer {
177
+ display: flex;
178
+ padding-right: 24px;
179
+ padding-bottom: 24px;
180
+ padding-left: 24px;
181
+ margin-top: 24px;
182
+ align-content: center;
183
+ }
184
+ .bk-infobox-footer.is-position-right {
185
+ justify-content: right;
186
+ }
187
+ .bk-infobox-footer.is-position-center {
188
+ justify-content: center;
189
+ }
190
+ .bk-infobox-footer.is-position-left {
191
+ justify-content: left;
192
+ }
193
+ .bk-infobox-footer .bk-button {
137
194
  min-width: 88px;
138
195
  }
139
- .bk-info-sub-title {
140
- text-align: center;
141
- word-break: break-all;
196
+ .bk-infobox-footer .bk-button ~ .bk-button {
197
+ margin-left: 8px;
142
198
  }
@@ -0,0 +1,4 @@
1
+ import type { Props } from './info-box';
2
+ export declare const genDefaultState: () => Required<Props>;
3
+ declare const _default: import("vue").DefineComponent<{}, () => JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
4
+ export default _default;
@@ -948,13 +948,14 @@ var inputEmitEventsType = (_inputEmitEventsType = {}, _defineProperty(_definePro
948
948
  });
949
949
  });
950
950
  var tooltips = (0,external_vue_namespaceObject.computed)(function () {
951
+ var _props$modelValue2;
951
952
  if (showMaxLimit.value && ceilMaxLength.value - modelValueLength.value === 0) {
952
953
  return {
953
954
  content: t.value.maxlengthLimitTips
954
955
  };
955
956
  }
956
957
  return props.showOverflowTooltips && isOverflow.value && props.modelValue ? {
957
- content: props.modelValue,
958
+ content: (_props$modelValue2 = props.modelValue) === null || _props$modelValue2 === void 0 ? void 0 : _props$modelValue2.toString(),
958
959
  sameWidth: true
959
960
  } : {
960
961
  disabled: true
@@ -1,6 +1,6 @@
1
1
  import { type Ref } from 'vue';
2
2
  import type { ModalProps } from './modal';
3
- export declare const useContentResize: (root: Ref<HTMLElement>, resizeTarget: Ref<HTMLElement>, props: ModalProps) => {
3
+ export declare const useContentResize: (root: Ref<HTMLElement | undefined>, resizeTarget: Ref<HTMLElement | undefined>, props: ModalProps) => {
4
4
  contentStyles: Ref<{}>;
5
5
  isContentScroll: Ref<boolean>;
6
6
  };