@8wave/ai-elements 0.124.0-beta.3 → 0.124.0-beta.5

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 (138) hide show
  1. package/dist/_chunks/{Agent-CsSvagZw.js → Agent-BBWFD4nI.js} +7 -1
  2. package/dist/_chunks/{Agent-CsSvagZw.js.map → Agent-BBWFD4nI.js.map} +1 -1
  3. package/dist/_chunks/{PkFilePreview-DXmgMwwu.js → PkFilePreview-CC2W-RXG.js} +197 -196
  4. package/dist/_chunks/{PkFilePreview-DXmgMwwu.js.map → PkFilePreview-CC2W-RXG.js.map} +1 -1
  5. package/dist/_chunks/{PkFilePreviewDialog-Bzt534GA.js → PkFilePreviewDialog-DYU2CUZS.js} +2 -2
  6. package/dist/_chunks/{PkFilePreviewDialog-Bzt534GA.js.map → PkFilePreviewDialog-DYU2CUZS.js.map} +1 -1
  7. package/dist/_chunks/{PkStreamingMarkdown-PQ3X83Fq.js → PkStreamingMarkdown-CeWyL_2B.js} +3 -3
  8. package/dist/_chunks/{PkStreamingMarkdown-PQ3X83Fq.js.map → PkStreamingMarkdown-CeWyL_2B.js.map} +1 -1
  9. package/dist/_chunks/{PkToolChatFile-CYxqugvO.js → PkToolChatFile-BMj7-urz.js} +3 -3
  10. package/dist/_chunks/{PkToolChatFile-CYxqugvO.js.map → PkToolChatFile-BMj7-urz.js.map} +1 -1
  11. package/dist/_chunks/{PkToolRequestGeolocation-CSAMqLyV.js → PkToolRequestGeolocation-D98zUqNQ.js} +2 -2
  12. package/dist/_chunks/{PkToolRequestGeolocation-CSAMqLyV.js.map → PkToolRequestGeolocation-D98zUqNQ.js.map} +1 -1
  13. package/dist/_chunks/{PkToolRequestOAuthConnection-ST3-OlS4.js → PkToolRequestOAuthConnection-DwcRnUcd.js} +2 -2
  14. package/dist/_chunks/{PkToolRequestOAuthConnection-ST3-OlS4.js.map → PkToolRequestOAuthConnection-DwcRnUcd.js.map} +1 -1
  15. package/dist/_chunks/{PkToolShowArtifact-BIpD-GkV.js → PkToolShowArtifact-BoJC-NtV.js} +2 -2
  16. package/dist/_chunks/{PkToolShowArtifact-BIpD-GkV.js.map → PkToolShowArtifact-BoJC-NtV.js.map} +1 -1
  17. package/dist/_chunks/{PkToolShowContactForm-2_YDqjeM.js → PkToolShowContactForm-CErVBzjl.js} +2 -2
  18. package/dist/_chunks/{PkToolShowContactForm-2_YDqjeM.js.map → PkToolShowContactForm-CErVBzjl.js.map} +1 -1
  19. package/dist/_chunks/{PkToolShowForm-Bu4igmQL.js → PkToolShowForm-B7Q79XAb.js} +4 -4
  20. package/dist/_chunks/{PkToolShowForm-Bu4igmQL.js.map → PkToolShowForm-B7Q79XAb.js.map} +1 -1
  21. package/dist/_chunks/{PkToolShowImageGallery-BMP-xuYr.js → PkToolShowImageGallery-CxeQcE6A.js} +2 -2
  22. package/dist/_chunks/{PkToolShowImageGallery-BMP-xuYr.js.map → PkToolShowImageGallery-CxeQcE6A.js.map} +1 -1
  23. package/dist/_chunks/{PkToolShowProductList-AkLG4dBV.js → PkToolShowProductList-DDqYsHNq.js} +2 -2
  24. package/dist/_chunks/{PkToolShowProductList-AkLG4dBV.js.map → PkToolShowProductList-DDqYsHNq.js.map} +1 -1
  25. package/dist/_chunks/{PkToolShowSources-DKtdU_Bq.js → PkToolShowSources-CTc2s510.js} +3 -3
  26. package/dist/_chunks/{PkToolShowSources-DKtdU_Bq.js.map → PkToolShowSources-CTc2s510.js.map} +1 -1
  27. package/dist/_chunks/{PkToolShowSuggestedReply-DVr8ps6g.js → PkToolShowSuggestedReply-vui8vph1.js} +2 -2
  28. package/dist/_chunks/{PkToolShowSuggestedReply-DVr8ps6g.js.map → PkToolShowSuggestedReply-vui8vph1.js.map} +1 -1
  29. package/dist/_chunks/{PkToolShowVideo-C5jqPYXw.js → PkToolShowVideo-C2kh6pVN.js} +2 -2
  30. package/dist/_chunks/{PkToolShowVideo-C5jqPYXw.js.map → PkToolShowVideo-C2kh6pVN.js.map} +1 -1
  31. package/dist/_chunks/{PkToolShowWebPages-BqL9PjpM.js → PkToolShowWebPages-By7zBIVa.js} +2 -2
  32. package/dist/_chunks/{PkToolShowWebPages-BqL9PjpM.js.map → PkToolShowWebPages-By7zBIVa.js.map} +1 -1
  33. package/dist/_chunks/{chatImagePolicy-ZiVuD6nX.js → chatImagePolicy-C4jFnVQl.js} +2 -2
  34. package/dist/_chunks/{chatImagePolicy-ZiVuD6nX.js.map → chatImagePolicy-C4jFnVQl.js.map} +1 -1
  35. package/dist/_chunks/{markdown-CUaXq5OY.js → markdown-DDYeZICP.js} +2 -2
  36. package/dist/_chunks/{markdown-CUaXq5OY.js.map → markdown-DDYeZICP.js.map} +1 -1
  37. package/dist/_chunks/{utils-Bz1Gb3iO.js → utils-DAQfsk2H.js} +109 -70
  38. package/dist/_chunks/utils-DAQfsk2H.js.map +1 -0
  39. package/dist/ai-elements.es.js +2529 -2509
  40. package/dist/ai-elements.es.js.map +1 -1
  41. package/dist-vue/PkChatbot.js +1 -1
  42. package/dist-vue/PkChatbotEmptyState.js +1 -1
  43. package/dist-vue/PkChatbotInput.js +1 -1
  44. package/dist-vue/PkChatbotMessages.js +1 -1
  45. package/dist-vue/PkChatbotStepPayload.js +1 -1
  46. package/dist-vue/PkChatbotStepToolDetail.js +1 -1
  47. package/dist-vue/PkChatbotSteps.js +1 -1
  48. package/dist-vue/PkChatbotViewChat.js +1 -1
  49. package/dist-vue/PkChatbotViewConversations.js +1 -1
  50. package/dist-vue/PkChatbotViewFiles.js +1 -1
  51. package/dist-vue/PkChatbotViewProfile.js +1 -1
  52. package/dist-vue/_chunks/{Agent-D3US-D1x.js → Agent-DQl-tv4S.js} +154 -148
  53. package/dist-vue/_chunks/{Agent-D3US-D1x.js.map → Agent-DQl-tv4S.js.map} +1 -1
  54. package/dist-vue/_chunks/{Document-D5FVOcP9.js → Document-DXDifFZE.js} +2 -2
  55. package/dist-vue/_chunks/{Document-D5FVOcP9.js.map → Document-DXDifFZE.js.map} +1 -1
  56. package/dist-vue/_chunks/{PkChatbot-C7--w-xA.js → PkChatbot-DQssgXm3.js} +8 -8
  57. package/dist-vue/_chunks/{PkChatbot-C7--w-xA.js.map → PkChatbot-DQssgXm3.js.map} +1 -1
  58. package/dist-vue/_chunks/{PkChatbotEmptyState-qKpfIuvI.js → PkChatbotEmptyState-B6qxJAPT.js} +2 -2
  59. package/dist-vue/_chunks/{PkChatbotEmptyState-qKpfIuvI.js.map → PkChatbotEmptyState-B6qxJAPT.js.map} +1 -1
  60. package/dist-vue/_chunks/{PkChatbotInput-DSH5IrO6.js → PkChatbotInput-Bk8OS1xU.js} +2 -2
  61. package/dist-vue/_chunks/{PkChatbotInput-DSH5IrO6.js.map → PkChatbotInput-Bk8OS1xU.js.map} +1 -1
  62. package/dist-vue/_chunks/PkChatbotMessages-D4LJZxv7.js +1041 -0
  63. package/dist-vue/_chunks/{PkChatbotMessages-pWNZCmM2.js.map → PkChatbotMessages-D4LJZxv7.js.map} +1 -1
  64. package/dist-vue/_chunks/{PkChatbotStepPayload-BT-Xg18D.js → PkChatbotStepPayload-_0WRbSR6.js} +2 -2
  65. package/dist-vue/_chunks/{PkChatbotStepPayload-BT-Xg18D.js.map → PkChatbotStepPayload-_0WRbSR6.js.map} +1 -1
  66. package/dist-vue/_chunks/{PkChatbotStepToolDetail-Cs322RDk.js → PkChatbotStepToolDetail-DiaervF2.js} +3 -3
  67. package/dist-vue/_chunks/{PkChatbotStepToolDetail-Cs322RDk.js.map → PkChatbotStepToolDetail-DiaervF2.js.map} +1 -1
  68. package/dist-vue/_chunks/PkChatbotSteps-BqL-ClgI.js +189 -0
  69. package/dist-vue/_chunks/{PkChatbotSteps-Dd62GEXJ.js.map → PkChatbotSteps-BqL-ClgI.js.map} +1 -1
  70. package/dist-vue/_chunks/{PkChatbotViewChat-mWZvsKLA.js → PkChatbotViewChat-BfVLCU_j.js} +337 -317
  71. package/dist-vue/_chunks/PkChatbotViewChat-BfVLCU_j.js.map +1 -0
  72. package/dist-vue/_chunks/{PkChatbotViewConversations-CIv5g2xZ.js → PkChatbotViewConversations-C32O6SsT.js} +3 -3
  73. package/dist-vue/_chunks/{PkChatbotViewConversations-CIv5g2xZ.js.map → PkChatbotViewConversations-C32O6SsT.js.map} +1 -1
  74. package/dist-vue/_chunks/{PkChatbotViewFiles-DjYF-UoB.js → PkChatbotViewFiles-Du5AAS4v.js} +3 -3
  75. package/dist-vue/_chunks/{PkChatbotViewFiles-DjYF-UoB.js.map → PkChatbotViewFiles-Du5AAS4v.js.map} +1 -1
  76. package/dist-vue/_chunks/{PkChatbotViewProfile-D3d-hG14.js → PkChatbotViewProfile-UZrZdOyM.js} +2 -2
  77. package/dist-vue/_chunks/{PkChatbotViewProfile-D3d-hG14.js.map → PkChatbotViewProfile-UZrZdOyM.js.map} +1 -1
  78. package/dist-vue/_chunks/{PkFilePreview-CFqcO3vY.js → PkFilePreview-jeqvHDm7.js} +30 -29
  79. package/dist-vue/_chunks/{PkFilePreview-CFqcO3vY.js.map → PkFilePreview-jeqvHDm7.js.map} +1 -1
  80. package/dist-vue/_chunks/{PkFilePreviewDialog-DeNnbXWq.js → PkFilePreviewDialog-BSvgiM9A.js} +2 -2
  81. package/dist-vue/_chunks/{PkFilePreviewDialog-DeNnbXWq.js.map → PkFilePreviewDialog-BSvgiM9A.js.map} +1 -1
  82. package/dist-vue/_chunks/{PkStreamingMarkdown-QDsT-4jC.js → PkStreamingMarkdown-Dk3iXhTm.js} +3 -3
  83. package/dist-vue/_chunks/{PkStreamingMarkdown-QDsT-4jC.js.map → PkStreamingMarkdown-Dk3iXhTm.js.map} +1 -1
  84. package/dist-vue/_chunks/{PkToolChatFile-UZeUytvT.js → PkToolChatFile-Bnj-YFLh.js} +3 -3
  85. package/dist-vue/_chunks/{PkToolChatFile-UZeUytvT.js.map → PkToolChatFile-Bnj-YFLh.js.map} +1 -1
  86. package/dist-vue/_chunks/{PkToolRequestGeolocation-gEDbmudT.js → PkToolRequestGeolocation-SDzM1-Wl.js} +2 -2
  87. package/dist-vue/_chunks/{PkToolRequestGeolocation-gEDbmudT.js.map → PkToolRequestGeolocation-SDzM1-Wl.js.map} +1 -1
  88. package/dist-vue/_chunks/{PkToolRequestOAuthConnection-C9_w8V0T.js → PkToolRequestOAuthConnection-DNrlGxMX.js} +2 -2
  89. package/dist-vue/_chunks/{PkToolRequestOAuthConnection-C9_w8V0T.js.map → PkToolRequestOAuthConnection-DNrlGxMX.js.map} +1 -1
  90. package/dist-vue/_chunks/{PkToolShowArtifact-ldnH-U3h.js → PkToolShowArtifact-BtCGilTJ.js} +2 -2
  91. package/dist-vue/_chunks/{PkToolShowArtifact-ldnH-U3h.js.map → PkToolShowArtifact-BtCGilTJ.js.map} +1 -1
  92. package/dist-vue/_chunks/{PkToolShowContactForm-4hISKYqb.js → PkToolShowContactForm-BZNIeJpf.js} +2 -2
  93. package/dist-vue/_chunks/{PkToolShowContactForm-4hISKYqb.js.map → PkToolShowContactForm-BZNIeJpf.js.map} +1 -1
  94. package/dist-vue/_chunks/{PkToolShowDiagram-uHFCQ0FJ.js → PkToolShowDiagram-KD4MfVkP.js} +2 -2
  95. package/dist-vue/_chunks/{PkToolShowDiagram-uHFCQ0FJ.js.map → PkToolShowDiagram-KD4MfVkP.js.map} +1 -1
  96. package/dist-vue/_chunks/{PkToolShowForm-DiUz5_Ct.js → PkToolShowForm-Dtfpi58S.js} +4 -4
  97. package/dist-vue/_chunks/{PkToolShowForm-DiUz5_Ct.js.map → PkToolShowForm-Dtfpi58S.js.map} +1 -1
  98. package/dist-vue/_chunks/{PkToolShowImageGallery-CEzeXupr.js → PkToolShowImageGallery-DnS04nTs.js} +2 -2
  99. package/dist-vue/_chunks/{PkToolShowImageGallery-CEzeXupr.js.map → PkToolShowImageGallery-DnS04nTs.js.map} +1 -1
  100. package/dist-vue/_chunks/{PkToolShowProductList-h4Dqvk1V.js → PkToolShowProductList-BlFKAtqQ.js} +2 -2
  101. package/dist-vue/_chunks/{PkToolShowProductList-h4Dqvk1V.js.map → PkToolShowProductList-BlFKAtqQ.js.map} +1 -1
  102. package/dist-vue/_chunks/{PkToolShowSources-BJd4zYAY.js → PkToolShowSources-DM177ZlR.js} +3 -3
  103. package/dist-vue/_chunks/{PkToolShowSources-BJd4zYAY.js.map → PkToolShowSources-DM177ZlR.js.map} +1 -1
  104. package/dist-vue/_chunks/{PkToolShowSuggestedReply-Bb7Inxa4.js → PkToolShowSuggestedReply-BlcEfMx8.js} +2 -2
  105. package/dist-vue/_chunks/{PkToolShowSuggestedReply-Bb7Inxa4.js.map → PkToolShowSuggestedReply-BlcEfMx8.js.map} +1 -1
  106. package/dist-vue/_chunks/{PkToolShowVideo-DgkpZriW.js → PkToolShowVideo-DQdVpaWT.js} +2 -2
  107. package/dist-vue/_chunks/{PkToolShowVideo-DgkpZriW.js.map → PkToolShowVideo-DQdVpaWT.js.map} +1 -1
  108. package/dist-vue/_chunks/{PkToolShowWebPages-DQr3SEGC.js → PkToolShowWebPages-Cx2Ft_wN.js} +2 -2
  109. package/dist-vue/_chunks/{PkToolShowWebPages-DQr3SEGC.js.map → PkToolShowWebPages-Cx2Ft_wN.js.map} +1 -1
  110. package/dist-vue/_chunks/{createChatbotApiClient-CFKeOgEA.js → createChatbotApiClient-Bukf58dz.js} +2 -2
  111. package/dist-vue/_chunks/{createChatbotApiClient-CFKeOgEA.js.map → createChatbotApiClient-Bukf58dz.js.map} +1 -1
  112. package/dist-vue/_chunks/{useChatbotStore--PcS9kGN.js → useChatbotStore-DcvdWkgq.js} +3 -3
  113. package/dist-vue/_chunks/{useChatbotStore--PcS9kGN.js.map → useChatbotStore-DcvdWkgq.js.map} +1 -1
  114. package/dist-vue/_chunks/{utils-DmBnucJs.js → utils-BuxgMuKv.js} +125 -76
  115. package/dist-vue/_chunks/utils-BuxgMuKv.js.map +1 -0
  116. package/dist-vue/api.js +1 -1
  117. package/dist-vue/apps/web-component/src/composables/useChatbotAgent.d.ts +4 -0
  118. package/dist-vue/composables.js +8 -8
  119. package/dist-vue/composables.js.map +1 -1
  120. package/dist-vue/index.js +5620 -5554
  121. package/dist-vue/index.js.map +1 -1
  122. package/dist-vue/locales.js +18 -0
  123. package/dist-vue/packages/components/src/chat/PkAgentSettingsPanel.d.ts +8 -2
  124. package/dist-vue/packages/components/src/chat/PkAuroraCanvas.d.ts +10 -3
  125. package/dist-vue/packages/components/src/chat/useChatFilePreview.d.ts +2 -0
  126. package/dist-vue/packages/components/src/chat/utils.d.ts +29 -0
  127. package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +12 -0
  128. package/dist-vue/packages/models/src/schema/Agent.d.ts +48 -0
  129. package/dist-vue/packages/models/src/schema/ReasoningChat.d.ts +12 -0
  130. package/dist-vue/packages/models/src/schema/SpreadsheetPreview.d.ts +5 -0
  131. package/dist-vue/packages/models/src/schema/SubAgent.d.ts +12 -0
  132. package/dist-vue/style.css +1 -1
  133. package/package.json +1 -1
  134. package/dist/_chunks/utils-Bz1Gb3iO.js.map +0 -1
  135. package/dist-vue/_chunks/PkChatbotMessages-pWNZCmM2.js +0 -1041
  136. package/dist-vue/_chunks/PkChatbotSteps-Dd62GEXJ.js +0 -189
  137. package/dist-vue/_chunks/PkChatbotViewChat-mWZvsKLA.js.map +0 -1
  138. package/dist-vue/_chunks/utils-DmBnucJs.js.map +0 -1
@@ -1,31 +1,31 @@
1
1
  import { r as e } from "./rolldown-runtime-9rEmUaIe.js";
2
2
  import { A as t, B as n, Et as r, F as i, I as a, J as o, L as s, N as c, Ot as l, Q as u, S as d, Tt as f, V as p, X as m, _ as h, d as g, f as _, g as v, gt as y, h as b, j as x, k as S, kt as C, ot as w, r as T, tt as E, v as D, w as O, wt as k, x as A, y as j, z as M } from "./vue.runtime.esm-bundler-C2U5uTqB.js";
3
3
  import { r as ee } from "./vue-i18n-POtLvOl1.js";
4
- import { B as te, F as N, H as P, I as ne, L as re, R as F, V as I, a as ie, z as L } from "./utils-Bz1Gb3iO.js";
5
- import { c as ae } from "./dist-m75acBC9.js";
6
- import { t as R } from "./index.es-fkUmGg9G.js";
7
- import { t as oe } from "./VvButtonLocalized-DCJiCUYU.js";
8
- import { t as z } from "./_plugin-vue_export-helper-Djzt4Yr7.js";
9
- import { t as se } from "./PkEditorRadioButtons-DWNs2pp4.js";
4
+ import { B as te, H as N, I as P, L as ne, R as re, U as F, V as ie, a as ae, z as oe } from "./utils-DAQfsk2H.js";
5
+ import { c as se } from "./dist-m75acBC9.js";
6
+ import { t as I } from "./index.es-fkUmGg9G.js";
7
+ import { t as ce } from "./VvButtonLocalized-DCJiCUYU.js";
8
+ import { t as L } from "./_plugin-vue_export-helper-Djzt4Yr7.js";
9
+ import { t as le } from "./PkEditorRadioButtons-DWNs2pp4.js";
10
10
  // ../../packages/components/src/chat/PkSpreadsheetPreview.vue?vue&type=script&setup=true&lang.ts
11
11
  S(), w(), f(), T();
12
- var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-preview__bar" }, le = ["aria-label"], V = ["aria-label"], ue = ["aria-label"], de = [
12
+ var R = { class: "pk-spreadsheet-preview" }, ue = { class: "pk-spreadsheet-preview__bar" }, de = ["aria-label"], z = ["aria-label"], fe = ["aria-label"], pe = [
13
13
  "rowspan",
14
14
  "colspan",
15
15
  "data-focus",
16
16
  "title",
17
17
  "onMousedown",
18
18
  "onMouseenter"
19
- ], fe = {
19
+ ], me = {
20
20
  key: 1,
21
21
  class: "pk-spreadsheet-preview__more"
22
- }, pe = ["aria-label"], me = ["aria-current", "onClick"], H = { class: "pk-spreadsheet-preview__status" }, he = { class: "pk-spreadsheet-preview__info" }, ge = ["title"], _e = ["title"], ve = {
22
+ }, B = ["aria-label"], he = ["aria-current", "onClick"], V = { class: "pk-spreadsheet-preview__status" }, ge = { class: "pk-spreadsheet-preview__info" }, _e = ["title"], ve = ["title"], ye = {
23
23
  key: 2,
24
24
  class: "pk-spreadsheet-preview__stats"
25
- }, ye = {
25
+ }, be = {
26
26
  key: 0,
27
27
  class: "pk-spreadsheet-preview__average"
28
- }, be = { key: 1 }, xe = { class: "pk-spreadsheet-preview__zoom" }, U = { class: "pk-spreadsheet-preview__percent" }, Se = 64, W = 20, G = 28, K = 44, q = /*#__PURE__*/ z(/* @__PURE__ */ O({
28
+ }, xe = { key: 1 }, Se = { class: "pk-spreadsheet-preview__zoom" }, H = { class: "pk-spreadsheet-preview__percent" }, Ce = 64, U = 20, W = 28, G = 44, K = /*#__PURE__*/ L(/* @__PURE__ */ O({
29
29
  __name: "PkSpreadsheetPreview",
30
30
  props: /*@__PURE__*/ c({ preview: { type: null } }, {
31
31
  sheet: { default: 0 },
@@ -35,7 +35,7 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
35
35
  }),
36
36
  emits: ["update:sheet", "update:zoom"],
37
37
  setup(e) {
38
- let t = e, { t: n, locale: a } = ee({ useScope: "global" }), s = o(e, "sheet"), c = o(e, "zoom"), f = m("scrollEl"), { width: h, height: S } = ae(f, {
38
+ let t = e, { t: n, locale: a } = ee({ useScope: "global" }), s = o(e, "sheet"), c = o(e, "zoom"), f = m("scrollEl"), { width: h, height: S } = se(f, {
39
39
  width: 0,
40
40
  height: 0
41
41
  }, { box: "border-box" }), w = b(() => t.preview.sheets[s.value] ?? t.preview.sheets[0]);
@@ -49,27 +49,27 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
49
49
  }, E = b(() => {
50
50
  let e = w.value;
51
51
  if (!e) return [];
52
- let t = new Set(e.columns.filter((e) => e.hidden).map((e) => e.col)), n = new Map(e.columns.map((e) => [e.col, e.width])), r = [], i = K, a = h.value / c.value;
52
+ let t = new Set(e.columns.filter((e) => e.hidden).map((e) => e.col)), n = new Map(e.columns.map((e) => [e.col, e.width])), r = [], i = G, a = h.value / c.value;
53
53
  for (let o = 1; o <= e.lastColumn || !e.moreColumns && (o <= e.lastColumn + 2 || i < a); o++) {
54
54
  if (t.has(o)) continue;
55
- let e = n.get(o) ?? Se;
55
+ let e = n.get(o) ?? Ce;
56
56
  r.push({
57
57
  col: o,
58
58
  width: e
59
59
  }), i += e;
60
60
  }
61
61
  return r;
62
- }), O = b(() => E.value.reduce((e, t) => e + t.width, K)), te = b(() => E.value.map((e) => `${e.col}:${e.width}`).join(",")), N = /* @__PURE__ */ new WeakMap(), P = b(() => {
62
+ }), O = b(() => E.value.reduce((e, t) => e + t.width, G)), te = b(() => E.value.map((e) => `${e.col}:${e.width}`).join(",")), N = /* @__PURE__ */ new WeakMap(), P = b(() => {
63
63
  let e = w.value;
64
64
  if (!e) return [];
65
- let t = new Set(e.hiddenRows ?? []), n = new Map(e.rows.map((e) => [e.row, e.height])), r = Math.ceil((S.value / c.value - G) / W), i = e.moreRows ? e.lastRow : Math.max(e.lastRow + 5, r + t.size), a = N.get(e);
65
+ let t = new Set(e.hiddenRows ?? []), n = new Map(e.rows.map((e) => [e.row, e.height])), r = Math.ceil((S.value / c.value - W) / U), i = e.moreRows ? e.lastRow : Math.max(e.lastRow + 5, r + t.size), a = N.get(e);
66
66
  a || (a = /* @__PURE__ */ new Map(), N.set(e, a));
67
67
  let o = a;
68
68
  return Array.from({ length: i }, (e, t) => t + 1).filter((e) => !t.has(e)).map((e) => {
69
69
  let t = o.get(e);
70
70
  return t || (t = {
71
71
  row: e,
72
- height: n.get(e) ?? W
72
+ height: n.get(e) ?? U
73
73
  }, o.set(e, t)), t;
74
74
  });
75
75
  }), ne = b(() => {
@@ -83,37 +83,38 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
83
83
  col: n.col
84
84
  });
85
85
  return e;
86
- }), F = (e, t) => ne.value.get(`${e},${t}`), I = (e, t) => {
86
+ }), F = (e, t) => ne.value.get(`${e},${t}`), ie = (e, t) => {
87
87
  let n = F(e, t)?.span;
88
88
  if (n) return {
89
89
  rows: P.value.filter((t) => t.row >= e && t.row < e + n.rows).length,
90
90
  cols: E.value.filter((e) => e.col >= t && e.col < t + n.cols).length
91
91
  };
92
- }, ie = (e) => e?.style === void 0 ? void 0 : t.preview.styles[e.style], L = (e, t) => {
92
+ }, ae = (e) => e?.style === void 0 ? void 0 : t.preview.styles[e.style], oe = (e, t) => {
93
93
  let n = e.decimals === void 0 ? { maximumFractionDigits: 10 } : {
94
94
  minimumFractionDigits: e.decimals,
95
95
  maximumFractionDigits: e.maxDecimals ?? e.decimals
96
96
  };
97
97
  return new Intl.NumberFormat(a.value, {
98
98
  ...n,
99
+ useGrouping: e.grouped === !0,
99
100
  ...e.format === "percent" ? { style: "percent" } : {},
100
101
  ...e.format === "currency" && e.currency ? {
101
102
  style: "currency",
102
103
  currency: e.currency
103
104
  } : {}
104
105
  }).format(t);
105
- }, R = (e) => {
106
+ }, I = (e) => {
106
107
  let t = /* @__PURE__ */ new Date(`${e}T00:00:00Z`);
107
108
  return Number.isNaN(t.getTime()) ? e : new Intl.DateTimeFormat(a.value, {
108
109
  dateStyle: "short",
109
110
  timeZone: "UTC"
110
111
  }).format(t);
111
- }, z = (e) => {
112
+ }, L = (e) => {
112
113
  if (!e) return "";
113
114
  if (e.missing) return "—";
114
115
  let t = e.value;
115
- return t === void 0 ? "" : typeof t == "boolean" ? n(t ? "chatFilePreview.true" : "chatFilePreview.false") : e.format === "date" && typeof t == "string" ? R(t) : typeof t == "number" ? L(e, t) : t;
116
- }, se = (e) => {
116
+ return t === void 0 ? "" : typeof t == "boolean" ? n(t ? "chatFilePreview.true" : "chatFilePreview.false") : e.format === "date" && typeof t == "string" ? I(t) : typeof t == "number" ? oe(e, t) : t;
117
+ }, le = (e) => {
117
118
  if (!e) return "";
118
119
  if (e.formula) return `=${e.formula}`;
119
120
  let t = e.value;
@@ -121,9 +122,9 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
121
122
  useGrouping: !1,
122
123
  maximumFractionDigits: 15,
123
124
  ...e.format === "percent" ? { style: "percent" } : {}
124
- }).format(t) : z(e);
125
- }, q = (e) => e ? `${e.width}px solid ${e.color}` : void 0, Ce = (e, t, n) => {
126
- let r = ie(e), i = e?.value, a = typeof i == "number" || !!e?.missing, o = {
125
+ }).format(t) : L(e);
126
+ }, K = (e) => e ? `${e.width}px solid ${e.color}` : void 0, we = (e, t, n) => {
127
+ let r = ae(e), i = e?.value, a = typeof i == "number" || !!e?.missing, o = {
127
128
  textAlign: r?.align ?? (a ? "right" : typeof i == "boolean" || e?.format === "error" ? "center" : "left"),
128
129
  verticalAlign: r?.valign === "top" ? "top" : r?.valign === "middle" ? "middle" : "bottom",
129
130
  whiteSpace: r?.wrap ? "pre-wrap" : "nowrap"
@@ -134,43 +135,43 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
134
135
  let e = `${4 + r.indent * 9}px`;
135
136
  o.textAlign === "right" ? o.paddingRight = e : o.paddingLeft = e;
136
137
  }
137
- return o.borderTop = q(r?.borders?.top), o.borderRight = q(r?.borders?.right), o.borderBottom = q(r?.borders?.bottom), o.borderLeft = q(r?.borders?.left), Object.assign(o, J(t, n)), o;
138
- }, J = (e, t) => {
138
+ return o.borderTop = K(r?.borders?.top), o.borderRight = K(r?.borders?.right), o.borderBottom = K(r?.borders?.bottom), o.borderLeft = K(r?.borders?.left), Object.assign(o, q(t, n)), o;
139
+ }, q = (e, t) => {
139
140
  let n = w.value?.frozen;
140
141
  if (!n) return {};
141
142
  let r = {};
142
- return e <= n.rows && (r.position = "sticky", r.top = `${G + P.value.filter((t) => t.row < e).reduce((e, t) => e + t.height, 0)}px`, r.zIndex = 2), t <= n.cols && (r.position = "sticky", r.left = `${K + E.value.filter((e) => e.col < t).reduce((e, t) => e + t.width, 0)}px`, r.zIndex = e <= n.rows ? 3 : 2), r;
143
- }, Y = y({
143
+ return e <= n.rows && (r.position = "sticky", r.top = `${W + P.value.filter((t) => t.row < e).reduce((e, t) => e + t.height, 0)}px`, r.zIndex = 2), t <= n.cols && (r.position = "sticky", r.left = `${G + E.value.filter((e) => e.col < t).reduce((e, t) => e + t.width, 0)}px`, r.zIndex = e <= n.rows ? 3 : 2), r;
144
+ }, J = y({
144
145
  row: 1,
145
146
  col: 1
146
- }), X = y({
147
+ }), Y = y({
147
148
  row: 1,
148
149
  col: 1
149
150
  });
150
151
  u(w, () => {
151
- Y.value = {
152
+ J.value = {
152
153
  row: 1,
153
154
  col: 1
154
- }, X.value = {
155
+ }, Y.value = {
155
156
  row: 1,
156
157
  col: 1
157
158
  };
158
159
  });
159
- let Z = b(() => ({
160
- r1: Math.min(Y.value.row, X.value.row),
161
- r2: Math.max(Y.value.row, X.value.row),
162
- c1: Math.min(Y.value.col, X.value.col),
163
- c2: Math.max(Y.value.col, X.value.col)
164
- })), we = (e, t) => e >= Z.value.r1 && e <= Z.value.r2 && t >= Z.value.c1 && t <= Z.value.c2, Te = (e, t) => X.value.row === e && X.value.col === t, Ee = (e) => e >= Z.value.r1 && e <= Z.value.r2 ? `${Z.value.c1}:${Z.value.c2}:${X.value.row === e ? X.value.col : 0}` : "", De = y(!1), Q = (e, t, n) => {
165
- f.value?.focus({ preventScroll: !0 }), X.value = {
160
+ let X = b(() => ({
161
+ r1: Math.min(J.value.row, Y.value.row),
162
+ r2: Math.max(J.value.row, Y.value.row),
163
+ c1: Math.min(J.value.col, Y.value.col),
164
+ c2: Math.max(J.value.col, Y.value.col)
165
+ })), Te = (e, t) => e >= X.value.r1 && e <= X.value.r2 && t >= X.value.c1 && t <= X.value.c2, Ee = (e, t) => Y.value.row === e && Y.value.col === t, De = (e) => e >= X.value.r1 && e <= X.value.r2 ? `${X.value.c1}:${X.value.c2}:${Y.value.row === e ? Y.value.col : 0}` : "", Z = y(!1), Q = (e, t, n) => {
166
+ f.value?.focus({ preventScroll: !0 }), Y.value = {
166
167
  row: e,
167
168
  col: t
168
- }, n.shiftKey || (Y.value = {
169
+ }, n.shiftKey || (J.value = {
169
170
  row: e,
170
171
  col: t
171
- }), De.value = !0;
172
+ }), Z.value = !0;
172
173
  }, Oe = (e, t) => {
173
- De.value && (X.value = {
174
+ Z.value && (Y.value = {
174
175
  row: e,
175
176
  col: t
176
177
  });
@@ -185,7 +186,7 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
185
186
  }[e.key];
186
187
  if (!t) return;
187
188
  e.preventDefault();
188
- let n = P.value.map((e) => e.row), r = E.value.map((e) => e.col), a = (e) => re.value.get(`${e.row},${e.col}`) ?? e, o = a(X.value), s = n.indexOf(X.value.row), c = r.indexOf(X.value.col), l = o;
189
+ let n = P.value.map((e) => e.row), r = E.value.map((e) => e.col), a = (e) => re.value.get(`${e.row},${e.col}`) ?? e, o = a(Y.value), s = n.indexOf(Y.value.row), c = r.indexOf(Y.value.col), l = o;
189
190
  for (;;) {
190
191
  let e = Math.min(n.length - 1, Math.max(0, s + t[0])), i = Math.min(r.length - 1, Math.max(0, c + t[1]));
191
192
  if (e === s && i === c || (s = e, c = i, l = a({
@@ -193,12 +194,12 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
193
194
  col: r[c]
194
195
  }), l.row !== o.row || l.col !== o.col)) break;
195
196
  }
196
- X.value = l, e.shiftKey || (Y.value = l), i(() => f.value?.querySelector("[data-focus]")?.scrollIntoView({
197
+ Y.value = l, e.shiftKey || (J.value = l), i(() => f.value?.querySelector("[data-focus]")?.scrollIntoView({
197
198
  block: "nearest",
198
199
  inline: "nearest"
199
200
  }));
200
- }, Ae = b(() => F(X.value.row, X.value.col)), $ = b(() => {
201
- let { r1: e, r2: t, c1: n, c2: r } = Z.value;
201
+ }, Ae = b(() => F(Y.value.row, Y.value.col)), $ = b(() => {
202
+ let { r1: e, r2: t, c1: n, c2: r } = X.value;
202
203
  if (e === t && n === r) return;
203
204
  let i = 0, a = 0, o = 0, s;
204
205
  for (let c = e; c <= t; c++) for (let e = n; e <= r; e++) {
@@ -207,20 +208,20 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
207
208
  }
208
209
  if (i) return {
209
210
  count: i,
210
- sum: s ? L(s, a) : void 0,
211
- average: s ? L(s, a / o) : void 0
211
+ sum: s ? oe(s, a) : void 0,
212
+ average: s ? oe(s, a / o) : void 0
212
213
  };
213
214
  }), je = (e) => {
214
215
  c.value = Math.min(2, Math.max(.5, Math.round((c.value + e) * 10) / 10));
215
216
  };
216
217
  return (t, i) => {
217
- let o = oe;
218
- return M(), j("div", B, [
219
- v("div", ce, [
218
+ let o = ce;
219
+ return M(), j("div", R, [
220
+ v("div", ue, [
220
221
  v("span", {
221
222
  class: "pk-spreadsheet-preview__ref",
222
223
  "aria-label": k(n)("chatFilePreview.cell")
223
- }, C(T(X.value.col)) + C(X.value.row), 9, le),
224
+ }, C(T(Y.value.col)) + C(Y.value.row), 9, de),
224
225
  i[6] ||= v("span", {
225
226
  class: "pk-spreadsheet-preview__fx",
226
227
  "aria-hidden": "true"
@@ -228,7 +229,7 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
228
229
  v("output", {
229
230
  class: "pk-spreadsheet-preview__formula",
230
231
  "aria-label": k(n)("chatFilePreview.formulaBar")
231
- }, C(se(Ae.value)), 9, V)
232
+ }, C(le(Ae.value)), 9, z)
232
233
  ]),
233
234
  v("div", {
234
235
  ref_key: "scrollEl",
@@ -238,8 +239,8 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
238
239
  role: "grid",
239
240
  "aria-label": w.value?.name,
240
241
  onKeydown: ke,
241
- onMouseup: i[2] ||= (e) => De.value = !1,
242
- onMouseleave: i[3] ||= (e) => De.value = !1
242
+ onMouseup: i[2] ||= (e) => Z.value = !1,
243
+ onMouseleave: i[3] ||= (e) => Z.value = !1
243
244
  }, [w.value ? (M(), j("table", {
244
245
  key: 0,
245
246
  class: r(["pk-spreadsheet-preview__grid", { "pk-spreadsheet-preview__grid--lines": w.value.gridlines }]),
@@ -248,14 +249,14 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
248
249
  width: `${O.value}px`
249
250
  })
250
251
  }, [
251
- v("colgroup", null, [v("col", { style: l({ width: `${K}px` }) }, null, 4), (M(!0), j(_, null, p(E.value, (e) => (M(), j("col", {
252
+ v("colgroup", null, [v("col", { style: l({ width: `${G}px` }) }, null, 4), (M(!0), j(_, null, p(E.value, (e) => (M(), j("col", {
252
253
  key: e.col,
253
254
  style: l({ width: `${e.width}px` })
254
255
  }, null, 4))), 128))]),
255
- v("thead", null, [v("tr", { style: l({ height: `${G}px` }) }, [i[7] ||= v("th", { class: "pk-spreadsheet-preview__corner" }, null, -1), (M(!0), j(_, null, p(E.value, (e) => (M(), j("th", {
256
+ v("thead", null, [v("tr", { style: l({ height: `${W}px` }) }, [i[7] ||= v("th", { class: "pk-spreadsheet-preview__corner" }, null, -1), (M(!0), j(_, null, p(E.value, (e) => (M(), j("th", {
256
257
  key: e.col,
257
258
  scope: "col",
258
- class: r(["pk-spreadsheet-preview__head", { "pk-spreadsheet-preview__head--current": e.col >= Z.value.c1 && e.col <= Z.value.c2 }])
259
+ class: r(["pk-spreadsheet-preview__head", { "pk-spreadsheet-preview__head--current": e.col >= X.value.c1 && e.col <= X.value.c2 }])
259
260
  }, C(T(e.col)), 3))), 128))], 4)]),
260
261
  v("tbody", null, [(M(!0), j(_, null, p(P.value, (e, t, i, o) => {
261
262
  let s = [
@@ -263,7 +264,7 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
263
264
  w.value,
264
265
  te.value,
265
266
  k(a),
266
- Ee(e.row)
267
+ De(e.row)
267
268
  ];
268
269
  if (o && o.el && o.key === e.row && x(o, s)) return o;
269
270
  let c = (M(), j("tr", {
@@ -271,29 +272,29 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
271
272
  style: l({ height: `${e.height}px` })
272
273
  }, [v("th", {
273
274
  scope: "row",
274
- class: r(["pk-spreadsheet-preview__row", { "pk-spreadsheet-preview__row--current": e.row >= Z.value.r1 && e.row <= Z.value.r2 }]),
275
+ class: r(["pk-spreadsheet-preview__row", { "pk-spreadsheet-preview__row--current": e.row >= X.value.r1 && e.row <= X.value.r2 }]),
275
276
  style: l(w.value.frozen && e.row <= w.value.frozen.rows ? {
276
- ...J(e.row, 0),
277
+ ...q(e.row, 0),
277
278
  left: 0,
278
279
  zIndex: 4
279
280
  } : void 0)
280
281
  }, C(e.row), 7), (M(!0), j(_, null, p(E.value, (t) => (M(), j(_, { key: t.col }, [re.value.has(`${e.row},${t.col}`) ? D("", !0) : (M(), j("td", {
281
282
  key: 0,
282
- rowspan: I(e.row, t.col)?.rows,
283
- colspan: I(e.row, t.col)?.cols,
283
+ rowspan: ie(e.row, t.col)?.rows,
284
+ colspan: ie(e.row, t.col)?.cols,
284
285
  class: r(["pk-spreadsheet-preview__cell", {
285
- "pk-spreadsheet-preview__cell--range": we(e.row, t.col) && !Te(e.row, t.col),
286
+ "pk-spreadsheet-preview__cell--range": Te(e.row, t.col) && !Ee(e.row, t.col),
286
287
  "pk-spreadsheet-preview__cell--missing": F(e.row, t.col)?.missing
287
288
  }]),
288
- style: l(Ce(F(e.row, t.col), e.row, t.col)),
289
- "data-focus": Te(e.row, t.col) ? "" : void 0,
289
+ style: l(we(F(e.row, t.col), e.row, t.col)),
290
+ "data-focus": Ee(e.row, t.col) ? "" : void 0,
290
291
  title: F(e.row, t.col)?.missing ? k(n)("chatFilePreview.missingValue") : void 0,
291
292
  onMousedown: g((n) => Q(e.row, t.col, n), ["prevent"]),
292
293
  onMouseenter: (n) => Oe(e.row, t.col)
293
- }, C(z(F(e.row, t.col))), 47, de))], 64))), 128))], 4));
294
+ }, C(L(F(e.row, t.col))), 47, pe))], 64))), 128))], 4));
294
295
  return c.memo = s, c;
295
296
  }, i, 0), 128))])
296
- ], 6)) : D("", !0), w.value && (w.value.moreRows || w.value.moreColumns) ? (M(), j("p", fe, [w.value.moreRows ? (M(), j(_, { key: 0 }, [A(C(k(n)("chatFilePreview.moreRows", w.value.moreRows)), 1)], 64)) : D("", !0), w.value.moreColumns ? (M(), j(_, { key: 1 }, [A(C(k(n)("chatFilePreview.moreColumns", w.value.moreColumns)), 1)], 64)) : D("", !0)])) : D("", !0)], 40, ue),
297
+ ], 6)) : D("", !0), w.value && (w.value.moreRows || w.value.moreColumns) ? (M(), j("p", me, [w.value.moreRows ? (M(), j(_, { key: 0 }, [A(C(k(n)("chatFilePreview.moreRows", w.value.moreRows)), 1)], 64)) : D("", !0), w.value.moreColumns ? (M(), j(_, { key: 1 }, [A(C(k(n)("chatFilePreview.moreColumns", w.value.moreColumns)), 1)], 64)) : D("", !0)])) : D("", !0)], 40, fe),
297
298
  v("nav", {
298
299
  class: "pk-spreadsheet-preview__sheets",
299
300
  "aria-label": k(n)("chatFilePreview.sheets")
@@ -303,20 +304,20 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
303
304
  class: "pk-spreadsheet-preview__sheet",
304
305
  "aria-current": t === s.value ? "page" : void 0,
305
306
  onClick: (e) => s.value = t
306
- }, C(e.name), 9, me))), 128))], 8, pe),
307
- v("div", H, [v("p", he, [e.preview.staleFormulas ? (M(), j("span", {
307
+ }, C(e.name), 9, he))), 128))], 8, B),
308
+ v("div", V, [v("p", ge, [e.preview.staleFormulas ? (M(), j("span", {
308
309
  key: 0,
309
310
  class: "pk-spreadsheet-preview__note",
310
311
  title: k(n)("chatFilePreview.staleFormulas")
311
- }, C(k(n)("chatFilePreview.staleFormulas")), 9, ge)) : e.preview.computedFormulas ? (M(), j("span", {
312
+ }, C(k(n)("chatFilePreview.staleFormulas")), 9, _e)) : e.preview.computedFormulas ? (M(), j("span", {
312
313
  key: 1,
313
314
  class: "pk-spreadsheet-preview__note",
314
315
  title: k(n)("chatFilePreview.computedFormulas")
315
- }, C(k(n)("chatFilePreview.computedFormulas")), 9, _e)) : D("", !0), $.value ? (M(), j("span", ve, [
316
- $.value.average ? (M(), j("span", ye, C(k(n)("chatFilePreview.average")) + " " + C($.value.average), 1)) : D("", !0),
316
+ }, C(k(n)("chatFilePreview.computedFormulas")), 9, ve)) : D("", !0), $.value ? (M(), j("span", ye, [
317
+ $.value.average ? (M(), j("span", be, C(k(n)("chatFilePreview.average")) + " " + C($.value.average), 1)) : D("", !0),
317
318
  v("span", null, C(k(n)("chatFilePreview.count")) + " " + C($.value.count), 1),
318
- $.value.sum ? (M(), j("span", be, C(k(n)("chatFilePreview.sum")) + " " + C($.value.sum), 1)) : D("", !0)
319
- ])) : D("", !0)]), v("div", xe, [
319
+ $.value.sum ? (M(), j("span", xe, C(k(n)("chatFilePreview.sum")) + " " + C($.value.sum), 1)) : D("", !0)
320
+ ])) : D("", !0)]), v("div", Se, [
320
321
  d(o, {
321
322
  modifiers: "action-quiet",
322
323
  icon: "ri:subtract-line",
@@ -324,7 +325,7 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
324
325
  disabled: c.value <= .5,
325
326
  onClick: i[4] ||= (e) => je(-.1)
326
327
  }, null, 8, ["aria-label", "disabled"]),
327
- v("span", U, C(Math.round(c.value * 100)) + "% ", 1),
328
+ v("span", H, C(Math.round(c.value * 100)) + "% ", 1),
328
329
  d(o, {
329
330
  modifiers: "action-quiet",
330
331
  icon: "ri:add-line",
@@ -339,10 +340,10 @@ var B = { class: "pk-spreadsheet-preview" }, ce = { class: "pk-spreadsheet-previ
339
340
  }), [["styles", [".pk-spreadsheet-preview{--pk-spreadsheet-green:#217346;--pk-spreadsheet-green-head:#217346;flex-direction:column;flex:1;min-height:0;display:flex}.pk-spreadsheet-preview__bar{min-height:var(--spacing-40);border-bottom:var(--border) solid var(--color-surface-3);background-color:var(--color-surface);font-size:var(--text-14);align-items:stretch;display:flex}.pk-spreadsheet-preview__ref{width:var(--spacing-96);padding:0 var(--spacing-12);box-sizing:border-box;border-right:var(--border) solid var(--color-surface-3);font-variant-numeric:tabular-nums;flex-shrink:0;align-items:center;display:flex}.pk-spreadsheet-preview__fx{width:var(--spacing-40);border-right:var(--border) solid var(--color-surface-3);color:var(--color-word-3);flex-shrink:0;justify-content:center;align-items:center;font-family:Georgia,serif;font-style:italic;display:flex}.pk-spreadsheet-preview__formula{min-width:0;padding:0 var(--spacing-12);text-overflow:ellipsis;white-space:nowrap;flex:1;align-items:center;display:flex;overflow:hidden}.pk-spreadsheet-preview__scroll{cursor:cell;background-color:#fff;outline:none;flex:1;min-height:0;overflow:auto}.pk-spreadsheet-preview__scroll:focus-visible{box-shadow:inset 0 0 0 var(--spacing-2) var(--input-focus-color)}.pk-spreadsheet-preview__grid{border-collapse:collapse;table-layout:fixed;color:#000;-webkit-user-select:none;user-select:none;font-family:Calibri,Carlito,Segoe UI,Arial,sans-serif;font-size:11pt}.pk-spreadsheet-preview__grid td{max-width:0;padding:0 var(--spacing-4);text-overflow:clip;background-color:#fff;line-height:1.2;overflow:hidden}.pk-spreadsheet-preview__grid--lines td{border:var(--border) solid #e1e1e1}.pk-spreadsheet-preview__corner,.pk-spreadsheet-preview__head,.pk-spreadsheet-preview__row{z-index:1;border:var(--border) solid var(--color-surface-3);background-color:var(--color-surface-1);color:var(--color-word-3);font-family:var(--font-family-sans);font-size:var(--text-12);font-weight:var(--font-normal);text-align:center;position:sticky}.pk-spreadsheet-preview__corner,.pk-spreadsheet-preview__head{padding:var(--spacing-4) var(--spacing-4) var(--spacing-2);vertical-align:middle;line-height:1;top:0}.pk-spreadsheet-preview__row{vertical-align:middle}.pk-spreadsheet-preview__corner{z-index:5;left:0}.pk-spreadsheet-preview__row{padding:0 var(--spacing-4);font-variant-numeric:tabular-nums;left:0}.pk-spreadsheet-preview__head--current{background-color:var(--color-surface-2);box-shadow:inset 0 calc(var(--spacing-2) * -1) 0 var(--pk-spreadsheet-green-head);color:var(--pk-spreadsheet-green-head);font-weight:var(--font-medium)}.pk-spreadsheet-preview__row--current{background-color:var(--color-surface-2);box-shadow:inset calc(var(--spacing-2) * -1) 0 0 var(--pk-spreadsheet-green-head);color:var(--pk-spreadsheet-green-head);font-weight:var(--font-medium)}.pk-spreadsheet-preview__cell[data-focus]{outline:var(--spacing-2) solid var(--pk-spreadsheet-green);outline-offset:calc(var(--spacing-2) * -1)}.pk-spreadsheet-preview__cell--range{box-shadow:inset 0 0 0 100vmax #1f1d2b14}.pk-spreadsheet-preview__cell--missing{color:#6b6880}.pk-spreadsheet-preview__more{padding:var(--spacing-8) var(--spacing-12);color:#6b6880;font-size:var(--text-12);margin:0;position:sticky;left:0}.pk-spreadsheet-preview__sheets{min-height:var(--spacing-32);padding-left:var(--spacing-40);border-top:var(--border) solid var(--color-surface-3);background-color:var(--color-surface-1);flex-shrink:0;display:flex;overflow-x:auto}@media (pointer:coarse){.pk-spreadsheet-preview__sheets{min-height:var(--spacing-40)}}.pk-spreadsheet-preview__status{min-height:var(--spacing-40);border-top:var(--border) solid var(--color-surface-3);background-color:var(--color-surface-1);font-size:var(--text-12);flex-shrink:0;align-items:center;display:flex}.pk-spreadsheet-preview__sheet{padding:0 var(--spacing-16);border:0;border-right:var(--border) solid var(--color-surface-3);color:var(--color-word-2);font:inherit;font-size:var(--text-12);white-space:nowrap;cursor:pointer;background:0 0;flex-shrink:0}.pk-spreadsheet-preview__sheet:first-child{border-left:var(--border) solid var(--color-surface-3)}.pk-spreadsheet-preview__sheet:hover{background-color:var(--color-surface-2)}.pk-spreadsheet-preview__sheet[aria-current=page]{background-color:var(--color-surface);box-shadow:inset 0 calc(var(--spacing-2) * -1) 0 var(--pk-spreadsheet-green-head);color:var(--pk-spreadsheet-green-head);font-weight:var(--font-semibold)}.pk-spreadsheet-preview__info{align-items:center;gap:var(--spacing-16);min-width:0;padding:0 var(--spacing-12);color:var(--color-word-2);font-variant-numeric:tabular-nums;white-space:nowrap;flex:1;margin:0;display:flex;overflow:hidden}.pk-spreadsheet-preview__note{min-width:0;color:var(--color-word-3);text-overflow:ellipsis;overflow:hidden}.pk-spreadsheet-preview__stats{gap:var(--spacing-12);flex-shrink:0;margin-left:auto;display:flex}@container (width<26rem){.pk-spreadsheet-preview__average{display:none}}.pk-spreadsheet-preview__zoom{align-items:center;gap:var(--spacing-2);padding-right:var(--spacing-8);flex-shrink:0;display:flex}.pk-spreadsheet-preview__percent{min-width:var(--spacing-40);font-variant-numeric:tabular-nums;text-align:center}@media (prefers-color-scheme:dark){:where(:host,:root,.theme):not(.theme--light) .pk-spreadsheet-preview{--pk-spreadsheet-green-head:#5fbf8f}}:where(.theme.theme--dark) .pk-spreadsheet-preview{--pk-spreadsheet-green-head:#5fbf8f}"]]]);
340
341
  // ../../packages/components/src/chat/PkWordPreviewRuns.vue?vue&type=script&setup=true&lang.ts
341
342
  S(), f(), w();
342
- var Ce = ["src"], J = {
343
+ var we = ["src"], q = {
343
344
  key: 1,
344
345
  class: "pk-word-preview__image"
345
- }, Y = ["title"], X = ["title"], Z = /* @__PURE__ */ O({
346
+ }, J = ["title"], Y = ["title"], X = /* @__PURE__ */ O({
346
347
  __name: "PkWordPreviewRuns",
347
348
  props: {
348
349
  runs: { type: Array },
@@ -351,13 +352,13 @@ var Ce = ["src"], J = {
351
352
  numbers: { type: Object }
352
353
  },
353
354
  setup(e) {
354
- let n = e, { t: i } = ee({ useScope: "global" }), a = t(ie, void 0), o = (e) => e.picture ? P(a?.value, e.picture.ref) : void 0, s = (e) => n.page ? I(e) : "inline", c = (e) => {
355
+ let n = e, { t: i } = ee({ useScope: "global" }), a = t(ae, void 0), o = (e) => e.picture ? F(a?.value, e.picture.ref) : void 0, s = (e) => n.page ? N(e) : "inline", c = (e) => {
355
356
  let t = {
356
357
  width: `${e.width}pt`,
357
358
  aspectRatio: `${e.width} / ${e.height}`
358
359
  }, r = e.anchor, i = n.page;
359
360
  if (!r || !i) return t;
360
- let a = r.xFrom === "page" ? r.x - i.margins.left : r.x, o = I(e);
361
+ let a = r.xFrom === "page" ? r.x - i.margins.left : r.x, o = N(e);
361
362
  if (o === "around") {
362
363
  let n = i.width - i.margins.left - i.margins.right, o = a + e.width / 2 < n / 2;
363
364
  return {
@@ -379,7 +380,7 @@ var Ce = ["src"], J = {
379
380
  zIndex: r.wrap === "behind" ? -1 : 1
380
381
  };
381
382
  }, u = (e) => e.field && n.numbers ? String(n.numbers[e.field]) : e.text, d = b(() => {
382
- let e = re(n.runs, n.mode ?? "markup"), t = (e) => !!e.picture && !!n.page && ["around", "block"].includes(I(e.picture));
383
+ let e = re(n.runs, n.mode ?? "markup"), t = (e) => !!e.picture && !!n.page && ["around", "block"].includes(N(e.picture));
383
384
  return [...e.filter(t), ...e.filter((e) => !t(e))];
384
385
  }), f = b(() => !n.mode || n.mode === "markup"), m = (e) => {
385
386
  let t = {};
@@ -399,17 +400,17 @@ var Ce = ["src"], J = {
399
400
  style: l(c(e.picture)),
400
401
  src: o(e),
401
402
  alt: ""
402
- }, null, 14, Ce))], 64)) : (M(), j("span", J, C(k(i)("chatFilePreview.image")), 1))], 64)) : f.value && e.change === "deleted" ? (M(), j("del", {
403
+ }, null, 14, we))], 64)) : (M(), j("span", q, C(k(i)("chatFilePreview.image")), 1))], 64)) : f.value && e.change === "deleted" ? (M(), j("del", {
403
404
  key: 1,
404
405
  class: "pk-word-preview__removed",
405
406
  style: l(h(e)),
406
407
  title: g(e)
407
- }, C(u(e)), 13, Y)) : f.value && e.change === "inserted" ? (M(), j("ins", {
408
+ }, C(u(e)), 13, J)) : f.value && e.change === "inserted" ? (M(), j("ins", {
408
409
  key: 2,
409
410
  class: "pk-word-preview__added",
410
411
  style: l(h(e)),
411
412
  title: g(e)
412
- }, C(u(e)), 13, X)) : (M(), j("span", {
413
+ }, C(u(e)), 13, Y)) : (M(), j("span", {
413
414
  key: 3,
414
415
  style: l(m(e))
415
416
  }, C(u(e)), 5))], 64))), 128));
@@ -417,7 +418,7 @@ var Ce = ["src"], J = {
417
418
  });
418
419
  // ../../packages/components/src/chat/PkWordPreviewBlock.vue?vue&type=script&setup=true&lang.ts
419
420
  S(), f();
420
- var we = { key: 0 }, Te = ["colspan"], Ee = ["role", "aria-level"], De = { key: 1 }, Q = /* @__PURE__ */ O({
421
+ var Te = { key: 0 }, Ee = ["colspan"], De = ["role", "aria-level"], Z = { key: 1 }, Q = /* @__PURE__ */ O({
421
422
  __name: "PkWordPreviewBlock",
422
423
  props: {
423
424
  block: { type: null },
@@ -457,7 +458,7 @@ var we = { key: 0 }, Te = ["colspan"], Ee = ["role", "aria-level"], De = { key:
457
458
  "pk-word-preview__table--next": e.row !== 0,
458
459
  "pk-word-preview__changed": c.value
459
460
  }])
460
- }, [s.value.length ? (M(), j("colgroup", we, [(M(!0), j(_, null, p(s.value, (e, t) => (M(), j("col", {
461
+ }, [s.value.length ? (M(), j("colgroup", Te, [(M(!0), j(_, null, p(s.value, (e, t) => (M(), j("col", {
461
462
  key: t,
462
463
  style: l({ width: e })
463
464
  }, null, 4))), 128))])) : D("", !0), v("tbody", null, [v("tr", null, [(M(!0), j(_, null, p(o.value, (t, n) => (M(), j("td", {
@@ -468,7 +469,7 @@ var we = { key: 0 }, Te = ["colspan"], Ee = ["role", "aria-level"], De = { key:
468
469
  textAlign: t.align,
469
470
  fontSize: t.size ? `${t.size}pt` : void 0
470
471
  })
471
- }, [d(Z, {
472
+ }, [d(X, {
472
473
  runs: t.runs,
473
474
  mode: e.mode,
474
475
  numbers: e.numbers
@@ -476,7 +477,7 @@ var we = { key: 0 }, Te = ["colspan"], Ee = ["role", "aria-level"], De = { key:
476
477
  "runs",
477
478
  "mode",
478
479
  "numbers"
479
- ])], 12, Te))), 128))])])], 2)) : e.block.kind === "table" ? D("", !0) : (M(), j("div", {
480
+ ])], 12, Ee))), 128))])])], 2)) : e.block.kind === "table" ? D("", !0) : (M(), j("div", {
480
481
  key: 1,
481
482
  class: r(["pk-word-preview__block", { "pk-word-preview__changed": a.value }]),
482
483
  role: e.block.kind === "heading" ? "heading" : void 0,
@@ -488,7 +489,7 @@ var we = { key: 0 }, Te = ["colspan"], Ee = ["role", "aria-level"], De = { key:
488
489
  class: "pk-word-preview__label",
489
490
  style: l(i.value)
490
491
  }, C(e.block.label), 5)) : D("", !0),
491
- d(Z, {
492
+ d(X, {
492
493
  runs: e.block.runs,
493
494
  mode: e.mode,
494
495
  page: e.page,
@@ -499,8 +500,8 @@ var we = { key: 0 }, Te = ["colspan"], Ee = ["role", "aria-level"], De = { key:
499
500
  "page",
500
501
  "numbers"
501
502
  ]),
502
- !e.block.label && !e.block.runs.length ? (M(), j("br", De)) : D("", !0)
503
- ], 14, Ee));
503
+ !e.block.label && !e.block.runs.length ? (M(), j("br", Z)) : D("", !0)
504
+ ], 14, De));
504
505
  }
505
506
  });
506
507
  // ../../packages/components/src/chat/PkWordPreviewPart.vue?vue&type=script&setup=true&lang.ts
@@ -515,11 +516,11 @@ var Oe = { class: "pk-word-preview__part" }, ke = ["src"], Ae = /* @__PURE__ */
515
516
  numbers: { type: Object }
516
517
  },
517
518
  setup(e) {
518
- let n = e, r = t(ie, void 0), i = b(() => N(n.blocks, n.mode)), a = b(() => te(n.blocks, n.mode).flatMap((e) => {
519
- let t = P(r?.value, e.ref);
519
+ let n = e, r = t(ae, void 0), i = b(() => P(n.blocks, n.mode)), a = b(() => ie(n.blocks, n.mode).flatMap((e) => {
520
+ let t = F(r?.value, e.ref);
520
521
  return t ? [{
521
522
  src: t,
522
- css: L(e, n.section.page)
523
+ css: te(e, n.section.page)
523
524
  }] : [];
524
525
  })), o = b(() => {
525
526
  let { margins: e } = n.section.page;
@@ -586,7 +587,7 @@ var $ = ["aria-label"], je = {
586
587
  }, Ye = { class: "pk-word-preview__count" }, Xe = {
587
588
  key: 1,
588
589
  class: "pk-word-preview__legend"
589
- }, Ze = ["title"], Qe = { class: "pk-word-preview__removed" }, $e = { class: "pk-word-preview__added" }, et = { class: "pk-word-preview__percent" }, tt = ["data-part"], nt = 96 / 72, rt = /*#__PURE__*/ z(/* @__PURE__ */ O({
590
+ }, Ze = ["title"], Qe = { class: "pk-word-preview__removed" }, $e = { class: "pk-word-preview__added" }, et = { class: "pk-word-preview__percent" }, tt = ["data-part"], nt = 96 / 72, rt = /*#__PURE__*/ L(/* @__PURE__ */ O({
590
591
  __name: "PkWordPreview",
591
592
  props: /*@__PURE__*/ c({
592
593
  preview: { type: null },
@@ -603,48 +604,48 @@ var $ = ["aria-label"], je = {
603
604
  emits: ["update:fit", "update:zoom"],
604
605
  setup(e) {
605
606
  let t = e, { t: c } = ee({ useScope: "global" });
606
- n(ie, b(() => t.preview.images));
607
- let f = (e) => re(e, t.mode), g = b(() => N(t.preview.blocks, t.mode)), x = m("rootEl"), S = m("scrollEl"), w = m("measureEl"), { width: T } = ae(x), { width: E } = ae(S), O = b(() => T.value === 0 || T.value >= 640), A = b(() => T.value >= 1e3), I = b(() => t.preview.sections?.length ? t.preview.sections : [{
607
+ n(ae, b(() => t.preview.images));
608
+ let f = (e) => re(e, t.mode), g = b(() => P(t.preview.blocks, t.mode)), x = m("rootEl"), S = m("scrollEl"), w = m("measureEl"), { width: T } = se(x), { width: E } = se(S), O = b(() => T.value === 0 || T.value >= 640), A = b(() => T.value >= 1e3), N = b(() => t.preview.sections?.length ? t.preview.sections : [{
608
609
  page: t.preview.page,
609
610
  headerDistance: 0,
610
611
  footerDistance: 0,
611
612
  headers: {},
612
613
  footers: {}
613
- }]), R = b(() => I.value[0].page), z = b(() => ({
614
+ }]), I = b(() => N.value[0].page), L = b(() => ({
614
615
  fontFamily: ne(t.preview.defaults.font),
615
616
  fontSize: `${t.preview.defaults.size}pt`,
616
617
  color: t.preview.defaults.color ?? "#000000",
617
- "--pk-word-line": F(t.preview.defaults.font),
618
+ "--pk-word-line": oe(t.preview.defaults.font),
618
619
  "--pk-word-size": `${t.preview.defaults.size}pt`
619
- })), se = b(() => ({
620
- ...z.value,
621
- width: `${R.value.width - R.value.margins.left - R.value.margins.right}pt`
622
- })), B = y([]), ce = y({}), le = async () => {
620
+ })), le = b(() => ({
621
+ ...L.value,
622
+ width: `${I.value.width - I.value.margins.left - I.value.margins.right}pt`
623
+ })), R = y([]), ue = y({}), de = async () => {
623
624
  await i();
624
625
  let e = w.value?.querySelectorAll("[data-item]");
625
- B.value = [...e ?? []].map((e) => e.getBoundingClientRect().height);
626
+ R.value = [...e ?? []].map((e) => e.getBoundingClientRect().height);
626
627
  let t = w.value?.querySelectorAll("[data-part]");
627
- ce.value = Object.fromEntries([...t ?? []].map((e) => [e.dataset.part ?? "", e.getBoundingClientRect().height]));
628
+ ue.value = Object.fromEntries([...t ?? []].map((e) => [e.dataset.part ?? "", e.getBoundingClientRect().height]));
628
629
  };
629
630
  u([
630
631
  g,
631
632
  O,
632
633
  () => t.preview.parts
633
- ], le, { flush: "post" }), s(() => {
634
- le(), document.fonts?.ready.then(le);
634
+ ], de, { flush: "post" }), s(() => {
635
+ de(), document.fonts?.ready.then(de);
635
636
  });
636
- let V = b(() => {
637
- if (!O.value || B.value.length !== g.value.length) return [{
637
+ let z = b(() => {
638
+ if (!O.value || R.value.length !== g.value.length) return [{
638
639
  items: g.value.map((e, t) => t),
639
640
  section: 0,
640
641
  number: 1,
641
- top: R.value.margins.top,
642
- bottom: R.value.margins.bottom
642
+ top: I.value.margins.top,
643
+ bottom: I.value.margins.bottom
643
644
  }];
644
645
  let e = [], n = 0, r = !0, i = 0, a, o = () => {
645
- let o = I.value[n], s = r && o.pageStart !== void 0 ? o.pageStart : (a ?? e[e.length - 1]?.number ?? 0) + 1;
646
+ let o = N.value[n], s = r && o.pageStart !== void 0 ? o.pageStart : (a ?? e[e.length - 1]?.number ?? 0) + 1;
646
647
  a = void 0;
647
- let c = (e) => r && o.titlePage ? e.first : t.preview.evenAndOddHeaders && s % 2 == 0 ? e.even : e.default, l = c(o.headers), u = c(o.footers), d = (e) => e ? (ce.value[e] ?? 0) / nt : 0;
648
+ let c = (e) => r && o.titlePage ? e.first : t.preview.evenAndOddHeaders && s % 2 == 0 ? e.even : e.default, l = c(o.headers), u = c(o.footers), d = (e) => e ? (ue.value[e] ?? 0) / nt : 0;
648
649
  e.push({
649
650
  items: [],
650
651
  section: n,
@@ -656,38 +657,38 @@ var $ = ["aria-label"], je = {
656
657
  }), r = !1, i = 0;
657
658
  };
658
659
  return g.value.forEach((t, s) => {
659
- t.section !== void 0 && t.section !== n && I.value[t.section] && (n = t.section, r = t.breakBefore || !e.length, r || (a = I.value[n].pageStart));
660
- let c = e[e.length - 1], l = c && I.value[c.section].page, u = l ? (l.height - c.top - c.bottom) * nt : 0;
661
- (!c || c.items.length && (t.breakBefore || i + B.value[s] > u)) && o(), e[e.length - 1].items.push(s), i += B.value[s];
660
+ t.section !== void 0 && t.section !== n && N.value[t.section] && (n = t.section, r = t.breakBefore || !e.length, r || (a = N.value[n].pageStart));
661
+ let c = e[e.length - 1], l = c && N.value[c.section].page, u = l ? (l.height - c.top - c.bottom) * nt : 0;
662
+ (!c || c.items.length && (t.breakBefore || i + R.value[s] > u)) && o(), e[e.length - 1].items.push(s), i += R.value[s];
662
663
  }), e.length || o(), e;
663
- }), ue = b(() => {
664
+ }), fe = b(() => {
664
665
  let e = /* @__PURE__ */ new Map();
665
- for (let t of V.value) e.set(t.section, (e.get(t.section) ?? 0) + 1);
666
- return V.value.map((t) => ({
666
+ for (let t of z.value) e.set(t.section, (e.get(t.section) ?? 0) + 1);
667
+ return z.value.map((t) => ({
667
668
  page: t.number,
668
- pages: V.value.length,
669
+ pages: z.value.length,
669
670
  sectionPages: e.get(t.section) ?? 1
670
671
  }));
671
- }), de = (e) => {
672
- let t = I.value[e.section].page;
672
+ }), pe = (e) => {
673
+ let t = N.value[e.section].page;
673
674
  return {
674
- ...z.value,
675
+ ...L.value,
675
676
  width: `${t.width}pt`,
676
677
  minHeight: `${t.height}pt`,
677
678
  padding: `${e.top}pt ${t.margins.right}pt ${e.bottom}pt ${t.margins.left}pt`
678
679
  };
679
- }, fe = (e) => {
680
+ }, me = (e) => {
680
681
  let n = [...new Set(e.items.map((e) => g.value[e].block))];
681
- return te(n.map((e) => t.preview.blocks[e]), t.mode).flatMap((n) => {
682
- let r = P(t.preview.images, n.ref);
682
+ return ie(n.map((e) => t.preview.blocks[e]), t.mode).flatMap((n) => {
683
+ let r = F(t.preview.images, n.ref);
683
684
  return r ? [{
684
685
  src: r,
685
- css: L(n, I.value[e.section].page)
686
+ css: te(n, N.value[e.section].page)
686
687
  }] : [];
687
688
  });
688
- }, pe = o(e, "fit"), me = o(e, "zoom"), H = b(() => pe.value ? Math.min(1.25, Math.max(.3, (E.value - 48) / (R.value.width * nt))) : me.value), he = (e) => {
689
- me.value = Math.min(2, Math.max(.3, Math.round((H.value + e) * 10) / 10)), pe.value = !1;
690
- }, ge = y(0), _e = y(), ve = () => {
689
+ }, B = o(e, "fit"), he = o(e, "zoom"), V = b(() => B.value ? Math.min(1.25, Math.max(.3, (E.value - 48) / (I.value.width * nt))) : he.value), ge = (e) => {
690
+ he.value = Math.min(2, Math.max(.3, Math.round((V.value + e) * 10) / 10)), B.value = !1;
691
+ }, _e = y(0), ve = y(), ye = () => {
691
692
  let e = S.value?.getBoundingClientRect();
692
693
  if (!e) return;
693
694
  let t = S.value?.querySelectorAll("[data-page]") ?? [], n = 0;
@@ -695,50 +696,50 @@ var $ = ["aria-label"], je = {
695
696
  if (i.getBoundingClientRect().top - e.top > e.height / 3) break;
696
697
  n = r;
697
698
  }
698
- ge.value = n;
699
+ _e.value = n;
699
700
  let r;
700
- for (let t of U.value) {
701
+ for (let t of H.value) {
701
702
  let n = S.value?.querySelector(`[data-key="${t.key}"]`);
702
703
  if (n) {
703
704
  if (n.getBoundingClientRect().top - e.top > 48) break;
704
705
  r = t.key;
705
706
  }
706
707
  }
707
- _e.value = r ?? U.value[0]?.key;
708
- }, ye = 0, be = () => {
709
- ye ||= requestAnimationFrame(() => {
710
- ye = 0, ve();
708
+ ve.value = r ?? H.value[0]?.key;
709
+ }, be = 0, xe = () => {
710
+ be ||= requestAnimationFrame(() => {
711
+ be = 0, ye();
711
712
  });
712
713
  };
713
- a(() => cancelAnimationFrame(ye)), u(V, () => i(be));
714
- let xe = (e) => f(e).map((e) => e.text).join("").replace(/\s+/g, " ").trim(), U = b(() => g.value.flatMap((e) => {
715
- let n = t.preview.blocks[e.block], r = n.kind === "heading" ? [n.label, xe(n.runs)].filter(Boolean).join(" ") : "";
714
+ a(() => cancelAnimationFrame(be)), u(z, () => i(xe));
715
+ let Se = (e) => f(e).map((e) => e.text).join("").replace(/\s+/g, " ").trim(), H = b(() => g.value.flatMap((e) => {
716
+ let n = t.preview.blocks[e.block], r = n.kind === "heading" ? [n.label, Se(n.runs)].filter(Boolean).join(" ") : "";
716
717
  return n.kind === "heading" && n.level <= 3 && r ? [{
717
718
  key: e.key,
718
719
  level: n.level,
719
720
  text: r
720
721
  }] : [];
721
- })), Se = (e) => e.length > 60 ? `${e.slice(0, 60)}…` : e, W = b(() => g.value.flatMap((e) => {
722
+ })), Ce = (e) => e.length > 60 ? `${e.slice(0, 60)}…` : e, U = b(() => g.value.flatMap((e) => {
722
723
  let n = t.preview.blocks[e.block], r = n.kind === "table" ? (n.rows[e.row ?? 0] ?? []).flatMap((e) => e.runs) : n.runs, i = r.filter((e) => e.change === "deleted").map((e) => e.text).join(" ").trim(), a = r.filter((e) => e.change === "inserted").map((e) => e.text).join(" ").trim();
723
724
  return i || a ? [{
724
725
  key: e.key,
725
- removed: Se(i),
726
- added: Se(a)
726
+ removed: Ce(i),
727
+ added: Ce(a)
727
728
  }] : [];
728
- })), G = y("outline"), K = y(!1), q = (e) => {
729
+ })), W = y("outline"), G = y(!1), K = (e) => {
729
730
  S.value?.querySelector(`[data-key="${e}"]`)?.scrollIntoView({
730
731
  block: "start",
731
732
  behavior: "smooth"
732
- }), A.value || (K.value = !1);
733
- }, Ce = b(() => t.preview.blocks.flatMap((e) => e.kind === "table" ? e.rows.flat().map((e) => xe(e.runs)) : [xe(e.runs)]).join(" ").split(/\s+/).filter(Boolean).length), J = b(() => t.preview.revisionAuthors.join(", "));
733
+ }), A.value || (G.value = !1);
734
+ }, we = b(() => t.preview.blocks.flatMap((e) => e.kind === "table" ? e.rows.flat().map((e) => Se(e.runs)) : [Se(e.runs)]).join(" ").split(/\s+/).filter(Boolean).length), q = b(() => t.preview.revisionAuthors.join(", "));
734
735
  return (t, n) => {
735
- let i = oe;
736
+ let i = ce;
736
737
  return M(), j("div", {
737
738
  ref_key: "rootEl",
738
739
  ref: x,
739
740
  class: r(["pk-word-preview", { "pk-word-preview--paged": O.value }])
740
741
  }, [
741
- (A.value || K.value) && (U.value.length || W.value.length) ? (M(), j("aside", {
742
+ (A.value || G.value) && (H.value.length || U.value.length) ? (M(), j("aside", {
742
743
  key: 0,
743
744
  class: r(["pk-word-preview__side", { "pk-word-preview__side--over": !A.value }]),
744
745
  "aria-label": k(c)("chatFilePreview.outline")
@@ -746,53 +747,53 @@ var $ = ["aria-label"], je = {
746
747
  type: "button",
747
748
  role: "tab",
748
749
  class: "pk-word-preview__tab",
749
- "aria-selected": G.value === "outline",
750
- onClick: n[0] ||= (e) => G.value = "outline"
751
- }, C(k(c)("chatFilePreview.outline")), 9, Me), W.value.length ? (M(), j("button", {
750
+ "aria-selected": W.value === "outline",
751
+ onClick: n[0] ||= (e) => W.value = "outline"
752
+ }, C(k(c)("chatFilePreview.outline")), 9, Me), U.value.length ? (M(), j("button", {
752
753
  key: 0,
753
754
  type: "button",
754
755
  role: "tab",
755
756
  class: "pk-word-preview__tab",
756
- "aria-selected": G.value === "changes",
757
- onClick: n[1] ||= (e) => G.value = "changes"
758
- }, C(k(c)("chatFilePreview.changes", { count: W.value.length })), 9, Ne)) : D("", !0)]), G.value === "outline" || !W.value.length ? (M(), j("nav", Pe, [(M(!0), j(_, null, p(U.value, (e) => (M(), j("button", {
757
+ "aria-selected": W.value === "changes",
758
+ onClick: n[1] ||= (e) => W.value = "changes"
759
+ }, C(k(c)("chatFilePreview.changes", { count: U.value.length })), 9, Ne)) : D("", !0)]), W.value === "outline" || !U.value.length ? (M(), j("nav", Pe, [(M(!0), j(_, null, p(H.value, (e) => (M(), j("button", {
759
760
  key: e.key,
760
761
  type: "button",
761
762
  class: r(["pk-word-preview__entry", `pk-word-preview__entry--${Math.min(e.level, 3)}`]),
762
- "aria-current": _e.value === e.key ? "location" : void 0,
763
- onClick: (t) => q(e.key)
764
- }, [v("span", Ie, C(e.text), 1), W.value.some((t) => t.key === e.key) ? (M(), j("span", Le)) : D("", !0)], 10, Fe))), 128)), U.value.length ? D("", !0) : (M(), j("p", Re, C(k(c)("chatFilePreview.noHeadings")), 1))])) : (M(), j("nav", ze, [(M(!0), j(_, null, p(W.value, (e) => (M(), j("button", {
763
+ "aria-current": ve.value === e.key ? "location" : void 0,
764
+ onClick: (t) => K(e.key)
765
+ }, [v("span", Ie, C(e.text), 1), U.value.some((t) => t.key === e.key) ? (M(), j("span", Le)) : D("", !0)], 10, Fe))), 128)), H.value.length ? D("", !0) : (M(), j("p", Re, C(k(c)("chatFilePreview.noHeadings")), 1))])) : (M(), j("nav", ze, [(M(!0), j(_, null, p(U.value, (e) => (M(), j("button", {
765
766
  key: e.key,
766
767
  type: "button",
767
768
  class: "pk-word-preview__entry pk-word-preview__entry--change",
768
- onClick: (t) => q(e.key)
769
+ onClick: (t) => K(e.key)
769
770
  }, [e.removed ? (M(), j("del", Ve, C(e.removed), 1)) : D("", !0), e.added ? (M(), j("ins", He, C(e.added), 1)) : D("", !0)], 8, Be))), 128))]))], 10, $)) : D("", !0),
770
771
  v("div", Ue, [v("div", {
771
772
  ref_key: "scrollEl",
772
773
  ref: S,
773
774
  class: "pk-word-preview__scroll",
774
- onScroll: be
775
+ onScroll: xe
775
776
  }, [O.value ? (M(), j("div", {
776
777
  key: 0,
777
778
  class: "pk-word-preview__pages",
778
- style: l({ zoom: H.value })
779
- }, [(M(!0), j(_, null, p(V.value, (t, n) => (M(), j("article", {
779
+ style: l({ zoom: V.value })
780
+ }, [(M(!0), j(_, null, p(z.value, (t, n) => (M(), j("article", {
780
781
  key: n,
781
782
  "data-page": "",
782
783
  class: "pk-word-preview__page",
783
784
  "aria-label": k(c)("chatFilePreview.pageOf", {
784
785
  page: n + 1,
785
- count: V.value.length
786
+ count: z.value.length
786
787
  }),
787
- style: l(de(t))
788
+ style: l(pe(t))
788
789
  }, [
789
790
  t.header && e.preview.parts?.[t.header] ? (M(), h(Ae, {
790
791
  key: 0,
791
792
  blocks: e.preview.parts[t.header],
792
793
  where: "header",
793
- section: I.value[t.section],
794
+ section: N.value[t.section],
794
795
  mode: e.mode,
795
- numbers: ue.value[n]
796
+ numbers: fe.value[n]
796
797
  }, null, 8, [
797
798
  "blocks",
798
799
  "section",
@@ -805,8 +806,8 @@ var $ = ["aria-label"], je = {
805
806
  block: e.preview.blocks[g.value[r].block],
806
807
  row: g.value[r].row,
807
808
  mode: e.mode,
808
- page: I.value[t.section].page,
809
- numbers: ue.value[n]
809
+ page: N.value[t.section].page,
810
+ numbers: fe.value[n]
810
811
  }, null, 8, [
811
812
  "data-key",
812
813
  "block",
@@ -815,7 +816,7 @@ var $ = ["aria-label"], je = {
815
816
  "page",
816
817
  "numbers"
817
818
  ]))), 128)),
818
- (M(!0), j(_, null, p(fe(t), (e, t) => (M(), j("img", {
819
+ (M(!0), j(_, null, p(me(t), (e, t) => (M(), j("img", {
819
820
  key: `image-${t}`,
820
821
  class: "pk-word-preview__float",
821
822
  style: l(e.css),
@@ -826,9 +827,9 @@ var $ = ["aria-label"], je = {
826
827
  key: 1,
827
828
  blocks: e.preview.parts[t.footer],
828
829
  where: "footer",
829
- section: I.value[t.section],
830
+ section: N.value[t.section],
830
831
  mode: e.mode,
831
- numbers: ue.value[n]
832
+ numbers: fe.value[n]
832
833
  }, null, 8, [
833
834
  "blocks",
834
835
  "section",
@@ -838,7 +839,7 @@ var $ = ["aria-label"], je = {
838
839
  ], 12, We))), 128))], 4)) : (M(), j("article", {
839
840
  key: 1,
840
841
  class: "pk-word-preview__page pk-word-preview__page--flow",
841
- style: l(z.value)
842
+ style: l(L.value)
842
843
  }, [(M(!0), j(_, null, p(g.value, (t) => (M(), h(Q, {
843
844
  key: t.key,
844
845
  "data-key": t.key,
@@ -852,20 +853,20 @@ var $ = ["aria-label"], je = {
852
853
  "mode"
853
854
  ]))), 128))], 4)), e.preview.truncated ? (M(), j("p", Ke, C(k(c)("chatFilePreview.truncated")), 1)) : D("", !0)], 544), v("div", qe, [
854
855
  O.value ? (M(), j("span", Je, C(k(c)("chatFilePreview.pageOf", {
855
- page: ge.value + 1,
856
- count: V.value.length
856
+ page: _e.value + 1,
857
+ count: z.value.length
857
858
  })), 1)) : D("", !0),
858
- v("span", Ye, C(k(c)("chatFilePreview.words", Ce.value)), 1),
859
+ v("span", Ye, C(k(c)("chatFilePreview.words", we.value)), 1),
859
860
  e.mode === "markup" && e.preview.revisionAuthors.length ? (M(), j("span", Xe, [
860
861
  v("span", {
861
862
  class: "pk-word-preview__legend-text",
862
- title: k(c)("chatFilePreview.revisionsOf", { authors: J.value })
863
- }, C(k(c)("chatFilePreview.revisionsOf", { authors: J.value })), 9, Ze),
863
+ title: k(c)("chatFilePreview.revisionsOf", { authors: q.value })
864
+ }, C(k(c)("chatFilePreview.revisionsOf", { authors: q.value })), 9, Ze),
864
865
  v("del", Qe, C(k(c)("chatFilePreview.removed")), 1),
865
866
  v("ins", $e, C(k(c)("chatFilePreview.added")), 1)
866
867
  ])) : D("", !0),
867
868
  n[6] ||= v("span", { class: "pk-word-preview__spacer" }, null, -1),
868
- !A.value && (U.value.length || W.value.length) ? (M(), h(i, {
869
+ !A.value && (H.value.length || U.value.length) ? (M(), h(i, {
869
870
  key: 2,
870
871
  class: "pk-word-preview__outline-toggle",
871
872
  modifiers: "action-quiet",
@@ -873,8 +874,8 @@ var $ = ["aria-label"], je = {
873
874
  label: k(c)("chatFilePreview.outline"),
874
875
  title: k(c)("chatFilePreview.outline"),
875
876
  "aria-label": k(c)("chatFilePreview.outline"),
876
- "aria-expanded": K.value,
877
- onClick: n[2] ||= (e) => K.value = !K.value
877
+ "aria-expanded": G.value,
878
+ onClick: n[2] ||= (e) => G.value = !G.value
878
879
  }, null, 8, [
879
880
  "label",
880
881
  "title",
@@ -885,23 +886,23 @@ var $ = ["aria-label"], je = {
885
886
  d(i, {
886
887
  modifiers: "action-quiet",
887
888
  label: k(c)("chatFilePreview.fitWidth"),
888
- disabled: pe.value,
889
- onClick: n[3] ||= (e) => pe.value = !0
889
+ disabled: B.value,
890
+ onClick: n[3] ||= (e) => B.value = !0
890
891
  }, null, 8, ["label", "disabled"]),
891
892
  d(i, {
892
893
  modifiers: "action-quiet",
893
894
  icon: "ri:subtract-line",
894
895
  "aria-label": k(c)("chatFilePreview.zoomOut"),
895
- disabled: H.value <= .3,
896
- onClick: n[4] ||= (e) => he(-.1)
896
+ disabled: V.value <= .3,
897
+ onClick: n[4] ||= (e) => ge(-.1)
897
898
  }, null, 8, ["aria-label", "disabled"]),
898
- v("span", et, C(Math.round(H.value * 100)) + "% ", 1),
899
+ v("span", et, C(Math.round(V.value * 100)) + "% ", 1),
899
900
  d(i, {
900
901
  modifiers: "action-quiet",
901
902
  icon: "ri:add-line",
902
903
  "aria-label": k(c)("chatFilePreview.zoomIn"),
903
- disabled: H.value >= 2,
904
- onClick: n[5] ||= (e) => he(.1)
904
+ disabled: V.value >= 2,
905
+ onClick: n[5] ||= (e) => ge(.1)
905
906
  }, null, 8, ["aria-label", "disabled"])
906
907
  ], 64)) : D("", !0)
907
908
  ])]),
@@ -911,7 +912,7 @@ var $ = ["aria-label"], je = {
911
912
  ref: w,
912
913
  class: "pk-word-preview__measure",
913
914
  "aria-hidden": "true",
914
- style: l(se.value)
915
+ style: l(le.value)
915
916
  }, [(M(!0), j(_, null, p(g.value, (t) => (M(), j("div", {
916
917
  key: t.key,
917
918
  "data-item": ""
@@ -919,7 +920,7 @@ var $ = ["aria-label"], je = {
919
920
  block: e.preview.blocks[t.block],
920
921
  row: t.row,
921
922
  mode: e.mode,
922
- page: R.value
923
+ page: I.value
923
924
  }, null, 8, [
924
925
  "block",
925
926
  "row",
@@ -928,12 +929,12 @@ var $ = ["aria-label"], je = {
928
929
  ])]))), 128)), (M(!0), j(_, null, p(e.preview.parts, (t, n) => (M(), j("div", {
929
930
  key: n,
930
931
  "data-part": n
931
- }, [(M(!0), j(_, null, p(k(N)(t, e.mode), (n) => (M(), h(Q, {
932
+ }, [(M(!0), j(_, null, p(k(P)(t, e.mode), (n) => (M(), h(Q, {
932
933
  key: n.key,
933
934
  block: t[n.block],
934
935
  row: n.row,
935
936
  mode: e.mode,
936
- page: R.value
937
+ page: I.value
937
938
  }, null, 8, [
938
939
  "block",
939
940
  "row",
@@ -943,7 +944,7 @@ var $ = ["aria-label"], je = {
943
944
  ], 2);
944
945
  };
945
946
  }
946
- }), [["styles", [".pk-word-preview{flex:1;min-height:0;display:flex;position:relative}.pk-word-preview__side{gap:var(--spacing-12);width:16.5rem;padding:var(--spacing-12);box-sizing:border-box;border-right:var(--border) solid var(--color-surface-3);background-color:var(--color-surface);flex-direction:column;flex-shrink:0;display:flex;overflow-y:auto}.pk-word-preview__side--over{inset:0 auto var(--spacing-40) 0;z-index:3;box-shadow:var(--shadow-lg);position:absolute}.pk-word-preview__tabs{border-bottom:var(--border) solid var(--color-surface-3);display:flex}.pk-word-preview__tab{min-height:var(--spacing-40);color:var(--color-word-3);font:inherit;font-size:var(--text-14);cursor:pointer;background:0 0;border:0;flex:1}.pk-word-preview__tab[aria-selected=true]{box-shadow:inset 0 calc(var(--spacing-2) * -1) 0 var(--color-word-1);color:var(--color-word-1);font-weight:var(--font-semibold)}.pk-word-preview__list{border:var(--border) solid var(--color-surface-3);border-radius:var(--rounded-lg);flex-direction:column;display:flex;overflow:hidden}.pk-word-preview__entry{align-items:center;gap:var(--spacing-8);min-height:var(--spacing-40);padding:var(--spacing-8) var(--spacing-12);border:0;border-bottom:var(--border) solid var(--color-surface-2);color:var(--color-word-2);font:inherit;font-size:var(--text-14);text-align:start;cursor:pointer;transition:background-color var(--duration-150) var(--ease-out);background:0 0;display:flex}.pk-word-preview__entry:last-child{border-bottom:0}.pk-word-preview__entry:hover{background-color:var(--color-surface-1)}.pk-word-preview__entry[aria-current=location]{background-color:var(--color-surface-2);box-shadow:inset var(--spacing-3) 0 0 var(--color-word-2);color:var(--color-word-1);font-weight:var(--font-medium)}.pk-word-preview__entry--0{font-weight:var(--font-semibold)}.pk-word-preview__entry--2{padding-left:var(--spacing-24)}.pk-word-preview__entry--3{padding-left:var(--spacing-36)}.pk-word-preview__entry--change{gap:var(--spacing-4) var(--spacing-8);font-size:var(--text-12);flex-wrap:wrap}.pk-word-preview__entry-text{flex:1;min-width:0}.pk-word-preview__none{padding:var(--spacing-md);color:var(--color-word-3);font-size:var(--text-12);text-align:center;margin:0}.pk-word-preview__main{flex-direction:column;flex:1;min-width:0;display:flex}.pk-word-preview__scroll{min-height:0;padding:var(--spacing-md);background-color:var(--color-surface-2);flex:1;overflow:auto}.pk-word-preview__pages{align-items:center;gap:var(--spacing-24);flex-direction:column;width:max-content;min-width:100%;display:flex}.pk-word-preview__page{isolation:isolate;box-sizing:border-box;line-height:var(--pk-word-line,1.17);overflow-wrap:break-word;background-color:#fff;position:relative;overflow:hidden;box-shadow:0 1px 3px #140e3329,0 10px 28px #140e3314}.pk-word-preview__page--flow{width:100%;padding:var(--spacing-24) var(--spacing-20)}.pk-word-preview__measure{visibility:hidden;pointer-events:none;line-height:var(--pk-word-line,1.17);overflow-wrap:break-word;position:absolute;top:0;left:-100000px}.pk-word-preview__block{white-space:pre-wrap;margin:0;display:flow-root;position:relative}.pk-word-preview__picture{vertical-align:baseline;max-width:100%;height:auto}.pk-word-preview__picture--paragraph{max-width:none}.pk-word-preview__float{max-width:none;position:absolute}.pk-word-preview__part{pointer-events:none;position:absolute;inset:0}.pk-word-preview__part-flow{pointer-events:auto;position:absolute}.pk-word-preview__label{text-indent:0;display:inline-block}.pk-word-preview__changed:before{content:\"\";background-color:#3f3c51;width:1.5pt;position:absolute;top:0;bottom:0;left:-14pt}.pk-word-preview__table{border-collapse:collapse;table-layout:fixed;width:100%;margin:0;position:relative}.pk-word-preview__table td{vertical-align:top;white-space:pre-wrap;overflow-wrap:anywhere;padding:0 5.4pt}.pk-word-preview__table--lines td{border:.5pt solid #000}.pk-word-preview__table--lines.pk-word-preview__table--next td{border-top:0}.pk-word-preview__removed{color:var(--u-danger-text,#c42b3c);text-decoration:line-through}.pk-word-preview__added{color:var(--u-success-text,#178230);text-underline-offset:.2em;text-decoration:underline}.pk-word-preview__page .pk-word-preview__removed{color:#c42b3c}.pk-word-preview__page .pk-word-preview__added{color:#178230}.pk-word-preview__removed+.pk-word-preview__added{margin-inline-start:.15em}.pk-word-preview__image{padding:var(--spacing-2) var(--spacing-8);border:var(--border) dashed #c9c8d2;border-radius:var(--rounded);color:#6b6880;text-indent:0;font-size:9pt;display:inline-block}.pk-word-preview__truncated{margin:var(--spacing-md) 0 0;color:var(--color-word-3);font-size:var(--text-12);text-align:center}.pk-word-preview__status{align-items:center;gap:var(--spacing-16);min-height:var(--spacing-40);padding:0 var(--spacing-8) 0 var(--spacing-12);border-top:var(--border) solid var(--color-surface-3);background-color:var(--color-surface-1);color:var(--color-word-2);font-size:var(--text-12);white-space:nowrap;display:flex}.pk-word-preview__status>*{flex-shrink:0}.pk-word-preview__count{font-variant-numeric:tabular-nums}.pk-word-preview__status>.pk-word-preview__legend{gap:var(--spacing-8);flex-shrink:1;min-width:0;display:flex}.pk-word-preview__legend-text{text-overflow:ellipsis;min-width:0;overflow:hidden}.pk-word-preview__legend>.pk-word-preview__removed,.pk-word-preview__legend>.pk-word-preview__added{flex-shrink:0}.pk-word-preview__spacer{flex:1}@container (width<30rem){.pk-word-preview__outline-toggle .vv-button__label{display:none}}.pk-word-preview__percent{min-width:var(--spacing-40);font-variant-numeric:tabular-nums;text-align:center}"]]]);
947
+ }), [["styles", [".pk-word-preview{flex:1;min-height:0;display:flex;position:relative}.pk-word-preview__side{gap:var(--spacing-12);width:16.5rem;padding:var(--spacing-12);box-sizing:border-box;border-right:var(--border) solid var(--color-surface-3);background-color:var(--color-surface);flex-direction:column;flex-shrink:0;display:flex;overflow-y:auto}.pk-word-preview__side--over{inset:0 auto var(--spacing-40) 0;z-index:3;box-shadow:var(--shadow-lg);position:absolute}.pk-word-preview__tabs{border-bottom:var(--border) solid var(--color-surface-3);display:flex}.pk-word-preview__tab{min-height:var(--spacing-40);color:var(--color-word-3);font:inherit;font-size:var(--text-14);cursor:pointer;background:0 0;border:0;flex:1}.pk-word-preview__tab[aria-selected=true]{box-shadow:inset 0 calc(var(--spacing-2) * -1) 0 var(--color-word-1);color:var(--color-word-1);font-weight:var(--font-semibold)}.pk-word-preview__list{border:var(--border) solid var(--color-surface-3);border-radius:var(--rounded-lg);flex-direction:column;flex-shrink:0;display:flex;overflow:hidden}.pk-word-preview__entry{align-items:center;gap:var(--spacing-8);min-height:var(--spacing-40);padding:var(--spacing-8) var(--spacing-12);border:0;border-bottom:var(--border) solid var(--color-surface-2);color:var(--color-word-2);font:inherit;font-size:var(--text-14);text-align:start;cursor:pointer;transition:background-color var(--duration-150) var(--ease-out);background:0 0;display:flex}.pk-word-preview__entry:last-child{border-bottom:0}.pk-word-preview__entry:hover{background-color:var(--color-surface-1)}.pk-word-preview__entry[aria-current=location]{background-color:var(--color-surface-2);box-shadow:inset var(--spacing-3) 0 0 var(--color-word-2);color:var(--color-word-1);font-weight:var(--font-medium)}.pk-word-preview__entry--0{font-weight:var(--font-semibold)}.pk-word-preview__entry--2{padding-left:var(--spacing-24)}.pk-word-preview__entry--3{padding-left:var(--spacing-36)}.pk-word-preview__entry--change{gap:var(--spacing-4) var(--spacing-8);font-size:var(--text-12);flex-wrap:wrap}.pk-word-preview__entry-text{flex:1;min-width:0}.pk-word-preview__none{padding:var(--spacing-md);color:var(--color-word-3);font-size:var(--text-12);text-align:center;margin:0}.pk-word-preview__main{flex-direction:column;flex:1;min-width:0;display:flex}.pk-word-preview__scroll{min-height:0;padding:var(--spacing-md);background-color:var(--color-surface-2);flex:1;overflow:auto}.pk-word-preview__pages{align-items:center;gap:var(--spacing-24);flex-direction:column;width:max-content;min-width:100%;display:flex}.pk-word-preview__page{isolation:isolate;box-sizing:border-box;line-height:var(--pk-word-line,1.17);overflow-wrap:break-word;background-color:#fff;position:relative;overflow:hidden;box-shadow:0 1px 3px #140e3329,0 10px 28px #140e3314}.pk-word-preview__page--flow{width:100%;padding:var(--spacing-24) var(--spacing-20)}.pk-word-preview__measure{visibility:hidden;pointer-events:none;height:0;line-height:var(--pk-word-line,1.17);overflow-wrap:break-word;position:absolute;top:0;left:-100000px;overflow:hidden}.pk-word-preview__block{white-space:pre-wrap;margin:0;display:flow-root;position:relative}.pk-word-preview__picture{vertical-align:baseline;max-width:100%;height:auto}.pk-word-preview__picture--paragraph{max-width:none}.pk-word-preview__float{max-width:none;position:absolute}.pk-word-preview__part{pointer-events:none;position:absolute;inset:0}.pk-word-preview__part-flow{pointer-events:auto;position:absolute}.pk-word-preview__label{text-indent:0;display:inline-block}.pk-word-preview__changed:before{content:\"\";background-color:#3f3c51;width:1.5pt;position:absolute;top:0;bottom:0;left:-14pt}.pk-word-preview__table{border-collapse:collapse;table-layout:fixed;width:100%;margin:0;position:relative}.pk-word-preview__table td{vertical-align:top;white-space:pre-wrap;overflow-wrap:anywhere;padding:0 5.4pt}.pk-word-preview__table--lines td{border:.5pt solid #000}.pk-word-preview__table--lines.pk-word-preview__table--next td{border-top:0}.pk-word-preview__removed{color:var(--u-danger-text,#c42b3c);text-decoration:line-through}.pk-word-preview__added{color:var(--u-success-text,#178230);text-underline-offset:.2em;text-decoration:underline}.pk-word-preview__page .pk-word-preview__removed{color:#c42b3c}.pk-word-preview__page .pk-word-preview__added{color:#178230}.pk-word-preview__removed+.pk-word-preview__added{margin-inline-start:.15em}.pk-word-preview__image{padding:var(--spacing-2) var(--spacing-8);border:var(--border) dashed #c9c8d2;border-radius:var(--rounded);color:#6b6880;text-indent:0;font-size:9pt;display:inline-block}.pk-word-preview__truncated{margin:var(--spacing-md) 0 0;color:var(--color-word-3);font-size:var(--text-12);text-align:center}.pk-word-preview__status{align-items:center;gap:var(--spacing-16);min-height:var(--spacing-40);padding:0 var(--spacing-8) 0 var(--spacing-12);border-top:var(--border) solid var(--color-surface-3);background-color:var(--color-surface-1);color:var(--color-word-2);font-size:var(--text-12);white-space:nowrap;display:flex}.pk-word-preview__status>*{flex-shrink:0}.pk-word-preview__count{font-variant-numeric:tabular-nums}.pk-word-preview__status>.pk-word-preview__legend{gap:var(--spacing-8);flex-shrink:1;min-width:0;display:flex}.pk-word-preview__legend-text{text-overflow:ellipsis;min-width:0;overflow:hidden}.pk-word-preview__legend>.pk-word-preview__removed,.pk-word-preview__legend>.pk-word-preview__added{flex-shrink:0}.pk-word-preview__spacer{flex:1}@container (width<30rem){.pk-word-preview__outline-toggle .vv-button__label{display:none}}.pk-word-preview__percent{min-width:var(--spacing-40);font-variant-numeric:tabular-nums;text-align:center}"]]]);
947
948
  // ../../packages/components/src/chat/PkFilePreview.vue?vue&type=script&setup=true&lang.ts
948
949
  S(), f(), w();
949
950
  var it = ["aria-label"], at = { class: "pk-file-preview__head" }, ot = { class: "pk-file-preview__file" }, st = {
@@ -1013,7 +1014,7 @@ var it = ["aria-label"], at = { class: "pk-file-preview__head" }, ot = { class:
1013
1014
  return u(() => n.version, () => {
1014
1015
  m.value = "markup";
1015
1016
  }), (t, n) => {
1016
- let o = R, c = oe;
1017
+ let o = I, c = ce;
1017
1018
  return M(), j("section", {
1018
1019
  class: "pk-file-preview",
1019
1020
  "aria-label": e.filename,
@@ -1047,7 +1048,7 @@ var it = ["aria-label"], at = { class: "pk-file-preview__head" }, ot = { class:
1047
1048
  disabled: !f.value,
1048
1049
  onClick: n[1] ||= (e) => f.value && i("version", f.value)
1049
1050
  }, null, 8, ["aria-label", "disabled"])
1050
- ], 8, ft)) : D("", !0), w.value ? (M(), h(se, {
1051
+ ], 8, ft)) : D("", !0), w.value ? (M(), h(le, {
1051
1052
  key: 1,
1052
1053
  modelValue: m.value,
1053
1054
  "onUpdate:modelValue": n[2] ||= (e) => m.value = e,
@@ -1123,7 +1124,7 @@ var it = ["aria-label"], at = { class: "pk-file-preview__head" }, ot = { class:
1123
1124
  "fit",
1124
1125
  "preview",
1125
1126
  "mode"
1126
- ])) : (M(), h(q, {
1127
+ ])) : (M(), h(K, {
1127
1128
  key: 3,
1128
1129
  sheet: g.value,
1129
1130
  "onUpdate:sheet": n[9] ||= (e) => g.value = e,
@@ -1137,7 +1138,7 @@ var it = ["aria-label"], at = { class: "pk-file-preview__head" }, ot = { class:
1137
1138
  ]))])], 8, it);
1138
1139
  };
1139
1140
  }
1140
- }), xt = ".pk-file-preview{background-color:var(--color-surface);height:100%;min-height:0;color:var(--color-word-1);outline:none;flex-direction:column;display:flex;container-type:inline-size}.pk-file-preview__head{align-items:center;gap:var(--spacing-8) var(--spacing-12);padding:var(--spacing-12) var(--spacing-12) var(--spacing-12) var(--spacing-md);border-bottom:var(--border) solid var(--color-surface-3);flex-wrap:wrap;display:flex}.pk-file-preview__file{align-items:center;gap:var(--spacing-12);flex:12rem;min-width:0;display:flex}.pk-file-preview__tile{width:var(--spacing-32);height:var(--spacing-32);border:var(--border) solid var(--color-surface-3);border-radius:var(--rounded);flex-shrink:0;justify-content:center;align-items:center;display:flex}.pk-file-preview__tile .vv-icon{width:var(--spacing-18);height:var(--spacing-18)}.pk-file-preview__icon--word{color:#2b7de9}.pk-file-preview__icon--sheet{color:#1f9d57}.pk-file-preview__name{flex-direction:column;min-width:0;display:flex}.pk-file-preview__title{font-size:var(--text-14);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.pk-file-preview__note{color:var(--color-word-3);font-size:var(--text-12)}.pk-file-preview__tools{align-items:center;gap:var(--spacing-8) var(--spacing-12);flex-wrap:wrap;display:flex}.pk-file-preview__versions{align-items:center;gap:var(--spacing-2);display:flex}.pk-file-preview__version{font-size:var(--text-14);font-weight:var(--font-semibold);font-variant-numeric:tabular-nums;white-space:nowrap}.pk-file-preview__actions{align-items:center;gap:var(--spacing-8);margin-left:auto;display:flex}@container (width<52rem){.pk-file-preview__file{order:1}.pk-file-preview__actions{order:2}.pk-file-preview__tools{flex-basis:100%;order:3}.pk-file-preview__tools .pk-file-preview__modes{flex:auto}}.pk-file-preview__mode-short{display:none}@container (width<38rem){.pk-file-preview__mode-long{display:none}.pk-file-preview__mode-short{display:inline}}@container (width<30rem){.pk-file-preview__tools .pk-file-preview__modes{flex:100%}.pk-file-preview__tools .pk-file-preview__modes .vv-radio{padding-inline:var(--spacing-4)}}.pk-file-preview__body{background-color:var(--color-surface-1);flex-direction:column;flex:1;min-height:0;display:flex}.pk-file-preview__skeleton{width:min(42rem, 100% - 2 * var(--spacing-md));margin:var(--spacing-md) auto;padding:var(--spacing-lg);box-sizing:border-box;border:var(--border) solid var(--color-surface-3);border-radius:var(--rounded);background-color:var(--color-surface)}.pk-file-preview__skeleton-line{height:var(--spacing-12);margin-bottom:var(--spacing-12);border-radius:var(--rounded)}.pk-file-preview__empty{margin:var(--spacing-lg) var(--spacing-md);color:var(--color-word-3);font-size:var(--text-14);text-align:center}", St = /* @__PURE__ */ e({ default: () => Ct }), Ct = /*#__PURE__*/ z(bt, [["styles", [xt]]]);
1141
+ }), xt = ".pk-file-preview{background-color:var(--color-surface);height:100%;min-height:0;color:var(--color-word-1);outline:none;flex-direction:column;display:flex;container-type:inline-size}.pk-file-preview__head{align-items:center;gap:var(--spacing-8) var(--spacing-12);padding:var(--spacing-12) var(--spacing-12) var(--spacing-12) var(--spacing-md);border-bottom:var(--border) solid var(--color-surface-3);flex-wrap:wrap;display:flex}.pk-file-preview__file{align-items:center;gap:var(--spacing-12);flex:12rem;min-width:0;display:flex}.pk-file-preview__tile{width:var(--spacing-32);height:var(--spacing-32);border:var(--border) solid var(--color-surface-3);border-radius:var(--rounded);flex-shrink:0;justify-content:center;align-items:center;display:flex}.pk-file-preview__tile .vv-icon{width:var(--spacing-18);height:var(--spacing-18)}.pk-file-preview__icon--word{color:#2b7de9}.pk-file-preview__icon--sheet{color:#1f9d57}.pk-file-preview__name{flex-direction:column;min-width:0;display:flex}.pk-file-preview__title{font-size:var(--text-14);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.pk-file-preview__note{color:var(--color-word-3);font-size:var(--text-12)}.pk-file-preview__tools{align-items:center;gap:var(--spacing-8) var(--spacing-12);flex-wrap:wrap;display:flex}.pk-file-preview__versions{align-items:center;gap:var(--spacing-2);display:flex}.pk-file-preview__version{font-size:var(--text-14);font-weight:var(--font-semibold);font-variant-numeric:tabular-nums;white-space:nowrap}.pk-file-preview__actions{align-items:center;gap:var(--spacing-8);margin-left:auto;display:flex}@container (width<52rem){.pk-file-preview__file{order:1}.pk-file-preview__actions{order:2}.pk-file-preview__tools{flex-basis:100%;order:3}.pk-file-preview__tools .pk-file-preview__modes{flex:auto}}.pk-file-preview__mode-short{display:none}@container (width<38rem){.pk-file-preview__mode-long{display:none}.pk-file-preview__mode-short{display:inline}}@container (width<30rem){.pk-file-preview__tools .pk-file-preview__modes{flex:100%}.pk-file-preview__tools .pk-file-preview__modes .vv-radio{padding-inline:var(--spacing-4)}}.pk-file-preview__body{background-color:var(--color-surface-1);flex-direction:column;flex:1;min-height:0;display:flex}.pk-file-preview__skeleton{width:min(42rem, 100% - 2 * var(--spacing-md));margin:var(--spacing-md) auto;padding:var(--spacing-lg);box-sizing:border-box;border:var(--border) solid var(--color-surface-3);border-radius:var(--rounded);background-color:var(--color-surface)}.pk-file-preview__skeleton-line{height:var(--spacing-12);margin-bottom:var(--spacing-12);border-radius:var(--rounded)}.pk-file-preview__empty{margin:var(--spacing-lg) var(--spacing-md);color:var(--color-word-3);font-size:var(--text-14);text-align:center}", St = /* @__PURE__ */ e({ default: () => Ct }), Ct = /*#__PURE__*/ L(bt, [["styles", [xt]]]);
1141
1142
  export { St as n, Ct as t };
1142
1143
 
1143
- //# sourceMappingURL=PkFilePreview-DXmgMwwu.js.map
1144
+ //# sourceMappingURL=PkFilePreview-CC2W-RXG.js.map