@astryx-vue/core 0.12.1 → 0.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 (136) hide show
  1. package/dist/AppShell/index.d.ts +1 -1
  2. package/dist/AvatarGroup/index.d.ts +1 -1
  3. package/dist/Banner/index.d.ts +1 -1
  4. package/dist/BottomSheet/index.d.ts +1 -1
  5. package/dist/Button/index.d.ts +1 -1
  6. package/dist/ButtonGroup/index.d.ts +1 -1
  7. package/dist/Calendar/index.d.ts +1 -1
  8. package/dist/Card/index.d.ts +1 -1
  9. package/dist/Carousel/index.d.ts +1 -1
  10. package/dist/Chat/index.d.ts +1 -1
  11. package/dist/CheckboxInput/index.d.ts +1 -1
  12. package/dist/CheckboxList/index.d.ts +1 -1
  13. package/dist/ClickableCard/index.d.ts +1 -1
  14. package/dist/Code/index.d.ts +1 -1
  15. package/dist/Collapsible/index.d.ts +1 -1
  16. package/dist/ComplexSelector/index.d.ts +1 -1
  17. package/dist/ComplexSelector/index.js +1 -1
  18. package/dist/{ComplexSelector-B_5mzJjR.js → ComplexSelector-Dmbep7M7.js} +165 -49
  19. package/dist/ContextMenu/index.d.ts +1 -1
  20. package/dist/DateInput/index.d.ts +1 -1
  21. package/dist/DateRangeInput/index.d.ts +1 -1
  22. package/dist/DateTimeInput/index.d.ts +1 -1
  23. package/dist/Dialog/index.d.ts +1 -1
  24. package/dist/Divider/index.d.ts +1 -1
  25. package/dist/Drawer/index.d.ts +1 -1
  26. package/dist/FileInput/index.d.ts +1 -1
  27. package/dist/HoverCard/index.d.ts +1 -1
  28. package/dist/InfoTip/index.d.ts +1 -1
  29. package/dist/InternationalizationProvider/index.d.ts +1 -1
  30. package/dist/InternationalizationProvider/index.js +1 -1
  31. package/dist/{InternationalizationProvider-CyDjQn5Z.js → InternationalizationProvider-BYU2MRtX.js} +1 -1
  32. package/dist/Link/index.d.ts +1 -1
  33. package/dist/List/index.d.ts +1 -1
  34. package/dist/MetadataList/index.d.ts +1 -1
  35. package/dist/MoreMenu/index.d.ts +1 -1
  36. package/dist/MultiSelector/index.d.ts +1 -1
  37. package/dist/MultiSelector/index.js +1 -1
  38. package/dist/{MultiSelector-BdedjB6u.js → MultiSelector-BXIpOmSU.js} +105 -50
  39. package/dist/NavItem/index.d.ts +1 -1
  40. package/dist/NumberInput/index.d.ts +1 -1
  41. package/dist/OverflowList/index.d.ts +1 -1
  42. package/dist/Overlay/index.d.ts +1 -1
  43. package/dist/Pagination/index.d.ts +1 -1
  44. package/dist/Pagination/index.js +1 -1
  45. package/dist/{Pagination-uttop2ls.js → Pagination-eeM9SNsG.js} +1 -1
  46. package/dist/Popover/index.d.ts +1 -1
  47. package/dist/PowerSearch/index.d.ts +1 -1
  48. package/dist/PowerSearch/index.js +1 -1
  49. package/dist/{PowerSearch-DDuYfvNh.js → PowerSearch-CaqFxaFb.js} +7 -7
  50. package/dist/ProgressBar/index.d.ts +1 -1
  51. package/dist/Radio/index.d.ts +1 -1
  52. package/dist/RadioList/index.d.ts +1 -1
  53. package/dist/ScrollableArea/index.d.ts +1 -1
  54. package/dist/SelectableCard/index.d.ts +1 -1
  55. package/dist/Selector/index.d.ts +1 -1
  56. package/dist/Selector/index.js +1 -1
  57. package/dist/{Selector-OpczmkqS.js → Selector-DP012yul.js} +8 -43
  58. package/dist/SideNav/index.d.ts +1 -1
  59. package/dist/Stepper/index.d.ts +1 -1
  60. package/dist/Switch/index.d.ts +1 -1
  61. package/dist/TabList/index.d.ts +1 -1
  62. package/dist/Table/index.d.ts +1 -1
  63. package/dist/Table/index.js +1 -1
  64. package/dist/{Table-_pSoEiGP.js → Table-YDS_Hj1L.js} +5 -5
  65. package/dist/TextArea/index.d.ts +1 -1
  66. package/dist/TextInput/index.d.ts +1 -1
  67. package/dist/TimeInput/index.d.ts +1 -1
  68. package/dist/Timestamp/index.d.ts +1 -1
  69. package/dist/ToggleButton/index.d.ts +1 -1
  70. package/dist/Token/index.d.ts +1 -1
  71. package/dist/Tokenizer/index.d.ts +1 -1
  72. package/dist/Tokenizer/index.js +1 -1
  73. package/dist/{Tokenizer-BNazaZsP.js → Tokenizer-CY0ymjYr.js} +107 -48
  74. package/dist/Toolbar/index.d.ts +1 -1
  75. package/dist/Tooltip/index.d.ts +1 -1
  76. package/dist/TopNav/index.d.ts +1 -1
  77. package/dist/TreeList/index.d.ts +1 -1
  78. package/dist/Typeahead/index.d.ts +1 -1
  79. package/dist/Typeahead/index.js +2 -2
  80. package/dist/{Typeahead-BgQVQw-0.js → Typeahead-ByeXwX8E.js} +46 -11
  81. package/dist/composables/index.d.ts +2 -1
  82. package/dist/composables/index.js +1 -1
  83. package/dist/{index-Cb-HJUhK.d.ts → index--tm6L1ot.d.ts} +2 -2
  84. package/dist/{index-TXcNH86P.d.ts → index-B1eCxBCY.d.ts} +1 -1
  85. package/dist/{index-BuubzuE8.d.ts → index-BDZCJ9ri.d.ts} +2 -2
  86. package/dist/{index-wY6dKz6c.d.ts → index-BEZ4ezJk.d.ts} +2 -2
  87. package/dist/{index-a1jCiQP7.d.ts → index-BcJzA5j_.d.ts} +8 -8
  88. package/dist/{index-CTjkJP4x.d.ts → index-Bgk1Rj2A.d.ts} +1 -1
  89. package/dist/{index-CuW4AQ7M.d.ts → index-BhxqUt3y.d.ts} +2 -2
  90. package/dist/{index-Bmqz1lVz.d.ts → index-BpprL2SN.d.ts} +1 -1
  91. package/dist/{index-CGDmjlec.d.ts → index-Buxb8Onp.d.ts} +60 -60
  92. package/dist/{index-DhcjuwQq.d.ts → index-C5e2rZML.d.ts} +3 -3
  93. package/dist/{index-D05JGsT3.d.ts → index-C8wfe0Mr.d.ts} +1 -1
  94. package/dist/{index-DFLPv9io.d.ts → index-CP-fJFcJ.d.ts} +1 -1
  95. package/dist/{index-_5purQow.d.ts → index-CfHBwR3F.d.ts} +10 -8
  96. package/dist/{index-CM2L3SUw.d.ts → index-D1J81rYJ.d.ts} +15 -0
  97. package/dist/{index-CKtrcglY.d.ts → index-D1RIIzDd.d.ts} +6 -6
  98. package/dist/{index-DydQ5Ngj.d.ts → index-D7YRtteD.d.ts} +1 -1
  99. package/dist/{index-CBOv5j3c.d.ts → index-DDrL_-hJ.d.ts} +2 -2
  100. package/dist/{index-BmYnVNI-.d.ts → index-DE1genab.d.ts} +14 -2
  101. package/dist/{index-D-YoRrfP.d.ts → index-DKuoSloc.d.ts} +2 -44
  102. package/dist/{index-Cy1rEWC-.d.ts → index-DMcf0QeR.d.ts} +2 -2
  103. package/dist/{index-B3FE7s7V.d.ts → index-DPH5yoAr.d.ts} +4 -4
  104. package/dist/{index-Q1oG9yIT.d.ts → index-DPklTi3o.d.ts} +1 -1
  105. package/dist/{index-B44fLswd.d.ts → index-DYabo8TI.d.ts} +2 -2
  106. package/dist/{index-O9y23OPJ.d.ts → index-DneQgJfI.d.ts} +1 -1
  107. package/dist/{index-C1zwvxPH.d.ts → index-KcCNhdAw.d.ts} +2 -2
  108. package/dist/{index-utZGF4GR.d.ts → index-NOXYEdOI.d.ts} +1 -1
  109. package/dist/{index-lmd9LZKB.d.ts → index-PffxihMx.d.ts} +1 -1
  110. package/dist/{index-COgrQZIL.d.ts → index-YKCx03zD.d.ts} +2 -2
  111. package/dist/{index-mkbGYz8f.d.ts → index-YfMHAQ_D.d.ts} +9 -2
  112. package/dist/{index-CLHJybQY.d.ts → index-ul1hNxih.d.ts} +1 -1
  113. package/dist/{index-9tZJgo0R.d.ts → index-x0rjeitC.d.ts} +2 -2
  114. package/dist/index.d.ts +34 -33
  115. package/dist/index.js +15 -15
  116. package/dist/{loadCatalog-XbgoqaRp.js → loadCatalog-BtQRPyzj.js} +6 -2
  117. package/dist/{loadCatalog-CQEYXGuI.d.ts → loadCatalog-Kp7aQZpL.d.ts} +3 -0
  118. package/dist/locale/index.d.ts +2 -2
  119. package/dist/locale/index.js +4 -4
  120. package/dist/{locale-BwnZeppK.js → locale-DET_YkFW.js} +1 -1
  121. package/dist/selectorEscape-BppRdqpc.js +52 -0
  122. package/dist/{useAnchoredListbox-CuRfVgKl.js → stillPointerGate-Bh02Mfnw.js} +19 -1
  123. package/dist/{tokenizer-DSka5PJD.js → tokenizer-ChiAuPN-.js} +5 -1
  124. package/dist/{searchResultMessage-BEqDlHdV.js → triggerVariant-BDVvyLtv.js} +18 -18
  125. package/dist/{useCombobox-CTo5C-gc.js → useCombobox-D374_pT8.js} +32 -8
  126. package/dist/useInputStatusIcon-B6m_t8cK.d.ts +45 -0
  127. package/dist/{useOptionActionGrid-CkJcuvaU.js → useOptionActionGrid-C7ibYM_A.js} +15 -1
  128. package/dist/{TypeaheadMenu-BOzaCvSb.js → useTypeaheadAnnouncement-MbuZumTd.js} +75 -33
  129. package/package.json +1 -1
  130. package/styles/complex-selector.css +24 -1
  131. package/styles/multi-selector.css +10 -0
  132. package/styles/selector.css +10 -0
  133. package/styles/tokenizer.css +64 -0
  134. package/styles/typeahead.css +28 -0
  135. package/dist/triggerVariant-BsL8jMHs.js +0 -16
  136. package/dist/{index-J6YRJ7Ul.d.ts → index-BqhgeAT4.d.ts} +1 -1
@@ -416,3 +416,13 @@
416
416
  outline: var(--astryx-focus-outline-width, 2px) var(--astryx-focus-outline-style, solid) var(--astryx-focus-outline-color, var(--astryx-color-accent));
417
417
  outline-offset: 1px;
418
418
  }
419
+
420
+ /* 强制颜色下焦点只剩边框能表达:聚焦(含可聚焦的禁用字段)的边框取系统 Highlight 色。 */
421
+ @layer astryx.components {
422
+ @media (forced-colors: active) {
423
+ .astryx-multi-selector-control:focus-within,
424
+ .astryx-multi-selector-control.is-open {
425
+ border-color: Highlight;
426
+ }
427
+ }
428
+ }
@@ -528,3 +528,13 @@
528
528
  .astryx-selector-search-clear:focus-visible {
529
529
  outline: none;
530
530
  }
531
+
532
+ /* 强制颜色下焦点只剩边框能表达:聚焦(含可聚焦的禁用字段)的边框取系统 Highlight 色。 */
533
+ @layer astryx.components {
534
+ @media (forced-colors: active) {
535
+ .astryx-selector-field:focus-within,
536
+ .astryx-selector-field.is-open {
537
+ border-color: Highlight;
538
+ }
539
+ }
540
+ }
@@ -108,6 +108,18 @@
108
108
  cursor: pointer;
109
109
  }
110
110
 
111
+ .astryx-tokenizer-control > .astryx-field-icon,
112
+ .astryx-tokenizer-control > .astryx-field-info-tip {
113
+ flex: none;
114
+ margin-inline-start: auto;
115
+ color: var(--astryx-input-status-color, var(--astryx-color-text-secondary, #525252));
116
+ }
117
+
118
+ .astryx-tokenizer-clear + .astryx-field-icon,
119
+ .astryx-tokenizer-clear + .astryx-field-info-tip {
120
+ margin-inline-start: 0;
121
+ }
122
+
111
123
  .astryx-tokenizer-measure {
112
124
  position: absolute;
113
125
  display: flex;
@@ -150,6 +162,39 @@
150
162
  padding: 0;
151
163
  }
152
164
 
165
+ /* 展开时标签直接排进外框的弹性行,输入框跟在最后一个标签后面,光标就落在接着打字的地方。 */
166
+ .astryx-tokenizer-tokens:not(.is-collapsed) {
167
+ display: contents;
168
+ }
169
+
170
+ /*
171
+ * 有标签时输入框跟在最后一个标签后面。空着失焦(或只读)时不占任何位置,
172
+ * 连列间距都收回,所以不会为它多出一行空白;聚焦时只要文字内缩进加光标的宽度,
173
+ * 并把光标的宽度还给这一行。打了字就恢复完整的输入宽度,必要时换行。
174
+ */
175
+ .astryx-tokenizer-control.has-tokens .astryx-tokenizer-input {
176
+ box-sizing: border-box;
177
+ flex: 1 1 40px;
178
+ width: 0;
179
+ min-width: 40px;
180
+ padding-inline: calc(var(--astryx-spacing-2, 8px) - var(--astryx-spacing-1, 4px) + 1px) 0;
181
+ }
182
+
183
+ .astryx-tokenizer-control.has-tokens .astryx-tokenizer-input.is-empty {
184
+ min-width: 0;
185
+ flex-basis: 0;
186
+ }
187
+
188
+ .astryx-tokenizer-control.has-tokens .astryx-tokenizer-input.is-empty:is(:not(:focus), :read-only) {
189
+ margin-inline-start: calc(-1 * var(--astryx-spacing-1, 4px));
190
+ padding-inline-start: 0;
191
+ }
192
+
193
+ .astryx-tokenizer-control.has-tokens .astryx-tokenizer-input.is-empty:focus:not(:read-only) {
194
+ min-width: calc(var(--astryx-spacing-2, 8px) - var(--astryx-spacing-1, 4px) + 3px);
195
+ margin-inline-end: -2px;
196
+ }
197
+
153
198
  .astryx-tokenizer-token {
154
199
  display: inline-flex;
155
200
  max-width: 100%;
@@ -206,3 +251,22 @@
206
251
  outline: var(--astryx-focus-outline-width, 2px) var(--astryx-focus-outline-style, solid) var(--astryx-focus-outline-color, var(--astryx-color-accent));
207
252
  outline-offset: 1px;
208
253
  }
254
+
255
+ /* 强制颜色下焦点只剩边框能表达:聚焦(含可聚焦的禁用字段)的边框取系统 Highlight 色。 */
256
+ @layer astryx.components {
257
+ @media (forced-colors: active) {
258
+ .astryx-tokenizer-control:focus-within,
259
+ .astryx-tokenizer-control.is-open {
260
+ border-color: Highlight;
261
+ }
262
+ }
263
+ }
264
+
265
+ @layer astryx.components {
266
+ /* 触屏上点输入框会升起键盘,焦点外观淡入的每一帧都要重绘,改成立刻出现;鼠标和 Tab 仍淡入。 */
267
+ @media (pointer: coarse) {
268
+ .astryx-tokenizer-control {
269
+ transition: none;
270
+ }
271
+ }
272
+ }
@@ -344,3 +344,31 @@
344
344
  outline: var(--astryx-focus-outline-width, 2px) var(--astryx-focus-outline-style, solid) var(--astryx-focus-outline-color, var(--astryx-color-accent));
345
345
  outline-offset: 1px;
346
346
  }
347
+
348
+ /* 强制颜色下焦点只剩边框能表达:聚焦(含可聚焦的禁用字段)的边框取系统 Highlight 色。 */
349
+ @layer astryx.components {
350
+ @media (forced-colors: active) {
351
+ .astryx-typeahead-control:focus-within,
352
+ .astryx-typeahead-control.is-open {
353
+ border-color: Highlight;
354
+ }
355
+ }
356
+ }
357
+
358
+ @layer astryx.components {
359
+ /* 状态图标顶在输入框末尾,颜色跟着状态色;清除按钮在它前面。 */
360
+ .astryx-typeahead-control > .astryx-field-icon,
361
+ .astryx-typeahead-control > .astryx-field-info-tip {
362
+ flex: none;
363
+ color: var(--astryx-input-status-color, var(--astryx-color-text-secondary, #525252));
364
+ }
365
+ }
366
+
367
+ @layer astryx.components {
368
+ /* 触屏上点输入框会升起键盘,焦点外观淡入的每一帧都要重绘,改成立刻出现;鼠标和 Tab 仍淡入。 */
369
+ @media (pointer: coarse) {
370
+ .astryx-typeahead-control {
371
+ transition: none;
372
+ }
373
+ }
374
+ }
@@ -1,16 +0,0 @@
1
- //#region src/Field/statusPlacement.ts
2
- /**
3
- * 次要和幽灵触发器把贴在控件下的状态说明挪开,避免把工具栏撑高。
4
- * tooltip 和已经写明的 detached 保持原样。
5
- */
6
- function fieldStatusPlacement(variant, statusVariant) {
7
- return (variant === "ghost" || variant === "secondary") && statusVariant === "attached" ? "detached" : statusVariant;
8
- }
9
- //#endregion
10
- //#region src/selectors/triggerVariant.ts
11
- function normalizeTriggerVariant(value) {
12
- if (value === "secondary" || value === "ghost") return value;
13
- return "input";
14
- }
15
- //#endregion
16
- export { fieldStatusPlacement as n, normalizeTriggerVariant as t };
@@ -43,9 +43,9 @@ declare const __VLS_base: import("vue").DefineComponent<TokenProps, {}, {}, {},
43
43
  onRemove?: ((event: Event) => any) | undefined;
44
44
  }>, {
45
45
  size: TokenSize;
46
+ labelHidden: boolean;
46
47
  disabled: boolean;
47
48
  color: "default" | "blue" | "cyan" | "gray" | "green" | "orange" | "pink" | "purple" | "red" | "teal" | "yellow";
48
- labelHidden: boolean;
49
49
  removable: boolean;
50
50
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
51
51
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;