@sdata/web-vue 3.11.0 → 3.13.0

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 (109) hide show
  1. package/dist/sd.css +147 -15
  2. package/dist/sd.min.css +43 -1
  3. package/es/_components/picker/input-range.vue.d.ts +6 -7
  4. package/es/_components/picker/input-range.vue_vue_type_script_setup_true_lang.js +63 -46
  5. package/es/_components/picker/input.vue.d.ts +5 -6
  6. package/es/_components/picker/input.vue_vue_type_script_setup_true_lang.js +52 -35
  7. package/es/_hooks/use-readonly-tip.d.ts +11 -0
  8. package/es/_hooks/use-readonly-tip.js +66 -0
  9. package/es/auto-complete/auto-complete.d.ts +9 -0
  10. package/es/auto-complete/auto-complete.js +11 -1
  11. package/es/auto-complete/index.d.ts +15 -0
  12. package/es/button/button.vue.d.ts +16 -7
  13. package/es/button/button.vue_vue_type_script_setup_true_lang.js +57 -31
  14. package/es/button/index.d.ts +11 -0
  15. package/es/button/interface.d.ts +2 -0
  16. package/es/card/card.d.ts +312 -0
  17. package/es/card/card.js +39 -7
  18. package/es/card/index.d.ts +616 -0
  19. package/es/card/style/index.css +23 -0
  20. package/es/card/style/index.scss +31 -0
  21. package/es/cascader/cascader.vue.d.ts +9 -8
  22. package/es/cascader/cascader.vue_vue_type_script_setup_true_lang.js +149 -128
  23. package/es/cascader/types.d.ts +1 -0
  24. package/es/color-picker/color-picker.d.ts +9 -0
  25. package/es/color-picker/color-picker.js +33 -11
  26. package/es/color-picker/index.d.ts +15 -0
  27. package/es/config-provider/context.d.ts +9 -9
  28. package/es/copy/copy.vue_vue_type_script_setup_true_lang.js +1 -1
  29. package/es/date-picker/index.d.ts +3 -6
  30. package/es/date-picker/picker.vue.d.ts +2 -3
  31. package/es/date-picker/picker.vue_vue_type_script_setup_true_lang.js +5 -5
  32. package/es/date-picker/range-picker.vue.d.ts +2 -3
  33. package/es/date-picker/range-picker.vue_vue_type_script_setup_true_lang.js +4 -4
  34. package/es/drawer/drawer.vue_vue_type_script_setup_true_lang.js +3 -3
  35. package/es/empty/empty.js +1 -1
  36. package/es/file-previewer/file-previewer.vue_vue_type_script_setup_true_lang.js +1 -1
  37. package/es/image/image.vue_vue_type_script_setup_true_lang.js +1 -1
  38. package/es/image/preview-action.d.ts +7 -127
  39. package/es/image/preview.vue_vue_type_script_setup_true_lang.js +2 -2
  40. package/es/index.css +147 -15
  41. package/es/index.js +3 -3
  42. package/es/input/index.d.ts +6 -6
  43. package/es/input/input.d.ts +3 -3
  44. package/es/input/input.js +18 -6
  45. package/es/input-number/index.d.ts +9 -9
  46. package/es/input-number/input-number.d.ts +5 -5
  47. package/es/input-number/input-number.js +8 -8
  48. package/es/input-tag/index.d.ts +6 -6
  49. package/es/input-tag/input-tag.d.ts +3 -3
  50. package/es/input-tag/input-tag.js +16 -7
  51. package/es/locale/interface.d.ts +1 -0
  52. package/es/locale/lang/en-us.js +1 -0
  53. package/es/locale/lang/zh-cn.js +1 -0
  54. package/es/locale/lang/zh-tw.js +1 -0
  55. package/es/mention/index.d.ts +15 -0
  56. package/es/mention/mention.d.ts +9 -0
  57. package/es/mention/mention.js +12 -1
  58. package/es/menu/base-menu.vue_vue_type_script_setup_true_lang.js +1 -1
  59. package/es/modal/modal.vue_vue_type_script_setup_true_lang.js +3 -3
  60. package/es/pagination/pagination.js +1 -1
  61. package/es/popconfirm/popconfirm.vue_vue_type_script_setup_true_lang.js +2 -2
  62. package/es/popover/popover.vue_vue_type_script_setup_true_lang.js +1 -1
  63. package/es/rate/index.d.ts +6 -6
  64. package/es/rate/rate.d.ts +3 -3
  65. package/es/rate/rate.js +17 -7
  66. package/es/scrollbar/scrollbar.vue_vue_type_script_setup_true_lang.js +1 -1
  67. package/es/scrollbar/style/index.css +57 -15
  68. package/es/scrollbar/style/index.scss +63 -15
  69. package/es/sd-vue.js +3 -3
  70. package/es/secret/secret.vue_vue_type_script_setup_true_lang.js +1 -1
  71. package/es/select/index.d.ts +15 -0
  72. package/es/select/select.d.ts +9 -0
  73. package/es/select/select.js +28 -5
  74. package/es/style/normalize.scss +68 -0
  75. package/es/table/table-th.js +2 -2
  76. package/es/tabs/context.d.ts +2 -0
  77. package/es/tabs/index.d.ts +32 -0
  78. package/es/tabs/style/index.css +29 -0
  79. package/es/tabs/style/index.scss +38 -0
  80. package/es/tabs/tab-pane.vue.d.ts +4 -2
  81. package/es/tabs/tab-pane.vue_vue_type_script_setup_true_lang.js +19 -3
  82. package/es/tabs/tabs.d.ts +19 -0
  83. package/es/tabs/tabs.js +23 -2
  84. package/es/textarea/index.d.ts +15 -0
  85. package/es/textarea/textarea.vue.d.ts +11 -2
  86. package/es/textarea/textarea.vue_vue_type_script_setup_true_lang.js +71 -46
  87. package/es/time-picker/index.d.ts +3 -6
  88. package/es/time-picker/panel.vue_vue_type_script_setup_true_lang.js +1 -1
  89. package/es/time-picker/time-picker.vue.d.ts +2 -3
  90. package/es/time-picker/time-picker.vue_vue_type_script_setup_true_lang.js +8 -5
  91. package/es/toolbar/toolbar.vue_vue_type_script_setup_true_lang.js +1 -1
  92. package/es/tooltip/index.d.ts +8 -127
  93. package/es/tooltip/interface.d.ts +17 -0
  94. package/es/tooltip/tooltip.vue.d.ts +5 -88
  95. package/es/tooltip/tooltip.vue_vue_type_script_setup_true_lang.js +8 -69
  96. package/es/tour/tour.vue_vue_type_script_setup_true_lang.js +1 -1
  97. package/es/tree/tree.vue_vue_type_script_setup_true_lang.js +1 -1
  98. package/es/tree-select/tree-select.vue.d.ts +16 -10
  99. package/es/tree-select/tree-select.vue_vue_type_script_setup_true_lang.js +156 -133
  100. package/es/typography/base.js +1 -1
  101. package/es/upload/upload-button.js +1 -1
  102. package/es/verification-code/index.d.ts +15 -6
  103. package/es/verification-code/verification-code.d.ts +9 -3
  104. package/es/verification-code/verification-code.js +4 -1
  105. package/json/vetur-attributes.json +48 -7
  106. package/json/vetur-tags.json +17 -5
  107. package/json/web-types.json +99 -10
  108. package/package.json +1 -1
  109. package/es/style/base.scss +0 -18
@@ -1,5 +1,6 @@
1
1
  /*! Tailwind CSS v4 preflight baseline scoped to SD Design layer */
2
2
  @use '@style/theme/index.scss' as *;
3
+ @use '@components/scrollbar/style/token.scss' as sb;
3
4
 
4
5
  /* stylelint-disable-next-line layer-name-pattern */
5
6
  @layer #{$prefix}-design {
@@ -224,4 +225,71 @@
224
225
  [hidden]:where(:not([hidden='until-found'])) {
225
226
  display: none !important;
226
227
  }
228
+
229
+ /* Native scrollbar baseline — mirrors the <Scrollbar> embed theme
230
+ (transparent track, neutral thumb; shares --sd-scrollbar-* with the <Scrollbar> component).
231
+ Opt-in: only applies within an element carrying the design-system
232
+ class (`.sd-design` by default; follows $prefix), e.g.
233
+ <html class="sd-design-system-scrollbar">. Standard scrollbar-* properties are
234
+ primary; ::-webkit-scrollbar*
235
+ is the fallback for browsers without standard support. Where the
236
+ standard properties apply they override the webkit rules, so the
237
+ rounded corners and hover/active states only render in webkit-only
238
+ browsers. */
239
+ @supports (scrollbar-color: auto) {
240
+ .#{$prefix}-design-system-scrollbar {
241
+ &,
242
+ & * {
243
+ scrollbar-width: thin;
244
+ scrollbar-color: var(
245
+ #{$sd-cssvars-prefix}-scrollbar-thumb-color,
246
+ #{sb.$scrollbar-thumb-bar-bg_color}
247
+ )
248
+ transparent;
249
+ }
250
+ }
251
+ }
252
+
253
+ @supports selector(::-webkit-scrollbar) {
254
+ .#{$prefix}-design-system-scrollbar {
255
+ &::-webkit-scrollbar,
256
+ & *::-webkit-scrollbar {
257
+ width: var(#{$sd-cssvars-prefix}-scrollbar-size, #{sb.$scrollbar-thumb-bar-size});
258
+ height: var(#{$sd-cssvars-prefix}-scrollbar-size, #{sb.$scrollbar-thumb-bar-size});
259
+ }
260
+
261
+ &::-webkit-scrollbar-track,
262
+ & *::-webkit-scrollbar-track {
263
+ background: transparent;
264
+ }
265
+
266
+ &::-webkit-scrollbar-thumb,
267
+ & *::-webkit-scrollbar-thumb {
268
+ background: var(
269
+ #{$sd-cssvars-prefix}-scrollbar-thumb-color,
270
+ #{sb.$scrollbar-thumb-bar-bg_color}
271
+ );
272
+ border-radius: var(
273
+ #{$sd-cssvars-prefix}-scrollbar-thumb-radius,
274
+ #{sb.$scrollbar-thumb-bar-border_radius}
275
+ );
276
+ }
277
+
278
+ &::-webkit-scrollbar-thumb:hover,
279
+ & *::-webkit-scrollbar-thumb:hover {
280
+ background: var(
281
+ #{$sd-cssvars-prefix}-scrollbar-thumb-color-hover,
282
+ #{sb.$scrollbar-thumb-bar-bg_color_hover}
283
+ );
284
+ }
285
+
286
+ &::-webkit-scrollbar-thumb:active,
287
+ & *::-webkit-scrollbar-thumb:active {
288
+ background: var(
289
+ #{$sd-cssvars-prefix}-scrollbar-thumb-color-active,
290
+ #{sb.$scrollbar-thumb-bar-bg_color_active}
291
+ );
292
+ }
293
+ }
294
+ }
227
295
  }
@@ -2,9 +2,9 @@ import { _objectSpread2 } from "../_virtual/_@oxc-project_runtime@0.133.0/helper
2
2
  import { getPrefixCls } from "../_utils/global-config.js";
3
3
  import { isBoolean, isFunction, isObject } from "../_utils/is.js";
4
4
  import icon_hover_default from "../_components/icon-hover.js";
5
- import Button from "../button/index.js";
6
- import Trigger from "../trigger/index.js";
7
5
  import { useI18n } from "../locale/index.js";
6
+ import Trigger from "../trigger/index.js";
7
+ import Button from "../button/index.js";
8
8
  import Checkbox from "../checkbox/index.js";
9
9
  import Radio from "../radio/index.js";
10
10
  import IconCaretDown from "../icon/icon-caret-down/index.js";
@@ -1,4 +1,5 @@
1
1
  import { InjectionKey } from 'vue';
2
+ import type { ScrollbarProps } from '../scrollbar';
2
3
  import { TabData, TabTriggerEvent } from './interface';
3
4
  export interface TabsContext {
4
5
  lazyLoad: boolean;
@@ -7,5 +8,6 @@ export interface TabsContext {
7
8
  addItem: (id: number, data: TabData) => void;
8
9
  removeItem: (id: number) => void;
9
10
  trigger: TabTriggerEvent;
11
+ scrollbar: ScrollbarProps | false;
10
12
  }
11
13
  export declare const tabsInjectionKey: InjectionKey<TabsContext>;
@@ -71,6 +71,14 @@ declare const Tabs: {
71
71
  type: import("vue").PropType<import("./interface").ScrollPosition>;
72
72
  default: string;
73
73
  };
74
+ fullHeight: {
75
+ type: BooleanConstructor;
76
+ default: boolean;
77
+ };
78
+ scrollbar: {
79
+ type: import("vue").PropType<boolean | import("../index.ts").ScrollbarProps>;
80
+ default: boolean;
81
+ };
74
82
  }>> & Readonly<{
75
83
  onDelete?: ((_key: string | number, _ev: Event) => any) | undefined;
76
84
  onAdd?: ((_ev: Event) => any) | undefined;
@@ -88,9 +96,11 @@ declare const Tabs: {
88
96
  trigger: import("./interface").TabTriggerEvent;
89
97
  position: import("./interface").TabsPosition;
90
98
  direction: "horizontal" | "vertical";
99
+ scrollbar: boolean | import("../index.ts").ScrollbarProps;
91
100
  activeKey: string | number;
92
101
  animation: boolean;
93
102
  justify: boolean;
103
+ fullHeight: boolean;
94
104
  destroyOnHide: boolean;
95
105
  defaultActiveKey: string | number;
96
106
  editable: boolean;
@@ -175,6 +185,14 @@ declare const Tabs: {
175
185
  type: import("vue").PropType<import("./interface").ScrollPosition>;
176
186
  default: string;
177
187
  };
188
+ fullHeight: {
189
+ type: BooleanConstructor;
190
+ default: boolean;
191
+ };
192
+ scrollbar: {
193
+ type: import("vue").PropType<boolean | import("../index.ts").ScrollbarProps>;
194
+ default: boolean;
195
+ };
178
196
  }>> & Readonly<{
179
197
  onDelete?: ((_key: string | number, _ev: Event) => any) | undefined;
180
198
  onAdd?: ((_ev: Event) => any) | undefined;
@@ -186,9 +204,11 @@ declare const Tabs: {
186
204
  trigger: import("./interface").TabTriggerEvent;
187
205
  position: import("./interface").TabsPosition;
188
206
  direction: "horizontal" | "vertical";
207
+ scrollbar: boolean | import("../index.ts").ScrollbarProps;
189
208
  activeKey: string | number;
190
209
  animation: boolean;
191
210
  justify: boolean;
211
+ fullHeight: boolean;
192
212
  destroyOnHide: boolean;
193
213
  defaultActiveKey: string | number;
194
214
  editable: boolean;
@@ -270,6 +290,14 @@ declare const Tabs: {
270
290
  type: import("vue").PropType<import("./interface").ScrollPosition>;
271
291
  default: string;
272
292
  };
293
+ fullHeight: {
294
+ type: BooleanConstructor;
295
+ default: boolean;
296
+ };
297
+ scrollbar: {
298
+ type: import("vue").PropType<boolean | import("../index.ts").ScrollbarProps>;
299
+ default: boolean;
300
+ };
273
301
  }>> & Readonly<{
274
302
  onDelete?: ((_key: string | number, _ev: Event) => any) | undefined;
275
303
  onAdd?: ((_ev: Event) => any) | undefined;
@@ -287,9 +315,11 @@ declare const Tabs: {
287
315
  trigger: import("./interface").TabTriggerEvent;
288
316
  position: import("./interface").TabsPosition;
289
317
  direction: "horizontal" | "vertical";
318
+ scrollbar: boolean | import("../index.ts").ScrollbarProps;
290
319
  activeKey: string | number;
291
320
  animation: boolean;
292
321
  justify: boolean;
322
+ fullHeight: boolean;
293
323
  destroyOnHide: boolean;
294
324
  defaultActiveKey: string | number;
295
325
  editable: boolean;
@@ -369,6 +399,8 @@ declare const Tabs: {
369
399
  }, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
370
400
  $slots: {
371
401
  default?: (props: {}) => any;
402
+ } & {
403
+ default?: (props: {}) => any;
372
404
  };
373
405
  });
374
406
  install: (app: App, options?: SDOptions) => void;
@@ -420,6 +420,35 @@
420
420
  height: 100%;
421
421
  }
422
422
 
423
+ .sd-tabs-horizontal.sd-tabs-full-height {
424
+ display: flex;
425
+ flex-direction: column;
426
+ height: 100%;
427
+ }
428
+ .sd-tabs-horizontal.sd-tabs-full-height > .sd-tabs-nav {
429
+ flex-shrink: 0;
430
+ }
431
+ .sd-tabs-horizontal.sd-tabs-full-height .sd-tabs-content {
432
+ flex: 1;
433
+ min-height: 0;
434
+ }
435
+ .sd-tabs-horizontal.sd-tabs-full-height .sd-tabs-content-list {
436
+ height: 100%;
437
+ }
438
+ .sd-tabs-horizontal.sd-tabs-full-height .sd-tabs-content-item-active {
439
+ height: 100%;
440
+ }
441
+ .sd-tabs-horizontal.sd-tabs-full-height .sd-tabs-pane {
442
+ height: 100%;
443
+ overflow: auto;
444
+ }
445
+ .sd-tabs-horizontal.sd-tabs-full-height .sd-tabs-pane-scroll {
446
+ overflow: hidden;
447
+ }
448
+ .sd-tabs-horizontal.sd-tabs-full-height .sd-tabs-pane-scrollbar {
449
+ height: 100%;
450
+ }
451
+
423
452
  .sd-tabs-nav-size-mini.sd-tabs-nav-type-line .sd-tabs-nav-extra {
424
453
  font-size: 12px;
425
454
  line-height: 32px;
@@ -643,6 +643,44 @@ $tabs-prefix-cls: string.unquote('#{theme.$prefix}-tabs');
643
643
  }
644
644
  }
645
645
 
646
+ // full-height:撑满父容器高度(仅水平方向),内容区域自动滚动
647
+ .#{$tabs-prefix-cls}-horizontal.#{$tabs-prefix-cls}-full-height {
648
+ display: flex;
649
+ flex-direction: column;
650
+ height: 100%;
651
+
652
+ > .#{$tabs-prefix-cls}-nav {
653
+ flex-shrink: 0;
654
+ }
655
+
656
+ .#{$tabs-prefix-cls}-content {
657
+ flex: 1;
658
+ min-height: 0;
659
+ }
660
+
661
+ .#{$tabs-prefix-cls}-content-list {
662
+ height: 100%;
663
+ }
664
+
665
+ .#{$tabs-prefix-cls}-content-item-active {
666
+ height: 100%;
667
+ }
668
+
669
+ .#{$tabs-prefix-cls}-pane {
670
+ height: 100%;
671
+ overflow: auto;
672
+ }
673
+
674
+ // scrollbar !== false:使用 Scrollbar 组件,pane 不再原生滚动
675
+ .#{$tabs-prefix-cls}-pane-scroll {
676
+ overflow: hidden;
677
+ }
678
+
679
+ .#{$tabs-prefix-cls}-pane-scrollbar {
680
+ height: 100%;
681
+ }
682
+ }
683
+
646
684
  @mixin for($data, $i: 1) {
647
685
  @if ($i <= list.length($data)) {
648
686
  $size: list.nth($data, $i);
@@ -1,6 +1,8 @@
1
- declare var __VLS_1: {};
1
+ declare var __VLS_7: {}, __VLS_9: {};
2
2
  type __VLS_Slots = {} & {
3
- default?: (props: typeof __VLS_1) => any;
3
+ default?: (props: typeof __VLS_7) => any;
4
+ } & {
5
+ default?: (props: typeof __VLS_9) => any;
4
6
  };
5
7
  declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
6
8
  title: StringConstructor;
@@ -1,7 +1,8 @@
1
1
  import { _objectSpread2 } from "../_virtual/_@oxc-project_runtime@0.133.0/helpers/esm/objectSpread2.js";
2
2
  import { getPrefixCls } from "../_utils/global-config.js";
3
+ import Scrollbar from "../scrollbar/index.js";
3
4
  import { tabsInjectionKey } from "./context.js";
4
- import { computed, createCommentVNode, createElementBlock, defineComponent, getCurrentInstance, inject, normalizeClass, onBeforeUnmount, onUpdated, openBlock, reactive, ref, renderSlot, toRefs, unref, useSlots, watch } from "vue";
5
+ import { computed, createBlock, createCommentVNode, createElementBlock, defineComponent, getCurrentInstance, inject, mergeProps, normalizeClass, onBeforeUnmount, onUpdated, openBlock, reactive, ref, renderSlot, toRefs, unref, useSlots, watch, withCtx } from "vue";
5
6
  //#region components/tabs/tab-pane.vue?vue&type=script&setup=true&lang.ts
6
7
  var tab_pane_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineComponent(_objectSpread2(_objectSpread2({}, { name: "TabPane" }), {}, {
7
8
  __name: "tab-pane",
@@ -53,6 +54,15 @@ var tab_pane_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineC
53
54
  const key = computed(() => instance === null || instance === void 0 ? void 0 : instance.vnode.key);
54
55
  const active = computed(() => key.value === tabsCtx.activeKey);
55
56
  const mounted = ref(tabsCtx.lazyLoad ? active.value : true);
57
+ const paneScrollbarProps = computed(() => {
58
+ const { scrollbar } = tabsCtx;
59
+ return scrollbar === false || scrollbar === void 0 ? {} : scrollbar;
60
+ });
61
+ const hasPaneScrollbar = computed(() => {
62
+ const { scrollbar } = tabsCtx;
63
+ return scrollbar !== false && scrollbar !== void 0;
64
+ });
65
+ const paneCls = computed(() => [`${prefixCls}-pane`, { [`${prefixCls}-pane-scroll`]: hasPaneScrollbar.value }]);
56
66
  const data = reactive({
57
67
  key,
58
68
  title,
@@ -85,8 +95,14 @@ var tab_pane_vue_vue_type_script_setup_true_lang_default = /*@__PURE__*/ defineC
85
95
  class: normalizeClass([`${unref(prefixCls)}-content-item`, { [`${unref(prefixCls)}-content-item-active`]: active.value }])
86
96
  }, [mounted.value ? (openBlock(), createElementBlock("div", {
87
97
  key: 0,
88
- class: normalizeClass(`${unref(prefixCls)}-pane`)
89
- }, [renderSlot(_ctx.$slots, "default")], 2)) : createCommentVNode("", true)], 2);
98
+ class: normalizeClass(paneCls.value)
99
+ }, [hasPaneScrollbar.value ? (openBlock(), createBlock(unref(Scrollbar), mergeProps({
100
+ key: 0,
101
+ "outer-class": `${unref(prefixCls)}-pane-scrollbar`
102
+ }, paneScrollbarProps.value), {
103
+ default: withCtx(() => [renderSlot(_ctx.$slots, "default")]),
104
+ _: 3
105
+ }, 16, ["outer-class"])) : renderSlot(_ctx.$slots, "default", { key: 1 })], 2)) : createCommentVNode("", true)], 2);
90
106
  };
91
107
  }
92
108
  }));
package/es/tabs/tabs.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import type { PropType } from 'vue';
2
2
  import type { Direction, Size } from '../_utils/constant';
3
+ import type { ScrollbarProps } from '../scrollbar';
3
4
  import type { TabsPosition, TabsType, TabTriggerEvent, ScrollPosition } from './interface';
4
5
  declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
5
6
  activeKey: {
@@ -69,6 +70,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
69
70
  type: PropType<ScrollPosition>;
70
71
  default: string;
71
72
  };
73
+ fullHeight: {
74
+ type: BooleanConstructor;
75
+ default: boolean;
76
+ };
77
+ scrollbar: {
78
+ type: PropType<boolean | ScrollbarProps>;
79
+ default: boolean;
80
+ };
72
81
  }>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
73
82
  'update:activeKey': (_key: string | number) => true;
74
83
  change: (_key: string | number) => true;
@@ -143,6 +152,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
143
152
  type: PropType<ScrollPosition>;
144
153
  default: string;
145
154
  };
155
+ fullHeight: {
156
+ type: BooleanConstructor;
157
+ default: boolean;
158
+ };
159
+ scrollbar: {
160
+ type: PropType<boolean | ScrollbarProps>;
161
+ default: boolean;
162
+ };
146
163
  }>> & Readonly<{
147
164
  onDelete?: ((_key: string | number, _ev: Event) => any) | undefined;
148
165
  onAdd?: ((_ev: Event) => any) | undefined;
@@ -154,9 +171,11 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
154
171
  trigger: TabTriggerEvent;
155
172
  position: TabsPosition;
156
173
  direction: "horizontal" | "vertical";
174
+ scrollbar: boolean | ScrollbarProps;
157
175
  activeKey: string | number;
158
176
  animation: boolean;
159
177
  justify: boolean;
178
+ fullHeight: boolean;
160
179
  destroyOnHide: boolean;
161
180
  defaultActiveKey: string | number;
162
181
  editable: boolean;
package/es/tabs/tabs.js CHANGED
@@ -2,10 +2,11 @@ import { configProviderInjectionKey } from "../config-provider/context.js";
2
2
  import { getPrefixCls } from "../_utils/global-config.js";
3
3
  import { isUndefined } from "../_utils/is.js";
4
4
  import { useSize } from "../_hooks/use-size.js";
5
+ import { useScrollbar } from "../_hooks/use-scrollbar.js";
5
6
  import { useChildrenComponents } from "../_hooks/use-children-components.js";
6
7
  import { tabsInjectionKey } from "./context.js";
7
8
  import tabs_nav_default from "./tabs-nav.js";
8
- import { computed, createVNode, defineComponent, inject, nextTick, provide, reactive, ref, toRefs } from "vue";
9
+ import { computed, createVNode, defineComponent, inject, nextTick, provide, reactive, ref, toRef, toRefs } from "vue";
9
10
  //#region components/tabs/tabs.tsx
10
11
  var tabs_default = /* @__PURE__ */ defineComponent({
11
12
  name: "Tabs",
@@ -154,6 +155,23 @@ var tabs_default = /* @__PURE__ */ defineComponent({
154
155
  scrollPosition: {
155
156
  type: [String, Number],
156
157
  default: "auto"
158
+ },
159
+ /**
160
+ * @zh 是否高度撑满父容器(仅在水平方向生效,内容区域自动滚动)
161
+ * @en Whether to fill the height of the parent container (only effective in horizontal direction, the content area scrolls automatically)
162
+ */
163
+ fullHeight: {
164
+ type: Boolean,
165
+ default: false
166
+ },
167
+ /**
168
+ * @zh 内容区域是否使用 Scrollbar 组件滚动,可传入对象自定义滚动条配置。为 false 时使用原生 overflow 滚动。仅 `full-height` 为 true 时生效
169
+ * @en Whether the content area uses the Scrollbar component for scrolling, an object can be passed to customize the scrollbar. When false, native overflow scrolling is used. Only effective when `full-height` is true
170
+ * @defaultValue true
171
+ */
172
+ scrollbar: {
173
+ type: [Boolean, Object],
174
+ default: true
157
175
  }
158
176
  },
159
177
  emits: {
@@ -222,13 +240,15 @@ var tabs_default = /* @__PURE__ */ defineComponent({
222
240
  if (index === -1) return 0;
223
241
  return index;
224
242
  });
243
+ const { scrollbarProps } = useScrollbar(toRef(props, "scrollbar"));
225
244
  provide(tabsInjectionKey, reactive({
226
245
  lazyLoad,
227
246
  destroyOnHide,
228
247
  activeKey: computedActiveKey,
229
248
  addItem,
230
249
  removeItem,
231
- trigger
250
+ trigger,
251
+ scrollbar: computed(() => props.fullHeight && props.scrollbar !== false ? scrollbarProps.value : false)
232
252
  }));
233
253
  const handleChange = (key) => {
234
254
  if (key !== computedActiveKey.value) {
@@ -270,6 +290,7 @@ var tabs_default = /* @__PURE__ */ defineComponent({
270
290
  `${prefixCls}-size-${mergedSize.value}`,
271
291
  {
272
292
  [`${prefixCls}-justify`]: props.justify,
293
+ [`${prefixCls}-full-height`]: props.fullHeight,
273
294
  [`${prefixCls}-rtl`]: rtl.value
274
295
  }
275
296
  ]);
@@ -13,6 +13,10 @@ declare const Textarea: {
13
13
  type: BooleanConstructor;
14
14
  default: boolean;
15
15
  };
16
+ readonly: {
17
+ type: (StringConstructor | BooleanConstructor)[];
18
+ default: boolean;
19
+ };
16
20
  error: {
17
21
  type: BooleanConstructor;
18
22
  default: boolean;
@@ -67,6 +71,7 @@ declare const Textarea: {
67
71
  "update:modelValue": (_value: string) => any;
68
72
  }, import("vue").PublicProps, {
69
73
  error: boolean;
74
+ readonly: string | boolean;
70
75
  disabled: boolean;
71
76
  defaultValue: string;
72
77
  allowClear: boolean;
@@ -97,6 +102,10 @@ declare const Textarea: {
97
102
  type: BooleanConstructor;
98
103
  default: boolean;
99
104
  };
105
+ readonly: {
106
+ type: (StringConstructor | BooleanConstructor)[];
107
+ default: boolean;
108
+ };
100
109
  error: {
101
110
  type: BooleanConstructor;
102
111
  default: boolean;
@@ -144,6 +153,7 @@ declare const Textarea: {
144
153
  blur: () => void;
145
154
  }, {}, {}, {}, {
146
155
  error: boolean;
156
+ readonly: string | boolean;
147
157
  disabled: boolean;
148
158
  defaultValue: string;
149
159
  allowClear: boolean;
@@ -171,6 +181,10 @@ declare const Textarea: {
171
181
  type: BooleanConstructor;
172
182
  default: boolean;
173
183
  };
184
+ readonly: {
185
+ type: (StringConstructor | BooleanConstructor)[];
186
+ default: boolean;
187
+ };
174
188
  error: {
175
189
  type: BooleanConstructor;
176
190
  default: boolean;
@@ -225,6 +239,7 @@ declare const Textarea: {
225
239
  "update:modelValue": (_value: string) => any;
226
240
  }, string, {
227
241
  error: boolean;
242
+ readonly: string | boolean;
228
243
  disabled: boolean;
229
244
  defaultValue: string;
230
245
  allowClear: boolean;
@@ -1,9 +1,9 @@
1
1
  import { PropType } from 'vue';
2
2
  declare function focus(): void;
3
3
  declare function blur(): void;
4
- declare var __VLS_9: {};
4
+ declare var __VLS_16: {};
5
5
  type __VLS_Slots = {} & {
6
- suffix?: (props: typeof __VLS_9) => any;
6
+ suffix?: (props: typeof __VLS_16) => any;
7
7
  };
8
8
  declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
9
9
  modelValue: StringConstructor;
@@ -16,6 +16,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
16
16
  type: BooleanConstructor;
17
17
  default: boolean;
18
18
  };
19
+ readonly: {
20
+ type: (StringConstructor | BooleanConstructor)[];
21
+ default: boolean;
22
+ };
19
23
  error: {
20
24
  type: BooleanConstructor;
21
25
  default: boolean;
@@ -72,6 +76,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
72
76
  type: BooleanConstructor;
73
77
  default: boolean;
74
78
  };
79
+ readonly: {
80
+ type: (StringConstructor | BooleanConstructor)[];
81
+ default: boolean;
82
+ };
75
83
  error: {
76
84
  type: BooleanConstructor;
77
85
  default: boolean;
@@ -116,6 +124,7 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
116
124
  "onUpdate:modelValue"?: ((_value: string) => any) | undefined;
117
125
  }>, {
118
126
  error: boolean;
127
+ readonly: string | boolean;
119
128
  disabled: boolean;
120
129
  defaultValue: string;
121
130
  allowClear: boolean;