@plitzi/plitzi-builder 0.38.4 → 0.38.6

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 (261) hide show
  1. package/CHANGELOG.md +372 -0
  2. package/dist/index.html +2 -15
  3. package/dist/modules/App/AppContainer/containers/ContainerServer.d.ts +2 -2
  4. package/dist/modules/App/components/AppDirectory/Directory.d.ts +3 -1
  5. package/dist/modules/App/helpers/utils.d.ts +1 -3
  6. package/dist/modules/Builder/components/BuilderSearch/helpers.d.ts +0 -1
  7. package/dist/modules/Builder/components/BuilderTree/utils.d.ts +1 -0
  8. package/dist/modules/Builder/hooks/useRevealElement.d.ts +6 -2
  9. package/dist/modules/Components/Components.d.ts +1 -1
  10. package/dist/modules/Components/components/ComponentForm/helpers.d.ts +15 -0
  11. package/dist/modules/Components/components/ComponentForm/index.d.ts +1 -0
  12. package/dist/modules/Components/components/FormSection/FormSection.d.ts +10 -0
  13. package/dist/modules/Components/components/FormSection/index.d.ts +3 -0
  14. package/dist/modules/Components/components/PropsEditor/helpers.d.ts +7 -0
  15. package/dist/modules/Data/Data.d.ts +7 -0
  16. package/dist/modules/Data/components/DataEditor/DataEditor.d.ts +12 -0
  17. package/dist/modules/Data/components/DataEditor/index.d.ts +3 -0
  18. package/dist/modules/Data/components/DataHeader/DataHeader.d.ts +14 -0
  19. package/dist/modules/Data/components/DataHeader/index.d.ts +3 -0
  20. package/dist/modules/Data/components/DataProblems/DataProblems.d.ts +9 -0
  21. package/dist/modules/Data/components/DataProblems/index.d.ts +3 -0
  22. package/dist/modules/Data/components/DataSidebar/DataSidebar.d.ts +13 -0
  23. package/dist/modules/Data/components/DataSidebar/index.d.ts +3 -0
  24. package/dist/modules/Data/components/DataWelcome/DataWelcome.d.ts +6 -0
  25. package/dist/modules/Data/components/DataWelcome/index.d.ts +3 -0
  26. package/dist/modules/Data/helpers.d.ts +12 -0
  27. package/dist/modules/Data/index.d.ts +2 -0
  28. package/dist/modules/Data/useData.d.ts +12 -0
  29. package/dist/modules/Elements/CategoryChip.d.ts +11 -0
  30. package/dist/modules/Elements/Element.d.ts +2 -1
  31. package/dist/modules/Elements/ElementCategory.d.ts +6 -3
  32. package/dist/modules/Elements/ElementHelper.d.ts +12 -2
  33. package/dist/modules/Elements/Elements.d.ts +4 -0
  34. package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/FileItem/FileItem.d.ts +1 -1
  35. package/dist/modules/FileTree/components/NewFile/NewFile.d.ts +11 -0
  36. package/dist/modules/FileTree/components/SaveStateBadge/SaveStateBadge.d.ts +7 -0
  37. package/dist/modules/FileTree/components/SaveStateBadge/index.d.ts +2 -0
  38. package/dist/modules/FileTree/helpers.d.ts +39 -0
  39. package/dist/modules/FileTree/index.d.ts +7 -0
  40. package/dist/modules/Functions/components/FunctionsHeader/FunctionsHeader.d.ts +1 -1
  41. package/dist/modules/Functions/helpers.d.ts +0 -35
  42. package/dist/modules/Interactions/components/Workflow/helpers/whileRunning.d.ts +1 -1
  43. package/dist/modules/Usages/Usages.d.ts +10 -0
  44. package/dist/modules/Usages/components/UsageList/UsageList.d.ts +13 -0
  45. package/dist/modules/Usages/components/UsageList/index.d.ts +3 -0
  46. package/dist/modules/Usages/components/UsageRow/UsageRow.d.ts +11 -0
  47. package/dist/modules/Usages/components/UsageRow/components/UsageElement/UsageElement.d.ts +8 -0
  48. package/dist/modules/Usages/components/UsageRow/components/UsageElement/index.d.ts +3 -0
  49. package/dist/modules/Usages/components/UsageRow/components/UsageOwner/UsageOwner.d.ts +9 -0
  50. package/dist/modules/Usages/components/UsageRow/components/UsageOwner/index.d.ts +3 -0
  51. package/dist/modules/Usages/components/UsageRow/components/UsageReferences/UsageReferences.d.ts +7 -0
  52. package/dist/modules/Usages/components/UsageRow/components/UsageReferences/index.d.ts +3 -0
  53. package/dist/modules/Usages/components/UsageRow/components/UsageTreeGroup/UsageTreeGroup.d.ts +7 -0
  54. package/dist/modules/Usages/components/UsageRow/components/UsageTreeGroup/index.d.ts +3 -0
  55. package/dist/modules/Usages/components/UsageRow/index.d.ts +3 -0
  56. package/dist/modules/Usages/helpers/copy.d.ts +21 -0
  57. package/dist/modules/Usages/helpers/grouping.d.ts +14 -0
  58. package/dist/modules/Usages/helpers/grouping.test.d.ts +1 -0
  59. package/dist/modules/Usages/helpers/providerTypes.d.ts +7 -0
  60. package/dist/modules/Usages/helpers/unusedParity.test.d.ts +1 -0
  61. package/dist/modules/Usages/helpers/usageIndex.d.ts +67 -0
  62. package/dist/modules/Usages/helpers/usageIndex.test.d.ts +1 -0
  63. package/dist/modules/Usages/hooks/useUsageIndex.d.ts +9 -0
  64. package/dist/modules/Usages/index.d.ts +3 -0
  65. package/dist/package.json.d.ts +3 -21
  66. package/dist/plitzi-builder.css +1 -1
  67. package/dist/plitzi-builder.css.gz +0 -0
  68. package/dist/plitzi-builder.js +2637 -2839
  69. package/dist/plitzi-builder.js.gz +0 -0
  70. package/dist/plitzi-functions-worker.js +1 -1
  71. package/package.json +17 -35
  72. package/dist/modules/AI/AiChat.d.ts +0 -2
  73. package/dist/modules/AI/components/AiChatContent/AiChatContent.d.ts +0 -22
  74. package/dist/modules/AI/components/AiChatContent/index.d.ts +0 -3
  75. package/dist/modules/AI/components/AiChatHeader/AiChatHeader.d.ts +0 -6
  76. package/dist/modules/AI/components/AiChatHeader/components/ConversationButton/ConversationButton.d.ts +0 -2
  77. package/dist/modules/AI/components/AiChatHeader/components/ConversationButton/index.d.ts +0 -3
  78. package/dist/modules/AI/components/AiChatHeader/components/HeaderActions/HeaderActions.d.ts +0 -6
  79. package/dist/modules/AI/components/AiChatHeader/components/HeaderActions/index.d.ts +0 -3
  80. package/dist/modules/AI/components/AiChatHeader/helpers.d.ts +0 -1
  81. package/dist/modules/AI/components/AiChatHeader/index.d.ts +0 -3
  82. package/dist/modules/AI/components/AiProviderSettings/AiProviderSettings.d.ts +0 -10
  83. package/dist/modules/AI/components/AiProviderSettings/helpers/constants.d.ts +0 -6
  84. package/dist/modules/AI/components/AiProviderSettings/helpers/groupModels.d.ts +0 -4
  85. package/dist/modules/AI/components/AiProviderSettings/index.d.ts +0 -3
  86. package/dist/modules/AI/components/Chat/Chat.d.ts +0 -6
  87. package/dist/modules/AI/components/Chat/components/LiveEntry/LiveEntry.d.ts +0 -9
  88. package/dist/modules/AI/components/Chat/components/LiveEntry/components/LiveHeader/LiveHeader.d.ts +0 -10
  89. package/dist/modules/AI/components/Chat/components/LiveEntry/components/LiveHeader/index.d.ts +0 -3
  90. package/dist/modules/AI/components/Chat/components/LiveEntry/components/LiveThinking/LiveThinking.d.ts +0 -7
  91. package/dist/modules/AI/components/Chat/components/LiveEntry/components/LiveThinking/index.d.ts +0 -3
  92. package/dist/modules/AI/components/Chat/components/LiveEntry/index.d.ts +0 -3
  93. package/dist/modules/AI/components/Chat/helpers.d.ts +0 -2
  94. package/dist/modules/AI/components/Chat/index.d.ts +0 -3
  95. package/dist/modules/AI/components/ChatInput/ChatInput.d.ts +0 -19
  96. package/dist/modules/AI/components/ChatInput/components/AttachmentThumbnail/AttachmentThumbnail.d.ts +0 -7
  97. package/dist/modules/AI/components/ChatInput/components/AttachmentThumbnail/index.d.ts +0 -3
  98. package/dist/modules/AI/components/ChatInput/components/ButtonAttachments/ButtonAttachments.d.ts +0 -12
  99. package/dist/modules/AI/components/ChatInput/components/ButtonAttachments/index.d.ts +0 -3
  100. package/dist/modules/AI/components/ChatInput/components/ButtonSend/ButtonSend.d.ts +0 -12
  101. package/dist/modules/AI/components/ChatInput/components/ButtonSend/index.d.ts +0 -3
  102. package/dist/modules/AI/components/ChatInput/components/ChatInputControls/ChatInputControls.d.ts +0 -27
  103. package/dist/modules/AI/components/ChatInput/components/ChatInputControls/index.d.ts +0 -3
  104. package/dist/modules/AI/components/ChatInput/components/EffortSelector/EffortSelector.d.ts +0 -8
  105. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortBars/EffortBars.d.ts +0 -7
  106. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortBars/index.d.ts +0 -3
  107. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortDropdown/EffortDropdown.d.ts +0 -7
  108. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortDropdown/EffortDropdownItem.d.ts +0 -9
  109. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortDropdown/index.d.ts +0 -3
  110. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortTrigger/EffortTrigger.d.ts +0 -9
  111. package/dist/modules/AI/components/ChatInput/components/EffortSelector/components/EffortTrigger/index.d.ts +0 -3
  112. package/dist/modules/AI/components/ChatInput/components/EffortSelector/helpers.d.ts +0 -9
  113. package/dist/modules/AI/components/ChatInput/components/EffortSelector/index.d.ts +0 -2
  114. package/dist/modules/AI/components/ChatInput/components/ModelSelector/ModelSelector.d.ts +0 -10
  115. package/dist/modules/AI/components/ChatInput/components/ModelSelector/components/ModelOption/ModelOption.d.ts +0 -9
  116. package/dist/modules/AI/components/ChatInput/components/ModelSelector/components/ModelOption/index.d.ts +0 -2
  117. package/dist/modules/AI/components/ChatInput/components/ModelSelector/helpers.d.ts +0 -3
  118. package/dist/modules/AI/components/ChatInput/components/ModelSelector/index.d.ts +0 -2
  119. package/dist/modules/AI/components/ChatInput/components/QuestionInput/QuestionInput.d.ts +0 -8
  120. package/dist/modules/AI/components/ChatInput/components/QuestionInput/helpers.d.ts +0 -11
  121. package/dist/modules/AI/components/ChatInput/components/QuestionInput/index.d.ts +0 -4
  122. package/dist/modules/AI/components/ChatInput/components/SkillsManager/SkillsManager.d.ts +0 -8
  123. package/dist/modules/AI/components/ChatInput/components/SkillsManager/components/CategoryButton/CategoryButton.d.ts +0 -10
  124. package/dist/modules/AI/components/ChatInput/components/SkillsManager/components/CategoryButton/index.d.ts +0 -2
  125. package/dist/modules/AI/components/ChatInput/components/SkillsManager/components/SkillItem/SkillItem.d.ts +0 -7
  126. package/dist/modules/AI/components/ChatInput/components/SkillsManager/components/SkillItem/index.d.ts +0 -2
  127. package/dist/modules/AI/components/ChatInput/components/SkillsManager/components/SkillsButton/SkillsButton.d.ts +0 -8
  128. package/dist/modules/AI/components/ChatInput/components/SkillsManager/components/SkillsButton/index.d.ts +0 -2
  129. package/dist/modules/AI/components/ChatInput/components/SkillsManager/data.d.ts +0 -3
  130. package/dist/modules/AI/components/ChatInput/components/SkillsManager/helpers.d.ts +0 -7
  131. package/dist/modules/AI/components/ChatInput/components/SkillsManager/index.d.ts +0 -5
  132. package/dist/modules/AI/components/ChatInput/components/UsageBar/Ring.d.ts +0 -12
  133. package/dist/modules/AI/components/ChatInput/components/UsageBar/UsageBar.d.ts +0 -13
  134. package/dist/modules/AI/components/ChatInput/components/UsageBar/helpers.d.ts +0 -7
  135. package/dist/modules/AI/components/ChatInput/components/UsageBar/index.d.ts +0 -3
  136. package/dist/modules/AI/components/ChatInput/hooks/useMessageHistory.d.ts +0 -7
  137. package/dist/modules/AI/components/ChatInput/index.d.ts +0 -3
  138. package/dist/modules/AI/components/ChatMessage/ChatMessage.d.ts +0 -7
  139. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/AIBrandPreview.d.ts +0 -7
  140. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandColors/BrandColorItem.d.ts +0 -8
  141. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandColors/BrandColors.d.ts +0 -7
  142. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandColors/index.d.ts +0 -3
  143. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandConfirmPanel/BrandConfirmPanel.d.ts +0 -14
  144. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandConfirmPanel/index.d.ts +0 -3
  145. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandHeader/BrandHeader.d.ts +0 -11
  146. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandHeader/index.d.ts +0 -3
  147. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandHero/BrandHero.d.ts +0 -9
  148. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandHero/index.d.ts +0 -3
  149. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandPersonality/BrandPersonality.d.ts +0 -6
  150. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandPersonality/index.d.ts +0 -3
  151. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandTypography/BrandTypography.d.ts +0 -8
  152. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandTypography/index.d.ts +0 -3
  153. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandVoice/BrandVoice.d.ts +0 -6
  154. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/components/BrandVoice/index.d.ts +0 -3
  155. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/helpers.d.ts +0 -2
  156. package/dist/modules/AI/components/ChatMessage/components/AIBrandPreview/index.d.ts +0 -1
  157. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/AIColorPalettePreview.d.ts +0 -7
  158. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/components/ColorPaletteRow/ColorPaletteRow.d.ts +0 -9
  159. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/components/ColorPaletteRow/index.d.ts +0 -3
  160. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/components/ColorStripItem/ColorStripItem.d.ts +0 -7
  161. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/components/ColorStripItem/index.d.ts +0 -3
  162. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/helpers.d.ts +0 -5
  163. package/dist/modules/AI/components/ChatMessage/components/AIColorPalettePreview/index.d.ts +0 -1
  164. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/AISnippetPreview.d.ts +0 -12
  165. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/components/AISnippetHeader/AISnippetHeader.d.ts +0 -15
  166. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/components/AISnippetHeader/DisplayModeButton.d.ts +0 -9
  167. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/components/AISnippetHeader/index.d.ts +0 -3
  168. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/components/ConfirmPanel/ConfirmPanel.d.ts +0 -12
  169. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/components/ConfirmPanel/index.d.ts +0 -3
  170. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/helpers.d.ts +0 -5
  171. package/dist/modules/AI/components/ChatMessage/components/AISnippetPreview/index.d.ts +0 -3
  172. package/dist/modules/AI/components/ChatMessage/components/AIStyleGuidePreview/AIStyleGuidePreview.d.ts +0 -7
  173. package/dist/modules/AI/components/ChatMessage/components/AIStyleGuidePreview/components/ColorScaleRow/ColorScaleRow.d.ts +0 -9
  174. package/dist/modules/AI/components/ChatMessage/components/AIStyleGuidePreview/components/ColorScaleRow/ColorShadeButton.d.ts +0 -9
  175. package/dist/modules/AI/components/ChatMessage/components/AIStyleGuidePreview/components/ColorScaleRow/index.d.ts +0 -3
  176. package/dist/modules/AI/components/ChatMessage/components/AIStyleGuidePreview/helpers.d.ts +0 -10
  177. package/dist/modules/AI/components/ChatMessage/components/AIStyleGuidePreview/index.d.ts +0 -1
  178. package/dist/modules/AI/components/ChatMessage/components/AIWireframePreview/AIWireframePreview.d.ts +0 -8
  179. package/dist/modules/AI/components/ChatMessage/components/AIWireframePreview/helpers.d.ts +0 -1
  180. package/dist/modules/AI/components/ChatMessage/components/AIWireframePreview/index.d.ts +0 -1
  181. package/dist/modules/AI/components/ChatMessage/components/ActionButtons/ActionButtons.d.ts +0 -6
  182. package/dist/modules/AI/components/ChatMessage/components/ActionButtons/index.d.ts +0 -3
  183. package/dist/modules/AI/components/ChatMessage/components/AssistantMessage/AssistantMessage.d.ts +0 -15
  184. package/dist/modules/AI/components/ChatMessage/components/AssistantMessage/index.d.ts +0 -3
  185. package/dist/modules/AI/components/ChatMessage/components/ResourceStep/ResourceStep.d.ts +0 -6
  186. package/dist/modules/AI/components/ChatMessage/components/ResourceStep/index.d.ts +0 -1
  187. package/dist/modules/AI/components/ChatMessage/components/SdkElementPreview/SdkElementPreview.d.ts +0 -8
  188. package/dist/modules/AI/components/ChatMessage/components/SdkElementPreview/index.d.ts +0 -3
  189. package/dist/modules/AI/components/ChatMessage/components/ThinkingBlock/ThinkingBlock.d.ts +0 -6
  190. package/dist/modules/AI/components/ChatMessage/components/ThinkingBlock/index.d.ts +0 -3
  191. package/dist/modules/AI/components/ChatMessage/components/UserMessage/UserMessage.d.ts +0 -11
  192. package/dist/modules/AI/components/ChatMessage/components/UserMessage/components/MessageActions/MessageActions.d.ts +0 -6
  193. package/dist/modules/AI/components/ChatMessage/components/UserMessage/components/MessageActions/index.d.ts +0 -2
  194. package/dist/modules/AI/components/ChatMessage/components/UserMessage/index.d.ts +0 -3
  195. package/dist/modules/AI/components/ChatMessage/helpers/extractToolVisual.d.ts +0 -30
  196. package/dist/modules/AI/components/ChatMessage/helpers/groupStepsIntoItems.d.ts +0 -29
  197. package/dist/modules/AI/components/ChatMessage/helpers/toolVisualTypes.d.ts +0 -103
  198. package/dist/modules/AI/components/ChatMessage/helpers/utils.d.ts +0 -1
  199. package/dist/modules/AI/components/ChatMessage/index.d.ts +0 -3
  200. package/dist/modules/AI/components/CopyButton/CopyButton.d.ts +0 -7
  201. package/dist/modules/AI/components/CopyButton/index.d.ts +0 -2
  202. package/dist/modules/AI/components/HistoryPanel/HistoryPanel.d.ts +0 -10
  203. package/dist/modules/AI/components/HistoryPanel/components/ConversationList/ConversationList.d.ts +0 -9
  204. package/dist/modules/AI/components/HistoryPanel/components/ConversationList/components/ConversationItem/ConversationItem.d.ts +0 -11
  205. package/dist/modules/AI/components/HistoryPanel/components/ConversationList/components/ConversationItem/index.d.ts +0 -3
  206. package/dist/modules/AI/components/HistoryPanel/components/ConversationList/index.d.ts +0 -3
  207. package/dist/modules/AI/components/HistoryPanel/components/HistoryFooter/HistoryFooter.d.ts +0 -5
  208. package/dist/modules/AI/components/HistoryPanel/components/HistoryFooter/index.d.ts +0 -3
  209. package/dist/modules/AI/components/HistoryPanel/components/HistorySearch/HistorySearch.d.ts +0 -6
  210. package/dist/modules/AI/components/HistoryPanel/components/HistorySearch/index.d.ts +0 -3
  211. package/dist/modules/AI/components/HistoryPanel/helpers.d.ts +0 -1
  212. package/dist/modules/AI/components/HistoryPanel/index.d.ts +0 -3
  213. package/dist/modules/AI/components/HistoryPanel/types.d.ts +0 -10
  214. package/dist/modules/AI/components/MessageTools/MessageTools.d.ts +0 -7
  215. package/dist/modules/AI/components/MessageTools/components/MessageTool/MessageTool.d.ts +0 -4
  216. package/dist/modules/AI/components/MessageTools/components/MessageTool/humanizeToolName.d.ts +0 -1
  217. package/dist/modules/AI/components/MessageTools/components/MessageTool/index.d.ts +0 -3
  218. package/dist/modules/AI/components/MessageTools/index.d.ts +0 -3
  219. package/dist/modules/AI/components/ModeLabel/ModeLabel.d.ts +0 -6
  220. package/dist/modules/AI/components/ModeLabel/index.d.ts +0 -3
  221. package/dist/modules/AI/components/QuotaCountdown/QuotaCountdown.d.ts +0 -5
  222. package/dist/modules/AI/components/QuotaCountdown/helpers/formatRetryDelay.d.ts +0 -2
  223. package/dist/modules/AI/components/QuotaCountdown/index.d.ts +0 -3
  224. package/dist/modules/AI/components/ToggleMode/ToggleMode.d.ts +0 -8
  225. package/dist/modules/AI/components/ToggleMode/index.d.ts +0 -3
  226. package/dist/modules/AI/components/ToolVisualRenderer/ToolVisualRenderer.d.ts +0 -10
  227. package/dist/modules/AI/components/ToolVisualRenderer/index.d.ts +0 -2
  228. package/dist/modules/AI/components/VoiceVisualizer/VoiceVisualizer.d.ts +0 -18
  229. package/dist/modules/AI/components/VoiceVisualizer/helpers/drawByBlob.d.ts +0 -11
  230. package/dist/modules/AI/components/VoiceVisualizer/helpers/drawByLiveStream.d.ts +0 -20
  231. package/dist/modules/AI/components/VoiceVisualizer/helpers/getBarsData.d.ts +0 -9
  232. package/dist/modules/AI/components/VoiceVisualizer/helpers/index.d.ts +0 -7
  233. package/dist/modules/AI/components/VoiceVisualizer/helpers/initialCanvasSetup.d.ts +0 -9
  234. package/dist/modules/AI/components/VoiceVisualizer/helpers/paintLine.d.ts +0 -9
  235. package/dist/modules/AI/components/VoiceVisualizer/helpers/paintLineFromCenterToRight.d.ts +0 -8
  236. package/dist/modules/AI/components/VoiceVisualizer/index.d.ts +0 -2
  237. package/dist/modules/AI/contexts/AiChatContext.d.ts +0 -37
  238. package/dist/modules/AI/contexts/AiChatProvider.d.ts +0 -9
  239. package/dist/modules/AI/helpers/computeUsageFromMessages.d.ts +0 -3
  240. package/dist/modules/AI/helpers/formatDuration.d.ts +0 -2
  241. package/dist/modules/AI/helpers/getDateGroup.d.ts +0 -2
  242. package/dist/modules/AI/helpers/parseAiStream.d.ts +0 -2
  243. package/dist/modules/AI/helpers/relativeTime.d.ts +0 -2
  244. package/dist/modules/AI/hooks/useAiChat.d.ts +0 -37
  245. package/dist/modules/AI/hooks/useAiErrors.d.ts +0 -11
  246. package/dist/modules/AI/hooks/useAiProviderSettings.d.ts +0 -9
  247. package/dist/modules/AI/hooks/useAiUsage.d.ts +0 -8
  248. package/dist/modules/AI/hooks/useLiveSteps.d.ts +0 -23
  249. package/dist/modules/AI/hooks/useMediaRecorder.d.ts +0 -18
  250. package/dist/modules/AI/hooks/useStreamingText.d.ts +0 -7
  251. package/dist/modules/AI/hooks/useVoice.d.ts +0 -11
  252. package/dist/modules/AI/index.d.ts +0 -1
  253. package/dist/modules/AI/types.d.ts +0 -150
  254. package/dist/modules/Functions/components/FunctionsSidebar/components/NewFile/NewFile.d.ts +0 -7
  255. package/dist/serviceWorker.d.ts +0 -2
  256. /package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/FileItem/index.d.ts +0 -0
  257. /package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/FolderItem/FolderItem.d.ts +0 -0
  258. /package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/FolderItem/index.d.ts +0 -0
  259. /package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/NewFile/index.d.ts +0 -0
  260. /package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/SidebarSection/SidebarSection.d.ts +0 -0
  261. /package/dist/modules/{Functions/components/FunctionsSidebar → FileTree}/components/SidebarSection/index.d.ts +0 -0
package/CHANGELOG.md CHANGED
@@ -1,5 +1,377 @@
1
1
  # @plitzi/plitzi-builder
2
2
 
3
+ ## 0.38.6
4
+
5
+ ### Patch Changes
6
+
7
+ - 3bce653: ## Fixes
8
+
9
+ - **The dev tools draw their icons again.** The panel lives in a shadow root of its own, which the page's stylesheets
10
+ never reach, and Font Awesome moved to a sheet of its own in 0.38.5 (`plitzi-sdk-icons.css`): the badge and every tab
11
+ lost their icons. The panel now links that sheet inside its root, beside its own. Where it is served is the SDK's
12
+ new `sdkIconsStylePath` — the page server sends `/sdk-assets/plitzi-sdk-icons.css`, the same sheet the document
13
+ links — which the `iframe` and `shadow` render modes read too: they had `/plitzi-sdk-icons.css` hard-coded, a path a
14
+ page server does not serve.
15
+
16
+ - Updated dependencies [3bce653]
17
+ - @plitzi/sdk-auth@0.38.6
18
+ - @plitzi/sdk-authoring@0.38.6
19
+ - @plitzi/sdk-dev-tools@0.38.6
20
+ - @plitzi/sdk-elements@0.38.6
21
+ - @plitzi/sdk-event-bridge@0.38.6
22
+ - @plitzi/sdk-interactions@0.38.6
23
+ - @plitzi/sdk-navigation@0.38.6
24
+ - @plitzi/sdk-plugins@0.38.6
25
+ - @plitzi/sdk-schema@0.38.6
26
+ - @plitzi/sdk-shared@0.38.6
27
+ - @plitzi/sdk-style@0.38.6
28
+ - @plitzi/sdk-variables@0.38.6
29
+ - @plitzi/plitzi-sdk@0.38.6
30
+
31
+ ## 0.38.5
32
+
33
+ ### Patch Changes
34
+
35
+ - 3bce653: ## Agents work through the MCP: the builder's AI chat is gone
36
+
37
+ An agent reaches a space through the MCP, from whatever harness the person already uses; Plitzi no longer runs one of
38
+ its own inside the builder. **Breaking** for whoever imported what that chat was built on:
39
+
40
+ - **The builder's Assistant panel is removed**, with its conversations, attachments, previews and provider settings.
41
+ - **`@plitzi/sdk-mcp` no longer exports the in-process AI engine**: `AIEngine`, `toolResponseOk`, `toolResponseErr`,
42
+ `zodToJsonSchema`, `getAllowedModes`, `bindTools`, `isToolActive`, `resolveToolHandler`, `isCallToolResult`,
43
+ `toolResponseFromResult` and `buildAgentGuide`. The MCP server, its tools and `@plitzi/sdk-mcp/server` are unchanged;
44
+ the tool functions are still exported to run in-process.
45
+ - **`@plitzi/sdk-shared` drops the chat's types** — `AITypes` (`AiContext`, `AiMode`, `AiMessageAttachment`,
46
+ `AiUsage`, …) and `McpTypes` (`McpTool`, `McpToolHandler`, `McpContent`, …), with their `./types/AITypes` and
47
+ `./types/McpTypes/index` subpaths — and no longer depends on `@modelcontextprotocol/sdk`.
48
+ - **A change's `origin` is never `coworker`**: `ChangeOrigin` is `builder`, `mcp`, `autofix`, `api` or `system`, and
49
+ the History panel's filter follows.
50
+ - **The builder's platform flags are gone**: `PlatformFlags` is no longer part of the builder's first query, nor
51
+ `platformFlags` of its store — `assistanceAI` was the only one.
52
+ - **Plitzi's own deployment no longer offers the `ai.complete` task** to flows.
53
+ - **Each MCP tool says whether it only reads** (`readOnlyHint`, from the tool's `access`), so a host can run a read
54
+ without asking and ask before a write. Until now `access` was read only by the builder's chat.
55
+ - **The MCP works over the JSON adapters.** `createJsonAdapters` offers `getSchema` and `getStyle`, and — for a space
56
+ read from a path — `saveSchema` and `saveStyle`, each writing its document back into the file. **Breaking**:
57
+ `saveOfflineData` is gone from `SSRAdapters`; nothing called it, and it was the JSON adapters' only write, so an MCP
58
+ over them could neither read nor save.
59
+
60
+ ## Lighter pages: icons on their own
61
+ - **Font Awesome is a stylesheet of its own**, `plitzi-sdk-icons.css`, with its fonts as files beside it
62
+ (`webfonts/`) instead of base64 inside `plitzi-sdk.css` — which drops from 287 KB to 103 KB. A page fetches a face
63
+ only when it shows an icon of that style, and a new SDK version no longer downloads the fonts again. The page server
64
+ links it after `plitzi-sdk.css` (`SSRTemplateProps.iconsCssPath`), the SDK's iframe and shadow modes load it beside
65
+ the stylesheet, and the package exports it: **a project that imports `@plitzi/plitzi-sdk/plitzi-sdk.css` imports
66
+ `@plitzi/plitzi-sdk/plitzi-sdk-icons.css` too** — `plitzi upgrade` adds it to `src/main.ts`, and a new project has
67
+ it. The MCP's rendered widgets inline the sheet, fonts and all, only for a widget that draws an icon.
68
+ - **Material Icons is no longer loaded.** Nothing in Plitzi used it; every page paid a request to Google for it.
69
+ - **A page loads only the plugins it draws.** The page server sends the rest as their declaration
70
+ (`PluginEntry.deferred`, `pluginDeclarationOf` in `@plitzi/sdk-shared/plugins/declaration`); the SDK registers each
71
+ as a stand-in that knows its types from the start, and loads its code and stylesheet the first time one of its
72
+ elements is drawn — on a page reached by navigating too, with no server involved. What a page draws is
73
+ `pageElementTypes` (`@plitzi/sdk-shared/schema/pageElements`): the page, its layouts, the components and references
74
+ it holds. `render()` takes a plugin as `{ load, css, declaration }` beside `{ component }`.
75
+ - **The space travels beside the page, not inside it.** The page names it (`<link id="plitzi-space">`,
76
+ `SSRTemplateProps.spaceDocumentPath`), the browser fetches it while the scripts load, and the page server answers
77
+ `/_plitzi/space/<hash>.json` behind the same gates as its pages — `immutable`, since the name is its content's hash:
78
+ one download for every page and every visit until the space changes. The website's docs page went from 2.6 MB to
79
+ 0.5 MB. Still the whole space, so every navigation after the first page stays in the browser. A draft preview and a
80
+ deployment's own `templateFn` keep it inline.
81
+ - **An arrival on screen plays as the page arrives.** A `motion: { on: 'view' }` element already in view was held
82
+ invisible until the SDK hydrated — the page's content, and a page rendered `ssrOnly` forever. The page server's
83
+ document now sees it as soon as it is parsed, and hands over to the SDK once the page is live.
84
+
85
+ ## Server data: one request per question, the newest winning, and a way to stop
86
+ - **A link asks for its page's server data once.** The navigation's prefetch already brought it; the route change that
87
+ followed asked again — two renders per click. `useRscSync` now asks only for a location the store does not hold.
88
+ - **Answers land in the order they were asked.** `refreshRsc` joins a refresh already in flight for the same URL and
89
+ aborts one a newer refresh would overwrite (a whole payload asked again, an element asked again); a whole payload
90
+ keeps what an element asked for after it. A slow answer no longer paints a page the visitor has left.
91
+ - **Stopping.** `cancelRsc(store, ids)`, an `apiContainer`'s `cancelQuery` callback (`cancelApi(id)` in authoring) and
92
+ `queryCache.cancel(key)` for a browser provider: the request is dropped and what is shown stays. The server hears it:
93
+ `SSRRscContext.signal` aborts when the browser hangs up, and the default `getRscData` stops every element still
94
+ resolving — a shared render run only once nobody is waiting on it.
95
+ - **Pending.** A server provider's `isLoading` is true while it is asked again (`rsc.refreshing`). The `navigation`
96
+ source says `pending` and `pendingLocation` while a link waits for its destination's data; a second link clicked
97
+ before the first went supersedes it, and the first never goes.
98
+ - **A bound `input` asks again.** An `apiContainer`'s `input` is a prop now: bound to state, every change refetches a
99
+ server provider. What a refresh asks for (`req.ctx.rscParams`) wins over the `input` the element was saved with.
100
+ - **A section cut by its budget says how to give it more** (`rsc.elementTimeoutMs`).
101
+
102
+ ## Flows
103
+ - **`whileRunning('latest')`**: a new firing stops the run in progress — no further step; its `runServerAction` is
104
+ cancelled (request and server run) and its `webHook` aborted — and runs. A search as you type. The step's context
105
+ carries the `signal`. Offered in the builder and the MCP.
106
+ - `onApiSuccess` / `onApiError` fire once per answer: a cancelled request or a loading flag that came and went no
107
+ longer runs the flow again.
108
+ - **A debounce is `whileRunning('latest')` and a `delay` first**: `delayTime` ends its wait the moment its run is
109
+ superseded, so only the last firing gets past it. Its `time` is a number.
110
+
111
+ ## Server actions
112
+ - **The request budget is never silent.** A task that caught the refused fetch hid `maxRequests`; the step that ran
113
+ into it now logs it, and the server logs it once, naming `createServer({ action: { limits: { maxRequests } } })`.
114
+ - **`invalid_input` says what the value was and which type takes it** — `windows (text, got a list; declare the field
115
+ \`json\` to take it)`. The templates reference documents that a param that is only `|json_encode` is the value it
116
+ encodes.
117
+ - **`kv` survives a restart with no database.** `createFileKv({ file })` (`@plitzi/sdk-server/actions`) keeps the
118
+ in-process store in one JSON file, written whole as soon as anything changes — for one process.
119
+ `createSqliteKv({ file } | { db })` (`@plitzi/sdk-server/sqlite`, new entry) is a table in a SQLite file over
120
+ `node:sqlite`, every operation one statement, shared safely by every process on the file. Both pass the adapter
121
+ contract every store is held to. The `09-schedules` example uses it rather than its own copy, whose counters read
122
+ `22.0`.
123
+
124
+ ## Authoring
125
+ - **What a space declares and never uses** is suggested now: `unused-class`, `unused-token`, `unused-component`, and
126
+ `literal-colour` — a class painted from the palette typing out a scheme token's light value. A suggestion about
127
+ declarations names them in `subjects`, so the MCP says one a batch left unused beside the ones the space had.
128
+ `unusedDeclarations(schema, style)` is the rule itself, for anything else that says "unused" (the builder does).
129
+ - **`pageFamily(shape, entries)`** writes pages of one shape from data: each page its id, slug, titles, folder and
130
+ layout, and its body built inside `scope(entry.id, …)` so two pages never give one id.
131
+ - **`action-output-path`** (warned): `.data` read on a provider fed by a server action, which publishes its output at
132
+ the root. **`actionSource(id, sample)`** types such a provider by a sample of its output.
133
+ - A value template (`returns: 'value'`, a computed, a step param) may name its parts with `{% set %}` before its one
134
+ expression, and is still that expression's value.
135
+ - `abs()`, `floor()`, `ceil()`, `clamp()` are refused with how they are written here (`x|abs`,
136
+ `x|round(0, 'floor')`, `min(max(x, low), high)`).
137
+ - An unknown attribute is reported against the element's props, not as "'id' does not exist in type ElementSpec[]".
138
+ - `explain` answers a builder's name (`reloadApi`, `cancelApi`) with its step, and knows `whileRunning`.
139
+ - A component's instance takes `quiet`, like any element — `component(id, { quiet: ['repeated-shape'] })`: instances
140
+ whose slots are filled alike on purpose stop being offered as a repeat, and an exported instance that carries one
141
+ typechecks.
142
+ - `container` and `text` take a `title`. A trigger's `preview` may hold numbers, flags, lists and `null`.
143
+ - **A Markdown element's headings are sections a link can name.** Each renders with the anchor its words read as
144
+ (`## Server data` → `#server-data`, numbered when repeated), and a link's `hash` may name one: `anchor-missing` counts
145
+ them, so a table of contents built from the Markdown is checked like any other link.
146
+ - `answerAction(page, actionId, output)` (testing): a test that would save something answers that server action in
147
+ the browser — the server's `kv`, and what the developer kept, are never written. A stream step gets its `done` frame.
148
+
149
+ ## Plugins
150
+ - **A plugin's stylesheet sits below the space's.** The cascade order is now `… utilities, plitzi-sdk-plugin,
151
+ plitzi-sdk-runtime`, and whatever builds a plugin writes its CSS into `plitzi-sdk-plugin` (`inPluginLayer` from
152
+ `@plitzi/sdk-shared/style`): `plitzi pack plugin`, a server compiling one (`action: 'compile'`), and the stylesheet a
153
+ server copies or downloads for one. A space's classes and `customCss` now win over what the plugin's author shipped,
154
+ whatever the specificity — as they do over a built-in element. A plugin packed before this ships unlayered and still
155
+ wins until it is packed again.
156
+ - **Declared param types reach the callback.** A param declared `number` (new, a text box in the builder) or `boolean`
157
+ is handed over as one — written `5000`, or bound to text that says it; an empty number as nothing, so the component's
158
+ default applies.
159
+ - **`useElementVisible(id)`** (`@plitzi/plitzi-sdk`): whether another element is on the page — its own `visible`, every
160
+ container around it, the breakpoint — kept current while the plugin is mounted, at that plugin's cost alone.
161
+ - **A page open on a development server loads again when the server restarts** (`devReload`): `start:dev` restarting
162
+ on a change to the server's code reached the open page only when somebody reloaded it.
163
+ - **A saved plugin is swapped into the open page** (`devReload`, server mode): the page server rebuilds the plugin
164
+ whose source changed and the page renders the new component in place, keeping its state — no restart, no reload. A
165
+ change to its declaration (what the builder and the linter know of it) still reloads the page. `render()` takes
166
+ `{ hotPlugins: true }` and answers `{ unmount, replacePlugin }`; `PluginManager.rebuild(name)` and `onSources`. A new
167
+ folder in `src/plugins` is registered without a restart (`server.plugins.register`), from `create` and `create --from` alike.
168
+ - **A plugin brings its own server half.** `functions/index.ts` beside the component — the `defineFunctions` a
169
+ space's functions use — answers routes under `/fn/plugins/<type>/` and runs steps named `<type>.<action>` (origin
170
+ `'plugin'`, the builder's **Plugins** group). It runs with a narrower `ctx`: its own `kv` (prefixed
171
+ `plugin:<type>:`, its `rateLimit` and `sign` too), none of the space's credentials, no realtime publishing or grants;
172
+ its routes and tasks outside its namespace are refused, as are a space's routes under `/fn/plugins/`. The component
173
+ reaches its routes with `usePluginRoute(type)` (`@plitzi/plitzi-sdk`; `undefined` where no server runs code).
174
+ A page server takes them as `functions.plugins` (`{ [type]: FunctionsDefinition }`), swaps one with
175
+ `server.functions.setPlugin`, and asks a cloud adapter with `actionLookups.getPluginFunctions(spaceId, version)`.
176
+ `plitzi pack plugin` carries the source in the zip as `functions.source.json` (`PLUGIN_FUNCTIONS_SOURCE`, named by
177
+ the manifest's `functions`; `loadFunctionsSource` builds it) — kept privately by the platform, never published.
178
+ - **A plugin lays out the space's elements it holds.** `elementChildren(children)` (`@plitzi/plitzi-sdk`) hands
179
+ over each child element with the id it was authored under, for a dock, tabs or a masonry to place in boxes of its
180
+ own — instead of writing styles onto elements it does not render.
181
+ - **`useDisplayMode()`** (`@plitzi/plitzi-sdk`): `desktop`, `tablet` or `mobile`, at the widths the space's styles are
182
+ compiled at — not a breakpoint of the plugin's own.
183
+ - **A file a library needs whole travels inside the bundle**, imported as Vite imports it: `worker.js?raw` (its text — a
184
+ worker from a Blob), `engine.wasm?inline` (a base64 data URI). `plitzi pack` and a server compiling a plugin share
185
+ one build (`@plitzi/sdk-shared/plugins/bundle`), so a server now inlines `.avif`, `.ttf` and `.otf` as `pack` did.
186
+
187
+ ## CLI and page checks
188
+ - **`plitzi lint`** reads a local space's source the way eslint reads code, for what the document cannot show:
189
+ `file-too-long`, `pages-in-one-file`, `inline-records` (rows of data written in code → `src/data/`), `repeated-css`,
190
+ `special-case-in-map`, `colour-not-token`, `positional-id`, `unused-file` — each at file:line with what to write
191
+ instead — and authoring's suggestions at the line that wrote them. `--json`, `--strict`, `--max-warnings <n>`;
192
+ `// plitzi-lint-disable-next-line <code> -- why` for a departure on purpose. Projects get `npm run lint:space`
193
+ (`upgrade` adds it to older ones). `doctor` stays the project's and never reads the space.
194
+ - **`--template blank`** starts with only the colours its page uses: a token declared and read by nothing is one
195
+ authoring now points out.
196
+ - **The welcome space is written as a folder**, not one 800-line file: `src/space/index.ts` (the page), `tokens.ts`,
197
+ `theme.ts`, `content.ts` — the shape a space keeps as it grows, and clean under `plitzi lint`. **Breaking** for
198
+ whoever called it: `blankSpaceSource()` is now `blankTemplateFiles({ name, dir, plugin })`, which returns the files by
199
+ path; `toPortableSource` keeps imports of the files beside it. A plugin package's preview space is
200
+ `preview/space/index.ts`.
201
+ - **`check`, `shot` and the generated visual tests settle instead of waiting for `networkidle`**, which never came on a
202
+ page with a realtime channel: `openPage` (`@plitzi/sdk-authoring`) waits for load, then quiet, counting no stream
203
+ that stays open.
204
+ - **The server is the project's in `src/config/serverOptions.ts`; `src/main.ts` stays the CLI's.** `create` writes
205
+ `src/config/serverOptions.ts` (handed to `createServer`, typed from `ServerConfig`, now exported by
206
+ `@plitzi/sdk-server`) and, with `--source local`, `src/actions/index.ts` (the space’s server actions), which `main.ts` wires
207
+ for calls, renders and schedules. What `main.ts` wires itself (the space's adapters, the plugins, `public/`,
208
+ `src/data/`, `src/functions/`, the actions' lookups) is left out of `serverOptions`' type and comes after it, so no option unwires it.
209
+ `upgrade` writes either file into a project that has none — only when the `main.ts` reading it is the CLI's — and
210
+ never replaces it; `create --from` projects read `serverOptions.ts` too.
211
+ - **`upgrade packages` brings up the scripts the CLI wrote and nobody changed** (`.plitzi/scaffold.json` now records
212
+ them); a script the project changed is left and said, as before.
213
+ - `start:dev` restarts on a change to the server's code — `src/main.ts`, `src/config/`, `src/actions/` and
214
+ `src/functions/` (there from the start, kept by a `.gitkeep`); a plugin is swapped in the open page instead, and its
215
+ `functions/` set again, without a restart. A function imports its siblings with `.ts`, as `src/`.
216
+ - `add plugin --server` writes the plugin's server half (`functions/index.ts`, a `GET`/`POST /state` example on its
217
+ `kv`); a package gets `@plitzi/sdk-server` as a devDependency for its types. Refused in a client-mode project.
218
+ - `add plugin`: `--prop rows:list` and `--prop meta:json` for data a binding fills; `--headless` writes
219
+ `drawsNothing: true`; the generated events hook never fires on the builder's canvas.
220
+ - A `channel` with no tag is boxless to a page check, like a provider; an empty list is said to have no rows, with what
221
+ to do, instead of "no size (0×0)".
222
+ - **A server-mode project keeps its `kv` in `state/kv.json`** (`createFileKv`; ignored by git): what the space's actions
223
+ save outlives a restart, `start:dev`'s included. `action.kv` in `src/config/serverOptions.ts` names another store.
224
+ - A server-mode project types what its plugins import besides code (`plitzi/assets.d.ts`): a stylesheet, an image,
225
+ `?raw`, `?inline` — a client-mode one has them from `vite/client`.
226
+ - **A project made from a space runs the server `create` writes.** It has the same `src/main.ts` as any project: it
227
+ now takes a free port and writes `tmp/dev-server.json` (which `check`, `shot` and the visual tests read), answers
228
+ `/health`, and re-authors its pages on save instead of waiting for a restart. Its actions are `src/actions/` and its
229
+ connectors `src/connectors/`, both there from the start, and `start:dev` restarts on them; `src/actions/index.ts`
230
+ exports `actions` and `connectors`, as a `create` project's does (`push` reads that). Before, `upgrade` showed its
231
+ `main.ts` as the project's own, and `--take all` would have put `create`'s server in place of the space's.
232
+ - **A `--source cloud` server project starts.** Its key is in `.env`, which nothing read: `npm start` stopped on "Set
233
+ PLITZI_HOST_KEY". Every server project's `src/main.ts` now reads `.env` itself (`process.loadEnvFile`), and every
234
+ one is given a signing key there (`PLITZI_SIGNING_SECRET`, made for it by `create`) — `ctx.sign` refused in a project
235
+ `create` wrote, a plugin's server half included. `PORT` is no longer written into `.env`, where it pinned 8080. A
236
+ cloud project keeps its `kv` in `state/kv.json` too.
237
+ - **`upgrade` keeps the package manager a project was written for** (`.plitzi/scaffold.json`) when it has no lockfile
238
+ of its own yet: a yarn or pnpm project not installed (`--no-install`), or sitting in a monorepo folder, was taken for
239
+ npm and its `AGENTS.md`, Playwright config and `.gitignore` replaced with npm's commands.
240
+ - `author`, `check`, `fix` and `push` know the element types of a project's built-only plugins
241
+ (`vendor/plugins/*/plugin-manifest.json`, every element each provides), as its server does.
242
+ - **`import` reaches Plitzi only when told to.** A site not served from this machine needs `--account` — ask the
243
+ person's Plitzi account whether one of their spaces verified its domain, signing in — and without it is refused,
244
+ saying so, before any request: an agent running `import` in a local project opened a sign-in nobody asked for. The
245
+ CLI skill and the generated `AGENTS.md` say to run `import` only when the user asks, and to ask before `--account`.
246
+ - **A server project's data is no longer on the internet.** It was `public/data/*.json`, served to anyone as a file;
247
+ it is `src/data/*.json`, which the server reads and never serves (`dataDir`, new in `createServer`): a provider with
248
+ `runtime: 'server'` and `query: '/data/<file>'` reads it, and the page arrives with it. `projectData`
249
+ (`@plitzi/sdk-authoring/node`) and `authorSpace`'s `serverData` hold bindings to those files, and a provider asking
250
+ for `/data/…` from the browser is refused (`server-data-in-browser`): nothing would answer it. What a provider reads
251
+ is still in the page it renders — data a page must not carry is a server action's to read. A client-mode project
252
+ keeps `public/data/`, which the browser has to fetch. The catalog template follows the mode
253
+ (`catalogTemplateFiles({ mode })`). `public/` holds only what is meant for everyone.
254
+ - **The project's own server code is `src/functions/`**, with the rest of its source — typechecked with it, left out of
255
+ `tsconfig.build.json` (the server builds it at boot). `functions pull`/`push`/`dev`, `push`, `pull` and `create
256
+ --from` follow. The `kv` folder is `state/` (it was `data/`, beside a data folder that was something else).
257
+ - **What is the CLI's is in `plitzi/`, apart from `src/`.** `plitzi/author.ts`, `plitzi/assets.d.ts` (server mode) or
258
+ `plitzi/preflight.css` (client mode), and `plitzi/README.md` — which says what each folder of `src/` is, instead of a
259
+ README in every one. `src/main.ts` stays where an entry point is looked for, the CLI's all the same.
260
+ `src/plugins/declarations.ts` is gone: a plugin is declared by its folder's `declaration.ts`, found by the server,
261
+ `author`, `check`, `fix`, `push` and the visual test alike (`pluginDeclarations` from `@plitzi/sdk-authoring/node`;
262
+ Vite's `import.meta.glob` in client mode).
263
+ - `functions.plugins` is in `SSRServerConfig`'s type and checked as the server starts: a project passing its plugins'
264
+ server halves did not typecheck.
265
+ - **A project's source is folders that grow.** The space is `src/space/` — its `index.ts` exports it as `space` and
266
+ assembles the rest (the catalog template's `src/site/` is `src/space/` now; `create --from` writes the space's own
267
+ `index.ts` there, exported as `space` too). The server actions are `src/actions/` — `index.ts` lists them, one action
268
+ a file, as `create --from` already had them — and what the server does besides serving the space is
269
+ `src/config/serverOptions.ts`. `start:dev` watches `src/config` and `src/actions` whole.
270
+ - **One server for every project, kept by `upgrade`.** `src/main.ts` runs what a project holds from where it lands — a
271
+ runtime in `src/runtime/` (or built only, `vendor/runtime.bundle`), plugins built only (`vendor/plugins/`), the
272
+ actions' connectors — so `create --from` writes no `main.ts` or `.prettierignore` of its own any more, and `upgrade`
273
+ keeps both current in projects made from a space too. `loadRuntimeModule` (`@plitzi/sdk-server/runtime`): a project's
274
+ runtime module, or nothing when it has none.
275
+ - **`plitzi add runtime`** writes `src/runtime/index.ts` — run by the project's server (`npm start` answers its
276
+ endpoints) and sent by `plitzi runtime push`, whose default entry it is now — and has `start:dev` restart on it. A
277
+ space taken out with a runtime gets `src/runtime/index.ts` handing over the module its source starts at.
278
+ - **`push` sends the space's files back as their CDN addresses.** `create --from` and `pull` write each CDN address as
279
+ the project's path (`/assets/a.png`, served from `public/assets/`); `push` sent those paths as they were, and the
280
+ space's pictures and data pointed at nothing on Plitzi. It also says, before sending, what Plitzi would not have: a
281
+ provider reading a file `src/data/` does not hold, and a file the space names that is not on its CDN.
282
+ - **`push` sends a project's data and its files.** Two new parts: `data` — `src/data/` whole, kept by Plitzi as the
283
+ space's own data (private, frozen with each publish, read by the page server of the version it renders; refused when
284
+ the space's copy changed since the project last had it, unless `--force`) — and `files` — each changed file of
285
+ `public/assets/`, put at the same path under the space's `assets/` on its CDN, so a pull brings it back where it was.
286
+ `create --from` and `pull` write the space's data into `src/data/`. `getData` joins the action lookups
287
+ (`ActionLookupsConfig`), and the page server resolves `/data/<file>` through it when there is no `dataDir`.
288
+ - **A space's data is edited in the builder and by agents.** The builder's Server view has a **Data** tab: the JSON
289
+ files the space's server providers read (`/data/<file>`), a file list and a JSON editor, saved whole against the
290
+ copy it read (⌘S; a newer copy is refused, a broken file named). The MCP reads it as `plitzi://data/{env}` and writes
291
+ it with `upsertDataFile` / `deleteDataFile` (`getData` / `saveData` among the adapters; a file that is not JSON is
292
+ refused as it is written), and the guide has a Data section. One write path for the builder, agents and `plitzi push`
293
+ (`SpaceData` / `SpaceSaveData` over GraphQL, under `spaceManage`), one history. `DataDraft` / `DataSaveResult` are
294
+ in `@plitzi/sdk-shared`. The builder's file list is shared by Functions and Data (`modules/FileTree`).
295
+ - **`plitzi doctor`**: whether the project the CLI set up is whole, checked against what it is now — a developer may
296
+ change any file. Packages (declared, installed at versions that agree, one copy of the SDK and of React), the CLI's
297
+ files and scripts (as `upgrade` sees them, one planner for both), the file each Node script starts and every folder
298
+ `start:dev` watches, the TypeScript configs, `.gitignore` and `.env` (never in git; the signing secret as long as the
299
+ project's server wants it), the code Node runs as written (relative imports with their extension, JSON with its
300
+ attribute, no JSX, every package declared — walked with esbuild), each plugin folder against its declaration, the data
301
+ files, `src/functions/` built by the project's own sdk-server, `.plitzi/` and the skills. Each finding has an area, a
302
+ code, the file and its fix; `--json`, `--strict`; exit 1 on an error. It never checks the space — `npm run author`
303
+ and `check` do — and every report says so. A layout an older CLI left (`src/space.ts`, `src/author.ts`,
304
+ `functions/` at the root…) is its own area, checked first and alone. `--fix` repairs what is simple and safe —
305
+ that layout moved with every import, URL and script following (and the scaffold record with it), dead files,
306
+ `.gitignore`, `"type": "module"`, a watched folder, a signing secret — then checks again; `--dry-run` says what.
307
+ Each report ends with what to run next. `upgrade` writes no file over an older layout, and says `doctor --fix`.
308
+ `buildFunctions` and `FunctionsBuildError` are exported from
309
+ `@plitzi/sdk-server/functions-runner`, `MIN_SIGNING_SECRET_LENGTH` from `@plitzi/sdk-server/actions`.
310
+ - **`--dry-run`** on every command that writes or sends — `create`, `add plugin`, `add runtime`, `pull`, `push`,
311
+ `pack plugin`, `source`, `import`, `upload plugin`, `functions pull`/`push`, `runtime push`/`start`/`stop`/`size`/
312
+ `vars`, `skills update`, `doctor --fix`: each file it would write (`+` new, `~` replaced, `-` removed), what it would install or run, what it would
313
+ send and where, and none of it done. It still reads what it needs to say so.
314
+ - **A new project is formatted from the start**, every template and mode: its first `format` changes nothing. The CLI's
315
+ own files are in its `.prettierignore`, so formatting never turns one into a file `upgrade` believes was changed.
316
+
317
+ ## Builder
318
+ - **The pages panel keeps its folders as you left them** — open or closed, per space, across reloads — the way the
319
+ style inspector keeps its sections. A folder starts closed.
320
+ - **Usages**, a panel beside Layers: where each component, class, token, space variable and data source is used,
321
+ page by page — what reads it and which elements — and which nothing uses, by authoring's own rule. A click selects
322
+ the element, inside a component too.
323
+ - **Revealing an element inside a component opens the component** (the Usages panel, ⌘P, the issues and the history all
324
+ reveal through it); before, the selection was dropped. **Panels stay open** when a component opens or closes.
325
+ - **The canvas dims a page's layout around its body again when the layout or its slot draws no box**
326
+ (`display: contents`, which the efficiency guide recommends): the hole was measured as a rect of zeros and the whole
327
+ page was dimmed. A box-less element is measured by what it holds, and the mask by the box that positions it.
328
+ - **Elements is one category at a time.** A row of chips — each category with its count, and the space's components as
329
+ one more — picks what the panel shows, remembered between sessions, so the panel stays the same height however many
330
+ elements plugins add. A search looks through every category and the components at once. Each element is a tile: its
331
+ icon, its whole name, and what it is on hover. Container, Button, Form, Form Control, Dropdown Popup, List Item, Rich
332
+ Text, Dialog Container and Tab Container Item have icons of their own (`sdk-elements`), none shared with another
333
+ element or with the component and snippet icons.
334
+ - **Layers reads as a tree and is driven from the keyboard.** A guide per depth, a chevron that turns, the component's
335
+ name beside an element that is one, and the selected row kept in view. ↑/↓, Home/End, → to open or go in, ← to close
336
+ or go up. A row under a closed ancestor is no longer shown. (plitzi-ui's `Tree`.)
337
+ - **Motion and preview no longer share an icon.** Playing the page's motion is a wand, which pulses while it plays;
338
+ preview is an eye, and a pen to go back to editing.
339
+ - **A component's settings fit their modal, however many props it has.** The modal is wider; the name and folder
340
+ share a line, and each prop is one compact row — its name, its kind, required, remove — with what a binding writes to
341
+ read it (`{{ props.<name> }}`) or what is wrong with it, and what it is for, beneath. The fields scroll and the buttons
342
+ stay in view. Props and slots are titled sections, and a slot shows its id.
343
+
344
+ ## Packages
345
+ - **`GET /auth/continue` takes `?fallback=`**: where to go when `redirect` is refused, vetted by the same check. A sign-in
346
+ screen's way back sends its site there, so leaving without signing in never lands on "you are signed in".
347
+ - **Markdown renders headings you can link to and code you can copy.** A heading carries its anchor and a `#` link to
348
+ itself; a fenced block a header with its language and a **Copy** button. The anchor is `@plitzi/sdk-shared`'s:
349
+ `anchorOf`, `uniqueAnchor` and `markdownHeadings` (`schema/anchor`, `schema/markdownHeadings`) — what the element
350
+ renders, what authoring checks a link against and what a table of contents is built from are one function. Needs
351
+ `@plitzi/plitzi-ui` 1.6.31 (its `Markdown` takes `headingAnchor`).
352
+ - **Every package declares what it imports, and nothing more.** `react` is a peer of `sdk-auth`, `sdk-event-bridge`,
353
+ `sdk-interactions`, `sdk-style` and `sdk-variables`; `sdk-schema` depends on `immer`, `sdk-elements` on
354
+ `@dr.pogodin/react-helmet`, `sdk-plugins` on `@plitzi/plitzi-ui`, `sdk-style` on `@plitzi/sdk-event-bridge` and
355
+ `sdk-dev-tools` on `@plitzi/sdk-plugins` — each worked only because `@plitzi/plitzi-sdk` brought them, and failed
356
+ installed alone or under a strict linker. `prop-types` and the `@plitzi/*` dependencies nothing imported are gone:
357
+ `sdk-mcp` no longer declares `@plitzi/sdk-elements`, which its code does not import — it still arrives through
358
+ `@plitzi/plitzi-sdk`.
359
+
360
+ - Updated dependencies [3bce653]
361
+ - @plitzi/sdk-auth@0.38.5
362
+ - @plitzi/sdk-authoring@0.38.5
363
+ - @plitzi/sdk-dev-tools@0.38.5
364
+ - @plitzi/sdk-elements@0.38.5
365
+ - @plitzi/sdk-event-bridge@0.38.5
366
+ - @plitzi/sdk-interactions@0.38.5
367
+ - @plitzi/sdk-navigation@0.38.5
368
+ - @plitzi/sdk-plugins@0.38.5
369
+ - @plitzi/sdk-schema@0.38.5
370
+ - @plitzi/sdk-shared@0.38.5
371
+ - @plitzi/sdk-style@0.38.5
372
+ - @plitzi/sdk-variables@0.38.5
373
+ - @plitzi/plitzi-sdk@0.38.5
374
+
3
375
  ## 0.38.4
4
376
 
5
377
  ### Patch Changes
package/dist/index.html CHANGED
@@ -28,19 +28,6 @@
28
28
  }
29
29
  }
30
30
  </script>
31
- <link
32
- rel="preload"
33
- href="https://fonts.googleapis.com/icon?family=Material+Icons"
34
- as="style"
35
- onload="
36
- this.onload = null;
37
- this.rel = 'stylesheet';
38
- "
39
- />
40
- <noscript>
41
- <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet" />
42
- </noscript>
43
-
44
31
  <link href="https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700&family=Geist+Mono:wght@400;500&display=swap" rel="stylesheet" />
45
32
 
46
33
  <link href="/plitzi-builder.css" rel="preload" as="style" />
@@ -58,10 +45,10 @@
58
45
  render(
59
46
  'plitzi',
60
47
  {
61
- webKey: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxOCIsIm9yaWdpbnMiOlsiaHR0cHM6Ly90cmVtb3IucGxpdHppLmFwcCIsImh0dHBzOi8vdHJlbW9yLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vcGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsOjMwMDAiLCJodHRwczovL2FwcC5wbGl0emkubG9jYWw6MzAwMSIsImh0dHBzOi8vc3NyLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vc2VydmVyLnBsaXR6aS5sb2NhbCIsImh0dHA6Ly9sb2NhbGhvc3Q6MzAwMCIsImh0dHA6Ly9sb2NhbGhvc3Q6ODA4MCIsImh0dHA6Ly8xMjcuMC4wLjE6ODA4MCJdLCJpc3MiOiJodHRwczovL3NlcnZlci5wbGl0emkubG9jYWwiLCJhdWQiOlsiaHR0cHM6Ly9wbGl0emkubG9jYWwiLCJodHRwczovL2FwcC5wbGl0emkubG9jYWwiLCJodHRwczovL2FwcC5wbGl0emkubG9jYWw6MzAwMCIsImh0dHBzOi8vYXBwLnBsaXR6aS5sb2NhbDozMDAxIiwiaHR0cHM6Ly9hcGkucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9zc3IucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9zZXJ2ZXIucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9tY3AucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hdXRoLnBsaXR6aS5sb2NhbCIsImh0dHA6Ly8xMjcuMC4wLjE6NTMwMCIsImh0dHA6Ly9sb2NhbGhvc3Q6NTE4MCJdLCJzY29wZSI6InNwYWNlOnJlbmRlciIsImlhdCI6MTc5MDc5NDEyMywianRpIjoiNmU1MTNmOTIwNTEwMzNkNCIsIm5iZiI6MTc5MDc5NDEyM30.4zBNY-E9PJZUfotar7D9LDM5yuwHOQc1nbxhHLPbVgA',
48
+ webKey: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxIiwib3JpZ2lucyI6WyJodHRwczovL3dlYnNpdGUucGxpdHppLmFwcCIsImh0dHBzOi8vcGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsOjMwMDAiLCJodHRwczovL2FwcC5wbGl0emkubG9jYWw6MzAwMSIsImh0dHBzOi8vc3NyLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vc2VydmVyLnBsaXR6aS5sb2NhbCIsImh0dHA6Ly9sb2NhbGhvc3Q6MzAwMCIsImh0dHA6Ly9sb2NhbGhvc3Q6ODA4MCIsImh0dHA6Ly8xMjcuMC4wLjE6ODA4MCIsImh0dHBzOi8vZGV2LnBsaXR6aS5jb20iLCJodHRwczovL3BsaXR6aS5jb20iLCJodHRwczovL3N0Zy5wbGl0emkuY29tIl0sImlzcyI6Imh0dHBzOi8vc2VydmVyLnBsaXR6aS5sb2NhbCIsImF1ZCI6WyJodHRwczovL3BsaXR6aS5sb2NhbCIsImh0dHBzOi8vYXBwLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vYXBwLnBsaXR6aS5sb2NhbDozMDAwIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsOjMwMDEiLCJodHRwczovL2FwaS5wbGl0emkubG9jYWwiLCJodHRwczovL3Nzci5wbGl0emkubG9jYWwiLCJodHRwczovL3NlcnZlci5wbGl0emkubG9jYWwiLCJodHRwczovL21jcC5wbGl0emkubG9jYWwiLCJodHRwczovL2F1dGgucGxpdHppLmxvY2FsIiwiaHR0cDovLzEyNy4wLjAuMTo1MzAwIiwiaHR0cDovL2xvY2FsaG9zdDo1MTgwIl0sInNjb3BlIjoic3BhY2U6cmVuZGVyIiwiaWF0IjoxNzkwMjEzMjg5LCJqdGkiOiJhZDgyN2EyMjliZjhlMzk3IiwibmJmIjoxNzkwMjEzMjg5fQ.dedpVVA5Nv3Xr7nEOZ8UmEJcIamF9AHGnLgqQyDV8-k',
62
49
  // The actor. Without it the builder loads and every write is refused, since authorization is
63
50
  // can(actor, space, permission). Both halves come from `yarn token 1 --user admin` in plitzi-sdk-server.
64
- userKey: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxIiwiaXNzIjoiaHR0cHM6Ly9zZXJ2ZXIucGxpdHppLmxvY2FsIiwiYXVkIjpbImh0dHBzOi8vcGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsOjMwMDAiLCJodHRwczovL2FwcC5wbGl0emkubG9jYWw6MzAwMSIsImh0dHBzOi8vYXBpLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vc3NyLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vc2VydmVyLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vbWNwLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vYXV0aC5wbGl0emkubG9jYWwiLCJodHRwOi8vMTI3LjAuMC4xOjUzMDAiLCJodHRwOi8vbG9jYWxob3N0OjUxODAiXSwic2NvcGUiOiJ1c2VyIiwiZXhwIjoxNzkwODgwNDk3LCJpYXQiOjE3OTA3OTQwOTcsImp0aSI6IjgzNWVjMTA5MDhkNzA4NjYiLCJuYmYiOjE3OTA3OTQwOTd9.aSm7PJz1yPtXjPD9DT40IWaqK7N9EAuSZ1Bsb7ZvABc',
51
+ userKey: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxIiwiaXNzIjoiaHR0cHM6Ly9zZXJ2ZXIucGxpdHppLmxvY2FsIiwiYXVkIjpbImh0dHBzOi8vcGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsIiwiaHR0cHM6Ly9hcHAucGxpdHppLmxvY2FsOjMwMDAiLCJodHRwczovL2FwcC5wbGl0emkubG9jYWw6MzAwMSIsImh0dHBzOi8vYXBpLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vc3NyLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vc2VydmVyLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vbWNwLnBsaXR6aS5sb2NhbCIsImh0dHBzOi8vYXV0aC5wbGl0emkubG9jYWwiLCJodHRwOi8vMTI3LjAuMC4xOjUzMDAiLCJodHRwOi8vbG9jYWxob3N0OjUxODAiXSwic2NvcGUiOiJ1c2VyIiwiZXhwIjoxNzkxMzg4NjQxLCJpYXQiOjE3OTEzMDIyNDEsImp0aSI6IjcwMjBkM2IyNjhmODcxNGQiLCJuYmYiOjE3OTEzMDIyNDF9.J5Ou41_K-nr12D3JP4wCVf0bZsorEVbvOgQ6WQTN54Y',
65
52
  environment: 'main',
66
53
  functionsWorkerUrl: '/plitzi-functions-worker.js',
67
54
  server: {
@@ -1,6 +1,6 @@
1
1
  /**
2
- * Everything of the space that runs on a server — its actions, functions, connectors, the credentials they use and its
3
- * runtime — under one entry of the sidebar. Whether the space HAS a server to run them is said here, once, above them
2
+ * Everything of the space that runs on a server — its actions, functions, the data its pages read there, connectors,
3
+ * the credentials they use and its runtime — under one entry of the sidebar. Whether the space HAS a server to run them is said here, once, above them
4
4
  * all.
5
5
  */
6
6
  declare const ContainerServer: () => import('react').JSX.Element;
@@ -9,6 +9,8 @@ export type DirectoryProps = {
9
9
  isRootFolder?: boolean;
10
10
  currentPageId?: string;
11
11
  nestedLevel?: number;
12
+ isCollapsed?: (folderId: string) => boolean;
13
+ onCollapse?: (folderId: string, collapsed: boolean) => void;
12
14
  };
13
- declare const Directory: ({ id, name, slug, parentId, isRootFolder, currentPageId, nestedLevel, pageFolders, elements }: DirectoryProps) => import('react').JSX.Element;
15
+ declare const Directory: ({ id, name, slug, parentId, isRootFolder, currentPageId, nestedLevel, pageFolders, elements, isCollapsed, onCollapse }: DirectoryProps) => import('react').JSX.Element;
14
16
  export default Directory;
@@ -6,10 +6,8 @@ import { PopupInstance } from '@plitzi/plitzi-ui/components';
6
6
  export declare const FULL_VIEW_IDS: readonly ["server", "settings"];
7
7
  export type FullViewId = (typeof FULL_VIEW_IDS)[number];
8
8
  export declare const isFullViewId: (id: string | undefined) => id is FullViewId;
9
- export declare const getPopups: ({ activeIds, platformFlags }: {
9
+ export declare const getPopups: ({ activeIds }: {
10
10
  activeIds?: string[];
11
- /** The editor's own feature flags, as the platform resolved them for whoever opened it. */
12
- platformFlags?: Record<string, boolean>;
13
11
  }) => {
14
12
  left: PopupInstance[];
15
13
  right: PopupInstance[];
@@ -1,2 +1 @@
1
- /** ⌘P / Ctrl+P — not ⌘K, which the AI panel already takes for its conversation list. */
2
1
  export declare const isSearchShortcut: (e: KeyboardEvent) => boolean;
@@ -2,6 +2,7 @@ import { ComponentDefinition, Element } from '@plitzi/sdk-shared';
2
2
  type Node = {
3
3
  id: string;
4
4
  label: string;
5
+ hint?: string;
5
6
  icon: string;
6
7
  parentId?: string;
7
8
  items?: Node[];
@@ -1,13 +1,17 @@
1
1
  import { ElementMatch } from '../helpers/searchElements';
2
2
  export type RevealTarget = Pick<ElementMatch, 'id' | 'rootId' | 'ancestors'>;
3
3
  /**
4
- * Takes the author to an element anywhere in the space: its page or layout on screen, the tree opened down to it,
5
- * and the element selected.
4
+ * Takes the author to an element anywhere in the space: its page, layout or component on screen, the tree opened down
5
+ * to it, and the element selected.
6
6
  *
7
7
  * The branches go into the same `openedCache` the tree reads, so revealing a match and expanding a node by hand are
8
8
  * the same act — an element eight levels down is selected AND visible in the Layers panel, not selected somewhere
9
9
  * the panel is not showing.
10
10
  *
11
+ * An element a component holds is reached by opening that component, whatever the caller worked out as its root: the
12
+ * pages' `flat` does not hold it unless the component is already open. One on a page closes the component open, if
13
+ * any, since the canvas shows the component in its place while it is.
14
+ *
11
15
  * The switch always goes out, even to the root already on screen: the builder may be showing a layout on top of
12
16
  * the current page, and asking for the page is what brings it back. Asking for the root already open is a no-op.
13
17
  */
@@ -3,7 +3,7 @@ export type ComponentsProps = {
3
3
  filter: string;
4
4
  };
5
5
  /**
6
- * The space's components, at the foot of the element catalog: placed the way an element is, by dragging it onto a
6
+ * The space's components, a category of the element catalog: placed the way an element is, by dragging it onto a
7
7
  * page — with what each is called and how many places render it. Edited by opening it in the canvas, where its tree is
8
8
  * edited like a page's.
9
9
  */
@@ -0,0 +1,15 @@
1
+ import { z } from 'zod';
2
+ import { PropEntry } from '../PropsEditor';
3
+ import { ProviderModalProps } from '@plitzi/plitzi-ui/Modal';
4
+ import { SpaceComponentDeclaration } from '@plitzi/sdk-shared';
5
+ export declare const componentFormSchema: z.ZodObject<{
6
+ label: z.ZodString;
7
+ folder: z.ZodOptional<z.ZodString>;
8
+ }, z.core.$strip>;
9
+ /**
10
+ * How the modal that holds the component's form opens: wide enough for a prop's name, kind and switches on one line.
11
+ * Its height is the form's to manage — the fields scroll and the buttons stay in view.
12
+ */
13
+ export declare const COMPONENT_MODAL: ProviderModalProps;
14
+ /** The props a declaration has, as the editor's rows. */
15
+ export declare const entriesOf: (declaration?: SpaceComponentDeclaration) => PropEntry[];
@@ -1 +1,2 @@
1
1
  export { default } from './ComponentForm';
2
+ export { COMPONENT_MODAL } from './helpers';
@@ -0,0 +1,10 @@
1
+ import { ReactNode } from 'react';
2
+ export type FormSectionProps = {
3
+ title: string;
4
+ /** What the section is for, in a line under its title. */
5
+ hint?: ReactNode;
6
+ children: ReactNode;
7
+ };
8
+ /** One part of the component's form: its title, what it is for, and its fields. */
9
+ declare const FormSection: ({ title, hint, children }: FormSectionProps) => import('react').JSX.Element;
10
+ export default FormSection;
@@ -0,0 +1,3 @@
1
+ import { default as FormSection } from './FormSection';
2
+ export * from './FormSection';
3
+ export default FormSection;
@@ -0,0 +1,7 @@
1
+ import { ComponentProp } from '@plitzi/sdk-shared';
2
+ /** The kinds a prop can be, as the kind picker lists them. */
3
+ export declare const TYPES: {
4
+ value: ComponentProp['type'];
5
+ label: string;
6
+ }[];
7
+ export declare const isPropType: (value: string) => value is ComponentProp["type"];
@@ -0,0 +1,7 @@
1
+ /**
2
+ * The space's own data: JSON files its pages read on the server, edited here and saved as the draft — whole, against
3
+ * the copy this panel read, so one saved since from elsewhere (an agent, a project's `plitzi push`) is never
4
+ * overwritten unseen. The live site reads what the space was last published with.
5
+ */
6
+ declare const Data: () => import('react').JSX.Element;
7
+ export default Data;
@@ -0,0 +1,12 @@
1
+ export type DataEditorProps = {
2
+ file: string;
3
+ value: string;
4
+ modified: boolean;
5
+ /** What is wrong with the text as JSON, as it is typed — none when it reads. */
6
+ problem?: string;
7
+ theme: 'light' | 'dark';
8
+ onChange: (text: string) => void;
9
+ };
10
+ /** The file being edited, with the query a provider reads it by and whether it is JSON as it stands. */
11
+ declare const DataEditor: ({ file, value, modified, problem, theme, onChange }: DataEditorProps) => import('react').JSX.Element;
12
+ export default DataEditor;
@@ -0,0 +1,3 @@
1
+ import { default as DataEditor } from './DataEditor';
2
+ export * from './DataEditor';
3
+ export default DataEditor;
@@ -0,0 +1,14 @@
1
+ import { SaveState } from '../../../FileTree';
2
+ export type DataHeaderProps = {
3
+ /** Where the files stand — none for data never saved. */
4
+ state?: SaveState;
5
+ canSave: boolean;
6
+ isSaving: boolean;
7
+ /** Whether there are changes to discard. */
8
+ canDiscard: boolean;
9
+ onSave: () => void;
10
+ onDiscard: () => void;
11
+ };
12
+ /** The panel's name and what it is for, where the files stand, and saving them. */
13
+ declare const DataHeader: ({ state, canSave, isSaving, canDiscard, onSave, onDiscard }: DataHeaderProps) => import('react').JSX.Element;
14
+ export default DataHeader;
@@ -0,0 +1,3 @@
1
+ import { default as DataHeader } from './DataHeader';
2
+ export * from './DataHeader';
3
+ export default DataHeader;
@@ -0,0 +1,9 @@
1
+ import { DataProblem } from '@plitzi/sdk-shared';
2
+ export type DataProblemsProps = {
3
+ problems: DataProblem[];
4
+ /** The file a problem is about, to open. */
5
+ onSelect: (file: string) => void;
6
+ };
7
+ /** What the last save found wrong, by file: nothing was kept. */
8
+ declare const DataProblems: ({ problems, onSelect }: DataProblemsProps) => import('react').JSX.Element;
9
+ export default DataProblems;
@@ -0,0 +1,3 @@
1
+ import { default as DataProblems } from './DataProblems';
2
+ export * from './DataProblems';
3
+ export default DataProblems;