@8wave/ai-elements 0.75.0 → 0.77.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{PkStreamingMarkdown-rIdQh5_D.js → PkStreamingMarkdown-COZApJzT.js} +3 -3
- package/dist/_chunks/{PkStreamingMarkdown-rIdQh5_D.js.map → PkStreamingMarkdown-COZApJzT.js.map} +1 -1
- package/dist/_chunks/{PkToolShowArtifact-CeLgwZBA.js → PkToolShowArtifact-BZQixk9z.js} +5 -5
- package/dist/_chunks/{PkToolShowArtifact-CeLgwZBA.js.map → PkToolShowArtifact-BZQixk9z.js.map} +1 -1
- package/dist/_chunks/{PkToolShowCalendarEvent-cQpAAE3a.js → PkToolShowCalendarEvent-BEqn5iEb.js} +6 -6
- package/dist/_chunks/{PkToolShowCalendarEvent-cQpAAE3a.js.map → PkToolShowCalendarEvent-BEqn5iEb.js.map} +1 -1
- package/dist/_chunks/{PkToolShowComparison-Cu-zT8-Z.js → PkToolShowComparison-p34r0Hhd.js} +4 -4
- package/dist/_chunks/{PkToolShowComparison-Cu-zT8-Z.js.map → PkToolShowComparison-p34r0Hhd.js.map} +1 -1
- package/dist/_chunks/{PkToolShowContactForm-CqoSVvjG.js → PkToolShowContactForm-thS7c8iL.js} +18 -18
- package/dist/_chunks/{PkToolShowContactForm-CqoSVvjG.js.map → PkToolShowContactForm-thS7c8iL.js.map} +1 -1
- package/dist/_chunks/{PkToolShowEmail-oLGym0R9.js → PkToolShowEmail-Be8FvWjw.js} +4 -4
- package/dist/_chunks/{PkToolShowEmail-oLGym0R9.js.map → PkToolShowEmail-Be8FvWjw.js.map} +1 -1
- package/dist/_chunks/{PkToolShowImageGallery-CDXSL1Mg.js → PkToolShowImageGallery-DmJztS-Z.js} +5 -5
- package/dist/_chunks/{PkToolShowImageGallery-CDXSL1Mg.js.map → PkToolShowImageGallery-DmJztS-Z.js.map} +1 -1
- package/dist/_chunks/{PkToolShowLocation-BtRUdoEw.js → PkToolShowLocation-DOoLCHzS.js} +6 -6
- package/dist/_chunks/{PkToolShowLocation-BtRUdoEw.js.map → PkToolShowLocation-DOoLCHzS.js.map} +1 -1
- package/dist/_chunks/{PkToolShowMessage-tJQGRhce.js → PkToolShowMessage-DgeULbdQ.js} +4 -4
- package/dist/_chunks/{PkToolShowMessage-tJQGRhce.js.map → PkToolShowMessage-DgeULbdQ.js.map} +1 -1
- package/dist/_chunks/{PkToolShowMultipleChoice-CtVvdyDg.js → PkToolShowMultipleChoice-CpGyn_bZ.js} +3 -3
- package/dist/_chunks/{PkToolShowMultipleChoice-CtVvdyDg.js.map → PkToolShowMultipleChoice-CpGyn_bZ.js.map} +1 -1
- package/dist/_chunks/{PkToolShowProductList-D_k6CDdb.js → PkToolShowProductList-DEo7XogW.js} +4 -4
- package/dist/_chunks/{PkToolShowProductList-D_k6CDdb.js.map → PkToolShowProductList-DEo7XogW.js.map} +1 -1
- package/dist/_chunks/{PkToolShowQrCode-S1j_T8wQ.js → PkToolShowQrCode-UE4uSyvJ.js} +4 -4
- package/dist/_chunks/{PkToolShowQrCode-S1j_T8wQ.js.map → PkToolShowQrCode-UE4uSyvJ.js.map} +1 -1
- package/dist/_chunks/{PkToolShowSources-CroItMtG.js → PkToolShowSources-BMXftK6O.js} +7 -7
- package/dist/_chunks/PkToolShowSources-BMXftK6O.js.map +1 -0
- package/dist/_chunks/{PkToolShowSuggestedReply-BRa5Lpti.js → PkToolShowSuggestedReply-CPAnHI0c.js} +3 -3
- package/dist/_chunks/{PkToolShowSuggestedReply-BRa5Lpti.js.map → PkToolShowSuggestedReply-CPAnHI0c.js.map} +1 -1
- package/dist/_chunks/{PkToolShowWeather-CUpCJ8Nj.js → PkToolShowWeather-DcSUbzx0.js} +4 -4
- package/dist/_chunks/{PkToolShowWeather-CUpCJ8Nj.js.map → PkToolShowWeather-DcSUbzx0.js.map} +1 -1
- package/dist/_chunks/{PkToolShowWebPages-f-dHyxfD.js → PkToolShowWebPages-aH_GarEV.js} +5 -5
- package/dist/_chunks/{PkToolShowWebPages-f-dHyxfD.js.map → PkToolShowWebPages-aH_GarEV.js.map} +1 -1
- package/dist/_chunks/{PkUrl-CI17WkYu.js → PkUrl-BHD0_pal.js} +2 -2
- package/dist/_chunks/{PkUrl-CI17WkYu.js.map → PkUrl-BHD0_pal.js.map} +1 -1
- package/dist/_chunks/{VvCheckbox.es-BF8Mdg0O.js → VvCheckbox.es-ohF87NOe.js} +3 -3
- package/dist/_chunks/{VvCheckbox.es-BF8Mdg0O.js.map → VvCheckbox.es-ohF87NOe.js.map} +1 -1
- package/dist/_chunks/{VvCheckboxGroup.es-BJc8MmJ3.js → VvCheckboxGroup.es-DZCbyLN0.js} +4 -4
- package/dist/_chunks/{VvCheckboxGroup.es-BJc8MmJ3.js.map → VvCheckboxGroup.es-DZCbyLN0.js.map} +1 -1
- package/dist/_chunks/{VvCombobox.es-ILRHqAye.js → VvCombobox.es-YLPD7MpO.js} +6 -6
- package/dist/_chunks/{VvCombobox.es-ILRHqAye.js.map → VvCombobox.es-YLPD7MpO.js.map} +1 -1
- package/dist/_chunks/{VvInputText.es-CDnMeO26.js → VvInputText.es-DAnAXfBO.js} +7 -7
- package/dist/_chunks/{VvInputText.es-CDnMeO26.js.map → VvInputText.es-DAnAXfBO.js.map} +1 -1
- package/dist/_chunks/{VvRadio.es-C2p5vvAx.js → VvRadio.es-Do9oyNtV.js} +3 -3
- package/dist/_chunks/{VvRadio.es-C2p5vvAx.js.map → VvRadio.es-Do9oyNtV.js.map} +1 -1
- package/dist/_chunks/{VvRadioGroup.es-6GlWuDjY.js → VvRadioGroup.es-BHcqcJFC.js} +4 -4
- package/dist/_chunks/{VvRadioGroup.es-6GlWuDjY.js.map → VvRadioGroup.es-BHcqcJFC.js.map} +1 -1
- package/dist/_chunks/{VvSelect.es-i4lO9onq.js → VvSelect.es-CP_y02fy.js} +5 -5
- package/dist/_chunks/{VvSelect.es-i4lO9onq.js.map → VvSelect.es-CP_y02fy.js.map} +1 -1
- package/dist/_chunks/{VvTextarea.es-CGpiCS4S.js → VvTextarea.es-DetA_2DM.js} +6 -6
- package/dist/_chunks/{VvTextarea.es-CGpiCS4S.js.map → VvTextarea.es-DetA_2DM.js.map} +1 -1
- package/dist/_chunks/{dist-BTnzL-m0.js → dist-yqV26MWM.js} +4 -4
- package/dist/_chunks/{dist-BTnzL-m0.js.map → dist-yqV26MWM.js.map} +1 -1
- package/dist/_chunks/{esm-0nyRYwmP.js → esm-DLxNpT06.js} +7 -7
- package/dist/_chunks/{esm-0nyRYwmP.js.map → esm-DLxNpT06.js.map} +1 -1
- package/dist/_chunks/{floating-ui.vue-B5ZV-j8C.js → floating-ui.vue-tVPpNXUc.js} +3 -3
- package/dist/_chunks/{floating-ui.vue-B5ZV-j8C.js.map → floating-ui.vue-tVPpNXUc.js.map} +1 -1
- package/dist/_chunks/{iconify-C1EOwL90.js → iconify-y0w2FIJH.js} +3 -3
- package/dist/_chunks/{iconify-C1EOwL90.js.map → iconify-y0w2FIJH.js.map} +1 -1
- package/dist/_chunks/{index.es-CUjDCkXD.js → index.es-7fUi-rc0.js} +7 -7
- package/dist/_chunks/{index.es-CUjDCkXD.js.map → index.es-7fUi-rc0.js.map} +1 -1
- package/dist/_chunks/{src-C_wl-KYN.js → src-BfoQF6Z3.js} +2 -2
- package/dist/_chunks/{src-C_wl-KYN.js.map → src-BfoQF6Z3.js.map} +1 -1
- package/dist/_chunks/{useLightbox-CH1KeVqr.js → useLightbox-DL_oVBep.js} +3 -3
- package/dist/_chunks/{useLightbox-CH1KeVqr.js.map → useLightbox-DL_oVBep.js.map} +1 -1
- package/dist/_chunks/{vue-i18n-KvYvoek4.js → vue-i18n-DAH6nDTN.js} +3 -3
- package/dist/_chunks/{vue-i18n-KvYvoek4.js.map → vue-i18n-DAH6nDTN.js.map} +1 -1
- package/dist/_chunks/{vue.runtime.esm-bundler-BmggS4HU.js → vue.runtime.esm-bundler-Dq29dQrz.js} +16 -10
- package/dist/_chunks/vue.runtime.esm-bundler-Dq29dQrz.js.map +1 -0
- package/dist/ai-elements.es.js +65 -53
- package/dist/ai-elements.es.js.map +1 -1
- package/dist-vue/PkChatbot.js +1 -1
- package/dist-vue/PkChatbotFeedbackForm.js +1 -1
- package/dist-vue/PkChatbotMessages.js +1 -1
- package/dist-vue/PkChatbotViewChat.js +1 -1
- package/dist-vue/PkChatbotViewConversations.js +1 -1
- package/dist-vue/PkChatbotViewProfile.js +1 -1
- package/dist-vue/_chunks/{Media-CXQSoKqt.js → Media-kK7BnZGr.js} +2 -2
- package/dist-vue/_chunks/Media-kK7BnZGr.js.map +1 -0
- package/dist-vue/_chunks/{PkChatbot-DAzGc7al.js → PkChatbot-B9RSkQmJ.js} +6 -6
- package/dist-vue/_chunks/{PkChatbot-DAzGc7al.js.map → PkChatbot-B9RSkQmJ.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotFeedbackForm-DvUzirPP.js → PkChatbotFeedbackForm-lj9CHdhn.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotFeedbackForm-DvUzirPP.js.map → PkChatbotFeedbackForm-lj9CHdhn.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotMessages-dsjB0-26.js → PkChatbotMessages-DOeUT6YL.js} +4 -4
- package/dist-vue/_chunks/{PkChatbotMessages-dsjB0-26.js.map → PkChatbotMessages-DOeUT6YL.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewChat-CjoezIyz.js → PkChatbotViewChat-C2FuDayB.js} +5 -5
- package/dist-vue/_chunks/{PkChatbotViewChat-CjoezIyz.js.map → PkChatbotViewChat-C2FuDayB.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewConversations-DSQu6vY1.js → PkChatbotViewConversations-2xc0o-fO.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewConversations-DSQu6vY1.js.map → PkChatbotViewConversations-2xc0o-fO.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewProfile-BJJiaG9H.js → PkChatbotViewProfile-CoT1JnMk.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewProfile-BJJiaG9H.js.map → PkChatbotViewProfile-CoT1JnMk.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowContactForm-r_GgO-ZX.js → PkToolShowContactForm-5H4jfq1F.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowContactForm-r_GgO-ZX.js.map → PkToolShowContactForm-5H4jfq1F.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowSources-DK2DCvU3.js → PkToolShowSources-Dv0uuvqS.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowSources-DK2DCvU3.js.map → PkToolShowSources-Dv0uuvqS.js.map} +1 -1
- package/dist-vue/_chunks/{createChatbotApiClient-f86KwRcq.js → createChatbotApiClient-CvDRMmDa.js} +2 -2
- package/dist-vue/_chunks/{createChatbotApiClient-f86KwRcq.js.map → createChatbotApiClient-CvDRMmDa.js.map} +1 -1
- package/dist-vue/_chunks/{index.es-_14zrNZB.js → index.es-Dk_HaA08.js} +2 -2
- package/dist-vue/_chunks/{index.es-_14zrNZB.js.map → index.es-Dk_HaA08.js.map} +1 -1
- package/dist-vue/_chunks/{useChatbotStore-CJlkoNn7.js → useChatbotStore-DMDbzuub.js} +5 -5
- package/dist-vue/_chunks/{useChatbotStore-CJlkoNn7.js.map → useChatbotStore-DMDbzuub.js.map} +1 -1
- package/dist-vue/api.js +1 -1
- package/dist-vue/composables.js +2 -2
- package/dist-vue/index.js +18 -18
- package/dist-vue/index.js.map +1 -1
- package/dist-vue/packages/models/src/schema/AgentEndpoint.d.ts +1 -1
- package/dist-vue/packages/models/src/schema/constants.d.ts +3 -1
- package/package.json +2 -2
- package/dist/_chunks/PkToolShowSources-CroItMtG.js.map +0 -1
- package/dist/_chunks/vue.runtime.esm-bundler-BmggS4HU.js.map +0 -1
- package/dist-vue/_chunks/Media-CXQSoKqt.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $ as e, C as t, E as n, Gt as r, O as i, Vt as a, _ as o, v as s, w as c, x as l, yt as u, z as d } from "./vue.runtime.esm-bundler-
|
|
2
|
-
import { c as f, n as p, o as m, r as h, s as g } from "./index.es-
|
|
3
|
-
import { i as _ } from "./dist-
|
|
1
|
+
import { $ as e, C as t, E as n, Gt as r, O as i, Vt as a, _ as o, v as s, w as c, x as l, yt as u, z as d } from "./vue.runtime.esm-bundler-Dq29dQrz.js";
|
|
2
|
+
import { c as f, n as p, o as m, r as h, s as g } from "./index.es-7fUi-rc0.js";
|
|
3
|
+
import { i as _ } from "./dist-yqV26MWM.js";
|
|
4
4
|
//#region ../../packages/components/src/chat/PkToolShowEmail.vue?vue&type=script&setup=true&lang.ts
|
|
5
5
|
var v = { class: "border border-surface-3 rounded-xl w-full overflow-hidden" }, y = { class: "px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8" }, b = { class: "font-bold" }, x = { class: "border-b border-surface-3 p-sm" }, S = { class: "text-12 text-word-4 mb-4" }, C = { class: "text-word-2 font-semibold" }, w = { class: "p-sm" }, T = { class: "text-12 text-word-4 mb-4" }, E = { class: "text-word-2 whitespace-pre-wrap break-words" }, D = /* @__PURE__ */ n({
|
|
6
6
|
__name: "PkToolShowEmail",
|
|
@@ -84,4 +84,4 @@ var v = { class: "border border-surface-3 rounded-xl w-full overflow-hidden" },
|
|
|
84
84
|
//#endregion
|
|
85
85
|
export { D as default };
|
|
86
86
|
|
|
87
|
-
//# sourceMappingURL=PkToolShowEmail-
|
|
87
|
+
//# sourceMappingURL=PkToolShowEmail-Be8FvWjw.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PkToolShowEmail-oLGym0R9.js","names":["$t"],"sources":["../../../../packages/components/src/chat/PkToolShowEmail.vue","../../../../packages/components/src/chat/PkToolShowEmail.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed } from 'vue'\n import { useClipboard } from '@vueuse/core'\n\n const props = defineProps<{\n part: unknown\n }>()\n\n const { copy, copied } = useClipboard()\n\n const toolPart = computed(() => {\n const part = props.part as {\n input?: {\n subject: string\n body: string\n }\n }\n return part\n })\n const openInMailApp = () => {\n if (!toolPart.value.input) {\n return\n }\n const mailtoLink = `mailto:?subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(mailtoLink)\n }\n\n const openInOutlook = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://outlook.office.com/mail/deeplink/compose?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInGmail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://mail.google.com/mail/u/0/?tf=cm&to=&su=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInYahooMail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://compose.mail.yahoo.com/?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n</script>\n\n<template>\n <div class=\"border border-surface-3 rounded-xl w-full overflow-hidden\">\n <div\n class=\"px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8\">\n <VvIcon name=\"ri:mail-line\" class=\"text-16\" />\n <strong class=\"font-bold\">\n {{ $t('label.email') }}\n </strong>\n <VvButtonGroup modifiers=\"compact\" class=\"ml-auto shrink-0\">\n <VvButton\n modifiers=\"action-quiet-small\"\n :icon=\"copied ? 'ri:check-line' : 'ri:file-copy-line'\"\n :label=\"copied ? $t('action.copied') : $t('action.copy')\"\n @click=\"\n copy(\n `${toolPart?.input?.subject}\\n\\n${toolPart?.input?.body}`,\n )\n \" />\n <VvDropdown\n v-bind=\"{\n placement: 'bottom-end',\n modifiers: 'menu',\n flip: true,\n offset: 3,\n }\">\n <VvButton\n icon=\"ri:mail-send-line\"\n modifiers=\"action-quiet-small\"\n :label=\"$t('action.send')\" />\n <template #items>\n <VvDropdownAction @click=\"openInOutlook\">\n <VvIcon name=\"mdi:outlook\" />\n {{ $t('action.openInOutlook') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInGmail\">\n <VvIcon name=\"mdi:gmail\" />\n {{ $t('action.openInGmail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInYahooMail\">\n <VvIcon name=\"mdi:yahoo\" />\n {{ $t('action.openInYahooMail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInMailApp\">\n <VvIcon name=\"ri:mail-open-line\" />\n {{ $t('action.openInMailApp') }}\n </VvDropdownAction>\n </template>\n </VvDropdown>\n </VvButtonGroup>\n </div>\n <div class=\"border-b border-surface-3 p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.subject') }}\n </div>\n <div class=\"text-word-2 font-semibold\">\n {{ toolPart?.input?.subject }}\n </div>\n </div>\n <div class=\"p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.body') }}\n </div>\n <pre class=\"text-word-2 whitespace-pre-wrap break-words\">{{\n toolPart?.input?.body\n }}</pre>\n </div>\n </div>\n</template>\n","<script setup lang=\"ts\">\n import { computed } from 'vue'\n import { useClipboard } from '@vueuse/core'\n\n const props = defineProps<{\n part: unknown\n }>()\n\n const { copy, copied } = useClipboard()\n\n const toolPart = computed(() => {\n const part = props.part as {\n input?: {\n subject: string\n body: string\n }\n }\n return part\n })\n const openInMailApp = () => {\n if (!toolPart.value.input) {\n return\n }\n const mailtoLink = `mailto:?subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(mailtoLink)\n }\n\n const openInOutlook = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://outlook.office.com/mail/deeplink/compose?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInGmail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://mail.google.com/mail/u/0/?tf=cm&to=&su=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInYahooMail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://compose.mail.yahoo.com/?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n</script>\n\n<template>\n <div class=\"border border-surface-3 rounded-xl w-full overflow-hidden\">\n <div\n class=\"px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8\">\n <VvIcon name=\"ri:mail-line\" class=\"text-16\" />\n <strong class=\"font-bold\">\n {{ $t('label.email') }}\n </strong>\n <VvButtonGroup modifiers=\"compact\" class=\"ml-auto shrink-0\">\n <VvButton\n modifiers=\"action-quiet-small\"\n :icon=\"copied ? 'ri:check-line' : 'ri:file-copy-line'\"\n :label=\"copied ? $t('action.copied') : $t('action.copy')\"\n @click=\"\n copy(\n `${toolPart?.input?.subject}\\n\\n${toolPart?.input?.body}`,\n )\n \" />\n <VvDropdown\n v-bind=\"{\n placement: 'bottom-end',\n modifiers: 'menu',\n flip: true,\n offset: 3,\n }\">\n <VvButton\n icon=\"ri:mail-send-line\"\n modifiers=\"action-quiet-small\"\n :label=\"$t('action.send')\" />\n <template #items>\n <VvDropdownAction @click=\"openInOutlook\">\n <VvIcon name=\"mdi:outlook\" />\n {{ $t('action.openInOutlook') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInGmail\">\n <VvIcon name=\"mdi:gmail\" />\n {{ $t('action.openInGmail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInYahooMail\">\n <VvIcon name=\"mdi:yahoo\" />\n {{ $t('action.openInYahooMail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInMailApp\">\n <VvIcon name=\"ri:mail-open-line\" />\n {{ $t('action.openInMailApp') }}\n </VvDropdownAction>\n </template>\n </VvDropdown>\n </VvButtonGroup>\n </div>\n <div class=\"border-b border-surface-3 p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.subject') }}\n </div>\n <div class=\"text-word-2 font-semibold\">\n {{ toolPart?.input?.subject }}\n </div>\n </div>\n <div class=\"p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.body') }}\n </div>\n <pre class=\"text-word-2 whitespace-pre-wrap break-words\">{{\n toolPart?.input?.body\n }}</pre>\n </div>\n </div>\n</template>\n"],"mappings":";;;;;;;;EAII,IAAM,IAAQ,GAIR,EAAE,SAAM,cAAW,GAAa,EAEhC,IAAW,QACA,EAAM,KAOtB,EACK,UAAsB;AACxB,OAAI,CAAC,EAAS,MAAM,MAChB;GAEJ,IAAM,IAAa,mBAAmB,mBAClC,EAAS,MAAM,MAAM,QACxB,CAAC,QAAQ,mBAAmB,EAAS,MAAM,MAAM,KAAK;AACvD,UAAO,KAAK,EAAU;KAGpB,UAAsB;AACxB,OAAI,CAAC,EAAS,MAAM,MAChB;GAEJ,IAAM,IAAM,gEAAgE,mBACxE,EAAS,MAAM,MAAM,QACxB,CAAC,QAAQ,mBAAmB,EAAS,MAAM,MAAM,KAAK;AACvD,UAAO,KAAK,GAAK,SAAQ;KAGvB,UAAoB;AACtB,OAAI,CAAC,EAAS,MAAM,MAChB;GAEJ,IAAM,IAAM,kDAAkD,mBAC1D,EAAS,MAAM,MAAM,QACxB,CAAC,QAAQ,mBAAmB,EAAS,MAAM,MAAM,KAAK;AACvD,UAAO,KAAK,GAAK,SAAQ;KAGvB,UAAwB;AAC1B,OAAI,CAAC,EAAS,MAAM,MAChB;GAEJ,IAAM,IAAM,+CAA+C,mBACvD,EAAS,MAAM,MAAM,QACxB,CAAC,QAAQ,mBAAmB,EAAS,MAAM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AA,EAAA,EAAG,MACnC,EAAGA,EAAAA,GAAE,uBAAA,CAAA,EAAA,EAAA,CAAA,CAAA;;;;wBAhBoB,CAHjC,EAGiC,GAAA;QAF7B,MAAK;QACL,WAAU;QACT,OAAOA,EAAAA,GAAE,cAAA;;;;;;;IAsB1B,EAOM,OAPN,GAOM,CANF,EAEM,OAFN,GAEM,EADCA,EAAAA,GAAE,gBAAA,CAAA,EAAA,EAAA,EAET,EAEM,OAFN,GAEM,EADC,EAAA,OAAU,OAAO,QAAO,EAAA,EAAA,CAAA,CAAA;IAGnC,EAOM,OAPN,GAOM,CANF,EAEM,OAFN,GAEM,EADCA,EAAAA,GAAE,aAAA,CAAA,EAAA,EAAA,EAET,EAEQ,OAFR,GAEQ,EADJ,EAAA,OAAU,OAAO,KAAI,EAAA,EAAA,CAAA,CAAA"}
|
|
1
|
+
{"version":3,"file":"PkToolShowEmail-Be8FvWjw.js","names":["$t"],"sources":["../../../../packages/components/src/chat/PkToolShowEmail.vue","../../../../packages/components/src/chat/PkToolShowEmail.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed } from 'vue'\n import { useClipboard } from '@vueuse/core'\n\n const props = defineProps<{\n part: unknown\n }>()\n\n const { copy, copied } = useClipboard()\n\n const toolPart = computed(() => {\n const part = props.part as {\n input?: {\n subject: string\n body: string\n }\n }\n return part\n })\n const openInMailApp = () => {\n if (!toolPart.value.input) {\n return\n }\n const mailtoLink = `mailto:?subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(mailtoLink)\n }\n\n const openInOutlook = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://outlook.office.com/mail/deeplink/compose?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInGmail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://mail.google.com/mail/u/0/?tf=cm&to=&su=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInYahooMail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://compose.mail.yahoo.com/?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n</script>\n\n<template>\n <div class=\"border border-surface-3 rounded-xl w-full overflow-hidden\">\n <div\n class=\"px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8\">\n <VvIcon name=\"ri:mail-line\" class=\"text-16\" />\n <strong class=\"font-bold\">\n {{ $t('label.email') }}\n </strong>\n <VvButtonGroup modifiers=\"compact\" class=\"ml-auto shrink-0\">\n <VvButton\n modifiers=\"action-quiet-small\"\n :icon=\"copied ? 'ri:check-line' : 'ri:file-copy-line'\"\n :label=\"copied ? $t('action.copied') : $t('action.copy')\"\n @click=\"\n copy(\n `${toolPart?.input?.subject}\\n\\n${toolPart?.input?.body}`,\n )\n \" />\n <VvDropdown\n v-bind=\"{\n placement: 'bottom-end',\n modifiers: 'menu',\n flip: true,\n offset: 3,\n }\">\n <VvButton\n icon=\"ri:mail-send-line\"\n modifiers=\"action-quiet-small\"\n :label=\"$t('action.send')\" />\n <template #items>\n <VvDropdownAction @click=\"openInOutlook\">\n <VvIcon name=\"mdi:outlook\" />\n {{ $t('action.openInOutlook') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInGmail\">\n <VvIcon name=\"mdi:gmail\" />\n {{ $t('action.openInGmail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInYahooMail\">\n <VvIcon name=\"mdi:yahoo\" />\n {{ $t('action.openInYahooMail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInMailApp\">\n <VvIcon name=\"ri:mail-open-line\" />\n {{ $t('action.openInMailApp') }}\n </VvDropdownAction>\n </template>\n </VvDropdown>\n </VvButtonGroup>\n </div>\n <div class=\"border-b border-surface-3 p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.subject') }}\n </div>\n <div class=\"text-word-2 font-semibold\">\n {{ toolPart?.input?.subject }}\n </div>\n </div>\n <div class=\"p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.body') }}\n </div>\n <pre class=\"text-word-2 whitespace-pre-wrap break-words\">{{\n toolPart?.input?.body\n }}</pre>\n </div>\n </div>\n</template>\n","<script setup lang=\"ts\">\n import { computed } from 'vue'\n import { useClipboard } from '@vueuse/core'\n\n const props = defineProps<{\n part: unknown\n }>()\n\n const { copy, copied } = useClipboard()\n\n const toolPart = computed(() => {\n const part = props.part as {\n input?: {\n subject: string\n body: string\n }\n }\n return part\n })\n const openInMailApp = () => {\n if (!toolPart.value.input) {\n return\n }\n const mailtoLink = `mailto:?subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(mailtoLink)\n }\n\n const openInOutlook = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://outlook.office.com/mail/deeplink/compose?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInGmail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://mail.google.com/mail/u/0/?tf=cm&to=&su=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n\n const openInYahooMail = () => {\n if (!toolPart.value.input) {\n return\n }\n const url = `https://compose.mail.yahoo.com/?to=&subject=${encodeURIComponent(\n toolPart.value.input.subject,\n )}&body=${encodeURIComponent(toolPart.value.input.body)}`\n window.open(url, '_blank')\n }\n</script>\n\n<template>\n <div class=\"border border-surface-3 rounded-xl w-full overflow-hidden\">\n <div\n class=\"px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8\">\n <VvIcon name=\"ri:mail-line\" class=\"text-16\" />\n <strong class=\"font-bold\">\n {{ $t('label.email') }}\n </strong>\n <VvButtonGroup modifiers=\"compact\" class=\"ml-auto shrink-0\">\n <VvButton\n modifiers=\"action-quiet-small\"\n :icon=\"copied ? 'ri:check-line' : 'ri:file-copy-line'\"\n :label=\"copied ? $t('action.copied') : $t('action.copy')\"\n @click=\"\n copy(\n `${toolPart?.input?.subject}\\n\\n${toolPart?.input?.body}`,\n )\n \" />\n <VvDropdown\n v-bind=\"{\n placement: 'bottom-end',\n modifiers: 'menu',\n flip: true,\n offset: 3,\n }\">\n <VvButton\n icon=\"ri:mail-send-line\"\n modifiers=\"action-quiet-small\"\n :label=\"$t('action.send')\" />\n <template #items>\n <VvDropdownAction @click=\"openInOutlook\">\n <VvIcon name=\"mdi:outlook\" />\n {{ $t('action.openInOutlook') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInGmail\">\n <VvIcon name=\"mdi:gmail\" />\n {{ $t('action.openInGmail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInYahooMail\">\n <VvIcon name=\"mdi:yahoo\" />\n {{ $t('action.openInYahooMail') }}\n </VvDropdownAction>\n <VvDropdownAction @click=\"openInMailApp\">\n <VvIcon name=\"ri:mail-open-line\" />\n {{ $t('action.openInMailApp') }}\n </VvDropdownAction>\n </template>\n </VvDropdown>\n </VvButtonGroup>\n </div>\n <div class=\"border-b border-surface-3 p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.subject') }}\n </div>\n <div class=\"text-word-2 font-semibold\">\n {{ toolPart?.input?.subject }}\n </div>\n </div>\n <div class=\"p-sm\">\n <div class=\"text-12 text-word-4 mb-4\">\n {{ $t('label.body') }}\n </div>\n <pre class=\"text-word-2 whitespace-pre-wrap break-words\">{{\n toolPart?.input?.body\n }}</pre>\n </div>\n </div>\n</template>\n"],"mappings":";;;;;;;;EAII,IAAM,IAAQ,GAIR,EAAE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AAI,EAAA,EAAA,CAAA,CAAA"}
|
package/dist/_chunks/{PkToolShowImageGallery-CDXSL1Mg.js → PkToolShowImageGallery-DmJztS-Z.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Bt as e, E as t, Gt as n, L as r, V as i, _ as a, b as o, ft as s, h as c, v as l, w as u, x as d, yt as f, z as p } from "./vue.runtime.esm-bundler-
|
|
2
|
-
import { o as m } from "./index.es-
|
|
3
|
-
import { n as h } from "./src-
|
|
4
|
-
import { n as g, t as _ } from "./useLightbox-
|
|
1
|
+
import { Bt as e, E as t, Gt as n, L as r, V as i, _ as a, b as o, ft as s, h as c, v as l, w as u, x as d, yt as f, z as p } from "./vue.runtime.esm-bundler-Dq29dQrz.js";
|
|
2
|
+
import { o as m } from "./index.es-7fUi-rc0.js";
|
|
3
|
+
import { n as h } from "./src-BfoQF6Z3.js";
|
|
4
|
+
import { n as g, t as _ } from "./useLightbox-DL_oVBep.js";
|
|
5
5
|
//#region ../../packages/components/src/chat/PkToolShowImageGallery.vue?vue&type=script&setup=true&lang.ts
|
|
6
6
|
var v = {
|
|
7
7
|
key: 0,
|
|
@@ -60,4 +60,4 @@ var v = {
|
|
|
60
60
|
//#endregion
|
|
61
61
|
export { T as default };
|
|
62
62
|
|
|
63
|
-
//# sourceMappingURL=PkToolShowImageGallery-
|
|
63
|
+
//# sourceMappingURL=PkToolShowImageGallery-DmJztS-Z.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PkToolShowImageGallery-
|
|
1
|
+
{"version":3,"file":"PkToolShowImageGallery-DmJztS-Z.js","names":["$t"],"sources":["../../../../packages/components/src/chat/PkToolShowImageGallery.vue","../../../../packages/components/src/chat/PkToolShowImageGallery.vue"],"sourcesContent":["<script setup lang=\"ts\">\n import { computed, ref, onMounted } from 'vue'\n import { isSameSite } from 'utils'\n import { useLightbox, useImageSizes } from '../composables/useLightbox'\n\n const props = defineProps<{\n part: unknown\n }>()\n\n const toolPart = computed(() => {\n const part = props.part as {\n input?: {\n images: Array<{\n url: string\n caption?: string\n alt?: string\n }>\n }\n }\n return part\n })\n\n const galleryRef = ref<HTMLElement>()\n const { preload, getSize } = useImageSizes()\n\n const images = computed(() => toolPart.value.input?.images ?? [])\n\n const hiddenCount = computed(() =>\n images.value.length > 6 ? images.value.length - 5 : 0,\n )\n\n const gridCols = computed(() => {\n const count = images.value.length\n if (count === 1) {\n return 'grid-cols-1'\n }\n if (count === 2) {\n return 'grid-cols-2'\n }\n return 'grid-cols-3'\n })\n\n const { init } = useLightbox({ gallery: galleryRef })\n\n onMounted(async () => {\n preload(images.value)\n await init()\n })\n</script>\n\n<template>\n <div\n v-if=\"images.length\"\n class=\"border border-surface-3 rounded-xl w-full overflow-hidden\">\n <div\n class=\"px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8 min-h-40\">\n <VvIcon name=\"ri:image-line\" class=\"text-16\" />\n <strong class=\"font-bold\">\n {{ $t('label.gallery', { count: images.length }) }}\n </strong>\n </div>\n <div class=\"p-sm\">\n <div ref=\"galleryRef\" class=\"grid gap-8\" :class=\"gridCols\">\n <a\n v-for=\"(image, index) in images\"\n :key=\"image.url\"\n :href=\"image.url\"\n :data-pswp-src=\"image.url\"\n :data-pswp-width=\"getSize(image.url).width\"\n :data-pswp-height=\"getSize(image.url).height\"\n :data-pswp-caption=\"image.caption ?? image.alt ?? ''\"\n :data-cropped=\"true\"\n class=\"relative block aspect-square overflow-hidden rounded-lg cursor-pointer group\"\n :class=\"index >= 5 && hiddenCount > 0 ? 'hidden' : ''\"\n :title=\"image.caption ?? image.alt ?? ''\"\n :target=\"isSameSite(image.url) ? undefined : '_blank'\"\n :rel=\"\n isSameSite(image.url)\n ? undefined\n : 'noopener noreferrer'\n \">\n <img\n :src=\"image.url\"\n :alt=\"image.alt ?? image.caption ?? ''\"\n class=\"w-full h-full object-cover transition-opacity group-hover:opacity-80\" />\n <!-- +N overlay on last visible thumbnail when there are more hidden images -->\n <div\n v-if=\"hiddenCount > 0 && index === 4\"\n class=\"absolute inset-0 bg-black/50 flex items-center justify-center text-white font-semibold text-16 rounded-lg\">\n +{{ hiddenCount }}\n </div>\n </a>\n </div>\n </div>\n </div>\n</template>\n","<script setup lang=\"ts\">\n import { computed, ref, onMounted } from 'vue'\n import { isSameSite } from 'utils'\n import { useLightbox, useImageSizes } from '../composables/useLightbox'\n\n const props = defineProps<{\n part: unknown\n }>()\n\n const toolPart = computed(() => {\n const part = props.part as {\n input?: {\n images: Array<{\n url: string\n caption?: string\n alt?: string\n }>\n }\n }\n return part\n })\n\n const galleryRef = ref<HTMLElement>()\n const { preload, getSize } = useImageSizes()\n\n const images = computed(() => toolPart.value.input?.images ?? [])\n\n const hiddenCount = computed(() =>\n images.value.length > 6 ? images.value.length - 5 : 0,\n )\n\n const gridCols = computed(() => {\n const count = images.value.length\n if (count === 1) {\n return 'grid-cols-1'\n }\n if (count === 2) {\n return 'grid-cols-2'\n }\n return 'grid-cols-3'\n })\n\n const { init } = useLightbox({ gallery: galleryRef })\n\n onMounted(async () => {\n preload(images.value)\n await init()\n })\n</script>\n\n<template>\n <div\n v-if=\"images.length\"\n class=\"border border-surface-3 rounded-xl w-full overflow-hidden\">\n <div\n class=\"px-sm py-6 bg-surface-1 text-12 border-b border-surface-3 text-word-3 flex items-center gap-8 min-h-40\">\n <VvIcon name=\"ri:image-line\" class=\"text-16\" />\n <strong class=\"font-bold\">\n {{ $t('label.gallery', { count: images.length }) }}\n </strong>\n </div>\n <div class=\"p-sm\">\n <div ref=\"galleryRef\" class=\"grid gap-8\" :class=\"gridCols\">\n <a\n v-for=\"(image, index) in images\"\n :key=\"image.url\"\n :href=\"image.url\"\n :data-pswp-src=\"image.url\"\n :data-pswp-width=\"getSize(image.url).width\"\n :data-pswp-height=\"getSize(image.url).height\"\n :data-pswp-caption=\"image.caption ?? image.alt ?? ''\"\n :data-cropped=\"true\"\n class=\"relative block aspect-square overflow-hidden rounded-lg cursor-pointer group\"\n :class=\"index >= 5 && hiddenCount > 0 ? 'hidden' : ''\"\n :title=\"image.caption ?? image.alt ?? ''\"\n :target=\"isSameSite(image.url) ? undefined : '_blank'\"\n :rel=\"\n isSameSite(image.url)\n ? undefined\n : 'noopener noreferrer'\n \">\n <img\n :src=\"image.url\"\n :alt=\"image.alt ?? image.caption ?? ''\"\n class=\"w-full h-full object-cover transition-opacity group-hover:opacity-80\" />\n <!-- +N overlay on last visible thumbnail when there are more hidden images -->\n <div\n v-if=\"hiddenCount > 0 && index === 4\"\n class=\"absolute inset-0 bg-black/50 flex items-center justify-center text-white font-semibold text-16 rounded-lg\">\n +{{ hiddenCount }}\n </div>\n </a>\n </div>\n </div>\n </div>\n</template>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;EAKI,IAAM,IAAQ,GAIR,IAAW,QACA,EAAM,KAUtB,EAEK,IAAa,GAAiB,EAC9B,EAAE,YAAS,eAAY,GAAc,EAErC,IAAS,QAAe,EAAS,MAAM,OAAO,UAAU,EAAE,CAAA,EAE1D,IAAc,QAChB,EAAO,MAAM,SAAS,IAAI,EAAO,MAAM,SAAS,IAAI,EACxD,EAEM,IAAW,QAAe;GAC5B,IAAM,IAAQ,EAAO,MAAM;AAO3B,UANI,MAAU,IACH,gBAEP,MAAU,IACH,gBAEJ;IACV,EAEK,EAAE,YAAS,EAAY,EAAE,SAAS,GAAY,CAAA;SAEpD,EAAU,YAAY;AAElB,GADA,EAAQ,EAAO,MAAK,EACpB,MAAM,GAAK;IACd;;UAKS,EAAA,MAAO,UAAA,GAAA,EADjB,EA2CM,OA3CN,GA2CM,CAxCF,EAMM,OANN,GAMM,CAJF,EAA+C,GAAA;IAAvC,MAAK;IAAgB,OAAM;OACnC,EAES,UAFT,GAES,EADFA,EAAAA,GAAE,iBAAA,EAAA,OAA2B,EAAA,MAAO,QAAM,CAAA,CAAA,EAAA,EAAA,CAAA,CAAA,EAGrD,EAgCM,OAhCN,GAgCM,CA/BF,EA8BM,OAAA;aA9BG;IAAJ,KAAI;IAAa,OAAK,EAAA,CAAC,cAAqB,EAAA,MAAQ,CAAA;eACrD,EA4BI,GAAA,MAAA,EA3ByB,EAAA,QAAjB,GAAO,YADnB,EA4BI,KAAA;IA1BC,KAAK,EAAM;IACX,MAAM,EAAM;IACZ,iBAAe,EAAM;IACrB,mBAAiB,EAAA,EAAO,CAAC,EAAM,IAAG,CAAE;IACpC,oBAAkB,EAAA,EAAO,CAAC,EAAM,IAAG,CAAE;IACrC,qBAAmB,EAAM,WAAW,EAAM,OAAG;IAC7C,gBAAc;IACf,OAAK,EAAA,CAAC,gFACE,KAAK,KAAS,EAAA,QAAW,IAAA,WAAA,GAAA,CAAA;IAChC,OAAO,EAAM,WAAW,EAAM,OAAG;IACjC,QAAQ,EAAA,EAAU,CAAC,EAAM,IAAG,GAAI,KAAA,IAAS;IACzC,KAA8B,EAAA,EAAU,CAAC,EAAM,IAAG,GAAgC,KAAA,IAAA;OAKnF,EAGmF,OAAA;IAF9E,KAAK,EAAM;IACX,KAAK,EAAM,OAAO,EAAM,WAAO;IAChC,OAAM;mBAGA,EAAA,QAAW,KAAQ,MAAK,KAAA,GAAA,EADlC,EAIM,OAJN,GAEsH,OACjH,EAAG,EAAA,MAAW,EAAA,EAAA,IAAA,EAAA,IAAA,GAAA,CAAA,EAAA,IAAA,EAAA"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { r as e } from "./rolldown-runtime-DHui2AQb.js";
|
|
2
|
-
import { $ as t, B as n, C as r, D as i, E as a, F as o, Gt as s, H as c, Ht as l, I as u, K as d, L as f, M as p, O as m, Q as h, R as g, Vt as ee, Y as te, Z as ne, _ as re, b as ie, ct as ae, ft as _, j as oe, v as se, w as v, x as ce, yt as y, z as le } from "./vue.runtime.esm-bundler-
|
|
3
|
-
import { c as ue, n as de, o as fe, r as pe, s as me } from "./index.es-
|
|
4
|
-
import { g as he, h as ge } from "./src-
|
|
5
|
-
import { i as _e } from "./dist-
|
|
2
|
+
import { $ as t, B as n, C as r, D as i, E as a, F as o, Gt as s, H as c, Ht as l, I as u, K as d, L as f, M as p, O as m, Q as h, R as g, Vt as ee, Y as te, Z as ne, _ as re, b as ie, ct as ae, ft as _, j as oe, v as se, w as v, x as ce, yt as y, z as le } from "./vue.runtime.esm-bundler-Dq29dQrz.js";
|
|
3
|
+
import { c as ue, n as de, o as fe, r as pe, s as me } from "./index.es-7fUi-rc0.js";
|
|
4
|
+
import { g as he, h as ge } from "./src-BfoQF6Z3.js";
|
|
5
|
+
import { i as _e } from "./dist-yqV26MWM.js";
|
|
6
6
|
import { t as ve } from "./marker-icon-ZAZ5tZ1p.js";
|
|
7
7
|
import { t as ye } from "./marker-icon-2x-BVjf1WKG.js";
|
|
8
8
|
import { t as be } from "./marker-shadow-DjWZKKzZ.js";
|
|
@@ -4319,7 +4319,7 @@ function tr() {
|
|
|
4319
4319
|
throw Error("Unable to locate global object.");
|
|
4320
4320
|
}
|
|
4321
4321
|
//#endregion
|
|
4322
|
-
//#region ../../node_modules/.pnpm/@maxel01+vue-leaflet@1.0.0-beta.7_leaflet@2.0.0-alpha_vue@3.5.
|
|
4322
|
+
//#region ../../node_modules/.pnpm/@maxel01+vue-leaflet@1.0.0-beta.7_leaflet@2.0.0-alpha_vue@3.5.34_typescript@6.0.3_/node_modules/@maxel01/vue-leaflet/dist/vue-leaflet.es.js
|
|
4323
4323
|
var nr = /* @__PURE__ */ Symbol("getMapObject"), rr = /* @__PURE__ */ Symbol("addLayer"), ir = /* @__PURE__ */ Symbol("removeLayer"), ar = /* @__PURE__ */ Symbol("registerControl"), or = /* @__PURE__ */ Symbol("registerLayerControl"), sr = /* @__PURE__ */ Symbol("canSetParentHtml"), cr = /* @__PURE__ */ Symbol("setParentHtml"), lr = /* @__PURE__ */ Symbol("setIcon"), ur = /* @__PURE__ */ Symbol("bindPopup"), dr = /* @__PURE__ */ Symbol("bindTooltip"), fr = /* @__PURE__ */ Symbol("unbindPopup"), pr = /* @__PURE__ */ Symbol("unbindTooltip"), mr = { experimental: {
|
|
4324
4324
|
useResetWebpackIcon: !0,
|
|
4325
4325
|
skipUndefinedProps: !1
|
|
@@ -4996,4 +4996,4 @@ var ti = {
|
|
|
4996
4996
|
//#endregion
|
|
4997
4997
|
export { ui as n, di as t };
|
|
4998
4998
|
|
|
4999
|
-
//# sourceMappingURL=PkToolShowLocation-
|
|
4999
|
+
//# sourceMappingURL=PkToolShowLocation-DOoLCHzS.js.map
|