@histoire/app 0.16.4 → 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 +7 -7
  49. package/dist/style.css +530 -527
  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
@@ -5,8 +5,8 @@ import { openInEditor } from "../../util/open-in-editor.js";
5
5
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
6
  __name: "DevOnlyToolbarOpenInEditor",
7
7
  props: {
8
- file: null,
9
- tooltip: null
8
+ file: {},
9
+ tooltip: {}
10
10
  },
11
11
  setup(__props) {
12
12
  return (_ctx, _cache) => {
@@ -14,14 +14,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
14
14
  return withDirectives((openBlock(), createElementBlock("a", {
15
15
  target: "_blank",
16
16
  class: "histoire-toolbar-open-in-editor htw-flex htw-items-center htw-gap-1 htw-h-full htw-px-2 hover:htw-text-primary-500 htw-opacity-50 hover:htw-opacity-100 dark:hover:htw-text-primary-400 htw-text-gray-900 dark:htw-text-gray-100",
17
- onClick: _cache[0] || (_cache[0] = ($event) => unref(openInEditor)(__props.file))
17
+ onClick: _cache[0] || (_cache[0] = ($event) => unref(openInEditor)(_ctx.file))
18
18
  }, [
19
19
  createVNode(unref(Icon), {
20
20
  icon: "carbon:script-reference",
21
21
  class: "htw-w-4 htw-h-4"
22
22
  })
23
23
  ])), [
24
- [_directive_tooltip, __props.tooltip]
24
+ [_directive_tooltip, _ctx.tooltip]
25
25
  ]);
26
26
  };
27
27
  }
@@ -23,7 +23,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
23
23
  setup(__props) {
24
24
  useCssVars((_ctx) => ({
25
25
  "627bec82": unref(settings).backgroundColor,
26
- "35068428": unref(contrastColor)
26
+ "35068428": contrastColor.value
27
27
  }));
28
28
  const settings = usePreviewSettingsStore().currentSettings;
29
29
  const contrastColor = computed(() => getContrastColor(settings));
@@ -79,7 +79,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
79
79
  default: withCtx(() => [
80
80
  withDirectives((openBlock(), createElementBlock("div", _hoisted_1, [
81
81
  createElementVNode("div", _hoisted_2, [
82
- unref(contrastColor) ? (openBlock(), createElementBlock("span", _hoisted_3, "a")) : createCommentVNode("", true)
82
+ contrastColor.value ? (openBlock(), createElementBlock("span", _hoisted_3, "a")) : createCommentVNode("", true)
83
83
  ]),
84
84
  createVNode(unref(Icon), {
85
85
  icon: "carbon:caret-down",
@@ -1,4 +1,4 @@
1
- import { defineComponent, computed, resolveDirective, withDirectives, openBlock, createElementBlock, unref, createVNode } from "@histoire/vendors/vue";
1
+ import { defineComponent, computed, resolveDirective, withDirectives, openBlock, createElementBlock, createVNode, unref } from "@histoire/vendors/vue";
2
2
  import { Icon } from "@histoire/vendors/iconify";
3
3
  import { getSandboxUrl } from "../../util/sandbox.js";
4
4
  "use strict";
@@ -6,8 +6,8 @@ const _hoisted_1 = ["href"];
6
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
7
7
  __name: "ToolbarNewTab",
8
8
  props: {
9
- variant: null,
10
- story: null
9
+ variant: {},
10
+ story: {}
11
11
  },
12
12
  setup(__props) {
13
13
  const props = __props;
@@ -17,7 +17,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
17
17
  return (_ctx, _cache) => {
18
18
  const _directive_tooltip = resolveDirective("tooltip");
19
19
  return withDirectives((openBlock(), createElementBlock("a", {
20
- href: unref(sandboxUrl),
20
+ href: sandboxUrl.value,
21
21
  target: "_blank",
22
22
  class: "histoire-toolbar-new-tab htw-flex htw-items-center htw-gap-1 htw-h-full htw-px-2 hover:htw-text-primary-500 htw-opacity-50 hover:htw-opacity-100 dark:hover:htw-text-primary-400 htw-text-gray-900 dark:htw-text-gray-100"
23
23
  }, [
@@ -5,18 +5,18 @@ const _hoisted_1 = { class: "histoire-toolbar-title htw-flex htw-items-center ht
5
5
  const _sfc_main = /* @__PURE__ */ defineComponent({
6
6
  __name: "ToolbarTitle",
7
7
  props: {
8
- variant: null
8
+ variant: {}
9
9
  },
10
10
  setup(__props) {
11
11
  return (_ctx, _cache) => {
12
12
  return openBlock(), createElementBlock("div", _hoisted_1, [
13
13
  createVNode(unref(Icon), {
14
- icon: __props.variant.icon ?? "carbon:cube",
14
+ icon: _ctx.variant.icon ?? "carbon:cube",
15
15
  class: normalizeClass(["htw-w-4 htw-h-4 htw-opacity-50", [
16
- __props.variant.iconColor ? "bind-icon-color" : "htw-text-gray-500"
16
+ _ctx.variant.iconColor ? "bind-icon-color" : "htw-text-gray-500"
17
17
  ]])
18
18
  }, null, 8, ["icon", "class"]),
19
- createElementVNode("span", null, toDisplayString(__props.variant.title), 1)
19
+ createElementVNode("span", null, toDisplayString(_ctx.variant.title), 1)
20
20
  ]);
21
21
  };
22
22
  }
@@ -16,8 +16,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
16
16
  __name: "StoryGroup",
17
17
  props: {
18
18
  path: { default: () => [] },
19
- group: null,
20
- stories: null
19
+ group: {},
20
+ stories: {}
21
21
  },
22
22
  setup(__props) {
23
23
  const props = __props;
@@ -29,7 +29,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
29
29
  }
30
30
  return (_ctx, _cache) => {
31
31
  return openBlock(), createElementBlock("div", _hoisted_1, [
32
- __props.group.title ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
32
+ _ctx.group.title ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
33
33
  _hoisted_2,
34
34
  createElementVNode("div", {
35
35
  role: "button",
@@ -42,26 +42,26 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
42
42
  ]
43
43
  }, [
44
44
  createVNode(unref(Icon), {
45
- icon: unref(isFolderOpen) ? "ri:subtract-line" : "ri:add-line",
45
+ icon: isFolderOpen.value ? "ri:subtract-line" : "ri:add-line",
46
46
  class: "htw-w-4 htw-h-4 htw-ml-4 htw-rounded-sm htw-border htw-border-gray-500/40"
47
47
  }, null, 8, ["icon"]),
48
- createElementVNode("span", _hoisted_4, toDisplayString(__props.group.title), 1)
48
+ createElementVNode("span", _hoisted_4, toDisplayString(_ctx.group.title), 1)
49
49
  ], 40, _hoisted_3)
50
50
  ], 64)) : createCommentVNode("", true),
51
- unref(isFolderOpen) ? (openBlock(), createElementBlock("div", _hoisted_5, [
52
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.group.children, (element) => {
51
+ isFolderOpen.value ? (openBlock(), createElementBlock("div", _hoisted_5, [
52
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.group.children, (element) => {
53
53
  return openBlock(), createElementBlock(Fragment, {
54
54
  key: element.title
55
55
  }, [
56
56
  element.children ? (openBlock(), createBlock(StoryListFolder, {
57
57
  key: 0,
58
- path: unref(folderPath),
58
+ path: folderPath.value,
59
59
  folder: element,
60
- stories: __props.stories,
60
+ stories: _ctx.stories,
61
61
  depth: 0
62
62
  }, null, 8, ["path", "folder", "stories"])) : (openBlock(), createBlock(StoryListItem, {
63
63
  key: 1,
64
- story: __props.stories[element.index],
64
+ story: _ctx.stories[element.index],
65
65
  depth: 0
66
66
  }, null, 8, ["story"]))
67
67
  ], 64);
@@ -8,27 +8,27 @@ const _hoisted_1 = { class: "histoire-story-list htw-overflow-y-auto" };
8
8
  const _sfc_main = /* @__PURE__ */ defineComponent({
9
9
  __name: "StoryList",
10
10
  props: {
11
- tree: null,
12
- stories: null
11
+ tree: {},
12
+ stories: {}
13
13
  },
14
14
  setup(__props) {
15
15
  return (_ctx, _cache) => {
16
16
  return openBlock(), createElementBlock("div", _hoisted_1, [
17
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.tree, (element) => {
17
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.tree, (element) => {
18
18
  return openBlock(), createElementBlock(Fragment, {
19
19
  key: element.title
20
20
  }, [
21
21
  element.group ? (openBlock(), createBlock(_sfc_main$1, {
22
22
  key: 0,
23
23
  group: element,
24
- stories: __props.stories
24
+ stories: _ctx.stories
25
25
  }, null, 8, ["group", "stories"])) : element.children ? (openBlock(), createBlock(StoryListFolder, {
26
26
  key: 1,
27
27
  folder: element,
28
- stories: __props.stories
28
+ stories: _ctx.stories
29
29
  }, null, 8, ["folder", "stories"])) : (openBlock(), createBlock(StoryListItem, {
30
30
  key: 2,
31
- story: __props.stories[element.index]
31
+ story: _ctx.stories[element.index]
32
32
  }, null, 8, ["story"]))
33
33
  ], 64);
34
34
  }), 128))
@@ -1,4 +1,4 @@
1
- import { pushScopeId, popScopeId, defineComponent, useCssVars, unref, computed, resolveComponent, openBlock, createElementBlock, createElementVNode, withKeys, createVNode, normalizeClass, toDisplayString, Fragment, renderList, createBlock, createCommentVNode } from "@histoire/vendors/vue";
1
+ import { pushScopeId, popScopeId, defineComponent, useCssVars, computed, resolveComponent, openBlock, createElementBlock, createElementVNode, withKeys, createVNode, unref, normalizeClass, toDisplayString, Fragment, renderList, createBlock, createCommentVNode } from "@histoire/vendors/vue";
2
2
  import StoryListItem from "./StoryListItem.vue.js";
3
3
  import { Icon } from "@histoire/vendors/iconify";
4
4
  import { useFolderStore } from "../../stores/folder.js";
@@ -17,14 +17,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
17
17
  __name: "StoryListFolder",
18
18
  props: {
19
19
  path: { default: () => [] },
20
- folder: null,
21
- stories: null,
20
+ folder: {},
21
+ stories: {},
22
22
  depth: { default: 0 }
23
23
  },
24
24
  setup(__props) {
25
25
  const props = __props;
26
26
  useCssVars((_ctx) => ({
27
- "6851b0a7": unref(folderPadding)
27
+ "6851b0a7": folderPadding.value
28
28
  }));
29
29
  const folderStore = useFolderStore();
30
30
  const folderPath = computed(() => [...props.path, props.folder.title]);
@@ -53,28 +53,28 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
53
53
  createVNode(unref(Icon), {
54
54
  icon: "carbon:caret-right",
55
55
  class: normalizeClass(["htw-w-full htw-h-full htw-transition-transform htw-duration-150", {
56
- "htw-rotate-90": unref(isFolderOpen)
56
+ "htw-rotate-90": isFolderOpen.value
57
57
  }])
58
58
  }, null, 8, ["class"])
59
59
  ]),
60
- createElementVNode("span", _hoisted_5, toDisplayString(__props.folder.title), 1)
60
+ createElementVNode("span", _hoisted_5, toDisplayString(_ctx.folder.title), 1)
61
61
  ])
62
62
  ], 40, _hoisted_2),
63
- unref(isFolderOpen) ? (openBlock(), createElementBlock("div", _hoisted_6, [
64
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.folder.children, (element) => {
63
+ isFolderOpen.value ? (openBlock(), createElementBlock("div", _hoisted_6, [
64
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.folder.children, (element) => {
65
65
  return openBlock(), createElementBlock(Fragment, {
66
66
  key: element.title
67
67
  }, [
68
68
  element.children ? (openBlock(), createBlock(_component_StoryListFolder, {
69
69
  key: 0,
70
- path: unref(folderPath),
70
+ path: folderPath.value,
71
71
  folder: element,
72
- stories: __props.stories,
73
- depth: __props.depth + 1
72
+ stories: _ctx.stories,
73
+ depth: _ctx.depth + 1
74
74
  }, null, 8, ["path", "folder", "stories", "depth"])) : (openBlock(), createBlock(StoryListItem, {
75
75
  key: 1,
76
- story: __props.stories[element.index],
77
- depth: __props.depth + 1
76
+ story: _ctx.stories[element.index],
77
+ depth: _ctx.depth + 1
78
78
  }, null, 8, ["story", "depth"]))
79
79
  ], 64);
80
80
  }), 128))
@@ -1,4 +1,4 @@
1
- import { pushScopeId, popScopeId, defineComponent, useCssVars, unref, computed, ref, openBlock, createElementBlock, createVNode, withCtx, createElementVNode, normalizeClass, toDisplayString, createCommentVNode } from "@histoire/vendors/vue";
1
+ import { pushScopeId, popScopeId, defineComponent, useCssVars, computed, ref, openBlock, createElementBlock, createVNode, withCtx, createElementVNode, unref, normalizeClass, toDisplayString, createCommentVNode } from "@histoire/vendors/vue";
2
2
  import BaseListItemLink from "../base/BaseListItemLink.vue.js";
3
3
  import { Icon } from "@histoire/vendors/iconify";
4
4
  import { useRoute } from "@histoire/vendors/vue-router";
@@ -14,14 +14,14 @@ const _hoisted_3 = {
14
14
  const _sfc_main = /* @__PURE__ */ defineComponent({
15
15
  __name: "StoryListItem",
16
16
  props: {
17
- story: null,
17
+ story: {},
18
18
  depth: { default: 0 }
19
19
  },
20
20
  setup(__props) {
21
21
  const props = __props;
22
22
  useCssVars((_ctx) => ({
23
- "444efc12": unref(filePadding),
24
- "ae892164": __props.story.iconColor
23
+ "444efc12": filePadding.value,
24
+ "ae892164": _ctx.story.iconColor
25
25
  }));
26
26
  const filePadding = computed(() => {
27
27
  return props.depth * 12 + "px";
@@ -41,7 +41,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
41
41
  to: {
42
42
  name: "story",
43
43
  params: {
44
- storyId: __props.story.id
44
+ storyId: _ctx.story.id
45
45
  }
46
46
  },
47
47
  class: "htw-pl-0.5 htw-pr-2 htw-py-2 md:htw-py-1.5 htw-mx-1 htw-rounded-sm"
@@ -49,15 +49,15 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
49
49
  default: withCtx(({ active }) => [
50
50
  createElementVNode("span", _hoisted_1, [
51
51
  createVNode(unref(Icon), {
52
- icon: __props.story.icon ?? "carbon:cube",
52
+ icon: _ctx.story.icon ?? "carbon:cube",
53
53
  class: normalizeClass(["htw-w-5 htw-h-5 sm:htw-w-4 sm:htw-h-4 htw-flex-none", {
54
- "htw-text-primary-500": !active && !__props.story.iconColor,
55
- "bind-icon-color": !active && __props.story.iconColor
54
+ "htw-text-primary-500": !active && !_ctx.story.iconColor,
55
+ "bind-icon-color": !active && _ctx.story.iconColor
56
56
  }])
57
57
  }, null, 8, ["icon", "class"]),
58
- createElementVNode("span", _hoisted_2, toDisplayString(__props.story.title), 1)
58
+ createElementVNode("span", _hoisted_2, toDisplayString(_ctx.story.title), 1)
59
59
  ]),
60
- !__props.story.docsOnly ? (openBlock(), createElementBlock("span", _hoisted_3, toDisplayString(__props.story.variants.length), 1)) : createCommentVNode("", true)
60
+ !_ctx.story.docsOnly ? (openBlock(), createElementBlock("span", _hoisted_3, toDisplayString(_ctx.story.variants.length), 1)) : createCommentVNode("", true)
61
61
  ]),
62
62
  _: 1
63
63
  }, 8, ["to"])
@@ -44,10 +44,6 @@
44
44
  color: var(--663732b6);
45
45
  }
46
46
 
47
- .bind-tree-padding[data-v-2d2e4786] {
48
- padding-left: var(--6851b0a7);
49
- }
50
-
51
47
  .bind-tree-margin[data-v-19810958] {
52
48
  margin-left: var(--444efc12);
53
49
  }
@@ -55,9 +51,8 @@
55
51
  color: var(--ae892164);
56
52
  }
57
53
 
58
- .__histoire-code-placeholder[data-v-1bdf9905] {
59
- color: inherit;
60
- font-size: inherit;
54
+ .bind-tree-padding[data-v-2d2e4786] {
55
+ padding-left: var(--6851b0a7);
61
56
  }
62
57
 
63
58
  .bind-icon-color[data-v-ab890d9c] {
@@ -68,6 +63,11 @@
68
63
  color: var(--4d25d048);
69
64
  }
70
65
 
66
+ .__histoire-code-placeholder[data-v-1bdf9905] {
67
+ color: inherit;
68
+ font-size: inherit;
69
+ }
70
+
71
71
  .bind-icon-color[data-v-6c8e9661] {
72
72
  color: var(--a8c1277e);
73
73
  }