@8wave/ai-elements 0.97.0 → 0.98.0-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. package/README.md +20 -18
  2. package/dist/_chunks/{Document-njJL_3oo.js → Document-CjCQXPDF.js} +54 -54
  3. package/dist/_chunks/{Document-njJL_3oo.js.map → Document-CjCQXPDF.js.map} +1 -1
  4. package/dist/_chunks/{PkStreamingMarkdown-Bns7j3b7.js → PkStreamingMarkdown-Djw604Ny.js} +43 -43
  5. package/dist/_chunks/PkStreamingMarkdown-Djw604Ny.js.map +1 -0
  6. package/dist/_chunks/{PkToolShowArtifact-BHGuiacA.js → PkToolShowArtifact-BaGEr7O9.js} +2 -2
  7. package/dist/_chunks/{PkToolShowArtifact-BHGuiacA.js.map → PkToolShowArtifact-BaGEr7O9.js.map} +1 -1
  8. package/dist/_chunks/{PkToolShowContactForm-Cp6fDIOT.js → PkToolShowContactForm-DEQBTzf4.js} +4 -4
  9. package/dist/_chunks/{PkToolShowContactForm-Cp6fDIOT.js.map → PkToolShowContactForm-DEQBTzf4.js.map} +1 -1
  10. package/dist/_chunks/{PkToolShowForm-BqUkMxMK.js → PkToolShowForm-AZwrmmM9.js} +2 -2
  11. package/dist/_chunks/{PkToolShowForm-BqUkMxMK.js.map → PkToolShowForm-AZwrmmM9.js.map} +1 -1
  12. package/dist/_chunks/{PkToolShowSources-Bg0QAcmF.js → PkToolShowSources-FnMkkdm6.js} +3 -3
  13. package/dist/_chunks/{PkToolShowSources-Bg0QAcmF.js.map → PkToolShowSources-FnMkkdm6.js.map} +1 -1
  14. package/dist/_chunks/{VvCheckbox.es-If2fZZst.js → VvCheckbox.es-D5d8k9yP.js} +2 -2
  15. package/dist/_chunks/{VvCheckbox.es-If2fZZst.js.map → VvCheckbox.es-D5d8k9yP.js.map} +1 -1
  16. package/dist/_chunks/{VvCheckboxGroup.es-A-IjEdQh.js → VvCheckboxGroup.es-DVnsOjX0.js} +2 -2
  17. package/dist/_chunks/{VvCheckboxGroup.es-A-IjEdQh.js.map → VvCheckboxGroup.es-DVnsOjX0.js.map} +1 -1
  18. package/dist/_chunks/{VvCombobox.es-DLRkNj0w.js → VvCombobox.es-CFA-K-cQ.js} +2 -2
  19. package/dist/_chunks/{VvCombobox.es-DLRkNj0w.js.map → VvCombobox.es-CFA-K-cQ.js.map} +1 -1
  20. package/dist/_chunks/{VvInputText.es-DV6kHrYx.js → VvInputText.es-csEQ-bSG.js} +2 -2
  21. package/dist/_chunks/{VvInputText.es-DV6kHrYx.js.map → VvInputText.es-csEQ-bSG.js.map} +1 -1
  22. package/dist/_chunks/{VvRadio.es-C_L52PYW.js → VvRadio.es-BpymhC73.js} +2 -2
  23. package/dist/_chunks/{VvRadio.es-C_L52PYW.js.map → VvRadio.es-BpymhC73.js.map} +1 -1
  24. package/dist/_chunks/{VvRadioGroup.es-B64sR46T.js → VvRadioGroup.es-CSNzOJKx.js} +2 -2
  25. package/dist/_chunks/{VvRadioGroup.es-B64sR46T.js.map → VvRadioGroup.es-CSNzOJKx.js.map} +1 -1
  26. package/dist/_chunks/{VvSelect.es-D_WR7HcC.js → VvSelect.es-CjKMd0nH.js} +2 -2
  27. package/dist/_chunks/{VvSelect.es-D_WR7HcC.js.map → VvSelect.es-CjKMd0nH.js.map} +1 -1
  28. package/dist/_chunks/{VvTextarea.es-DpF-slnp.js → VvTextarea.es-eEyRRpuT.js} +2 -2
  29. package/dist/_chunks/{VvTextarea.es-DpF-slnp.js.map → VvTextarea.es-eEyRRpuT.js.map} +1 -1
  30. package/dist/_chunks/index.es-BYny0uhz.js.map +1 -1
  31. package/dist/_chunks/{index.es-DN8D4nRq.js → index.es-eLFDkB2Y.js} +11 -11
  32. package/dist/_chunks/{index.es-DN8D4nRq.js.map → index.es-eLFDkB2Y.js.map} +1 -1
  33. package/dist/_chunks/{schemas-BsOP_5an.js → schemas-DnUKIqgi.js} +503 -503
  34. package/dist/_chunks/{schemas-BsOP_5an.js.map → schemas-DnUKIqgi.js.map} +1 -1
  35. package/dist/ai-elements.es.js +3836 -3743
  36. package/dist/ai-elements.es.js.map +1 -1
  37. package/dist-vue/PkChatbot.js +1 -1
  38. package/dist-vue/PkChatbotAuth.js +1 -1
  39. package/dist-vue/PkChatbotEmptyState.js +1 -1
  40. package/dist-vue/PkChatbotFeedbackForm.js +1 -1
  41. package/dist-vue/PkChatbotInput.js +1 -1
  42. package/dist-vue/PkChatbotMessages.js +1 -1
  43. package/dist-vue/PkChatbotSteps.js +1 -1
  44. package/dist-vue/PkChatbotViewChat.js +1 -1
  45. package/dist-vue/PkChatbotViewConversations.js +1 -1
  46. package/dist-vue/PkChatbotViewFiles.js +1 -1
  47. package/dist-vue/PkChatbotViewProfile.js +1 -1
  48. package/dist-vue/_chunks/{Document-q67u4D3u.js → Document-B8gv0e2O.js} +15 -15
  49. package/dist-vue/_chunks/{Document-q67u4D3u.js.map → Document-B8gv0e2O.js.map} +1 -1
  50. package/dist-vue/_chunks/{Media-BmW9F_3T.js → Media-B_7Yj-ml.js} +26 -26
  51. package/dist-vue/_chunks/{Media-BmW9F_3T.js.map → Media-B_7Yj-ml.js.map} +1 -1
  52. package/dist-vue/_chunks/{PkChatbot-A1jKttsQ.js → PkChatbot-CneS8fVC.js} +7 -7
  53. package/dist-vue/_chunks/{PkChatbot-A1jKttsQ.js.map → PkChatbot-CneS8fVC.js.map} +1 -1
  54. package/dist-vue/_chunks/{PkChatbotAuth-C0ATmt-9.js → PkChatbotAuth-C_L2xWuD.js} +4 -4
  55. package/dist-vue/_chunks/{PkChatbotAuth-C0ATmt-9.js.map → PkChatbotAuth-C_L2xWuD.js.map} +1 -1
  56. package/dist-vue/_chunks/{PkChatbotEmptyState-BGTSWFSS.js → PkChatbotEmptyState-BGOC6vxr.js} +2 -2
  57. package/dist-vue/_chunks/{PkChatbotEmptyState-BGTSWFSS.js.map → PkChatbotEmptyState-BGOC6vxr.js.map} +1 -1
  58. package/dist-vue/_chunks/{PkChatbotFeedbackForm-Dhsa1c06.js → PkChatbotFeedbackForm-BSe40qlc.js} +3 -3
  59. package/dist-vue/_chunks/{PkChatbotFeedbackForm-Dhsa1c06.js.map → PkChatbotFeedbackForm-BSe40qlc.js.map} +1 -1
  60. package/dist-vue/_chunks/{PkChatbotInput-Be3J_Fgz.js → PkChatbotInput-DTazYlPd.js} +2 -2
  61. package/dist-vue/_chunks/{PkChatbotInput-Be3J_Fgz.js.map → PkChatbotInput-DTazYlPd.js.map} +1 -1
  62. package/dist-vue/_chunks/{PkChatbotMessages-Cbn8okze.js → PkChatbotMessages-DEzcxcqc.js} +9 -9
  63. package/dist-vue/_chunks/{PkChatbotMessages-Cbn8okze.js.map → PkChatbotMessages-DEzcxcqc.js.map} +1 -1
  64. package/dist-vue/_chunks/{PkChatbotSteps-BhqYCNWy.js → PkChatbotSteps-BpqdFhsG.js} +2 -2
  65. package/dist-vue/_chunks/{PkChatbotSteps-BhqYCNWy.js.map → PkChatbotSteps-BpqdFhsG.js.map} +1 -1
  66. package/dist-vue/_chunks/{PkChatbotViewChat-Cc8bZfAr.js → PkChatbotViewChat-C7Xv2Oer.js} +6 -6
  67. package/dist-vue/_chunks/{PkChatbotViewChat-Cc8bZfAr.js.map → PkChatbotViewChat-C7Xv2Oer.js.map} +1 -1
  68. package/dist-vue/_chunks/{PkChatbotViewConversations-BsfA4A7O.js → PkChatbotViewConversations-YbHHc8oD.js} +2 -2
  69. package/dist-vue/_chunks/{PkChatbotViewConversations-BsfA4A7O.js.map → PkChatbotViewConversations-YbHHc8oD.js.map} +1 -1
  70. package/dist-vue/_chunks/{PkChatbotViewFiles-C6aouWQh.js → PkChatbotViewFiles-BPE0g2Jk.js} +3 -3
  71. package/dist-vue/_chunks/{PkChatbotViewFiles-C6aouWQh.js.map → PkChatbotViewFiles-BPE0g2Jk.js.map} +1 -1
  72. package/dist-vue/_chunks/{PkChatbotViewProfile-B_ZAXIrC.js → PkChatbotViewProfile-B_gWPgVY.js} +2 -2
  73. package/dist-vue/_chunks/{PkChatbotViewProfile-B_ZAXIrC.js.map → PkChatbotViewProfile-B_gWPgVY.js.map} +1 -1
  74. package/dist-vue/_chunks/{PkStreamingMarkdown-CNLdk20r.js → PkStreamingMarkdown-DEhbK-3c.js} +43 -43
  75. package/dist-vue/_chunks/PkStreamingMarkdown-DEhbK-3c.js.map +1 -0
  76. package/dist-vue/_chunks/{PkToolShowArtifact-B2ilUNT0.js → PkToolShowArtifact-CTBwt4DN.js} +2 -2
  77. package/dist-vue/_chunks/{PkToolShowArtifact-B2ilUNT0.js.map → PkToolShowArtifact-CTBwt4DN.js.map} +1 -1
  78. package/dist-vue/_chunks/{PkToolShowContactForm-C3CXe6sh.js → PkToolShowContactForm-B6-MsExL.js} +4 -4
  79. package/dist-vue/_chunks/{PkToolShowContactForm-C3CXe6sh.js.map → PkToolShowContactForm-B6-MsExL.js.map} +1 -1
  80. package/dist-vue/_chunks/{PkToolShowForm-DnzUxm2o.js → PkToolShowForm-C-mWyeka.js} +2 -2
  81. package/dist-vue/_chunks/{PkToolShowForm-DnzUxm2o.js.map → PkToolShowForm-C-mWyeka.js.map} +1 -1
  82. package/dist-vue/_chunks/{PkToolShowSources-BF2-VGSg.js → PkToolShowSources-rGZz65c2.js} +3 -3
  83. package/dist-vue/_chunks/{PkToolShowSources-BF2-VGSg.js.map → PkToolShowSources-rGZz65c2.js.map} +1 -1
  84. package/dist-vue/_chunks/{constants-DtnBK4PW.js → constants-BSe0uxSf.js} +4 -4
  85. package/dist-vue/_chunks/{constants-DtnBK4PW.js.map → constants-BSe0uxSf.js.map} +1 -1
  86. package/dist-vue/_chunks/{createChatbotApiClient-BHfNaVk8.js → createChatbotApiClient-Bf5DbqVH.js} +125 -113
  87. package/dist-vue/_chunks/createChatbotApiClient-Bf5DbqVH.js.map +1 -0
  88. package/dist-vue/_chunks/{index.es-BODtrBxv.js → index.es-XfWQ82pb.js} +3 -3
  89. package/dist-vue/_chunks/{index.es-BODtrBxv.js.map → index.es-XfWQ82pb.js.map} +1 -1
  90. package/dist-vue/_chunks/{schemas-BsOP_5an.js → schemas-DnUKIqgi.js} +503 -503
  91. package/dist-vue/_chunks/{schemas-BsOP_5an.js.map → schemas-DnUKIqgi.js.map} +1 -1
  92. package/dist-vue/_chunks/{useChatbotStore-bbenzuMe.js → useChatbotStore-Cfx-qlC4.js} +778 -761
  93. package/dist-vue/_chunks/useChatbotStore-Cfx-qlC4.js.map +1 -0
  94. package/dist-vue/api.js +1 -1
  95. package/dist-vue/apps/web-component/src/components/EmbeddedChatWidget.ce.d.ts +6 -0
  96. package/dist-vue/apps/web-component/src/components/FloatingChatWidget.ce.d.ts +6 -0
  97. package/dist-vue/apps/web-component/src/composables/useChatbotAgent.d.ts +6 -0
  98. package/dist-vue/apps/web-component/src/lib.d.ts +2 -0
  99. package/dist-vue/composables.js +5 -3
  100. package/dist-vue/composables.js.map +1 -1
  101. package/dist-vue/index.js +23 -23
  102. package/dist-vue/packages/components/src/chat/PkChatbotMessages.d.ts +134 -3
  103. package/dist-vue/packages/components/src/chat/PkMessageParts.d.ts +134 -3
  104. package/dist-vue/packages/composable/src/chatbot/api/index.d.ts +1 -0
  105. package/dist-vue/packages/composable/src/chatbot/api/resolveShortUrls.d.ts +16 -0
  106. package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +24 -24
  107. package/dist-vue/packages/models/src/schema/McpServer.d.ts +4 -0
  108. package/package.json +3 -3
  109. package/dist/_chunks/PkStreamingMarkdown-Bns7j3b7.js.map +0 -1
  110. package/dist-vue/_chunks/PkStreamingMarkdown-CNLdk20r.js.map +0 -1
  111. package/dist-vue/_chunks/createChatbotApiClient-BHfNaVk8.js.map +0 -1
  112. package/dist-vue/_chunks/useChatbotStore-bbenzuMe.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"PkChatbotViewFiles-C6aouWQh.js","names":[],"sources":["../../../../packages/composable/src/useFileRow.ts","../../../../packages/components/src/chat/PkChatbotViewFiles.vue","../../../../packages/components/src/chat/PkChatbotViewFiles.vue"],"sourcesContent":["import { reactive } from 'vue'\nimport { useI18n } from 'vue-i18n'\nimport { isImageMime, isInlineViewable } from 'models'\n\n/** Minimal shape a file-list row needs for the shared display helpers. */\nexport interface FileRowLike {\n documentId: string\n mimeType: string | null\n}\n\n/**\n * Shared display logic for the user-files list rows, used by both the in-app\n * table (PjUserFilesTable) and the embedded widget (PkChatbotViewFiles). The two\n * surfaces differ only in how they build URLs (authenticated store vs widget API\n * client), so the URL builders are injected.\n *\n * - `view(id, inline)` → opens/downloads the original file.\n * - `preview(id)` → small resized blob for the row thumbnail.\n */\nexport function useFileRow(urls: {\n view: (documentId: string, inline: boolean) => string\n preview: (documentId: string) => string\n}) {\n const { locale } = useI18n({ useScope: 'global' })\n\n // Image rows show a thumbnail; if it fails to load (auth/redirect, or the\n // preview isn't generated yet) we fall back to the file-type icon.\n const thumbError = reactive(new Set<string>())\n const showThumb = (file: FileRowLike): boolean =>\n isImageMime(file.mimeType) && !thumbError.has(file.documentId)\n const thumbUrl = (file: FileRowLike): string =>\n urls.preview(file.documentId)\n const onThumbError = (file: FileRowLike): void => {\n thumbError.add(file.documentId)\n }\n\n // Name click previews images/PDF inline; an explicit download forces an\n // attachment (inline=false → download SAS).\n const openFile = (file: FileRowLike, download = false): void => {\n const inline = !download && isInlineViewable(file.mimeType)\n window.open(urls.view(file.documentId, inline), '_blank', 'noopener')\n }\n\n const formatDate = (iso: string): string =>\n new Date(iso).toLocaleDateString(locale.value, {\n year: 'numeric',\n month: 'short',\n day: 'numeric',\n })\n\n return { showThumb, thumbUrl, onThumbError, openFile, formatDate }\n}\n","<script setup lang=\"ts\">\n import { ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { fileIconForMime } from 'models'\n import {\n useChatbotStore,\n useDialogConfirm,\n useFileRow,\n type ChatbotFile,\n } from 'composables'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n const { openDialogConfirm } = useDialogConfirm()\n\n const store = useChatbotStore(props.agentId)\n const { chatFiles, isLoadingChatFiles } = storeToRefs(store)\n const { showThumb, thumbUrl, onThumbError, openFile, formatDate } =\n useFileRow({\n view: store.getChatFileUrl,\n preview: store.getChatFilePreviewUrl,\n })\n\n const deletingId = ref<string | null>(null)\n\n const handleExclude = async (file: ChatbotFile) => {\n const proceed = await openDialogConfirm({\n title: $t('userFiles.excludeTitle'),\n questionLabel: $t('userFiles.excludeConfirm'),\n })\n if (!proceed) {\n return\n }\n deletingId.value = file.documentId\n try {\n await store.deleteChatFile(file.documentId)\n } catch {\n // surfaced by the host's error handling\n } finally {\n deletingId.value = null\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 relative\">\n <!-- Loading skeleton -->\n <div\n v-if=\"isLoadingChatFiles && chatFiles.length === 0\"\n class=\"flex flex-col gap-8 p-16 vv-skeleton\">\n <div\n v-for=\"i in 4\"\n :key=\"i\"\n class=\"vv-skeleton__item rounded-md h-56\" />\n </div>\n\n <!-- Empty state -->\n <div\n v-else-if=\"chatFiles.length === 0\"\n class=\"flex flex-col flex-1 items-center justify-center gap-12 p-24 text-center\">\n <div\n class=\"w-64 h-64 rounded-full bg-surface-1 border border-surface-3 flex items-center justify-center\">\n <VvIcon\n name=\"ri:folder-open-line\"\n class=\"w-28 h-28 text-word-4\" />\n </div>\n <span class=\"text-14 text-word-3 leading-relaxed\">\n {{ $t('userFiles.chatFilesEmpty') }}\n </span>\n </div>\n\n <!-- File list -->\n <ul v-else class=\"pk-chatbot-files\">\n <li\n v-for=\"file in chatFiles\"\n :key=\"file.documentId\"\n class=\"pk-chatbot-files__item\">\n <span class=\"pk-chatbot-files__icon\">\n <img\n v-if=\"showThumb(file)\"\n :src=\"thumbUrl(file)\"\n loading=\"lazy\"\n decoding=\"async\"\n alt=\"\"\n class=\"pk-chatbot-files__thumb\"\n @error=\"onThumbError(file)\" />\n <VvIcon v-else :name=\"fileIconForMime(file.mimeType)\" />\n </span>\n <button\n type=\"button\"\n class=\"pk-chatbot-files__main\"\n :title=\"$t('userFiles.open')\"\n @click=\"openFile(file)\">\n <span class=\"pk-chatbot-files__name\">\n {{ file.name || $t('userFiles.untitled') }}\n </span>\n <span class=\"pk-chatbot-files__date\">\n {{ formatDate(file.createdAt) }}\n </span>\n </button>\n <div class=\"pk-chatbot-files__actions\">\n <VvButton\n modifiers=\"action-quiet xs\"\n icon=\"ri:download-line\"\n :title=\"$t('action.download')\"\n @click=\"openFile(file, true)\" />\n <VvButton\n modifiers=\"action-quiet-danger xs\"\n icon=\"ri:delete-bin-line\"\n :title=\"$t('userFiles.exclude')\"\n :loading=\"deletingId === file.documentId\"\n :disabled=\"deletingId === file.documentId\"\n @click=\"handleExclude(file)\" />\n </div>\n </li>\n </ul>\n </div>\n</template>\n\n<style lang=\"scss\">\n .pk-chatbot-files {\n display: flex;\n flex-direction: column;\n list-style: none;\n margin: 0;\n padding: var(--spacing-8);\n overflow-y: auto;\n\n &__item {\n display: flex;\n align-items: center;\n gap: var(--spacing-10);\n padding: var(--spacing-8) var(--spacing-10);\n border-radius: var(--rounded-md);\n transition: var(--transition-colors);\n\n // Separator between files\n & + & {\n border-top: 1px solid var(--color-surface-3);\n }\n\n &:hover {\n background-color: var(--color-surface-2);\n }\n }\n\n &__icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: var(--spacing-36);\n height: var(--spacing-36);\n flex-shrink: 0;\n border-radius: var(--rounded-md);\n background-color: var(--color-surface-1);\n color: var(--color-word-3);\n overflow: hidden;\n }\n\n &__thumb {\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n &__main {\n display: flex;\n flex-direction: column;\n min-width: 0;\n flex: 1;\n text-align: left;\n background: none;\n border: 0;\n padding: 0;\n cursor: pointer;\n }\n\n &__name {\n font-size: var(--text-14);\n color: var(--color-word-1);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n &__date {\n font-size: var(--text-12);\n color: var(--color-word-3);\n }\n\n &__actions {\n display: flex;\n align-items: center;\n gap: var(--spacing-2);\n flex-shrink: 0;\n }\n }\n</style>\n","<script setup lang=\"ts\">\n import { ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { fileIconForMime } from 'models'\n import {\n useChatbotStore,\n useDialogConfirm,\n useFileRow,\n type ChatbotFile,\n } from 'composables'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n const { openDialogConfirm } = useDialogConfirm()\n\n const store = useChatbotStore(props.agentId)\n const { chatFiles, isLoadingChatFiles } = storeToRefs(store)\n const { showThumb, thumbUrl, onThumbError, openFile, formatDate } =\n useFileRow({\n view: store.getChatFileUrl,\n preview: store.getChatFilePreviewUrl,\n })\n\n const deletingId = ref<string | null>(null)\n\n const handleExclude = async (file: ChatbotFile) => {\n const proceed = await openDialogConfirm({\n title: $t('userFiles.excludeTitle'),\n questionLabel: $t('userFiles.excludeConfirm'),\n })\n if (!proceed) {\n return\n }\n deletingId.value = file.documentId\n try {\n await store.deleteChatFile(file.documentId)\n } catch {\n // surfaced by the host's error handling\n } finally {\n deletingId.value = null\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 relative\">\n <!-- Loading skeleton -->\n <div\n v-if=\"isLoadingChatFiles && chatFiles.length === 0\"\n class=\"flex flex-col gap-8 p-16 vv-skeleton\">\n <div\n v-for=\"i in 4\"\n :key=\"i\"\n class=\"vv-skeleton__item rounded-md h-56\" />\n </div>\n\n <!-- Empty state -->\n <div\n v-else-if=\"chatFiles.length === 0\"\n class=\"flex flex-col flex-1 items-center justify-center gap-12 p-24 text-center\">\n <div\n class=\"w-64 h-64 rounded-full bg-surface-1 border border-surface-3 flex items-center justify-center\">\n <VvIcon\n name=\"ri:folder-open-line\"\n class=\"w-28 h-28 text-word-4\" />\n </div>\n <span class=\"text-14 text-word-3 leading-relaxed\">\n {{ $t('userFiles.chatFilesEmpty') }}\n </span>\n </div>\n\n <!-- File list -->\n <ul v-else class=\"pk-chatbot-files\">\n <li\n v-for=\"file in chatFiles\"\n :key=\"file.documentId\"\n class=\"pk-chatbot-files__item\">\n <span class=\"pk-chatbot-files__icon\">\n <img\n v-if=\"showThumb(file)\"\n :src=\"thumbUrl(file)\"\n loading=\"lazy\"\n decoding=\"async\"\n alt=\"\"\n class=\"pk-chatbot-files__thumb\"\n @error=\"onThumbError(file)\" />\n <VvIcon v-else :name=\"fileIconForMime(file.mimeType)\" />\n </span>\n <button\n type=\"button\"\n class=\"pk-chatbot-files__main\"\n :title=\"$t('userFiles.open')\"\n @click=\"openFile(file)\">\n <span class=\"pk-chatbot-files__name\">\n {{ file.name || $t('userFiles.untitled') }}\n </span>\n <span class=\"pk-chatbot-files__date\">\n {{ formatDate(file.createdAt) }}\n </span>\n </button>\n <div class=\"pk-chatbot-files__actions\">\n <VvButton\n modifiers=\"action-quiet xs\"\n icon=\"ri:download-line\"\n :title=\"$t('action.download')\"\n @click=\"openFile(file, true)\" />\n <VvButton\n modifiers=\"action-quiet-danger xs\"\n icon=\"ri:delete-bin-line\"\n :title=\"$t('userFiles.exclude')\"\n :loading=\"deletingId === file.documentId\"\n :disabled=\"deletingId === file.documentId\"\n @click=\"handleExclude(file)\" />\n </div>\n </li>\n </ul>\n </div>\n</template>\n\n<style lang=\"scss\">\n .pk-chatbot-files {\n display: flex;\n flex-direction: column;\n list-style: none;\n margin: 0;\n padding: var(--spacing-8);\n overflow-y: auto;\n\n &__item {\n display: flex;\n align-items: center;\n gap: var(--spacing-10);\n padding: var(--spacing-8) var(--spacing-10);\n border-radius: var(--rounded-md);\n transition: var(--transition-colors);\n\n // Separator between files\n & + & {\n border-top: 1px solid var(--color-surface-3);\n }\n\n &:hover {\n background-color: var(--color-surface-2);\n }\n }\n\n &__icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: var(--spacing-36);\n height: var(--spacing-36);\n flex-shrink: 0;\n border-radius: var(--rounded-md);\n background-color: var(--color-surface-1);\n color: var(--color-word-3);\n overflow: hidden;\n }\n\n &__thumb {\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n &__main {\n display: flex;\n flex-direction: column;\n min-width: 0;\n flex: 1;\n text-align: left;\n background: none;\n border: 0;\n padding: 0;\n cursor: pointer;\n }\n\n &__name {\n font-size: var(--text-14);\n color: var(--color-word-1);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n &__date {\n font-size: var(--text-12);\n color: var(--color-word-3);\n }\n\n &__actions {\n display: flex;\n align-items: center;\n gap: var(--spacing-2);\n flex-shrink: 0;\n }\n }\n</style>\n"],"mappings":"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"}
1
+ {"version":3,"file":"PkChatbotViewFiles-BPE0g2Jk.js","names":[],"sources":["../../../../packages/composable/src/useFileRow.ts","../../../../packages/components/src/chat/PkChatbotViewFiles.vue","../../../../packages/components/src/chat/PkChatbotViewFiles.vue"],"sourcesContent":["import { reactive } from 'vue'\nimport { useI18n } from 'vue-i18n'\nimport { isImageMime, isInlineViewable } from 'models'\n\n/** Minimal shape a file-list row needs for the shared display helpers. */\nexport interface FileRowLike {\n documentId: string\n mimeType: string | null\n}\n\n/**\n * Shared display logic for the user-files list rows, used by both the in-app\n * table (PjUserFilesTable) and the embedded widget (PkChatbotViewFiles). The two\n * surfaces differ only in how they build URLs (authenticated store vs widget API\n * client), so the URL builders are injected.\n *\n * - `view(id, inline)` → opens/downloads the original file.\n * - `preview(id)` → small resized blob for the row thumbnail.\n */\nexport function useFileRow(urls: {\n view: (documentId: string, inline: boolean) => string\n preview: (documentId: string) => string\n}) {\n const { locale } = useI18n({ useScope: 'global' })\n\n // Image rows show a thumbnail; if it fails to load (auth/redirect, or the\n // preview isn't generated yet) we fall back to the file-type icon.\n const thumbError = reactive(new Set<string>())\n const showThumb = (file: FileRowLike): boolean =>\n isImageMime(file.mimeType) && !thumbError.has(file.documentId)\n const thumbUrl = (file: FileRowLike): string =>\n urls.preview(file.documentId)\n const onThumbError = (file: FileRowLike): void => {\n thumbError.add(file.documentId)\n }\n\n // Name click previews images/PDF inline; an explicit download forces an\n // attachment (inline=false → download SAS).\n const openFile = (file: FileRowLike, download = false): void => {\n const inline = !download && isInlineViewable(file.mimeType)\n window.open(urls.view(file.documentId, inline), '_blank', 'noopener')\n }\n\n const formatDate = (iso: string): string =>\n new Date(iso).toLocaleDateString(locale.value, {\n year: 'numeric',\n month: 'short',\n day: 'numeric',\n })\n\n return { showThumb, thumbUrl, onThumbError, openFile, formatDate }\n}\n","<script setup lang=\"ts\">\n import { ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { fileIconForMime } from 'models'\n import {\n useChatbotStore,\n useDialogConfirm,\n useFileRow,\n type ChatbotFile,\n } from 'composables'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n const { openDialogConfirm } = useDialogConfirm()\n\n const store = useChatbotStore(props.agentId)\n const { chatFiles, isLoadingChatFiles } = storeToRefs(store)\n const { showThumb, thumbUrl, onThumbError, openFile, formatDate } =\n useFileRow({\n view: store.getChatFileUrl,\n preview: store.getChatFilePreviewUrl,\n })\n\n const deletingId = ref<string | null>(null)\n\n const handleExclude = async (file: ChatbotFile) => {\n const proceed = await openDialogConfirm({\n title: $t('userFiles.excludeTitle'),\n questionLabel: $t('userFiles.excludeConfirm'),\n })\n if (!proceed) {\n return\n }\n deletingId.value = file.documentId\n try {\n await store.deleteChatFile(file.documentId)\n } catch {\n // surfaced by the host's error handling\n } finally {\n deletingId.value = null\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 relative\">\n <!-- Loading skeleton -->\n <div\n v-if=\"isLoadingChatFiles && chatFiles.length === 0\"\n class=\"flex flex-col gap-8 p-16 vv-skeleton\">\n <div\n v-for=\"i in 4\"\n :key=\"i\"\n class=\"vv-skeleton__item rounded-md h-56\" />\n </div>\n\n <!-- Empty state -->\n <div\n v-else-if=\"chatFiles.length === 0\"\n class=\"flex flex-col flex-1 items-center justify-center gap-12 p-24 text-center\">\n <div\n class=\"w-64 h-64 rounded-full bg-surface-1 border border-surface-3 flex items-center justify-center\">\n <VvIcon\n name=\"ri:folder-open-line\"\n class=\"w-28 h-28 text-word-4\" />\n </div>\n <span class=\"text-14 text-word-3 leading-relaxed\">\n {{ $t('userFiles.chatFilesEmpty') }}\n </span>\n </div>\n\n <!-- File list -->\n <ul v-else class=\"pk-chatbot-files\">\n <li\n v-for=\"file in chatFiles\"\n :key=\"file.documentId\"\n class=\"pk-chatbot-files__item\">\n <span class=\"pk-chatbot-files__icon\">\n <img\n v-if=\"showThumb(file)\"\n :src=\"thumbUrl(file)\"\n loading=\"lazy\"\n decoding=\"async\"\n alt=\"\"\n class=\"pk-chatbot-files__thumb\"\n @error=\"onThumbError(file)\" />\n <VvIcon v-else :name=\"fileIconForMime(file.mimeType)\" />\n </span>\n <button\n type=\"button\"\n class=\"pk-chatbot-files__main\"\n :title=\"$t('userFiles.open')\"\n @click=\"openFile(file)\">\n <span class=\"pk-chatbot-files__name\">\n {{ file.name || $t('userFiles.untitled') }}\n </span>\n <span class=\"pk-chatbot-files__date\">\n {{ formatDate(file.createdAt) }}\n </span>\n </button>\n <div class=\"pk-chatbot-files__actions\">\n <VvButton\n modifiers=\"action-quiet xs\"\n icon=\"ri:download-line\"\n :title=\"$t('action.download')\"\n @click=\"openFile(file, true)\" />\n <VvButton\n modifiers=\"action-quiet-danger xs\"\n icon=\"ri:delete-bin-line\"\n :title=\"$t('userFiles.exclude')\"\n :loading=\"deletingId === file.documentId\"\n :disabled=\"deletingId === file.documentId\"\n @click=\"handleExclude(file)\" />\n </div>\n </li>\n </ul>\n </div>\n</template>\n\n<style lang=\"scss\">\n .pk-chatbot-files {\n display: flex;\n flex-direction: column;\n list-style: none;\n margin: 0;\n padding: var(--spacing-8);\n overflow-y: auto;\n\n &__item {\n display: flex;\n align-items: center;\n gap: var(--spacing-10);\n padding: var(--spacing-8) var(--spacing-10);\n border-radius: var(--rounded-md);\n transition: var(--transition-colors);\n\n // Separator between files\n & + & {\n border-top: 1px solid var(--color-surface-3);\n }\n\n &:hover {\n background-color: var(--color-surface-2);\n }\n }\n\n &__icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: var(--spacing-36);\n height: var(--spacing-36);\n flex-shrink: 0;\n border-radius: var(--rounded-md);\n background-color: var(--color-surface-1);\n color: var(--color-word-3);\n overflow: hidden;\n }\n\n &__thumb {\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n &__main {\n display: flex;\n flex-direction: column;\n min-width: 0;\n flex: 1;\n text-align: left;\n background: none;\n border: 0;\n padding: 0;\n cursor: pointer;\n }\n\n &__name {\n font-size: var(--text-14);\n color: var(--color-word-1);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n &__date {\n font-size: var(--text-12);\n color: var(--color-word-3);\n }\n\n &__actions {\n display: flex;\n align-items: center;\n gap: var(--spacing-2);\n flex-shrink: 0;\n }\n }\n</style>\n","<script setup lang=\"ts\">\n import { ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { fileIconForMime } from 'models'\n import {\n useChatbotStore,\n useDialogConfirm,\n useFileRow,\n type ChatbotFile,\n } from 'composables'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n const { openDialogConfirm } = useDialogConfirm()\n\n const store = useChatbotStore(props.agentId)\n const { chatFiles, isLoadingChatFiles } = storeToRefs(store)\n const { showThumb, thumbUrl, onThumbError, openFile, formatDate } =\n useFileRow({\n view: store.getChatFileUrl,\n preview: store.getChatFilePreviewUrl,\n })\n\n const deletingId = ref<string | null>(null)\n\n const handleExclude = async (file: ChatbotFile) => {\n const proceed = await openDialogConfirm({\n title: $t('userFiles.excludeTitle'),\n questionLabel: $t('userFiles.excludeConfirm'),\n })\n if (!proceed) {\n return\n }\n deletingId.value = file.documentId\n try {\n await store.deleteChatFile(file.documentId)\n } catch {\n // surfaced by the host's error handling\n } finally {\n deletingId.value = null\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 relative\">\n <!-- Loading skeleton -->\n <div\n v-if=\"isLoadingChatFiles && chatFiles.length === 0\"\n class=\"flex flex-col gap-8 p-16 vv-skeleton\">\n <div\n v-for=\"i in 4\"\n :key=\"i\"\n class=\"vv-skeleton__item rounded-md h-56\" />\n </div>\n\n <!-- Empty state -->\n <div\n v-else-if=\"chatFiles.length === 0\"\n class=\"flex flex-col flex-1 items-center justify-center gap-12 p-24 text-center\">\n <div\n class=\"w-64 h-64 rounded-full bg-surface-1 border border-surface-3 flex items-center justify-center\">\n <VvIcon\n name=\"ri:folder-open-line\"\n class=\"w-28 h-28 text-word-4\" />\n </div>\n <span class=\"text-14 text-word-3 leading-relaxed\">\n {{ $t('userFiles.chatFilesEmpty') }}\n </span>\n </div>\n\n <!-- File list -->\n <ul v-else class=\"pk-chatbot-files\">\n <li\n v-for=\"file in chatFiles\"\n :key=\"file.documentId\"\n class=\"pk-chatbot-files__item\">\n <span class=\"pk-chatbot-files__icon\">\n <img\n v-if=\"showThumb(file)\"\n :src=\"thumbUrl(file)\"\n loading=\"lazy\"\n decoding=\"async\"\n alt=\"\"\n class=\"pk-chatbot-files__thumb\"\n @error=\"onThumbError(file)\" />\n <VvIcon v-else :name=\"fileIconForMime(file.mimeType)\" />\n </span>\n <button\n type=\"button\"\n class=\"pk-chatbot-files__main\"\n :title=\"$t('userFiles.open')\"\n @click=\"openFile(file)\">\n <span class=\"pk-chatbot-files__name\">\n {{ file.name || $t('userFiles.untitled') }}\n </span>\n <span class=\"pk-chatbot-files__date\">\n {{ formatDate(file.createdAt) }}\n </span>\n </button>\n <div class=\"pk-chatbot-files__actions\">\n <VvButton\n modifiers=\"action-quiet xs\"\n icon=\"ri:download-line\"\n :title=\"$t('action.download')\"\n @click=\"openFile(file, true)\" />\n <VvButton\n modifiers=\"action-quiet-danger xs\"\n icon=\"ri:delete-bin-line\"\n :title=\"$t('userFiles.exclude')\"\n :loading=\"deletingId === file.documentId\"\n :disabled=\"deletingId === file.documentId\"\n @click=\"handleExclude(file)\" />\n </div>\n </li>\n </ul>\n </div>\n</template>\n\n<style lang=\"scss\">\n .pk-chatbot-files {\n display: flex;\n flex-direction: column;\n list-style: none;\n margin: 0;\n padding: var(--spacing-8);\n overflow-y: auto;\n\n &__item {\n display: flex;\n align-items: center;\n gap: var(--spacing-10);\n padding: var(--spacing-8) var(--spacing-10);\n border-radius: var(--rounded-md);\n transition: var(--transition-colors);\n\n // Separator between files\n & + & {\n border-top: 1px solid var(--color-surface-3);\n }\n\n &:hover {\n background-color: var(--color-surface-2);\n }\n }\n\n &__icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: var(--spacing-36);\n height: var(--spacing-36);\n flex-shrink: 0;\n border-radius: var(--rounded-md);\n background-color: var(--color-surface-1);\n color: var(--color-word-3);\n overflow: hidden;\n }\n\n &__thumb {\n width: 100%;\n height: 100%;\n object-fit: cover;\n }\n\n &__main {\n display: flex;\n flex-direction: column;\n min-width: 0;\n flex: 1;\n text-align: left;\n background: none;\n border: 0;\n padding: 0;\n cursor: pointer;\n }\n\n &__name {\n font-size: var(--text-14);\n color: var(--color-word-1);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n &__date {\n font-size: var(--text-12);\n color: var(--color-word-3);\n }\n\n &__actions {\n display: flex;\n align-items: center;\n gap: var(--spacing-2);\n flex-shrink: 0;\n }\n }\n</style>\n"],"mappings":"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"}
@@ -1,4 +1,4 @@
1
- import { t as e } from "./useChatbotStore-bbenzuMe.js";
1
+ import { t as e } from "./useChatbotStore-Cfx-qlC4.js";
2
2
  import { t } from "./PkAvatar-CyIgsndA.js";
3
3
  import { t as n } from "./chatbotProfileContext-CgnFhNPn.js";
4
4
  import { VvAlert as r, VvButton as i, VvIcon as a } from "@volverjs/ui-vue/components";
@@ -83,4 +83,4 @@ var x = { class: "flex flex-col flex-1 min-h-0 overflow-y-auto" }, S = { class:
83
83
  //#endregion
84
84
  export { N as t };
85
85
 
86
- //# sourceMappingURL=PkChatbotViewProfile-B_ZAXIrC.js.map
86
+ //# sourceMappingURL=PkChatbotViewProfile-B_gWPgVY.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PkChatbotViewProfile-B_ZAXIrC.js","names":[],"sources":["../../../../packages/components/src/chat/PkChatbotViewProfile.vue","../../../../packages/components/src/chat/PkChatbotViewProfile.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed, inject, ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { useChatbotStore } from 'composables'\n import PkAvatar from './PkAvatar.vue'\n import { ChatbotProfileContextKey } from './chatbotProfileContext'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n\n const store = useChatbotStore(props.agentId)\n const { name: agentName, agentInterface } = storeToRefs(store)\n\n const profile = inject(ChatbotProfileContextKey, undefined)\n const user = computed(() => profile?.user.value ?? null)\n const canManage = computed(() => profile?.canManageProfile.value ?? false)\n const profileUrl = computed(() => profile?.profileUrl.value)\n // External token mode: the host owns the auth lifecycle, so the widget\n // offers no sign-out nor profile management (the main site is not\n // accessible to externally authenticated users).\n const isExternalAuth = computed(\n () => profile?.isExternalAuth?.value ?? false,\n )\n\n const isSigningOut = ref(false)\n const errorMessage = ref<string>()\n\n async function onSignOut() {\n if (!profile) {\n return\n }\n isSigningOut.value = true\n try {\n await profile.signOut()\n } catch (error) {\n errorMessage.value =\n error instanceof Error ? error.message : $t('message.error')\n } finally {\n isSigningOut.value = false\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 overflow-y-auto\">\n <!-- Hero: user identity -->\n <div\n class=\"flex flex-col items-center gap-sm pt-lg px-lg pb-md bg-surface-1 border-b border-surface-3\">\n <PkAvatar\n modifiers=\"surface ring\"\n class=\"w-64 h-64\"\n :name=\"user?.name ?? agentName\"\n :img-src=\"user?.image ?? agentInterface?.logo\" />\n <div class=\"flex flex-col items-center gap-6 text-center\">\n <strong\n v-if=\"user?.name ?? agentName\"\n class=\"text-16 font-semibold text-word-1 leading-tight\">\n {{ user?.name ?? agentName }}\n </strong>\n <span\n v-if=\"user?.email\"\n class=\"text-12 text-word-3 leading-none\">\n {{ user.email }}\n </span>\n </div>\n </div>\n\n <!-- Actions -->\n <div class=\"flex flex-col gap-sm p-md flex-1\">\n <VvAlert\n v-if=\"errorMessage\"\n modifiers=\"danger\"\n :content=\"errorMessage\" />\n\n <!-- Manage profile link card -->\n <a\n v-if=\"canManage && profileUrl && !isExternalAuth\"\n :href=\"profileUrl\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n class=\"flex items-center gap-12 p-12 rounded-lg border border-surface-3 hover:border-surface-5 hover:bg-surface-1 transition-colors cursor-pointer no-underline\">\n <div\n class=\"w-40 h-40 rounded-md bg-surface-2 border border-surface-3 flex items-center justify-center shrink-0\">\n <VvIcon\n name=\"ri:user-settings-line\"\n class=\"w-20 h-20 text-word-2\" />\n </div>\n <div class=\"flex flex-col flex-1 min-w-0 gap-1\">\n <span class=\"text-14 font-medium text-word-1 leading-tight\">\n {{ $t('action.manageProfile') }}\n </span>\n <span class=\"text-12 text-word-3 leading-tight\">\n {{ $t('label.manageProfileDescription') }}\n </span>\n </div>\n <VvIcon\n name=\"ri:arrow-right-s-line\"\n class=\"w-16 h-16 text-word-4 shrink-0\" />\n </a>\n </div>\n\n <!-- Footer: sign out -->\n <div v-if=\"!isExternalAuth\" class=\"px-md py-sm\">\n <VvButton\n modifiers=\"secondary-danger\"\n class=\"w-full\"\n icon=\"ri:logout-box-line\"\n :loading=\"isSigningOut\"\n :disabled=\"isSigningOut\"\n :label=\"$t('action.signOut')\"\n @click=\"onSignOut\" />\n </div>\n\n <slot />\n </div>\n</template>\n","<script setup lang=\"ts\">\n import { computed, inject, ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { useChatbotStore } from 'composables'\n import PkAvatar from './PkAvatar.vue'\n import { ChatbotProfileContextKey } from './chatbotProfileContext'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n\n const store = useChatbotStore(props.agentId)\n const { name: agentName, agentInterface } = storeToRefs(store)\n\n const profile = inject(ChatbotProfileContextKey, undefined)\n const user = computed(() => profile?.user.value ?? null)\n const canManage = computed(() => profile?.canManageProfile.value ?? false)\n const profileUrl = computed(() => profile?.profileUrl.value)\n // External token mode: the host owns the auth lifecycle, so the widget\n // offers no sign-out nor profile management (the main site is not\n // accessible to externally authenticated users).\n const isExternalAuth = computed(\n () => profile?.isExternalAuth?.value ?? false,\n )\n\n const isSigningOut = ref(false)\n const errorMessage = ref<string>()\n\n async function onSignOut() {\n if (!profile) {\n return\n }\n isSigningOut.value = true\n try {\n await profile.signOut()\n } catch (error) {\n errorMessage.value =\n error instanceof Error ? error.message : $t('message.error')\n } finally {\n isSigningOut.value = false\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 overflow-y-auto\">\n <!-- Hero: user identity -->\n <div\n class=\"flex flex-col items-center gap-sm pt-lg px-lg pb-md bg-surface-1 border-b border-surface-3\">\n <PkAvatar\n modifiers=\"surface ring\"\n class=\"w-64 h-64\"\n :name=\"user?.name ?? agentName\"\n :img-src=\"user?.image ?? agentInterface?.logo\" />\n <div class=\"flex flex-col items-center gap-6 text-center\">\n <strong\n v-if=\"user?.name ?? agentName\"\n class=\"text-16 font-semibold text-word-1 leading-tight\">\n {{ user?.name ?? agentName }}\n </strong>\n <span\n v-if=\"user?.email\"\n class=\"text-12 text-word-3 leading-none\">\n {{ user.email }}\n </span>\n </div>\n </div>\n\n <!-- Actions -->\n <div class=\"flex flex-col gap-sm p-md flex-1\">\n <VvAlert\n v-if=\"errorMessage\"\n modifiers=\"danger\"\n :content=\"errorMessage\" />\n\n <!-- Manage profile link card -->\n <a\n v-if=\"canManage && profileUrl && !isExternalAuth\"\n :href=\"profileUrl\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n class=\"flex items-center gap-12 p-12 rounded-lg border border-surface-3 hover:border-surface-5 hover:bg-surface-1 transition-colors cursor-pointer no-underline\">\n <div\n class=\"w-40 h-40 rounded-md bg-surface-2 border border-surface-3 flex items-center justify-center shrink-0\">\n <VvIcon\n name=\"ri:user-settings-line\"\n class=\"w-20 h-20 text-word-2\" />\n </div>\n <div class=\"flex flex-col flex-1 min-w-0 gap-1\">\n <span class=\"text-14 font-medium text-word-1 leading-tight\">\n {{ $t('action.manageProfile') }}\n </span>\n <span class=\"text-12 text-word-3 leading-tight\">\n {{ $t('label.manageProfileDescription') }}\n </span>\n </div>\n <VvIcon\n name=\"ri:arrow-right-s-line\"\n class=\"w-16 h-16 text-word-4 shrink-0\" />\n </a>\n </div>\n\n <!-- Footer: sign out -->\n <div v-if=\"!isExternalAuth\" class=\"px-md py-sm\">\n <VvButton\n modifiers=\"secondary-danger\"\n class=\"w-full\"\n icon=\"ri:logout-box-line\"\n :loading=\"isSigningOut\"\n :disabled=\"isSigningOut\"\n :label=\"$t('action.signOut')\"\n @click=\"onSignOut\" />\n </div>\n\n <slot />\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;EAQI,IAAM,IAAQ,GAER,EAAE,GAAG,MAAO,EAAQ,EAAE,UAAU,SAAS,CAAC,GAG1C,EAAE,MAAM,GAAW,sBAAmB,EAD9B,EAAgB,EAAM,OACoB,CAAK,GAEvD,IAAU,EAAO,GAA0B,KAAA,CAAS,GACpD,IAAO,QAAe,GAAS,KAAK,SAAS,IAAI,GACjD,IAAY,QAAe,GAAS,iBAAiB,SAAS,EAAK,GACnE,IAAa,QAAe,GAAS,WAAW,KAAK,GAIrD,IAAiB,QACb,GAAS,gBAAgB,SAAS,EAC5C,GAEM,IAAe,EAAI,EAAK,GACxB,IAAe,EAAY;EAEjC,eAAe,IAAY;GAClB,OAGL;MAAa,QAAQ;IACrB,IAAI;KACA,MAAM,EAAQ,QAAQ;IAC1B,SAAS,GAAO;KACZ,EAAa,QACT,aAAiB,QAAQ,EAAM,UAAU,EAAG,eAAe;IACnE,UAAU;KACN,EAAa,QAAQ;IACzB;GARqB;EASzB;;;eAIA,EAsEM,OAtEN,GAsEM;IApEF,EAmBM,OAnBN,GAmBM,CAjBF,EAIqD,GAAA;KAHjD,WAAU;KACV,OAAM;KACL,MAAM,EAAA,OAAM,QAAQ,EAAA,CAAA;KACpB,WAAS,EAAA,OAAM,SAAS,EAAA,CAAA,CAAc,EAAE;sCAC7C,EAWM,OAXN,GAWM,CATQ,EAAA,OAAM,QAAQ,EAAA,CAAA,KAAA,EAAA,GADxB,EAIS,UAJT,GAIS,EADF,EAAA,OAAM,QAAQ,EAAA,CAAA,CAAS,GAAA,CAAA,KAAA,EAAA,IAAA,EAAA,GAGpB,EAAA,OAAM,SAAA,EAAA,GADhB,EAIO,QAJP,GAIO,EADA,EAAA,MAAK,KAAK,GAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,CAAA,CAAA,CAAA;IAMzB,EA+BM,OA/BN,GA+BM,CA7BQ,EAAA,SAAA,EAAA,GADV,EAG8B,GAAA;;KAD1B,WAAU;KACT,SAAS,EAAA;2CAIJ,EAAA,SAAa,EAAA,SAAU,CAAK,EAAA,SAAA,EAAA,GADtC,EAuBI,KAAA;;KArBC,MAAM,EAAA;KACP,QAAO;KACP,KAAI;KACJ,OAAM;;KACN,EAKM,OALN,GAKM,CAHF,EAEoC,GAAA;MADhC,MAAK;MACL,OAAM;;KAEd,EAOM,OAPN,GAOM,CANF,EAEO,QAFP,GAEO,EADA,EAAA,CAAA,CAAE,CAAA,sBAAA,CAAA,GAAA,CAAA,GAET,EAEO,QAFP,GAEO,EADA,EAAA,CAAA,CAAE,CAAA,gCAAA,CAAA,GAAA,CAAA,CAAA,CAAA;KAGb,EAE6C,GAAA;MADzC,MAAK;MACL,OAAM;;;IAKN,EAAA,qBAAA,EAAA,GAAZ,EASM,OATN,GASM,CARF,EAOyB,GAAA;KANrB,WAAU;KACV,OAAM;KACN,MAAK;KACJ,SAAS,EAAA;KACT,UAAU,EAAA;KACV,OAAO,EAAA,CAAA,CAAE,CAAA,gBAAA;KACT,SAAO;;;;;;IAGhB,EAAQ,EAAA,QAAA,SAAA"}
1
+ {"version":3,"file":"PkChatbotViewProfile-B_gWPgVY.js","names":[],"sources":["../../../../packages/components/src/chat/PkChatbotViewProfile.vue","../../../../packages/components/src/chat/PkChatbotViewProfile.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed, inject, ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { useChatbotStore } from 'composables'\n import PkAvatar from './PkAvatar.vue'\n import { ChatbotProfileContextKey } from './chatbotProfileContext'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n\n const store = useChatbotStore(props.agentId)\n const { name: agentName, agentInterface } = storeToRefs(store)\n\n const profile = inject(ChatbotProfileContextKey, undefined)\n const user = computed(() => profile?.user.value ?? null)\n const canManage = computed(() => profile?.canManageProfile.value ?? false)\n const profileUrl = computed(() => profile?.profileUrl.value)\n // External token mode: the host owns the auth lifecycle, so the widget\n // offers no sign-out nor profile management (the main site is not\n // accessible to externally authenticated users).\n const isExternalAuth = computed(\n () => profile?.isExternalAuth?.value ?? false,\n )\n\n const isSigningOut = ref(false)\n const errorMessage = ref<string>()\n\n async function onSignOut() {\n if (!profile) {\n return\n }\n isSigningOut.value = true\n try {\n await profile.signOut()\n } catch (error) {\n errorMessage.value =\n error instanceof Error ? error.message : $t('message.error')\n } finally {\n isSigningOut.value = false\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 overflow-y-auto\">\n <!-- Hero: user identity -->\n <div\n class=\"flex flex-col items-center gap-sm pt-lg px-lg pb-md bg-surface-1 border-b border-surface-3\">\n <PkAvatar\n modifiers=\"surface ring\"\n class=\"w-64 h-64\"\n :name=\"user?.name ?? agentName\"\n :img-src=\"user?.image ?? agentInterface?.logo\" />\n <div class=\"flex flex-col items-center gap-6 text-center\">\n <strong\n v-if=\"user?.name ?? agentName\"\n class=\"text-16 font-semibold text-word-1 leading-tight\">\n {{ user?.name ?? agentName }}\n </strong>\n <span\n v-if=\"user?.email\"\n class=\"text-12 text-word-3 leading-none\">\n {{ user.email }}\n </span>\n </div>\n </div>\n\n <!-- Actions -->\n <div class=\"flex flex-col gap-sm p-md flex-1\">\n <VvAlert\n v-if=\"errorMessage\"\n modifiers=\"danger\"\n :content=\"errorMessage\" />\n\n <!-- Manage profile link card -->\n <a\n v-if=\"canManage && profileUrl && !isExternalAuth\"\n :href=\"profileUrl\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n class=\"flex items-center gap-12 p-12 rounded-lg border border-surface-3 hover:border-surface-5 hover:bg-surface-1 transition-colors cursor-pointer no-underline\">\n <div\n class=\"w-40 h-40 rounded-md bg-surface-2 border border-surface-3 flex items-center justify-center shrink-0\">\n <VvIcon\n name=\"ri:user-settings-line\"\n class=\"w-20 h-20 text-word-2\" />\n </div>\n <div class=\"flex flex-col flex-1 min-w-0 gap-1\">\n <span class=\"text-14 font-medium text-word-1 leading-tight\">\n {{ $t('action.manageProfile') }}\n </span>\n <span class=\"text-12 text-word-3 leading-tight\">\n {{ $t('label.manageProfileDescription') }}\n </span>\n </div>\n <VvIcon\n name=\"ri:arrow-right-s-line\"\n class=\"w-16 h-16 text-word-4 shrink-0\" />\n </a>\n </div>\n\n <!-- Footer: sign out -->\n <div v-if=\"!isExternalAuth\" class=\"px-md py-sm\">\n <VvButton\n modifiers=\"secondary-danger\"\n class=\"w-full\"\n icon=\"ri:logout-box-line\"\n :loading=\"isSigningOut\"\n :disabled=\"isSigningOut\"\n :label=\"$t('action.signOut')\"\n @click=\"onSignOut\" />\n </div>\n\n <slot />\n </div>\n</template>\n","<script setup lang=\"ts\">\n import { computed, inject, ref } from 'vue'\n import { storeToRefs } from 'pinia'\n import { useI18n } from 'vue-i18n'\n import { useChatbotStore } from 'composables'\n import PkAvatar from './PkAvatar.vue'\n import { ChatbotProfileContextKey } from './chatbotProfileContext'\n\n const props = defineProps<{ agentId: string }>()\n\n const { t: $t } = useI18n({ useScope: 'global' })\n\n const store = useChatbotStore(props.agentId)\n const { name: agentName, agentInterface } = storeToRefs(store)\n\n const profile = inject(ChatbotProfileContextKey, undefined)\n const user = computed(() => profile?.user.value ?? null)\n const canManage = computed(() => profile?.canManageProfile.value ?? false)\n const profileUrl = computed(() => profile?.profileUrl.value)\n // External token mode: the host owns the auth lifecycle, so the widget\n // offers no sign-out nor profile management (the main site is not\n // accessible to externally authenticated users).\n const isExternalAuth = computed(\n () => profile?.isExternalAuth?.value ?? false,\n )\n\n const isSigningOut = ref(false)\n const errorMessage = ref<string>()\n\n async function onSignOut() {\n if (!profile) {\n return\n }\n isSigningOut.value = true\n try {\n await profile.signOut()\n } catch (error) {\n errorMessage.value =\n error instanceof Error ? error.message : $t('message.error')\n } finally {\n isSigningOut.value = false\n }\n }\n</script>\n\n<template>\n <div class=\"flex flex-col flex-1 min-h-0 overflow-y-auto\">\n <!-- Hero: user identity -->\n <div\n class=\"flex flex-col items-center gap-sm pt-lg px-lg pb-md bg-surface-1 border-b border-surface-3\">\n <PkAvatar\n modifiers=\"surface ring\"\n class=\"w-64 h-64\"\n :name=\"user?.name ?? agentName\"\n :img-src=\"user?.image ?? agentInterface?.logo\" />\n <div class=\"flex flex-col items-center gap-6 text-center\">\n <strong\n v-if=\"user?.name ?? agentName\"\n class=\"text-16 font-semibold text-word-1 leading-tight\">\n {{ user?.name ?? agentName }}\n </strong>\n <span\n v-if=\"user?.email\"\n class=\"text-12 text-word-3 leading-none\">\n {{ user.email }}\n </span>\n </div>\n </div>\n\n <!-- Actions -->\n <div class=\"flex flex-col gap-sm p-md flex-1\">\n <VvAlert\n v-if=\"errorMessage\"\n modifiers=\"danger\"\n :content=\"errorMessage\" />\n\n <!-- Manage profile link card -->\n <a\n v-if=\"canManage && profileUrl && !isExternalAuth\"\n :href=\"profileUrl\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n class=\"flex items-center gap-12 p-12 rounded-lg border border-surface-3 hover:border-surface-5 hover:bg-surface-1 transition-colors cursor-pointer no-underline\">\n <div\n class=\"w-40 h-40 rounded-md bg-surface-2 border border-surface-3 flex items-center justify-center shrink-0\">\n <VvIcon\n name=\"ri:user-settings-line\"\n class=\"w-20 h-20 text-word-2\" />\n </div>\n <div class=\"flex flex-col flex-1 min-w-0 gap-1\">\n <span class=\"text-14 font-medium text-word-1 leading-tight\">\n {{ $t('action.manageProfile') }}\n </span>\n <span class=\"text-12 text-word-3 leading-tight\">\n {{ $t('label.manageProfileDescription') }}\n </span>\n </div>\n <VvIcon\n name=\"ri:arrow-right-s-line\"\n class=\"w-16 h-16 text-word-4 shrink-0\" />\n </a>\n </div>\n\n <!-- Footer: sign out -->\n <div v-if=\"!isExternalAuth\" class=\"px-md py-sm\">\n <VvButton\n modifiers=\"secondary-danger\"\n class=\"w-full\"\n icon=\"ri:logout-box-line\"\n :loading=\"isSigningOut\"\n :disabled=\"isSigningOut\"\n :label=\"$t('action.signOut')\"\n @click=\"onSignOut\" />\n </div>\n\n <slot />\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;EAQI,IAAM,IAAQ,GAER,EAAE,GAAG,MAAO,EAAQ,EAAE,UAAU,SAAS,CAAC,GAG1C,EAAE,MAAM,GAAW,sBAAmB,EAD9B,EAAgB,EAAM,OACoB,CAAK,GAEvD,IAAU,EAAO,GAA0B,KAAA,CAAS,GACpD,IAAO,QAAe,GAAS,KAAK,SAAS,IAAI,GACjD,IAAY,QAAe,GAAS,iBAAiB,SAAS,EAAK,GACnE,IAAa,QAAe,GAAS,WAAW,KAAK,GAIrD,IAAiB,QACb,GAAS,gBAAgB,SAAS,EAC5C,GAEM,IAAe,EAAI,EAAK,GACxB,IAAe,EAAY;EAEjC,eAAe,IAAY;GAClB,OAGL;MAAa,QAAQ;IACrB,IAAI;KACA,MAAM,EAAQ,QAAQ;IAC1B,SAAS,GAAO;KACZ,EAAa,QACT,aAAiB,QAAQ,EAAM,UAAU,EAAG,eAAe;IACnE,UAAU;KACN,EAAa,QAAQ;IACzB;GARqB;EASzB;;;eAIA,EAsEM,OAtEN,GAsEM;IApEF,EAmBM,OAnBN,GAmBM,CAjBF,EAIqD,GAAA;KAHjD,WAAU;KACV,OAAM;KACL,MAAM,EAAA,OAAM,QAAQ,EAAA,CAAA;KACpB,WAAS,EAAA,OAAM,SAAS,EAAA,CAAA,CAAc,EAAE;sCAC7C,EAWM,OAXN,GAWM,CATQ,EAAA,OAAM,QAAQ,EAAA,CAAA,KAAA,EAAA,GADxB,EAIS,UAJT,GAIS,EADF,EAAA,OAAM,QAAQ,EAAA,CAAA,CAAS,GAAA,CAAA,KAAA,EAAA,IAAA,EAAA,GAGpB,EAAA,OAAM,SAAA,EAAA,GADhB,EAIO,QAJP,GAIO,EADA,EAAA,MAAK,KAAK,GAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,CAAA,CAAA,CAAA;IAMzB,EA+BM,OA/BN,GA+BM,CA7BQ,EAAA,SAAA,EAAA,GADV,EAG8B,GAAA;;KAD1B,WAAU;KACT,SAAS,EAAA;2CAIJ,EAAA,SAAa,EAAA,SAAU,CAAK,EAAA,SAAA,EAAA,GADtC,EAuBI,KAAA;;KArBC,MAAM,EAAA;KACP,QAAO;KACP,KAAI;KACJ,OAAM;;KACN,EAKM,OALN,GAKM,CAHF,EAEoC,GAAA;MADhC,MAAK;MACL,OAAM;;KAEd,EAOM,OAPN,GAOM,CANF,EAEO,QAFP,GAEO,EADA,EAAA,CAAA,CAAE,CAAA,sBAAA,CAAA,GAAA,CAAA,GAET,EAEO,QAFP,GAEO,EADA,EAAA,CAAA,CAAE,CAAA,gCAAA,CAAA,GAAA,CAAA,CAAA,CAAA;KAGb,EAE6C,GAAA;MADzC,MAAK;MACL,OAAM;;;IAKN,EAAA,qBAAA,EAAA,GAAZ,EASM,OATN,GASM,CARF,EAOyB,GAAA;KANrB,WAAU;KACV,OAAM;KACN,MAAK;KACJ,SAAS,EAAA;KACT,UAAU,EAAA;KACV,OAAO,EAAA,CAAA,CAAE,CAAA,gBAAA;KACT,SAAO;;;;;;IAGhB,EAAQ,EAAA,QAAA,SAAA"}
@@ -532,7 +532,7 @@ $$` : `${e}$$`;
532
532
  return n;
533
533
  };
534
534
  //#endregion
535
- //#region ../../node_modules/.pnpm/marked@18.0.6/node_modules/marked/lib/marked.esm.js
535
+ //#region ../../node_modules/.pnpm/marked@18.0.7/node_modules/marked/lib/marked.esm.js
536
536
  function k() {
537
537
  return {
538
538
  async: !1,
@@ -632,7 +632,7 @@ var gt = ((e = "") => {
632
632
  headingBeginRegex: M((e) => RegExp(`^ {0,${e}}#`)),
633
633
  htmlBeginRegex: M((e) => RegExp(`^ {0,${e}}<(?:[a-z].*>|!--)`, "i")),
634
634
  blockquoteBeginRegex: M((e) => RegExp(`^ {0,${e}}>`))
635
- }, _t = /^(?:[ \t]*(?:\n|$))+/, vt = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, yt = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, F = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, bt = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, I = / {0,3}(?:[*+-]|\d{1,9}[.)])/, xt = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, St = N(xt).replace(/bull/g, I).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), Ct = N(xt).replace(/bull/g, I).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), wt = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, Tt = /^[^\n]+/, Et = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, Dt = N(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", Et).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), Ot = N(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g, I).getRegex(), L = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", kt = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, At = N("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n+|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n+|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n+|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", kt).replace("tag", L).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), jt = (e) => N(wt).replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", e).replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", L).getRegex(), Mt = jt(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/), Nt = jt(/ {0,3}(?:[*+-]|\d{1,9}[.)])[ \t]+[^ \t\n]/), Pt = {
635
+ }, _t = /^(?:[ \t]*(?:\n|$))+/, vt = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, yt = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, F = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, bt = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, I = / {0,3}(?:[*+-]|\d{1,9}[.)])/, xt = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, St = N(xt).replace(/bull/g, I).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}(?:\s|$)/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), Ct = N(xt).replace(/bull/g, I).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}(?:\s|$)/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), wt = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/, Tt = /^[^\n]+/, Et = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, Dt = N(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", Et).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), Ot = N(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g, I).getRegex(), L = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", kt = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, At = N("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", kt).replace("tag", L).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), jt = (e) => N(wt).replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~~~)[^\\n]*\\n").replace("list", e).replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", L).getRegex(), Mt = jt(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/), Nt = jt(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/), Pt = {
636
636
  blockquote: N(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", Nt).getRegex(),
637
637
  code: vt,
638
638
  def: Dt,
@@ -646,11 +646,11 @@ var gt = ((e = "") => {
646
646
  paragraph: Mt,
647
647
  table: j,
648
648
  text: Tt
649
- }, Ft = N("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", L).getRegex(), It = {
649
+ }, Ft = N("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~~~)[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", L).getRegex(), It = {
650
650
  ...Pt,
651
651
  lheading: Ct,
652
652
  table: Ft,
653
- paragraph: N(wt).replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", Ft).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", L).getRegex()
653
+ paragraph: N(wt).replace("hr", F).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", Ft).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~~~)[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", L).getRegex()
654
654
  }, Lt = {
655
655
  ...Pt,
656
656
  html: N("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment", kt).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
@@ -694,7 +694,7 @@ var gt = ((e = "") => {
694
694
  url: N(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", fn).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
695
695
  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
696
696
  del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,
697
- text: N(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", fn).getRegex()
697
+ text: N(/^(`+|~+|[^`~])(?:(?=[`~])|(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", fn).getRegex()
698
698
  }, hn = {
699
699
  ...mn,
700
700
  br: N(Bt).replace("{2,}", "*").getRegex(),
@@ -1388,78 +1388,78 @@ ${c}` : c;
1388
1388
  }
1389
1389
  inlineTokens(e, t = []) {
1390
1390
  this.tokenizer.lexer = this;
1391
- let n = e, r = null;
1391
+ let n = e;
1392
1392
  if (this.tokens.links) {
1393
1393
  let e = Object.keys(this.tokens.links);
1394
- if (e.length > 0) for (; (r = this.tokenizer.rules.inline.reflinkSearch.exec(n)) !== null;) e.includes(r[0].slice(r[0].lastIndexOf("[") + 1, -1)) && (n = n.slice(0, r.index) + "[" + "a".repeat(r[0].length - 2) + "]" + n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
1394
+ e.length > 0 && (n = n.replace(this.tokenizer.rules.inline.reflinkSearch, (t) => e.includes(t.slice(t.lastIndexOf("[") + 1, -1)) ? "[" + "a".repeat(t.length - 2) + "]" : t));
1395
1395
  }
1396
- for (; (r = this.tokenizer.rules.inline.anyPunctuation.exec(n)) !== null;) n = n.slice(0, r.index) + "++" + n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
1397
- let i;
1398
- for (; (r = this.tokenizer.rules.inline.blockSkip.exec(n)) !== null;) i = r[2] ? r[2].length : 0, n = n.slice(0, r.index + i) + "[" + "a".repeat(r[0].length - i - 2) + "]" + n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
1399
- n = this.options.hooks?.emStrongMask?.call({ lexer: this }, n) ?? n;
1400
- let a = !1, o = "", s = Infinity;
1396
+ n = n.replace(this.tokenizer.rules.inline.anyPunctuation, "++"), n = n.replace(this.tokenizer.rules.inline.blockSkip, (e, t, n) => {
1397
+ let r = n ? n.length : 0;
1398
+ return e.slice(0, r) + "[" + "a".repeat(e.length - r - 2) + "]";
1399
+ }), n = this.options.hooks?.emStrongMask?.call({ lexer: this }, n) ?? n;
1400
+ let r = !1, i = "", a = Infinity;
1401
1401
  for (; e;) {
1402
- if (e.length < s) s = e.length;
1402
+ if (e.length < a) a = e.length;
1403
1403
  else {
1404
1404
  this.infiniteLoopError(e.charCodeAt(0));
1405
1405
  break;
1406
1406
  }
1407
- a || (o = ""), a = !1;
1408
- let r;
1409
- if (this.options.extensions?.inline?.some((n) => (r = n.call({ lexer: this }, e, t)) ? (e = e.substring(r.raw.length), t.push(r), !0) : !1)) continue;
1410
- if (r = this.tokenizer.escape(e)) {
1411
- e = e.substring(r.raw.length), t.push(r);
1407
+ r || (i = ""), r = !1;
1408
+ let o;
1409
+ if (this.options.extensions?.inline?.some((n) => (o = n.call({ lexer: this }, e, t)) ? (e = e.substring(o.raw.length), t.push(o), !0) : !1)) continue;
1410
+ if (o = this.tokenizer.escape(e)) {
1411
+ e = e.substring(o.raw.length), t.push(o);
1412
1412
  continue;
1413
1413
  }
1414
- if (r = this.tokenizer.tag(e)) {
1415
- e = e.substring(r.raw.length), t.push(r);
1414
+ if (o = this.tokenizer.tag(e)) {
1415
+ e = e.substring(o.raw.length), t.push(o);
1416
1416
  continue;
1417
1417
  }
1418
- if (r = this.tokenizer.link(e)) {
1419
- e = e.substring(r.raw.length), t.push(r);
1418
+ if (o = this.tokenizer.link(e)) {
1419
+ e = e.substring(o.raw.length), t.push(o);
1420
1420
  continue;
1421
1421
  }
1422
- if (r = this.tokenizer.reflink(e, this.tokens.links)) {
1423
- e = e.substring(r.raw.length);
1422
+ if (o = this.tokenizer.reflink(e, this.tokens.links)) {
1423
+ e = e.substring(o.raw.length);
1424
1424
  let n = t.at(-1);
1425
- r.type === "text" && n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
1425
+ o.type === "text" && n?.type === "text" ? (n.raw += o.raw, n.text += o.text) : t.push(o);
1426
1426
  continue;
1427
1427
  }
1428
- if (r = this.tokenizer.emStrong(e, n, o)) {
1429
- e = e.substring(r.raw.length), t.push(r);
1428
+ if (o = this.tokenizer.emStrong(e, n, i)) {
1429
+ e = e.substring(o.raw.length), t.push(o);
1430
1430
  continue;
1431
1431
  }
1432
- if (r = this.tokenizer.codespan(e)) {
1433
- e = e.substring(r.raw.length), t.push(r);
1432
+ if (o = this.tokenizer.codespan(e)) {
1433
+ e = e.substring(o.raw.length), t.push(o);
1434
1434
  continue;
1435
1435
  }
1436
- if (r = this.tokenizer.br(e)) {
1437
- e = e.substring(r.raw.length), t.push(r);
1436
+ if (o = this.tokenizer.br(e)) {
1437
+ e = e.substring(o.raw.length), t.push(o);
1438
1438
  continue;
1439
1439
  }
1440
- if (r = this.tokenizer.del(e, n, o)) {
1441
- e = e.substring(r.raw.length), t.push(r);
1440
+ if (o = this.tokenizer.del(e, n, i)) {
1441
+ e = e.substring(o.raw.length), t.push(o);
1442
1442
  continue;
1443
1443
  }
1444
- if (r = this.tokenizer.autolink(e)) {
1445
- e = e.substring(r.raw.length), t.push(r);
1444
+ if (o = this.tokenizer.autolink(e)) {
1445
+ e = e.substring(o.raw.length), t.push(o);
1446
1446
  continue;
1447
1447
  }
1448
- if (!this.state.inLink && (r = this.tokenizer.url(e))) {
1449
- e = e.substring(r.raw.length), t.push(r);
1448
+ if (!this.state.inLink && (o = this.tokenizer.url(e))) {
1449
+ e = e.substring(o.raw.length), t.push(o);
1450
1450
  continue;
1451
1451
  }
1452
- let i = e;
1452
+ let s = e;
1453
1453
  if (this.options.extensions?.startInline) {
1454
1454
  let t = Infinity, n = e.slice(1), r;
1455
1455
  this.options.extensions.startInline.forEach((e) => {
1456
1456
  r = e.call({ lexer: this }, n), typeof r == "number" && r >= 0 && (t = Math.min(t, r));
1457
- }), t < Infinity && t >= 0 && (i = e.substring(0, t + 1));
1457
+ }), t < Infinity && t >= 0 && (s = e.substring(0, t + 1));
1458
1458
  }
1459
- if (r = this.tokenizer.inlineText(i)) {
1460
- e = e.substring(r.raw.length), r.raw.slice(-1) !== "_" && (o = r.raw.slice(-1)), a = !0;
1459
+ if (o = this.tokenizer.inlineText(s)) {
1460
+ e = e.substring(o.raw.length), o.raw.slice(-1) !== "_" && (i = o.raw.slice(-1)), r = !0;
1461
1461
  let n = t.at(-1);
1462
- n?.type === "text" ? (n.raw += r.raw, n.text += r.text) : t.push(r);
1462
+ n?.type === "text" ? (n.raw += o.raw, n.text += o.text) : t.push(o);
1463
1463
  continue;
1464
1464
  }
1465
1465
  if (e) {
@@ -2218,4 +2218,4 @@ var Tn = ["innerHTML"], En = /* @__PURE__ */ o({
2218
2218
  //#endregion
2219
2219
  export { En as t };
2220
2220
 
2221
- //# sourceMappingURL=PkStreamingMarkdown-CNLdk20r.js.map
2221
+ //# sourceMappingURL=PkStreamingMarkdown-DEhbK-3c.js.map