astro-tractstack 2.1.3 → 2.2.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 (128) hide show
  1. package/README.md +54 -266
  2. package/bin/create-tractstack.js +9 -6
  3. package/dist/index.js +109 -71
  4. package/package.json +4 -2
  5. package/templates/css/custom.css +5 -0
  6. package/templates/icons/code.svg +18 -0
  7. package/templates/icons/li.svg +4 -0
  8. package/templates/icons/link.svg +22 -0
  9. package/templates/icons/p.svg +3 -0
  10. package/templates/src/client/app.js +80 -1
  11. package/templates/src/components/Footer.astro +1 -1
  12. package/templates/src/components/codehooks/BunnyVideoSetup.tsx +6 -6
  13. package/templates/src/components/codehooks/EpinetDurationSelector.tsx +3 -3
  14. package/templates/src/components/codehooks/FeaturedArticleSetup.tsx +1 -1
  15. package/templates/src/components/codehooks/ListContentSetup.tsx +2 -2
  16. package/templates/src/components/codehooks/ProductCardSetup.tsx +1 -1
  17. package/templates/src/components/codehooks/ProductGridSetup.tsx +2 -2
  18. package/templates/src/components/codehooks/SandboxRegisterForm.tsx +3 -3
  19. package/templates/src/components/compositor/Compositor.tsx +25 -9
  20. package/templates/src/components/compositor/Node.tsx +168 -496
  21. package/templates/src/components/compositor/PanelVisibilityWrapper.tsx +1 -0
  22. package/templates/src/components/compositor/elements/SignUp.tsx +1 -1
  23. package/templates/src/components/compositor/elements/YouTubeWrapper.tsx +2 -0
  24. package/templates/src/components/compositor/nodes/CreativePane.tsx +262 -0
  25. package/templates/src/components/compositor/nodes/GhostInsertBlock.tsx +4 -6
  26. package/templates/src/components/compositor/nodes/GridLayout.tsx +4 -2
  27. package/templates/src/components/compositor/nodes/Markdown.tsx +18 -3
  28. package/templates/src/components/compositor/nodes/Pane.tsx +11 -5
  29. package/templates/src/components/compositor/nodes/RenderChildren.tsx +1 -1
  30. package/templates/src/components/compositor/nodes/tagElements/NodeAnchorComponent.tsx +5 -5
  31. package/templates/src/components/compositor/nodes/tagElements/NodeBasicTag.tsx +90 -42
  32. package/templates/src/components/compositor/nodes/tagElements/NodeImg.tsx +2 -0
  33. package/templates/src/components/compositor/nodes/tagElements/NodeText.tsx +27 -1
  34. package/templates/src/components/compositor/preview/PaneSnapshotGenerator.tsx +10 -8
  35. package/templates/src/components/compositor/tools/NodeOverlay.tsx +224 -0
  36. package/templates/src/components/compositor/tools/PaneOverlay.tsx +122 -0
  37. package/templates/src/components/edit/Header.tsx +68 -9
  38. package/templates/src/components/edit/PanelSwitch.tsx +42 -4
  39. package/templates/src/components/edit/SettingsPanel.tsx +2 -3
  40. package/templates/src/components/edit/ToolMode.tsx +1 -31
  41. package/templates/src/components/edit/pane/AddPanePanel_break.tsx +2 -2
  42. package/templates/src/components/edit/pane/AddPanePanel_codehook.tsx +1 -1
  43. package/templates/src/components/edit/pane/AddPanePanel_new.tsx +193 -659
  44. package/templates/src/components/edit/pane/AddPanePanel_reuse.tsx +15 -82
  45. package/templates/src/components/edit/pane/AiRestylePaneModal.tsx +95 -45
  46. package/templates/src/components/edit/pane/ConfigPanePanel.tsx +137 -49
  47. package/templates/src/components/edit/pane/RestylePaneModal.tsx +1 -1
  48. package/templates/src/components/edit/pane/steps/AiCreativeDesignStep.tsx +375 -0
  49. package/templates/src/components/edit/pane/steps/AiDesignStep.tsx +1 -23
  50. package/templates/src/components/edit/pane/steps/AiLibraryCopyStep.tsx +327 -0
  51. package/templates/src/components/edit/pane/steps/AiRefineDesignStep.tsx +267 -0
  52. package/templates/src/components/edit/pane/steps/AiStandardDesignStep.tsx +371 -0
  53. package/templates/src/components/edit/pane/steps/CopyInputStep.tsx +201 -76
  54. package/templates/src/components/edit/pane/steps/CreativeInjectStep.tsx +141 -0
  55. package/templates/src/components/edit/panels/CreativeImagePanel.tsx +435 -0
  56. package/templates/src/components/edit/panels/CreativeLinkPanel.tsx +110 -0
  57. package/templates/src/components/edit/panels/StyleCodeHookPanel.tsx +1 -1
  58. package/templates/src/components/edit/panels/StyleParentPanel.tsx +118 -126
  59. package/templates/src/components/edit/panels/StyleParentPanel_add.tsx +3 -2
  60. package/templates/src/components/edit/panels/StyleParentPanel_deleteLayer.tsx +1 -0
  61. package/templates/src/components/edit/panels/StyleParentPanel_remove.tsx +3 -1
  62. package/templates/src/components/edit/panels/StyleParentPanel_update.tsx +3 -1
  63. package/templates/src/components/edit/panels/StyleWidgetPanel.tsx +1 -1
  64. package/templates/src/components/edit/state/SaveModal.tsx +19 -787
  65. package/templates/src/components/edit/state/SaveToLibraryModal.tsx +2 -2
  66. package/templates/src/components/edit/storyfragment/StoryFragmentPanel_menu.tsx +1 -1
  67. package/templates/src/components/edit/widgets/BunnyWidget.tsx +5 -5
  68. package/templates/src/components/edit/widgets/InteractiveDisclosureWidget.tsx +1 -1
  69. package/templates/src/components/edit/widgets/SignupWidget.tsx +1 -1
  70. package/templates/src/components/fields/ActionBuilderTimeSelector.tsx +1 -1
  71. package/templates/src/components/fields/ArtpackImage.tsx +11 -3
  72. package/templates/src/components/fields/BackgroundImage.tsx +8 -0
  73. package/templates/src/components/fields/BackgroundImageWrapper.tsx +15 -9
  74. package/templates/src/components/fields/ImageUpload.tsx +6 -0
  75. package/templates/src/components/form/ActionBuilderField.tsx +15 -5
  76. package/templates/src/components/form/ActionBuilderSlugSelector.tsx +1 -1
  77. package/templates/src/components/form/ColorPicker.tsx +1 -1
  78. package/templates/src/components/form/EnumSelect.tsx +1 -1
  79. package/templates/src/components/form/NumberInput.tsx +1 -1
  80. package/templates/src/components/form/StringArrayInput.tsx +1 -1
  81. package/templates/src/components/form/StringInput.tsx +1 -1
  82. package/templates/src/components/form/UnsavedChangesBar.tsx +1 -1
  83. package/templates/src/components/form/advanced/APIConfigSection.tsx +2 -2
  84. package/templates/src/components/form/advanced/AuthConfigSection.tsx +2 -2
  85. package/templates/src/components/profile/ProfileCreate.tsx +1 -1
  86. package/templates/src/components/profile/ProfileEdit.tsx +1 -1
  87. package/templates/src/components/storykeep/Dashboard_Advanced.tsx +2 -2
  88. package/templates/src/components/storykeep/controls/content/BeliefForm.tsx +1 -1
  89. package/templates/src/components/storykeep/controls/content/ContentSummary.tsx +2 -2
  90. package/templates/src/components/storykeep/controls/content/KnownResourceTable.tsx +1 -1
  91. package/templates/src/components/storykeep/controls/content/ManageContent.tsx +6 -6
  92. package/templates/src/components/storykeep/controls/content/MenuForm.tsx +1 -1
  93. package/templates/src/components/storykeep/controls/content/PaneTable.tsx +358 -0
  94. package/templates/src/components/storykeep/controls/content/ResourceTable.tsx +1 -1
  95. package/templates/src/constants/prompts.json +18 -10
  96. package/templates/src/constants.ts +3 -0
  97. package/templates/src/hooks/usePaneFragments.ts +60 -0
  98. package/templates/src/lib/session.ts +71 -16
  99. package/templates/src/pages/[...slug].astro +4 -46
  100. package/templates/src/pages/api/css.ts +149 -0
  101. package/templates/src/pages/maint.astro +1 -1
  102. package/templates/src/pages/storykeep/login.astro +2 -2
  103. package/templates/src/stores/nodes.ts +162 -49
  104. package/templates/src/stores/orphanAnalysis.ts +6 -30
  105. package/templates/src/stores/previews.ts +7 -0
  106. package/templates/src/stores/storykeep.ts +0 -8
  107. package/templates/src/types/compositorTypes.ts +53 -10
  108. package/templates/src/utils/compositor/aiGeneration.ts +93 -0
  109. package/templates/src/utils/compositor/allowInsert.ts +2 -0
  110. package/templates/src/utils/compositor/htmlAst.ts +704 -0
  111. package/templates/src/utils/compositor/nodesHelper.ts +281 -102
  112. package/templates/src/utils/compositor/savePipeline.ts +893 -0
  113. package/templates/src/utils/etl/index.ts +3 -0
  114. package/templates/src/utils/etl/transformer.ts +10 -0
  115. package/templates/src/utils/helpers.ts +101 -0
  116. package/utils/inject-files.ts +100 -62
  117. package/templates/icons/text.svg +0 -6
  118. package/templates/src/components/compositor/NodeWithGuid.tsx +0 -69
  119. package/templates/src/components/compositor/nodes/GridLayout_eraser.tsx +0 -33
  120. package/templates/src/components/compositor/nodes/Markdown_eraser.tsx +0 -56
  121. package/templates/src/components/compositor/nodes/Pane_DesignLibrary.tsx +0 -269
  122. package/templates/src/components/compositor/nodes/Pane_eraser.tsx +0 -186
  123. package/templates/src/components/compositor/nodes/Pane_layout.tsx +0 -79
  124. package/templates/src/components/compositor/nodes/tagElements/NodeA_eraser.tsx +0 -26
  125. package/templates/src/components/compositor/nodes/tagElements/NodeBasicTag_eraser.tsx +0 -61
  126. package/templates/src/components/compositor/nodes/tagElements/NodeBasicTag_insert.tsx +0 -120
  127. package/templates/src/components/compositor/nodes/tagElements/NodeBasicTag_settings.tsx +0 -62
  128. package/templates/src/components/compositor/nodes/tagElements/NodeButton_eraser.tsx +0 -26
@@ -0,0 +1,122 @@
1
+ import { type MouseEvent } from 'react';
2
+ import { useStore } from '@nanostores/react';
3
+ import PencilSquareIcon from '@heroicons/react/24/outline/PencilSquareIcon';
4
+ import { settingsPanelStore } from '@/stores/storykeep';
5
+ import { getCtx } from '@/stores/nodes';
6
+ import { classNames } from '@/utils/helpers';
7
+ import type { NodeProps } from '@/types/nodeProps';
8
+
9
+ interface PaneOverlayProps extends NodeProps {
10
+ layer?: number;
11
+ isColumn?: boolean;
12
+ hasBackground?: boolean;
13
+ }
14
+
15
+ export const PaneOverlay = (props: PaneOverlayProps) => {
16
+ const { nodeId, layer, isColumn, hasBackground } = props;
17
+ const ctx = getCtx(props);
18
+ const settingsPanel = useStore(settingsPanelStore);
19
+ const toolMode = useStore(ctx.toolModeValStore).value;
20
+ const node = ctx.allNodes.get().get(nodeId);
21
+
22
+ if (!node) return null;
23
+
24
+ const showButtons = layer || isColumn || hasBackground;
25
+
26
+ const handleBgClick = (e: MouseEvent) => {
27
+ e.stopPropagation();
28
+ settingsPanelStore.set({
29
+ nodeId,
30
+ action: 'style-parent',
31
+ view: 'backgroundImage',
32
+ expanded: true,
33
+ });
34
+ };
35
+
36
+ const handleLayerClick = (e: MouseEvent) => {
37
+ e.stopPropagation();
38
+ settingsPanelStore.set({
39
+ nodeId,
40
+ action: 'style-parent',
41
+ view: 'wrapperStyles',
42
+ layer: layer || 1,
43
+ expanded: true,
44
+ });
45
+ };
46
+
47
+ const handleColumnClick = (e: MouseEvent) => {
48
+ e.stopPropagation();
49
+ settingsPanelStore.set({
50
+ nodeId,
51
+ action: 'style-parent',
52
+ view: 'summary',
53
+ expanded: true,
54
+ });
55
+ };
56
+
57
+ const isSelected = settingsPanel?.nodeId === nodeId;
58
+
59
+ const outlineClass = isSelected
60
+ ? 'outline outline-4 outline-dotted outline-orange-400 outline-offset-2'
61
+ : 'group-hover:outline group-hover:outline-2 group-hover:outline-dotted group-hover:outline-cyan-500 group-hover:outline-offset-2';
62
+
63
+ return (
64
+ <>
65
+ <div
66
+ className={classNames(
67
+ 'pointer-events-none absolute inset-0 z-10 transition-all duration-200',
68
+ toolMode === 'text' ? outlineClass : ''
69
+ )}
70
+ />
71
+
72
+ {showButtons && (
73
+ <div
74
+ className="pane-overlay compositor-chrome absolute flex gap-1 opacity-10 transition-opacity duration-200 group-hover:opacity-100"
75
+ style={{
76
+ top: '-24px',
77
+ right: 0,
78
+ zIndex: 10,
79
+ }}
80
+ onClick={(e) => e.stopPropagation()}
81
+ data-attr="exclude"
82
+ data-node-id={nodeId}
83
+ data-layer={layer}
84
+ >
85
+ {hasBackground && (
86
+ <button
87
+ onClick={handleBgClick}
88
+ className="flex h-6 w-auto min-w-px cursor-help items-center justify-center px-1"
89
+ title="Edit Background"
90
+ >
91
+ <img
92
+ src="/icons/image.svg"
93
+ alt="background"
94
+ className="h-3.5 w-auto"
95
+ />
96
+ </button>
97
+ )}
98
+
99
+ {layer && (
100
+ <button
101
+ onClick={handleLayerClick}
102
+ className="flex h-6 w-6 items-center justify-center rounded-full bg-purple-600 text-white shadow-md hover:scale-110 hover:bg-purple-600"
103
+ title={`Edit Layer ${layer}`}
104
+ >
105
+ <PencilSquareIcon className="h-3.5 w-3.5" />
106
+ </button>
107
+ )}
108
+
109
+ {isColumn && (
110
+ <button
111
+ onClick={handleColumnClick}
112
+ className="flex h-6 w-6 items-center justify-center rounded-full bg-purple-600 text-white shadow-md hover:scale-110 hover:bg-purple-600"
113
+ title="Edit Column Styles"
114
+ >
115
+ <PencilSquareIcon className="h-3.5 w-3.5" />
116
+ </button>
117
+ )}
118
+ </div>
119
+ )}
120
+ </>
121
+ );
122
+ };
@@ -12,6 +12,7 @@ import ExclamationTriangleIcon from '@heroicons/react/24/outline/ExclamationTria
12
12
  import {
13
13
  viewportModeStore,
14
14
  setViewportMode,
15
+ viewportKeyStore,
15
16
  settingsPanelStore,
16
17
  pendingHomePageSlugStore,
17
18
  saasModalOpenStore,
@@ -33,6 +34,7 @@ const StoryKeepHeader = ({
33
34
  const viewport = useStore(viewportModeStore);
34
35
  const pendingHomePageSlug = useStore(pendingHomePageSlugStore);
35
36
  const ctx = getCtx();
37
+ const showSaveBypass = useStore(ctx.showSaveBypass);
36
38
  const hasTitle = useStore(ctx.hasTitle);
37
39
  const hasPanes = useStore(ctx.hasPanes);
38
40
  const [canUndo, setCanUndo] = useState(false);
@@ -48,6 +50,25 @@ const StoryKeepHeader = ({
48
50
  ctx.history.history.listen(updateUndoRedo);
49
51
  }, [ctx.history]);
50
52
 
53
+ useEffect(() => {
54
+ if (viewport !== 'auto') return;
55
+
56
+ const handleResize = () => {
57
+ const width = window.innerWidth;
58
+ if (width >= 1368) {
59
+ viewportKeyStore.setKey('value', 'desktop');
60
+ } else if (width >= 801) {
61
+ viewportKeyStore.setKey('value', 'tablet');
62
+ } else {
63
+ viewportKeyStore.setKey('value', 'mobile');
64
+ }
65
+ };
66
+
67
+ handleResize();
68
+ window.addEventListener('resize', handleResize);
69
+ return () => window.removeEventListener('resize', handleResize);
70
+ }, [viewport]);
71
+
51
72
  const handleSave = () => {
52
73
  if (isSandboxMode) {
53
74
  saasModalOpenStore.set(true);
@@ -103,7 +124,7 @@ const StoryKeepHeader = ({
103
124
  ];
104
125
 
105
126
  // Show save button if there are undo changes OR pending home page change
106
- const shouldShowSave = canUndo || pendingHomePageSlug;
127
+ const shouldShowSave = canUndo || pendingHomePageSlug || showSaveBypass;
107
128
 
108
129
  if (!hasTitle && !hasPanes) return null;
109
130
 
@@ -172,15 +193,53 @@ const StoryKeepHeader = ({
172
193
  </div>
173
194
  )}
174
195
 
196
+ {import.meta.env.DEV && (
197
+ <button
198
+ onClick={() => {
199
+ const allNodesMap = ctx.allNodes.get();
200
+ const allNodesArray = Array.from(allNodesMap.values());
201
+
202
+ console.group('Dev Mode: Full Nodes Context Inspection');
203
+ console.log('Total Nodes in Store:', allNodesArray.length);
204
+ console.log('Full Nodes Map:', allNodesMap);
205
+
206
+ // Specifically audit Creative Panes for large htmlAst payloads
207
+ // Using type guards/property checks to handle the BaseNode vs PaneNode distinction
208
+ const creativePanes = allNodesArray.filter(
209
+ (n) => n.nodeType === 'Pane' && 'htmlAst' in n
210
+ );
211
+
212
+ if (creativePanes.length > 0) {
213
+ console.group('Creative Panes Detail (htmlAst Audit)');
214
+ creativePanes.forEach((pane) => {
215
+ // Guarding slug access since it is not on BaseNode
216
+ const nodeSlug =
217
+ 'slug' in pane ? (pane as any).slug : 'NO_SLUG';
218
+
219
+ console.log(`Pane ID: ${pane.id} | Slug: ${nodeSlug}`, {
220
+ editableElements: (pane as any).htmlAst?.editableElements,
221
+ tree: (pane as any).htmlAst?.tree,
222
+ css: (pane as any).htmlAst?.css,
223
+ });
224
+ });
225
+ console.groupEnd();
226
+ }
227
+
228
+ console.groupEnd();
229
+ }}
230
+ className="rounded-md bg-myblue px-3.5 py-1.5 font-action font-bold text-white hover:bg-myorange"
231
+ >
232
+ Inspect
233
+ </button>
234
+ )}
235
+
175
236
  {shouldShowSave && (
176
- <div className="flex flex-wrap items-center justify-center gap-2 text-sm">
177
- <button
178
- onClick={handleSave}
179
- className="rounded-md bg-myblue px-3.5 py-1.5 font-action font-bold text-white hover:bg-myorange"
180
- >
181
- Save
182
- </button>
183
- </div>
237
+ <button
238
+ onClick={handleSave}
239
+ className="rounded-md bg-myblue px-3.5 py-1.5 font-action font-bold text-white hover:bg-myorange"
240
+ >
241
+ Save
242
+ </button>
184
243
  )}
185
244
  </div>
186
245
 
@@ -6,6 +6,8 @@ import {
6
6
  isGridLayoutNode,
7
7
  isMarkdownPaneFragmentNode,
8
8
  } from '@/utils/compositor/typeGuards';
9
+ import CreativeImagePanel from './panels/CreativeImagePanel';
10
+ import CreativeLinkPanel from './panels/CreativeLinkPanel';
9
11
  import StyleBreakPanel from './panels/StyleBreakPanel';
10
12
  import StyleParentPanel from './panels/StyleParentPanel';
11
13
  import StyleParentAddPanel from './panels/StyleParentPanel_add';
@@ -41,6 +43,7 @@ import type {
41
43
  FlatNode,
42
44
  GridLayoutNode,
43
45
  MarkdownPaneFragmentNode,
46
+ SettingsPanelSignal,
44
47
  } from '@/types/compositorTypes';
45
48
 
46
49
  interface SettingsPanelProps {
@@ -109,6 +112,7 @@ const PanelSwitch = ({
109
112
  node={markdownNode}
110
113
  parentNode={paneNode}
111
114
  layer={signal.layer || 0}
115
+ view={signal.view}
112
116
  />
113
117
  );
114
118
  else if (gridLayoutNode && paneNode)
@@ -117,6 +121,7 @@ const PanelSwitch = ({
117
121
  node={gridLayoutNode}
118
122
  parentNode={paneNode}
119
123
  layer={signal.layer || 0}
124
+ view={signal.view}
120
125
  />
121
126
  );
122
127
  break;
@@ -127,7 +132,8 @@ const PanelSwitch = ({
127
132
  <StyleParentAddPanel
128
133
  node={markdownNode}
129
134
  layer={signal.layer || 0}
130
- targetProperty={(signal as any).targetProperty}
135
+ targetProperty={(signal as SettingsPanelSignal).targetProperty}
136
+ view={signal.view}
131
137
  />
132
138
  );
133
139
  else if (gridLayoutNode)
@@ -135,7 +141,8 @@ const PanelSwitch = ({
135
141
  <StyleParentAddPanel
136
142
  node={gridLayoutNode}
137
143
  layer={signal.layer || 0}
138
- targetProperty={(signal as any).targetProperty}
144
+ targetProperty={(signal as SettingsPanelSignal).targetProperty}
145
+ view={signal.view}
139
146
  />
140
147
  );
141
148
  break;
@@ -153,7 +160,8 @@ const PanelSwitch = ({
153
160
  node={clickedNode}
154
161
  layer={signal.layer || 0}
155
162
  className={signal.className}
156
- targetProperty={(signal as any).targetProperty}
163
+ targetProperty={(signal as SettingsPanelSignal).targetProperty}
164
+ view={signal.view}
157
165
  />
158
166
  );
159
167
  break;
@@ -171,7 +179,8 @@ const PanelSwitch = ({
171
179
  node={clickedNode}
172
180
  layer={signal.layer || 0}
173
181
  className={signal.className}
174
- targetProperty={(signal as any).targetProperty}
182
+ targetProperty={(signal as SettingsPanelSignal).targetProperty}
183
+ view={signal.view}
175
184
  />
176
185
  );
177
186
  break;
@@ -183,6 +192,7 @@ const PanelSwitch = ({
183
192
  <StyleParentDeleteLayerPanel
184
193
  node={markdownNode}
185
194
  layer={signal.layer || 0}
195
+ view={signal.view}
186
196
  />
187
197
  );
188
198
  break;
@@ -576,6 +586,34 @@ const PanelSwitch = ({
576
586
  );
577
587
  break;
578
588
 
589
+ case 'style-creative-img':
590
+ if (paneNode && signal.childId)
591
+ return (
592
+ <CreativeImagePanel
593
+ node={paneNode}
594
+ childId={signal.childId}
595
+ mode="img"
596
+ />
597
+ );
598
+ break;
599
+
600
+ case 'style-creative-bg':
601
+ if (paneNode && signal.childId)
602
+ return (
603
+ <CreativeImagePanel
604
+ node={paneNode}
605
+ childId={signal.childId}
606
+ mode="bg"
607
+ />
608
+ );
609
+ break;
610
+
611
+ case 'style-creative-link':
612
+ case 'style-creative-btn':
613
+ if (paneNode && signal.childId)
614
+ return <CreativeLinkPanel node={paneNode} childId={signal.childId} />;
615
+ break;
616
+
579
617
  default:
580
618
  settingsPanelStore.set(null);
581
619
  }
@@ -14,9 +14,8 @@ const SettingsPanel = ({ availableCodeHooks }: SettingsPanelProps) => {
14
14
  const signal = useStore(settingsPanelStore);
15
15
  const ctx = getCtx();
16
16
  const { value: toolModeVal } = useStore(ctx.toolModeValStore);
17
- const isLinkInsertSignal = signal?.action === 'style-link';
18
- const shouldShow =
19
- toolModeVal === 'styles' || (toolModeVal === 'text' && isLinkInsertSignal);
17
+ //const isLinkInsertSignal = signal?.action === 'style-link';
18
+ const shouldShow = signal !== null && toolModeVal !== 'insert';
20
19
 
21
20
  if (!shouldShow || !signal) {
22
21
  return null;
@@ -3,7 +3,7 @@ import { useStore } from '@nanostores/react';
3
3
  import PencilSquareIcon from '@heroicons/react/24/outline/PencilSquareIcon';
4
4
  import PaintBrushIcon from '@heroicons/react/24/outline/PaintBrushIcon';
5
5
  import TrashIcon from '@heroicons/react/24/outline/TrashIcon';
6
- import ArrowPathRoundedSquareIcon from '@heroicons/react/24/outline/ArrowPathRoundedSquareIcon';
6
+ import SparklesIcon from '@heroicons/react/24/outline/SparklesIcon';
7
7
  import ArrowsUpDownIcon from '@heroicons/react/24/outline/ArrowsUpDownIcon';
8
8
  import PlusIcon from '@heroicons/react/24/outline/PlusIcon';
9
9
  import BugAntIcon from '@heroicons/react/24/outline/BugAntIcon';
@@ -17,12 +17,6 @@ import type { ToolModeVal } from '@/types/compositorTypes';
17
17
  import { selectionStore, resetSelectionStore } from '@/stores/selection';
18
18
 
19
19
  const storykeepToolModes = [
20
- {
21
- key: 'styles' as const,
22
- Icon: PaintBrushIcon,
23
- title: 'Styles',
24
- description: 'Click to edit styles',
25
- },
26
20
  {
27
21
  key: 'text' as const,
28
22
  Icon: PencilSquareIcon,
@@ -35,30 +29,6 @@ const storykeepToolModes = [
35
29
  title: 'Add',
36
30
  description: 'Add new element, e.g. paragraph or image',
37
31
  },
38
- {
39
- key: 'eraser' as const,
40
- Icon: TrashIcon,
41
- title: 'Eraser',
42
- description: 'Erase any element(s)',
43
- },
44
- {
45
- key: 'move' as const,
46
- Icon: ArrowsUpDownIcon,
47
- title: 'Move',
48
- description: 'Keyboard accessible re-order',
49
- },
50
- {
51
- key: 'designLibrary' as const,
52
- Icon: ArrowPathRoundedSquareIcon,
53
- title: 'Design Library',
54
- description: 'Save pane to design library',
55
- },
56
- {
57
- key: 'debug' as const,
58
- Icon: BugAntIcon,
59
- title: 'Debug Mode',
60
- description: 'Toggle node tree id reveal',
61
- },
62
32
  ] as const;
63
33
 
64
34
  interface StoryKeepToolModeProps {
@@ -327,7 +327,7 @@ const AddPaneBreakPanel = ({
327
327
  composite={true}
328
328
  >
329
329
  <div className="relative">
330
- <div className="sm:text-sm relative w-full cursor-default overflow-hidden rounded-lg bg-white text-left shadow-md focus:outline-none focus-visible:ring-2 focus-visible:ring-white/75 focus-visible:ring-offset-2 focus-visible:ring-offset-teal-300">
330
+ <div className="relative w-full cursor-default overflow-hidden rounded-lg bg-white text-left shadow-md focus:outline-none focus-visible:ring-2 focus-visible:ring-white/75 focus-visible:ring-offset-2 focus-visible:ring-offset-teal-300 md:text-sm">
331
331
  <Combobox.Input
332
332
  autoComplete="off"
333
333
  className="w-full border-none py-2 pl-3 pr-10 text-sm leading-5 text-gray-900 focus:ring-0"
@@ -341,7 +341,7 @@ const AddPaneBreakPanel = ({
341
341
  </Combobox.Trigger>
342
342
  </div>
343
343
 
344
- <Combobox.Content className="sm:text-sm absolute z-50 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black/5 focus:outline-none">
344
+ <Combobox.Content className="absolute z-50 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black/5 focus:outline-none md:text-sm">
345
345
  {collection.items.length === 0 ? (
346
346
  <div className="relative cursor-default select-none px-4 py-2 text-gray-700">
347
347
  Nothing found.
@@ -212,7 +212,7 @@ const AddPaneCodeHookPanel = ({
212
212
  </Combobox.Trigger>
213
213
  </div>
214
214
 
215
- <Combobox.Content className="sm:text-sm absolute z-50 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none">
215
+ <Combobox.Content className="absolute z-50 mt-1 max-h-60 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none md:text-sm">
216
216
  {collection.items.length === 0 ? (
217
217
  <div className="relative cursor-default select-none px-4 py-2 text-gray-700">
218
218
  Nothing found.