@poveste/app 0.2.1 → 0.3.1

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 (411) hide show
  1. package/dist/app/style/floating.pcss +16 -10
  2. package/dist/app/style/main.pcss +190 -30
  3. package/dist/app/style/sandbox.css +3 -1
  4. package/dist/app/style/transitions.pcss +49 -50
  5. package/dist/bundled/App.js +5 -0
  6. package/dist/bundled/App.vue_vue_type_script_setup_true_lang.js +169 -0
  7. package/dist/bundled/_virtual/_plugin-vue_export-helper.js +7 -9
  8. package/dist/bundled/api.js +5 -9
  9. package/dist/bundled/app.css +66 -39
  10. package/dist/bundled/assets/poveste-text-dark.js +4 -0
  11. package/dist/bundled/assets/poveste-text.js +4 -0
  12. package/dist/bundled/assets/poveste.js +4 -0
  13. package/dist/bundled/components/HomeView.js +5 -0
  14. package/dist/bundled/components/HomeView.vue_vue_type_script_setup_true_lang.js +62 -0
  15. package/dist/bundled/components/app/AppActions.js +5 -0
  16. package/dist/bundled/components/app/AppActions.vue_vue_type_script_setup_true_lang.js +63 -0
  17. package/dist/bundled/components/app/AppHeader.js +5 -0
  18. package/dist/bundled/components/app/AppHeader.vue_vue_type_script_setup_true_lang.js +21 -0
  19. package/dist/bundled/components/app/AppLogo.js +5 -0
  20. package/dist/bundled/components/app/AppLogo.vue_vue_type_script_setup_true_lang.js +26 -0
  21. package/dist/bundled/components/app/Breadcrumb.js +7 -0
  22. package/dist/bundled/components/app/Breadcrumb.vue_vue_type_script_setup_true_lang.js +68 -0
  23. package/dist/bundled/components/app/HomeCounter.js +7 -0
  24. package/dist/bundled/components/app/HomeCounter.vue_vue_type_script_setup_true_lang.js +55 -0
  25. package/dist/bundled/components/app/InitialLoading.js +5 -0
  26. package/dist/bundled/components/app/InitialLoading.vue_vue_type_script_setup_true_lang.js +34 -0
  27. package/dist/bundled/components/app/MobileOverlay.js +5 -0
  28. package/dist/bundled/components/app/MobileOverlay.vue_vue_type_script_setup_true_lang.js +34 -0
  29. package/dist/bundled/components/app/TopBar.js +5 -0
  30. package/dist/bundled/components/app/TopBar.vue_vue_type_script_setup_true_lang.js +65 -0
  31. package/dist/bundled/components/app/TopBarChip.js +11 -0
  32. package/dist/bundled/components/app/TopBarChipItem.js +11 -0
  33. package/dist/bundled/components/base/BaseButton.js +5 -0
  34. package/dist/bundled/components/base/BaseButton.vue_vue_type_script_setup_true_lang.js +30 -0
  35. package/dist/bundled/components/base/BaseCheckbox.js +5 -0
  36. package/dist/bundled/components/base/BaseCheckbox.vue_vue_type_script_setup_true_lang.js +53 -0
  37. package/dist/bundled/components/base/BaseEmpty.js +12 -0
  38. package/dist/bundled/components/base/BaseIcon.js +7 -0
  39. package/dist/bundled/components/base/BaseIcon.vue_vue_type_script_setup_true_lang.js +26 -0
  40. package/dist/bundled/components/base/BaseKeyboardShortcut.js +5 -0
  41. package/dist/bundled/components/base/BaseKeyboardShortcut.vue_vue_type_script_setup_true_lang.js +17 -0
  42. package/dist/bundled/components/base/BaseListItem.js +5 -0
  43. package/dist/bundled/components/base/BaseListItem.vue_vue_type_script_setup_true_lang.js +22 -0
  44. package/dist/bundled/components/base/BaseListItemLink.js +24 -0
  45. package/dist/bundled/components/base/BaseListItemLink.vue_vue_type_script_lang.js +19 -0
  46. package/dist/bundled/components/base/BaseOverflowMenu.js +5 -0
  47. package/dist/bundled/components/base/BaseOverflowMenu.vue_vue_type_script_setup_true_lang.js +95 -0
  48. package/dist/bundled/components/base/BaseOverflowTab.js +26 -0
  49. package/dist/bundled/components/base/BaseOverflowTab.vue_vue_type_script_lang.js +17 -0
  50. package/dist/bundled/components/base/BaseSelect.js +5 -0
  51. package/dist/bundled/components/base/BaseSelect.vue_vue_type_script_setup_true_lang.js +59 -0
  52. package/dist/bundled/components/base/BaseSplitPane.js +7 -0
  53. package/dist/bundled/components/base/BaseSplitPane.vue_vue_type_script_setup_true_lang.js +159 -0
  54. package/dist/bundled/components/base/BaseTab.js +26 -0
  55. package/dist/bundled/components/base/BaseTab.vue_vue_type_script_lang.js +17 -0
  56. package/dist/bundled/components/base/BaseTag.js +11 -0
  57. package/dist/bundled/components/command/CommandPrompts.js +5 -0
  58. package/dist/bundled/components/command/CommandPrompts.vue_vue_type_script_setup_true_lang.js +86 -0
  59. package/dist/bundled/components/command/CommandPromptsModal.js +5 -0
  60. package/dist/bundled/components/command/CommandPromptsModal.vue_vue_type_script_setup_true_lang.js +35 -0
  61. package/dist/bundled/components/command/PromptSelect.js +5 -0
  62. package/dist/bundled/components/command/PromptSelect.vue_vue_type_script_setup_true_lang.js +111 -0
  63. package/dist/bundled/components/command/PromptText.js +5 -0
  64. package/dist/bundled/components/command/PromptText.vue_vue_type_script_setup_true_lang.js +51 -0
  65. package/dist/bundled/components/layout/LayoutItem.js +5 -0
  66. package/dist/bundled/components/layout/LayoutItem.vue_vue_type_script_setup_true_lang.js +42 -0
  67. package/dist/bundled/components/layout/LayoutItemGroup.js +5 -0
  68. package/dist/bundled/components/layout/LayoutItemGroup.vue_vue_type_script_setup_true_lang.js +19 -0
  69. package/dist/bundled/components/layout/LayoutModal.js +5 -0
  70. package/dist/bundled/components/layout/LayoutModal.vue_vue_type_script_setup_true_lang.js +47 -0
  71. package/dist/bundled/components/layout/LayoutPane.js +5 -0
  72. package/dist/bundled/components/layout/LayoutPane.vue_vue_type_script_setup_true_lang.js +47 -0
  73. package/dist/bundled/components/misc/CheckerboardPattern.js +34 -0
  74. package/dist/bundled/components/misc/HatchedPattern.js +12 -0
  75. package/dist/bundled/components/panel/ControlsComponentPropItem.js +5 -0
  76. package/dist/bundled/components/panel/ControlsComponentPropItem.vue_vue_type_script_setup_true_lang.js +60 -0
  77. package/dist/bundled/components/panel/ControlsComponentProps.js +5 -0
  78. package/dist/bundled/components/panel/ControlsComponentProps.vue_vue_type_script_setup_true_lang.js +39 -0
  79. package/dist/bundled/components/panel/ControlsComponentState.js +5 -0
  80. package/dist/bundled/components/panel/ControlsComponentState.vue_vue_type_script_setup_true_lang.js +29 -0
  81. package/dist/bundled/components/panel/ControlsComponentStateItem.js +5 -0
  82. package/dist/bundled/components/panel/ControlsComponentStateItem.vue_vue_type_script_setup_true_lang.js +40 -0
  83. package/dist/bundled/components/panel/PaneTabs.js +5 -0
  84. package/dist/bundled/components/panel/PaneTabs.vue_vue_type_script_setup_true_lang.js +137 -0
  85. package/dist/bundled/components/panel/StatePresets.js +5 -0
  86. package/dist/bundled/components/panel/StatePresets.vue_vue_type_script_setup_true_lang.js +147 -0
  87. package/dist/bundled/components/panel/StoryControls.js +5 -0
  88. package/dist/bundled/components/panel/StoryControls.vue_vue_type_script_setup_true_lang.js +73 -0
  89. package/dist/bundled/components/panel/StoryDocs.js +5 -0
  90. package/dist/bundled/components/panel/StoryDocs.vue_vue_type_script_setup_true_lang.js +130 -0
  91. package/dist/bundled/components/panel/StoryEvent.js +5 -0
  92. package/dist/bundled/components/panel/StoryEvent.vue_vue_type_script_setup_true_lang.js +36 -0
  93. package/dist/bundled/components/panel/StoryEvents.js +5 -0
  94. package/dist/bundled/components/panel/StoryEvents.vue_vue_type_script_setup_true_lang.js +42 -0
  95. package/dist/bundled/components/panel/StorySidePanel.js +5 -0
  96. package/dist/bundled/components/panel/StorySidePanel.vue_vue_type_script_setup_true_lang.js +69 -0
  97. package/dist/bundled/components/panel/StorySourceCode.js +7 -0
  98. package/dist/bundled/components/panel/StorySourceCode.vue_vue_type_script_setup_true_lang.js +146 -0
  99. package/dist/bundled/components/search/SearchItem.js +7 -0
  100. package/dist/bundled/components/search/SearchItem.vue_vue_type_script_setup_true_lang.js +67 -0
  101. package/dist/bundled/components/search/SearchItemContent.js +5 -0
  102. package/dist/bundled/components/search/SearchItemContent.vue_vue_type_script_setup_true_lang.js +49 -0
  103. package/dist/bundled/components/search/SearchLoading.js +5 -0
  104. package/dist/bundled/components/search/SearchLoading.vue_vue_type_script_setup_true_lang.js +17 -0
  105. package/dist/bundled/components/search/SearchModal.js +5 -0
  106. package/dist/bundled/components/search/SearchModal.vue_vue_type_script_setup_true_lang.js +38 -0
  107. package/dist/bundled/components/search/SearchPane.js +5 -0
  108. package/dist/bundled/components/search/SearchPane.vue_vue_type_script_setup_true_lang.js +229 -0
  109. package/dist/bundled/components/search/search-docs-data.js +6 -8
  110. package/dist/bundled/components/search/search-title-data.js +7 -9
  111. package/dist/bundled/components/story/GenericMountStory.js +5 -0
  112. package/dist/bundled/components/story/GenericMountStory.vue_vue_type_script_setup_true_lang.js +27 -0
  113. package/dist/bundled/components/story/GenericRenderStory.js +5 -0
  114. package/dist/bundled/components/story/GenericRenderStory.vue_vue_type_script_setup_true_lang.js +30 -0
  115. package/dist/bundled/components/story/StoryResponsivePreview.js +7 -0
  116. package/dist/bundled/components/story/StoryResponsivePreview.vue_vue_type_script_setup_true_lang.js +170 -0
  117. package/dist/bundled/components/story/StoryVariantGrid.js +5 -0
  118. package/dist/bundled/components/story/StoryVariantGrid.vue_vue_type_script_setup_true_lang.js +99 -0
  119. package/dist/bundled/components/story/StoryVariantGridItem.js +7 -0
  120. package/dist/bundled/components/story/StoryVariantGridItem.vue_vue_type_script_setup_true_lang.js +142 -0
  121. package/dist/bundled/components/story/StoryVariantListItem.js +7 -0
  122. package/dist/bundled/components/story/StoryVariantListItem.vue_vue_type_script_setup_true_lang.js +44 -0
  123. package/dist/bundled/components/story/StoryVariantSingle.js +7 -0
  124. package/dist/bundled/components/story/StoryVariantSingle.vue_vue_type_script_setup_true_lang.js +76 -0
  125. package/dist/bundled/components/story/StoryVariantSinglePreviewNative.js +5 -0
  126. package/dist/bundled/components/story/StoryVariantSinglePreviewNative.vue_vue_type_script_setup_true_lang.js +68 -0
  127. package/dist/bundled/components/story/StoryVariantSinglePreviewRemote.js +5 -0
  128. package/dist/bundled/components/story/StoryVariantSinglePreviewRemote.vue_vue_type_script_setup_true_lang.js +134 -0
  129. package/dist/bundled/components/story/StoryVariantSingleView.js +5 -0
  130. package/dist/bundled/components/story/StoryVariantSingleView.vue_vue_type_script_setup_true_lang.js +30 -0
  131. package/dist/bundled/components/story/StoryView.js +5 -0
  132. package/dist/bundled/components/story/StoryView.vue_vue_type_script_setup_true_lang.js +95 -0
  133. package/dist/bundled/components/story/StoryViewer.js +7 -0
  134. package/dist/bundled/components/story/StoryViewer.vue_vue_type_script_setup_true_lang.js +43 -0
  135. package/dist/bundled/components/toolbar/DevOnlyToolbarOpenInEditor.js +5 -0
  136. package/dist/bundled/components/toolbar/DevOnlyToolbarOpenInEditor.vue_vue_type_script_setup_true_lang.js +30 -0
  137. package/dist/bundled/components/toolbar/ToolbarBackground.js +7 -0
  138. package/dist/bundled/components/toolbar/ToolbarBackground.vue_vue_type_script_setup_true_lang.js +109 -0
  139. package/dist/bundled/components/toolbar/ToolbarNewTab.js +5 -0
  140. package/dist/bundled/components/toolbar/ToolbarNewTab.vue_vue_type_script_setup_true_lang.js +34 -0
  141. package/dist/bundled/components/toolbar/ToolbarResponsiveSize.js +5 -0
  142. package/dist/bundled/components/toolbar/ToolbarResponsiveSize.vue_vue_type_script_setup_true_lang.js +93 -0
  143. package/dist/bundled/components/toolbar/ToolbarTextDirection.js +5 -0
  144. package/dist/bundled/components/toolbar/ToolbarTextDirection.vue_vue_type_script_setup_true_lang.js +26 -0
  145. package/dist/bundled/components/toolbar/ToolbarTitle.js +7 -0
  146. package/dist/bundled/components/toolbar/ToolbarTitle.vue_vue_type_script_setup_true_lang.js +35 -0
  147. package/dist/bundled/components/tree/StoryGroup.js +5 -0
  148. package/dist/bundled/components/tree/StoryGroup.vue_vue_type_script_setup_true_lang.js +59 -0
  149. package/dist/bundled/components/tree/StoryList.js +5 -0
  150. package/dist/bundled/components/tree/StoryList.vue_vue_type_script_setup_true_lang.js +33 -0
  151. package/dist/bundled/components/tree/StoryListFolder.js +7 -0
  152. package/dist/bundled/components/tree/StoryListFolder.vue_vue_type_script_setup_true_lang.js +67 -0
  153. package/dist/bundled/components/tree/StoryListItem.js +7 -0
  154. package/dist/bundled/components/tree/StoryListItem.vue_vue_type_script_setup_true_lang.js +58 -0
  155. package/dist/bundled/index.js +24 -33
  156. package/dist/bundled/plugin.js +43 -46
  157. package/dist/bundled/router.js +20 -28
  158. package/dist/bundled/sandbox.js +85 -99
  159. package/dist/bundled/stores/command.js +21 -23
  160. package/dist/bundled/stores/events.js +26 -27
  161. package/dist/bundled/stores/folder.js +37 -51
  162. package/dist/bundled/stores/layout.js +9 -13
  163. package/dist/bundled/stores/preview-settings.js +28 -31
  164. package/dist/bundled/stores/story.js +54 -41
  165. package/dist/bundled/util/color-scheme.js +29 -21
  166. package/dist/bundled/util/commands.js +39 -50
  167. package/dist/bundled/util/config.js +5 -7
  168. package/dist/bundled/util/const.js +8 -12
  169. package/dist/bundled/util/dark.js +16 -20
  170. package/dist/bundled/util/docs.js +14 -23
  171. package/dist/bundled/util/env.js +4 -4
  172. package/dist/bundled/util/events.js +22 -28
  173. package/dist/bundled/util/highlighter.js +23 -0
  174. package/dist/bundled/util/keyboard.js +89 -103
  175. package/dist/bundled/util/mapping.js +49 -64
  176. package/dist/bundled/util/open-in-editor.js +4 -4
  177. package/dist/bundled/util/preview-settings.js +23 -26
  178. package/dist/bundled/util/responsive.js +4 -5
  179. package/dist/bundled/util/sandbox.js +7 -8
  180. package/dist/bundled/util/scroll.js +20 -28
  181. package/dist/bundled/util/select.js +21 -26
  182. package/dist/bundled/util/state.js +25 -36
  183. package/dist/bundled/util/tooltip.js +8 -9
  184. package/dist/bundled/util/variant.js +14 -17
  185. package/dist/style.css +2828 -2953
  186. package/package.json +12 -9
  187. package/src/__tests__/postcss-scope-wrapper.spec.ts +65 -0
  188. package/src/app/App.vue +16 -16
  189. package/src/app/components/HomeView.vue +8 -3
  190. package/src/app/components/app/AppActions.vue +3 -3
  191. package/src/app/components/app/AppHeader.vue +4 -4
  192. package/src/app/components/app/Breadcrumb.vue +8 -8
  193. package/src/app/components/app/HomeCounter.vue +59 -13
  194. package/src/app/components/app/InitialLoading.vue +5 -5
  195. package/src/app/components/app/MobileOverlay.vue +5 -5
  196. package/src/app/components/app/TopBar.vue +4 -4
  197. package/src/app/components/app/TopBarChip.vue +1 -1
  198. package/src/app/components/app/TopBarChipItem.vue +1 -1
  199. package/src/app/components/base/BaseButton.vue +3 -3
  200. package/src/app/components/base/BaseCheckbox.vue +9 -9
  201. package/src/app/components/base/BaseCopyIcon.vue +1 -1
  202. package/src/app/components/base/BaseEmpty.vue +4 -4
  203. package/src/app/components/base/BaseKeyboardShortcut.vue +1 -1
  204. package/src/app/components/base/BaseListItem.vue +3 -3
  205. package/src/app/components/base/BaseListItemLink.vue +3 -3
  206. package/src/app/components/base/BaseOverflowMenu.vue +4 -4
  207. package/src/app/components/base/BaseOverflowTab.vue +3 -3
  208. package/src/app/components/base/BaseSelect.vue +6 -6
  209. package/src/app/components/base/BaseSplitPane.vue +18 -18
  210. package/src/app/components/base/BaseTab.vue +3 -3
  211. package/src/app/components/base/BaseTag.vue +1 -1
  212. package/src/app/components/command/CommandPrompts.vue +5 -5
  213. package/src/app/components/command/CommandPromptsModal.vue +5 -5
  214. package/src/app/components/command/PromptSelect.vue +14 -14
  215. package/src/app/components/command/PromptText.vue +4 -4
  216. package/src/app/components/layout/LayoutItem.vue +4 -4
  217. package/src/app/components/layout/LayoutItemGroup.vue +1 -1
  218. package/src/app/components/layout/LayoutModal.vue +7 -7
  219. package/src/app/components/layout/LayoutPane.vue +1 -1
  220. package/src/app/components/panel/ControlsComponentPropItem.vue +2 -2
  221. package/src/app/components/panel/ControlsComponentProps.vue +3 -3
  222. package/src/app/components/panel/ControlsComponentState.vue +2 -2
  223. package/src/app/components/panel/PaneTabs.vue +4 -4
  224. package/src/app/components/panel/StatePresets.vue +16 -16
  225. package/src/app/components/panel/StoryControls.vue +7 -8
  226. package/src/app/components/panel/StoryDocs.vue +5 -5
  227. package/src/app/components/panel/StoryEvent.vue +7 -7
  228. package/src/app/components/panel/StoryEvents.vue +1 -1
  229. package/src/app/components/panel/StorySidePanel.vue +6 -6
  230. package/src/app/components/panel/StorySourceCode.vue +31 -33
  231. package/src/app/components/search/SearchItem.vue +5 -17
  232. package/src/app/components/search/SearchItemContent.vue +9 -9
  233. package/src/app/components/search/SearchLoading.vue +2 -2
  234. package/src/app/components/search/SearchModal.vue +9 -9
  235. package/src/app/components/search/SearchPane.vue +41 -17
  236. package/src/app/components/story/StoryResponsivePreview.vue +27 -27
  237. package/src/app/components/story/StoryVariantGrid.vue +5 -5
  238. package/src/app/components/story/StoryVariantGridItem.vue +21 -21
  239. package/src/app/components/story/StoryVariantListItem.vue +4 -4
  240. package/src/app/components/story/StoryVariantSingle.vue +9 -9
  241. package/src/app/components/story/StoryVariantSinglePreviewNative.vue +7 -8
  242. package/src/app/components/story/StoryVariantSinglePreviewRemote.vue +15 -14
  243. package/src/app/components/story/StoryVariantSingleView.vue +1 -1
  244. package/src/app/components/story/StoryView.vue +5 -5
  245. package/src/app/components/story/StoryViewer.vue +1 -1
  246. package/src/app/components/toolbar/DevOnlyToolbarOpenInEditor.vue +1 -1
  247. package/src/app/components/toolbar/ToolbarBackground.vue +16 -16
  248. package/src/app/components/toolbar/ToolbarNewTab.vue +1 -1
  249. package/src/app/components/toolbar/ToolbarResponsiveSize.vue +14 -14
  250. package/src/app/components/toolbar/ToolbarTextDirection.vue +1 -1
  251. package/src/app/components/toolbar/ToolbarTitle.vue +6 -6
  252. package/src/app/components/tree/StoryGroup.vue +5 -5
  253. package/src/app/components/tree/StoryList.vue +1 -1
  254. package/src/app/components/tree/StoryListFolder.vue +6 -6
  255. package/src/app/components/tree/StoryListItem.vue +6 -6
  256. package/src/app/sandbox.ts +36 -10
  257. package/src/app/stores/story.ts +17 -0
  258. package/src/app/style/floating.pcss +16 -10
  259. package/src/app/style/main.pcss +190 -30
  260. package/src/app/style/sandbox.css +3 -1
  261. package/src/app/style/transitions.pcss +49 -50
  262. package/src/app/util/env.ts +5 -0
  263. package/src/app/util/events.ts +0 -1
  264. package/src/app/util/highlighter.ts +32 -0
  265. package/src/app/util/scroll.ts +2 -1
  266. package/src/app/util/tooltip.ts +2 -2
  267. package/dist/bundled/App.vue.js +0 -5
  268. package/dist/bundled/App.vue2.js +0 -211
  269. package/dist/bundled/assets/poveste-text-dark.svg.js +0 -4
  270. package/dist/bundled/assets/poveste-text.svg.js +0 -4
  271. package/dist/bundled/assets/poveste.svg.js +0 -4
  272. package/dist/bundled/components/HomeView.vue.js +0 -5
  273. package/dist/bundled/components/HomeView.vue2.js +0 -66
  274. package/dist/bundled/components/app/AppActions.vue.js +0 -5
  275. package/dist/bundled/components/app/AppActions.vue2.js +0 -76
  276. package/dist/bundled/components/app/AppHeader.vue.js +0 -5
  277. package/dist/bundled/components/app/AppHeader.vue2.js +0 -29
  278. package/dist/bundled/components/app/AppLogo.vue.js +0 -5
  279. package/dist/bundled/components/app/AppLogo.vue2.js +0 -29
  280. package/dist/bundled/components/app/Breadcrumb.vue.js +0 -8
  281. package/dist/bundled/components/app/Breadcrumb.vue2.js +0 -91
  282. package/dist/bundled/components/app/HomeCounter.vue.js +0 -5
  283. package/dist/bundled/components/app/HomeCounter.vue2.js +0 -42
  284. package/dist/bundled/components/app/InitialLoading.vue.js +0 -5
  285. package/dist/bundled/components/app/InitialLoading.vue2.js +0 -51
  286. package/dist/bundled/components/app/MobileOverlay.vue.js +0 -5
  287. package/dist/bundled/components/app/MobileOverlay.vue2.js +0 -45
  288. package/dist/bundled/components/app/TopBar.vue.js +0 -5
  289. package/dist/bundled/components/app/TopBar.vue2.js +0 -73
  290. package/dist/bundled/components/app/TopBarChip.vue.js +0 -13
  291. package/dist/bundled/components/app/TopBarChipItem.vue.js +0 -13
  292. package/dist/bundled/components/base/BaseButton.vue.js +0 -5
  293. package/dist/bundled/components/base/BaseButton.vue2.js +0 -39
  294. package/dist/bundled/components/base/BaseCheckbox.vue.js +0 -5
  295. package/dist/bundled/components/base/BaseCheckbox.vue2.js +0 -78
  296. package/dist/bundled/components/base/BaseEmpty.vue.js +0 -14
  297. package/dist/bundled/components/base/BaseIcon.vue.js +0 -8
  298. package/dist/bundled/components/base/BaseIcon.vue2.js +0 -29
  299. package/dist/bundled/components/base/BaseKeyboardShortcut.vue.js +0 -5
  300. package/dist/bundled/components/base/BaseKeyboardShortcut.vue2.js +0 -20
  301. package/dist/bundled/components/base/BaseListItem.vue.js +0 -5
  302. package/dist/bundled/components/base/BaseListItem.vue2.js +0 -33
  303. package/dist/bundled/components/base/BaseListItemLink.vue.js +0 -33
  304. package/dist/bundled/components/base/BaseListItemLink.vue2.js +0 -26
  305. package/dist/bundled/components/base/BaseOverflowMenu.vue.js +0 -5
  306. package/dist/bundled/components/base/BaseOverflowMenu.vue2.js +0 -100
  307. package/dist/bundled/components/base/BaseOverflowTab.vue.js +0 -36
  308. package/dist/bundled/components/base/BaseOverflowTab.vue2.js +0 -18
  309. package/dist/bundled/components/base/BaseSelect.vue.js +0 -5
  310. package/dist/bundled/components/base/BaseSelect.vue2.js +0 -77
  311. package/dist/bundled/components/base/BaseSplitPane.vue.js +0 -8
  312. package/dist/bundled/components/base/BaseSplitPane.vue2.js +0 -187
  313. package/dist/bundled/components/base/BaseTab.vue.js +0 -36
  314. package/dist/bundled/components/base/BaseTab.vue2.js +0 -18
  315. package/dist/bundled/components/base/BaseTag.vue.js +0 -13
  316. package/dist/bundled/components/command/CommandPrompts.vue.js +0 -5
  317. package/dist/bundled/components/command/CommandPrompts.vue2.js +0 -91
  318. package/dist/bundled/components/command/CommandPromptsModal.vue.js +0 -5
  319. package/dist/bundled/components/command/CommandPromptsModal.vue2.js +0 -45
  320. package/dist/bundled/components/command/PromptSelect.vue.js +0 -5
  321. package/dist/bundled/components/command/PromptSelect.vue2.js +0 -142
  322. package/dist/bundled/components/command/PromptText.vue.js +0 -5
  323. package/dist/bundled/components/command/PromptText.vue2.js +0 -67
  324. package/dist/bundled/components/layout/LayoutItem.vue.js +0 -5
  325. package/dist/bundled/components/layout/LayoutItem.vue2.js +0 -44
  326. package/dist/bundled/components/layout/LayoutItemGroup.vue.js +0 -5
  327. package/dist/bundled/components/layout/LayoutItemGroup.vue2.js +0 -25
  328. package/dist/bundled/components/layout/LayoutModal.vue.js +0 -5
  329. package/dist/bundled/components/layout/LayoutModal.vue2.js +0 -68
  330. package/dist/bundled/components/layout/LayoutPane.vue.js +0 -5
  331. package/dist/bundled/components/layout/LayoutPane.vue2.js +0 -59
  332. package/dist/bundled/components/misc/CheckerboardPattern.vue.js +0 -40
  333. package/dist/bundled/components/misc/HatchedPattern.vue.js +0 -12
  334. package/dist/bundled/components/panel/ControlsComponentPropItem.vue.js +0 -5
  335. package/dist/bundled/components/panel/ControlsComponentPropItem.vue2.js +0 -72
  336. package/dist/bundled/components/panel/ControlsComponentProps.vue.js +0 -5
  337. package/dist/bundled/components/panel/ControlsComponentProps.vue2.js +0 -45
  338. package/dist/bundled/components/panel/ControlsComponentState.vue.js +0 -5
  339. package/dist/bundled/components/panel/ControlsComponentState.vue2.js +0 -41
  340. package/dist/bundled/components/panel/ControlsComponentStateItem.vue.js +0 -5
  341. package/dist/bundled/components/panel/ControlsComponentStateItem.vue2.js +0 -46
  342. package/dist/bundled/components/panel/PaneTabs.vue.js +0 -5
  343. package/dist/bundled/components/panel/PaneTabs.vue2.js +0 -114
  344. package/dist/bundled/components/panel/StatePresets.vue.js +0 -5
  345. package/dist/bundled/components/panel/StatePresets.vue2.js +0 -193
  346. package/dist/bundled/components/panel/StoryControls.vue.js +0 -5
  347. package/dist/bundled/components/panel/StoryControls.vue2.js +0 -87
  348. package/dist/bundled/components/panel/StoryDocs.vue.js +0 -7
  349. package/dist/bundled/components/panel/StoryDocs.vue2.js +0 -161
  350. package/dist/bundled/components/panel/StoryEvent.vue.js +0 -5
  351. package/dist/bundled/components/panel/StoryEvent.vue2.js +0 -59
  352. package/dist/bundled/components/panel/StoryEvents.vue.js +0 -5
  353. package/dist/bundled/components/panel/StoryEvents.vue2.js +0 -53
  354. package/dist/bundled/components/panel/StorySidePanel.vue.js +0 -5
  355. package/dist/bundled/components/panel/StorySidePanel.vue2.js +0 -94
  356. package/dist/bundled/components/panel/StorySourceCode.vue.js +0 -8
  357. package/dist/bundled/components/panel/StorySourceCode.vue2.js +0 -204
  358. package/dist/bundled/components/search/SearchItem.vue.js +0 -8
  359. package/dist/bundled/components/search/SearchItem.vue2.js +0 -93
  360. package/dist/bundled/components/search/SearchItemContent.vue.js +0 -5
  361. package/dist/bundled/components/search/SearchItemContent.vue2.js +0 -71
  362. package/dist/bundled/components/search/SearchLoading.vue.js +0 -5
  363. package/dist/bundled/components/search/SearchLoading.vue2.js +0 -21
  364. package/dist/bundled/components/search/SearchModal.vue.js +0 -5
  365. package/dist/bundled/components/search/SearchModal.vue2.js +0 -51
  366. package/dist/bundled/components/search/SearchPane.vue.js +0 -5
  367. package/dist/bundled/components/search/SearchPane.vue2.js +0 -272
  368. package/dist/bundled/components/story/GenericMountStory.vue.js +0 -5
  369. package/dist/bundled/components/story/GenericMountStory.vue2.js +0 -34
  370. package/dist/bundled/components/story/GenericRenderStory.vue.js +0 -5
  371. package/dist/bundled/components/story/GenericRenderStory.vue2.js +0 -39
  372. package/dist/bundled/components/story/StoryResponsivePreview.vue.js +0 -8
  373. package/dist/bundled/components/story/StoryResponsivePreview.vue2.js +0 -207
  374. package/dist/bundled/components/story/StoryVariantGrid.vue.js +0 -5
  375. package/dist/bundled/components/story/StoryVariantGrid.vue2.js +0 -127
  376. package/dist/bundled/components/story/StoryVariantGridItem.vue.js +0 -8
  377. package/dist/bundled/components/story/StoryVariantGridItem.vue2.js +0 -170
  378. package/dist/bundled/components/story/StoryVariantListItem.vue.js +0 -8
  379. package/dist/bundled/components/story/StoryVariantListItem.vue2.js +0 -55
  380. package/dist/bundled/components/story/StoryVariantSingle.vue.js +0 -8
  381. package/dist/bundled/components/story/StoryVariantSingle.vue2.js +0 -107
  382. package/dist/bundled/components/story/StoryVariantSinglePreviewNative.vue.js +0 -5
  383. package/dist/bundled/components/story/StoryVariantSinglePreviewNative.vue2.js +0 -73
  384. package/dist/bundled/components/story/StoryVariantSinglePreviewRemote.vue.js +0 -5
  385. package/dist/bundled/components/story/StoryVariantSinglePreviewRemote.vue2.js +0 -153
  386. package/dist/bundled/components/story/StoryVariantSingleView.vue.js +0 -5
  387. package/dist/bundled/components/story/StoryVariantSingleView.vue2.js +0 -35
  388. package/dist/bundled/components/story/StoryView.vue.js +0 -5
  389. package/dist/bundled/components/story/StoryView.vue2.js +0 -114
  390. package/dist/bundled/components/story/StoryViewer.vue.js +0 -8
  391. package/dist/bundled/components/story/StoryViewer.vue2.js +0 -55
  392. package/dist/bundled/components/toolbar/DevOnlyToolbarOpenInEditor.vue.js +0 -5
  393. package/dist/bundled/components/toolbar/DevOnlyToolbarOpenInEditor.vue2.js +0 -35
  394. package/dist/bundled/components/toolbar/ToolbarBackground.vue.js +0 -8
  395. package/dist/bundled/components/toolbar/ToolbarBackground.vue2.js +0 -127
  396. package/dist/bundled/components/toolbar/ToolbarNewTab.vue.js +0 -5
  397. package/dist/bundled/components/toolbar/ToolbarNewTab.vue2.js +0 -39
  398. package/dist/bundled/components/toolbar/ToolbarResponsiveSize.vue.js +0 -5
  399. package/dist/bundled/components/toolbar/ToolbarResponsiveSize.vue2.js +0 -127
  400. package/dist/bundled/components/toolbar/ToolbarTextDirection.vue.js +0 -5
  401. package/dist/bundled/components/toolbar/ToolbarTextDirection.vue2.js +0 -31
  402. package/dist/bundled/components/toolbar/ToolbarTitle.vue.js +0 -8
  403. package/dist/bundled/components/toolbar/ToolbarTitle.vue2.js +0 -49
  404. package/dist/bundled/components/tree/StoryGroup.vue.js +0 -5
  405. package/dist/bundled/components/tree/StoryGroup.vue2.js +0 -74
  406. package/dist/bundled/components/tree/StoryList.vue.js +0 -5
  407. package/dist/bundled/components/tree/StoryList.vue2.js +0 -41
  408. package/dist/bundled/components/tree/StoryListFolder.vue.js +0 -8
  409. package/dist/bundled/components/tree/StoryListFolder.vue2.js +0 -86
  410. package/dist/bundled/components/tree/StoryListItem.vue.js +0 -8
  411. package/dist/bundled/components/tree/StoryListItem.vue2.js +0 -69
@@ -2,40 +2,115 @@
2
2
  @import 'floating-vue/dist/style.css';
3
3
  @import '@poveste/controls/dist/index.es.css';
4
4
 
5
- @import 'floating.pcss';
6
- @import 'transitions.pcss';
7
-
8
- *,
9
- ::before,
10
- ::after {
11
- box-sizing: border-box;
12
- border-width: 0;
13
- border-style: solid;
14
- border-color: #e5e7eb;
15
- }
5
+ @import './floating.pcss';
6
+ @import './transitions.pcss';
16
7
 
17
- a,
18
- input,
19
- button {
20
- color: inherit;
21
- }
8
+ /*
9
+ * Tailwind v4. Preflight is intentionally omitted (was `corePlugins.preflight:
10
+ * false` in v3) — the manual reset below replaces it. The `ptw-` utility prefix
11
+ * is gone; chrome/story isolation is handled by @scope (postcss-scope-wrapper, #27).
12
+ */
13
+ @layer theme, base, components, utilities;
14
+ @import 'tailwindcss/theme.css' layer(theme);
15
+ @import 'tailwindcss/utilities.css' layer(utilities);
22
16
 
23
- a {
24
- text-decoration: inherit;
25
- }
17
+ /* v4 auto-detection only scans this package; the app renders controls, so their
18
+ utility classes must be generated here too (was a content glob in v3). */
19
+ @source "../../../../poveste-controls/src";
26
20
 
27
- input, button {
28
- font-family: inherit;
29
- }
21
+ /* The markdown renderer builds the docs code-block chrome as an HTML string, so
22
+ its utility classes live in a package v4 never scans. */
23
+ @source "../../../../poveste/src/node/markdown.ts";
24
+
25
+ /* TODO(#36): port the v3 typography theme() customization to v4 CSS. */
26
+ @plugin '@tailwindcss/typography';
27
+
28
+ /* Chrome dark mode. Deliberately a distinct class from the story-side
29
+ `theme.darkClass` default (`dark`) so chrome and story themes stay independent —
30
+ in v3 the `ptw-` prefix applied to the dark class and kept them separate. */
31
+ @custom-variant dark (&:where(.ptw-dark, .ptw-dark *));
30
32
 
31
- a,
32
- button {
33
- user-select: none;
33
+ @theme {
34
+ /*
35
+ * primary + gray are themable at runtime: resolved-theme.ts injects
36
+ * --_poveste-color-<name>-<key> as space-separated RGB channels, and v4's
37
+ * native color-mix handles opacity (replacing the v3 withOpacityValue shim).
38
+ */
39
+ --color-primary-50: rgb(var(--_poveste-color-primary-50));
40
+ --color-primary-100: rgb(var(--_poveste-color-primary-100));
41
+ --color-primary-200: rgb(var(--_poveste-color-primary-200));
42
+ --color-primary-300: rgb(var(--_poveste-color-primary-300));
43
+ --color-primary-400: rgb(var(--_poveste-color-primary-400));
44
+ --color-primary-500: rgb(var(--_poveste-color-primary-500));
45
+ --color-primary-600: rgb(var(--_poveste-color-primary-600));
46
+ --color-primary-700: rgb(var(--_poveste-color-primary-700));
47
+ --color-primary-800: rgb(var(--_poveste-color-primary-800));
48
+ --color-primary-900: rgb(var(--_poveste-color-primary-900));
49
+
50
+ --color-gray-50: rgb(var(--_poveste-color-gray-50));
51
+ --color-gray-100: rgb(var(--_poveste-color-gray-100));
52
+ --color-gray-200: rgb(var(--_poveste-color-gray-200));
53
+ --color-gray-300: rgb(var(--_poveste-color-gray-300));
54
+ --color-gray-400: rgb(var(--_poveste-color-gray-400));
55
+ --color-gray-500: rgb(var(--_poveste-color-gray-500));
56
+ --color-gray-600: rgb(var(--_poveste-color-gray-600));
57
+ --color-gray-700: rgb(var(--_poveste-color-gray-700));
58
+ --color-gray-750: rgb(var(--_poveste-color-gray-750));
59
+ --color-gray-800: rgb(var(--_poveste-color-gray-800));
60
+ --color-gray-850: rgb(var(--_poveste-color-gray-850));
61
+ --color-gray-900: rgb(var(--_poveste-color-gray-900));
62
+ --color-gray-950: rgb(var(--_poveste-color-gray-950));
63
+
64
+ /* border radius (ported from the root v3 config) */
65
+ --radius-sm: 0.25rem;
66
+ --radius: 0.375rem;
67
+ --radius-md: 0.5rem;
68
+ --radius-lg: 0.75rem;
69
+ --radius-xl: 1rem;
70
+ --radius-2xl: 1.5rem;
71
+ --radius-3xl: 2rem;
34
72
  }
35
73
 
36
- @tailwind base;
37
- @tailwind components;
38
- @tailwind utilities;
74
+ /*
75
+ * Manual reset — replaces Preflight, which is intentionally disabled.
76
+ *
77
+ * MUST stay inside `@layer base`. Unlayered rules beat *every* layered rule
78
+ * regardless of specificity, so an unlayered `* { border-width: 0 }` silently
79
+ * defeats `.border` in `@layer utilities` — every border in the app renders at
80
+ * zero width. In v3 this block was safe unlayered because `@tailwind utilities`
81
+ * emitted unlayered rules that won on specificity; v4 puts them in a real
82
+ * cascade layer, which inverts the outcome. Same trap for the `a`/`input`/
83
+ * `button` rules below vs. text-colour and font utilities.
84
+ */
85
+ @layer base {
86
+ *,
87
+ ::before,
88
+ ::after {
89
+ box-sizing: border-box;
90
+ border-width: 0;
91
+ border-style: solid;
92
+ border-color: #e5e7eb;
93
+ }
94
+
95
+ a,
96
+ input,
97
+ button {
98
+ color: inherit;
99
+ }
100
+
101
+ a {
102
+ text-decoration: inherit;
103
+ }
104
+
105
+ input, button {
106
+ font-family: inherit;
107
+ }
108
+
109
+ a,
110
+ button {
111
+ user-select: none;
112
+ }
113
+ }
39
114
 
40
115
  @layer base {
41
116
  body,
@@ -73,7 +148,7 @@ button {
73
148
  background: transparent !important;
74
149
  }
75
150
 
76
- .ptw-prose {
151
+ .prose {
77
152
  h1, h2, h3, h4 {
78
153
  &:not(:hover) {
79
154
  .header-anchor[aria-hidden="true"] {
@@ -93,8 +168,93 @@ button {
93
168
  background-repeat: no-repeat;
94
169
  background-position: right;
95
170
 
96
- .ptw-dark & {
171
+ /* Subject-side, not `.ptw-dark &` — see the note in floating.pcss. */
172
+ &:where(.ptw-dark, .ptw-dark *) {
97
173
  background-image: linear-gradient(to left, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0));
98
174
  }
99
175
  }
100
176
  }
177
+
178
+ /*
179
+ * Typography (@tailwindcss/typography) customization — ported from the v3
180
+ * `theme.extend.typography` JS config to CSS. Unlayered so it overrides the
181
+ * plugin's layered defaults. Needs a visual pass on the docs/markdown pages.
182
+ */
183
+ .prose {
184
+ --tw-prose-invert-quote-borders: var(--color-gray-800);
185
+ --tw-prose-invert-hr: var(--color-gray-800);
186
+ --tw-prose-invert-bullets: var(--color-gray-500);
187
+
188
+ /*
189
+ * The guard repeats what the plugin puts on every rule it generates, so
190
+ * `not-prose` opts out of ours too. In v3 these lived in
191
+ * `theme.extend.typography` and the plugin added it for us; hand-written CSS
192
+ * gets nothing.
193
+ *
194
+ * `:where()` keeps the guard at zero specificity, so every selector below
195
+ * weighs exactly what its unguarded form did.
196
+ */
197
+ & :not(:where([class~='not-prose'], [class~='not-prose'] *)) {
198
+ &:is(a) {
199
+ color: var(--color-primary-500);
200
+ text-decoration: none;
201
+
202
+ &:hover {
203
+ text-decoration: underline;
204
+ }
205
+ }
206
+
207
+ &:is(h1, h2, h3, h4, th) {
208
+ margin-bottom: 0.75rem;
209
+
210
+ &:not(:first-child) {
211
+ margin-top: 1.25rem;
212
+ }
213
+ }
214
+
215
+ &:is(blockquote) {
216
+ margin-left: 0;
217
+ margin-right: 0;
218
+ background-color: var(--color-gray-100);
219
+ padding: 0.25rem 0.375rem;
220
+
221
+ &:where(.ptw-dark, .ptw-dark *) {
222
+ background-color: var(--color-gray-750);
223
+ }
224
+
225
+ & p:first-child {
226
+ margin-top: 0;
227
+ }
228
+
229
+ & p:last-child {
230
+ margin-bottom: 0;
231
+ }
232
+ }
233
+
234
+ &:is(li) {
235
+ margin-top: 0.1rem;
236
+ margin-bottom: 0.1rem;
237
+ }
238
+
239
+ /*
240
+ * Inline code only. markdown-it wraps the highlighted output in
241
+ * `<pre><code class="language-x">`, and that `code` is the parent of the
242
+ * `not-prose` island rather than part of it, so the guard above misses it —
243
+ * as does the island itself for shiki's own `code`, which sits in a `pre`
244
+ * too. The plugin's `pre code` reset would have handled both, but it lives
245
+ * in a cascade layer and this rule is unlayered: unlayered wins outright,
246
+ * the same inversion as #104.
247
+ */
248
+ &:is(code):not(:where(pre *)) {
249
+ background-color: color-mix(in oklab, var(--color-gray-500) 20%, transparent);
250
+ font-weight: normal;
251
+ padding: 0.05rem 0.5rem;
252
+ border-radius: 0.25rem;
253
+ font-size: 0.8rem;
254
+
255
+ &::before, &::after {
256
+ display: none;
257
+ }
258
+ }
259
+ }
260
+ }
@@ -14,7 +14,9 @@ html {
14
14
  font-family: 'Noto Sans Display', system-ui, sans-serif;
15
15
  }
16
16
 
17
- .ptw-sandbox-hidden {
17
+ /* Namespaced: sandbox.css is not @scope-wrapped, so this rule shares the
18
+ document with user story markup. */
19
+ .__poveste-sandbox-hidden {
18
20
  display: none;
19
21
  }
20
22
 
@@ -1,51 +1,50 @@
1
- .__poveste-scale-x {
2
- &-enter-active,
3
- &-leave-active {
4
- transition: transform .15s, opacity .15s;
5
- }
6
-
7
- &-enter-from,
8
- &-leave-to {
9
- transform: scaleX(0);
10
- opacity: 0;
11
- }
12
- }
13
-
14
- .__poveste-scale-y {
15
- &-enter-active,
16
- &-leave-active {
17
- transition: transform .15s, opacity .15s;
18
- }
19
-
20
- &-enter-from,
21
- &-leave-to {
22
- transform: scaleY(0);
23
- opacity: 0;
24
- }
25
- }
26
-
27
- .__poveste-fade {
28
- &-enter-active,
29
- &-leave-active {
30
- transition: opacity .15s;
31
- }
32
-
33
- &-enter-from,
34
- &-leave-to {
35
- opacity: 0;
36
- }
37
- }
38
-
39
- .__poveste-fade-bottom {
40
- &-enter-active,
41
- &-leave-active {
42
- transition: transform .15s, opacity .15s;
43
- transform: translateY(0px);
44
- }
45
-
46
- &-enter-from,
47
- &-leave-to {
48
- transform: translateY(32px);
49
- opacity: 0;
50
- }
1
+ /*
2
+ * Vue transition classes. Written out in full rather than with SCSS-style
3
+ * `&-enter-active` concatenation: Tailwind v4 uses native CSS nesting, where
4
+ * `&` is a real selector reference (`:is(…)`) and cannot be string-joined
5
+ * with a suffix. v3 resolved that through postcss-nested.
6
+ */
7
+
8
+ .__poveste-scale-x-enter-active,
9
+ .__poveste-scale-x-leave-active {
10
+ transition: transform .15s, opacity .15s;
11
+ }
12
+
13
+ .__poveste-scale-x-enter-from,
14
+ .__poveste-scale-x-leave-to {
15
+ transform: scaleX(0);
16
+ opacity: 0;
17
+ }
18
+
19
+ .__poveste-scale-y-enter-active,
20
+ .__poveste-scale-y-leave-active {
21
+ transition: transform .15s, opacity .15s;
22
+ }
23
+
24
+ .__poveste-scale-y-enter-from,
25
+ .__poveste-scale-y-leave-to {
26
+ transform: scaleY(0);
27
+ opacity: 0;
28
+ }
29
+
30
+ .__poveste-fade-enter-active,
31
+ .__poveste-fade-leave-active {
32
+ transition: opacity .15s;
33
+ }
34
+
35
+ .__poveste-fade-enter-from,
36
+ .__poveste-fade-leave-to {
37
+ opacity: 0;
38
+ }
39
+
40
+ .__poveste-fade-bottom-enter-active,
41
+ .__poveste-fade-bottom-leave-active {
42
+ transition: transform .15s, opacity .15s;
43
+ transform: translateY(0px);
44
+ }
45
+
46
+ .__poveste-fade-bottom-enter-from,
47
+ .__poveste-fade-bottom-leave-to {
48
+ transform: translateY(32px);
49
+ opacity: 0;
51
50
  }
@@ -1 +1,6 @@
1
+ // `navigator.platform` is deprecated with no cross-browser replacement:
2
+ // `navigator.userAgentData` is Chromium-only, so reading it here would simply
3
+ // stop detecting macOS in Safari and Firefox — the two places where getting the
4
+ // ⌘ shortcuts right matters most.
5
+ // eslint-disable-next-line ts/no-deprecated
1
6
  export const isMac = navigator.platform.toLowerCase().includes('mac')
@@ -1,7 +1,6 @@
1
1
  import { EVENT_SEND } from './const'
2
2
 
3
3
  export async function logEvent(name: string, argument) {
4
- console.log('[poveste] Event fired', { name, argument })
5
4
  const event = {
6
5
  name,
7
6
  argument: JSON.parse(stringifyEvent(argument)), // Needed for HTMLEvent that can't be cloned
@@ -0,0 +1,32 @@
1
+ import type { Highlighter } from 'shiki'
2
+ import { createHighlighter } from 'shiki'
3
+
4
+ /**
5
+ * Shiki is meant to be used as a singleton: each instance carries its own WASM
6
+ * engine and grammar set. The source pane unmounts and remounts on every story
7
+ * navigation, so creating one per mount grows memory for the lifetime of the
8
+ * tab — and trips Shiki's own warning once ten are live.
9
+ *
10
+ * The langs and themes are fixed, so one shared instance is always correct.
11
+ */
12
+ let highlighterPromise: Promise<Highlighter> | undefined
13
+
14
+ export function getHighlighter(): Promise<Highlighter> {
15
+ highlighterPromise ??= createHighlighter({
16
+ langs: [
17
+ 'html',
18
+ 'jsx',
19
+ ],
20
+ themes: [
21
+ 'github-light',
22
+ 'github-dark',
23
+ ],
24
+ }).catch((e) => {
25
+ // Don't let a cached rejection disable highlighting for the rest of the
26
+ // session — drop it so the next mount can try again.
27
+ highlighterPromise = undefined
28
+ throw e
29
+ })
30
+
31
+ return highlighterPromise
32
+ }
@@ -7,7 +7,7 @@ export function useScrollOnActive(active: Ref<boolean>, el: Ref<HTMLElement>) {
7
7
  if (value) {
8
8
  autoScroll()
9
9
  }
10
- })
10
+ }, { flush: 'post' })
11
11
 
12
12
  function autoScroll() {
13
13
  if (el.value) {
@@ -16,6 +16,7 @@ export function useScrollOnActive(active: Ref<boolean>, el: Ref<HTMLElement>) {
16
16
  block: 'center',
17
17
  inline: 'nearest',
18
18
  behavior: 'smooth',
19
+ boundary: document.body,
19
20
  })
20
21
  }
21
22
  }
@@ -3,11 +3,11 @@ import { formatKey } from './keyboard.js'
3
3
 
4
4
  export function makeTooltip(descriptionHtml: string, keyboardShortcut: (options: { isMac: boolean }) => string) {
5
5
  return {
6
- content: `<div>${descriptionHtml}</div><div class="ptw-flex ptw-items-center ptw-gap-1 ptw-mt-2 ptw-text-sm">${genKeyboardShortcutHtml(keyboardShortcut({ isMac }))}</div>`,
6
+ content: `<div>${descriptionHtml}</div><div class="flex items-center gap-1 mt-2 text-sm">${genKeyboardShortcutHtml(keyboardShortcut({ isMac }))}</div>`,
7
7
  html: true,
8
8
  }
9
9
  }
10
10
 
11
11
  function genKeyboardShortcutHtml(shortcut: string) {
12
- return `<span class="ptw-border ptw-border-gray-600 ptw-px-1 ptw-rounded-sm ptw-text-gray-400">${shortcut.split('+').map(k => formatKey(k.trim())).join(' ')}</span>`
12
+ return `<span class="border border-gray-600 px-1 rounded-sm text-gray-400">${shortcut.split('+').map(k => formatKey(k.trim())).join(' ')}</span>`
13
13
  }
@@ -1,5 +0,0 @@
1
- import _sfc_main from "./App.vue2.js";
2
- "use strict";
3
- export {
4
- _sfc_main as default
5
- };
@@ -1,211 +0,0 @@
1
- import { defineComponent, ref, computed, watch, onMounted, resolveComponent, createElementBlock, openBlock, createCommentVNode, createElementVNode, createVNode, unref, createBlock, normalizeStyle, withCtx, Transition } from "@poveste/vendors/vue";
2
- import { useTitle } from "@poveste/vendors/vue-use";
3
- import { files, tree, onUpdate } from "virtual:$poveste-stories";
4
- import "./components/app/AppActions.vue.js";
5
- import "./components/app/AppHeader.vue.js";
6
- import Breadcrumb from "./components/app/Breadcrumb.vue.js";
7
- import "./components/app/InitialLoading.vue.js";
8
- import "./components/app/TopBar.vue.js";
9
- import BaseSplitPane from "./components/base/BaseSplitPane.vue.js";
10
- import "./components/command/CommandPromptsModal.vue.js";
11
- import "./components/layout/LayoutModal.vue.js";
12
- import "./components/search/SearchModal.vue.js";
13
- import "./components/story/GenericMountStory.vue.js";
14
- import "./components/tree/StoryList.vue.js";
15
- import { useCommandStore } from "./stores/command.js";
16
- import { useLayoutStore } from "./stores/layout.js";
17
- import { useStoryStore } from "./stores/story.js";
18
- import { povesteConfig } from "./util/config.js";
19
- import { toggleDark } from "./util/dark.js";
20
- import { onKeyboardShortcut } from "./util/keyboard.js";
21
- import { mapFile } from "./util/mapping.js";
22
- import { isMobile } from "./util/responsive.js";
23
- import _sfc_main$1 from "./components/story/GenericMountStory.vue2.js";
24
- import _sfc_main$2 from "./components/app/AppHeader.vue2.js";
25
- import _sfc_main$3 from "./components/app/AppActions.vue2.js";
26
- import _sfc_main$4 from "./components/app/TopBar.vue2.js";
27
- import _sfc_main$5 from "./components/tree/StoryList.vue2.js";
28
- import _sfc_main$6 from "./components/layout/LayoutModal.vue2.js";
29
- import _sfc_main$7 from "./components/search/SearchModal.vue2.js";
30
- import _sfc_main$8 from "./components/command/CommandPromptsModal.vue2.js";
31
- import _sfc_main$9 from "./components/app/InitialLoading.vue2.js";
32
- "use strict";
33
- const _hoisted_1 = { class: "poveste-app-root ptw-h-full" };
34
- const _hoisted_2 = {
35
- key: 0,
36
- class: "poveste-app ptw-hidden"
37
- };
38
- const _hoisted_3 = {
39
- key: 0,
40
- class: "ptw-h-full ptw-flex ptw-flex-col ptw-divide-y ptw-divide-gray-100 dark:ptw-divide-gray-800"
41
- };
42
- const _hoisted_4 = { class: "ptw-flex ptw-items-center ptw-gap-2 ptw-pr-4" };
43
- const _hoisted_5 = { class: "ptw-flex ptw-flex-col ptw-h-full ptw-bg-gray-100 dark:ptw-bg-gray-750 __poveste-pane-shadow-from-right" };
44
- const _hoisted_6 = { class: "ptw-flex ptw-flex-col ptw-h-full" };
45
- const _hoisted_7 = {
46
- key: 2,
47
- class: "ptw-h-full ptw-flex ptw-flex-col"
48
- };
49
- const __default__ = {
50
- name: "PovesteApp"
51
- };
52
- const _sfc_main = /* @__PURE__ */ defineComponent({
53
- ...__default__,
54
- setup(__props) {
55
- const files$1 = ref(files.map((file) => mapFile(file)));
56
- const tree$1 = ref(tree);
57
- onUpdate((newFiles, newTree) => {
58
- loading.value = false;
59
- files$1.value = newFiles.map((file) => {
60
- const existingFile = files$1.value.find((f) => f.id === file.id);
61
- return mapFile(file, existingFile);
62
- });
63
- tree$1.value = newTree;
64
- });
65
- const stories = computed(() => files$1.value.reduce((acc, file) => {
66
- acc.push(file.story);
67
- return acc;
68
- }, []));
69
- const storyStore = useStoryStore();
70
- watch(stories, (value) => {
71
- storyStore.setStories(value);
72
- }, {
73
- immediate: true
74
- });
75
- useTitle(computed(() => {
76
- if (storyStore.currentStory) {
77
- let title = storyStore.currentStory.title;
78
- if (storyStore.currentVariant) {
79
- title += ` › ${storyStore.currentVariant.title}`;
80
- }
81
- return `${title} | ${povesteConfig.theme.title}`;
82
- }
83
- return povesteConfig.theme.title;
84
- }));
85
- const loadSearch = ref(false);
86
- const isSearchOpen = ref(false);
87
- const isLayoutOpen = ref(false);
88
- watch(isSearchOpen, (value) => {
89
- if (value) {
90
- loadSearch.value = true;
91
- }
92
- });
93
- onKeyboardShortcut(["ctrl+k", "meta+k"], (event) => {
94
- isSearchOpen.value = true;
95
- event.preventDefault();
96
- });
97
- onKeyboardShortcut(["ctrl+shift+l", "meta+shift+l"], (event) => {
98
- isLayoutOpen.value = !isLayoutOpen.value;
99
- event.preventDefault();
100
- });
101
- onKeyboardShortcut(["ctrl+shift+d", "meta+shift+d"], (event) => {
102
- event.preventDefault();
103
- toggleDark();
104
- });
105
- const loading = ref(false);
106
- if (import.meta.hot && !files.length) {
107
- loading.value = true;
108
- import.meta.hot.on("poveste:all-stories-loaded", () => {
109
- loading.value = false;
110
- });
111
- }
112
- const mounted = ref(false);
113
- onMounted(() => {
114
- mounted.value = true;
115
- });
116
- const commandStore = useCommandStore();
117
- const layoutStore = useLayoutStore();
118
- return (_ctx, _cache) => {
119
- const _component_RouterView = resolveComponent("RouterView");
120
- return openBlock(), createElementBlock("div", _hoisted_1, [
121
- unref(storyStore).currentStory ? (openBlock(), createElementBlock("div", _hoisted_2, [
122
- (openBlock(), createBlock(_sfc_main$1, {
123
- key: unref(storyStore).currentStory.id,
124
- story: unref(storyStore).currentStory
125
- }, null, 8, ["story"]))
126
- ])) : createCommentVNode("", true),
127
- createElementVNode("div", {
128
- class: "ptw-h-screen ptw-bg-gray-100 dark:ptw-bg-gray-750 dark:ptw-text-gray-100",
129
- style: normalizeStyle({
130
- // Prevent flash of content
131
- opacity: mounted.value ? 1 : 0
132
- })
133
- }, [
134
- unref(isMobile) ? (openBlock(), createElementBlock("div", _hoisted_3, [
135
- createElementVNode("div", _hoisted_4, [
136
- createVNode(_sfc_main$2, { class: "ptw-flex-1" }),
137
- createVNode(_sfc_main$3, {
138
- class: "ptw-flex-none",
139
- onLayout: _cache[0] || (_cache[0] = ($event) => isLayoutOpen.value = true),
140
- onSearch: _cache[1] || (_cache[1] = ($event) => isSearchOpen.value = true)
141
- })
142
- ]),
143
- createVNode(Breadcrumb, {
144
- tree: tree$1.value,
145
- stories: stories.value
146
- }, null, 8, ["tree", "stories"]),
147
- createVNode(_component_RouterView, { class: "ptw-grow" })
148
- ])) : unref(layoutStore).settings.storyListVisible ? (openBlock(), createBlock(BaseSplitPane, {
149
- key: 1,
150
- "save-id": "main-horiz",
151
- min: 5,
152
- max: 50,
153
- "default-split": 15,
154
- class: "ptw-h-full"
155
- }, {
156
- first: withCtx(() => [
157
- createElementVNode("div", _hoisted_5, [
158
- createVNode(_sfc_main$2, { class: "ptw-flex-none" }),
159
- createVNode(_sfc_main$5, {
160
- tree: tree$1.value,
161
- stories: stories.value,
162
- class: "ptw-flex-1"
163
- }, null, 8, ["tree", "stories"])
164
- ])
165
- ]),
166
- last: withCtx(() => [
167
- createElementVNode("div", _hoisted_6, [
168
- createVNode(_sfc_main$4, {
169
- onLayout: _cache[2] || (_cache[2] = ($event) => isLayoutOpen.value = true),
170
- onSearch: _cache[3] || (_cache[3] = ($event) => isSearchOpen.value = true)
171
- }),
172
- createVNode(_component_RouterView, { class: "ptw-flex-1 ptw-min-h-0" })
173
- ])
174
- ]),
175
- _: 1
176
- })) : (openBlock(), createElementBlock("div", _hoisted_7, [
177
- createVNode(_sfc_main$4, {
178
- onLayout: _cache[4] || (_cache[4] = ($event) => isLayoutOpen.value = true),
179
- onSearch: _cache[5] || (_cache[5] = ($event) => isSearchOpen.value = true)
180
- }),
181
- createVNode(_component_RouterView, { class: "ptw-flex-1 ptw-min-h-0" })
182
- ])),
183
- !unref(isMobile) ? (openBlock(), createBlock(_sfc_main$6, {
184
- key: 3,
185
- shown: isLayoutOpen.value,
186
- onClose: _cache[6] || (_cache[6] = ($event) => isLayoutOpen.value = false)
187
- }, null, 8, ["shown"])) : createCommentVNode("", true),
188
- loadSearch.value ? (openBlock(), createBlock(_sfc_main$7, {
189
- key: 4,
190
- shown: isSearchOpen.value,
191
- onClose: _cache[7] || (_cache[7] = ($event) => isSearchOpen.value = false)
192
- }, null, 8, ["shown"])) : createCommentVNode("", true),
193
- _ctx.__POVESTE_DEV__ ? (openBlock(), createBlock(_sfc_main$8, {
194
- key: 5,
195
- shown: unref(commandStore).showPromptsModal,
196
- onClose: _cache[8] || (_cache[8] = ($event) => unref(commandStore).showPromptsModal = false)
197
- }, null, 8, ["shown"])) : createCommentVNode("", true)
198
- ], 4),
199
- createVNode(Transition, { name: "__poveste-fade" }, {
200
- default: withCtx(() => [
201
- loading.value ? (openBlock(), createBlock(_sfc_main$9, { key: 0 })) : createCommentVNode("", true)
202
- ]),
203
- _: 1
204
- })
205
- ]);
206
- };
207
- }
208
- });
209
- export {
210
- _sfc_main as default
211
- };
@@ -1,4 +0,0 @@
1
- const PovesteLogoDark = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxODcwIDUxMiIgZmlsbD0ibm9uZSI+CiAgPGRlZnM+CiAgICA8bGluZWFyR3JhZGllbnQgaWQ9InB2dyIgeDE9Ijk2IiB5MT0iNDE2IiB4Mj0iNDE2IiB5Mj0iOTYiIGdyYWRpZW50VW5pdHM9InVzZXJTcGFjZU9uVXNlIj4KICAgICAgPHN0b3Agb2Zmc2V0PSIwIiBzdG9wLWNvbG9yPSIjMjRDNTZBIi8+CiAgICAgIDxzdG9wIG9mZnNldD0iMSIgc3RvcC1jb2xvcj0iIzE3QTZDNiIvPgogICAgPC9saW5lYXJHcmFkaWVudD4KICA8L2RlZnM+CiAgPHJlY3QgeD0iMTYiIHk9IjE2IiB3aWR0aD0iNDgwIiBoZWlnaHQ9IjQ4MCIgcng9IjExMiIgZmlsbD0idXJsKCNwdncpIi8+CiAgPHJlY3QgeD0iMTQwIiB5PSIxNDIiIHdpZHRoPSIyMzIiIGhlaWdodD0iNDQiIHJ4PSIxNiIgZmlsbD0iI2ZmZiIvPgogIDxyZWN0IHg9IjE1MSIgeT0iMjE3IiB3aWR0aD0iODgiIGhlaWdodD0iMTQ2IiByeD0iOSIgc3Ryb2tlPSIjZmZmIiBzdHJva2Utd2lkdGg9IjIyIi8+CiAgPHJlY3QgeD0iMTcyIiB5PSIyNDQiIHdpZHRoPSIzMCIgaGVpZ2h0PSI5MiIgcng9IjEzIiBmaWxsPSIjZmZmIi8+CiAgPHJlY3QgeD0iMjYyIiB5PSIyMDYiIHdpZHRoPSIxMTAiIGhlaWdodD0iMTY4IiByeD0iMjAiIGZpbGw9IiNmZmYiLz4KICA8cmVjdCB4PSIyODQiIHk9IjIyNiIgd2lkdGg9IjY2IiBoZWlnaHQ9IjU4IiByeD0iMTMiIGZpbGw9InVybCgjcHZ3KSIvPgogIDx0ZXh0IHg9IjY3NiIgeT0iMjU2IiBkb21pbmFudC1iYXNlbGluZT0iY2VudHJhbCIgZm9udC1mYW1pbHk9InVpLXNhbnMtc2VyaWYsIHN5c3RlbS11aSwgLWFwcGxlLXN5c3RlbSwgJ1NlZ29lIFVJJywgUm9ib3RvLCBIZWx2ZXRpY2EsIEFyaWFsLCBzYW5zLXNlcmlmIiBmb250LXNpemU9IjMyMCIgZm9udC13ZWlnaHQ9IjQwMCIgbGV0dGVyLXNwYWNpbmc9Ii00IiBmaWxsPSIjZjhmYWZjIj5Qb3Zlc3RlPC90ZXh0Pgo8L3N2Zz4K";
2
- export {
3
- PovesteLogoDark as default
4
- };
@@ -1,4 +0,0 @@
1
- const PovesteLogoLight = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxODcwIDUxMiIgZmlsbD0ibm9uZSI+CiAgPGRlZnM+CiAgICA8bGluZWFyR3JhZGllbnQgaWQ9InB2dyIgeDE9Ijk2IiB5MT0iNDE2IiB4Mj0iNDE2IiB5Mj0iOTYiIGdyYWRpZW50VW5pdHM9InVzZXJTcGFjZU9uVXNlIj4KICAgICAgPHN0b3Agb2Zmc2V0PSIwIiBzdG9wLWNvbG9yPSIjMjRDNTZBIi8+CiAgICAgIDxzdG9wIG9mZnNldD0iMSIgc3RvcC1jb2xvcj0iIzE3QTZDNiIvPgogICAgPC9saW5lYXJHcmFkaWVudD4KICA8L2RlZnM+CiAgPHJlY3QgeD0iMTYiIHk9IjE2IiB3aWR0aD0iNDgwIiBoZWlnaHQ9IjQ4MCIgcng9IjExMiIgZmlsbD0idXJsKCNwdncpIi8+CiAgPHJlY3QgeD0iMTQwIiB5PSIxNDIiIHdpZHRoPSIyMzIiIGhlaWdodD0iNDQiIHJ4PSIxNiIgZmlsbD0iI2ZmZiIvPgogIDxyZWN0IHg9IjE1MSIgeT0iMjE3IiB3aWR0aD0iODgiIGhlaWdodD0iMTQ2IiByeD0iOSIgc3Ryb2tlPSIjZmZmIiBzdHJva2Utd2lkdGg9IjIyIi8+CiAgPHJlY3QgeD0iMTcyIiB5PSIyNDQiIHdpZHRoPSIzMCIgaGVpZ2h0PSI5MiIgcng9IjEzIiBmaWxsPSIjZmZmIi8+CiAgPHJlY3QgeD0iMjYyIiB5PSIyMDYiIHdpZHRoPSIxMTAiIGhlaWdodD0iMTY4IiByeD0iMjAiIGZpbGw9IiNmZmYiLz4KICA8cmVjdCB4PSIyODQiIHk9IjIyNiIgd2lkdGg9IjY2IiBoZWlnaHQ9IjU4IiByeD0iMTMiIGZpbGw9InVybCgjcHZ3KSIvPgogIDx0ZXh0IHg9IjY3NiIgeT0iMjU2IiBkb21pbmFudC1iYXNlbGluZT0iY2VudHJhbCIgZm9udC1mYW1pbHk9InVpLXNhbnMtc2VyaWYsIHN5c3RlbS11aSwgLWFwcGxlLXN5c3RlbSwgJ1NlZ29lIFVJJywgUm9ib3RvLCBIZWx2ZXRpY2EsIEFyaWFsLCBzYW5zLXNlcmlmIiBmb250LXNpemU9IjMyMCIgZm9udC13ZWlnaHQ9IjQwMCIgbGV0dGVyLXNwYWNpbmc9Ii00IiBmaWxsPSIjMWUyOTNiIj5Qb3Zlc3RlPC90ZXh0Pgo8L3N2Zz4K";
2
- export {
3
- PovesteLogoLight as default
4
- };