@expcat/tigercat-vue 2.1.0 → 2.1.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 (198) hide show
  1. package/dist/{chunk-7W3NALIL.mjs → chunk-3FPS7XVB.mjs} +26 -27
  2. package/dist/{chunk-2OI6GWOT.mjs → chunk-3KAHJF7D.mjs} +12 -11
  3. package/dist/{chunk-IEAEB4TX.mjs → chunk-3OCHBGPF.mjs} +242 -51
  4. package/dist/{chunk-OHR7IUBQ.mjs → chunk-5OILGUNU.mjs} +2 -2
  5. package/dist/{chunk-OQVGB7X6.mjs → chunk-626VUZ2Q.mjs} +1 -1
  6. package/dist/{chunk-66OS5A4D.mjs → chunk-67VS6QHJ.mjs} +26 -12
  7. package/dist/{chunk-EHGFW5GX.mjs → chunk-6JAAXPBW.mjs} +4 -3
  8. package/dist/{chunk-JHMT5Q6P.mjs → chunk-6NYC7EY2.mjs} +29 -15
  9. package/dist/{chunk-6BDDX2R4.mjs → chunk-73Z7N7VG.mjs} +1 -4
  10. package/dist/{chunk-F3ZVVVYD.mjs → chunk-7C7SG3SS.mjs} +15 -3
  11. package/dist/{chunk-CHEXI7MO.mjs → chunk-7TJE7OYH.mjs} +4 -3
  12. package/dist/{chunk-EGIMTTZA.mjs → chunk-BOHE5URZ.mjs} +18 -3
  13. package/dist/{chunk-5RIHHZF6.mjs → chunk-BQK7LH2L.mjs} +4 -1
  14. package/dist/{chunk-E6EZHSGY.mjs → chunk-BSOLH6R5.mjs} +0 -1
  15. package/dist/{chunk-RSM6FOWX.mjs → chunk-CCC3S6LK.mjs} +6 -3
  16. package/dist/{chunk-U75YXWSA.mjs → chunk-CLTRADS7.mjs} +17 -5
  17. package/dist/{chunk-BEIPGX74.mjs → chunk-DRLQCY7R.mjs} +162 -7
  18. package/dist/{chunk-KBJANUZZ.mjs → chunk-E523VGZP.mjs} +1 -1
  19. package/dist/{chunk-4HUYX5WW.mjs → chunk-EC62TY2Y.mjs} +80 -19
  20. package/dist/{chunk-D3U2NJ32.mjs → chunk-FEQ7PZXI.mjs} +8 -2
  21. package/dist/{chunk-PE5OA4YG.mjs → chunk-FHUGOSEY.mjs} +8 -2
  22. package/dist/{chunk-OAPIT53X.mjs → chunk-FIEECAJV.mjs} +7 -10
  23. package/dist/{chunk-7SFB77JR.mjs → chunk-GBPMQJJJ.mjs} +8 -1
  24. package/dist/{chunk-6AMWX5K4.mjs → chunk-GQOPDD44.mjs} +1 -1
  25. package/dist/{chunk-5RXYJWNA.mjs → chunk-H4DEIGEG.mjs} +77 -25
  26. package/dist/{chunk-AU6IC6K7.mjs → chunk-IFASMNTU.mjs} +36 -16
  27. package/dist/{chunk-EZYOCPMM.mjs → chunk-IK2WHKDA.mjs} +29 -15
  28. package/dist/{chunk-HGXD57QM.mjs → chunk-JBS3AESR.mjs} +65 -23
  29. package/dist/{chunk-PYRKFQ6J.mjs → chunk-JIU5UEOU.mjs} +70 -26
  30. package/dist/{chunk-JALHMWKW.mjs → chunk-K5MHUMKR.mjs} +2 -2
  31. package/dist/{chunk-BZ6MVFV7.mjs → chunk-K5RYFPOQ.mjs} +17 -19
  32. package/dist/{chunk-DI6RRAGQ.mjs → chunk-KIUGJNQO.mjs} +4 -4
  33. package/dist/{chunk-5E4LINDO.mjs → chunk-LH2V2JMZ.mjs} +26 -10
  34. package/dist/{chunk-PQBKN2NH.mjs → chunk-LRFKHJDU.mjs} +14 -5
  35. package/dist/{chunk-W5XFWVNV.mjs → chunk-M4FWWEMX.mjs} +15 -6
  36. package/dist/{chunk-VLW3UBIR.mjs → chunk-N2XV37BL.mjs} +37 -41
  37. package/dist/{chunk-2LIIMWBR.mjs → chunk-OYU47A57.mjs} +1 -2
  38. package/dist/{chunk-KU2Q5V3L.mjs → chunk-P62TYR3M.mjs} +18 -2
  39. package/dist/{chunk-P5FDKBXG.mjs → chunk-P7X46BAW.mjs} +70 -3
  40. package/dist/{chunk-KROVW4AW.mjs → chunk-PJQTRDIG.mjs} +13 -3
  41. package/dist/{chunk-26OI3TEA.mjs → chunk-PMQSXEMT.mjs} +42 -6
  42. package/dist/{chunk-XLNK3Z2P.mjs → chunk-POWDTOMF.mjs} +88 -79
  43. package/dist/{chunk-AXDBME5A.mjs → chunk-PSGVG4TN.mjs} +38 -21
  44. package/dist/{chunk-7DWWNFRP.mjs → chunk-PWWWACHC.mjs} +1 -1
  45. package/dist/{chunk-UUWTKCMY.mjs → chunk-QWLD5FMJ.mjs} +1 -1
  46. package/dist/{chunk-ALIUAGJO.mjs → chunk-QZLOF36M.mjs} +7 -13
  47. package/dist/{chunk-WLYQHKLZ.mjs → chunk-QZRSFGZZ.mjs} +50 -11
  48. package/dist/{chunk-37W7XTA6.mjs → chunk-RHQWQJ4I.mjs} +4 -3
  49. package/dist/{chunk-32X54QKW.mjs → chunk-RRLE7QRH.mjs} +43 -22
  50. package/dist/{chunk-RID7A5V7.mjs → chunk-RRNQL6MJ.mjs} +23 -6
  51. package/dist/{chunk-VJ6YM2EW.mjs → chunk-S4BKVFQ7.mjs} +1 -1
  52. package/dist/{chunk-LPZBXTJ6.mjs → chunk-SAC4PAG3.mjs} +4 -4
  53. package/dist/{chunk-W5RZPTFD.mjs → chunk-SNNT64HK.mjs} +13 -2
  54. package/dist/{chunk-N3C6YI7I.mjs → chunk-SWMYIORV.mjs} +22 -7
  55. package/dist/{chunk-U4B5QT72.mjs → chunk-SX3NAN4M.mjs} +1 -1
  56. package/dist/{chunk-JL3CN4UK.mjs → chunk-TDBMAKTJ.mjs} +10 -3
  57. package/dist/chunk-UEGNXN5B.mjs +28 -0
  58. package/dist/{chunk-NEEGXKJW.mjs → chunk-UGHLEKEZ.mjs} +22 -3
  59. package/dist/{chunk-HKYRRQS7.mjs → chunk-UNQO7EVG.mjs} +1 -1
  60. package/dist/{chunk-VN2TWPRC.mjs → chunk-UR5F74ZB.mjs} +112 -18
  61. package/dist/{chunk-VCCK4CDT.mjs → chunk-URPXBKK4.mjs} +23 -5
  62. package/dist/{chunk-7KCOF5US.mjs → chunk-VY6FVIOZ.mjs} +10 -8
  63. package/dist/{chunk-KICZSLOX.mjs → chunk-W2ICYZVU.mjs} +1 -1
  64. package/dist/{chunk-FIVVKBBF.mjs → chunk-W3QOMJKQ.mjs} +8 -6
  65. package/dist/{chunk-DCMRB3HR.mjs → chunk-WV25G4M3.mjs} +4 -3
  66. package/dist/{chunk-ZOYHZF4N.mjs → chunk-X5LJT76O.mjs} +49 -32
  67. package/dist/{chunk-FSJRNEZK.mjs → chunk-YLO73TDM.mjs} +4 -4
  68. package/dist/{chunk-BNYA5IUB.mjs → chunk-YNXP34KO.mjs} +39 -38
  69. package/dist/{chunk-2T2NEZRZ.mjs → chunk-YVDTXHQ6.mjs} +1 -1
  70. package/dist/{chunk-AUMTHL6N.mjs → chunk-ZOP7PEKY.mjs} +2 -1
  71. package/dist/components/ActivityFeed.d.mts +23 -5
  72. package/dist/components/ActivityFeed.mjs +2 -2
  73. package/dist/components/Affix.mjs +1 -1
  74. package/dist/components/Alert.d.mts +1 -1
  75. package/dist/components/Anchor.d.mts +1 -1
  76. package/dist/components/Anchor.mjs +1 -1
  77. package/dist/components/AreaChart.mjs +4 -3
  78. package/dist/components/AutoComplete.mjs +1 -1
  79. package/dist/components/BarChart.mjs +4 -3
  80. package/dist/components/Calendar.mjs +1 -1
  81. package/dist/components/Cascader.mjs +1 -1
  82. package/dist/components/ChartCanvas.d.mts +7 -3
  83. package/dist/components/ChartCanvas.mjs +1 -1
  84. package/dist/components/ChatWindow.d.mts +26 -8
  85. package/dist/components/ChatWindow.mjs +3 -3
  86. package/dist/components/Checkbox.d.mts +1 -1
  87. package/dist/components/Code.d.mts +34 -7
  88. package/dist/components/Code.mjs +3 -1
  89. package/dist/components/CodeEditor.d.mts +1 -1
  90. package/dist/components/CollapsePanel.mjs +1 -1
  91. package/dist/components/ColorPicker.d.mts +19 -1
  92. package/dist/components/ColorPicker.mjs +3 -1
  93. package/dist/components/ColorSwatch.d.mts +6 -0
  94. package/dist/components/ColorSwatch.mjs +1 -1
  95. package/dist/components/CommentThread.d.mts +63 -27
  96. package/dist/components/CommentThread.mjs +2 -2
  97. package/dist/components/ContextMenu.d.mts +2 -2
  98. package/dist/components/Countdown.d.mts +2 -2
  99. package/dist/components/CronEditor.d.mts +1 -1
  100. package/dist/components/DataExport.mjs +2 -2
  101. package/dist/components/DataTableWithToolbar.mjs +8 -8
  102. package/dist/components/DatePicker.d.mts +1 -1
  103. package/dist/components/Descriptions.d.mts +1 -1
  104. package/dist/components/DonutChart.mjs +4 -4
  105. package/dist/components/Drawer.d.mts +1 -1
  106. package/dist/components/Dropdown.d.mts +21 -2
  107. package/dist/components/Dropdown.mjs +1 -1
  108. package/dist/components/FileManager.d.mts +7 -1
  109. package/dist/components/FileManager.mjs +1 -1
  110. package/dist/components/FloatButton.d.mts +31 -1
  111. package/dist/components/FloatButton.mjs +1 -1
  112. package/dist/components/FormWizard.mjs +1 -1
  113. package/dist/components/FunnelChart.mjs +3 -3
  114. package/dist/components/Gantt.d.mts +3 -1
  115. package/dist/components/Gantt.mjs +2 -2
  116. package/dist/components/GaugeChart.mjs +2 -2
  117. package/dist/components/HeatmapChart.mjs +3 -3
  118. package/dist/components/Icon.d.mts +1 -1
  119. package/dist/components/Image.d.mts +1 -1
  120. package/dist/components/Image.mjs +3 -3
  121. package/dist/components/ImageAnnotation.d.mts +1 -1
  122. package/dist/components/ImageGroup.mjs +2 -2
  123. package/dist/components/ImagePreview.mjs +1 -1
  124. package/dist/components/Input.mjs +1 -1
  125. package/dist/components/InputNumber.mjs +1 -1
  126. package/dist/components/InputOTP.d.mts +1 -1
  127. package/dist/components/Kanban.mjs +2 -2
  128. package/dist/components/LineChart.mjs +4 -3
  129. package/dist/components/Link.d.mts +1 -1
  130. package/dist/components/List.mjs +2 -2
  131. package/dist/components/Loading.mjs +1 -1
  132. package/dist/components/MarkdownEditor.d.mts +1 -1
  133. package/dist/components/MarkdownEditor.mjs +1 -1
  134. package/dist/components/MaskInput.d.mts +9 -3
  135. package/dist/components/MaskInput.mjs +1 -1
  136. package/dist/components/Menu.d.mts +2 -2
  137. package/dist/components/Modal.d.mts +1 -1
  138. package/dist/components/NavigationMenu.d.mts +3 -3
  139. package/dist/components/NotificationCenter.d.mts +44 -26
  140. package/dist/components/NotificationCenter.mjs +4 -4
  141. package/dist/components/NumberKeyboard.d.mts +1 -1
  142. package/dist/components/OrgChart.mjs +2 -2
  143. package/dist/components/PageHeader.d.mts +1 -1
  144. package/dist/components/Pagination.mjs +1 -1
  145. package/dist/components/PieChart.mjs +3 -3
  146. package/dist/components/Popconfirm.d.mts +1 -1
  147. package/dist/components/Popconfirm.mjs +2 -2
  148. package/dist/components/Popover.d.mts +2 -2
  149. package/dist/components/Popover.mjs +2 -2
  150. package/dist/components/QRCode.d.mts +2 -11
  151. package/dist/components/QRCode.mjs +1 -1
  152. package/dist/components/RadarChart.mjs +3 -3
  153. package/dist/components/Radio.d.mts +1 -1
  154. package/dist/components/Radio.mjs +1 -1
  155. package/dist/components/Rate.mjs +1 -1
  156. package/dist/components/Result.d.mts +1 -1
  157. package/dist/components/RichTextEditor.d.mts +1 -1
  158. package/dist/components/RichTextEditor.mjs +1 -1
  159. package/dist/components/ScatterChart.mjs +4 -3
  160. package/dist/components/ScrollSpy.mjs +1 -1
  161. package/dist/components/Select.d.mts +4 -6
  162. package/dist/components/Select.mjs +1 -1
  163. package/dist/components/Signature.mjs +1 -1
  164. package/dist/components/Slider.d.mts +18 -0
  165. package/dist/components/Slider.mjs +1 -1
  166. package/dist/components/SplitButton.d.mts +1 -1
  167. package/dist/components/SplitButton.mjs +2 -2
  168. package/dist/components/Splitter.d.mts +4 -4
  169. package/dist/components/Splitter.mjs +1 -1
  170. package/dist/components/Spotlight.d.mts +1 -1
  171. package/dist/components/Statistic.d.mts +2 -2
  172. package/dist/components/Stepper.d.mts +7 -1
  173. package/dist/components/Stepper.mjs +1 -1
  174. package/dist/components/SunburstChart.mjs +3 -3
  175. package/dist/components/Switch.d.mts +22 -6
  176. package/dist/components/Switch.mjs +1 -1
  177. package/dist/components/Table.d.mts +4 -4
  178. package/dist/components/Table.mjs +4 -4
  179. package/dist/components/TagsInput.d.mts +1 -1
  180. package/dist/components/TaskBoard.mjs +1 -1
  181. package/dist/components/Text.d.mts +2 -2
  182. package/dist/components/Textarea.mjs +1 -1
  183. package/dist/components/TimePicker.d.mts +1 -1
  184. package/dist/components/Tooltip.d.mts +1 -1
  185. package/dist/components/Tooltip.mjs +2 -2
  186. package/dist/components/Tour.mjs +1 -1
  187. package/dist/components/Transfer.d.mts +2 -1
  188. package/dist/components/Transfer.mjs +1 -1
  189. package/dist/components/TreeMapChart.mjs +3 -3
  190. package/dist/components/TreeSelect.mjs +1 -1
  191. package/dist/components/Upload.d.mts +1 -1
  192. package/dist/components/Upload.mjs +1 -1
  193. package/dist/components/Watermark.d.mts +1 -1
  194. package/dist/composables/useChartInteraction.d.mts +5 -0
  195. package/dist/composables/useChartInteraction.mjs +1 -1
  196. package/dist/index.d.mts +1 -1
  197. package/dist/index.mjs +57 -0
  198. package/package.json +2 -2
@@ -31,6 +31,7 @@ import {
31
31
  getPickerOptionAria,
32
32
  getPickerTriggerKeyAction,
33
33
  getPickerNavigationIndex,
34
+ getPickerOptionId,
34
35
  findFirstEnabledIndex,
35
36
  coerceClassValue,
36
37
  classNames,
@@ -234,20 +235,19 @@ var TreeSelect = defineComponent({
234
235
  commitActiveIndex(-1);
235
236
  return;
236
237
  }
237
- if (!props.virtual) return;
238
238
  commitActiveIndex(resolveActiveIndex());
239
239
  nextTick(() => alignVirtualScroll(activeIndex.value));
240
240
  });
241
241
  watch(activeIndex, (idx) => {
242
- if (!props.virtual || !isOpen.value) return;
242
+ if (!isOpen.value) return;
243
243
  nextTick(() => alignVirtualScroll(idx));
244
244
  });
245
245
  watch(searchQuery, () => {
246
- if (!props.virtual || !isOpen.value) return;
246
+ if (!isOpen.value) return;
247
247
  commitActiveIndex(resolveActiveIndex());
248
248
  });
249
249
  watch([expandedKeys, () => props.treeData], () => {
250
- if (!props.virtual || !isOpen.value) return;
250
+ if (!isOpen.value) return;
251
251
  const remapped = getTreeSelectVisibleIndex(visibleNodes.value, lastActiveKey.value);
252
252
  if (remapped >= 0) activeIndex.value = remapped;
253
253
  });
@@ -316,7 +316,49 @@ var TreeSelect = defineComponent({
316
316
  emit("update:modelValue", val);
317
317
  emit("change", val);
318
318
  }
319
+ function handleOpenListKeyDown(e, fromSearchInput = false) {
320
+ const key = e.key;
321
+ if (fromSearchInput && key === " ") return false;
322
+ if (key === "ArrowDown" || key === "ArrowUp" || key === "Home" || key === "End") {
323
+ e.preventDefault();
324
+ e.stopPropagation();
325
+ commitActiveIndex(
326
+ getPickerNavigationIndex(visibleNodes.value, activeIndex.value, key, isNodeDisabled)
327
+ );
328
+ return true;
329
+ }
330
+ if (key === "Enter" || key === " ") {
331
+ e.preventDefault();
332
+ e.stopPropagation();
333
+ const item = visibleNodes.value[activeIndex.value];
334
+ if (item && !item.node.disabled) {
335
+ handleNodeSelect(item.node);
336
+ }
337
+ return true;
338
+ }
339
+ if (key === "ArrowRight") {
340
+ e.preventDefault();
341
+ e.stopPropagation();
342
+ const item = visibleNodes.value[activeIndex.value];
343
+ if (item?.hasChildren && !item.isExpanded) {
344
+ toggleExpand(item.node.key);
345
+ }
346
+ return true;
347
+ }
348
+ if (key === "ArrowLeft") {
349
+ e.preventDefault();
350
+ e.stopPropagation();
351
+ const item = visibleNodes.value[activeIndex.value];
352
+ if (item?.hasChildren && item.isExpanded) {
353
+ toggleExpand(item.node.key);
354
+ }
355
+ return true;
356
+ }
357
+ return false;
358
+ }
319
359
  function handleKeyDown(e) {
360
+ if (props.disabled) return;
361
+ if (isOpen.value && handleOpenListKeyDown(e)) return;
320
362
  const action = getPickerTriggerKeyAction(e.key, isOpen.value);
321
363
  if (action === "none") return;
322
364
  e.preventDefault();
@@ -329,16 +371,47 @@ var TreeSelect = defineComponent({
329
371
  closeDropdown();
330
372
  }
331
373
  }
332
- function renderFlatNode(flatNode) {
374
+ function handleDropdownKeyDown(e) {
375
+ if (e.target instanceof HTMLInputElement) return;
376
+ if (!isOpen.value) return;
377
+ handleOpenListKeyDown(e);
378
+ }
379
+ function handleSearchKeyDown(e) {
380
+ switch (e.key) {
381
+ case " ":
382
+ e.stopPropagation();
383
+ return;
384
+ case "ArrowDown":
385
+ case "ArrowUp":
386
+ case "Enter":
387
+ handleOpenListKeyDown(e, true);
388
+ return;
389
+ case "Escape":
390
+ e.preventDefault();
391
+ e.stopPropagation();
392
+ closeDropdown();
393
+ nextTick(() => {
394
+ ;
395
+ triggerRef.value?.focus();
396
+ });
397
+ return;
398
+ default:
399
+ return;
400
+ }
401
+ }
402
+ function renderFlatNode(flatNode, index) {
333
403
  const { node, level, hasChildren, isExpanded } = flatNode;
334
404
  const selected = isSelected(node.key);
405
+ const isActive = index === activeIndex.value;
335
406
  const indent = level * 20;
336
407
  return h(
337
408
  "div",
338
409
  {
339
410
  key: node.key,
411
+ id: getPickerOptionId(listboxId, index),
412
+ "data-active": isActive || void 0,
340
413
  ...getPickerOptionAria({ selected, disabled: !!node.disabled }),
341
- class: getTreeSelectNodeClasses(selected, !!node.disabled, props.size),
414
+ class: getTreeSelectNodeClasses(selected || isActive, !!node.disabled, props.size),
342
415
  style: { paddingLeft: `${indent + 8}px`, height: props.virtual ? "100%" : void 0 },
343
416
  onClick: (e) => {
344
417
  e.stopPropagation();
@@ -389,8 +462,15 @@ var TreeSelect = defineComponent({
389
462
  {
390
463
  ref: triggerRef,
391
464
  type: "button",
392
- class: getTreeSelectTriggerClasses(props.size, props.disabled, isOpen.value),
393
- ...getPickerComboboxAria({ expanded: isOpen.value, listboxId }),
465
+ class: classNames(
466
+ getTreeSelectTriggerClasses(props.size, props.disabled, isOpen.value),
467
+ showClearButton.value ? "pr-14" : void 0
468
+ ),
469
+ ...getPickerComboboxAria({
470
+ expanded: isOpen.value,
471
+ listboxId,
472
+ activeIndex: isOpen.value ? activeIndex.value : -1
473
+ }),
394
474
  disabled: props.disabled,
395
475
  onClick: toggleDropdown,
396
476
  onKeydown: handleKeyDown
@@ -405,12 +485,19 @@ var TreeSelect = defineComponent({
405
485
  )
406
486
  },
407
487
  displayLabel.value || props.placeholder
408
- ),
409
- // Clear or chevron
488
+ )
489
+ ]
490
+ ),
491
+ h(
492
+ "span",
493
+ { class: "pointer-events-none absolute inset-y-0 right-3 flex items-center gap-1" },
494
+ [
410
495
  showClearButton.value ? h(
411
- "span",
496
+ "button",
412
497
  {
413
- class: "absolute right-2 top-1/2 -translate-y-1/2 text-[var(--tiger-treeselect-clear,var(--tiger-text-muted,#9ca3af))] hover:text-[var(--tiger-treeselect-clear-hover,var(--tiger-text,#111827))]",
498
+ type: "button",
499
+ class: "pointer-events-auto inline-flex rounded-sm focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--tiger-treeselect-ring,var(--tiger-primary,#2563eb))] text-[var(--tiger-treeselect-clear,var(--tiger-text-muted,#9ca3af))] hover:text-[var(--tiger-treeselect-clear-hover,var(--tiger-text,#111827))]",
500
+ "data-tiger-treeselect-clear": "",
414
501
  "aria-label": resolveLocaleText(
415
502
  "Clear selection",
416
503
  mergedLocale.value?.common?.clearText
@@ -418,10 +505,15 @@ var TreeSelect = defineComponent({
418
505
  onClick: handleClear
419
506
  },
420
507
  [ClearIcon]
421
- ) : h(
508
+ ) : null,
509
+ h(
422
510
  "span",
423
511
  {
424
- class: "absolute right-2 top-1/2 -translate-y-1/2 text-[var(--tiger-text-muted,#9ca3af)] pointer-events-none"
512
+ class: classNames(
513
+ "inline-flex text-[var(--tiger-text-muted,#9ca3af)]",
514
+ isOpen.value && "rotate-180"
515
+ ),
516
+ "aria-hidden": "true"
425
517
  },
426
518
  [ChevronDownIcon]
427
519
  )
@@ -439,7 +531,8 @@ var TreeSelect = defineComponent({
439
531
  overlay.floatingClasses.value
440
532
  ),
441
533
  style: overlay.floatingStyles.value,
442
- "data-positioned": overlay.positioned.value
534
+ "data-positioned": overlay.positioned.value,
535
+ onKeydown: handleDropdownKeyDown
443
536
  },
444
537
  [
445
538
  // Search
@@ -455,7 +548,8 @@ var TreeSelect = defineComponent({
455
548
  "Search tree",
456
549
  mergedLocale.value?.common?.searchPlaceholder
457
550
  ),
458
- onInput: (e) => updateSearchValue(e.target.value)
551
+ onInput: (e) => updateSearchValue(e.target.value),
552
+ onKeydown: handleSearchKeyDown
459
553
  }) : null,
460
554
  // Tree nodes
461
555
  visibleNodes.value.length > 0 ? props.virtual ? h(
@@ -477,12 +571,12 @@ var TreeSelect = defineComponent({
477
571
  {
478
572
  default: ({ index }) => {
479
573
  const item = visibleNodes.value[index];
480
- return item ? renderFlatNode(item) : null;
574
+ return item ? renderFlatNode(item, index) : null;
481
575
  }
482
576
  }
483
577
  )
484
578
  ]
485
- ) : visibleNodes.value.map((flatNode) => renderFlatNode(flatNode)) : h(
579
+ ) : visibleNodes.value.map((flatNode, index) => renderFlatNode(flatNode, index)) : h(
486
580
  "div",
487
581
  { class: treeSelectEmptyClasses },
488
582
  resolveLocaleText(
@@ -21,6 +21,12 @@ var Slider = defineComponent({
21
21
  value: {
22
22
  type: [Number, Array]
23
23
  },
24
+ /**
25
+ * Slider value (for default v-model) - controlled mode
26
+ */
27
+ modelValue: {
28
+ type: [Number, Array]
29
+ },
24
30
  /**
25
31
  * Default slider value - uncontrolled mode
26
32
  */
@@ -111,14 +117,24 @@ var Slider = defineComponent({
111
117
  * Emitted when value changes (for v-model:value)
112
118
  */
113
119
  "update:value": (value) => typeof value === "number" || Array.isArray(value),
120
+ /**
121
+ * Emitted when value changes (for default v-model)
122
+ */
123
+ "update:modelValue": (value) => typeof value === "number" || Array.isArray(value),
114
124
  /**
115
125
  * Emitted when value changes
116
126
  */
117
127
  change: (value) => typeof value === "number" || Array.isArray(value)
118
128
  },
119
129
  setup(props, { emit, attrs }) {
120
- const getInitialValue = () => {
130
+ const resolveBoundValue = () => {
121
131
  if (props.value !== void 0) return props.value;
132
+ if (props.modelValue !== void 0) return props.modelValue;
133
+ return void 0;
134
+ };
135
+ const getInitialValue = () => {
136
+ const bound = resolveBoundValue();
137
+ if (bound !== void 0) return bound;
122
138
  if (props.defaultValue !== void 0) return props.defaultValue;
123
139
  return props.range ? [props.min, props.max] : props.min;
124
140
  };
@@ -128,10 +144,11 @@ var Slider = defineComponent({
128
144
  const showTooltip = ref(false);
129
145
  const trackElement = ref(null);
130
146
  watch(
131
- () => props.value,
132
- (newValue) => {
133
- if (newValue !== void 0) {
134
- internalValue.value = newValue;
147
+ () => [props.value, props.modelValue],
148
+ () => {
149
+ const bound = resolveBoundValue();
150
+ if (bound !== void 0) {
151
+ internalValue.value = bound;
135
152
  }
136
153
  }
137
154
  );
@@ -149,6 +166,7 @@ var Slider = defineComponent({
149
166
  const updateValue = (newValue) => {
150
167
  internalValue.value = newValue;
151
168
  emit("update:value", newValue);
169
+ emit("update:modelValue", newValue);
152
170
  emit("change", newValue);
153
171
  };
154
172
  const handleMove = (event, el) => {
@@ -17,6 +17,7 @@ import {
17
17
  getAutoCompleteInputClasses,
18
18
  getAutoCompleteOptionClasses,
19
19
  filterAutoCompleteOptions,
20
+ resolveAutoCompleteDisplayValue,
20
21
  getInitialPickerActiveIndex,
21
22
  getPickerComboboxAria,
22
23
  getPickerListboxAria,
@@ -109,7 +110,7 @@ var AutoComplete = defineComponent({
109
110
  const listboxId = `tiger-autocomplete-listbox-${instanceId}`;
110
111
  const isOpen = ref(false);
111
112
  const uncontrolledSearchValue = ref(
112
- String(props.searchValue ?? props.modelValue ?? props.defaultSearchValue ?? "")
113
+ props.searchValue ?? resolveAutoCompleteDisplayValue(props.modelValue, props.options, props.defaultSearchValue)
113
114
  );
114
115
  const inputValue = computed(() => props.searchValue ?? uncontrolledSearchValue.value);
115
116
  const activeIndex = ref(-1);
@@ -135,14 +136,15 @@ var AutoComplete = defineComponent({
135
136
  const showClearButton = computed(
136
137
  () => props.clearable && !props.disabled && inputValue.value !== ""
137
138
  );
138
- watch(
139
- () => props.modelValue,
140
- (val) => {
141
- if (props.searchValue === void 0) {
142
- uncontrolledSearchValue.value = String(val ?? props.defaultSearchValue ?? "");
143
- }
139
+ watch([() => props.modelValue, () => props.options], () => {
140
+ if (props.searchValue === void 0) {
141
+ uncontrolledSearchValue.value = resolveAutoCompleteDisplayValue(
142
+ props.modelValue,
143
+ props.options,
144
+ props.defaultSearchValue
145
+ );
144
146
  }
145
- );
147
+ });
146
148
  function openDropdown() {
147
149
  if (props.disabled) return;
148
150
  isOpen.value = true;
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  useFloatingPopup
3
- } from "./chunk-26OI3TEA.mjs";
3
+ } from "./chunk-PMQSXEMT.mjs";
4
4
  import {
5
5
  renderVueOverlayTeleport
6
6
  } from "./chunk-Q7Y22OFX.mjs";
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  useChartInteraction
3
- } from "./chunk-PE5OA4YG.mjs";
3
+ } from "./chunk-FHUGOSEY.mjs";
4
4
  import {
5
5
  ChartTooltip
6
6
  } from "./chunk-SPFL55TF.mjs";
7
7
  import {
8
8
  ChartCanvas
9
- } from "./chunk-W5RZPTFD.mjs";
9
+ } from "./chunk-SNNT64HK.mjs";
10
10
 
11
11
  // src/components/HeatmapChart.ts
12
12
  import { defineComponent, computed, h, nextTick, ref, watchEffect } from "vue";
@@ -69,6 +69,7 @@ var HeatmapChart = defineComponent({
69
69
  wrapperClasses: _wrapperClasses
70
70
  } = useChartInteraction({
71
71
  hoverable: computed(() => props.hoverable),
72
+ showTooltip: computed(() => props.showTooltip),
72
73
  hoveredIndexProp: () => props.hoveredIndex,
73
74
  selectable: computed(() => props.selectable),
74
75
  selectedIndexProp: () => props.selectedIndex,
@@ -192,6 +193,7 @@ var HeatmapChart = defineComponent({
192
193
  };
193
194
  return () => {
194
195
  const interactive = props.hoverable || props.selectable;
196
+ const pointerInteractive = interactive || props.showTooltip;
195
197
  const rect = innerRect.value;
196
198
  const chart = h(
197
199
  ChartCanvas,
@@ -283,7 +285,7 @@ var HeatmapChart = defineComponent({
283
285
  }
284
286
  }
285
287
  );
286
- const tooltip = props.showTooltip && props.hoverable ? h(ChartTooltip, {
288
+ const tooltip = props.showTooltip ? h(ChartTooltip, {
287
289
  content: tooltipContent.value,
288
290
  open: resolvedHoveredIndex.value !== null && tooltipContent.value !== "",
289
291
  x: tooltipPosition.value.x,
@@ -300,12 +302,12 @@ var HeatmapChart = defineComponent({
300
302
  top: `${rect.y}px`,
301
303
  width: `${rect.width}px`,
302
304
  height: `${rect.height}px`,
303
- pointerEvents: interactive ? "auto" : "none"
305
+ pointerEvents: pointerInteractive ? "auto" : "none"
304
306
  },
305
307
  "data-heatmap-canvas": "true",
306
308
  "data-heatmap-render-mode": resolvedRenderMode.value,
307
- onMousemove: interactive ? handleCanvasMouseMove : void 0,
308
- onMouseleave: interactive ? handleMouseLeave : void 0,
309
+ onMousemove: pointerInteractive ? handleCanvasMouseMove : void 0,
310
+ onMouseleave: pointerInteractive ? handleMouseLeave : void 0,
309
311
  onClick: interactive ? handleCanvasClick : void 0
310
312
  }) : null;
311
313
  return h("div", { class: "inline-block relative" }, [chart, canvas, tooltip]);
@@ -7,6 +7,7 @@ import { defineComponent, h, ref, computed } from "vue";
7
7
  import {
8
8
  rateBaseClasses,
9
9
  getRateStarClasses,
10
+ rateHalfStarInnerClasses,
10
11
  rateActiveColor,
11
12
  rateInactiveColor,
12
13
  rateHoverColor,
@@ -126,7 +127,7 @@ var Rate = defineComponent({
126
127
  [h("path", { d: starPathD })]
127
128
  )
128
129
  ]),
129
- // Active half (clipped left 50%)
130
+ // Active half (clipped left 50%; inner glyph keeps full-star width)
130
131
  h(
131
132
  "span",
132
133
  {
@@ -137,12 +138,12 @@ var Rate = defineComponent({
137
138
  style: { width: "50%" }
138
139
  },
139
140
  [
140
- isChar ? h("span", null, props.character) : h(
141
+ isChar ? h("span", { class: rateHalfStarInnerClasses }, props.character) : h(
141
142
  "svg",
142
143
  {
143
144
  viewBox: starViewBox,
144
145
  fill: "currentColor",
145
- class: "w-full h-full"
146
+ class: rateHalfStarInnerClasses
146
147
  },
147
148
  [h("path", { d: starPathD })]
148
149
  )
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  useChartInteraction
3
- } from "./chunk-PE5OA4YG.mjs";
3
+ } from "./chunk-FHUGOSEY.mjs";
4
4
  import {
5
5
  ChartSeries
6
6
  } from "./chunk-2ZUEXCVJ.mjs";
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-SPFL55TF.mjs";
10
10
  import {
11
11
  ChartCanvas
12
- } from "./chunk-W5RZPTFD.mjs";
12
+ } from "./chunk-SNNT64HK.mjs";
13
13
  import {
14
14
  ChartLegend
15
15
  } from "./chunk-V443QIJM.mjs";
@@ -19,6 +19,7 @@ import { defineComponent, computed, h, useId } from "vue";
19
19
  import {
20
20
  classNames,
21
21
  computeSunburstArcs,
22
+ getSunburstLabelPoint,
22
23
  getChartElementOpacity,
23
24
  getChartInnerRect,
24
25
  getStableChartGradientPrefix,
@@ -75,6 +76,7 @@ var SunburstChart = defineComponent({
75
76
  wrapperClasses
76
77
  } = useChartInteraction({
77
78
  hoverable: computed(() => props.hoverable),
79
+ showTooltip: computed(() => props.showTooltip),
78
80
  hoveredIndexProp: () => props.hoveredIndex,
79
81
  selectable: computed(() => props.selectable),
80
82
  selectedIndexProp: () => props.selectedIndex,
@@ -166,45 +168,60 @@ var SunburstChart = defineComponent({
166
168
  )
167
169
  )
168
170
  ) : null;
171
+ const paths = arcs.value.map((arc) => {
172
+ const opacity = getChartElementOpacity(arc.index, activeIndex.value, {
173
+ activeOpacity: props.activeOpacity,
174
+ inactiveOpacity: props.inactiveOpacity
175
+ });
176
+ return h("path", {
177
+ key: `arc-${arc.index}`,
178
+ d: arc.path,
179
+ fill: props.gradient ? `url(#${gradientPrefix}-${arc.index})` : arc.color,
180
+ opacity,
181
+ stroke: "var(--tiger-surface,#ffffff)",
182
+ "stroke-width": 1,
183
+ class: classNames(interactive && "cursor-pointer"),
184
+ style: {
185
+ transition: "opacity var(--tiger-motion-duration-base,0.2s) var(--tiger-motion-ease-decelerate,ease-out), filter var(--tiger-motion-duration-base,0.2s) var(--tiger-motion-ease-decelerate,ease-out)",
186
+ filter: activeIndex.value === arc.index ? "var(--tiger-chart-block-active-filter, none)" : "none"
187
+ },
188
+ tabindex: props.selectable ? 0 : void 0,
189
+ role: props.selectable ? "button" : "img",
190
+ "aria-label": arc.label,
191
+ onMouseenter: (e) => handleMouseEnter(arc.index, e),
192
+ onMousemove: handleMouseMove,
193
+ onMouseleave: handleMouseLeave,
194
+ onClick: () => handleClick(arc.index)
195
+ });
196
+ });
197
+ const labels = props.showLabels ? arcs.value.map((arc) => {
198
+ const { x, y } = getSunburstLabelPoint(arc, cx.value, cy.value);
199
+ return h(
200
+ "text",
201
+ {
202
+ key: `label-${arc.index}`,
203
+ x,
204
+ y,
205
+ "text-anchor": "middle",
206
+ "dominant-baseline": "middle",
207
+ class: "fill-white text-xs",
208
+ style: { pointerEvents: "none" },
209
+ "aria-hidden": "true"
210
+ },
211
+ arc.label
212
+ );
213
+ }) : [];
169
214
  return h(
170
215
  ChartSeries,
171
216
  { data: arcs.value, type: "sunburst" },
172
217
  {
173
- default: () => [
174
- gradientDefs,
175
- ...arcs.value.map((arc) => {
176
- const opacity = getChartElementOpacity(arc.index, activeIndex.value, {
177
- activeOpacity: props.activeOpacity,
178
- inactiveOpacity: props.inactiveOpacity
179
- });
180
- return h("path", {
181
- key: `arc-${arc.index}`,
182
- d: arc.path,
183
- fill: props.gradient ? `url(#${gradientPrefix}-${arc.index})` : arc.color,
184
- opacity,
185
- stroke: "var(--tiger-surface,#ffffff)",
186
- "stroke-width": 1,
187
- class: classNames(interactive && "cursor-pointer"),
188
- style: {
189
- transition: "opacity var(--tiger-motion-duration-base,0.2s) var(--tiger-motion-ease-decelerate,ease-out), filter var(--tiger-motion-duration-base,0.2s) var(--tiger-motion-ease-decelerate,ease-out)",
190
- filter: activeIndex.value === arc.index ? "var(--tiger-chart-block-active-filter, none)" : "none"
191
- },
192
- tabindex: props.selectable ? 0 : void 0,
193
- role: props.selectable ? "button" : "img",
194
- "aria-label": arc.label,
195
- onMouseenter: (e) => handleMouseEnter(arc.index, e),
196
- onMousemove: handleMouseMove,
197
- onMouseleave: handleMouseLeave,
198
- onClick: () => handleClick(arc.index)
199
- });
200
- })
201
- ]
218
+ default: () => [gradientDefs, ...paths, ...labels]
202
219
  }
203
220
  );
204
221
  }
205
222
  }
206
223
  );
207
- const tooltip = props.showTooltip && props.hoverable ? h(ChartTooltip, {
224
+ const tooltip = props.showTooltip ? h(ChartTooltip, {
208
225
  content: tooltipContent.value,
209
226
  open: resolvedHoveredIndex.value !== null && tooltipContent.value !== "",
210
227
  x: tooltipPosition.value.x,
@@ -8,7 +8,7 @@ import {
8
8
  applyMarkdownToolbarAction,
9
9
  classNames,
10
10
  coerceClassValue,
11
- defaultMarkdownToolbar,
11
+ createDefaultMarkdownToolbar,
12
12
  findMarkdownHotkeyMatch,
13
13
  getMarkdownBodyClasses,
14
14
  getMarkdownContainerClasses,
@@ -74,9 +74,6 @@ var MarkdownEditor = defineComponent({
74
74
  () => props.value !== void 0 ? props.value : internalValue.value
75
75
  );
76
76
  const currentMode = computed(() => props.mode ?? internalMode.value);
77
- const toolbarItems = computed(
78
- () => props.toolbar === false ? [] : props.toolbar ?? defaultMarkdownToolbar
79
- );
80
77
  const previewHtml = computed(() => renderMarkdownToHtml(currentValue.value, props.renderer));
81
78
  const showFormattingToolbar = computed(() => props.toolbar !== false);
82
79
  const showTopbar = computed(() => showFormattingToolbar.value || props.showModeSwitch);
@@ -86,6 +83,9 @@ var MarkdownEditor = defineComponent({
86
83
  );
87
84
  const mergedLocale = computed(() => mergeTigerLocale(config.value.locale, props.locale));
88
85
  const labels = computed(() => getMarkdownEditorLabels(mergedLocale.value, props.labels));
86
+ const toolbarItems = computed(
87
+ () => props.toolbar === false ? [] : props.toolbar ?? createDefaultMarkdownToolbar(labels.value)
88
+ );
89
89
  const modeLabels = computed(() => ({
90
90
  edit: labels.value.editModeLabel,
91
91
  split: labels.value.splitModeLabel,
@@ -411,6 +411,44 @@ var Upload = defineComponent({
411
411
  };
412
412
  const renderUploadButton = () => {
413
413
  if (props.drag) {
414
+ const dragInner = slots.default ? slots.default() : [
415
+ h(
416
+ "svg",
417
+ {
418
+ class: "w-12 h-12 mb-3 text-gray-400",
419
+ fill: "none",
420
+ stroke: "currentColor",
421
+ viewBox: "0 0 24 24",
422
+ "aria-hidden": "true"
423
+ },
424
+ [
425
+ h("path", {
426
+ "stroke-linecap": "round",
427
+ "stroke-linejoin": "round",
428
+ "stroke-width": "2",
429
+ d: "M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12"
430
+ })
431
+ ]
432
+ ),
433
+ h("p", { class: "mb-2 text-sm" }, [
434
+ h("span", { class: "font-semibold" }, labels.value.clickToUploadText),
435
+ ` ${labels.value.dragAndDropText}`
436
+ ]),
437
+ props.accept && h(
438
+ "p",
439
+ { class: "text-xs text-gray-500" },
440
+ interpolateUploadLabel(labels.value.acceptInfoText, {
441
+ accept: props.accept
442
+ })
443
+ ),
444
+ props.maxSize && h(
445
+ "p",
446
+ { class: "text-xs text-gray-500" },
447
+ interpolateUploadLabel(labels.value.maxSizeInfoText, {
448
+ maxSize: formatFileSize(props.maxSize)
449
+ })
450
+ )
451
+ ];
414
452
  return h(
415
453
  "div",
416
454
  {
@@ -425,44 +463,7 @@ var Upload = defineComponent({
425
463
  "aria-disabled": props.disabled,
426
464
  "aria-label": labels.value.dragAreaAriaLabel
427
465
  },
428
- [
429
- h(
430
- "svg",
431
- {
432
- class: "w-12 h-12 mb-3 text-gray-400",
433
- fill: "none",
434
- stroke: "currentColor",
435
- viewBox: "0 0 24 24",
436
- "aria-hidden": "true"
437
- },
438
- [
439
- h("path", {
440
- "stroke-linecap": "round",
441
- "stroke-linejoin": "round",
442
- "stroke-width": "2",
443
- d: "M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12"
444
- })
445
- ]
446
- ),
447
- h("p", { class: "mb-2 text-sm" }, [
448
- h("span", { class: "font-semibold" }, labels.value.clickToUploadText),
449
- ` ${labels.value.dragAndDropText}`
450
- ]),
451
- props.accept && h(
452
- "p",
453
- { class: "text-xs text-gray-500" },
454
- interpolateUploadLabel(labels.value.acceptInfoText, {
455
- accept: props.accept
456
- })
457
- ),
458
- props.maxSize && h(
459
- "p",
460
- { class: "text-xs text-gray-500" },
461
- interpolateUploadLabel(labels.value.maxSizeInfoText, {
462
- maxSize: formatFileSize(props.maxSize)
463
- })
464
- )
465
- ]
466
+ dragInner
466
467
  );
467
468
  }
468
469
  return h(
@@ -2,7 +2,7 @@ import {
2
2
  Dropdown,
3
3
  DropdownItem,
4
4
  DropdownMenu
5
- } from "./chunk-KROVW4AW.mjs";
5
+ } from "./chunk-PJQTRDIG.mjs";
6
6
  import {
7
7
  useTigerConfig
8
8
  } from "./chunk-UOJOJBEU.mjs";