@histoire/app 0.16.1 → 0.16.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/dist/bundled/App.vue2.js +2 -2
  2. package/dist/bundled/components/HomeView.vue2.js +2 -2
  3. package/dist/bundled/components/app/AppHeader.vue2.js +1 -1
  4. package/dist/bundled/components/app/AppLogo.vue2.js +3 -3
  5. package/dist/bundled/components/app/Breadcrumb.vue2.js +13 -13
  6. package/dist/bundled/components/app/MobileOverlay.vue2.js +5 -5
  7. package/dist/bundled/components/base/BaseButton.vue2.js +7 -7
  8. package/dist/bundled/components/base/BaseCheckbox.vue2.js +2 -2
  9. package/dist/bundled/components/base/BaseIcon.vue2.js +6 -6
  10. package/dist/bundled/components/base/BaseKeyboardShortcut.vue2.js +3 -3
  11. package/dist/bundled/components/base/BaseListItem.vue2.js +1 -1
  12. package/dist/bundled/components/base/BaseOverflowMenu.vue2.js +4 -4
  13. package/dist/bundled/components/base/BaseSelect.vue2.js +8 -8
  14. package/dist/bundled/components/base/BaseSplitPane.vue2.js +4 -4
  15. package/dist/bundled/components/command/CommandPrompts.vue2.js +3 -3
  16. package/dist/bundled/components/command/PromptSelect.vue2.js +14 -14
  17. package/dist/bundled/components/command/PromptText.vue2.js +11 -11
  18. package/dist/bundled/components/panel/ControlsComponentPropItem.vue2.js +9 -9
  19. package/dist/bundled/components/panel/ControlsComponentProps.vue2.js +6 -6
  20. package/dist/bundled/components/panel/PaneTabs.vue2.js +4 -4
  21. package/dist/bundled/components/panel/StatePresets.vue2.js +7 -7
  22. package/dist/bundled/components/panel/StoryControls.vue2.js +3 -3
  23. package/dist/bundled/components/panel/StoryDocs.vue2.js +3 -3
  24. package/dist/bundled/components/panel/StoryEvent.vue2.js +5 -5
  25. package/dist/bundled/components/panel/StoryEvents.vue2.js +2 -2
  26. package/dist/bundled/components/panel/StorySidePanel.vue2.js +1 -1
  27. package/dist/bundled/components/panel/StorySourceCode.vue2.js +7 -7
  28. package/dist/bundled/components/search/SearchItemContent.vue2.js +11 -11
  29. package/dist/bundled/components/search/SearchPane.vue2.js +3 -3
  30. package/dist/bundled/components/story/GenericMountStory.vue2.js +2 -2
  31. package/dist/bundled/components/story/GenericRenderStory.vue2.js +2 -2
  32. package/dist/bundled/components/story/StoryResponsivePreview.vue2.js +12 -12
  33. package/dist/bundled/components/story/StoryVariantGrid.vue2.js +3 -3
  34. package/dist/bundled/components/story/StoryVariantGridItem.vue2.js +2 -2
  35. package/dist/bundled/components/story/StoryVariantSingle.vue2.js +9 -9
  36. package/dist/bundled/components/story/StoryVariantSinglePreviewNative.vue2.js +9 -9
  37. package/dist/bundled/components/story/StoryVariantSinglePreviewRemote.vue2.js +5 -5
  38. package/dist/bundled/components/story/StoryVariantSingleView.vue2.js +12 -12
  39. package/dist/bundled/components/story/StoryViewer.vue2.js +2 -2
  40. package/dist/bundled/components/toolbar/DevOnlyToolbarOpenInEditor.vue2.js +4 -4
  41. package/dist/bundled/components/toolbar/ToolbarBackground.vue2.js +2 -2
  42. package/dist/bundled/components/toolbar/ToolbarNewTab.vue2.js +4 -4
  43. package/dist/bundled/components/toolbar/ToolbarTitle.vue2.js +4 -4
  44. package/dist/bundled/components/tree/StoryGroup.vue2.js +10 -10
  45. package/dist/bundled/components/tree/StoryList.vue2.js +6 -6
  46. package/dist/bundled/components/tree/StoryListFolder.vue2.js +13 -13
  47. package/dist/bundled/components/tree/StoryListItem.vue2.js +10 -10
  48. package/dist/bundled/style.css +16 -16
  49. package/dist/style.css +537 -528
  50. package/package.json +15 -15
  51. package/src/app/components/app/MobileOverlay.vue +2 -2
  52. package/src/app/components/base/BaseSelect.vue +3 -3
@@ -112,7 +112,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
112
112
  }),
113
113
  createVNode(Breadcrumb, {
114
114
  tree: tree$1.value,
115
- stories: unref(stories)
115
+ stories: stories.value
116
116
  }, null, 8, ["tree", "stories"]),
117
117
  createVNode(_component_RouterView, { class: "htw-grow" })
118
118
  ])) : (openBlock(), createBlock(BaseSplitPane, {
@@ -131,7 +131,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
131
131
  }),
132
132
  createVNode(_sfc_main$3, {
133
133
  tree: tree$1.value,
134
- stories: unref(stories),
134
+ stories: stories.value,
135
135
  class: "htw-flex-1"
136
136
  }, null, 8, ["tree", "stories"])
137
137
  ])
@@ -1,4 +1,4 @@
1
- import { defineComponent, computed, openBlock, createElementBlock, createElementVNode, unref } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, openBlock, createElementBlock, createElementVNode } from "@histoire/vendors/vue";
2
2
  import { histoireConfig, customLogos } from "../util/config.js";
3
3
  import HistoireLogo from "../assets/histoire.svg.js";
4
4
  "use strict";
@@ -14,7 +14,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
14
14
  return (_ctx, _cache) => {
15
15
  return openBlock(), createElementBlock("div", _hoisted_1, [
16
16
  createElementVNode("img", {
17
- src: unref(logoUrl),
17
+ src: logoUrl.value,
18
18
  alt: "Logo",
19
19
  class: "htw-w-64 htw-h-64 htw-opacity-25"
20
20
  }, null, 8, _hoisted_2)
@@ -56,7 +56,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
56
56
  onClick: _cache[1] || (_cache[1] = ($event) => unref(toggleDark)())
57
57
  }, [
58
58
  createVNode(unref(Icon), {
59
- icon: unref(themeIcon),
59
+ icon: themeIcon.value,
60
60
  class: "htw-w-6 htw-h-6 sm:htw-w-4 sm:htw-h-4"
61
61
  }, null, 8, ["icon"])
62
62
  ])), [
@@ -1,4 +1,4 @@
1
- import { defineComponent, computed, openBlock, createElementBlock, unref } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, openBlock, createElementBlock } from "@histoire/vendors/vue";
2
2
  import { isDark } from "../../util/dark.js";
3
3
  import { histoireConfig, customLogos } from "../../util/config.js";
4
4
  import HistoireLogoDark from "../../assets/histoire-text-dark.svg.js";
@@ -19,8 +19,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
19
19
  return (_ctx, _cache) => {
20
20
  return openBlock(), createElementBlock("img", {
21
21
  class: "histoire-app-logo",
22
- src: unref(logoUrl),
23
- alt: unref(altText)
22
+ src: logoUrl.value,
23
+ alt: altText.value
24
24
  }, null, 8, _hoisted_1);
25
25
  };
26
26
  }
@@ -1,4 +1,4 @@
1
- import { pushScopeId, popScopeId, createElementVNode, defineComponent, useCssVars, unref, computed, ref, watch, openBlock, createElementBlock, Fragment, renderList, toDisplayString, createVNode, normalizeClass, createTextVNode, withCtx } from "@histoire/vendors/vue";
1
+ import { pushScopeId, popScopeId, createElementVNode, defineComponent, useCssVars, computed, ref, watch, openBlock, createElementBlock, Fragment, renderList, toDisplayString, createVNode, unref, normalizeClass, createTextVNode, withCtx } from "@histoire/vendors/vue";
2
2
  import { Icon } from "@histoire/vendors/iconify";
3
3
  import { useStoryStore } from "../../stores/story.js";
4
4
  import "./MobileOverlay.vue.js";
@@ -14,14 +14,14 @@ const _hoisted_4 = { class: "htw-opacity-40 htw-text-sm" };
14
14
  const _sfc_main = /* @__PURE__ */ defineComponent({
15
15
  __name: "Breadcrumb",
16
16
  props: {
17
- tree: null,
18
- stories: null
17
+ tree: {},
18
+ stories: {}
19
19
  },
20
20
  setup(__props) {
21
21
  useCssVars((_ctx) => {
22
22
  var _a;
23
23
  return {
24
- "5792748b": (_a = unref(story)) == null ? void 0 : _a.iconColor
24
+ "5792748b": (_a = story.value) == null ? void 0 : _a.iconColor
25
25
  };
26
26
  });
27
27
  const storyStore = useStoryStore();
@@ -46,8 +46,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
46
46
  class: "htw-px-6 htw-h-12 hover:htw-text-primary-500 dark:hover:htw-text-primary-400 htw-cursor-pointer htw-flex htw-gap-2 htw-flex-wrap htw-w-full htw-items-center",
47
47
  onClick: openMenu
48
48
  }, [
49
- unref(story) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
50
- (openBlock(true), createElementBlock(Fragment, null, renderList(unref(folders), (file, key) => {
49
+ story.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
50
+ (openBlock(true), createElementBlock(Fragment, null, renderList(folders.value, (file, key) => {
51
51
  return openBlock(), createElementBlock(Fragment, { key }, [
52
52
  createElementVNode("span", null, toDisplayString(file), 1),
53
53
  _hoisted_2
@@ -55,14 +55,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
55
55
  }), 128)),
56
56
  createElementVNode("span", _hoisted_3, [
57
57
  createVNode(unref(Icon), {
58
- icon: unref(story).icon ?? "carbon:cube",
58
+ icon: story.value.icon ?? "carbon:cube",
59
59
  class: normalizeClass(["htw-w-5 htw-h-5 htw-flex-none", {
60
- "htw-text-primary-500": !unref(story).iconColor,
61
- "bind-icon-color": unref(story).iconColor
60
+ "htw-text-primary-500": !story.value.iconColor,
61
+ "bind-icon-color": story.value.iconColor
62
62
  }])
63
63
  }, null, 8, ["icon", "class"]),
64
- createTextVNode(" " + toDisplayString(unref(story).title) + " ", 1),
65
- createElementVNode("span", _hoisted_4, toDisplayString(unref(story).variants.length), 1)
64
+ createTextVNode(" " + toDisplayString(story.value.title) + " ", 1),
65
+ createElementVNode("span", _hoisted_4, toDisplayString(story.value.variants.length), 1)
66
66
  ])
67
67
  ], 64)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
68
68
  createTextVNode(" Select a story... ")
@@ -80,8 +80,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
80
80
  }, {
81
81
  default: withCtx(() => [
82
82
  createVNode(_sfc_main$2, {
83
- tree: __props.tree,
84
- stories: __props.stories,
83
+ tree: _ctx.tree,
84
+ stories: _ctx.stories,
85
85
  class: "htw-flex-1 htw-overflow-y-scroll"
86
86
  }, null, 8, ["tree", "stories"])
87
87
  ]),
@@ -10,20 +10,20 @@ const _hoisted_3 = { class: "htw-text-gray-500" };
10
10
  const _sfc_main = /* @__PURE__ */ defineComponent({
11
11
  __name: "MobileOverlay",
12
12
  props: {
13
- title: null,
13
+ title: {},
14
14
  opened: { type: Boolean }
15
15
  },
16
16
  emits: ["close"],
17
- setup(__props, { emit: emits }) {
17
+ setup(__props, { emit }) {
18
18
  return (_ctx, _cache) => {
19
19
  return openBlock(), createBlock(Transition, { name: "__histoire-fade-bottom" }, {
20
20
  default: withCtx(() => [
21
- __props.opened ? (openBlock(), createElementBlock("div", _hoisted_1, [
21
+ _ctx.opened ? (openBlock(), createElementBlock("div", _hoisted_1, [
22
22
  createElementVNode("div", _hoisted_2, [
23
- createElementVNode("span", _hoisted_3, toDisplayString(__props.title), 1),
23
+ createElementVNode("span", _hoisted_3, toDisplayString(_ctx.title), 1),
24
24
  createElementVNode("a", {
25
25
  class: "htw-p-1 hover:htw-text-primary-500 dark:hover:htw-text-primary-400 htw-cursor-pointer",
26
- onClick: _cache[0] || (_cache[0] = ($event) => emits("close"))
26
+ onClick: _cache[0] || (_cache[0] = ($event) => emit("close"))
27
27
  }, [
28
28
  createVNode(unref(Icon), {
29
29
  icon: "carbon:close",
@@ -1,12 +1,12 @@
1
- import { defineComponent, computed, openBlock, createBlock, resolveDynamicComponent, unref, normalizeClass, withCtx, renderSlot } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, openBlock, createBlock, resolveDynamicComponent, normalizeClass, withCtx, renderSlot } from "@histoire/vendors/vue";
2
2
  import { RouterLink } from "@histoire/vendors/vue-router";
3
3
  "use strict";
4
4
  const _sfc_main = /* @__PURE__ */ defineComponent({
5
5
  __name: "BaseButton",
6
6
  props: {
7
- to: null,
8
- href: null,
9
- color: null
7
+ to: {},
8
+ href: {},
9
+ color: {}
10
10
  },
11
11
  setup(__props) {
12
12
  const props = __props;
@@ -20,10 +20,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
20
20
  return "button";
21
21
  });
22
22
  return (_ctx, _cache) => {
23
- return openBlock(), createBlock(resolveDynamicComponent(unref(comp)), {
23
+ return openBlock(), createBlock(resolveDynamicComponent(comp.value), {
24
24
  class: normalizeClass(["histoire-base-button htw-rounded htw-cursor-pointer", {
25
- "htw-bg-primary-200 dark:htw-bg-primary-800 hover:htw-bg-primary-300 dark:hover:htw-bg-primary-700": __props.color === "primary" || !__props.color,
26
- "htw-bg-grey-100 dark:htw-bg-grey-900 hover:htw-bg-grey-200 dark:hover:htw-bg-grey-800": __props.color === "grey"
25
+ "htw-bg-primary-200 dark:htw-bg-primary-800 hover:htw-bg-primary-300 dark:hover:htw-bg-primary-700": _ctx.color === "primary" || !_ctx.color,
26
+ "htw-bg-grey-100 dark:htw-bg-grey-900 hover:htw-bg-grey-200 dark:hover:htw-bg-grey-800": _ctx.color === "grey"
27
27
  }])
28
28
  }, {
29
29
  default: withCtx(() => [
@@ -1,4 +1,4 @@
1
- import { defineComponent, ref, computed, watch, openBlock, createElementBlock, withKeys, withModifiers, createElementVNode, normalizeClass, unref, renderSlot } from "@histoire/vendors/vue";
1
+ import { defineComponent, ref, computed, watch, openBlock, createElementBlock, withKeys, withModifiers, createElementVNode, normalizeClass, renderSlot } from "@histoire/vendors/vue";
2
2
  "use strict";
3
3
  const _hoisted_1 = { class: "htw-text-white htw-w-[16px] htw-h-[16px] htw-relative" };
4
4
  const _hoisted_2 = {
@@ -65,7 +65,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
65
65
  }
66
66
  ]]),
67
67
  "stroke-dasharray": dasharray.value,
68
- "stroke-dashoffset": unref(dashoffset)
68
+ "stroke-dashoffset": dashoffset.value
69
69
  }, null, 10, _hoisted_3)
70
70
  ]))
71
71
  ]),
@@ -1,4 +1,4 @@
1
- import { defineComponent, computed, unref, openBlock, createElementBlock, createBlock, pushScopeId, popScopeId } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, openBlock, createElementBlock, createBlock, unref, pushScopeId, popScopeId } from "@histoire/vendors/vue";
2
2
  import { Icon } from "@histoire/vendors/iconify";
3
3
  "use strict";
4
4
  const _withScopeId = (n) => (pushScopeId("data-v-74182813"), n = n(), popScopeId(), n);
@@ -6,20 +6,20 @@ const _hoisted_1 = ["src", "alt"];
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "BaseIcon",
8
8
  props: {
9
- icon: null
9
+ icon: {}
10
10
  },
11
11
  setup(__props) {
12
12
  const props = __props;
13
13
  const isUrl = computed(() => props.icon.startsWith("http") || props.icon.startsWith("data:image") || props.icon.startsWith(".") || props.icon.startsWith("/"));
14
14
  return (_ctx, _cache) => {
15
- return unref(isUrl) ? (openBlock(), createElementBlock("img", {
15
+ return isUrl.value ? (openBlock(), createElementBlock("img", {
16
16
  key: 0,
17
- src: __props.icon,
18
- alt: __props.icon,
17
+ src: _ctx.icon,
18
+ alt: _ctx.icon,
19
19
  class: "histoire-base-icon"
20
20
  }, null, 8, _hoisted_1)) : (openBlock(), createBlock(unref(Icon), {
21
21
  key: 1,
22
- icon: __props.icon,
22
+ icon: _ctx.icon,
23
23
  class: "histoire-base-icon"
24
24
  }, null, 8, ["icon"]));
25
25
  };
@@ -1,17 +1,17 @@
1
- import { defineComponent, computed, openBlock, createElementBlock, toDisplayString, unref } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, openBlock, createElementBlock, toDisplayString } from "@histoire/vendors/vue";
2
2
  import { formatKey } from "../../util/keyboard.js";
3
3
  "use strict";
4
4
  const _hoisted_1 = { class: "histoire-base-keyboard-shortcut htw-border htw-border-current htw-opacity-50 htw-px-1 htw-rounded-sm" };
5
5
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
6
  __name: "BaseKeyboardShortcut",
7
7
  props: {
8
- shortcut: null
8
+ shortcut: {}
9
9
  },
10
10
  setup(__props) {
11
11
  const props = __props;
12
12
  const formatted = computed(() => props.shortcut.split("+").map((k) => formatKey(k.trim())).join(" "));
13
13
  return (_ctx, _cache) => {
14
- return openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(unref(formatted)), 1);
14
+ return openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(formatted.value), 1);
15
15
  };
16
16
  }
17
17
  });
@@ -14,7 +14,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
14
14
  return openBlock(), createElementBlock("a", {
15
15
  class: normalizeClass(["istoire-base-list-ite htw-flex htw-items-center htw-gap-2 htw-text-gray-900 dark:htw-text-gray-100", [
16
16
  _ctx.$attrs.class,
17
- __props.isActive ? "active htw-bg-primary-500 hover:htw-bg-primary-600 htw-text-white dark:htw-text-black" : "hover:htw-bg-primary-100 dark:hover:htw-bg-primary-900"
17
+ _ctx.isActive ? "active htw-bg-primary-500 hover:htw-bg-primary-600 htw-text-white dark:htw-text-black" : "hover:htw-bg-primary-100 dark:hover:htw-bg-primary-900"
18
18
  ]]),
19
19
  onClick: _cache[0] || (_cache[0] = ($event) => handleNavigate()),
20
20
  onKeyup: [
@@ -1,4 +1,4 @@
1
- import { defineComponent, ref, computed, resolveComponent, openBlock, createElementBlock, createVNode, withCtx, renderSlot, unref, createBlock, createElementVNode, createCommentVNode, reactive, onBeforeUnmount, h } from "@histoire/vendors/vue";
1
+ import { defineComponent, ref, computed, resolveComponent, openBlock, createElementBlock, createVNode, withCtx, renderSlot, createBlock, createElementVNode, unref, createCommentVNode, reactive, onBeforeUnmount, h } from "@histoire/vendors/vue";
2
2
  import { useResizeObserver } from "@histoire/vendors/vue-use";
3
3
  import { Icon } from "@histoire/vendors/iconify";
4
4
  "use strict";
@@ -7,10 +7,10 @@ const _hoisted_1 = {
7
7
  class: "htw-cursor-pointer hover:htw-bg-primary-50 dark:hover:htw-bg-primary-900 htw-w-8 htw-h-full htw-flex htw-items-center htw-justify-center htw-absolute htw-top-0 htw-right-0"
8
8
  };
9
9
  const _hoisted_2 = { class: "htw-flex htw-flex-col htw-items-stretch" };
10
+ const overflowButtonWidth = 32;
10
11
  const _sfc_main = /* @__PURE__ */ defineComponent({
11
12
  __name: "BaseOverflowMenu",
12
13
  setup(__props) {
13
- const overflowButtonWidth = 32;
14
14
  const el = ref();
15
15
  const availableWidth = ref(0);
16
16
  useResizeObserver(el, (entries) => {
@@ -70,10 +70,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
70
70
  ]),
71
71
  _: 3
72
72
  }),
73
- unref(visibleChildrenCount) < children.value.size ? (openBlock(), createBlock(_component_VDropdown, { key: 0 }, {
73
+ visibleChildrenCount.value < children.value.size ? (openBlock(), createBlock(_component_VDropdown, { key: 0 }, {
74
74
  popper: withCtx(() => [
75
75
  createElementVNode("div", _hoisted_2, [
76
- createVNode(ChildrenSlice, { start: unref(visibleChildrenCount) }, {
76
+ createVNode(ChildrenSlice, { start: visibleChildrenCount.value }, {
77
77
  default: withCtx(() => [
78
78
  renderSlot(_ctx.$slots, "overflow")
79
79
  ]),
@@ -9,11 +9,11 @@ const _hoisted_4 = ["onClick"];
9
9
  const _sfc_main = /* @__PURE__ */ defineComponent({
10
10
  __name: "BaseSelect",
11
11
  props: {
12
- modelValue: null,
13
- options: null
12
+ modelValue: {},
13
+ options: {}
14
14
  },
15
15
  emits: ["update:modelValue", "select"],
16
- setup(__props, { emit: emits }) {
16
+ setup(__props, { emit }) {
17
17
  const props = __props;
18
18
  const formattedOptions = computed(() => {
19
19
  if (Array.isArray(props.options)) {
@@ -23,8 +23,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
23
23
  });
24
24
  const selectedLabel = computed(() => formattedOptions.value[props.modelValue]);
25
25
  function selectValue(value, hide) {
26
- emits("update:modelValue", value);
27
- emits("select", value);
26
+ emit("update:modelValue", value);
27
+ emit("select", value);
28
28
  hide();
29
29
  }
30
30
  return (_ctx, _cache) => {
@@ -35,7 +35,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
35
35
  }, {
36
36
  popper: withCtx(({ hide }) => [
37
37
  createElementVNode("div", _hoisted_3, [
38
- (openBlock(true), createElementBlock(Fragment, null, renderList(unref(formattedOptions), (label, value) => {
38
+ (openBlock(true), createElementBlock(Fragment, null, renderList(formattedOptions.value, (label, value) => {
39
39
  return openBlock(), createElementBlock("div", mergeProps({ ..._ctx.$attrs, class: null, style: null }, {
40
40
  key: label,
41
41
  class: ["htw-px-2 htw-py-1 htw-cursor-pointer hover:htw-bg-primary-100 dark:hover:htw-bg-primary-700", {
@@ -56,8 +56,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
56
56
  default: withCtx(() => [
57
57
  createElementVNode("div", _hoisted_1, [
58
58
  createElementVNode("div", _hoisted_2, [
59
- renderSlot(_ctx.$slots, "default", { label: unref(selectedLabel) }, () => [
60
- createTextVNode(toDisplayString(unref(selectedLabel)), 1)
59
+ renderSlot(_ctx.$slots, "default", { label: selectedLabel.value }, () => [
60
+ createTextVNode(toDisplayString(selectedLabel.value), 1)
61
61
  ])
62
62
  ]),
63
63
  createVNode(unref(Icon), {
@@ -1,7 +1,8 @@
1
- import { defineComponent, ref, watch, computed, onUnmounted, openBlock, createElementBlock, normalizeClass, createElementVNode, normalizeStyle, unref, renderSlot, withModifiers, pushScopeId, popScopeId } from "@histoire/vendors/vue";
1
+ import { defineComponent, ref, watch, computed, onUnmounted, openBlock, createElementBlock, normalizeClass, createElementVNode, normalizeStyle, renderSlot, withModifiers, pushScopeId, popScopeId } from "@histoire/vendors/vue";
2
2
  "use strict";
3
3
  const _withScopeId = (n) => (pushScopeId("data-v-ed925107"), n = n(), popScopeId(), n);
4
4
  const _hoisted_1 = ["onMousedown"];
5
+ const SAVE_PREFIX = "__histoire";
5
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
7
  __name: "BaseSplitPane",
7
8
  props: {
@@ -46,7 +47,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
46
47
  },
47
48
  setup(__props, { emit }) {
48
49
  const props = __props;
49
- const SAVE_PREFIX = "__histoire";
50
50
  const currentSplit = ref(props.defaultSplit);
51
51
  watch(() => props.split, (value) => {
52
52
  if (value !== void 0) {
@@ -153,7 +153,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
153
153
  "htw-border-r htw-border-gray-300/30 dark:htw-border-gray-800": __props.orientation === "landscape",
154
154
  "htw-flex-none": __props.fixed
155
155
  }]),
156
- style: normalizeStyle(unref(leftStyle))
156
+ style: normalizeStyle(leftStyle.value)
157
157
  }, [
158
158
  renderSlot(_ctx.$slots, "first", {}, void 0, true),
159
159
  createElementVNode("div", {
@@ -172,7 +172,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
172
172
  "htw-border-t htw-border-gray-300/30 dark:htw-border-gray-800": __props.orientation === "portrait",
173
173
  "htw-flex-1": __props.fixed
174
174
  }]),
175
- style: normalizeStyle(unref(rightStyle))
175
+ style: normalizeStyle(rightStyle.value)
176
176
  }, [
177
177
  renderSlot(_ctx.$slots, "last", {}, void 0, true)
178
178
  ], 6)
@@ -15,7 +15,7 @@ const _hoisted_3 = /* @__PURE__ */ createElementVNode("span", null, "Submit", -1
15
15
  const _sfc_main = /* @__PURE__ */ defineComponent({
16
16
  __name: "CommandPrompts",
17
17
  props: {
18
- command: null
18
+ command: {}
19
19
  },
20
20
  emits: ["close"],
21
21
  setup(__props, { emit }) {
@@ -58,8 +58,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
58
58
  onSubmit: _cache[0] || (_cache[0] = withModifiers(($event) => submit(), ["prevent"])),
59
59
  onKeyup: _cache[1] || (_cache[1] = withKeys(($event) => _ctx.$emit("close"), ["escape"]))
60
60
  }, [
61
- createElementVNode("div", _hoisted_1, toDisplayString(__props.command.label), 1),
62
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.command.prompts, (prompt, index) => {
61
+ createElementVNode("div", _hoisted_1, toDisplayString(_ctx.command.label), 1),
62
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.command.prompts, (prompt, index) => {
63
63
  return openBlock(), createBlock(resolveDynamicComponent(promptTypes[prompt.type]), {
64
64
  key: prompt.field,
65
65
  ref_for: true,
@@ -1,4 +1,4 @@
1
- import { defineComponent, computed, ref, watchEffect, openBlock, createElementBlock, withDirectives, createElementVNode, isRef, vModelText, unref, toDisplayString, createCommentVNode, createTextVNode, createVNode, withKeys, withModifiers, Fragment, renderList, normalizeClass, createBlock } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, ref, watchEffect, openBlock, createElementBlock, withDirectives, createElementVNode, vModelText, toDisplayString, createCommentVNode, createTextVNode, createVNode, withKeys, withModifiers, unref, Fragment, renderList, normalizeClass, createBlock } from "@histoire/vendors/vue";
2
2
  import { Icon } from "@histoire/vendors/iconify";
3
3
  import { useSelection } from "../../util/select.js";
4
4
  import "../base/BaseKeyboardShortcut.vue.js";
@@ -19,12 +19,12 @@ const _hoisted_9 = { class: "htw-flex-1" };
19
19
  const _sfc_main = /* @__PURE__ */ defineComponent({
20
20
  __name: "PromptSelect",
21
21
  props: {
22
- modelValue: null,
23
- prompt: null,
24
- answers: null
22
+ modelValue: {},
23
+ prompt: {},
24
+ answers: {}
25
25
  },
26
26
  emits: ["update:modelValue", "next"],
27
- setup(__props, { expose, emit }) {
27
+ setup(__props, { expose: __expose, emit }) {
28
28
  const props = __props;
29
29
  const model = computed({
30
30
  get: () => props.modelValue,
@@ -39,7 +39,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
39
39
  (_a = input.value) == null ? void 0 : _a.focus();
40
40
  (_b = input.value) == null ? void 0 : _b.select();
41
41
  }
42
- expose({
42
+ __expose({
43
43
  focus
44
44
  });
45
45
  const search = ref("");
@@ -82,17 +82,17 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
82
82
  return (_ctx, _cache) => {
83
83
  return openBlock(), createElementBlock("div", _hoisted_1, [
84
84
  withDirectives(createElementVNode("input", {
85
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(model) ? model.value = $event : null),
86
- required: __props.prompt.required,
85
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => model.value = $event),
86
+ required: _ctx.prompt.required,
87
87
  tabindex: "-1",
88
88
  class: "htw-absolute htw-inset-0 htw-opacity-0 htw-pointer-events-none"
89
89
  }, null, 8, _hoisted_2), [
90
- [vModelText, unref(model)]
90
+ [vModelText, model.value]
91
91
  ]),
92
92
  createElementVNode("label", _hoisted_3, [
93
93
  createElementVNode("span", _hoisted_4, [
94
- createElementVNode("span", null, toDisplayString(__props.prompt.label), 1),
95
- __props.prompt.required ? (openBlock(), createElementBlock("span", _hoisted_5, "*")) : createCommentVNode("", true),
94
+ createElementVNode("span", null, toDisplayString(_ctx.prompt.label), 1),
95
+ _ctx.prompt.required ? (openBlock(), createElementBlock("span", _hoisted_5, "*")) : createCommentVNode("", true),
96
96
  createElementVNode("span", _hoisted_6, [
97
97
  createTextVNode(" Press "),
98
98
  createVNode(_sfc_main$1, { shortcut: "Space" }),
@@ -114,18 +114,18 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
114
114
  ])
115
115
  ]),
116
116
  createElementVNode("div", _hoisted_7, [
117
- (openBlock(true), createElementBlock(Fragment, null, renderList(unref(formattedOptions), (option, index) => {
117
+ (openBlock(true), createElementBlock(Fragment, null, renderList(formattedOptions.value, (option, index) => {
118
118
  return openBlock(), createElementBlock("button", {
119
119
  key: option.value,
120
120
  type: "button",
121
121
  tabindex: "-1",
122
122
  class: normalizeClass([[
123
- unref(model) === option.value ? "htw-bg-primary-500/20" : index === unref(selectedIndex) ? "htw-bg-primary-500/10" : "htw-bg-transparent"
123
+ model.value === option.value ? "htw-bg-primary-500/20" : index === unref(selectedIndex) ? "htw-bg-primary-500/10" : "htw-bg-transparent"
124
124
  ], "htw-w-full htw-text-left htw-px-4 htw-py-2 hover:htw-bg-primary-500/10 htw-flex htw-items-center"]),
125
125
  onClick: ($event) => model.value = option.value
126
126
  }, [
127
127
  createElementVNode("span", _hoisted_9, toDisplayString(option.label), 1),
128
- unref(model) === option.value ? (openBlock(), createBlock(unref(Icon), {
128
+ model.value === option.value ? (openBlock(), createBlock(unref(Icon), {
129
129
  key: 0,
130
130
  icon: "carbon:checkmark",
131
131
  class: "htw-w-4 htw-h-4 htw-text-primary-500"
@@ -1,4 +1,4 @@
1
- import { defineComponent, computed, ref, watch, openBlock, createElementBlock, createElementVNode, toDisplayString, createCommentVNode, withDirectives, isRef, vModelText, unref } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, ref, watch, openBlock, createElementBlock, createElementVNode, toDisplayString, createCommentVNode, withDirectives, vModelText } from "@histoire/vendors/vue";
2
2
  "use strict";
3
3
  const _hoisted_1 = { class: "histoire-prompt-text" };
4
4
  const _hoisted_2 = { class: "htw-flex htw-flex-col htw-gap-2 htw-p-2" };
@@ -11,12 +11,12 @@ const _hoisted_5 = ["required"];
11
11
  const _sfc_main = /* @__PURE__ */ defineComponent({
12
12
  __name: "PromptText",
13
13
  props: {
14
- modelValue: null,
15
- prompt: null,
16
- answers: null
14
+ modelValue: {},
15
+ prompt: {},
16
+ answers: {}
17
17
  },
18
18
  emits: ["update:modelValue"],
19
- setup(__props, { expose, emit }) {
19
+ setup(__props, { expose: __expose, emit }) {
20
20
  const props = __props;
21
21
  const model = computed({
22
22
  get: () => props.modelValue,
@@ -28,7 +28,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
28
28
  (_a = input.value) == null ? void 0 : _a.focus();
29
29
  (_b = input.value) == null ? void 0 : _b.select();
30
30
  }
31
- expose({
31
+ __expose({
32
32
  focus
33
33
  });
34
34
  const defaultValue = computed(() => {
@@ -45,17 +45,17 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
45
45
  return openBlock(), createElementBlock("div", _hoisted_1, [
46
46
  createElementVNode("label", _hoisted_2, [
47
47
  createElementVNode("span", _hoisted_3, [
48
- createElementVNode("span", null, toDisplayString(__props.prompt.label), 1),
49
- __props.prompt.required ? (openBlock(), createElementBlock("span", _hoisted_4, "*")) : createCommentVNode("", true)
48
+ createElementVNode("span", null, toDisplayString(_ctx.prompt.label), 1),
49
+ _ctx.prompt.required ? (openBlock(), createElementBlock("span", _hoisted_4, "*")) : createCommentVNode("", true)
50
50
  ]),
51
51
  withDirectives(createElementVNode("input", {
52
52
  ref_key: "input",
53
53
  ref: input,
54
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(model) ? model.value = $event : null),
54
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => model.value = $event),
55
55
  class: "htw-bg-transparent htw-w-full htw-p-2 htw-border htw-border-gray-500/50 focus:htw-border-primary-500/50 htw-rounded htw-outline-none",
56
- required: __props.prompt.required
56
+ required: _ctx.prompt.required
57
57
  }, null, 8, _hoisted_5), [
58
- [vModelText, unref(model)]
58
+ [vModelText, model.value]
59
59
  ])
60
60
  ])
61
61
  ]);
@@ -1,13 +1,13 @@
1
- import { defineComponent, computed, resolveDirective, unref, openBlock, createBlock, resolveDynamicComponent, isRef, withCtx, withDirectives, createVNode, normalizeClass, withModifiers, createCommentVNode } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, resolveDirective, openBlock, createBlock, resolveDynamicComponent, withCtx, withDirectives, createVNode, unref, normalizeClass, withModifiers, createCommentVNode } from "@histoire/vendors/vue";
2
2
  import { Icon } from "@histoire/vendors/iconify";
3
3
  import { HstJson, HstCheckbox, HstNumber, HstText } from "@histoire/controls";
4
4
  "use strict";
5
5
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
6
  __name: "ControlsComponentPropItem",
7
7
  props: {
8
- variant: null,
9
- component: null,
10
- definition: null
8
+ variant: {},
9
+ component: {},
10
+ definition: {}
11
11
  },
12
12
  setup(__props) {
13
13
  const props = __props;
@@ -48,18 +48,18 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
48
48
  });
49
49
  return (_ctx, _cache) => {
50
50
  const _directive_tooltip = resolveDirective("tooltip");
51
- return unref(comp) ? (openBlock(), createBlock(resolveDynamicComponent(unref(comp)), {
51
+ return comp.value ? (openBlock(), createBlock(resolveDynamicComponent(comp.value), {
52
52
  key: 0,
53
- modelValue: unref(model),
54
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => isRef(model) ? model.value = $event : null),
53
+ modelValue: model.value,
54
+ "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => model.value = $event),
55
55
  class: "histoire-controls-component-prop-item",
56
- title: `${__props.definition.name}${unref(canReset) ? " *" : ""}`
56
+ title: `${_ctx.definition.name}${canReset.value ? " *" : ""}`
57
57
  }, {
58
58
  actions: withCtx(() => [
59
59
  withDirectives(createVNode(unref(Icon), {
60
60
  icon: "carbon:erase",
61
61
  class: normalizeClass(["htw-cursor-pointer htw-w-4 htw-h-4 hover:htw-text-primary-500 dark:hover:htw-text-primary-400 htw-text-gray-900 dark:htw-text-gray-100", [
62
- unref(canReset) ? "htw-opacity-50 hover:htw-opacity-100" : "htw-opacity-25 htw-pointer-events-none"
62
+ canReset.value ? "htw-opacity-50 hover:htw-opacity-100" : "htw-opacity-25 htw-pointer-events-none"
63
63
  ]]),
64
64
  onClick: _cache[0] || (_cache[0] = withModifiers(($event) => reset(), ["stop"]))
65
65
  }, null, 8, ["class"]), [
@@ -10,8 +10,8 @@ const _hoisted_4 = /* @__PURE__ */ createElementVNode("span", { class: "htw-opac
10
10
  const _sfc_main = /* @__PURE__ */ defineComponent({
11
11
  __name: "ControlsComponentProps",
12
12
  props: {
13
- variant: null,
14
- definition: null
13
+ variant: {},
14
+ definition: {}
15
15
  },
16
16
  setup(__props) {
17
17
  return (_ctx, _cache) => {
@@ -26,15 +26,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
26
26
  ]),
27
27
  createElementVNode("div", null, [
28
28
  _hoisted_3,
29
- createTextVNode(toDisplayString(__props.definition.name), 1),
29
+ createTextVNode(toDisplayString(_ctx.definition.name), 1),
30
30
  _hoisted_4
31
31
  ])
32
32
  ]),
33
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.definition.props, (prop) => {
33
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.definition.props, (prop) => {
34
34
  return openBlock(), createBlock(_sfc_main$1, {
35
35
  key: prop.name,
36
- variant: __props.variant,
37
- component: __props.definition,
36
+ variant: _ctx.variant,
37
+ component: _ctx.definition,
38
38
  definition: prop
39
39
  }, null, 8, ["variant", "component", "definition"]);
40
40
  }), 128))
@@ -11,8 +11,8 @@ import _sfc_main$1 from "../base/BaseOverflowMenu.vue2.js";
11
11
  const _sfc_main = /* @__PURE__ */ defineComponent({
12
12
  __name: "PaneTabs",
13
13
  props: {
14
- story: null,
15
- variant: null
14
+ story: {},
15
+ variant: {}
16
16
  },
17
17
  setup(__props) {
18
18
  const props = __props;
@@ -48,7 +48,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
48
48
  to: { ..._ctx.$route, query: { ..._ctx.$route.query, tab: "events" } },
49
49
  matched: _ctx.$route.query.tab === "events",
50
50
  class: normalizeClass({
51
- "htw-opacity-50": !unref(hasEvents)
51
+ "htw-opacity-50": !hasEvents.value
52
52
  })
53
53
  }, {
54
54
  default: withCtx(() => [
@@ -89,7 +89,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
89
89
  to: { ..._ctx.$route, query: { ..._ctx.$route.query, tab: "events" } },
90
90
  matched: _ctx.$route.query.tab === "events",
91
91
  class: normalizeClass({
92
- "htw-opacity-50": !unref(hasEvents)
92
+ "htw-opacity-50": !hasEvents.value
93
93
  })
94
94
  }, {
95
95
  default: withCtx(() => [