@astryx-vue/core 0.7.13 → 0.7.15

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 (202) hide show
  1. package/dist/AppShell/index.d.ts +1 -1
  2. package/dist/AppShell/index.js +1 -1
  3. package/dist/{AppShell-CqDS_G4G.js → AppShell-CYS8WXJ9.js} +2 -2
  4. package/dist/Avatar/index.js +1 -1
  5. package/dist/{Avatar-DJD56XAx.js → Avatar-BLPUC07s.js} +1 -1
  6. package/dist/AvatarGroup/index.d.ts +1 -1
  7. package/dist/AvatarGroup/index.js +1 -1
  8. package/dist/{AvatarGroup-ezWQX5UE.js → AvatarGroup-DkdSw1yf.js} +1 -1
  9. package/dist/Banner/index.d.ts +1 -1
  10. package/dist/Banner/index.js +1 -1
  11. package/dist/{Banner-CswzZPfJ.js → Banner-BAq0N2B5.js} +1 -1
  12. package/dist/Breadcrumbs/index.js +1 -1
  13. package/dist/{Breadcrumbs-CEA0ioO6.js → Breadcrumbs-CbHpqPFH.js} +1 -1
  14. package/dist/Button/index.d.ts +1 -1
  15. package/dist/ButtonGroup/index.d.ts +1 -1
  16. package/dist/Calendar/index.d.ts +1 -1
  17. package/dist/Calendar/index.js +1 -1
  18. package/dist/{Calendar-Gx77cbI3.js → Calendar-CJQCND7M.js} +2 -2
  19. package/dist/Card/index.d.ts +1 -1
  20. package/dist/Carousel/index.js +1 -1
  21. package/dist/{Carousel-N9tDxozW.js → Carousel-v8MoIvkj.js} +1 -1
  22. package/dist/Chat/index.d.ts +1 -1
  23. package/dist/Chat/index.js +1 -1
  24. package/dist/{Chat-CTbSrHfV.js → Chat-CZqMkxNN.js} +2 -2
  25. package/dist/CheckboxInput/index.d.ts +1 -1
  26. package/dist/CheckboxList/index.d.ts +1 -1
  27. package/dist/CheckboxList/index.js +1 -1
  28. package/dist/{CheckboxList-aim5LzZ7.js → CheckboxList-CIbjO5sX.js} +1 -1
  29. package/dist/Citation/index.js +1 -1
  30. package/dist/{Citation-D-El27C6.js → Citation-BDHIuvX3.js} +1 -1
  31. package/dist/ClickableCard/index.d.ts +1 -1
  32. package/dist/Code/index.d.ts +1 -1
  33. package/dist/Collapsible/index.d.ts +1 -1
  34. package/dist/CommandPalette/index.js +1 -1
  35. package/dist/{CommandPalette-CVukbDIa.js → CommandPalette-DYRnEj8W.js} +2 -2
  36. package/dist/ComplexSelector/index.d.ts +1 -1
  37. package/dist/ComplexSelector/index.js +1 -1
  38. package/dist/{ComplexSelector-ClGxdYzt.js → ComplexSelector-ClPFa7tt.js} +2 -2
  39. package/dist/ContextMenu/index.d.ts +1 -1
  40. package/dist/ContextMenu/index.js +1 -1
  41. package/dist/{ContextMenu-C4Ov6MeG.js → ContextMenu-C1dNw-kL.js} +2 -2
  42. package/dist/DateInput/index.d.ts +1 -1
  43. package/dist/DateInput/index.js +1 -1
  44. package/dist/{DateInput-C6CD1sCV.js → DateInput-CJ5LZkb3.js} +4 -4
  45. package/dist/DateRangeInput/index.d.ts +1 -1
  46. package/dist/DateRangeInput/index.js +1 -1
  47. package/dist/{DateRangeInput-BUdnZCEa.js → DateRangeInput-CODHgf6A.js} +3 -3
  48. package/dist/DateTimeInput/index.d.ts +1 -1
  49. package/dist/DateTimeInput/index.js +1 -1
  50. package/dist/{DateTimeInput-B9zKC2vp.js → DateTimeInput-BNqYdBps.js} +4 -4
  51. package/dist/Dialog/index.d.ts +1 -1
  52. package/dist/Dialog/index.js +1 -1
  53. package/dist/{DialogHeader-B-Lz4rB5.js → DialogHeader-BrskbLr4.js} +1 -1
  54. package/dist/Drawer/index.d.ts +1 -1
  55. package/dist/Drawer/index.js +1 -1
  56. package/dist/{Drawer-DjSbpQcy.js → Drawer-CDLPsaoR.js} +1 -1
  57. package/dist/DropdownMenu/index.js +2 -2
  58. package/dist/{DropdownMenu-YsxODlV4.js → DropdownMenu-CisXQME2.js} +3 -3
  59. package/dist/{DropdownMenu-CenkpwtH.js → DropdownMenu-JqLXEqmI.js} +1 -1
  60. package/dist/Field/index.js +1 -1
  61. package/dist/FileInput/index.d.ts +1 -1
  62. package/dist/FileInput/index.js +1 -1
  63. package/dist/{FileInput-lAMIbbni.js → FileInput-D5aCk6kL.js} +3 -3
  64. package/dist/{InputClearButton-CBCi06tn.js → InputClearButton-Dd1GgItq.js} +1 -1
  65. package/dist/InternationalizationProvider/index.d.ts +1 -1
  66. package/dist/InternationalizationProvider/index.js +1 -1
  67. package/dist/{InternationalizationProvider-qkLAE9Gm.js → InternationalizationProvider-DKNYYBp5.js} +3 -3
  68. package/dist/Lightbox/index.js +1 -1
  69. package/dist/{Lightbox-DmrWEQY7.js → Lightbox-Bx1uvH61.js} +1 -1
  70. package/dist/Link/index.js +1 -1
  71. package/dist/{Link-rT-hDx-e.js → Link-M-Slj9ez.js} +1 -1
  72. package/dist/List/index.d.ts +1 -1
  73. package/dist/Markdown/index.js +1 -1
  74. package/dist/{Markdown-DNvqv2Mu.js → Markdown-DDpbD0Sq.js} +2 -2
  75. package/dist/MetadataList/index.js +1 -1
  76. package/dist/{MetadataList-CzOUB43j.js → MetadataList-sNNwmmXa.js} +1 -1
  77. package/dist/MobileNav/index.js +1 -1
  78. package/dist/{MobileNavToggle-DvC9xZIC.js → MobileNavToggle-Bmu1OpEL.js} +1 -1
  79. package/dist/MoreMenu/index.d.ts +1 -1
  80. package/dist/MoreMenu/index.js +1 -1
  81. package/dist/{MoreMenu-Cn8fG326.js → MoreMenu-QWReDavJ.js} +1 -1
  82. package/dist/MultiSelector/index.d.ts +1 -1
  83. package/dist/MultiSelector/index.js +1 -1
  84. package/dist/{MultiSelector-Yi9nnEhy.js → MultiSelector-CFzCvmwp.js} +4 -4
  85. package/dist/{NavHeadingSurface-Bxyk1qhq.js → NavHeadingSurface-tn7cGNlX.js} +1 -1
  86. package/dist/NavItem/index.d.ts +1 -1
  87. package/dist/NumberInput/index.d.ts +1 -1
  88. package/dist/NumberInput/index.js +1 -1
  89. package/dist/{NumberInput-DP7XAtGl.js → NumberInput-D3GJDfEd.js} +2 -2
  90. package/dist/Outline/index.js +1 -1
  91. package/dist/{Outline-1Sh26FpE.js → Outline-C6xBCP2y.js} +1 -1
  92. package/dist/OverflowList/index.d.ts +1 -1
  93. package/dist/OverflowList/index.js +1 -1
  94. package/dist/{OverflowList-Cs6SZ_1W.js → OverflowList-BHnarnHA.js} +1 -1
  95. package/dist/Pagination/index.d.ts +1 -1
  96. package/dist/Pagination/index.js +1 -1
  97. package/dist/{Pagination-BzHqWFLM.js → Pagination-CQj_wYfI.js} +2 -2
  98. package/dist/Popover/index.d.ts +1 -1
  99. package/dist/PowerSearch/index.d.ts +1 -1
  100. package/dist/PowerSearch/index.js +1 -1
  101. package/dist/{PowerSearch-CxGjKHKW.js → PowerSearch-CtS6Lb32.js} +13 -13
  102. package/dist/ProgressBar/index.d.ts +1 -1
  103. package/dist/Radio/index.d.ts +1 -1
  104. package/dist/RadioList/index.d.ts +1 -1
  105. package/dist/Resizable/index.js +1 -1
  106. package/dist/{ResizeHandle-DhDxFvOI.js → ResizeHandle-Bxt3HOsd.js} +1 -1
  107. package/dist/ScrollableArea/index.d.ts +1 -1
  108. package/dist/SegmentedControl/index.d.ts +1 -1
  109. package/dist/SelectableCard/index.d.ts +1 -1
  110. package/dist/Selector/index.d.ts +1 -1
  111. package/dist/Selector/index.js +1 -1
  112. package/dist/{Selector-Ao0H26LN.js → Selector-B6BEBXzZ.js} +3 -3
  113. package/dist/SideNav/index.d.ts +1 -1
  114. package/dist/SideNav/index.js +1 -1
  115. package/dist/{SideNav-Dz9uQFO4.js → SideNav-51VcU4uB.js} +3 -3
  116. package/dist/Spinner/index.js +1 -1
  117. package/dist/{Spinner-B7xuy3ZA.js → Spinner-D8YW_EgO.js} +1 -1
  118. package/dist/Stepper/index.js +1 -1
  119. package/dist/{Stepper-BB-tXsGy.js → Stepper-D_tzl2pr.js} +1 -1
  120. package/dist/Switch/index.d.ts +1 -1
  121. package/dist/Switch/index.js +1 -1
  122. package/dist/{Switch-DSuC0F7H.js → Switch-GIld457S.js} +1 -1
  123. package/dist/TabList/index.d.ts +1 -1
  124. package/dist/TabList/index.js +1 -1
  125. package/dist/{TabList-CchZBEPh.js → TabList-B9RRmiqV.js} +1 -1
  126. package/dist/Table/index.d.ts +1 -1
  127. package/dist/Table/index.js +1 -1
  128. package/dist/{Table-BIzY_pTL.js → Table-ChVsEuB0.js} +8 -8
  129. package/dist/TextArea/index.d.ts +1 -1
  130. package/dist/TextArea/index.js +1 -1
  131. package/dist/{TextArea-DpDQCb59.js → TextArea-jled6DMh.js} +2 -2
  132. package/dist/TextInput/index.d.ts +1 -1
  133. package/dist/TextInput/index.js +1 -1
  134. package/dist/{TextInput-CzAq1vnQ.js → TextInput-rdwpMErv.js} +2 -2
  135. package/dist/Thumbnail/index.js +1 -1
  136. package/dist/{Thumbnail-CMg6lU2v.js → Thumbnail-BC4-JVWr.js} +2 -2
  137. package/dist/{TimeField-Dx-kKLOS.js → TimeField-BcGkQvY4.js} +2 -2
  138. package/dist/TimeInput/index.d.ts +1 -1
  139. package/dist/TimeInput/index.js +1 -1
  140. package/dist/{TimeInput-CZZRDp0n.js → TimeInput-DKY6qhOK.js} +1 -1
  141. package/dist/Timestamp/index.d.ts +1 -1
  142. package/dist/Timestamp/index.js +1 -1
  143. package/dist/{Timestamp-DqwJAzCD.js → Timestamp-BPFUaR4k.js} +1 -1
  144. package/dist/Toast/index.js +1 -1
  145. package/dist/{Toast-CCbbZ8RK.js → Toast-CN6C5mZ4.js} +1 -1
  146. package/dist/ToggleButton/index.d.ts +1 -1
  147. package/dist/Token/index.d.ts +1 -1
  148. package/dist/Token/index.js +1 -1
  149. package/dist/{Token-DP3bU-8c.js → Token-rBcE4hYh.js} +1 -1
  150. package/dist/Tokenizer/index.d.ts +1 -1
  151. package/dist/Tokenizer/index.js +1 -1
  152. package/dist/{Tokenizer-DC2AqiEU.js → Tokenizer-QsHKjPcl.js} +3 -3
  153. package/dist/Toolbar/index.d.ts +1 -1
  154. package/dist/TopNav/index.d.ts +1 -1
  155. package/dist/TopNav/index.js +1 -1
  156. package/dist/{TopNav-FgHFUA3F.js → TopNav-C9iMSVz_.js} +3 -3
  157. package/dist/TreeList/index.js +1 -1
  158. package/dist/{TreeList-rz7FL_GT.js → TreeList-DYJ1e47h.js} +1 -1
  159. package/dist/Typeahead/index.d.ts +1 -1
  160. package/dist/Typeahead/index.js +2 -2
  161. package/dist/{Typeahead-CCiqxJ9T.js → Typeahead-B215VyXn.js} +4 -4
  162. package/dist/{TypeaheadMenu-By-HLpFy.js → TypeaheadMenu-CafYGgVa.js} +1 -1
  163. package/dist/composables/index.js +1 -1
  164. package/dist/{composables-Csqd3fts.js → composables-rlh0LyHP.js} +1 -1
  165. package/dist/{context-CVUee2tp.js → context-dY6CBI-t.js} +519 -4
  166. package/dist/{index-Dacg7XTH.d.ts → index-8px-LKw_.d.ts} +2 -2
  167. package/dist/{index-oYGkhGRq.d.ts → index-B7Jz5i9a.d.ts} +2 -2
  168. package/dist/{index-DImU6Y2C.d.ts → index-BUlAPQW0.d.ts} +3 -3
  169. package/dist/{index-D_K1wfRa.d.ts → index-BhLLG-Gi.d.ts} +2 -2
  170. package/dist/{index-BaxM-pFP.d.ts → index-BnEhvmdR.d.ts} +4 -4
  171. package/dist/{index-CL8JvxHW.d.ts → index-C1zwvxPH.d.ts} +2 -2
  172. package/dist/{index-DPocrd8C.d.ts → index-CKpz_Eed.d.ts} +1 -1
  173. package/dist/{index-YKCx03zD.d.ts → index-COgrQZIL.d.ts} +2 -2
  174. package/dist/{index-D_8RGgF1.d.ts → index-CRPSZ4nY.d.ts} +1 -1
  175. package/dist/{index-Bgk1Rj2A.d.ts → index-CTjkJP4x.d.ts} +1 -1
  176. package/dist/{index-QmmrXztz.d.ts → index-CfSSGJgv.d.ts} +4 -4
  177. package/dist/{index-rnFsCdJ7.d.ts → index-Cy1rEWC-.d.ts} +1 -1
  178. package/dist/{index-BEvmfcQG.d.ts → index-DoEZBirv.d.ts} +6 -6
  179. package/dist/{index-DaXzQxos.d.ts → index-MEix_m1o.d.ts} +2 -2
  180. package/dist/{index-B1eCxBCY.d.ts → index-TXcNH86P.d.ts} +1 -1
  181. package/dist/{index-DrwSI1fc.d.ts → index-U06REq7f.d.ts} +52 -52
  182. package/dist/{index-Cp2OoE3-.d.ts → index-UFlyBbRd.d.ts} +1 -1
  183. package/dist/{index-D21zdEgS.d.ts → index-Uh-ddE5F.d.ts} +1 -1
  184. package/dist/{index-COxy6LEW.d.ts → index-gW0HW02U.d.ts} +1 -1
  185. package/dist/{index-3t5RAfNP.d.ts → index-mkbGYz8f.d.ts} +2 -2
  186. package/dist/{index-IfiA8CSr.d.ts → index-qayqGnJT.d.ts} +2 -2
  187. package/dist/{index-CkRAvbdh.d.ts → index-vhdPQJYw.d.ts} +5 -5
  188. package/dist/{index-BEZ4ezJk.d.ts → index-wY6dKz6c.d.ts} +2 -2
  189. package/dist/index.d.ts +25 -25
  190. package/dist/index.js +60 -60
  191. package/dist/loadCatalog-Cr3451_V.js +143 -0
  192. package/dist/{loadCatalog-yVGfaB20.d.ts → loadCatalog-DNIEPF3f.d.ts} +118 -0
  193. package/dist/locale/index.d.ts +2 -2
  194. package/dist/locale/index.js +4 -4
  195. package/dist/{locale-D4DoSjrL.js → locale-BdA3CTlQ.js} +1 -1
  196. package/dist/{searchResultMessage-DEyqvflW.js → searchResultMessage-u1rOubPl.js} +1 -1
  197. package/dist/{upstreamMap-BFXZHlnp.js → upstreamMap-CZUPxbc9.js} +144 -1
  198. package/dist/{useTranslator-BQ1KFNSZ.js → useTranslator-DZBywLvR.js} +2 -2
  199. package/package.json +1 -1
  200. package/styles/code.css +7 -0
  201. package/dist/loadCatalog-BvoQXMpW.js +0 -424
  202. package/dist/{index-CHx33xGa.d.ts → index-BJ9Wim6J.d.ts} +1 -1
@@ -79,16 +79,16 @@ const calendarMessages = {
79
79
  function clearLabel(label, fallback, prefix) {
80
80
  return label != null && label !== "" ? `${prefix}${label}` : fallback;
81
81
  }
82
- const numberFormats = /* @__PURE__ */ new Map();
82
+ const numberFormats$1 = /* @__PURE__ */ new Map();
83
83
  /**
84
84
  * 按语言给数字加千分位,对应原版 ICU 里的 `{count, number}`。
85
85
  * 内置文案只有 `en` 和 `zh-CN`,两者都写成 `1,234`。
86
86
  */
87
87
  function formatCount(value, locale) {
88
- let format = numberFormats.get(locale);
88
+ let format = numberFormats$1.get(locale);
89
89
  if (format == null) {
90
90
  format = new Intl.NumberFormat(locale);
91
- numberFormats.set(locale, format);
91
+ numberFormats$1.set(locale, format);
92
92
  }
93
93
  return format.format(value);
94
94
  }
@@ -267,6 +267,468 @@ const commandPaletteMessages = {
267
267
  }
268
268
  };
269
269
  //#endregion
270
+ //#region src/locale/messages/comment-composer.ts
271
+ const commentComposerMessages = {
272
+ "en": {
273
+ addEmoji: "Add emoji",
274
+ agents: "Agents",
275
+ attachImages: "Attach images",
276
+ cancel: "Cancel",
277
+ chooseImages: "Choose images",
278
+ imageAlt: "Image attachment",
279
+ imagesOnly: "Only image files can be added",
280
+ noAgents: "No agents",
281
+ placeholder: "Write a comment…",
282
+ removeQuote: "Remove quoted text",
283
+ uploadFailed: "Images couldn't be added"
284
+ },
285
+ "zh-CN": {
286
+ addEmoji: "添加表情",
287
+ agents: "智能体",
288
+ attachImages: "添加图片",
289
+ cancel: "取消",
290
+ chooseImages: "选择图片",
291
+ imageAlt: "图片附件",
292
+ imagesOnly: "只能添加图片文件",
293
+ noAgents: "没有智能体",
294
+ placeholder: "写一条评论…",
295
+ removeQuote: "移除引用文字",
296
+ uploadFailed: "图片没能添加。"
297
+ }
298
+ };
299
+ //#endregion
300
+ //#region src/locale/icu.ts
301
+ const pluralRules = /* @__PURE__ */ new Map();
302
+ const ordinalRules = /* @__PURE__ */ new Map();
303
+ const numberFormats = /* @__PURE__ */ new Map();
304
+ function rulesFor(locale, ordinal) {
305
+ const cache = ordinal ? ordinalRules : pluralRules;
306
+ let rules = cache.get(locale);
307
+ if (rules == null) {
308
+ rules = new Intl.PluralRules(locale, ordinal ? { type: "ordinal" } : void 0);
309
+ cache.set(locale, rules);
310
+ }
311
+ return rules;
312
+ }
313
+ function numberFor(locale) {
314
+ let format = numberFormats.get(locale);
315
+ if (format == null) {
316
+ format = new Intl.NumberFormat(locale);
317
+ numberFormats.set(locale, format);
318
+ }
319
+ return format;
320
+ }
321
+ /**
322
+ * 解析原版目录里的 ICU MessageFormat。
323
+ * 覆盖 `{name}`、`{name, number}`、`plural`、`selectordinal` 和 `select`。
324
+ * 解析失败时抛错,调用方负责把这个键记进未映射列表。
325
+ */
326
+ function formatIcu(message, values, locale) {
327
+ return render(parseMessage(message), values, locale, void 0);
328
+ }
329
+ function icuPlaceholderNames(message) {
330
+ return Object.keys(icuArgumentKinds(message));
331
+ }
332
+ /**
333
+ * 每个占位符名字用到的写法,已排序去重。
334
+ * 译文和原文的这张表一致,说明两边收同样的值;字面文字和占位符顺序不算在内。
335
+ * 解析失败时抛错。
336
+ */
337
+ function icuArgumentKinds(message) {
338
+ const kinds = /* @__PURE__ */ new Map();
339
+ collectKinds(parseMessage(message), kinds);
340
+ return Object.fromEntries([...kinds].map(([name, set]) => [name, [...set].sort()]));
341
+ }
342
+ function collectKinds(nodes, kinds) {
343
+ for (const node of nodes) {
344
+ if (node.type === "text" || node.type === "pound") continue;
345
+ const kind = node.type === "arg" ? "argument" : node.type === "plural" && node.ordinal ? "selectordinal" : node.type;
346
+ const set = kinds.get(node.name) ?? /* @__PURE__ */ new Set();
347
+ set.add(kind);
348
+ kinds.set(node.name, set);
349
+ if (node.type === "plural" || node.type === "select") for (const option of node.options) collectKinds(option.nodes, kinds);
350
+ }
351
+ }
352
+ function render(nodes, values, locale, pound) {
353
+ let text = "";
354
+ for (const node of nodes) text += renderNode(node, values, locale, pound);
355
+ return text;
356
+ }
357
+ function renderNode(node, values, locale, pound) {
358
+ if (node.type === "text") return node.value;
359
+ if (node.type === "pound") return pound == null ? "" : numberFor(locale).format(pound);
360
+ if (node.type === "arg") return textValue(values[node.name]);
361
+ if (node.type === "number") {
362
+ const value = numericValue(values[node.name]);
363
+ return value == null ? "" : numberFor(locale).format(value);
364
+ }
365
+ if (node.type === "select") return renderChoice(node.options, selectSelector(values[node.name]), values, locale, pound);
366
+ const value = numericValue(values[node.name]);
367
+ const rounded = value == null ? void 0 : value - node.offset;
368
+ const selector = value == null ? "other" : pluralSelector(value, node.options, locale, node.ordinal);
369
+ return renderChoice(node.options, selector, values, locale, rounded);
370
+ }
371
+ function pluralSelector(value, options, locale, ordinal) {
372
+ const exact = exactSelector(value);
373
+ if (exact != null && options.some((option) => option.selector === exact)) return exact;
374
+ return rulesFor(locale, ordinal).select(value);
375
+ }
376
+ function renderChoice(options, selector, values, locale, pound) {
377
+ const match = options.find((option) => option.selector === selector) ?? options.find((option) => option.selector === "other") ?? options[0];
378
+ return match == null ? "" : render(match.nodes, values, locale, pound);
379
+ }
380
+ function textValue(value) {
381
+ if (value == null) return "";
382
+ return typeof value === "number" ? String(value) : value;
383
+ }
384
+ function numericValue(value) {
385
+ if (typeof value === "number" && Number.isFinite(value)) return value;
386
+ if (typeof value === "string" && value.trim() !== "") {
387
+ const parsed = Number(value);
388
+ if (Number.isFinite(parsed)) return parsed;
389
+ }
390
+ }
391
+ function exactSelector(value) {
392
+ return Number.isInteger(value) ? `=${value}` : void 0;
393
+ }
394
+ function selectSelector(value) {
395
+ if (value == null) return "other";
396
+ return String(value);
397
+ }
398
+ function startsQuote(next, pluralPound) {
399
+ return next === "{" || next === "}" || next === "<" || next === ">" || pluralPound && next === "#";
400
+ }
401
+ function parseMessage(input) {
402
+ let index = 0;
403
+ function parseNodes(stop, pluralPound) {
404
+ const nodes = [];
405
+ let text = "";
406
+ const flush = () => {
407
+ if (text !== "") {
408
+ nodes.push({
409
+ type: "text",
410
+ value: text
411
+ });
412
+ text = "";
413
+ }
414
+ };
415
+ while (index < input.length) {
416
+ const char = input[index];
417
+ if (char === "'") {
418
+ const next = input[index + 1];
419
+ if (next === "'") {
420
+ text += "'";
421
+ index += 2;
422
+ continue;
423
+ }
424
+ if (!startsQuote(next, pluralPound)) {
425
+ text += "'";
426
+ index += 1;
427
+ continue;
428
+ }
429
+ index += 1;
430
+ while (index < input.length) {
431
+ if (input[index] === "'") {
432
+ if (input[index + 1] === "'") {
433
+ text += "'";
434
+ index += 2;
435
+ continue;
436
+ }
437
+ index += 1;
438
+ break;
439
+ }
440
+ text += input[index];
441
+ index += 1;
442
+ }
443
+ continue;
444
+ }
445
+ if (char === "#" && pluralPound) {
446
+ flush();
447
+ nodes.push({ type: "pound" });
448
+ index += 1;
449
+ continue;
450
+ }
451
+ if (char === "{") {
452
+ flush();
453
+ index += 1;
454
+ nodes.push(parseArgument());
455
+ continue;
456
+ }
457
+ if (stop != null && char === stop) {
458
+ flush();
459
+ return nodes;
460
+ }
461
+ text += char;
462
+ index += 1;
463
+ }
464
+ if (stop != null) throw new Error("ICU 消息没有闭合");
465
+ flush();
466
+ return nodes;
467
+ }
468
+ function parseArgument() {
469
+ skipSpace();
470
+ const name = readIdentifier();
471
+ skipSpace();
472
+ if (input[index] === "}") {
473
+ index += 1;
474
+ return {
475
+ type: "arg",
476
+ name
477
+ };
478
+ }
479
+ if (input[index] !== ",") throw new Error(`ICU 参数 ${name} 格式不对`);
480
+ index += 1;
481
+ skipSpace();
482
+ const kind = readIdentifier();
483
+ skipSpace();
484
+ if (kind === "number") {
485
+ if (input[index] === ",") skipNumberStyle();
486
+ expectChar("}");
487
+ index += 1;
488
+ return {
489
+ type: "number",
490
+ name
491
+ };
492
+ }
493
+ if (kind === "plural" || kind === "selectordinal" || kind === "select") {
494
+ expectChar(",");
495
+ index += 1;
496
+ skipSpace();
497
+ let offset = 0;
498
+ if (kind !== "select" && input.startsWith("offset:", index)) {
499
+ index += 7;
500
+ skipSpace();
501
+ offset = readInteger();
502
+ skipSpace();
503
+ }
504
+ const options = [];
505
+ while (index < input.length && input[index] !== "}") {
506
+ skipSpace();
507
+ if (input[index] === "}") break;
508
+ const selector = readSelector();
509
+ skipSpace();
510
+ expectChar("{");
511
+ index += 1;
512
+ const nodes = parseNodes("}", kind !== "select");
513
+ expectChar("}");
514
+ index += 1;
515
+ options.push({
516
+ selector,
517
+ nodes
518
+ });
519
+ }
520
+ expectChar("}");
521
+ index += 1;
522
+ if (options.length === 0) throw new Error(`ICU ${kind} 没有选项`);
523
+ if (kind === "select") return {
524
+ type: "select",
525
+ name,
526
+ options
527
+ };
528
+ return {
529
+ type: "plural",
530
+ name,
531
+ offset,
532
+ ordinal: kind === "selectordinal",
533
+ options
534
+ };
535
+ }
536
+ throw new Error(`不支持的 ICU 类型 ${kind}`);
537
+ }
538
+ function skipNumberStyle() {
539
+ let depth = 0;
540
+ while (index < input.length) {
541
+ const char = input[index];
542
+ if (char === "{") depth += 1;
543
+ else if (char === "}") {
544
+ if (depth === 0) return;
545
+ depth -= 1;
546
+ }
547
+ index += 1;
548
+ }
549
+ throw new Error("ICU number 没有闭合");
550
+ }
551
+ function skipSpace() {
552
+ while (index < input.length && (input[index] === " " || input[index] === "\n" || input[index] === "\r" || input[index] === " ")) index += 1;
553
+ }
554
+ function readIdentifier() {
555
+ const start = index;
556
+ while (index < input.length && /[\w$]/.test(input[index])) index += 1;
557
+ if (start === index) throw new Error("ICU 缺少参数名");
558
+ return input.slice(start, index);
559
+ }
560
+ function readSelector() {
561
+ if (input[index] === "=") {
562
+ index += 1;
563
+ const sign = input[index] === "-" ? "-" : "";
564
+ if (sign) index += 1;
565
+ return `=${sign}${readInteger()}`;
566
+ }
567
+ return readIdentifier();
568
+ }
569
+ function readInteger() {
570
+ const start = index;
571
+ while (index < input.length && input[index] >= "0" && input[index] <= "9") index += 1;
572
+ if (start === index) throw new Error("ICU 缺少数字");
573
+ return Number(input.slice(start, index));
574
+ }
575
+ function expectChar(char) {
576
+ if (input[index] !== char) throw new Error(`ICU 期望 ${char}`);
577
+ }
578
+ return parseNodes(null, false);
579
+ }
580
+ //#endregion
581
+ //#region src/locale/messages/comments.ts
582
+ function fill$1(template, locale, values) {
583
+ return formatIcu(template, values, locale).replace(/[ \t]{2,}/g, " ").trim();
584
+ }
585
+ const commentsMessages = {
586
+ "en": {
587
+ actionsLabel: (name) => fill$1("Actions for {name}'s comment", "en", { name }),
588
+ addReaction: "Add reaction",
589
+ agentBadge: "Agent",
590
+ agentLogo: (name) => fill$1("{name} logo", "en", { name }),
591
+ chooseReaction: "Choose a reaction",
592
+ commentsLabel: (label) => fill$1("Threads in {label}", "en", { label }),
593
+ copyLink: "Copy comment link",
594
+ currentVersion: "Current version",
595
+ delete: "Delete",
596
+ deleteDescription: (name) => fill$1("Delete {name}'s comment? This action cannot be undone.", "en", { name }),
597
+ deleteFailed: "This comment couldn't be deleted.",
598
+ deleteFailedRetry: "This comment couldn't be deleted. Try again.",
599
+ deleteTitle: "Delete comment?",
600
+ edit: "Edit",
601
+ editFailed: "Your edit couldn't be saved.",
602
+ editPlaceholder: "Edit comment",
603
+ edited: "Edited",
604
+ editingContext: "Editing comment",
605
+ emptyDescription: "Start the discussion with a comment.",
606
+ emptyReadOnlyDescription: "There is no discussion on this item.",
607
+ emptyTitle: "No comments yet",
608
+ hideReplies: "Hide replies",
609
+ historyEmptyDescription: "This comment has no earlier versions.",
610
+ historyEmptyTitle: "No edit history",
611
+ historyFailed: "Edit history couldn't load",
612
+ historyLoadFailed: "The comment's edit history couldn't be loaded. Try again.",
613
+ historyLoading: "Loading edit history",
614
+ historySubtitle: (name) => fill$1("Comment by {name}", "en", { name }),
615
+ historyTitle: "Edit history",
616
+ label: "Comments",
617
+ linkCopied: "Comment link copied",
618
+ loadFailed: "Comments couldn't load",
619
+ loadOlder: "Load earlier comments",
620
+ loading: "Loading comments",
621
+ olderFailed: "Earlier comments couldn't load",
622
+ otherReactors: (count) => fill$1("{count, plural, one {# other} other {# others}}", "en", { count }),
623
+ outdated: "Outdated",
624
+ postFailed: "Your comment couldn't be posted.",
625
+ reactionCelebrate: "Celebrate",
626
+ reactionCount: (reaction, count) => fill$1("{reaction}: {count, number}", "en", {
627
+ reaction,
628
+ count
629
+ }),
630
+ reactionFailed: "Your reaction couldn't be saved.",
631
+ reactionLaugh: "Haha",
632
+ reactionLike: "Like",
633
+ reactionLove: "Love",
634
+ reactionSad: "Sad",
635
+ reactionWow: "Wow",
636
+ reopen: "Reopen",
637
+ reopenFailed: "This thread couldn't be reopened.",
638
+ reply: "Reply",
639
+ replyFailed: "Your reply couldn't be posted.",
640
+ replyPlaceholder: (name) => fill$1("Reply to {name}…", "en", { name }),
641
+ replyingContext: (name) => fill$1("Replying to {name}", "en", { name }),
642
+ resolve: "Mark as resolved",
643
+ resolveFailed: "This thread couldn't be resolved.",
644
+ resolved: "Resolved",
645
+ resolvedBy: (name) => fill$1("Resolved by {name}", "en", { name }),
646
+ retry: "Retry",
647
+ retryFailed: "Retrying didn't work.",
648
+ sendFailed: "Couldn't send this comment.",
649
+ threadLabel: (name) => fill$1("Thread by {name}", "en", { name }),
650
+ unread: "New",
651
+ unsavedDraft: "Unsaved draft. Dismiss again to discard it.",
652
+ versionAuthor: (name) => fill$1("by {name}", "en", { name }),
653
+ viewHistory: "View edit history",
654
+ viewReplies: (count) => fill$1("View {count, plural, one {# reply} other {# replies}}", "en", { count }),
655
+ reactionsLabel: "Reactions",
656
+ reactionWith: (count, emoji) => `${count} ${count === 1 ? "reaction" : "reactions"} with ${emoji}`
657
+ },
658
+ "zh-CN": {
659
+ actionsLabel: (name) => fill$1("{name} 这条评论的操作", "zh-CN", { name }),
660
+ addReaction: "添加回应",
661
+ agentBadge: "智能体",
662
+ agentLogo: (name) => fill$1("{name} 的标志", "zh-CN", { name }),
663
+ chooseReaction: "选择回应",
664
+ commentsLabel: (label) => fill$1("{label} 中的讨论串", "zh-CN", { label }),
665
+ copyLink: "复制评论链接",
666
+ currentVersion: "当前版本",
667
+ delete: "删除",
668
+ deleteDescription: (name) => fill$1("要删除 {name} 的评论吗?此操作无法撤销。", "zh-CN", { name }),
669
+ deleteFailed: "这条评论没能删除。",
670
+ deleteFailedRetry: "这条评论没能删除。请再试一次。",
671
+ deleteTitle: "删除评论?",
672
+ edit: "编辑",
673
+ editFailed: "这次编辑没能保存。",
674
+ editPlaceholder: "编辑评论",
675
+ edited: "已编辑",
676
+ editingContext: "正在编辑评论",
677
+ emptyDescription: "写一条评论,开始讨论。",
678
+ emptyReadOnlyDescription: "这项还没有讨论。",
679
+ emptyTitle: "还没有评论",
680
+ hideReplies: "隐藏回复",
681
+ historyEmptyDescription: "这条评论没有更早的版本。",
682
+ historyEmptyTitle: "没有编辑历史",
683
+ historyFailed: "编辑历史没能加载",
684
+ historyLoadFailed: "这条评论的编辑历史没能加载。请再试一次。",
685
+ historyLoading: "正在加载编辑历史",
686
+ historySubtitle: (name) => fill$1("{name} 的评论", "zh-CN", { name }),
687
+ historyTitle: "编辑历史",
688
+ label: "评论",
689
+ linkCopied: "评论链接已复制",
690
+ loadFailed: "评论没能加载",
691
+ loadOlder: "加载更早的评论",
692
+ loading: "正在加载评论",
693
+ olderFailed: "更早的评论没能加载",
694
+ otherReactors: (count) => fill$1("{count, plural, other {另外 # 人}}", "zh-CN", { count }),
695
+ outdated: "已过期",
696
+ postFailed: "这条评论没能发出。",
697
+ reactionCelebrate: "庆祝",
698
+ reactionCount: (reaction, count) => fill$1("{reaction}:{count, number}", "zh-CN", {
699
+ reaction,
700
+ count
701
+ }),
702
+ reactionFailed: "这次回应没能保存。",
703
+ reactionLaugh: "哈哈",
704
+ reactionLike: "赞",
705
+ reactionLove: "喜欢",
706
+ reactionSad: "难过",
707
+ reactionWow: "哇",
708
+ reopen: "重新打开",
709
+ reopenFailed: "这个讨论串没能重新打开。",
710
+ reply: "回复",
711
+ replyFailed: "这条回复没能发出。",
712
+ replyPlaceholder: (name) => fill$1("回复 {name}…", "zh-CN", { name }),
713
+ replyingContext: (name) => fill$1("正在回复 {name}", "zh-CN", { name }),
714
+ resolve: "标为已解决",
715
+ resolveFailed: "这个讨论串没能标为已解决。",
716
+ resolved: "已解决",
717
+ resolvedBy: (name) => fill$1("由 {name} 标为已解决", "zh-CN", { name }),
718
+ retry: "重试",
719
+ retryFailed: "重试没有成功。",
720
+ sendFailed: "这条评论没能发出。",
721
+ threadLabel: (name) => fill$1("{name} 的讨论串", "zh-CN", { name }),
722
+ unread: "新",
723
+ unsavedDraft: "草稿还没保存。再关闭一次就会丢掉。",
724
+ versionAuthor: (name) => fill$1("由 {name}", "zh-CN", { name }),
725
+ viewHistory: "查看编辑历史",
726
+ viewReplies: (count) => fill$1("查看 {count, plural, other {# 条回复}}", "zh-CN", { count }),
727
+ reactionsLabel: "回应",
728
+ reactionWith: (count, emoji) => `${count} 次 ${emoji} 回应`
729
+ }
730
+ };
731
+ //#endregion
270
732
  //#region src/locale/messages/context-menu.ts
271
733
  const contextMenuMessages = {
272
734
  "en": { label: "Context menu" },
@@ -387,6 +849,53 @@ const dropdownMenuMessages = {
387
849
  }
388
850
  };
389
851
  //#endregion
852
+ //#region src/locale/messages/emoji-picker.ts
853
+ function fill(template, locale, values) {
854
+ return formatIcu(template, values, locale).replace(/[ \t]{2,}/g, " ").trim();
855
+ }
856
+ const emojiPickerMessages = {
857
+ "en": {
858
+ frequentlyUsed: "Frequently used",
859
+ groupActivities: "Activities",
860
+ groupAnimalsNature: "Animals & nature",
861
+ groupFlags: "Flags",
862
+ groupFoodDrink: "Food & drink",
863
+ groupObjects: "Objects",
864
+ groupPeopleBody: "People & body",
865
+ groupSmileysEmotion: "Smileys & emotion",
866
+ groupSymbols: "Symbols",
867
+ groupTravelPlaces: "Travel & places",
868
+ label: "Emoji",
869
+ loadFailed: "More emoji couldn't be loaded.",
870
+ loading: "Loading emoji",
871
+ noResults: (query) => fill("No emoji match “{query}”", "en", { query }),
872
+ searchLabel: "Search emoji",
873
+ searchResults: "Search results",
874
+ pickLabel: "Pick an emoji",
875
+ reactWith: (name) => `React with ${name}`
876
+ },
877
+ "zh-CN": {
878
+ frequentlyUsed: "常用",
879
+ groupActivities: "活动",
880
+ groupAnimalsNature: "动物与自然",
881
+ groupFlags: "旗帜",
882
+ groupFoodDrink: "食物与饮品",
883
+ groupObjects: "物品",
884
+ groupPeopleBody: "人物与身体",
885
+ groupSmileysEmotion: "表情与情绪",
886
+ groupSymbols: "符号",
887
+ groupTravelPlaces: "旅行与地点",
888
+ label: "表情",
889
+ loadFailed: "更多表情没能加载。",
890
+ loading: "正在加载表情",
891
+ noResults: (query) => fill("没有和“{query}”匹配的表情", "zh-CN", { query }),
892
+ searchLabel: "搜索表情",
893
+ searchResults: "搜索结果",
894
+ pickLabel: "选择表情",
895
+ reactWith: (name) => `用${name}回应`
896
+ }
897
+ };
898
+ //#endregion
390
899
  //#region src/locale/messages/field.ts
391
900
  const fieldMessages = {
392
901
  "en": {
@@ -1350,12 +1859,15 @@ const astryxMessages = {
1350
1859
  citation: citationMessages.en,
1351
1860
  codeBlock: codeBlockMessages.en,
1352
1861
  commandPalette: commandPaletteMessages.en,
1862
+ commentComposer: commentComposerMessages.en,
1863
+ comments: commentsMessages.en,
1353
1864
  contextMenu: contextMenuMessages.en,
1354
1865
  dateInput: dateInputMessages.en,
1355
1866
  dateRangeInput: dateRangeInputMessages.en,
1356
1867
  dateTimeInput: dateTimeInputMessages.en,
1357
1868
  dialog: dialogMessages.en,
1358
1869
  dropdownMenu: dropdownMenuMessages.en,
1870
+ emojiPicker: emojiPickerMessages.en,
1359
1871
  field: fieldMessages.en,
1360
1872
  fileInput: fileInputMessages.en,
1361
1873
  input: inputMessages.en,
@@ -1406,12 +1918,15 @@ const astryxMessages = {
1406
1918
  citation: citationMessages["zh-CN"],
1407
1919
  codeBlock: codeBlockMessages["zh-CN"],
1408
1920
  commandPalette: commandPaletteMessages["zh-CN"],
1921
+ commentComposer: commentComposerMessages["zh-CN"],
1922
+ comments: commentsMessages["zh-CN"],
1409
1923
  contextMenu: contextMenuMessages["zh-CN"],
1410
1924
  dateInput: dateInputMessages["zh-CN"],
1411
1925
  dateRangeInput: dateRangeInputMessages["zh-CN"],
1412
1926
  dateTimeInput: dateTimeInputMessages["zh-CN"],
1413
1927
  dialog: dialogMessages["zh-CN"],
1414
1928
  dropdownMenu: dropdownMenuMessages["zh-CN"],
1929
+ emojiPicker: emojiPickerMessages["zh-CN"],
1415
1930
  field: fieldMessages["zh-CN"],
1416
1931
  fileInput: fileInputMessages["zh-CN"],
1417
1932
  input: inputMessages["zh-CN"],
@@ -1498,4 +2013,4 @@ function useAstryxMessages() {
1498
2013
  });
1499
2014
  }
1500
2015
  //#endregion
1501
- export { provideAstryxLocale as a, astryxMessages as c, normalizeLocale as i, astryxMessagesKey as n, useAstryxLocale as o, builtInMessages as r, useAstryxMessages as s, astryxLocaleKey as t };
2016
+ export { provideAstryxLocale as a, astryxMessages as c, normalizeLocale as i, formatIcu as l, astryxMessagesKey as n, useAstryxLocale as o, builtInMessages as r, useAstryxMessages as s, astryxLocaleKey as t, icuPlaceholderNames as u };
@@ -139,8 +139,8 @@ declare const __VLS_export: <Value>(__VLS_props: NonNullable<Awaited<typeof __VL
139
139
  props: import("vue").PublicProps & __VLS_PrettifyLocal<(ComplexSelectorProps<Value> & {
140
140
  modelValue: Value;
141
141
  }) & {
142
- onChange?: ((value: Value) => any) | undefined;
143
142
  onClick?: ((event: MouseEvent) => any) | undefined;
143
+ onChange?: ((value: Value) => any) | undefined;
144
144
  onKeydown?: ((event: KeyboardEvent) => any) | undefined;
145
145
  onOpenChange?: ((isOpen: boolean) => any) | undefined;
146
146
  "onUpdate:modelValue"?: ((value: Value) => any) | undefined;
@@ -150,7 +150,7 @@ declare const __VLS_export: <Value>(__VLS_props: NonNullable<Awaited<typeof __VL
150
150
  expose: (exposed: import("vue").ShallowUnwrapRef<ComplexSelectorHandle>) => void;
151
151
  attrs: any;
152
152
  slots: ComplexSelectorSlots<Value>;
153
- emit: (((evt: "change", value: Value) => void) & ((evt: "click", event: MouseEvent) => void) & ((evt: "keydown", event: KeyboardEvent) => void) & ((evt: "openChange", isOpen: boolean) => void)) & ((event: "update:modelValue", value: Value) => void);
153
+ emit: (((evt: "click", event: MouseEvent) => void) & ((evt: "change", value: Value) => void) & ((evt: "keydown", event: KeyboardEvent) => void) & ((evt: "openChange", isOpen: boolean) => void)) & ((event: "update:modelValue", value: Value) => void);
154
154
  }>) => import("vue").VNode & {
155
155
  __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
156
156
  };
@@ -154,11 +154,11 @@ type __VLS_Slots = {
154
154
  default: () => unknown;
155
155
  };
156
156
  declare const __VLS_base: import("vue").DefineComponent<TabListProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
157
- change: (value: string) => any;
158
157
  "update:value": (value: string) => any;
158
+ change: (value: string) => any;
159
159
  }, string, import("vue").PublicProps, Readonly<TabListProps> & Readonly<{
160
- onChange?: ((value: string) => any) | undefined;
161
160
  "onUpdate:value"?: ((value: string) => any) | undefined;
161
+ onChange?: ((value: string) => any) | undefined;
162
162
  }>, {
163
163
  size: TabListSize;
164
164
  isFullBleed: boolean;
@@ -391,22 +391,22 @@ declare const __VLS_base: import("vue").DefineComponent<PowerSearchProps, {
391
391
  focusTypeahead: () => void | undefined;
392
392
  blurTypeahead: () => void | undefined;
393
393
  }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
394
- change: (filters: PowerSearchFilter[], changeType: PowerSearchChangeType, index: number) => any;
395
394
  blur: (event: FocusEvent) => any;
396
395
  focus: (event: FocusEvent) => any;
396
+ change: (filters: PowerSearchFilter[], changeType: PowerSearchChangeType, index: number) => any;
397
397
  "update:filters": (filters: PowerSearchFilter[]) => any;
398
398
  }, string, import("vue").PublicProps, Readonly<PowerSearchProps> & Readonly<{
399
- onChange?: ((filters: PowerSearchFilter[], changeType: PowerSearchChangeType, index: number) => any) | undefined;
400
399
  onBlur?: ((event: FocusEvent) => any) | undefined;
401
400
  onFocus?: ((event: FocusEvent) => any) | undefined;
401
+ onChange?: ((filters: PowerSearchFilter[], changeType: PowerSearchChangeType, index: number) => any) | undefined;
402
402
  "onUpdate:filters"?: ((filters: PowerSearchFilter[]) => any) | undefined;
403
403
  }>, {
404
404
  size: PowerSearchSize;
405
405
  status: PowerSearchStatus;
406
406
  statusVariant: PowerSearchStatusVariant;
407
407
  hasClear: boolean;
408
- disabled: boolean;
409
408
  labelHidden: boolean;
409
+ disabled: boolean;
410
410
  clearable: boolean;
411
411
  overflow: PowerSearchOverflow;
412
412
  readOnly: boolean;
@@ -9,13 +9,13 @@ declare const __VLS_base: import("vue").DefineComponent<ButtonProps, {
9
9
  onClick?: ((event: MouseEvent) => any) | undefined;
10
10
  }>, {
11
11
  type: "button" | "reset" | "submit";
12
- isDisabled: boolean;
13
- variant: ButtonVariant;
14
12
  elevation: ButtonElevation;
13
+ isDisabled: boolean;
15
14
  isLoading: boolean;
16
15
  isIconOnly: boolean;
17
16
  isInterruptible: boolean;
18
17
  loadingLabel: string;
18
+ variant: ButtonVariant;
19
19
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
20
20
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
21
21
  declare const _default: typeof __VLS_export;