@adyen/bento-vue3 1.28.0 → 1.29.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/@types/components.d.ts +4 -0
- package/dist/@types/packages/core/src/types/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/{internal/avatar → avatar}/avatar.vue.d.ts +4 -4
- package/dist/@types/packages/vue2/src/components/{avatar-image → avatar/components/avatar-image}/avatar-image.vue.d.ts +15 -4
- package/dist/@types/packages/vue2/src/components/button/components/loading-button/index.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/button/components/loading-button/loading-button.vue.d.ts +2 -3
- package/dist/@types/packages/vue2/src/components/checkbox/checkbox.vue.d.ts +4 -4
- package/dist/@types/packages/vue2/src/components/checkbox/components/checkbox-group/checkbox-group.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.vue.d.ts +16 -0
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-small-textbox/dropdown-small-textbox.vue.d.ts +10 -1
- package/dist/@types/packages/vue2/src/components/filter-bar/components/all-filters-modal/all-filters-modal.vue.d.ts +6 -2
- package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter/base-filter.vue.d.ts +6 -4
- package/dist/@types/packages/vue2/src/components/filter-bar/components/input-filter/input-filter.vue.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/input-field/input-field.types.d.ts +3 -0
- package/dist/@types/packages/vue2/src/components/input-field/input-field.vue.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/inspector/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/inspector/inspector.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/inspector/inspector.types.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/inspector/inspector.vue.d.ts +110 -0
- package/dist/@types/packages/vue2/src/components/internal/index.d.ts +0 -1
- package/dist/@types/packages/vue2/src/components/popover/popover.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/radio-group/components/radio-button/radio-button.vue.d.ts +4 -4
- package/dist/@types/packages/vue2/src/components/radio-group/radio-group.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/search-bar/search-bar.vue.d.ts +12 -1
- package/dist/@types/packages/vue2/src/components/secondary-nav/secondary-nav.vue.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/segmented-control/segmented-control.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/stepper/stepper.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/tag/tag.vue.d.ts +4 -4
- package/dist/@types/packages/vue2/src/components/textarea/textarea.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/timeline/components/timeline-item/timeline-item.vue.d.ts +7 -7
- package/dist/@types/packages/vue2/src/components/tutorial/components/tutorial-popover/tutorial-popover.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/types/index.d.ts +1 -1
- package/dist/@types/packages/vue2/src/types/listbox.d.ts +1 -1
- package/dist/action-bar.js +1 -1
- package/dist/assets/accordion-item.css +1 -1
- package/dist/assets/action-bar.css +1 -1
- package/dist/assets/avatar.css +1 -0
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/card.css +1 -1
- package/dist/assets/code-snippet.css +1 -1
- package/dist/assets/data-grid.css +1 -1
- package/dist/assets/dialog-page.css +1 -1
- package/dist/assets/dropdown-default-textbox.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/error-message.css +1 -1
- package/dist/assets/filter-bar.css +1 -1
- package/dist/assets/input-field.css +1 -1
- package/dist/assets/inspector.css +1 -0
- package/dist/assets/listbox-option-tag.css +1 -1
- package/dist/assets/loading-button.css +1 -1
- package/dist/assets/menu.css +1 -1
- package/dist/assets/modal-fullscreen.css +1 -1
- package/dist/assets/popover.css +1 -1
- package/dist/assets/radio-group.css +1 -1
- package/dist/assets/search-bar.css +1 -1
- package/dist/assets/secondary-nav.css +1 -1
- package/dist/assets/segmented-control.css +1 -1
- package/dist/assets/selection-card-group.css +1 -1
- package/dist/assets/sidepanel.css +1 -1
- package/dist/assets/structured-list-item.css +1 -1
- package/dist/assets/textarea.css +1 -1
- package/dist/assets/timeline-item.css +1 -1
- package/dist/avatar.js +5 -0
- package/dist/avatar.js.map +1 -0
- package/dist/button.js +2 -2
- package/dist/card.js +1 -1
- package/dist/checkbox.js +2 -2
- package/dist/chunks/{action-bar.BvAtk-jI.js → action-bar.UcSSukRr.js} +5 -5
- package/dist/chunks/{action-bar.BvAtk-jI.js.map → action-bar.UcSSukRr.js.map} +1 -1
- package/dist/chunks/avatar.IHx0kN0u.js +94 -0
- package/dist/chunks/avatar.IHx0kN0u.js.map +1 -0
- package/dist/chunks/{base-modal.BgYlnM_Q.js → base-modal.CY-t-QYh.js} +2 -2
- package/dist/chunks/{base-modal.BgYlnM_Q.js.map → base-modal.CY-t-QYh.js.map} +1 -1
- package/dist/chunks/{button-actions-with-menu.C14zvgVo.js → button-actions-with-menu.Dnyh1m51.js} +4 -4
- package/dist/chunks/{button-actions-with-menu.C14zvgVo.js.map → button-actions-with-menu.Dnyh1m51.js.map} +1 -1
- package/dist/chunks/{button-actions.hGhRdgC2.js → button-actions.BpLFzJJY.js} +2 -2
- package/dist/chunks/{button-actions.hGhRdgC2.js.map → button-actions.BpLFzJJY.js.map} +1 -1
- package/dist/chunks/{card.C7zLKdcy.js → card.DOQt8sH5.js} +2 -2
- package/dist/chunks/{card.C7zLKdcy.js.map → card.DOQt8sH5.js.map} +1 -1
- package/dist/chunks/{checkbox-group.BcT-eZ2p.js → checkbox-group.DS_f6k8E.js} +4 -4
- package/dist/chunks/{checkbox-group.BcT-eZ2p.js.map → checkbox-group.DS_f6k8E.js.map} +1 -1
- package/dist/chunks/{checkbox.xjIFibII.js → checkbox.C5cMvVMm.js} +3 -3
- package/dist/chunks/{checkbox.xjIFibII.js.map → checkbox.C5cMvVMm.js.map} +1 -1
- package/dist/chunks/{code-snippet.e8bxDBCO.js → code-snippet.68epWI-z.js} +184 -208
- package/dist/chunks/code-snippet.68epWI-z.js.map +1 -0
- package/dist/chunks/{controls-group.DWu8NqKL.js → controls-group.fAwpZLvA.js} +2 -2
- package/dist/chunks/{controls-group.DWu8NqKL.js.map → controls-group.fAwpZLvA.js.map} +1 -1
- package/dist/chunks/{copy.BhO7oRgC.js → copy.B6CXENok.js} +3 -3
- package/dist/chunks/{copy.BhO7oRgC.js.map → copy.B6CXENok.js.map} +1 -1
- package/dist/chunks/cross-circle-fill-small.DiZWEd7W.js +29 -0
- package/dist/chunks/cross-circle-fill-small.DiZWEd7W.js.map +1 -0
- package/dist/chunks/{dashboard-section.DKeDjvkB.js → dashboard-section.Bzj5vzTE.js} +3 -3
- package/dist/chunks/{dashboard-section.DKeDjvkB.js.map → dashboard-section.Bzj5vzTE.js.map} +1 -1
- package/dist/chunks/{dashed-underline.DGTW7Y_-.js → dashed-underline.SEXinixe.js} +3 -3
- package/dist/chunks/{dashed-underline.DGTW7Y_-.js.map → dashed-underline.SEXinixe.js.map} +1 -1
- package/dist/chunks/{data-grid-template.6Nls-D4o.js → data-grid-template.BRRSej-5.js} +2 -2
- package/dist/chunks/{data-grid-template.6Nls-D4o.js.map → data-grid-template.BRRSej-5.js.map} +1 -1
- package/dist/chunks/{data-grid.BwfZhc09.js → data-grid.D0dri6Lc.js} +15 -15
- package/dist/chunks/{data-grid.BwfZhc09.js.map → data-grid.D0dri6Lc.js.map} +1 -1
- package/dist/chunks/{date-picker.CoPmllNh.js → date-picker.NKXc916N.js} +15 -15
- package/dist/chunks/{date-picker.CoPmllNh.js.map → date-picker.NKXc916N.js.map} +1 -1
- package/dist/chunks/{date-range-picker.CiwDo2jW.js → date-range-picker.DXdh7SCV.js} +13 -13
- package/dist/chunks/{date-range-picker.CiwDo2jW.js.map → date-range-picker.DXdh7SCV.js.map} +1 -1
- package/dist/chunks/{dropdown-default-textbox.-Oy2eT40.js → dropdown-default-textbox.Bx0-dxhU.js} +112 -96
- package/dist/chunks/dropdown-default-textbox.Bx0-dxhU.js.map +1 -0
- package/dist/chunks/{dropdown-tag.C-LxVWlt.js → dropdown-tag.DPTV12uX.js} +14 -13
- package/dist/chunks/dropdown-tag.DPTV12uX.js.map +1 -0
- package/dist/chunks/{dropdown.CxBlK83Q.js → dropdown.CoVT4i0B.js} +360 -349
- package/dist/chunks/dropdown.CoVT4i0B.js.map +1 -0
- package/dist/chunks/{error-message.DyjHMyEZ.js → error-message.oV0CXm1m.js} +3 -3
- package/dist/chunks/{error-message.DyjHMyEZ.js.map → error-message.oV0CXm1m.js.map} +1 -1
- package/dist/chunks/es6.BvpG4Oi6.js +9 -0
- package/dist/chunks/es6.BvpG4Oi6.js.map +1 -0
- package/dist/chunks/expand.D1DTqaBO.js +33 -0
- package/dist/chunks/expand.D1DTqaBO.js.map +1 -0
- package/dist/chunks/{filter-bar.U2ZcPmSU.js → filter-bar.d1IKC-Nr.js} +329 -320
- package/dist/chunks/filter-bar.d1IKC-Nr.js.map +1 -0
- package/dist/chunks/{footer-actions.D9nQFagi.js → footer-actions.Cuiq9UJH.js} +2 -2
- package/dist/chunks/{footer-actions.D9nQFagi.js.map → footer-actions.Cuiq9UJH.js.map} +1 -1
- package/dist/chunks/{header.Cr7115vM.js → header.B4il13uF.js} +3 -3
- package/dist/chunks/{header.Cr7115vM.js.map → header.B4il13uF.js.map} +1 -1
- package/dist/chunks/index.DKQuLmwu.js +182 -0
- package/dist/chunks/{index.Dytpif0G.js.map → index.DKQuLmwu.js.map} +1 -1
- package/dist/chunks/{info-icon.DvL1e5Iu.js → info-icon.B8AL324x.js} +3 -3
- package/dist/chunks/{info-icon.DvL1e5Iu.js.map → info-icon.B8AL324x.js.map} +1 -1
- package/dist/chunks/{input-field.iH1ICJkQ.js → input-field.CKh69yj2.js} +119 -113
- package/dist/chunks/input-field.CKh69yj2.js.map +1 -0
- package/dist/chunks/inspector.types.88WOdYA6.js +116 -0
- package/dist/chunks/inspector.types.88WOdYA6.js.map +1 -0
- package/dist/chunks/listbox-option-tag.m6aNQTJN.js +55 -0
- package/dist/chunks/listbox-option-tag.m6aNQTJN.js.map +1 -0
- package/dist/chunks/loading-button.BxDrDxmI.js +123 -0
- package/dist/chunks/loading-button.BxDrDxmI.js.map +1 -0
- package/dist/chunks/{menu.DN-xhDQU.js → menu.PtOT_BKl.js} +2 -2
- package/dist/chunks/{menu.DN-xhDQU.js.map → menu.PtOT_BKl.js.map} +1 -1
- package/dist/chunks/{modal-fullscreen.CeogBGfr.js → modal-fullscreen.BkuEaCdO.js} +2 -2
- package/dist/chunks/{modal-fullscreen.CeogBGfr.js.map → modal-fullscreen.BkuEaCdO.js.map} +1 -1
- package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.BBef1Rl9.js → modal.vue_vue_type_script_setup_true_lang.CQXfT4eW.js} +4 -4
- package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.BBef1Rl9.js.map → modal.vue_vue_type_script_setup_true_lang.CQXfT4eW.js.map} +1 -1
- package/dist/chunks/{pagination.BwG1MF4j.js → pagination.DeOBHgWf.js} +2 -2
- package/dist/chunks/{pagination.BwG1MF4j.js.map → pagination.DeOBHgWf.js.map} +1 -1
- package/dist/chunks/{popover.DRb2GW7t.js → popover.CvUTNkQG.js} +3 -3
- package/dist/chunks/{popover.DRb2GW7t.js.map → popover.CvUTNkQG.js.map} +1 -1
- package/dist/chunks/{popper-container.B76aE-3-.js → popper-container.50jF-_VU.js} +487 -435
- package/dist/chunks/popper-container.50jF-_VU.js.map +1 -0
- package/dist/chunks/{radio-group.B9HCffiZ.js → radio-group.r5U1kQIe.js} +95 -93
- package/dist/chunks/radio-group.r5U1kQIe.js.map +1 -0
- package/dist/chunks/search-bar.DmXr-0Ax.js +116 -0
- package/dist/chunks/search-bar.DmXr-0Ax.js.map +1 -0
- package/dist/chunks/secondary-nav.DnQPIiYO.js +137 -0
- package/dist/chunks/secondary-nav.DnQPIiYO.js.map +1 -0
- package/dist/chunks/{segmented-control.NnFfAdTq.js → segmented-control.ClihHHOR.js} +12 -12
- package/dist/chunks/segmented-control.ClihHHOR.js.map +1 -0
- package/dist/chunks/{selection-card-group.C-YLePO4.js → selection-card-group.AkttDBv5.js} +3 -3
- package/dist/chunks/{selection-card-group.C-YLePO4.js.map → selection-card-group.AkttDBv5.js.map} +1 -1
- package/dist/chunks/{sidepanel.B-LtA15e.js → sidepanel.Dv73FrCn.js} +2 -2
- package/dist/chunks/{sidepanel.B-LtA15e.js.map → sidepanel.Dv73FrCn.js.map} +1 -1
- package/dist/chunks/{structured-list-item.DQiPKhOI.js → structured-list-item.DrYz5IsA.js} +4 -4
- package/dist/chunks/{structured-list-item.DQiPKhOI.js.map → structured-list-item.DrYz5IsA.js.map} +1 -1
- package/dist/chunks/{summary-grid-item-custom.B941Kdvq.js → summary-grid-item-custom.MloQOKnI.js} +4 -4
- package/dist/chunks/{summary-grid-item-custom.B941Kdvq.js.map → summary-grid-item-custom.MloQOKnI.js.map} +1 -1
- package/dist/chunks/{tag.CPhtHjDD.js → tag.D0imyBj_.js} +2 -2
- package/dist/chunks/{tag.CPhtHjDD.js.map → tag.D0imyBj_.js.map} +1 -1
- package/dist/chunks/textarea.meOoBSoa.js +267 -0
- package/dist/chunks/textarea.meOoBSoa.js.map +1 -0
- package/dist/chunks/{timeline-item.Cap9MXkH.js → timeline-item.BF6w6sUT.js} +181 -168
- package/dist/chunks/timeline-item.BF6w6sUT.js.map +1 -0
- package/dist/chunks/{tooltip.CTR3s-Rm.js → tooltip.C0jTO2wt.js} +2 -2
- package/dist/chunks/{tooltip.CTR3s-Rm.js.map → tooltip.C0jTO2wt.js.map} +1 -1
- package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.WNVsOZdp.js → tutorial.vue_vue_type_script_setup_true_lang.PX3UIJgR.js} +5 -5
- package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.WNVsOZdp.js.map → tutorial.vue_vue_type_script_setup_true_lang.PX3UIJgR.js.map} +1 -1
- package/dist/chunks/{use-cached-selected-values.BQBWFTvi.js → use-cached-selected-values.Bh2VFRA-.js} +3 -3
- package/dist/chunks/use-cached-selected-values.Bh2VFRA-.js.map +1 -0
- package/dist/code-snippet.js +1 -1
- package/dist/dashboard-template.js +1 -1
- package/dist/dashed-underline.js +1 -1
- package/dist/data-grid-template.js +1 -1
- package/dist/data-grid.js +1 -1
- package/dist/date-picker.js +1 -1
- package/dist/date-range-picker.js +1 -1
- package/dist/dropdown.js +11 -10
- package/dist/dropdown.js.map +1 -1
- package/dist/filter-bar.js +1 -1
- package/dist/header.js +1 -1
- package/dist/index.js +241 -236
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +1 -1
- package/dist/input-field.js +1 -1
- package/dist/inspector.js +6 -0
- package/dist/inspector.js.map +1 -0
- package/dist/internal.js +30 -31
- package/dist/menu.js +1 -1
- package/dist/modal-fullscreen.js +1 -1
- package/dist/modal.js +2 -2
- package/dist/pagination.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/popper-container.js +1 -1
- package/dist/radio-group.js +1 -1
- package/dist/search-bar.js +2 -2
- package/dist/secondary-nav.js +1 -1
- package/dist/segmented-control.js +1 -1
- package/dist/selection-card.js +1 -1
- package/dist/sidepanel.js +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/summary-grid.js +1 -1
- package/dist/tag.js +1 -1
- package/dist/textarea.js +1 -1
- package/dist/timeline.js +1 -1
- package/dist/tutorial.js +1 -1
- package/dist/web-types.json +1 -1
- package/package.json +2 -2
- package/dist/assets/avatar-image.css +0 -1
- package/dist/avatar-image.js +0 -7
- package/dist/avatar-image.js.map +0 -1
- package/dist/chunks/avatar-image.DO4w_loj.js +0 -61
- package/dist/chunks/avatar-image.DO4w_loj.js.map +0 -1
- package/dist/chunks/code-snippet.e8bxDBCO.js.map +0 -1
- package/dist/chunks/dropdown-default-textbox.-Oy2eT40.js.map +0 -1
- package/dist/chunks/dropdown-tag.C-LxVWlt.js.map +0 -1
- package/dist/chunks/dropdown.CxBlK83Q.js.map +0 -1
- package/dist/chunks/filter-bar.U2ZcPmSU.js.map +0 -1
- package/dist/chunks/index.Dytpif0G.js +0 -125
- package/dist/chunks/input-field.iH1ICJkQ.js.map +0 -1
- package/dist/chunks/listbox-option-tag.Bv4-hXnG.js +0 -94
- package/dist/chunks/listbox-option-tag.Bv4-hXnG.js.map +0 -1
- package/dist/chunks/loading-button.BI32pZiW.js +0 -117
- package/dist/chunks/loading-button.BI32pZiW.js.map +0 -1
- package/dist/chunks/popper-container.B76aE-3-.js.map +0 -1
- package/dist/chunks/radio-group.B9HCffiZ.js.map +0 -1
- package/dist/chunks/search-bar.DxskyM4e.js +0 -107
- package/dist/chunks/search-bar.DxskyM4e.js.map +0 -1
- package/dist/chunks/secondary-nav.D66nxbU-.js +0 -112
- package/dist/chunks/secondary-nav.D66nxbU-.js.map +0 -1
- package/dist/chunks/segmented-control.NnFfAdTq.js.map +0 -1
- package/dist/chunks/textarea.CJ8xiMjv.js +0 -288
- package/dist/chunks/textarea.CJ8xiMjv.js.map +0 -1
- package/dist/chunks/timeline-item.Cap9MXkH.js.map +0 -1
- package/dist/chunks/use-cached-selected-values.BQBWFTvi.js.map +0 -1
- /package/dist/@types/packages/{vue2/src/components/button → core/src}/components/loading-button/loading-button.types.d.ts +0 -0
- /package/dist/@types/packages/{vue2 → core}/src/types/omit-strict.d.ts +0 -0
- /package/dist/@types/packages/vue2/src/components/{avatar-image → avatar/components/avatar-image}/avatar-image.types.d.ts +0 -0
- /package/dist/@types/packages/vue2/src/components/{avatar-image → avatar/components/avatar-image}/index.d.ts +0 -0
- /package/dist/@types/packages/vue2/src/components/{internal/avatar → avatar}/index.d.ts +0 -0
|
@@ -1,30 +1,32 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { highlightActiveLine as
|
|
3
|
-
import { EditorSelection as
|
|
4
|
-
import { indentWithTab as
|
|
5
|
-
import { syntaxHighlighting as
|
|
6
|
-
import { B as Me } from "./
|
|
7
|
-
import { B as He } from "./
|
|
8
|
-
import { B as Ve } from "./
|
|
9
|
-
import { B as
|
|
10
|
-
import { B as
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
1
|
+
import { defineComponent as me, ref as x, computed as O, shallowRef as Z, onMounted as fe, watch as he, watchEffect as be, resolveComponent as h, openBlock as p, createElementBlock as j, normalizeClass as ee, createElementVNode as P, createBlock as I, mergeProps as ye, createCommentVNode as C, createVNode as H, withCtx as B, createTextVNode as te, toDisplayString as ne, renderSlot as Ne, normalizeProps as ke, guardReactiveProps as ve, pushScopeId as we, popScopeId as Ce } from "vue";
|
|
2
|
+
import { highlightActiveLine as _e, keymap as Ie, EditorView as oe, lineNumbers as Ae } from "@codemirror/view";
|
|
3
|
+
import { EditorSelection as Le, Compartment as q, EditorState as ae } from "@codemirror/state";
|
|
4
|
+
import { indentWithTab as Ee, history as Oe } from "@codemirror/commands";
|
|
5
|
+
import { syntaxHighlighting as Be, HighlightStyle as Te } from "@codemirror/language";
|
|
6
|
+
import { B as Se, a as Me, b as xe, c as je } from "./es6.BvpG4Oi6.js";
|
|
7
|
+
import { B as He } from "./dropdown.CoVT4i0B.js";
|
|
8
|
+
import { B as Ve } from "./button.DoqHEvPh.js";
|
|
9
|
+
import { B as Re } from "./typography.D7onlQ9v.js";
|
|
10
|
+
import { B as ze } from "./tooltip.C0jTO2wt.js";
|
|
11
|
+
import { B as Pe } from "./loading-indicator.BFMEf39U.js";
|
|
12
|
+
import { u as $e } from "./i18n.DY5YXG5f.js";
|
|
13
|
+
import { E as De } from "./expand.D1DTqaBO.js";
|
|
14
|
+
import { h as Je } from "./base-modal.CY-t-QYh.js";
|
|
15
|
+
import { C as Ge } from "./copy.B6CXENok.js";
|
|
16
|
+
import { json as Ke } from "@codemirror/lang-json";
|
|
17
|
+
import { xml as Ue } from "@codemirror/lang-xml";
|
|
18
|
+
import { javascript as We } from "@codemirror/lang-javascript";
|
|
19
|
+
import { java as qe } from "@codemirror/lang-java";
|
|
20
|
+
import { python as Xe } from "@codemirror/lang-python";
|
|
21
|
+
import { _ as Ye } from "./_plugin-vue_export-helper.CHgC5LLL.js";
|
|
20
22
|
import "../assets/code-snippet.css";
|
|
21
|
-
let
|
|
23
|
+
let Fe = 0;
|
|
22
24
|
class l {
|
|
23
25
|
/**
|
|
24
26
|
Create a new node prop type.
|
|
25
27
|
*/
|
|
26
28
|
constructor(o = {}) {
|
|
27
|
-
this.id =
|
|
29
|
+
this.id = Fe++, this.perNode = !!o.perNode, this.deserialize = o.deserialize || (() => {
|
|
28
30
|
throw new Error("This node type doesn't define a deserialize function");
|
|
29
31
|
});
|
|
30
32
|
}
|
|
@@ -40,7 +42,7 @@ class l {
|
|
|
40
42
|
add(o) {
|
|
41
43
|
if (this.perNode)
|
|
42
44
|
throw new RangeError("Can't add per-node props to node types");
|
|
43
|
-
return typeof o != "function" && (o =
|
|
45
|
+
return typeof o != "function" && (o = M.match(o)), (a) => {
|
|
44
46
|
let r = o(a);
|
|
45
47
|
return r === void 0 ? null : [this, r];
|
|
46
48
|
};
|
|
@@ -57,8 +59,8 @@ l.isolate = new l({ deserialize: (e) => {
|
|
|
57
59
|
l.contextHash = new l({ perNode: !0 });
|
|
58
60
|
l.lookAhead = new l({ perNode: !0 });
|
|
59
61
|
l.mounted = new l({ perNode: !0 });
|
|
60
|
-
const
|
|
61
|
-
class
|
|
62
|
+
const Qe = /* @__PURE__ */ Object.create(null);
|
|
63
|
+
class M {
|
|
62
64
|
/**
|
|
63
65
|
@internal
|
|
64
66
|
*/
|
|
@@ -69,7 +71,7 @@ class H {
|
|
|
69
71
|
Define a node type.
|
|
70
72
|
*/
|
|
71
73
|
static define(o) {
|
|
72
|
-
let a = o.props && o.props.length ? /* @__PURE__ */ Object.create(null) :
|
|
74
|
+
let a = o.props && o.props.length ? /* @__PURE__ */ Object.create(null) : Qe, r = (o.top ? 1 : 0) | (o.skipped ? 2 : 0) | (o.error ? 4 : 0) | (o.name == null ? 8 : 0), s = new M(o.name || "", a, o.id, r);
|
|
73
75
|
if (o.props) {
|
|
74
76
|
for (let i of o.props)
|
|
75
77
|
if (Array.isArray(i) || (i = i(s)), i) {
|
|
@@ -147,7 +149,7 @@ class H {
|
|
|
147
149
|
};
|
|
148
150
|
}
|
|
149
151
|
}
|
|
150
|
-
|
|
152
|
+
M.none = new M(
|
|
151
153
|
"",
|
|
152
154
|
/* @__PURE__ */ Object.create(null),
|
|
153
155
|
0,
|
|
@@ -159,13 +161,13 @@ var re;
|
|
|
159
161
|
e[e.ExcludeBuffers = 1] = "ExcludeBuffers", e[e.IncludeAnonymous = 2] = "IncludeAnonymous", e[e.IgnoreMounts = 4] = "IgnoreMounts", e[e.IgnoreOverlays = 8] = "IgnoreOverlays";
|
|
160
162
|
})(re || (re = {}));
|
|
161
163
|
new l({ perNode: !0 });
|
|
162
|
-
let
|
|
164
|
+
let Ze = 0;
|
|
163
165
|
class f {
|
|
164
166
|
/**
|
|
165
167
|
@internal
|
|
166
168
|
*/
|
|
167
169
|
constructor(o, a, r) {
|
|
168
|
-
this.set = o, this.base = a, this.modified = r, this.id =
|
|
170
|
+
this.set = o, this.base = a, this.modified = r, this.id = Ze++;
|
|
169
171
|
}
|
|
170
172
|
/**
|
|
171
173
|
Define a new tag. If `parent` is given, the tag is treated as a
|
|
@@ -200,32 +202,32 @@ class f {
|
|
|
200
202
|
return (a) => a.modified.indexOf(o) > -1 ? a : D.get(a.base || a, a.modified.concat(o).sort((r, s) => r.id - s.id));
|
|
201
203
|
}
|
|
202
204
|
}
|
|
203
|
-
let
|
|
205
|
+
let et = 0;
|
|
204
206
|
class D {
|
|
205
207
|
constructor() {
|
|
206
|
-
this.instances = [], this.id =
|
|
208
|
+
this.instances = [], this.id = et++;
|
|
207
209
|
}
|
|
208
210
|
static get(o, a) {
|
|
209
211
|
if (!a.length)
|
|
210
212
|
return o;
|
|
211
|
-
let r = a[0].instances.find((c) => c.base == o &&
|
|
213
|
+
let r = a[0].instances.find((c) => c.base == o && tt(a, c.modified));
|
|
212
214
|
if (r)
|
|
213
215
|
return r;
|
|
214
216
|
let s = [], i = new f(s, o, a);
|
|
215
217
|
for (let c of a)
|
|
216
218
|
c.instances.push(i);
|
|
217
|
-
let d =
|
|
219
|
+
let d = nt(a);
|
|
218
220
|
for (let c of o.set)
|
|
219
221
|
if (!c.modified.length)
|
|
220
|
-
for (let
|
|
221
|
-
s.push(D.get(c,
|
|
222
|
+
for (let k of d)
|
|
223
|
+
s.push(D.get(c, k));
|
|
222
224
|
return i;
|
|
223
225
|
}
|
|
224
226
|
}
|
|
225
|
-
function
|
|
227
|
+
function tt(e, o) {
|
|
226
228
|
return e.length == o.length && e.every((a, r) => a == o[r]);
|
|
227
229
|
}
|
|
228
|
-
function
|
|
230
|
+
function nt(e) {
|
|
229
231
|
let o = [[]];
|
|
230
232
|
for (let a = 0; a < e.length; a++)
|
|
231
233
|
for (let r = 0, s = o.length; r < s; r++)
|
|
@@ -233,7 +235,7 @@ function Fe(e) {
|
|
|
233
235
|
return o.sort((a, r) => r.length - a.length);
|
|
234
236
|
}
|
|
235
237
|
new l();
|
|
236
|
-
function
|
|
238
|
+
function ot(e, o) {
|
|
237
239
|
let a = /* @__PURE__ */ Object.create(null);
|
|
238
240
|
for (let i of e)
|
|
239
241
|
if (!Array.isArray(i.tag))
|
|
@@ -246,10 +248,10 @@ function Qe(e, o) {
|
|
|
246
248
|
style: (i) => {
|
|
247
249
|
let d = s;
|
|
248
250
|
for (let c of i)
|
|
249
|
-
for (let
|
|
250
|
-
let
|
|
251
|
-
if (
|
|
252
|
-
d = d ? d + " " +
|
|
251
|
+
for (let k of c.set) {
|
|
252
|
+
let v = a[k.id];
|
|
253
|
+
if (v) {
|
|
254
|
+
d = d ? d + " " + v : v;
|
|
253
255
|
break;
|
|
254
256
|
}
|
|
255
257
|
}
|
|
@@ -258,31 +260,31 @@ function Qe(e, o) {
|
|
|
258
260
|
scope: r
|
|
259
261
|
};
|
|
260
262
|
}
|
|
261
|
-
const n = f.define,
|
|
263
|
+
const n = f.define, V = n(), b = n(), ie = n(b), se = n(b), y = n(), R = n(y), X = n(y), m = n(), _ = n(m), g = n(), u = n(), Y = n(), T = n(Y), z = n(), t = {
|
|
262
264
|
/**
|
|
263
265
|
A comment.
|
|
264
266
|
*/
|
|
265
|
-
comment:
|
|
267
|
+
comment: V,
|
|
266
268
|
/**
|
|
267
269
|
A line [comment](#highlight.tags.comment).
|
|
268
270
|
*/
|
|
269
|
-
lineComment: n(
|
|
271
|
+
lineComment: n(V),
|
|
270
272
|
/**
|
|
271
273
|
A block [comment](#highlight.tags.comment).
|
|
272
274
|
*/
|
|
273
|
-
blockComment: n(
|
|
275
|
+
blockComment: n(V),
|
|
274
276
|
/**
|
|
275
277
|
A documentation [comment](#highlight.tags.comment).
|
|
276
278
|
*/
|
|
277
|
-
docComment: n(
|
|
279
|
+
docComment: n(V),
|
|
278
280
|
/**
|
|
279
281
|
Any kind of identifier.
|
|
280
282
|
*/
|
|
281
|
-
name:
|
|
283
|
+
name: b,
|
|
282
284
|
/**
|
|
283
285
|
The [name](#highlight.tags.name) of a variable.
|
|
284
286
|
*/
|
|
285
|
-
variableName: n(
|
|
287
|
+
variableName: n(b),
|
|
286
288
|
/**
|
|
287
289
|
A type [name](#highlight.tags.name).
|
|
288
290
|
*/
|
|
@@ -302,23 +304,23 @@ const n = f.define, j = n(), y = n(), ie = n(y), se = n(y), N = n(), R = n(N), X
|
|
|
302
304
|
/**
|
|
303
305
|
The [name](#highlight.tags.name) of a class.
|
|
304
306
|
*/
|
|
305
|
-
className: n(
|
|
307
|
+
className: n(b),
|
|
306
308
|
/**
|
|
307
309
|
A label [name](#highlight.tags.name).
|
|
308
310
|
*/
|
|
309
|
-
labelName: n(
|
|
311
|
+
labelName: n(b),
|
|
310
312
|
/**
|
|
311
313
|
A namespace [name](#highlight.tags.name).
|
|
312
314
|
*/
|
|
313
|
-
namespace: n(
|
|
315
|
+
namespace: n(b),
|
|
314
316
|
/**
|
|
315
317
|
The [name](#highlight.tags.name) of a macro.
|
|
316
318
|
*/
|
|
317
|
-
macroName: n(
|
|
319
|
+
macroName: n(b),
|
|
318
320
|
/**
|
|
319
321
|
A literal value.
|
|
320
322
|
*/
|
|
321
|
-
literal:
|
|
323
|
+
literal: y,
|
|
322
324
|
/**
|
|
323
325
|
A string [literal](#highlight.tags.literal).
|
|
324
326
|
*/
|
|
@@ -350,24 +352,24 @@ const n = f.define, j = n(), y = n(), ie = n(y), se = n(y), N = n(), R = n(N), X
|
|
|
350
352
|
/**
|
|
351
353
|
A boolean [literal](#highlight.tags.literal).
|
|
352
354
|
*/
|
|
353
|
-
bool: n(
|
|
355
|
+
bool: n(y),
|
|
354
356
|
/**
|
|
355
357
|
Regular expression [literal](#highlight.tags.literal).
|
|
356
358
|
*/
|
|
357
|
-
regexp: n(
|
|
359
|
+
regexp: n(y),
|
|
358
360
|
/**
|
|
359
361
|
An escape [literal](#highlight.tags.literal), for example a
|
|
360
362
|
backslash escape in a string.
|
|
361
363
|
*/
|
|
362
|
-
escape: n(
|
|
364
|
+
escape: n(y),
|
|
363
365
|
/**
|
|
364
366
|
A color [literal](#highlight.tags.literal).
|
|
365
367
|
*/
|
|
366
|
-
color: n(
|
|
368
|
+
color: n(y),
|
|
367
369
|
/**
|
|
368
370
|
A URL [literal](#highlight.tags.literal).
|
|
369
371
|
*/
|
|
370
|
-
url: n(
|
|
372
|
+
url: n(y),
|
|
371
373
|
/**
|
|
372
374
|
A language keyword.
|
|
373
375
|
*/
|
|
@@ -453,36 +455,36 @@ const n = f.define, j = n(), y = n(), ie = n(y), se = n(y), N = n(), R = n(N), X
|
|
|
453
455
|
/**
|
|
454
456
|
Program or markup punctuation.
|
|
455
457
|
*/
|
|
456
|
-
punctuation:
|
|
458
|
+
punctuation: Y,
|
|
457
459
|
/**
|
|
458
460
|
[Punctuation](#highlight.tags.punctuation) that separates
|
|
459
461
|
things.
|
|
460
462
|
*/
|
|
461
|
-
separator: n(
|
|
463
|
+
separator: n(Y),
|
|
462
464
|
/**
|
|
463
465
|
Bracket-style [punctuation](#highlight.tags.punctuation).
|
|
464
466
|
*/
|
|
465
|
-
bracket:
|
|
467
|
+
bracket: T,
|
|
466
468
|
/**
|
|
467
469
|
Angle [brackets](#highlight.tags.bracket) (usually `<` and `>`
|
|
468
470
|
tokens).
|
|
469
471
|
*/
|
|
470
|
-
angleBracket: n(
|
|
472
|
+
angleBracket: n(T),
|
|
471
473
|
/**
|
|
472
474
|
Square [brackets](#highlight.tags.bracket) (usually `[` and `]`
|
|
473
475
|
tokens).
|
|
474
476
|
*/
|
|
475
|
-
squareBracket: n(
|
|
477
|
+
squareBracket: n(T),
|
|
476
478
|
/**
|
|
477
479
|
Parentheses (usually `(` and `)` tokens). Subtag of
|
|
478
480
|
[bracket](#highlight.tags.bracket).
|
|
479
481
|
*/
|
|
480
|
-
paren: n(
|
|
482
|
+
paren: n(T),
|
|
481
483
|
/**
|
|
482
484
|
Braces (usually `{` and `}` tokens). Subtag of
|
|
483
485
|
[bracket](#highlight.tags.bracket).
|
|
484
486
|
*/
|
|
485
|
-
brace: n(
|
|
487
|
+
brace: n(T),
|
|
486
488
|
/**
|
|
487
489
|
Content, for example plain text in XML or markup documents.
|
|
488
490
|
*/
|
|
@@ -490,31 +492,31 @@ const n = f.define, j = n(), y = n(), ie = n(y), se = n(y), N = n(), R = n(N), X
|
|
|
490
492
|
/**
|
|
491
493
|
[Content](#highlight.tags.content) that represents a heading.
|
|
492
494
|
*/
|
|
493
|
-
heading:
|
|
495
|
+
heading: _,
|
|
494
496
|
/**
|
|
495
497
|
A level 1 [heading](#highlight.tags.heading).
|
|
496
498
|
*/
|
|
497
|
-
heading1: n(
|
|
499
|
+
heading1: n(_),
|
|
498
500
|
/**
|
|
499
501
|
A level 2 [heading](#highlight.tags.heading).
|
|
500
502
|
*/
|
|
501
|
-
heading2: n(
|
|
503
|
+
heading2: n(_),
|
|
502
504
|
/**
|
|
503
505
|
A level 3 [heading](#highlight.tags.heading).
|
|
504
506
|
*/
|
|
505
|
-
heading3: n(
|
|
507
|
+
heading3: n(_),
|
|
506
508
|
/**
|
|
507
509
|
A level 4 [heading](#highlight.tags.heading).
|
|
508
510
|
*/
|
|
509
|
-
heading4: n(
|
|
511
|
+
heading4: n(_),
|
|
510
512
|
/**
|
|
511
513
|
A level 5 [heading](#highlight.tags.heading).
|
|
512
514
|
*/
|
|
513
|
-
heading5: n(
|
|
515
|
+
heading5: n(_),
|
|
514
516
|
/**
|
|
515
517
|
A level 6 [heading](#highlight.tags.heading).
|
|
516
518
|
*/
|
|
517
|
-
heading6: n(
|
|
519
|
+
heading6: n(_),
|
|
518
520
|
/**
|
|
519
521
|
A prose separator (such as a horizontal rule).
|
|
520
522
|
*/
|
|
@@ -624,7 +626,7 @@ const n = f.define, j = n(), y = n(), ie = n(y), se = n(y), N = n(), R = n(N), X
|
|
|
624
626
|
*/
|
|
625
627
|
special: f.defineModifier()
|
|
626
628
|
};
|
|
627
|
-
|
|
629
|
+
ot([
|
|
628
630
|
{ tag: t.link, class: "tok-link" },
|
|
629
631
|
{ tag: t.heading, class: "tok-heading" },
|
|
630
632
|
{ tag: t.emphasis, class: "tok-emphasis" },
|
|
@@ -656,13 +658,13 @@ Qe([
|
|
|
656
658
|
{ tag: t.invalid, class: "tok-invalid" },
|
|
657
659
|
{ tag: t.punctuation, class: "tok-punctuation" }
|
|
658
660
|
]);
|
|
659
|
-
const
|
|
660
|
-
red:
|
|
661
|
-
orange:
|
|
662
|
-
green:
|
|
663
|
-
blue:
|
|
661
|
+
const at = {
|
|
662
|
+
red: Se,
|
|
663
|
+
orange: Me,
|
|
664
|
+
green: xe,
|
|
665
|
+
blue: je,
|
|
664
666
|
invalid: "#ffffff"
|
|
665
|
-
}, rt = (e) =>
|
|
667
|
+
}, rt = (e) => Te.define([
|
|
666
668
|
{
|
|
667
669
|
tag: t.keyword,
|
|
668
670
|
color: e.red
|
|
@@ -729,14 +731,14 @@ const et = "#c72727", tt = "#9b5700", nt = "#067934", ot = "#0063d7", at = {
|
|
|
729
731
|
tag: t.invalid,
|
|
730
732
|
color: e.invalid
|
|
731
733
|
}
|
|
732
|
-
]), it =
|
|
733
|
-
var
|
|
734
|
+
]), it = Be(rt(at));
|
|
735
|
+
var $ = /* @__PURE__ */ ((e) => (e.INLINE = "inline", e.SINGLELINE = "singleline", e.MULTILINE = "multiline", e))($ || {}), N = /* @__PURE__ */ ((e) => (e.JSON = "json", e.XML = "xml", e.JAVA = "java", e.JAVASCRIPT = "javascript", e.PYTHON = "python", e))(N || {}), S = /* @__PURE__ */ ((e) => (e.ACTION = "action", e.CHANGE = "change", e))(S || {});
|
|
734
736
|
const st = {
|
|
735
|
-
[
|
|
736
|
-
[
|
|
737
|
-
[
|
|
738
|
-
[
|
|
739
|
-
[
|
|
737
|
+
[N.JSON]: Ke,
|
|
738
|
+
[N.XML]: Ue,
|
|
739
|
+
[N.JAVASCRIPT]: We,
|
|
740
|
+
[N.JAVA]: qe,
|
|
741
|
+
[N.PYTHON]: Xe
|
|
740
742
|
}, lt = (e) => async () => st[e], ct = (e, o) => {
|
|
741
743
|
const a = e.doc.lineAt(o.from), r = /^\s*/.exec(a.text);
|
|
742
744
|
return r ? r[0] : "";
|
|
@@ -748,71 +750,45 @@ const st = {
|
|
|
748
750
|
${ct(e, r)}`;
|
|
749
751
|
return {
|
|
750
752
|
changes: { from: r.from, to: r.to, insert: i },
|
|
751
|
-
range:
|
|
753
|
+
range: Le.cursor(r.from + i.length)
|
|
752
754
|
};
|
|
753
755
|
});
|
|
754
756
|
return o(e.update(a, { scrollIntoView: !0, userEvent: "input" })), !0;
|
|
755
757
|
}
|
|
756
|
-
}
|
|
757
|
-
let le = 0;
|
|
758
|
-
const pt = {
|
|
759
|
-
beforeCreate() {
|
|
760
|
-
this.uuid = le.toString(), le += 1;
|
|
761
|
-
}
|
|
762
|
-
}, gt = { key: 0 }, ut = /* @__PURE__ */ A("path", {
|
|
763
|
-
fill: "#00112C",
|
|
764
|
-
d: "M14.75 1.25V6.75H13.25V3.81083L10.0001 7.06072L8.93945 6.00006L12.1895 2.75H9.25V1.25H14.75Z"
|
|
765
|
-
}, null, -1), mt = /* @__PURE__ */ A("path", {
|
|
766
|
-
fill: "#00112C",
|
|
767
|
-
d: "M2.75 12.1895V9.25H1.25V14.75H6.75V13.25H3.81083L7.06072 10.0001L6.00006 8.93945L2.75 12.1895Z"
|
|
768
|
-
}, null, -1);
|
|
769
|
-
function ft(e, o, a, r, s, i) {
|
|
770
|
-
return p(), I("svg", de({ role: "img" }, e.$attrs, {
|
|
771
|
-
class: "ui-assets-icons-16",
|
|
772
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
773
|
-
width: "16",
|
|
774
|
-
height: "16",
|
|
775
|
-
fill: "none"
|
|
776
|
-
}), [
|
|
777
|
-
e.$attrs["svg-title"] ? (p(), I("title", gt, Y(e.$attrs["svg-title"]), 1)) : b("", !0),
|
|
778
|
-
ut,
|
|
779
|
-
mt
|
|
780
|
-
], 16);
|
|
781
|
-
}
|
|
782
|
-
const ht = /* @__PURE__ */ pe(pt, [["render", ft]]), ce = {
|
|
758
|
+
}, le = {
|
|
783
759
|
"en-US": {
|
|
784
760
|
run: "Run",
|
|
785
761
|
expand: "Expand"
|
|
786
762
|
}
|
|
787
|
-
},
|
|
788
|
-
i18n: { messages:
|
|
763
|
+
}, pt = me({
|
|
764
|
+
i18n: { messages: le },
|
|
789
765
|
name: "bento-code-snippet",
|
|
790
766
|
components: {
|
|
791
|
-
BentoTypography:
|
|
792
|
-
BentoButton:
|
|
793
|
-
BentoDropdown:
|
|
794
|
-
Copy:
|
|
795
|
-
BaseModal:
|
|
796
|
-
BentoLoadingIndicator:
|
|
797
|
-
ExpandIcon:
|
|
767
|
+
BentoTypography: Re,
|
|
768
|
+
BentoButton: Ve,
|
|
769
|
+
BentoDropdown: He,
|
|
770
|
+
Copy: Ge,
|
|
771
|
+
BaseModal: Je,
|
|
772
|
+
BentoLoadingIndicator: Pe,
|
|
773
|
+
ExpandIcon: De
|
|
798
774
|
},
|
|
799
|
-
directives: { BentoTooltipDirective:
|
|
775
|
+
directives: { BentoTooltipDirective: ze },
|
|
800
776
|
props: {
|
|
801
777
|
/**
|
|
802
778
|
* Defines the variant of code-snippet
|
|
803
779
|
*/
|
|
804
780
|
variant: {
|
|
805
781
|
type: String,
|
|
806
|
-
default:
|
|
807
|
-
validator: (e) => Object.values(
|
|
782
|
+
default: $.MULTILINE,
|
|
783
|
+
validator: (e) => Object.values($).includes(e)
|
|
808
784
|
},
|
|
809
785
|
/**
|
|
810
786
|
* Language name for syntax highlighting rules
|
|
811
787
|
*/
|
|
812
788
|
lang: {
|
|
813
789
|
type: String,
|
|
814
|
-
default:
|
|
815
|
-
validator: (e) => Object.values(
|
|
790
|
+
default: N.JSON,
|
|
791
|
+
validator: (e) => Object.values(N).includes(e)
|
|
816
792
|
},
|
|
817
793
|
/**
|
|
818
794
|
* Label to show in the action-bar, describing the language
|
|
@@ -867,43 +843,43 @@ const ht = /* @__PURE__ */ pe(pt, [["render", ft]]), ce = {
|
|
|
867
843
|
default: !1
|
|
868
844
|
}
|
|
869
845
|
},
|
|
870
|
-
emits: [
|
|
846
|
+
emits: [S.ACTION, S.CHANGE],
|
|
871
847
|
setup(e, { emit: o }) {
|
|
872
|
-
const { t: a } =
|
|
873
|
-
}, d =
|
|
848
|
+
const { t: a } = $e({ messages: le }), r = x(null), s = [], i = () => {
|
|
849
|
+
}, d = O(() => e.langLabel ?? e.lang.toUpperCase()), c = O(() => e.variant === $.INLINE), k = O(() => ({
|
|
874
850
|
"b-code-snippet--inline": c.value,
|
|
875
851
|
"b-code-snippet--scrollable": !c.value
|
|
876
|
-
})),
|
|
852
|
+
})), v = O(() => ({
|
|
877
853
|
"b-code-snippet__code-area-content--editable": e.editable
|
|
878
|
-
})), J = lt(e.lang),
|
|
879
|
-
|
|
854
|
+
})), J = lt(e.lang), A = Z(), L = Z(), G = new q(), E = new q(), ce = new q(), w = x(null), K = x(0);
|
|
855
|
+
fe(async () => {
|
|
880
856
|
const U = await J();
|
|
881
|
-
|
|
882
|
-
const
|
|
883
|
-
|
|
857
|
+
w.value = e.content;
|
|
858
|
+
const ue = ({ state: W }) => {
|
|
859
|
+
w.value = W.doc.toString();
|
|
884
860
|
}, F = [
|
|
885
|
-
|
|
886
|
-
|
|
861
|
+
_e(),
|
|
862
|
+
Ie.of([Ee, dt]),
|
|
887
863
|
G.of(U()),
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
oe.updateListener.of((W) =>
|
|
864
|
+
E.of(it),
|
|
865
|
+
ce.of(ae.readOnly.of(!e.editable)),
|
|
866
|
+
oe.updateListener.of((W) => ue(W))
|
|
891
867
|
];
|
|
892
|
-
e.variant === "multiline" && F.push([
|
|
868
|
+
e.variant === "multiline" && F.push([Ae(), Oe()]);
|
|
893
869
|
const Q = ae.create({
|
|
894
870
|
doc: e.content,
|
|
895
871
|
extensions: [...F]
|
|
896
872
|
});
|
|
897
|
-
K.value = Q.doc.length,
|
|
873
|
+
K.value = Q.doc.length, L.value = new oe({
|
|
898
874
|
state: Q,
|
|
899
|
-
parent:
|
|
875
|
+
parent: A.value
|
|
900
876
|
});
|
|
901
|
-
}),
|
|
877
|
+
}), he(
|
|
902
878
|
() => e.content,
|
|
903
879
|
() => {
|
|
904
|
-
if (e.content !==
|
|
880
|
+
if (e.content !== w.value) {
|
|
905
881
|
const U = e.content.length;
|
|
906
|
-
|
|
882
|
+
L.value.dispatch({
|
|
907
883
|
changes: {
|
|
908
884
|
from: 0,
|
|
909
885
|
to: K.value,
|
|
@@ -913,119 +889,119 @@ const ht = /* @__PURE__ */ pe(pt, [["render", ft]]), ce = {
|
|
|
913
889
|
}
|
|
914
890
|
}
|
|
915
891
|
);
|
|
916
|
-
const
|
|
917
|
-
o(
|
|
892
|
+
const de = O(() => a(e.actionableText)), pe = () => {
|
|
893
|
+
o(S.ACTION, w.value);
|
|
918
894
|
};
|
|
919
|
-
|
|
920
|
-
|
|
895
|
+
be(() => {
|
|
896
|
+
w.value !== null && o(S.CHANGE, w.value);
|
|
921
897
|
});
|
|
922
|
-
const
|
|
898
|
+
const ge = x(!1);
|
|
923
899
|
return {
|
|
924
900
|
// Values
|
|
925
901
|
availableLanguages: s,
|
|
926
|
-
codeAreaContentConditionalClasses:
|
|
927
|
-
conditionalClasses:
|
|
928
|
-
container:
|
|
929
|
-
currentContents:
|
|
902
|
+
codeAreaContentConditionalClasses: v,
|
|
903
|
+
conditionalClasses: k,
|
|
904
|
+
container: A,
|
|
905
|
+
currentContents: w,
|
|
930
906
|
displayedLang: d,
|
|
931
|
-
editor:
|
|
907
|
+
editor: L,
|
|
932
908
|
selectedLanguage: r,
|
|
933
|
-
showModal:
|
|
909
|
+
showModal: ge,
|
|
934
910
|
isInlineVariant: c,
|
|
935
911
|
// Methods
|
|
936
912
|
handleChangeLanguage: i,
|
|
937
|
-
onActionClicked:
|
|
938
|
-
runText:
|
|
913
|
+
onActionClicked: pe,
|
|
914
|
+
runText: de,
|
|
939
915
|
// Translations
|
|
940
916
|
t: a
|
|
941
917
|
};
|
|
942
918
|
}
|
|
943
|
-
}),
|
|
919
|
+
}), gt = (e) => (we("data-v-5eb6a936"), e = e(), Ce(), e), ut = {
|
|
944
920
|
key: 0,
|
|
945
921
|
class: "b-code-snippet__action-bar"
|
|
946
|
-
},
|
|
922
|
+
}, mt = { class: "b-code-snippet__action-bar--start" }, ft = { class: "b-code-snippet__action-bar--end" }, ht = {
|
|
947
923
|
key: 1,
|
|
948
924
|
class: "b-code-snippet__code-area"
|
|
949
|
-
},
|
|
950
|
-
function
|
|
951
|
-
const d = h("bento-dropdown"), c = h("bento-typography"),
|
|
952
|
-
return p(),
|
|
953
|
-
class:
|
|
925
|
+
}, bt = { key: 2 }, yt = /* @__PURE__ */ gt(() => /* @__PURE__ */ P("div", { class: "b-code-snippet__empty-state" }, "Nothing to show", -1));
|
|
926
|
+
function Nt(e, o, a, r, s, i) {
|
|
927
|
+
const d = h("bento-dropdown"), c = h("bento-typography"), k = h("bento-loading-indicator"), v = h("copy"), J = h("expand-icon"), A = h("bento-button"), L = h("bento-code-snippet"), G = h("base-modal");
|
|
928
|
+
return p(), j("div", {
|
|
929
|
+
class: ee(["b-code-snippet", e.conditionalClasses])
|
|
954
930
|
}, [
|
|
955
|
-
e.isInlineVariant ?
|
|
956
|
-
|
|
957
|
-
e.availableLanguages.length > 0 ? (p(),
|
|
931
|
+
e.isInlineVariant ? C("", !0) : (p(), j("section", ut, [
|
|
932
|
+
P("div", mt, [
|
|
933
|
+
e.availableLanguages.length > 0 ? (p(), I(d, ye({
|
|
958
934
|
key: 0,
|
|
959
935
|
modelValue: e.selectedLanguage,
|
|
960
|
-
"onUpdate:modelValue": o[0] || (o[0] = (
|
|
936
|
+
"onUpdate:modelValue": o[0] || (o[0] = (E) => e.selectedLanguage = E)
|
|
961
937
|
}, e.$props, {
|
|
962
938
|
disabled: e.availableLanguages.length === 1,
|
|
963
939
|
items: e.availableLanguages,
|
|
964
940
|
class: "b-code-snippet__language-picker",
|
|
965
941
|
onInput: e.handleChangeLanguage
|
|
966
|
-
}), null, 16, ["modelValue", "disabled", "items", "onInput"])) :
|
|
967
|
-
|
|
942
|
+
}), null, 16, ["modelValue", "disabled", "items", "onInput"])) : C("", !0),
|
|
943
|
+
H(c, {
|
|
968
944
|
el: "span",
|
|
969
945
|
stronger: ""
|
|
970
946
|
}, {
|
|
971
|
-
default:
|
|
972
|
-
ne(
|
|
947
|
+
default: B(() => [
|
|
948
|
+
te(ne(e.displayedLang), 1)
|
|
973
949
|
]),
|
|
974
950
|
_: 1
|
|
975
951
|
})
|
|
976
952
|
]),
|
|
977
|
-
|
|
978
|
-
e.loading ? (p(),
|
|
979
|
-
e.currentContents !== null ? (p(),
|
|
953
|
+
P("div", ft, [
|
|
954
|
+
e.loading ? (p(), I(k, { key: 0 })) : C("", !0),
|
|
955
|
+
e.currentContents !== null ? (p(), I(v, {
|
|
980
956
|
key: 1,
|
|
981
957
|
class: "b-structured-list__icon",
|
|
982
958
|
text: e.currentContents
|
|
983
|
-
}, null, 8, ["text"])) :
|
|
984
|
-
e.expandable ? (p(),
|
|
959
|
+
}, null, 8, ["text"])) : C("", !0),
|
|
960
|
+
e.expandable ? (p(), I(A, {
|
|
985
961
|
key: 2,
|
|
986
962
|
variant: "tertiary",
|
|
987
963
|
condensed: "",
|
|
988
964
|
"aria-label": e.t("expand"),
|
|
989
|
-
onClick: o[1] || (o[1] = (
|
|
965
|
+
onClick: o[1] || (o[1] = (E) => e.showModal = !0)
|
|
990
966
|
}, {
|
|
991
|
-
iconLeft:
|
|
992
|
-
|
|
967
|
+
iconLeft: B(() => [
|
|
968
|
+
H(J)
|
|
993
969
|
]),
|
|
994
970
|
_: 1
|
|
995
|
-
}, 8, ["aria-label"])) :
|
|
996
|
-
e.actionable ? (p(),
|
|
971
|
+
}, 8, ["aria-label"])) : C("", !0),
|
|
972
|
+
e.actionable ? (p(), I(A, {
|
|
997
973
|
key: 3,
|
|
998
974
|
variant: "primary",
|
|
999
975
|
tertiary: "",
|
|
1000
976
|
condensed: "",
|
|
1001
977
|
onClick: e.onActionClicked
|
|
1002
978
|
}, {
|
|
1003
|
-
iconLeft:
|
|
1004
|
-
|
|
979
|
+
iconLeft: B(() => [
|
|
980
|
+
H(c, {
|
|
1005
981
|
el: "span",
|
|
1006
982
|
class: "b-code-snippet__action-button"
|
|
1007
983
|
}, {
|
|
1008
|
-
default:
|
|
1009
|
-
ne(
|
|
984
|
+
default: B(() => [
|
|
985
|
+
te(ne(e.runText), 1)
|
|
1010
986
|
]),
|
|
1011
987
|
_: 1
|
|
1012
988
|
})
|
|
1013
989
|
]),
|
|
1014
990
|
_: 1
|
|
1015
|
-
}, 8, ["onClick"])) :
|
|
991
|
+
}, 8, ["onClick"])) : C("", !0)
|
|
1016
992
|
])
|
|
1017
993
|
])),
|
|
1018
|
-
e.content || e.editable ? (p(),
|
|
1019
|
-
|
|
994
|
+
e.content || e.editable ? (p(), j("code", ht, [
|
|
995
|
+
P("div", {
|
|
1020
996
|
ref: "container",
|
|
1021
|
-
class:
|
|
997
|
+
class: ee(["b-code-snippet__code-area-content", e.codeAreaContentConditionalClasses])
|
|
1022
998
|
}, null, 2)
|
|
1023
|
-
])) : (p(),
|
|
1024
|
-
|
|
1025
|
-
|
|
999
|
+
])) : (p(), j("section", bt, [
|
|
1000
|
+
Ne(e.$slots, "empty-state", {}, () => [
|
|
1001
|
+
yt
|
|
1026
1002
|
], !0)
|
|
1027
1003
|
])),
|
|
1028
|
-
e.expandable ? (p(),
|
|
1004
|
+
e.expandable ? (p(), I(G, {
|
|
1029
1005
|
key: 3,
|
|
1030
1006
|
class: "b-code-snippet__modal",
|
|
1031
1007
|
"hide-close-button": !0,
|
|
@@ -1033,20 +1009,20 @@ function Lt(e, o, a, r, s, i) {
|
|
|
1033
1009
|
"is-dismissible": !0,
|
|
1034
1010
|
"is-open": e.showModal,
|
|
1035
1011
|
size: "large",
|
|
1036
|
-
onCloseModal: o[2] || (o[2] = (
|
|
1012
|
+
onCloseModal: o[2] || (o[2] = (E) => e.showModal = !1)
|
|
1037
1013
|
}, {
|
|
1038
|
-
content:
|
|
1039
|
-
|
|
1014
|
+
content: B(() => [
|
|
1015
|
+
H(L, ke(ve({ ...e.$props, expandable: !1 })), null, 16)
|
|
1040
1016
|
]),
|
|
1041
1017
|
_: 1
|
|
1042
|
-
}, 8, ["is-open"])) :
|
|
1018
|
+
}, 8, ["is-open"])) : C("", !0)
|
|
1043
1019
|
], 2);
|
|
1044
1020
|
}
|
|
1045
|
-
const
|
|
1021
|
+
const $t = /* @__PURE__ */ Ye(pt, [["render", Nt], ["__scopeId", "data-v-5eb6a936"]]);
|
|
1046
1022
|
export {
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1023
|
+
$ as B,
|
|
1024
|
+
N as a,
|
|
1025
|
+
S as b,
|
|
1026
|
+
$t as c
|
|
1051
1027
|
};
|
|
1052
|
-
//# sourceMappingURL=code-snippet.
|
|
1028
|
+
//# sourceMappingURL=code-snippet.68epWI-z.js.map
|