slice-machine-ui 1.26.1-beta.11 → 1.26.1-beta.12

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 (439) hide show
  1. package/out/404.html +1 -1
  2. package/out/_next/static/chunks/{183-ebd633fed7c74545.js → 183-6ad5c4eb28d4b155.js} +1 -1
  3. package/out/_next/static/chunks/207-f71df53ed0b0ac4d.js +1 -0
  4. package/out/_next/static/chunks/453-1a14e86de385fe7c.js +1 -0
  5. package/out/_next/static/chunks/614-af117b661cd3429a.js +1 -0
  6. package/out/_next/static/chunks/90-2d4bdae13d031364.js +1 -0
  7. package/out/_next/static/chunks/91-1c3665ce38e58792.js +1 -0
  8. package/out/_next/static/chunks/96-33e38032f1e55366.js +1 -0
  9. package/out/_next/static/chunks/pages/{_app-6177e3581af44083.js → _app-01bcd29a595cec3a.js} +2 -2
  10. package/out/_next/static/chunks/pages/changelog-ac1004bdd31d17f8.js +1 -0
  11. package/out/_next/static/chunks/pages/changes-5c4bd80747884a8c.js +1 -0
  12. package/out/_next/static/chunks/pages/custom-types/[customTypeId]-8bcc4d88f470d3f7.js +1 -0
  13. package/out/_next/static/chunks/pages/{custom-types-3c8e721ec6802127.js → custom-types-75e8eddec659f440.js} +1 -1
  14. package/out/_next/static/chunks/pages/index-16754a04037cf9c1.js +1 -0
  15. package/out/_next/static/chunks/pages/labs-d6f2feb6720ee64c.js +1 -0
  16. package/out/_next/static/chunks/pages/page-types/[pageTypeId]-8461ab4fcfaf0755.js +1 -0
  17. package/out/_next/static/chunks/pages/settings-7ad1540dc0af794d.js +1 -0
  18. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]/simulator-9941e7eeb9d4d084.js +1 -0
  19. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]-217d0b0469d4320e.js +1 -0
  20. package/out/_next/static/chunks/pages/slices-801310de228fd05e.js +1 -0
  21. package/out/_next/static/css/17da9daaa8986410.css +1 -0
  22. package/out/_next/static/css/{27f2b9b9c9f65885.css → 663a1bac4ce890da.css} +1 -1
  23. package/out/_next/static/css/c36992b18975f9b9.css +1 -0
  24. package/out/_next/static/css/{243a4d347efcfd53.css → df904982b9637c1a.css} +1 -1
  25. package/out/_next/static/svF8JPCb25QlsmymuzIiN/_buildManifest.js +1 -0
  26. package/out/changelog.html +1 -1
  27. package/out/changes.html +1 -1
  28. package/out/custom-types/[customTypeId].html +1 -1
  29. package/out/custom-types.html +1 -1
  30. package/out/index.html +1 -1
  31. package/out/labs.html +1 -1
  32. package/out/page-types/[pageTypeId].html +1 -1
  33. package/out/settings.html +1 -1
  34. package/out/slices/[lib]/[sliceName]/[variation]/simulator.html +1 -1
  35. package/out/slices/[lib]/[sliceName]/[variation].html +1 -1
  36. package/out/slices.html +1 -1
  37. package/package.json +3 -3
  38. package/sentry.client.config.ts +2 -1
  39. package/src/ErrorBoundary.tsx +2 -1
  40. package/src/apiClient.ts +12 -7
  41. package/src/components/Card/Card.stories.tsx +4 -3
  42. package/src/components/CodeBlock/CodeBlock.tsx +6 -5
  43. package/src/components/Count/Count.tsx +2 -1
  44. package/src/components/HoverCard/HoverCard.tsx +3 -2
  45. package/src/components/SideNav/SideNav.stories.tsx +3 -2
  46. package/src/components/SideNav/SideNav.tsx +3 -2
  47. package/src/components/SideNav/SideNavEnvironmentSelector.tsx +3 -2
  48. package/src/components/Table/Table.test.tsx +4 -3
  49. package/src/domain/__tests__/slice.test.ts +3 -2
  50. package/src/domain/slice.ts +7 -3
  51. package/src/features/autoSave/AutoSaveStatusIndicator.tsx +2 -1
  52. package/src/features/changelog/useSliceMachineLatestNonBreakingVersion.ts +2 -1
  53. package/src/features/changelog/useSliceMachineReleaseNotes.ts +2 -1
  54. package/src/features/changelog/useSliceMachineVersions.ts +2 -1
  55. package/src/features/changes/BlankSlates/NoChangesBlankSlate.tsx +9 -8
  56. package/src/features/changes/PushChangesButton.tsx +5 -4
  57. package/src/features/changes/StatusBadge.tsx +3 -2
  58. package/src/features/customTypes/EditDropdown.tsx +4 -3
  59. package/src/features/customTypes/PageTypeOnboarding.tsx +4 -3
  60. package/src/features/customTypes/__tests__/CustomTypeBuilderPage.test.tsx +5 -4
  61. package/src/features/customTypes/__tests__/CustomTypesTablePage.test.tsx +5 -4
  62. package/src/features/customTypes/actions/convertCustomToPageType.ts +3 -2
  63. package/src/features/customTypes/actions/createCustomType.ts +4 -3
  64. package/src/features/customTypes/actions/deleteCustomType.ts +2 -1
  65. package/src/features/customTypes/actions/renameCustomType.ts +2 -1
  66. package/src/features/customTypes/customTypesBuilder/CustomTypeProvider.tsx +6 -5
  67. package/src/features/customTypes/customTypesBuilder/CustomTypesBuilderPage.tsx +21 -17
  68. package/src/features/customTypes/customTypesBuilder/PageSnippetDialog/PageSnippetDialog.tsx +7 -6
  69. package/src/features/customTypes/customTypesBuilder/SliceZoneBlankSlate.tsx +4 -3
  70. package/src/features/customTypes/customTypesBuilder/useCustomType.ts +2 -1
  71. package/src/features/customTypes/customTypesConfig.ts +3 -2
  72. package/src/features/customTypes/customTypesTable/CustomTypesTable.tsx +8 -7
  73. package/src/features/customTypes/customTypesTable/CustomTypesTablePage.tsx +12 -11
  74. package/src/features/customTypes/customTypesTable/useCustomTypes.ts +6 -5
  75. package/src/features/documentation/MarkdownRenderer/index.tsx +4 -3
  76. package/src/features/documentation/useDocumentation.ts +2 -1
  77. package/src/features/environments/actions/getActiveEnvironment.ts +2 -1
  78. package/src/features/environments/actions/getEnvironments.ts +1 -1
  79. package/src/features/environments/actions/setEnvironment.ts +3 -2
  80. package/src/features/inAppGuide/InAppGuideContext.tsx +2 -1
  81. package/src/features/inAppGuide/InAppGuideDialog.tsx +4 -3
  82. package/src/features/inAppGuide/inAppGuideContent.tsx +2 -1
  83. package/src/features/labs/labsList/LabsPage.tsx +7 -6
  84. package/src/features/labs/labsList/useLab.tsx +2 -1
  85. package/src/features/settings/SettingsPage.tsx +9 -8
  86. package/src/features/settings/git/ConnectGitRepository.tsx +11 -10
  87. package/src/features/settings/git/GitOwnerSelect.tsx +2 -1
  88. package/src/features/settings/git/GitProvider.ts +5 -4
  89. package/src/features/settings/git/GitProviderConnectButtons.tsx +2 -1
  90. package/src/features/settings/git/GitRepositoriesList.tsx +6 -5
  91. package/src/features/settings/git/GitRepositoriesSearch.tsx +7 -6
  92. package/src/features/settings/git/GitRepositoryConnectDialog.tsx +4 -3
  93. package/src/features/settings/git/useGitIntegrationExperiment.ts +1 -1
  94. package/src/features/settings/git/useGitOwners.ts +2 -1
  95. package/src/features/settings/git/useGitRepos.ts +2 -1
  96. package/src/features/settings/git/useLinkedGitRepos.ts +3 -2
  97. package/src/features/settings/git/useWriteAPIToken.ts +3 -2
  98. package/src/features/slices/actions/addSlicesToSliceZone.ts +3 -2
  99. package/src/features/slices/actions/createSlice.ts +5 -4
  100. package/src/features/slices/actions/deleteSlice.ts +2 -1
  101. package/src/features/slices/actions/renameSlice.ts +5 -4
  102. package/src/features/slices/actions/uploadSliceScreenshot.ts +3 -2
  103. package/src/features/slices/convertLegacySlice/ConvertLegacySliceAsNewSliceDialog.tsx +5 -4
  104. package/src/features/slices/convertLegacySlice/ConvertLegacySliceAsNewVariationDialog.tsx +2 -1
  105. package/src/features/slices/convertLegacySlice/ConvertLegacySliceButton.tsx +10 -9
  106. package/src/features/slices/convertLegacySlice/types.ts +2 -2
  107. package/src/features/slices/sliceBuilder/FloatingBackButton.tsx +9 -8
  108. package/src/features/slices/sliceBuilder/SliceBuilderProvider.tsx +7 -6
  109. package/src/features/slices/sliceBuilder/actions/deleteVariation.ts +7 -6
  110. package/src/features/slices/sliceBuilder/actions/renameVariation.ts +5 -4
  111. package/src/features/slices/sliceBuilder/useGroupsInSlicesExperiment.ts +1 -1
  112. package/src/features/slices/sliceCards/NonSharedSliceCard.tsx +5 -4
  113. package/src/features/slices/sliceCards/SharedSliceCard.tsx +9 -8
  114. package/src/features/slicesTemplates/actions/createSlicesTemplates.ts +3 -2
  115. package/src/features/slicesTemplates/useSlicesTemplates.ts +2 -1
  116. package/src/features/sync/AutoSyncProvider.tsx +10 -9
  117. package/src/features/sync/actions/pushChanges.ts +4 -3
  118. package/src/features/sync/actions/trackPushChangesSuccess.ts +3 -3
  119. package/src/features/sync/components/AutoSyncStatusIndicator.tsx +4 -3
  120. package/src/features/sync/fetchUnSyncChanges.ts +4 -4
  121. package/src/features/sync/getUnSyncChanges.ts +5 -5
  122. package/src/features/sync/useUnSyncChanges.ts +5 -4
  123. package/src/hooks/useAdapterName.ts +2 -1
  124. package/src/hooks/useAuthStatus.ts +3 -2
  125. package/src/hooks/useCurrentSlice.tsx +5 -4
  126. package/src/hooks/useEditorContent.ts +4 -3
  127. package/src/hooks/useExperimentVariant.ts +2 -1
  128. package/src/hooks/useIsEmptyProject.ts +2 -1
  129. package/src/hooks/useRepositoryInformation.ts +3 -2
  130. package/src/hooks/useSMTracker.ts +5 -4
  131. package/src/hooks/useScreenshotChangesModal.ts +4 -3
  132. package/src/hooks/useServerState.ts +4 -3
  133. package/src/hooks/useSliceMachineConfig.ts +2 -1
  134. package/src/hooks/useSliceMachineRunningVersion.ts +2 -1
  135. package/src/hooks/useUpdateAvailable.ts +2 -1
  136. package/{components → src/legacy/components}/App/index.tsx +9 -8
  137. package/{components → src/legacy/components}/AppLayout/index.tsx +8 -7
  138. package/{components → src/legacy/components}/Changelog/index.tsx +5 -4
  139. package/{components → src/legacy/components}/Changelog/navigation/index.tsx +5 -4
  140. package/{components → src/legacy/components}/Changelog/versionDetails/UpdateCommandBox.tsx +5 -4
  141. package/{components → src/legacy/components}/Changelog/versionDetails/index.tsx +2 -1
  142. package/{components → src/legacy/components}/ChangesEmptyState/AuthErrorPage.tsx +3 -2
  143. package/{components → src/legacy/components}/ChangesItems/ChangesItems.tsx +14 -13
  144. package/{components → src/legacy/components}/ChangesItems/DevCollaborationExperiment.tsx +3 -2
  145. package/{components → src/legacy/components}/CodeBlock/index.tsx +2 -1
  146. package/{components → src/legacy/components}/ConfigErrors/index.jsx +3 -2
  147. package/{components → src/legacy/components}/CustomTypeTable/changesPage.tsx +11 -10
  148. package/{components → src/legacy/components}/DeleteCTModal/index.tsx +7 -6
  149. package/{components → src/legacy/components}/DeleteDocumentsDrawer/AssociatedDocumentsCard.tsx +3 -2
  150. package/{components → src/legacy/components}/DeleteDocumentsDrawer/HardDeleteDocumentsDrawer.tsx +6 -5
  151. package/{components → src/legacy/components}/DeleteDocumentsDrawer/SoftDeleteDocumentsDrawer.tsx +6 -5
  152. package/{components → src/legacy/components}/DeleteSliceModal/index.tsx +7 -6
  153. package/{components → src/legacy/components}/DeleteVariationModal/index.tsx +6 -5
  154. package/{components → src/legacy/components}/EmptyState/index.tsx +2 -1
  155. package/{components → src/legacy/components}/FormFields/Input.tsx +2 -1
  156. package/{components → src/legacy/components}/Forms/CreateCustomTypeModal/CreateCustomTypeModal.tsx +17 -16
  157. package/{components → src/legacy/components}/Forms/CreateSliceModal/CreateSliceModal.tsx +8 -7
  158. package/{components → src/legacy/components}/Forms/RenameCustomTypeModal/RenameCustomTypeModal.tsx +7 -6
  159. package/{components → src/legacy/components}/Forms/RenameSliceModal/RenameSliceModal.tsx +7 -6
  160. package/src/legacy/components/Forms/RenameVariationModal/RenameVariationModal.module.css.d.ts +5 -0
  161. package/{components → src/legacy/components}/Forms/RenameVariationModal/RenameVariationModal.tsx +6 -5
  162. package/{components → src/legacy/components}/Forms/components/SelectRepeatable.tsx +2 -1
  163. package/{components → src/legacy/components}/Forms/formsValidator.ts +4 -3
  164. package/{components → src/legacy/components}/ListItem/Header.tsx +2 -1
  165. package/{components → src/legacy/components}/ListItem/index.tsx +3 -2
  166. package/{components → src/legacy/components}/LoginModal/index.tsx +20 -19
  167. package/{components → src/legacy/components}/ModalFormCard/index.tsx +3 -2
  168. package/{components → src/legacy/components}/Navigation/ChangesItem.tsx +12 -11
  169. package/{components → src/legacy/components}/Navigation/Environment.tsx +13 -12
  170. package/{components → src/legacy/components}/Navigation/RunningVersion.tsx +3 -2
  171. package/{components → src/legacy/components}/Navigation/UpdateBox.tsx +3 -2
  172. package/src/legacy/components/Navigation/VideoItem.module.css.d.ts +5 -0
  173. package/{components → src/legacy/components}/Navigation/VideoItem.tsx +15 -14
  174. package/src/legacy/components/Navigation/index.module.css.d.ts +5 -0
  175. package/{components → src/legacy/components}/Navigation/index.test.tsx +7 -9
  176. package/{components → src/legacy/components}/Navigation/index.tsx +21 -20
  177. package/{components → src/legacy/components}/ReviewModal/ReviewForm.tsx +10 -9
  178. package/{components → src/legacy/components}/ReviewModal/ReviewModal.tsx +7 -6
  179. package/{components → src/legacy/components}/ScreenshotChangesModal/VariationDropZone.tsx +6 -5
  180. package/{components → src/legacy/components}/ScreenshotChangesModal/index.tsx +11 -10
  181. package/{components → src/legacy/components}/ScreenshotChangesModal/useCustomScreenshot.tsx +2 -1
  182. package/{components → src/legacy/components}/ScreenshotPreviewModal/index.tsx +8 -7
  183. package/{components → src/legacy/components}/Simulator/components/FailedConnect/index.tsx +2 -1
  184. package/{components → src/legacy/components}/Simulator/components/Header/VariationsPopover/MenuList.tsx +2 -1
  185. package/{components → src/legacy/components}/Simulator/components/Header/VariationsPopover/index.tsx +2 -1
  186. package/{components → src/legacy/components}/Simulator/components/Header/index.tsx +7 -6
  187. package/{components → src/legacy/components}/Simulator/components/IframeRenderer/index.tsx +3 -2
  188. package/{components → src/legacy/components}/Simulator/components/Toolbar/ScreensizeInput/index.tsx +2 -1
  189. package/{components → src/legacy/components}/Simulator/components/Toolbar/index.tsx +3 -2
  190. package/{components → src/legacy/components}/Simulator/index.tsx +12 -11
  191. package/{components → src/legacy/components}/SliceMachineDrawer/index.tsx +2 -1
  192. package/{components → src/legacy/components}/Tooltip/TextWithTooltip.tsx +2 -1
  193. package/{components → src/legacy/components}/Tooltip/index.jsx +2 -1
  194. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/DeleteSliceZoneModal.tsx +4 -3
  195. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/List.tsx +11 -10
  196. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/SlicesTemplatesModal.tsx +10 -9
  197. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/UpdateSliceZoneModal.tsx +3 -2
  198. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/UpdateSliceZoneModalList.tsx +4 -3
  199. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/index.tsx +23 -19
  200. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/SliceZone/sliceTemplatesComingSoon.ts +1 -1
  201. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/TabModal/create.tsx +2 -1
  202. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/TabModal/delete.tsx +1 -1
  203. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/TabModal/update.tsx +2 -1
  204. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/TabZone/index.tsx +25 -21
  205. package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/index.tsx +7 -6
  206. package/{lib → src/legacy/lib}/builders/SliceBuilder/FieldZones/index.tsx +17 -16
  207. package/{lib → src/legacy/lib}/builders/SliceBuilder/Sidebar/AddVariationModal.tsx +4 -3
  208. package/{lib → src/legacy/lib}/builders/SliceBuilder/Sidebar/index.tsx +13 -12
  209. package/{lib → src/legacy/lib}/builders/SliceBuilder/SimulatorButton/index.tsx +15 -11
  210. package/{lib → src/legacy/lib}/builders/SliceBuilder/index.tsx +9 -8
  211. package/{lib → src/legacy/lib}/builders/common/EditModal/Field.jsx +2 -1
  212. package/{lib → src/legacy/lib}/builders/common/EditModal/index.jsx +12 -8
  213. package/{lib → src/legacy/lib}/builders/common/SelectFieldTypeModal/index.jsx +4 -3
  214. package/{lib → src/legacy/lib}/builders/common/Zone/Card/components/ErrorTooltip.tsx +2 -1
  215. package/{lib → src/legacy/lib}/builders/common/Zone/Card/components/Hints/CodeBlock.tsx +2 -1
  216. package/{lib → src/legacy/lib}/builders/common/Zone/Card/components/Hints/index.tsx +2 -1
  217. package/{lib → src/legacy/lib}/builders/common/Zone/Card/components/NewField.tsx +14 -10
  218. package/{lib → src/legacy/lib}/builders/common/Zone/Card/index.jsx +4 -3
  219. package/{lib → src/legacy/lib}/builders/common/Zone/index.jsx +3 -2
  220. package/{lib → src/legacy/lib}/builders/utils/index.ts +1 -1
  221. package/{lib → src/legacy/lib}/models/common/DeprecatedMockConfigMessage.tsx +2 -1
  222. package/{lib → src/legacy/lib}/models/common/ModelData.ts +3 -3
  223. package/{lib → src/legacy/lib}/models/common/ModelStatus/index.ts +2 -2
  224. package/{lib → src/legacy/lib}/models/common/normalizers/customType.ts +2 -2
  225. package/{lib → src/legacy/lib}/models/common/normalizers/slices.ts +2 -2
  226. package/{lib → src/legacy/lib}/models/common/widgets/ContentRelationship/Form.tsx +6 -5
  227. package/{lib → src/legacy/lib}/models/common/widgets/ContentRelationship/index.ts +3 -2
  228. package/{lib → src/legacy/lib}/models/common/widgets/Group/Form.jsx +6 -5
  229. package/{lib → src/legacy/lib}/models/common/widgets/Group/ListItem/index.jsx +22 -18
  230. package/{lib → src/legacy/lib}/models/common/widgets/Group/index.ts +2 -1
  231. package/{lib → src/legacy/lib}/models/common/widgets/Image/Form.tsx +6 -5
  232. package/{lib → src/legacy/lib}/models/common/widgets/Image/components.tsx +5 -4
  233. package/{lib → src/legacy/lib}/models/common/widgets/Link/Form.jsx +5 -5
  234. package/{lib → src/legacy/lib}/models/common/widgets/LinkToMedia/Form.jsx +4 -4
  235. package/{lib → src/legacy/lib}/models/common/widgets/LinkToMedia/index.ts +2 -1
  236. package/{lib → src/legacy/lib}/models/common/widgets/Select/FormFields.jsx +6 -5
  237. package/{lib → src/legacy/lib}/models/common/widgets/StructuredText/Form.tsx +7 -6
  238. package/{lib → src/legacy/lib}/models/common/widgets/Widget.ts +2 -1
  239. package/{lib → src/legacy/lib}/models/server/ServerState.ts +2 -2
  240. package/{lib → src/legacy/lib}/utils/shared/customTypes.ts +1 -1
  241. package/src/modules/availableCustomTypes/index.ts +10 -9
  242. package/src/modules/availableCustomTypes/types.ts +2 -2
  243. package/src/modules/environment/index.ts +7 -6
  244. package/src/modules/environment/types.ts +1 -1
  245. package/src/modules/modal/index.ts +2 -1
  246. package/src/modules/slices/index.ts +12 -8
  247. package/src/modules/slices/selector.ts +1 -1
  248. package/src/modules/slices/types.ts +2 -2
  249. package/src/modules/useSliceMachineActions.ts +10 -6
  250. package/src/modules/userContext/index.ts +6 -5
  251. package/{pages → src/pages}/_app.tsx +22 -22
  252. package/{pages → src/pages}/changelog.tsx +2 -1
  253. package/{pages → src/pages}/changes.tsx +25 -21
  254. package/src/pages/custom-types/[customTypeId].tsx +1 -0
  255. package/{pages → src/pages}/custom-types.tsx +2 -1
  256. package/{pages → src/pages}/index.tsx +4 -3
  257. package/src/pages/labs.tsx +1 -0
  258. package/src/pages/page-types/[pageTypeId].tsx +1 -0
  259. package/src/pages/settings.tsx +1 -0
  260. package/{pages → src/pages}/slices/[lib]/[sliceName]/[variation]/index.tsx +4 -3
  261. package/{pages → src/pages}/slices/[lib]/[sliceName]/[variation]/simulator.tsx +3 -2
  262. package/{pages → src/pages}/slices.tsx +24 -23
  263. package/src/redux/reducer.ts +7 -6
  264. package/src/redux/store.ts +2 -1
  265. package/src/redux/type.ts +7 -6
  266. package/test/__setup__.ts +10 -8
  267. package/test/__testutils__/createTestPlugin.ts +3 -2
  268. package/test/__testutils__/createTestProject.ts +5 -4
  269. package/test/__testutils__/index.tsx +6 -5
  270. package/test/__testutils__/mockAWSACLAPI.ts +1 -1
  271. package/test/__testutils__/mockCustomTypesAPI.ts +1 -1
  272. package/test/__testutils__/mockPrismicAuthAPI.ts +1 -1
  273. package/test/__testutils__/mockPrismicUserAPI.ts +2 -3
  274. package/test/__testutils__/readMSWFormData.ts +1 -1
  275. package/test/components/IframeRenderer.test.ts +3 -2
  276. package/test/lib/builders/EditModal.test.tsx +5 -3
  277. package/test/lib/builders/buildersUtils.test.ts +3 -3
  278. package/test/lib/consts.test.ts +6 -2
  279. package/test/lib/models/common/CustomType.test.ts +6 -2
  280. package/test/lib/models/common/ModelStatus.test.ts +6 -4
  281. package/test/lib/models/common/Slice.test.ts +3 -2
  282. package/test/lib/models/common/widgets/index.test.ts +8 -4
  283. package/test/lib/utils/index.test.ts +3 -2
  284. package/test/lib/utils/preferWroomBase.test.ts +3 -2
  285. package/test/lib/utils/shared/customTypes.test.ts +2 -1
  286. package/test/pages/slices.test.tsx +10 -10
  287. package/test/src/modules/__fixtures__/serverState.ts +1 -1
  288. package/test/src/modules/__fixtures__/sliceUtilsFactory.ts +3 -3
  289. package/test/src/modules/availableCustomTypes/index.test.ts +3 -3
  290. package/test/src/modules/environment.test.ts +3 -5
  291. package/test/src/modules/loading.test.ts +3 -3
  292. package/test/src/modules/modal.test.ts +5 -5
  293. package/test/src/modules/slices.test.ts +3 -2
  294. package/test/src/modules/userContext.test.ts +3 -3
  295. package/test/src/normalizers/customType.test.ts +16 -3
  296. package/test/src/utils/fieldNameCreator.test.ts +1 -1
  297. package/tsconfig.json +1 -6
  298. package/vite.config.ts +1 -7
  299. package/out/_next/static/6WrgMw0SELcypoJCYNiKd/_buildManifest.js +0 -1
  300. package/out/_next/static/chunks/25-607d5cfe6492f4e8.js +0 -1
  301. package/out/_next/static/chunks/286-6ee80333008646b9.js +0 -1
  302. package/out/_next/static/chunks/318-c84322cba57be932.js +0 -1
  303. package/out/_next/static/chunks/382-8194eab141c7ea2f.js +0 -1
  304. package/out/_next/static/chunks/727-b53258380c1a11f1.js +0 -1
  305. package/out/_next/static/chunks/799-68887319f3169f78.js +0 -1
  306. package/out/_next/static/chunks/pages/changelog-2d061c06b2b82e28.js +0 -1
  307. package/out/_next/static/chunks/pages/changes-cde59d56dc849106.js +0 -1
  308. package/out/_next/static/chunks/pages/custom-types/[customTypeId]-89ccb93ce7409ad0.js +0 -1
  309. package/out/_next/static/chunks/pages/index-b5817351a77c6d40.js +0 -1
  310. package/out/_next/static/chunks/pages/labs-0fc7d01b8c9bfc2a.js +0 -1
  311. package/out/_next/static/chunks/pages/page-types/[pageTypeId]-dbf86fe3a94dc892.js +0 -1
  312. package/out/_next/static/chunks/pages/settings-897ad13a08f73048.js +0 -1
  313. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]/simulator-ed3157875529f0f2.js +0 -1
  314. package/out/_next/static/chunks/pages/slices/[lib]/[sliceName]/[variation]-69cf4b12bb354f9f.js +0 -1
  315. package/out/_next/static/chunks/pages/slices-391f6c4b30af0759.js +0 -1
  316. package/out/_next/static/css/0e0d6c4ec6bf7373.css +0 -1
  317. package/out/_next/static/css/f8eb526e10bc2441.css +0 -1
  318. package/pages/custom-types/[customTypeId].tsx +0 -1
  319. package/pages/labs.tsx +0 -1
  320. package/pages/page-types/[pageTypeId].tsx +0 -1
  321. package/pages/settings.tsx +0 -1
  322. /package/out/_next/static/{6WrgMw0SELcypoJCYNiKd → svF8JPCb25QlsmymuzIiN}/_ssgManifest.js +0 -0
  323. /package/{components → src/legacy/components}/AuthInstructions/index.jsx +0 -0
  324. /package/{components → src/legacy/components}/Button/index.tsx +0 -0
  325. /package/{components → src/legacy/components}/Card/CardBox.tsx +0 -0
  326. /package/{components → src/legacy/components}/Card/Default.jsx +0 -0
  327. /package/{components → src/legacy/components}/Card/Preview.jsx +0 -0
  328. /package/{components → src/legacy/components}/Card/WithTabs/components.jsx +0 -0
  329. /package/{components → src/legacy/components}/Card/WithTabs/index.jsx +0 -0
  330. /package/{components → src/legacy/components}/Card/index.tsx +0 -0
  331. /package/{components → src/legacy/components}/Changelog/navigation/VersionBadge.tsx +0 -0
  332. /package/{components → src/legacy/components}/Changelog/navigation/VersionTag.tsx +0 -0
  333. /package/{components → src/legacy/components}/Changelog/versionDetails/ReleaseNotesDetails.tsx +0 -0
  334. /package/{components → src/legacy/components}/Changelog/versionDetails/VersionKindLabel.tsx +0 -0
  335. /package/{components → src/legacy/components}/ChangesEmptyState/OfflinePage.tsx +0 -0
  336. /package/{components → src/legacy/components}/ChangesEmptyState/index.ts +0 -0
  337. /package/{components → src/legacy/components}/ChangesItems/ErrorBanner.tsx +0 -0
  338. /package/{components → src/legacy/components}/ChangesItems/index.ts +0 -0
  339. /package/{components → src/legacy/components}/ChangesSectionHeader/ChangesSectionHeader.tsx +0 -0
  340. /package/{components → src/legacy/components}/ChangesSectionHeader/index.ts +0 -0
  341. /package/{components → src/legacy/components}/DeleteDocumentsDrawer/index.tsx +0 -0
  342. /package/{components → src/legacy/components}/DropDownSelector/MenuList.tsx +0 -0
  343. /package/{components → src/legacy/components}/DropDownSelector/index.tsx +0 -0
  344. /package/{components → src/legacy/components}/Flex/index.tsx +0 -0
  345. /package/{components → src/legacy/components}/FormFields/Array.jsx +0 -0
  346. /package/{components → src/legacy/components}/FormFields/Checkbox.jsx +0 -0
  347. /package/{components → src/legacy/components}/FormFields/CheckboxControl.jsx +0 -0
  348. /package/{components → src/legacy/components}/FormFields/SelectDefaultValue.jsx +0 -0
  349. /package/{components → src/legacy/components}/FormFields/index.ts +0 -0
  350. /package/{components → src/legacy/components}/Forms/CreateCustomTypeModal/index.tsx +0 -0
  351. /package/{components → src/legacy/components}/Forms/CreateSliceModal/index.tsx +0 -0
  352. /package/{components → src/legacy/components}/Forms/RenameCustomTypeModal/index.ts +0 -0
  353. /package/{components → src/legacy/components}/Forms/RenameSliceModal/index.ts +0 -0
  354. /package/{components → src/legacy/components}/Forms/RenameVariationModal/RenameVariationModal.module.css +0 -0
  355. /package/{components → src/legacy/components}/Forms/RenameVariationModal/index.ts +0 -0
  356. /package/{components → src/legacy/components}/Forms/components/FlexCard.tsx +0 -0
  357. /package/{components → src/legacy/components}/Forms/components/InputBox.tsx +0 -0
  358. /package/{components → src/legacy/components}/Forms/formsTypes.ts +0 -0
  359. /package/{components → src/legacy/components}/FullPage/index.tsx +0 -0
  360. /package/{components → src/legacy/components}/Grid/index.tsx +0 -0
  361. /package/{components → src/legacy/components}/InputDeleteIcon/index.jsx +0 -0
  362. /package/{components → src/legacy/components}/ItemHeader/index.tsx +0 -0
  363. /package/{components → src/legacy/components}/Li/index.tsx +0 -0
  364. /package/{components → src/legacy/components}/ListItem/utils.js +0 -0
  365. /package/{components → src/legacy/components}/LoadingPage/index.tsx +0 -0
  366. /package/{components → src/legacy/components}/MissingLibraries/index.tsx +0 -0
  367. /package/{components → src/legacy/components}/Navigation/VideoItem.module.css +0 -0
  368. /package/{components → src/legacy/components}/Navigation/index.module.css +0 -0
  369. /package/{components → src/legacy/components}/ReactTooltipPortal/index.tsx +0 -0
  370. /package/{components → src/legacy/components}/ReviewModal/ReviewFormSelect.tsx +0 -0
  371. /package/{components → src/legacy/components}/ReviewModal/index.ts +0 -0
  372. /package/{components → src/legacy/components}/ScreenshotPreview/index.tsx +0 -0
  373. /package/{components → src/legacy/components}/Simulator/components/FullPage/index.tsx +0 -0
  374. /package/{components → src/legacy/components}/Simulator/components/Header/links.ts +0 -0
  375. /package/{components → src/legacy/components}/SliceMachineIconButton/index.tsx +0 -0
  376. /package/{components → src/legacy/components}/SliceMachineModal/index.tsx +0 -0
  377. /package/{components → src/legacy/components}/ToasterContainer/index.tsx +0 -0
  378. /package/{components → src/legacy/components}/Warnings/index.jsx +0 -0
  379. /package/{components → src/legacy/components}/WindowPortal/index.js +0 -0
  380. /package/{components → src/legacy/components}/YoutubeEmbed/index.tsx +0 -0
  381. /package/{lib → src/legacy/lib}/builders/CustomTypeBuilder/TabModal/InputBox.tsx +0 -0
  382. /package/{lib → src/legacy/lib}/builders/common/EditModal/Form.jsx +0 -0
  383. /package/{lib → src/legacy/lib}/builders/common/SelectFieldTypeModal/FieldTypeCard.jsx +0 -0
  384. /package/{lib → src/legacy/lib}/builders/common/Zone/Card/components/EditItem.jsx +0 -0
  385. /package/{lib → src/legacy/lib}/builders/common/Zone/components/EmptyState/index.tsx +0 -0
  386. /package/{lib → src/legacy/lib}/consts.ts +0 -0
  387. /package/{lib → src/legacy/lib}/env/sentry.ts +0 -0
  388. /package/{lib → src/legacy/lib}/forms/defaults.ts +0 -0
  389. /package/{lib → src/legacy/lib}/forms/fields.ts +0 -0
  390. /package/{lib → src/legacy/lib}/forms/index.ts +0 -0
  391. /package/{lib → src/legacy/lib}/forms/types.ts +0 -0
  392. /package/{lib → src/legacy/lib}/hljs/svelte.ts +0 -0
  393. /package/{lib → src/legacy/lib}/models/common/Auth.ts +0 -0
  394. /package/{lib → src/legacy/lib}/models/common/ComponentUI.ts +0 -0
  395. /package/{lib → src/legacy/lib}/models/common/CustomType/index.ts +0 -0
  396. /package/{lib → src/legacy/lib}/models/common/CustomType/sliceZone.ts +0 -0
  397. /package/{lib → src/legacy/lib}/models/common/CustomType/tab.ts +0 -0
  398. /package/{lib → src/legacy/lib}/models/common/Environment.ts +0 -0
  399. /package/{lib → src/legacy/lib}/models/common/ErrorWithStatus.ts +0 -0
  400. /package/{lib → src/legacy/lib}/models/common/Fields.ts +0 -0
  401. /package/{lib → src/legacy/lib}/models/common/Group.ts +0 -0
  402. /package/{lib → src/legacy/lib}/models/common/Library.ts +0 -0
  403. /package/{lib → src/legacy/lib}/models/common/LibraryUI.ts +0 -0
  404. /package/{lib → src/legacy/lib}/models/common/Manifest.ts +0 -0
  405. /package/{lib → src/legacy/lib}/models/common/ModelStatus/compareCustomTypeModels.ts +0 -0
  406. /package/{lib → src/legacy/lib}/models/common/ModelStatus/compareSliceModels.ts +0 -0
  407. /package/{lib → src/legacy/lib}/models/common/PrismicData.ts +0 -0
  408. /package/{lib → src/legacy/lib}/models/common/PrismicFile.ts +0 -0
  409. /package/{lib → src/legacy/lib}/models/common/Screenshots.ts +0 -0
  410. /package/{lib → src/legacy/lib}/models/common/Simulator.ts +0 -0
  411. /package/{lib → src/legacy/lib}/models/common/Slice.ts +0 -0
  412. /package/{lib → src/legacy/lib}/models/common/Slices.ts +0 -0
  413. /package/{lib → src/legacy/lib}/models/common/UserProfile.ts +0 -0
  414. /package/{lib → src/legacy/lib}/models/common/Warning.ts +0 -0
  415. /package/{lib → src/legacy/lib}/models/common/widgets/Boolean/index.ts +0 -0
  416. /package/{lib → src/legacy/lib}/models/common/widgets/Color/index.ts +0 -0
  417. /package/{lib → src/legacy/lib}/models/common/widgets/Date/index.ts +0 -0
  418. /package/{lib → src/legacy/lib}/models/common/widgets/Embed/index.ts +0 -0
  419. /package/{lib → src/legacy/lib}/models/common/widgets/GeoPoint/index.ts +0 -0
  420. /package/{lib → src/legacy/lib}/models/common/widgets/Image/index.ts +0 -0
  421. /package/{lib → src/legacy/lib}/models/common/widgets/Link/index.ts +0 -0
  422. /package/{lib → src/legacy/lib}/models/common/widgets/Number/index.ts +0 -0
  423. /package/{lib → src/legacy/lib}/models/common/widgets/Select/index.ts +0 -0
  424. /package/{lib → src/legacy/lib}/models/common/widgets/StructuredText/index.ts +0 -0
  425. /package/{lib → src/legacy/lib}/models/common/widgets/StructuredText/options.tsx +0 -0
  426. /package/{lib → src/legacy/lib}/models/common/widgets/Text/index.ts +0 -0
  427. /package/{lib → src/legacy/lib}/models/common/widgets/Timestamp/index.ts +0 -0
  428. /package/{lib → src/legacy/lib}/models/common/widgets/UID/index.ts +0 -0
  429. /package/{lib → src/legacy/lib}/models/common/widgets/ctBuilderArray.ts +0 -0
  430. /package/{lib → src/legacy/lib}/models/common/widgets/index.ts +0 -0
  431. /package/{lib → src/legacy/lib}/models/common/widgets/sliceBuilderArray.ts +0 -0
  432. /package/{lib → src/legacy/lib}/models/common/widgets/withGroup.ts +0 -0
  433. /package/{lib → src/legacy/lib}/prismic/endpoints.ts +0 -0
  434. /package/{lib → src/legacy/lib}/utils/index.ts +0 -0
  435. /package/{lib → src/legacy/lib}/utils/poll.ts +0 -0
  436. /package/{lib → src/legacy/lib}/utils/preferWroomBase.ts +0 -0
  437. /package/{lib → src/legacy/lib}/utils/repo.ts +0 -0
  438. /package/{lib → src/legacy/lib}/utils/str.ts +0 -0
  439. /package/{pages → src/pages}/api/embed.js +0 -0
@@ -1,6 +1,7 @@
1
1
  import { useRequest } from "@prismicio/editor-support/Suspense";
2
2
  import type { GitOwner } from "@slicemachine/manager";
3
- import { managerClient } from "@src/managerClient";
3
+
4
+ import { managerClient } from "@/managerClient";
4
5
 
5
6
  export function useGitOwners(): GitOwner[] {
6
7
  return useRequest(getGitOwners, []);
@@ -1,6 +1,7 @@
1
1
  import { useRequest } from "@prismicio/editor-support/Suspense";
2
2
  import type { GitRepo } from "@slicemachine/manager";
3
- import { managerClient } from "@src/managerClient";
3
+
4
+ import { managerClient } from "@/managerClient";
4
5
 
5
6
  type UseGitReposArgs = Parameters<typeof managerClient.git.fetchRepos>[0];
6
7
 
@@ -1,7 +1,8 @@
1
1
  import { revalidateData, useRequest } from "@prismicio/editor-support/Suspense";
2
2
  import type { GitRepoSpecifier } from "@slicemachine/manager";
3
- import { useSliceMachineConfig } from "@src/hooks/useSliceMachineConfig";
4
- import { managerClient } from "@src/managerClient";
3
+
4
+ import { useSliceMachineConfig } from "@/hooks/useSliceMachineConfig";
5
+ import { managerClient } from "@/managerClient";
5
6
 
6
7
  type UseLinkedGitReposReturnType = {
7
8
  linkedGitRepos: GitRepoSpecifier[];
@@ -1,6 +1,7 @@
1
1
  import type { GitRepoSpecifier } from "@slicemachine/manager";
2
- import { useSliceMachineConfig } from "@src/hooks/useSliceMachineConfig";
3
- import { managerClient } from "@src/managerClient";
2
+
3
+ import { useSliceMachineConfig } from "@/hooks/useSliceMachineConfig";
4
+ import { managerClient } from "@/managerClient";
4
5
 
5
6
  type UseWriteAPITokenReturnType = {
6
7
  updateToken: (token: string) => Promise<void>;
@@ -1,6 +1,7 @@
1
- import { CustomTypeSM } from "@lib/models/common/CustomType";
2
1
  import { SharedSlice } from "@prismicio/types-internal/lib/customtypes";
3
- import { telemetry } from "@src/apiClient";
2
+
3
+ import { telemetry } from "@/apiClient";
4
+ import { CustomTypeSM } from "@/legacy/lib/models/common/CustomType";
4
5
 
5
6
  export type AddSlicesToSliceZoneArgs = {
6
7
  customType: CustomTypeSM;
@@ -1,10 +1,11 @@
1
- import { pascalize } from "@lib/utils/str";
2
1
  import { SharedSlice } from "@prismicio/types-internal/lib/customtypes";
3
- import { telemetry } from "@src/apiClient";
4
- import { buildEmptySliceModel } from "@src/domain/slice";
5
- import { managerClient } from "@src/managerClient";
6
2
  import { toast } from "react-toastify";
7
3
 
4
+ import { telemetry } from "@/apiClient";
5
+ import { buildEmptySliceModel } from "@/domain/slice";
6
+ import { pascalize } from "@/legacy/lib/utils/str";
7
+ import { managerClient } from "@/managerClient";
8
+
8
9
  type CreateSliceArgs = {
9
10
  sliceName: string;
10
11
  libraryName: string;
@@ -1,6 +1,7 @@
1
- import { managerClient } from "@src/managerClient";
2
1
  import { toast } from "react-toastify";
3
2
 
3
+ import { managerClient } from "@/managerClient";
4
+
4
5
  type DeleteSliceArgs = {
5
6
  libraryID: string;
6
7
  sliceID: string;
@@ -1,9 +1,10 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import { Slices } from "@lib/models/common/Slice";
3
- import { rename } from "@src/domain/slice";
4
- import { managerClient } from "@src/managerClient";
5
1
  import { toast } from "react-toastify";
6
2
 
3
+ import { rename } from "@/domain/slice";
4
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
5
+ import { Slices } from "@/legacy/lib/models/common/Slice";
6
+ import { managerClient } from "@/managerClient";
7
+
7
8
  type DeleteSliceArgs = {
8
9
  newSliceName: string;
9
10
  slice: ComponentUI;
@@ -1,7 +1,8 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import { generateSliceCustomScreenshot, telemetry } from "@src/apiClient";
3
1
  import { toast } from "react-toastify";
4
2
 
3
+ import { generateSliceCustomScreenshot, telemetry } from "@/apiClient";
4
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
5
+
5
6
  type UploadSliceScreenshotArgs = {
6
7
  file: File;
7
8
  method: "upload" | "dragAndDrop";
@@ -1,5 +1,3 @@
1
- import { validateSliceModalValues as validateAsNewSliceValues } from "@components/Forms/formsValidator";
2
- import { pascalize } from "@lib/utils/str";
3
1
  import {
4
2
  Box,
5
3
  Dialog,
@@ -12,12 +10,15 @@ import {
12
10
  SelectItem,
13
11
  Text,
14
12
  } from "@prismicio/editor-ui";
15
- import { getRemoteSlices } from "@src/modules/slices";
16
- import { SliceMachineStoreType } from "@src/redux/type";
17
13
  import { Formik } from "formik";
18
14
  import type { FC } from "react";
19
15
  import { useSelector } from "react-redux";
20
16
 
17
+ import { validateSliceModalValues as validateAsNewSliceValues } from "@/legacy/components/Forms/formsValidator";
18
+ import { pascalize } from "@/legacy/lib/utils/str";
19
+ import { getRemoteSlices } from "@/modules/slices";
20
+ import { SliceMachineStoreType } from "@/redux/type";
21
+
21
22
  import styles from "./ConvertLegacySliceButton.module.css";
22
23
  import { DialogProps } from "./types";
23
24
 
@@ -1,4 +1,3 @@
1
- import { LibraryUI } from "@models/common/LibraryUI";
2
1
  import {
3
2
  Box,
4
3
  Dialog,
@@ -15,6 +14,8 @@ import { Formik } from "formik";
15
14
  import { camelCase } from "lodash";
16
15
  import { type FC, useState } from "react";
17
16
 
17
+ import { LibraryUI } from "@/legacy/lib/models/common/LibraryUI";
18
+
18
19
  import styles from "./ConvertLegacySliceButton.module.css";
19
20
  import { DialogProps } from "./types";
20
21
 
@@ -1,5 +1,3 @@
1
- import { ComponentUI } from "@models/common/ComponentUI";
2
- import { NonSharedSliceInSliceZone } from "@models/common/CustomType/sliceZone";
3
1
  import {
4
2
  Button,
5
3
  DropdownMenu,
@@ -8,17 +6,20 @@ import {
8
6
  DropdownMenuTrigger,
9
7
  Icon,
10
8
  } from "@prismicio/editor-ui";
11
- import { getState, telemetry } from "@src/apiClient";
12
- import { getFieldMappingFingerprint } from "@src/domain/slice";
13
- import { useCustomTypeState } from "@src/features/customTypes/customTypesBuilder/CustomTypeProvider";
14
- import { managerClient } from "@src/managerClient";
15
- import { getLibraries } from "@src/modules/slices";
16
- import useSliceMachineActions from "@src/modules/useSliceMachineActions";
17
- import { SliceMachineStoreType } from "@src/redux/type";
18
9
  import { type FC, useMemo, useState } from "react";
19
10
  import { useSelector } from "react-redux";
20
11
  import { toast } from "react-toastify";
21
12
 
13
+ import { getState, telemetry } from "@/apiClient";
14
+ import { getFieldMappingFingerprint } from "@/domain/slice";
15
+ import { useCustomTypeState } from "@/features/customTypes/customTypesBuilder/CustomTypeProvider";
16
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
17
+ import { NonSharedSliceInSliceZone } from "@/legacy/lib/models/common/CustomType/sliceZone";
18
+ import { managerClient } from "@/managerClient";
19
+ import { getLibraries } from "@/modules/slices";
20
+ import useSliceMachineActions from "@/modules/useSliceMachineActions";
21
+ import { SliceMachineStoreType } from "@/redux/type";
22
+
22
23
  import { NonSharedSliceCardProps } from "../sliceCards/NonSharedSliceCard";
23
24
  import { ConvertLegacySliceAsNewSliceDialog } from "./ConvertLegacySliceAsNewSliceDialog";
24
25
  import { ConvertLegacySliceAsNewVariationDialog } from "./ConvertLegacySliceAsNewVariationDialog";
@@ -1,5 +1,5 @@
1
- import { ComponentUI } from "@models/common/ComponentUI";
2
- import { LibraryUI } from "@models/common/LibraryUI";
1
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
2
+ import { LibraryUI } from "@/legacy/lib/models/common/LibraryUI";
3
3
 
4
4
  import { NonSharedSliceCardProps } from "../sliceCards/NonSharedSliceCard";
5
5
 
@@ -1,16 +1,17 @@
1
1
  import { Box, Button, ButtonGroup } from "@prismicio/editor-ui";
2
- import { ErrorBoundary } from "@src/ErrorBoundary";
3
- import { useCustomType } from "@src/features/customTypes/customTypesBuilder/useCustomType";
2
+ import { useRouter } from "next/router";
3
+ import { type FC, Suspense, useState } from "react";
4
+
5
+ import { ErrorBoundary } from "@/ErrorBoundary";
6
+ import { useCustomType } from "@/features/customTypes/customTypesBuilder/useCustomType";
4
7
  import {
5
8
  CUSTOM_TYPES_CONFIG,
6
9
  matchesBuilderPagePathname,
7
10
  readBuilderPageDynamicSegment,
8
- } from "@src/features/customTypes/customTypesConfig";
9
- import { type Route, useRouteChange } from "@src/hooks/useRouteChange";
10
- import { CloseIcon } from "@src/icons/CloseIcon";
11
- import { UndoIcon } from "@src/icons/UndoIcon";
12
- import { useRouter } from "next/router";
13
- import { type FC, Suspense, useState } from "react";
11
+ } from "@/features/customTypes/customTypesConfig";
12
+ import { type Route, useRouteChange } from "@/hooks/useRouteChange";
13
+ import { CloseIcon } from "@/icons/CloseIcon";
14
+ import { UndoIcon } from "@/icons/UndoIcon";
14
15
 
15
16
  export const FloatingBackButton: FC = () => {
16
17
  const { source } = useRouteChange();
@@ -1,10 +1,4 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import { VariationSM } from "@lib/models/common/Slice";
3
1
  import { useStableCallback } from "@prismicio/editor-support/React";
4
- import { readSliceMocks, updateSlice } from "@src/apiClient";
5
- import { useAutoSync } from "@src/features/sync/AutoSyncProvider";
6
- import { ActionQueueStatus, useActionQueue } from "@src/hooks/useActionQueue";
7
- import useSliceMachineActions from "@src/modules/useSliceMachineActions";
8
2
  import { useRouter } from "next/router";
9
3
  import {
10
4
  createContext,
@@ -15,6 +9,13 @@ import {
15
9
  useState,
16
10
  } from "react";
17
11
 
12
+ import { readSliceMocks, updateSlice } from "@/apiClient";
13
+ import { useAutoSync } from "@/features/sync/AutoSyncProvider";
14
+ import { ActionQueueStatus, useActionQueue } from "@/hooks/useActionQueue";
15
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
16
+ import { VariationSM } from "@/legacy/lib/models/common/Slice";
17
+ import useSliceMachineActions from "@/modules/useSliceMachineActions";
18
+
18
19
  type SliceContext = {
19
20
  slice: ComponentUI;
20
21
  actionQueueStatus: ActionQueueStatus;
@@ -1,14 +1,15 @@
1
- import type { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import type { VariationSM } from "@lib/models/common/Slice";
1
+ import type { NextRouter } from "next/router";
2
+ import { toast } from "react-toastify";
3
+
3
4
  import {
4
5
  deleteSliceVariation,
5
6
  readSlice,
6
7
  readSliceMocks,
7
8
  updateSlice,
8
- } from "@src/apiClient";
9
- import { SLICES_CONFIG } from "@src/features/slices/slicesConfig";
10
- import type { NextRouter } from "next/router";
11
- import { toast } from "react-toastify";
9
+ } from "@/apiClient";
10
+ import { SLICES_CONFIG } from "@/features/slices/slicesConfig";
11
+ import type { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
12
+ import type { VariationSM } from "@/legacy/lib/models/common/Slice";
12
13
 
13
14
  type DeleteVariationArgs = {
14
15
  component: ComponentUI;
@@ -1,12 +1,13 @@
1
- import type { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import type { VariationSM } from "@lib/models/common/Slice";
1
+ import { toast } from "react-toastify";
2
+
3
3
  import {
4
4
  readSlice,
5
5
  readSliceMocks,
6
6
  renameSliceVariation,
7
7
  updateSlice,
8
- } from "@src/apiClient";
9
- import { toast } from "react-toastify";
8
+ } from "@/apiClient";
9
+ import type { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
10
+ import type { VariationSM } from "@/legacy/lib/models/common/Slice";
10
11
 
11
12
  type RenameVariationArgs = {
12
13
  component: ComponentUI;
@@ -1,4 +1,4 @@
1
- import { useExperimentVariant } from "@src/hooks/useExperimentVariant";
1
+ import { useExperimentVariant } from "@/hooks/useExperimentVariant";
2
2
 
3
3
  type UseGitIntegrationExperimentReturnType = { eligible: boolean };
4
4
 
@@ -1,10 +1,11 @@
1
- import { type NonSharedSliceInSliceZone } from "@models/common/CustomType/sliceZone";
2
1
  import { Badge, Box, Text, Tooltip } from "@prismicio/editor-ui";
3
- import { Card, CardActions, CardFooter, CardMedia } from "@src/components/Card";
4
- import { getNonSharedSliceLabel } from "@src/domain/slice";
5
- import { useLab } from "@src/features/labs/labsList/useLab";
6
2
  import type { FC } from "react";
7
3
 
4
+ import { Card, CardActions, CardFooter, CardMedia } from "@/components/Card";
5
+ import { getNonSharedSliceLabel } from "@/domain/slice";
6
+ import { useLab } from "@/features/labs/labsList/useLab";
7
+ import { type NonSharedSliceInSliceZone } from "@/legacy/lib/models/common/CustomType/sliceZone";
8
+
8
9
  import { ConvertLegacySliceButton } from "../convertLegacySlice/ConvertLegacySliceButton";
9
10
 
10
11
  export type NonSharedSliceCardProps = {
@@ -1,4 +1,3 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
1
  import {
3
2
  Box,
4
3
  Button,
@@ -13,16 +12,18 @@ import {
13
12
  tokens,
14
13
  Tooltip,
15
14
  } from "@prismicio/editor-ui";
16
- import { Card, CardFooter, CardMedia, CardStatus } from "@src/components/Card";
17
- import { countMissingScreenshots, getScreenshotUrl } from "@src/domain/slice";
15
+ import Link from "next/link";
16
+ import type { FC } from "react";
17
+
18
+ import { Card, CardFooter, CardMedia, CardStatus } from "@/components/Card";
19
+ import { countMissingScreenshots, getScreenshotUrl } from "@/domain/slice";
18
20
  import {
19
21
  StatusBadge,
20
22
  type StatusBadgeProps,
21
- } from "@src/features/changes/StatusBadge";
22
- import { SLICES_CONFIG } from "@src/features/slices/slicesConfig";
23
- import { AddPhotoAlternateIcon } from "@src/icons/AddPhotoAlternateIcon";
24
- import Link from "next/link";
25
- import type { FC } from "react";
23
+ } from "@/features/changes/StatusBadge";
24
+ import { SLICES_CONFIG } from "@/features/slices/slicesConfig";
25
+ import { AddPhotoAlternateIcon } from "@/icons/AddPhotoAlternateIcon";
26
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
26
27
 
27
28
  type SharedSliceCardProps = {
28
29
  isComingSoon?: boolean;
@@ -1,7 +1,8 @@
1
- import { telemetry } from "@src/apiClient";
2
- import { managerClient } from "@src/managerClient";
3
1
  import { toast } from "react-toastify";
4
2
 
3
+ import { telemetry } from "@/apiClient";
4
+ import { managerClient } from "@/managerClient";
5
+
5
6
  type CreateSlicesTemplatesArgs = {
6
7
  templateIDs: string[];
7
8
  localLibrariesNames: string[];
@@ -1,6 +1,7 @@
1
1
  import { useRequest } from "@prismicio/editor-support/Suspense";
2
2
  import { SharedSlice } from "@prismicio/types-internal/lib/customtypes";
3
- import { managerClient } from "@src/managerClient";
3
+
4
+ import { managerClient } from "@/managerClient";
4
5
 
5
6
  export type SliceTemplate = {
6
7
  model: SharedSlice;
@@ -1,7 +1,3 @@
1
- import {
2
- ChangedCustomType,
3
- ChangedSlice,
4
- } from "@lib/models/common/ModelStatus";
5
1
  import {
6
2
  useOnChange,
7
3
  useStableCallback,
@@ -10,11 +6,6 @@ import {
10
6
  Environment,
11
7
  isUnauthenticatedError,
12
8
  } from "@slicemachine/manager/client";
13
- import { getState } from "@src/apiClient";
14
- import { useAuthStatus } from "@src/hooks/useAuthStatus";
15
- import { useNetwork } from "@src/hooks/useNetwork";
16
- import { AuthStatus } from "@src/modules/userContext/types";
17
- import useSliceMachineActions from "@src/modules/useSliceMachineActions";
18
9
  import {
19
10
  createContext,
20
11
  FC,
@@ -25,6 +16,16 @@ import {
25
16
  useMemo,
26
17
  } from "react";
27
18
 
19
+ import { getState } from "@/apiClient";
20
+ import { useAuthStatus } from "@/hooks/useAuthStatus";
21
+ import { useNetwork } from "@/hooks/useNetwork";
22
+ import {
23
+ ChangedCustomType,
24
+ ChangedSlice,
25
+ } from "@/legacy/lib/models/common/ModelStatus";
26
+ import { AuthStatus } from "@/modules/userContext/types";
27
+ import useSliceMachineActions from "@/modules/useSliceMachineActions";
28
+
28
29
  import { ActionQueueStatus, useActionQueue } from "../../hooks/useActionQueue";
29
30
  import { useActiveEnvironment } from "../environments/useActiveEnvironment";
30
31
  import { pushChanges } from "./actions/pushChanges";
@@ -1,9 +1,10 @@
1
+ import { PushChangesLimit } from "@slicemachine/manager";
2
+
3
+ import { pushChanges as pushChangesCall, telemetry } from "@/apiClient";
1
4
  import {
2
5
  ChangedCustomType,
3
6
  ChangedSlice,
4
- } from "@lib/models/common/ModelStatus";
5
- import { PushChangesLimit } from "@slicemachine/manager";
6
- import { pushChanges as pushChangesCall, telemetry } from "@src/apiClient";
7
+ } from "@/legacy/lib/models/common/ModelStatus";
7
8
 
8
9
  import { trackPushChangesSuccess } from "./trackPushChangesSuccess";
9
10
 
@@ -1,10 +1,10 @@
1
+ import { telemetry } from "@/apiClient";
2
+ import { countMissingScreenshots } from "@/domain/slice";
1
3
  import {
2
4
  ChangedCustomType,
3
5
  ChangedSlice,
4
6
  ModelStatus,
5
- } from "@lib/models/common/ModelStatus";
6
- import { telemetry } from "@src/apiClient";
7
- import { countMissingScreenshots } from "@src/domain/slice";
7
+ } from "@/legacy/lib/models/common/ModelStatus";
8
8
 
9
9
  type TrackPushChangesSuccessArgs = {
10
10
  changedSlices: ReadonlyArray<ChangedSlice>;
@@ -1,9 +1,10 @@
1
1
  import { Text, Tooltip } from "@prismicio/editor-ui";
2
- import { Synced } from "@src/icons/Synced";
3
- import { SyncFailed } from "@src/icons/SyncFailed";
4
- import { Syncing } from "@src/icons/Syncing";
5
2
  import { FC } from "react";
6
3
 
4
+ import { Synced } from "@/icons/Synced";
5
+ import { SyncFailed } from "@/icons/SyncFailed";
6
+ import { Syncing } from "@/icons/Syncing";
7
+
7
8
  import styles from "./AutoSyncStatusIndicator.module.css";
8
9
 
9
10
  type AutoSyncStatusIndicatorProps = {
@@ -1,7 +1,7 @@
1
- import { normalizeFrontendCustomTypes } from "@lib/models/common/normalizers/customType";
2
- import { normalizeFrontendSlices } from "@lib/models/common/normalizers/slices";
3
- import { getState } from "@src/apiClient";
4
- import { AuthStatus } from "@src/modules/userContext/types";
1
+ import { getState } from "@/apiClient";
2
+ import { normalizeFrontendCustomTypes } from "@/legacy/lib/models/common/normalizers/customType";
3
+ import { normalizeFrontendSlices } from "@/legacy/lib/models/common/normalizers/slices";
4
+ import { AuthStatus } from "@/modules/userContext/types";
5
5
 
6
6
  import { getUnSyncedChanges, UnSyncedChanges } from "./getUnSyncChanges";
7
7
 
@@ -1,5 +1,5 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import { LibraryUI } from "@lib/models/common/LibraryUI";
1
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
2
+ import { LibraryUI } from "@/legacy/lib/models/common/LibraryUI";
3
3
  import {
4
4
  getModelId,
5
5
  hasLocal,
@@ -7,14 +7,14 @@ import {
7
7
  LocalOrRemoteCustomType,
8
8
  LocalOrRemoteSlice,
9
9
  RemoteOnlySlice,
10
- } from "@lib/models/common/ModelData";
10
+ } from "@/legacy/lib/models/common/ModelData";
11
11
  import {
12
12
  ChangedCustomType,
13
13
  ChangedSlice,
14
14
  computeStatuses,
15
15
  ModelStatus,
16
- } from "@lib/models/common/ModelStatus";
17
- import { AuthStatus } from "@src/modules/userContext/types";
16
+ } from "@/legacy/lib/models/common/ModelStatus";
17
+ import { AuthStatus } from "@/modules/userContext/types";
18
18
 
19
19
  type GetUnSyncedChangesArgs = {
20
20
  customTypes: LocalOrRemoteCustomType[];
@@ -1,10 +1,11 @@
1
- import { useAuthStatus } from "@src/hooks/useAuthStatus";
2
- import { selectAllCustomTypes } from "@src/modules/availableCustomTypes";
3
- import { getFrontendSlices, getLibraries } from "@src/modules/slices";
4
- import { SliceMachineStoreType } from "@src/redux/type";
5
1
  import { useMemo } from "react";
6
2
  import { useSelector } from "react-redux";
7
3
 
4
+ import { useAuthStatus } from "@/hooks/useAuthStatus";
5
+ import { selectAllCustomTypes } from "@/modules/availableCustomTypes";
6
+ import { getFrontendSlices, getLibraries } from "@/modules/slices";
7
+ import { SliceMachineStoreType } from "@/redux/type";
8
+
8
9
  import { useNetwork } from "../../hooks/useNetwork";
9
10
  import { getUnSyncedChanges, UnSyncedChanges } from "./getUnSyncChanges";
10
11
 
@@ -1,5 +1,6 @@
1
1
  import { useRequest } from "@prismicio/editor-support/Suspense";
2
- import { managerClient } from "@src/managerClient";
2
+
3
+ import { managerClient } from "@/managerClient";
3
4
 
4
5
  async function getAdapterName() {
5
6
  try {
@@ -1,7 +1,8 @@
1
- import { getAuthStatus } from "@src/modules/environment";
2
- import { SliceMachineStoreType } from "@src/redux/type";
3
1
  import { useSelector } from "react-redux";
4
2
 
3
+ import { getAuthStatus } from "@/modules/environment";
4
+ import { SliceMachineStoreType } from "@/redux/type";
5
+
5
6
  export function useAuthStatus() {
6
7
  const { authStatus } = useSelector((store: SliceMachineStoreType) => ({
7
8
  authStatus: getAuthStatus(store),
@@ -1,10 +1,11 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import { VariationSM } from "@lib/models/common/Slice";
3
- import { selectCurrentSlice } from "@src/modules/slices/selector";
4
- import { SliceMachineStoreType } from "@src/redux/type";
5
1
  import { useRouter } from "next/router";
6
2
  import { useSelector } from "react-redux";
7
3
 
4
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
5
+ import { VariationSM } from "@/legacy/lib/models/common/Slice";
6
+ import { selectCurrentSlice } from "@/modules/slices/selector";
7
+ import { SliceMachineStoreType } from "@/redux/type";
8
+
8
9
  type UseCurrentSliceRet = { slice?: ComponentUI; variation?: VariationSM };
9
10
 
10
11
  const useCurrentSlice = (): UseCurrentSliceRet => {
@@ -1,10 +1,11 @@
1
- import { ComponentUI } from "@lib/models/common/ComponentUI";
2
- import { Slices } from "@lib/models/common/Slice";
3
1
  import { renderSliceMock } from "@prismicio/mocks";
4
2
  import { SharedSliceContent } from "@prismicio/types-internal/lib/content";
5
- import { defaultSharedSliceContent } from "@src/utils/editor";
6
3
  import { useMemo } from "react";
7
4
 
5
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
6
+ import { Slices } from "@/legacy/lib/models/common/Slice";
7
+ import { defaultSharedSliceContent } from "@/utils/editor";
8
+
8
9
  function useEditorContentOnce({
9
10
  variationID,
10
11
  slice,
@@ -1,6 +1,7 @@
1
1
  import { useRequest } from "@prismicio/editor-support/Suspense";
2
2
  import type { Variant } from "@slicemachine/manager";
3
- import { managerClient } from "@src/managerClient";
3
+
4
+ import { managerClient } from "@/managerClient";
4
5
 
5
6
  async function getExperimentVariant(variantName: string) {
6
7
  try {
@@ -1,5 +1,6 @@
1
1
  import { useRequest } from "@prismicio/editor-support/Suspense";
2
- import { managerClient } from "@src/managerClient";
2
+
3
+ import { managerClient } from "@/managerClient";
3
4
 
4
5
  export async function getIsEmptyProject() {
5
6
  const [
@@ -1,7 +1,8 @@
1
- import { getApiEndpoint, getRepoName } from "@src/modules/environment";
2
- import { SliceMachineStoreType } from "@src/redux/type";
3
1
  import { useSelector } from "react-redux";
4
2
 
3
+ import { getApiEndpoint, getRepoName } from "@/modules/environment";
4
+ import { SliceMachineStoreType } from "@/redux/type";
5
+
5
6
  // TODO: This hook should be extracted to a new manager endpoint
6
7
  export function useRepositoryInformation() {
7
8
  const { repositoryName, apiEndpoint } = useSelector(
@@ -1,11 +1,12 @@
1
- import type { LibraryUI } from "@lib/models/common/LibraryUI";
2
- import { telemetry } from "@src/apiClient";
3
- import { getLibraries } from "@src/modules/slices";
4
- import { SliceMachineStoreType } from "@src/redux/type";
5
1
  import { useRouter } from "next/router";
6
2
  import { useEffect } from "react";
7
3
  import { useSelector } from "react-redux";
8
4
 
5
+ import { telemetry } from "@/apiClient";
6
+ import type { LibraryUI } from "@/legacy/lib/models/common/LibraryUI";
7
+ import { getLibraries } from "@/modules/slices";
8
+ import { SliceMachineStoreType } from "@/redux/type";
9
+
9
10
  import { managerClient } from "../managerClient";
10
11
 
11
12
  const useSMTracker = () => {
@@ -1,8 +1,9 @@
1
- import { SliceVariationSelector } from "@components/ScreenshotChangesModal";
2
- import { ComponentUI } from "@lib/models/common/ComponentUI";
3
- import useSliceMachineActions from "@src/modules/useSliceMachineActions";
4
1
  import { useState } from "react";
5
2
 
3
+ import { SliceVariationSelector } from "@/legacy/components/ScreenshotChangesModal";
4
+ import { ComponentUI } from "@/legacy/lib/models/common/ComponentUI";
5
+ import useSliceMachineActions from "@/modules/useSliceMachineActions";
6
+
6
7
  type ModalPayload = {
7
8
  sliceFilterFn: (s: ComponentUI[]) => ComponentUI[];
8
9
  defaultVariationSelector?: SliceVariationSelector;