@contember/create 2.0.2 → 2.1.0-alpha.10

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 (282) hide show
  1. package/dist/development/src/commands/WorkspaceCreateCommand.cjs +37 -23
  2. package/dist/development/src/commands/WorkspaceCreateCommand.cjs.map +1 -1
  3. package/dist/development/src/commands/WorkspaceCreateCommand.js +37 -23
  4. package/dist/development/src/commands/WorkspaceCreateCommand.js.map +1 -1
  5. package/dist/development/src/lib/FileSystem.cjs +1 -0
  6. package/dist/development/src/lib/FileSystem.cjs.map +1 -1
  7. package/dist/development/src/lib/FileSystem.js +1 -0
  8. package/dist/development/src/lib/FileSystem.js.map +1 -1
  9. package/dist/development/src/lib/TemplateInstaller.cjs +24 -5
  10. package/dist/development/src/lib/TemplateInstaller.cjs.map +1 -1
  11. package/dist/development/src/lib/TemplateInstaller.js +24 -5
  12. package/dist/development/src/lib/TemplateInstaller.js.map +1 -1
  13. package/dist/development/src/lib/packageManagerDetector.cjs +22 -0
  14. package/dist/development/src/lib/packageManagerDetector.cjs.map +1 -0
  15. package/dist/development/src/lib/packageManagerDetector.js +22 -0
  16. package/dist/development/src/lib/packageManagerDetector.js.map +1 -0
  17. package/dist/production/src/commands/WorkspaceCreateCommand.cjs +37 -23
  18. package/dist/production/src/commands/WorkspaceCreateCommand.cjs.map +1 -1
  19. package/dist/production/src/commands/WorkspaceCreateCommand.js +37 -23
  20. package/dist/production/src/commands/WorkspaceCreateCommand.js.map +1 -1
  21. package/dist/production/src/lib/FileSystem.cjs +1 -0
  22. package/dist/production/src/lib/FileSystem.cjs.map +1 -1
  23. package/dist/production/src/lib/FileSystem.js +1 -0
  24. package/dist/production/src/lib/FileSystem.js.map +1 -1
  25. package/dist/production/src/lib/TemplateInstaller.cjs +24 -5
  26. package/dist/production/src/lib/TemplateInstaller.cjs.map +1 -1
  27. package/dist/production/src/lib/TemplateInstaller.js +24 -5
  28. package/dist/production/src/lib/TemplateInstaller.js.map +1 -1
  29. package/dist/production/src/lib/packageManagerDetector.cjs +22 -0
  30. package/dist/production/src/lib/packageManagerDetector.cjs.map +1 -0
  31. package/dist/production/src/lib/packageManagerDetector.js +22 -0
  32. package/dist/production/src/lib/packageManagerDetector.js.map +1 -0
  33. package/dist/types/commands/WorkspaceCreateCommand.d.ts +4 -2
  34. package/dist/types/commands/WorkspaceCreateCommand.d.ts.map +1 -1
  35. package/dist/types/lib/FileSystem.d.ts +1 -0
  36. package/dist/types/lib/FileSystem.d.ts.map +1 -1
  37. package/dist/types/lib/TemplateInstaller.d.ts.map +1 -1
  38. package/dist/types/lib/packageManagerDetector.d.ts +3 -0
  39. package/dist/types/lib/packageManagerDetector.d.ts.map +1 -0
  40. package/dist/types/tsconfig.tsbuildinfo +1 -1
  41. package/package.json +7 -3
  42. package/resources/templates/default/.gitignore.dist +154 -0
  43. package/resources/templates/default/README.md +98 -0
  44. package/resources/templates/{template-workspace → default}/admin/.env.development +1 -0
  45. package/resources/templates/{template-workspace → default}/admin/app/components/layout.tsx +7 -3
  46. package/resources/templates/default/admin/app/components/navigation.tsx +85 -0
  47. package/resources/templates/{template-workspace → default}/admin/app/index.tsx +4 -4
  48. package/resources/templates/default/admin/app/pages/tenant.tsx +160 -0
  49. package/resources/templates/default/admin/entrypoint/components/layout.tsx +14 -0
  50. package/resources/templates/default/admin/entrypoint/components/logged-in.tsx +47 -0
  51. package/resources/templates/default/admin/entrypoint/components/login.tsx +103 -0
  52. package/resources/templates/default/admin/entrypoint/config.ts +35 -0
  53. package/resources/templates/default/admin/entrypoint/contexts/login.tsx +18 -0
  54. package/resources/templates/default/admin/entrypoint/index.tsx +12 -0
  55. package/resources/templates/default/admin/entrypoint/login-entrypoint.tsx +24 -0
  56. package/resources/templates/default/admin/entrypoint/pages/index.tsx +48 -0
  57. package/resources/templates/default/admin/entrypoint/pages/magicLink.tsx +56 -0
  58. package/resources/templates/default/admin/entrypoint/pages/magicLintSent.tsx +63 -0
  59. package/resources/templates/default/admin/entrypoint/pages/passwordReset.tsx +44 -0
  60. package/resources/templates/default/admin/entrypoint/pages/resetRequest.tsx +35 -0
  61. package/resources/templates/default/admin/entrypoint/pages/resetRequestSuccess.tsx +34 -0
  62. package/resources/templates/default/admin/index.css +94 -0
  63. package/resources/templates/{template-workspace → default}/admin/index.html +1 -1
  64. package/resources/templates/{template-workspace → default}/admin/lib/block-repeater/block-repeater.tsx +4 -4
  65. package/resources/templates/{template-workspace → default}/admin/lib/board/board.tsx +3 -3
  66. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/cells.tsx +47 -0
  67. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/column-header.tsx +1 -1
  68. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/columns.tsx +72 -9
  69. package/resources/templates/default/admin/lib/datagrid/elements.tsx +59 -0
  70. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/empty.tsx +1 -1
  71. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/date.tsx +4 -4
  72. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/enum.tsx +37 -0
  73. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/relation.tsx +1 -1
  74. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/pagination.tsx +1 -1
  75. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/table.tsx +1 -1
  76. package/resources/templates/{template-workspace → default}/admin/lib/datagrid/ui.tsx +4 -4
  77. package/resources/templates/{template-workspace → default}/admin/lib/dimensions/dimensions.tsx +2 -2
  78. package/resources/templates/{template-workspace → default}/admin/lib/editor/common/editor-block-toolbar.tsx +1 -1
  79. package/resources/templates/{template-workspace → default}/admin/lib/editor/common/editor-canvas.tsx +2 -2
  80. package/resources/templates/{template-workspace → default}/admin/lib/editor/common/editor-inline-toolbar.tsx +1 -1
  81. package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/BlockElement.tsx +2 -2
  82. package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/TableCellElementRenderer.tsx +1 -1
  83. package/resources/templates/{template-workspace → default}/admin/lib/editor/editor-block.tsx +1 -1
  84. package/resources/templates/{template-workspace → default}/admin/lib/editor/sortable-block.tsx +1 -1
  85. package/resources/templates/{template-workspace → default}/admin/lib/form/container.tsx +2 -1
  86. package/resources/templates/{template-workspace → default}/admin/lib/layout/layout-boxed.tsx +4 -4
  87. package/resources/templates/{template-workspace → default}/admin/lib/repeater/repeater.tsx +3 -3
  88. package/resources/templates/{template-workspace → default}/admin/lib/select/ui.tsx +5 -5
  89. package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/common.tsx +1 -1
  90. package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/memberships-control.tsx +1 -1
  91. package/resources/templates/{template-workspace → default}/admin/lib/tenant/otp/otp-setup.tsx +1 -1
  92. package/resources/templates/{template-workspace → default}/admin/lib/toast/toast.tsx +4 -5
  93. package/resources/templates/{template-workspace → default}/admin/lib/ui/button.tsx +6 -6
  94. package/resources/templates/{template-workspace → default}/admin/lib/ui/card.tsx +1 -1
  95. package/resources/templates/{template-workspace → default}/admin/lib/ui/dialog.tsx +2 -2
  96. package/resources/templates/{template-workspace → default}/admin/lib/ui/dropdown.tsx +6 -6
  97. package/resources/templates/{template-workspace → default}/admin/lib/ui/input.tsx +11 -11
  98. package/resources/templates/{template-workspace → default}/admin/lib/ui/overlay.tsx +1 -1
  99. package/resources/templates/{template-workspace → default}/admin/lib/ui/popover.tsx +1 -1
  100. package/resources/templates/{template-workspace → default}/admin/lib/ui/property-list.tsx +3 -3
  101. package/resources/templates/{template-workspace → default}/admin/lib/ui/select.tsx +3 -3
  102. package/resources/templates/{template-workspace → default}/admin/lib/ui/sheet.tsx +4 -4
  103. package/resources/templates/{template-workspace → default}/admin/lib/ui/sidebar.tsx +15 -16
  104. package/resources/templates/{template-workspace → default}/admin/lib/ui/sortable.tsx +1 -1
  105. package/resources/templates/{template-workspace → default}/admin/lib/ui/switch.tsx +1 -1
  106. package/resources/templates/{template-workspace → default}/admin/lib/ui/table.tsx +3 -3
  107. package/resources/templates/{template-workspace → default}/admin/lib/ui/textarea.tsx +3 -3
  108. package/resources/templates/{template-workspace → default}/admin/lib/ui/toggle.tsx +2 -3
  109. package/resources/templates/{template-workspace → default}/admin/lib/ui/tooltip.tsx +2 -2
  110. package/resources/templates/{template-workspace → default}/admin/lib/upload/ui.tsx +4 -4
  111. package/resources/templates/{template-workspace → default}/admin/lib/upload/upload-progress.tsx +1 -1
  112. package/resources/templates/{template-workspace → default}/admin/lib/upload/view.tsx +3 -3
  113. package/resources/templates/{template-workspace → default}/admin/lib/utils/uic.tsx +30 -23
  114. package/resources/templates/{template-workspace → default}/admin/package.json +6 -3
  115. package/resources/templates/default/admin/postcss.config.js +5 -0
  116. package/resources/templates/default/admin/sentry.ts +26 -0
  117. package/resources/templates/{template-workspace → default}/admin/tsconfig.json +1 -9
  118. package/resources/templates/default/admin/vite-env.d.ts +12 -0
  119. package/resources/templates/default/admin/vite.config.ts +11 -0
  120. package/resources/templates/default/api/README.md +87 -0
  121. package/resources/templates/{template-workspace → default}/biome.json +1 -1
  122. package/resources/templates/default/client/README.md +285 -0
  123. package/resources/templates/{template-workspace → default}/contember.template.yaml +5 -0
  124. package/resources/templates/{template-workspace → default}/package.json +2 -2
  125. package/resources/templates/default/scripts/generate-client.sh +7 -0
  126. package/resources/templates/default/scripts/update-ui-lib.sh +344 -0
  127. package/src/commands/WorkspaceCreateCommand.ts +41 -24
  128. package/src/lib/FileSystem.ts +1 -0
  129. package/src/lib/TemplateInstaller.ts +30 -7
  130. package/src/lib/packageManagerDetector.ts +24 -0
  131. package/resources/templates/template-workspace/.gitignore.dist +0 -3
  132. package/resources/templates/template-workspace/admin/app/components/navigation.tsx +0 -1
  133. package/resources/templates/template-workspace/admin/index.css +0 -53
  134. package/resources/templates/template-workspace/admin/index.tsx +0 -268
  135. package/resources/templates/template-workspace/admin/lib/datagrid/elements.tsx +0 -48
  136. package/resources/templates/template-workspace/admin/postcss.config.js +0 -6
  137. package/resources/templates/template-workspace/admin/tailwind.config.js +0 -73
  138. package/resources/templates/template-workspace/admin/vite-env.d.ts +0 -7
  139. package/resources/templates/template-workspace/scripts/generate-client.sh +0 -8
  140. /package/resources/templates/{template-workspace → default}/.github/scripts/setup-actions-variables.sh +0 -0
  141. /package/resources/templates/{template-workspace → default}/.github/workflows/deploy.yaml +0 -0
  142. /package/resources/templates/{template-workspace → default}/admin/app/components/logo.tsx +0 -0
  143. /package/resources/templates/{template-workspace → default}/admin/app/config.ts +0 -0
  144. /package/resources/templates/{template-workspace → default}/admin/app/index.html +0 -0
  145. /package/resources/templates/{template-workspace → default}/admin/app/pages/index.tsx +0 -0
  146. /package/resources/templates/{template-workspace → default}/admin/lib/binding/binding.tsx +0 -0
  147. /package/resources/templates/{template-workspace → default}/admin/lib/binding/delete.tsx +0 -0
  148. /package/resources/templates/{template-workspace → default}/admin/lib/binding/hooks.tsx +0 -0
  149. /package/resources/templates/{template-workspace → default}/admin/lib/binding/identity.tsx +0 -0
  150. /package/resources/templates/{template-workspace → default}/admin/lib/binding/index.ts +0 -0
  151. /package/resources/templates/{template-workspace → default}/admin/lib/binding/navigation-guard-dialog.tsx +0 -0
  152. /package/resources/templates/{template-workspace → default}/admin/lib/binding/persist.tsx +0 -0
  153. /package/resources/templates/{template-workspace → default}/admin/lib/block-repeater/index.ts +0 -0
  154. /package/resources/templates/{template-workspace → default}/admin/lib/board/index.ts +0 -0
  155. /package/resources/templates/{template-workspace → default}/admin/lib/buttons/back-button.tsx +0 -0
  156. /package/resources/templates/{template-workspace → default}/admin/lib/buttons/index.ts +0 -0
  157. /package/resources/templates/{template-workspace → default}/admin/lib/buttons/link-back-button.tsx +0 -0
  158. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/column-leaf.tsx +0 -0
  159. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/export.tsx +0 -0
  160. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/boolean.tsx +0 -0
  161. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/common.tsx +0 -0
  162. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/defined.tsx +0 -0
  163. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/index.ts +0 -0
  164. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/mobile.tsx +0 -0
  165. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/number.tsx +0 -0
  166. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/filters/text.tsx +0 -0
  167. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/grid.tsx +0 -0
  168. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/index.ts +0 -0
  169. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/labels.tsx +0 -0
  170. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/layout-switcher.tsx +0 -0
  171. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/loader.tsx +0 -0
  172. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/tiles.tsx +0 -0
  173. /package/resources/templates/{template-workspace → default}/admin/lib/datagrid/toolbar.tsx +0 -0
  174. /package/resources/templates/{template-workspace → default}/admin/lib/dev/index.ts +0 -0
  175. /package/resources/templates/{template-workspace → default}/admin/lib/dev/login-panel.tsx +0 -0
  176. /package/resources/templates/{template-workspace → default}/admin/lib/dev/todo.tsx +0 -0
  177. /package/resources/templates/{template-workspace → default}/admin/lib/dict.ts +0 -0
  178. /package/resources/templates/{template-workspace → default}/admin/lib/dimensions/index.ts +0 -0
  179. /package/resources/templates/{template-workspace → default}/admin/lib/editor/block-editor.tsx +0 -0
  180. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/baseEditorPlugins.tsx +0 -0
  181. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/buttons.tsx +0 -0
  182. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/editor-editable-canvas.tsx +0 -0
  183. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/AnchorRenderer.tsx +0 -0
  184. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/HeadingRenderer.tsx +0 -0
  185. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/HorizontalRuleRenderer.tsx +0 -0
  186. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/ListItemRenderer.tsx +0 -0
  187. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/OrderedListRenderer.tsx +0 -0
  188. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/ParagraphRenderer.tsx +0 -0
  189. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/ScrollTargetRenderer.tsx +0 -0
  190. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/TableElementRenderer.tsx +0 -0
  191. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/TableRowElementRenderer.tsx +0 -0
  192. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/elements/UnorderedListRenderer.tsx +0 -0
  193. /package/resources/templates/{template-workspace → default}/admin/lib/editor/common/index.ts +0 -0
  194. /package/resources/templates/{template-workspace → default}/admin/lib/editor/index.ts +0 -0
  195. /package/resources/templates/{template-workspace → default}/admin/lib/editor/plugins.tsx +0 -0
  196. /package/resources/templates/{template-workspace → default}/admin/lib/editor/rich-text-view.tsx +0 -0
  197. /package/resources/templates/{template-workspace → default}/admin/lib/editor/rich-text.tsx +0 -0
  198. /package/resources/templates/{template-workspace → default}/admin/lib/errors/error-boundary.tsx +0 -0
  199. /package/resources/templates/{template-workspace → default}/admin/lib/errors/index.ts +0 -0
  200. /package/resources/templates/{template-workspace → default}/admin/lib/errors/use-error-formatter.ts +0 -0
  201. /package/resources/templates/{template-workspace → default}/admin/lib/field/formatted-field.tsx +0 -0
  202. /package/resources/templates/{template-workspace → default}/admin/lib/field/index.ts +0 -0
  203. /package/resources/templates/{template-workspace → default}/admin/lib/form/index.ts +0 -0
  204. /package/resources/templates/{template-workspace → default}/admin/lib/form/inputs.tsx +0 -0
  205. /package/resources/templates/{template-workspace → default}/admin/lib/form/labels.tsx +0 -0
  206. /package/resources/templates/{template-workspace → default}/admin/lib/form/select.tsx +0 -0
  207. /package/resources/templates/{template-workspace → default}/admin/lib/form/ui.tsx +0 -0
  208. /package/resources/templates/{template-workspace → default}/admin/lib/form/upload-repeaters.tsx +0 -0
  209. /package/resources/templates/{template-workspace → default}/admin/lib/form/upload.tsx +0 -0
  210. /package/resources/templates/{template-workspace → default}/admin/lib/formatting/formatting.ts +0 -0
  211. /package/resources/templates/{template-workspace → default}/admin/lib/formatting/index.ts +0 -0
  212. /package/resources/templates/{template-workspace → default}/admin/lib/images/formatImageResizeUrl.ts +0 -0
  213. /package/resources/templates/{template-workspace → default}/admin/lib/images/index.ts +0 -0
  214. /package/resources/templates/{template-workspace → default}/admin/lib/labels/enum-labels.ts +0 -0
  215. /package/resources/templates/{template-workspace → default}/admin/lib/labels/field-labels.ts +0 -0
  216. /package/resources/templates/{template-workspace → default}/admin/lib/labels/index.ts +0 -0
  217. /package/resources/templates/{template-workspace → default}/admin/lib/layout/index.ts +0 -0
  218. /package/resources/templates/{template-workspace → default}/admin/lib/layout/layout.tsx +0 -0
  219. /package/resources/templates/{template-workspace → default}/admin/lib/layout/slots.tsx +0 -0
  220. /package/resources/templates/{template-workspace → default}/admin/lib/outdated-application-dialog/index.ts +0 -0
  221. /package/resources/templates/{template-workspace → default}/admin/lib/outdated-application-dialog/outdated-application-dialog.tsx +0 -0
  222. /package/resources/templates/{template-workspace → default}/admin/lib/repeater/index.ts +0 -0
  223. /package/resources/templates/{template-workspace → default}/admin/lib/select/create-new.tsx +0 -0
  224. /package/resources/templates/{template-workspace → default}/admin/lib/select/filter.tsx +0 -0
  225. /package/resources/templates/{template-workspace → default}/admin/lib/select/highlight.tsx +0 -0
  226. /package/resources/templates/{template-workspace → default}/admin/lib/select/index.ts +0 -0
  227. /package/resources/templates/{template-workspace → default}/admin/lib/select/list.tsx +0 -0
  228. /package/resources/templates/{template-workspace → default}/admin/lib/select/multi-select.tsx +0 -0
  229. /package/resources/templates/{template-workspace → default}/admin/lib/select/select.tsx +0 -0
  230. /package/resources/templates/{template-workspace → default}/admin/lib/select/sortable-select.tsx +0 -0
  231. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/change-my-password.tsx +0 -0
  232. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/create-api-key.tsx +0 -0
  233. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/index.ts +0 -0
  234. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/invite.tsx +0 -0
  235. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/login.tsx +0 -0
  236. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/password-reset-request.tsx +0 -0
  237. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/password-reset.tsx +0 -0
  238. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/passwordless-signin-init.tsx +0 -0
  239. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/passwordless-signin.tsx +0 -0
  240. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/forms/update-project-member.tsx +0 -0
  241. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/hooks/useInvite.ts +0 -0
  242. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/hooks/useInviteUser.tsx +0 -0
  243. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/index.ts +0 -0
  244. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/listing/api-key-list.tsx +0 -0
  245. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/listing/index.ts +0 -0
  246. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/listing/member-delete-dialog.tsx +0 -0
  247. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/listing/member-list.tsx +0 -0
  248. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/listing/person-list.tsx +0 -0
  249. /package/resources/templates/{template-workspace → default}/admin/lib/tenant/otp/index.ts +0 -0
  250. /package/resources/templates/{template-workspace → default}/admin/lib/toast/index.ts +0 -0
  251. /package/resources/templates/{template-workspace → default}/admin/lib/toast/toaster.tsx +0 -0
  252. /package/resources/templates/{template-workspace → default}/admin/lib/ui/alert-dialog.tsx +0 -0
  253. /package/resources/templates/{template-workspace → default}/admin/lib/ui/avatar.tsx +0 -0
  254. /package/resources/templates/{template-workspace → default}/admin/lib/ui/collapsible.tsx +0 -0
  255. /package/resources/templates/{template-workspace → default}/admin/lib/ui/divider.tsx +0 -0
  256. /package/resources/templates/{template-workspace → default}/admin/lib/ui/label.tsx +0 -0
  257. /package/resources/templates/{template-workspace → default}/admin/lib/ui/loader.tsx +0 -0
  258. /package/resources/templates/{template-workspace → default}/admin/lib/ui/menu.tsx +0 -0
  259. /package/resources/templates/{template-workspace → default}/admin/lib/ui/progress.tsx +0 -0
  260. /package/resources/templates/{template-workspace → default}/admin/lib/ui/scroll-area.tsx +0 -0
  261. /package/resources/templates/{template-workspace → default}/admin/lib/ui/separator.tsx +0 -0
  262. /package/resources/templates/{template-workspace → default}/admin/lib/ui/skeleton.tsx +0 -0
  263. /package/resources/templates/{template-workspace → default}/admin/lib/ui/toggle-group.tsx +0 -0
  264. /package/resources/templates/{template-workspace → default}/admin/lib/upload/dropzone.tsx +0 -0
  265. /package/resources/templates/{template-workspace → default}/admin/lib/upload/index.ts +0 -0
  266. /package/resources/templates/{template-workspace → default}/admin/lib/upload/repeater.tsx +0 -0
  267. /package/resources/templates/{template-workspace → default}/admin/lib/utils/cn.ts +0 -0
  268. /package/resources/templates/{template-workspace → default}/admin/lib/utils/createComponentOpenHooks.tsx +0 -0
  269. /package/resources/templates/{template-workspace → default}/admin/lib/utils/index.ts +0 -0
  270. /package/resources/templates/{template-workspace → default}/admin/lib/utils/use-mobile.ts +0 -0
  271. /package/resources/templates/{template-workspace → default}/admin/public/favicon.png +0 -0
  272. /package/resources/templates/{template-workspace → default}/api/index.ts +0 -0
  273. /package/resources/templates/{template-workspace → default}/api/migrations/.gitkeep +0 -0
  274. /package/resources/templates/{template-workspace → default}/api/model/index.ts +0 -0
  275. /package/resources/templates/{template-workspace → default}/api/package.json +0 -0
  276. /package/resources/templates/{template-workspace → default}/api/tsconfig.json +0 -0
  277. /package/resources/templates/{template-workspace → default}/client/package.json +0 -0
  278. /package/resources/templates/{template-workspace → default}/client/src/index.ts +0 -0
  279. /package/resources/templates/{template-workspace → default}/client/tsconfig.json +0 -0
  280. /package/resources/templates/{template-workspace → default}/docker-compose.yaml +0 -0
  281. /package/resources/templates/{template-workspace → default}/tsconfig.json +0 -0
  282. /package/resources/templates/{template-workspace → default}/tsconfig.settings.json +0 -0
@@ -2,24 +2,24 @@ import { uic, uiconfig } from '../utils'
2
2
 
3
3
  export const inputConfig = uiconfig({
4
4
  baseClass: `
5
- flex w-full bg-background
6
- file:border-0 file:bg-transparent file:text-sm file:font-medium
7
- placeholder:text-muted-foreground
8
- focus-visible:outline-none
9
- disabled:cursor-not-allowed disabled:opacity-50
5
+ flex w-full bg-background-input
6
+ file:border-0 file:bg-transparent file:text-sm file:font-medium
7
+ placeholder:text-muted-foreground
8
+ focus-visible:outline-hidden
9
+ disabled:cursor-not-allowed disabled:opacity-50
10
10
  read-only:bg-gray-100
11
11
  ` /*data-[dirty]:border-yellow-500 focus-visible:data-[dirty]:border-input*/ + `
12
- data-[invalid]:border-destructive data-[invalid]:ring-destructive
12
+ data-[invalid]:border-destructive data-[invalid]:ring-destructive
13
13
  `,
14
14
  variants: {
15
15
  inputSize: {
16
16
  default: 'h-10 rounded-md p-2 text-sm',
17
- sm: 'h-8 rounded p-1 text-sm',
17
+ sm: 'h-8 rounded-sm p-1 text-sm',
18
18
  lg: 'h-12 rounded-lg p-3 text-lg',
19
19
  },
20
20
  variant: {
21
21
  default: 'border border-input ring-offset-background focus-visible:ring-2 focus-visible:ring-ring',
22
- ghost: 'border-transparent border-b focus-visible:ring-transparent rounded-none',
22
+ ghost: 'border-transparent border-b border-gray-200 focus-visible:ring-transparent rounded-none',
23
23
  },
24
24
  },
25
25
  defaultVariants: {
@@ -38,7 +38,7 @@ export const InputLike = uic('div', {
38
38
  flex items-center min-h-10 w-full rounded-md border border-input bg-background p-2 text-sm ring-offset-background max-w-md
39
39
  file:border-0 file:bg-transparent file:text-sm file:font-medium
40
40
  placeholder:text-muted-foreground
41
- focus-within:outline-none focus-within:ring-2 focus-within:ring-ring focus-within:ring-offset-2
41
+ focus-within:outline-hidden focus-within:ring-2 focus-within:ring-ring focus-within:ring-offset-2
42
42
  disabled:cursor-not-allowed
43
43
  disabled:opacity-50
44
44
  `,
@@ -49,7 +49,7 @@ export const InputLike = uic('div', {
49
49
  * without any styling, without ring, border etc; so it must be resetted
50
50
  */
51
51
  export const InputBare = uic('input', {
52
- baseClass: 'w-full h-full focus-visible:outline-none',
52
+ baseClass: 'w-full h-full focus-visible:outline-hidden',
53
53
  displayName: 'InputBare',
54
54
  })
55
55
 
@@ -63,7 +63,7 @@ export const CheckboxInput = uic('input', {
63
63
 
64
64
  export const RadioInput = uic('input', {
65
65
  baseClass: `
66
- appearance-none bg-white rounded-full w-4 h-4 ring-1 ring-gray-400 hover:ring-gray-600 grid place-items-center
66
+ appearance-none bg-background rounded-full w-4 h-4 ring-1 ring-gray-400 hover:ring-gray-600 grid place-items-center
67
67
  before:rounded-full before:bg-gray-600 before:w-2 before:h-2 before:ring-2 before:ring-white before:content-[''] before:transform before:transition-all before:scale-0 checked:before:scale-100
68
68
  `,
69
69
  })
@@ -18,7 +18,7 @@ export const Overlay = ({ position = 'fixed', className, children, showImmediat
18
18
 
19
19
  return (
20
20
  <div className={cn(
21
- 'z-50 bg-white bg-opacity-50 backdrop-blur-sm transition-all duration-300 delay-200',
21
+ 'z-50 bg-background/50 backdrop-blur-xs transition-all duration-300 delay-200',
22
22
  show ? 'opacity-100' : 'opacity-0',
23
23
  position === 'fixed' && 'w-full h-full fixed top-0 left-0',
24
24
  position === 'absolute' && 'w-full h-full absolute top-0 left-0',
@@ -19,7 +19,7 @@ const PopoverContent = React.forwardRef<
19
19
  align={align}
20
20
  sideOffset={sideOffset}
21
21
  className={cn(
22
- 'z-50 min-w-40 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none',
22
+ 'z-50 min-w-40 rounded-md border border-gray-200 bg-popover p-4 text-popover-foreground shadow-md outline-hidden',
23
23
  'data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
24
24
  className,
25
25
  )}
@@ -2,7 +2,7 @@ import { ReactNode } from 'react'
2
2
  import { uic } from '../utils'
3
3
 
4
4
  export const PropertyList = uic('div', {
5
- baseClass: 'relative overflow-auto bg-gray-50/50 max-w-lg border rounded-md grid grid-cols-[max-content,1fr]',
5
+ baseClass: 'relative overflow-auto bg-gray-50/50 max-w-lg border border-gray-200 rounded-md grid grid-cols-[max-content_1fr]',
6
6
  displayName: 'PropertyList',
7
7
  })
8
8
 
@@ -11,12 +11,12 @@ export const PropertyRow = uic('div', {
11
11
  })
12
12
 
13
13
  export const PropertyLabel = uic('div', {
14
- baseClass: 'text-sm min-w-32 border-b group-last:border-b-none px-4 py-3',
14
+ baseClass: 'text-sm min-w-32 border-b border-gray-200 group-last:border-b-none px-4 py-3',
15
15
  displayName: 'PropertyLabel',
16
16
  })
17
17
 
18
18
  export const PropertyValue = uic('div', {
19
- baseClass: 'text-sm font-semibold border-b group-last:border-b-none px-4 py-3',
19
+ baseClass: 'text-sm font-semibold border-b border-gray-200 group-last:border-b-none px-4 py-3',
20
20
  displayName: 'PropertyValue',
21
21
  })
22
22
 
@@ -11,7 +11,7 @@ export const SelectValue = SelectPrimitive.Value
11
11
 
12
12
  export const SelectTrigger = uic(SelectPrimitive.Trigger, {
13
13
  baseClass:
14
- 'flex gap-1 h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1',
14
+ 'flex gap-1 h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1',
15
15
  afterChildren: (
16
16
  <SelectPrimitive.Icon asChild>
17
17
  <ChevronDown className="h-4 w-4 opacity-50" />
@@ -34,7 +34,7 @@ export const SelectScrollDownButton = uic(SelectPrimitive.ScrollDownButton, {
34
34
 
35
35
  export const SelectContent = uic(SelectPrimitive.Content, {
36
36
  baseClass:
37
- 'relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
37
+ 'relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border border-gray-200 bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
38
38
  displayName: SelectPrimitive.Content.displayName,
39
39
  variants: {
40
40
  position: {
@@ -63,7 +63,7 @@ export const SelectLabel = uic(SelectPrimitive.Label, {
63
63
 
64
64
  export const SelectItem = uic(SelectPrimitive.Item, {
65
65
  baseClass:
66
- 'relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50',
66
+ 'relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-hidden focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50',
67
67
  beforeChildren: (
68
68
  <span className="absolute left-2 flex h-3.5 w-3.5 items-center justify-center">
69
69
  <SelectPrimitive.ItemIndicator>
@@ -21,9 +21,9 @@ export const SheetContent = uic(SheetPrimitive.Content, {
21
21
  baseClass: 'fixed z-50 gap-4 bg-background p-6 shadow-lg overflow-auto transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500',
22
22
  variants: {
23
23
  side: {
24
- top: 'inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top',
25
- bottom: 'inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom',
26
- left: 'inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm',
24
+ top: 'inset-x-0 top-0 border-b border-gray-200 data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top',
25
+ bottom: 'inset-x-0 bottom-0 border-t border-gray-200 data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom',
26
+ left: 'inset-y-0 left-0 h-full w-3/4 border-r border-gray-200 data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm',
27
27
  right: 'inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm',
28
28
  },
29
29
  },
@@ -35,7 +35,7 @@ export const SheetContent = uic(SheetPrimitive.Content, {
35
35
  <SheetPortal>
36
36
  {/*<SheetOverlay />*/}
37
37
  {props.children}
38
- <SheetPrimitive.Close className="absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary">
38
+ <SheetPrimitive.Close className="absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-hidden focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary">
39
39
  <XIcon className="h-4 w-4" />
40
40
  <span className="sr-only">Close</span>
41
41
  </SheetPrimitive.Close>
@@ -116,10 +116,9 @@ export const SidebarProvider = ({
116
116
  SidebarProvider.displayName = 'SidebarProvider'
117
117
 
118
118
  export const SidebarLayout = uic('div', {
119
- baseClass: 'group/sidebar-wrapper grid min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar max-h-screen max-w-[100vw] overflow-y-auto',
119
+ baseClass: 'group/sidebar-wrapper grid min-h-svh w-full has-[[data-variant=inset]]:bg-sidebar max-h-screen max-w-[100vw] overflow-y-auto md:grid-cols-[auto_1fr_auto]',
120
120
  // Add grid template columns
121
121
  style: {
122
- 'gridTemplateColumns': 'auto 1fr auto', // This creates two columns: one for sidebar, one for content
123
122
  '--sidebar-width': SIDEBAR_WIDTH,
124
123
  '--sidebar-width-large': SIDEBAR_WIDTH_LARGE,
125
124
  '--sidebar-width-icon': SIDEBAR_WIDTH_ICON,
@@ -140,7 +139,7 @@ export const SidebarInset = uic('main', {
140
139
 
141
140
  export const SidebarInsetHeader = uic('header', {
142
141
  baseClass: [
143
- 'bg-background z-50 flex justify-between h-16 shrink-0 items-center gap-2 border-b mb-4',
142
+ 'bg-background z-50 flex justify-between h-16 shrink-0 items-center gap-2 border-b border-gray-200',
144
143
  'transition-[width,height] ease-linear',
145
144
  'group-has-[[data-collapsible=icon]]/sidebar-wrapper:h-12',
146
145
  ],
@@ -148,7 +147,7 @@ export const SidebarInsetHeader = uic('header', {
148
147
  })
149
148
 
150
149
  export const SidebarInsetContent = uic('div', {
151
- baseClass: 'overflow-y-auto px-4',
150
+ baseClass: 'overflow-y-auto p-4',
152
151
  displayName: 'SidebarInsetContent',
153
152
  })
154
153
 
@@ -158,13 +157,13 @@ export const SidebarInsetHeaderActions = uic('div', {
158
157
  })
159
158
 
160
159
  const SidebarNone = uic('div', {
161
- baseClass: 'flex h-full w-[--sidebar-width] 2xl:w-[--sidebar-width-large] flex-col bg-sidebar text-sidebar-foreground',
160
+ baseClass: 'flex h-full w-(--sidebar-width) 2xl:w-(--sidebar-width-large) flex-col bg-sidebar text-sidebar-foreground',
162
161
  displayName: 'SidebarNone',
163
162
  })
164
163
 
165
164
  const SidebarDesktopGap = uic('div', {
166
165
  baseClass: [
167
- 'duration-200 relative w-[--sidebar-width] 2xl:w-[--sidebar-width-large] bg-transparent transition-[width] ease-linear',
166
+ 'duration-200 relative w-(--sidebar-width) 2xl:w-(--sidebar-width-large) bg-transparent transition-[width] ease-linear',
168
167
  'group-data-[collapsible=offcanvas]:w-0',
169
168
  'group-data-[side=right]:rotate-180',
170
169
  ],
@@ -172,7 +171,7 @@ const SidebarDesktopGap = uic('div', {
172
171
  variant: {
173
172
  floating: 'group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4))] 2xl:group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon-large)_+_theme(spacing.4))]',
174
173
  inset: 'group-data-[collapsible=icon]:w-5',
175
- sidebar: 'group-data-[collapsible=icon]:w-[--sidebar-width-icon] 2xl:group-data-[collapsible=icon]:w-[--sidebar-width-icon-large]',
174
+ sidebar: 'group-data-[collapsible=icon]:w-(--sidebar-width-icon) 2xl:group-data-[collapsible=icon]:w-(--sidebar-width-icon-large)',
176
175
  },
177
176
  },
178
177
  displayName: 'SidebarDesktopGap',
@@ -186,9 +185,9 @@ const SidebarInner = uic('div', {
186
185
  right: 'right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)] 2xl:group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width-large)*-1)]',
187
186
  },
188
187
  variant: {
189
- floating: 'p-2 w-[--sidebar-width] 2xl:w-[--sidebar-width-large] group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)] 2xl:group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon-large)_+_theme(spacing.4)_+2px)]',
190
- inset: 'p-2 w-[--sidebar-width] 2xl:w-[--sidebar-width-large] group-data-[collapsible=icon]:w-5',
191
- sidebar: 'w-[--sidebar-width] 2xl:w-[--sidebar-width-large] group-data-[collapsible=icon]:w-[--sidebar-width-icon] group-data-[side=left]:border-r group-data-[side=right]:border-l 2xl:group-data-[collapsible=icon]:w-[--sidebar-width-icon-large]',
188
+ floating: 'p-2 w-(--sidebar-width) 2xl:w-(--sidebar-width-large) group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)_+_theme(spacing.4)_+2px)] 2xl:group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon-large)_+_theme(spacing.4)_+2px)]',
189
+ inset: 'p-2 w-(--sidebar-width) 2xl:w-(--sidebar-width-large) group-data-[collapsible=icon]:w-5',
190
+ sidebar: 'w-(--sidebar-width) 2xl:w-(--sidebar-width-large) group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=left]:border-gray-200 group-data-[side=right]:border-l 2xl:group-data-[collapsible=icon]:w-(--sidebar-width-icon-large)',
192
191
  },
193
192
  },
194
193
  variantsAsDataAttrs: ['variant', 'side'],
@@ -223,7 +222,7 @@ export const Sidebar = forwardRef<HTMLDivElement, SidebarProps>(
223
222
  <SheetContent
224
223
  data-sidebar="sidebar"
225
224
  data-mobile={dataAttribute(true)}
226
- className="w-[--sidebar-width] 2xl:w-[--sidebar-width-large] bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden"
225
+ className="w-(--sidebar-width) 2xl:w-(--sidebar-width-large) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden"
227
226
  style={{ '--sidebar-width': SIDEBAR_WIDTH_MOBILE } as CSSProperties}
228
227
  side={side}
229
228
  >
@@ -349,7 +348,7 @@ export const SidebarGroup = uic('div', {
349
348
 
350
349
  export const SidebarGroupLabel = uic('div', {
351
350
  baseClass: [
352
- 'duration-200 flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-none ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0',
351
+ 'duration-200 flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium text-sidebar-foreground/70 outline-hidden ring-sidebar-ring transition-[margin,opa] ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0',
353
352
  'group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0',
354
353
  ],
355
354
  defaultProps: {
@@ -360,7 +359,7 @@ export const SidebarGroupLabel = uic('div', {
360
359
 
361
360
  export const SidebarGroupAction = uic('button', {
362
361
  baseClass: [
363
- 'absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0',
362
+ 'absolute right-3 top-3.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-hidden ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0',
364
363
  // Increases the hit area of the button on mobile.
365
364
  'after:absolute after:-inset-2 after:md:hidden',
366
365
  'group-data-[collapsible=icon]:hidden',
@@ -397,7 +396,7 @@ export const SidebarMenuItem = uic('li', {
397
396
 
398
397
  export const sidebarMenuButtonVariants = cva(
399
398
  [
400
- 'peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-none ring-sidebar-ring',
399
+ 'peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden ring-sidebar-ring',
401
400
  'transition-[width,height,padding]',
402
401
  'hover:bg-sidebar-accent hover:text-sidebar-accent-foreground',
403
402
  'focus-visible:ring-2',
@@ -483,7 +482,7 @@ SidebarMenuButton.displayName = 'SidebarMenuButton'
483
482
 
484
483
  export const SidebarMenuAction = uic('button', {
485
484
  baseClass: [
486
- 'absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-none ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2',
485
+ 'absolute right-1 top-1.5 flex aspect-square w-5 items-center justify-center rounded-md p-0 text-sidebar-foreground outline-hidden ring-sidebar-ring transition-transform hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2',
487
486
  'peer-hover/menu-button:text-sidebar-accent-foreground',
488
487
  '[&>svg]:size-4 [&>svg]:shrink-0',
489
488
  // Increases the hit area of the button on mobile.
@@ -541,7 +540,7 @@ export const SidebarMenuSkeleton = forwardRef<HTMLDivElement, SidebarMenuSkeleto
541
540
  {showIcon && <Skeleton className="size-4 rounded-md" data-sidebar="menu-skeleton-icon" />}
542
541
  <Skeleton
543
542
  style={{ '--skeleton-width': width } as CSSProperties}
544
- className="h-4 flex-1 max-w-[--skeleton-width]"
543
+ className="h-4 flex-1 max-w-(--skeleton-width)"
545
544
  data-sidebar="menu-skeleton-text"
546
545
  />
547
546
  </div>
@@ -1,7 +1,7 @@
1
1
  import { uic } from '../utils'
2
2
 
3
3
  export const DropIndicator = uic('div', {
4
- baseClass: 'bg-blue-300 rounded shadow-lg shadow-blue-700 absolute',
4
+ baseClass: 'bg-blue-300 rounded-sm shadow-lg shadow-blue-700 absolute',
5
5
  variants: {
6
6
  placement: {
7
7
  top: 'w-full h-1 -top-1',
@@ -3,7 +3,7 @@ import * as React from 'react'
3
3
  import { uic } from '../utils'
4
4
 
5
5
  export const Switch = uic(SwitchPrimitives.Root, {
6
- baseClass: 'peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-sm transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input',
6
+ baseClass: 'peer inline-flex h-5 w-9 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent shadow-xs transition-colors focus-visible:outline-hidden focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input',
7
7
  afterChildren:
8
8
  <SwitchPrimitives.Thumb className="pointer-events-none block h-4 w-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0" />,
9
9
  })
@@ -11,7 +11,7 @@ export const Table = uic('table', {
11
11
  })
12
12
 
13
13
  export const TableHeader = uic('thead', {
14
- baseClass: '[&_tr]:border-b',
14
+ baseClass: '[&_tr]:border-b border-gray-200',
15
15
  displayName: 'TableHeader',
16
16
  })
17
17
 
@@ -21,12 +21,12 @@ export const TableBody = uic('tbody', {
21
21
  })
22
22
 
23
23
  export const TableFooter = uic('tfoot', {
24
- baseClass: 'border-t bg-muted/50 font-medium [&>tr]:last:border-b-0',
24
+ baseClass: 'border-t border-gray-200 bg-muted/50 font-medium [&>tr]:last:border-b-0',
25
25
  displayName: 'TableFooter',
26
26
  })
27
27
 
28
28
  export const TableRow = uic('tr', {
29
- baseClass: 'border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted',
29
+ baseClass: 'border-b border-gray-200 transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted',
30
30
  displayName: 'TableRow',
31
31
  })
32
32
 
@@ -4,9 +4,9 @@ import { ComponentProps, forwardRef, useRef } from 'react'
4
4
 
5
5
  export const Textarea = uic('textarea', {
6
6
  baseClass: `
7
- w-full bg-background rounded-md border border-input px-3 py-2 text-sm shadow-sm
8
- placeholder:text-muted-foreground
9
- focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring
7
+ w-full bg-background rounded-md border border-input px-3 py-2 text-sm shadow-xs
8
+ placeholder:text-muted-foreground
9
+ focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring
10
10
  disabled:cursor-not-allowed disabled:opacity-50
11
11
  read-only:bg-gray-100
12
12
  ` /*data-[dirty]:border-yellow-500 focus-visible:data-[dirty]:border-input*/ + `
@@ -2,12 +2,12 @@ import * as TogglePrimitive from '@radix-ui/react-toggle'
2
2
  import { ConfigVariants, uic, uiconfig } from '../utils'
3
3
 
4
4
  export const toggleConfig = uiconfig({
5
- baseClass: 'inline-flex items-center justify-center rounded-md text-sm font-medium transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent data-[active]:shadow-inner data-[active]:text-accent-foreground',
5
+ baseClass: 'inline-flex items-center justify-center rounded-md text-sm font-medium transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-hidden focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[active]:bg-accent data-[active]:shadow-inner data-[active]:text-accent-foreground',
6
6
  variants: {
7
7
  variant: {
8
8
  default: 'bg-transparent',
9
9
  outline:
10
- 'border border-input bg-transparent shadow-sm hover:bg-accent hover:text-accent-foreground',
10
+ 'border border-input bg-transparent shadow-xs hover:bg-accent hover:text-accent-foreground',
11
11
  },
12
12
  size: {
13
13
  default: 'h-8 px-3',
@@ -25,4 +25,3 @@ export type ToggleProps = ConfigVariants<Exclude<typeof toggleConfig.variants, u
25
25
 
26
26
 
27
27
  export const Toggle = uic(TogglePrimitive.Root, toggleConfig)
28
-
@@ -12,8 +12,8 @@ export const TooltipContent = uic(TooltipPrimitive.Content, {
12
12
  baseClass: 'z-50 overflow-hidden p-2 text-sm text-popover-foreground animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2',
13
13
  variants: {
14
14
  variant: {
15
- default: 'rounded-md border bg-popover shadow-md',
16
- blurred: 'rounded-md backdrop-blur shadow-md border',
15
+ default: 'rounded-md border border-gray-200 bg-popover shadow-md',
16
+ blurred: 'rounded-md backdrop-blur-sm shadow-md border border-gray-200',
17
17
  seamless: '',
18
18
  },
19
19
  },
@@ -3,9 +3,9 @@ import { Loader } from '../ui/loader'
3
3
  import { GripIcon } from 'lucide-react'
4
4
  import { uic } from '../utils/uic'
5
5
 
6
- export const UploaderDropzoneWrapperUI = uic('div', { baseClass: 'rounded border p-1 shadow' })
6
+ export const UploaderDropzoneWrapperUI = uic('div', { baseClass: 'rounded-sm border border-gray-200 p-1 shadow-sm' })
7
7
  export const UploaderDropzoneAreaUI = uic('div', {
8
- baseClass: `h-40 w-40 flex flex-col gap-1 justify-center items-center py-4 border-dashed border-2 border-gray-300 rounded relative
8
+ baseClass: `h-40 w-40 flex flex-col gap-1 justify-center items-center py-4 border-dashed border-2 border-gray-300 rounded-sm relative
9
9
  transition-colors
10
10
  hover:border-gray-300 hover:bg-gray-50 hover:cursor-pointer
11
11
  data-[dropzone-accept]:border-green-500 group-data-[dropzone-accept]:bg-green-100
@@ -23,7 +23,7 @@ export const UploaderDropzoneAreaUI = uic('div', {
23
23
 
24
24
 
25
25
  export const UploaderItemUI = uic('div', {
26
- baseClass: 'rounded border p-1 shadow bg-gray-100 flex gap-2 relative',
26
+ baseClass: 'rounded-sm border border-gray-200 p-1 shadow-sm bg-gray-100 flex gap-2 relative',
27
27
  })
28
28
 
29
29
 
@@ -37,7 +37,7 @@ export const UploaderRepeaterItemsWrapperUI = uic('div', {
37
37
  })
38
38
  export const UploaderRepeaterItemUI = UploaderItemUI
39
39
  export const UploaderRepeaterDragOverlayUI = uic('div', {
40
- baseClass: 'rounded border border-gray-300 p-4 relative bg-opacity-60 bg-gray-100 backdrop-blur-sm',
40
+ baseClass: 'rounded-sm border border-gray-300 p-4 relative bg-gray-100/60 backdrop-blur-xs',
41
41
  })
42
42
  export const UploaderRepeaterHandleUI = uic('button', {
43
43
  baseClass: 'absolute top-0 left-0 h-6 w-6 inline-flex justify-center align-center opacity-10 hover:opacity-100 transition-opacity z-10',
@@ -45,7 +45,7 @@ export const UploaderFileProgressUI = ({ file, progress, info, actions }: { file
45
45
  const extension = file.name.split('.').pop()?.toUpperCase()
46
46
 
47
47
  return (
48
- <div className="border-t p-2 flex-1">
48
+ <div className="border-t border-gray-200 p-2 flex-1">
49
49
  <div className="flex items-center gap-2">
50
50
  <div className="relative">
51
51
  <FileIcon className="w-10 h-10 text-gray-400" />
@@ -130,7 +130,7 @@ export const UploadedAnyView = Component<UploadedAnyViewProps>(({ DestroyAction,
130
130
  const AnyFilePreview = Component(({ urlField, fileNameField }: FileUrlDataExtractorProps & GenericFileMetadataExtractorProps) => <>
131
131
  <FieldView<string> field={urlField} render={({ value: url }) => (
132
132
  url ? <a href={url ?? '#'} target="_blank" rel="noreferrer"
133
- className="text-blue-600 hover:text-blue-700 underline overflow-hidden whitespace-nowrap overflow-ellipsis flex flex-col group/anchor flex-1 items-center justify-center">
133
+ className="text-blue-600 hover:text-blue-700 underline overflow-hidden whitespace-nowrap text-ellipsis flex flex-col group/anchor flex-1 items-center justify-center">
134
134
  <FileIcon className="h-16 w-16 text-gray-400 group-hover/anchor:text-gray-500 transition-all" />
135
135
  {fileNameField ? <span><Field field={fileNameField} /></span> : null}
136
136
  </a> : null)} />
@@ -154,7 +154,7 @@ const Metadata = Component(({ children, urlField, fileSizeField, fileNameField,
154
154
  <MetaField field={lastModifiedField} label="Date:" format={formatDate} />
155
155
  <MetaField field={urlField} label="URL:" format={url => (
156
156
  <a href={url} target="_blank" rel="noreferrer"
157
- className="text-blue-600 underline overflow-hidden whitespace-nowrap overflow-ellipsis">
157
+ className="text-blue-600 underline overflow-hidden whitespace-nowrap text-ellipsis">
158
158
  {url.replace(/^(.{15}).*(.{15})$/, '$1…$2')}
159
159
  </a>
160
160
  )} />
@@ -191,7 +191,7 @@ const FileActions = Component(({ DestroyAction, metadata, actions, edit, baseFie
191
191
  metadata?: ReactNode
192
192
  } & BaseFileViewProps) => {
193
193
  return (
194
- <div className="absolute -top-2 -right-1 p-0.5 bg-gray-200 border border-gray-300 rounded shadow flex gap-2 opacity-0 transition-opacity group-hover:opacity-100">
194
+ <div className="absolute -top-2 -right-1 p-0.5 bg-gray-200 border border-gray-300 rounded-sm shadow-sm flex gap-2 opacity-0 transition-opacity group-hover:opacity-100">
195
195
  {actions}
196
196
  {edit && <Popover>
197
197
  <PopoverTrigger asChild>
@@ -2,9 +2,9 @@ import { dataAttribute } from '@contember/utilities'
2
2
  import { Slot } from '@radix-ui/react-slot'
3
3
  import { cva } from 'class-variance-authority'
4
4
  import { ClassValue, clsx } from 'clsx'
5
- import * as React from 'react'
6
- import { ComponentType, ReactElement, ReactNode } from 'react'
5
+ import { ComponentType, createElement, forwardRef, ReactNode, useMemo } from 'react'
7
6
  import { twMerge } from 'tailwind-merge'
7
+ import { useObjectMemo } from '@contember/react-utils'
8
8
 
9
9
  type StringToBoolean<T> = T extends 'true' | 'false' ? boolean : T
10
10
  type ConfigSchema = Record<string, Record<string, ClassValue>>
@@ -33,8 +33,8 @@ type Config<T extends ConfigSchema | undefined, El extends React.ElementType> =
33
33
  displayName?: string
34
34
  wrapOuter?: ComponentType<{ children?: ReactNode } & ConfigVariants<T>>
35
35
  wrapInner?: ComponentType<{ children?: ReactNode } & ConfigVariants<T>>
36
- beforeChildren?: ReactElement
37
- afterChildren?: ReactElement
36
+ beforeChildren?: ReactNode
37
+ afterChildren?: ReactNode
38
38
  style?: React.CSSProperties
39
39
  }
40
40
 
@@ -42,70 +42,77 @@ export const uiconfig = <T extends ConfigSchema | undefined>(config: Config<T, C
42
42
 
43
43
  export type NoInfer<T> = T & { [K in keyof T]: T[K] }
44
44
 
45
- const falsyToString = (value: any) => typeof value === 'boolean' ? `${value}` : value === 0 ? '0' : value
46
45
  export const uic = <El extends React.ElementType, Variants extends ConfigSchema | undefined = undefined>(Component: El, config: Config<Variants, NoInfer<El>>) => {
47
46
  const cls = cva<any>(config?.baseClass as any, {
48
47
  variants: config?.variants,
49
48
  defaultVariants: config?.defaultVariants,
50
49
  compoundVariants: config?.compoundVariants,
51
50
  })
51
+ const passVariantProps = config?.passVariantProps ? new Set(config.passVariantProps) : undefined
52
52
 
53
- const component = React.forwardRef<React.ElementRef<El>, React.ComponentProps<El> & {
53
+ const component = forwardRef<React.ElementRef<El>, React.ComponentProps<El> & {
54
54
  asChild?: boolean
55
- children?: React.ReactNode
55
+ children?: ReactNode
56
56
  className?: string
57
57
  } & ConfigVariants<Variants>>((props, ref) => {
58
58
  const { className: classNameProp, children: childrenBase, ...rest } = props
59
59
 
60
+ const variants: Record<string, string> = {}
61
+
60
62
  for (const key in config?.variants) {
61
- if (key in rest && !config?.passVariantProps?.includes(key)) {
63
+ variants[key] = (rest as any)[key]
64
+ if (key in rest && !passVariantProps?.has(key)) {
62
65
  delete (rest as any)[key]
63
66
  }
64
67
  }
65
68
 
69
+ const variantsMemoized = useObjectMemo(variants)
70
+
66
71
  const dataAttrs: Partial<Record<DataAttr<Variants>, DataAttrValue>> = {}
67
72
  if (config?.variantsAsDataAttrs && config.variants) {
68
73
  for (const key of config.variantsAsDataAttrs) {
69
74
  const keyAsString = key.toString()
70
- const variantValue = rest[key as any] ?? falsyToString(config.defaultVariants?.[key])
75
+ const variantValue = rest[key as any] ?? (config.defaultVariants?.[key] as string | null | undefined | boolean)
71
76
 
72
77
  dataAttrs[`data-${keyAsString}` as DataAttr<Variants>] = dataAttribute(variantValue)
73
78
  }
74
79
  }
80
+ const style = useMemo(() => config?.style ? { ...config.style, ...(rest.style || {}) } : rest.style, [rest.style])
81
+ const finalClassName = useMemo(() => twMerge(clsx(cls(variantsMemoized), classNameProp)), [variantsMemoized, classNameProp])
75
82
 
76
- let Comp: React.ElementType = Component
83
+ let FinalComponent: React.ElementType = Component
77
84
  if (props.asChild && typeof Component === 'string') {
78
- Comp = Slot
85
+ FinalComponent = Slot
79
86
  delete (rest as any).asChild
80
87
  }
81
88
 
82
89
  let children = childrenBase
83
90
  if (config?.wrapInner) {
84
- children = React.createElement(config.wrapInner, props as any, children)
91
+ children = createElement(config.wrapInner, props as any, children)
85
92
  }
86
93
 
87
94
  if (config?.beforeChildren || config?.afterChildren) {
88
- children = <>
89
- {config?.beforeChildren}
90
- {children}
91
- {config?.afterChildren}
92
- </>
95
+ children = [
96
+ config?.beforeChildren,
97
+ children,
98
+ config?.afterChildren,
99
+ ]
93
100
  }
94
101
 
95
- const style = config?.style ? { ...config.style, ...(rest.style || {}) } : rest.style
96
102
 
97
- const innerEl =
98
- <Comp
103
+ const innerEl = (
104
+ <FinalComponent
99
105
  ref={ref}
100
- className={twMerge(clsx(cls(props), classNameProp))}
106
+ className={finalClassName}
101
107
  {...(config.defaultProps ?? {})}
102
108
  {...dataAttrs}
103
109
  {...rest}
104
110
  style={style}
105
111
  >
106
112
  {children}
107
- </Comp>
108
- return config?.wrapOuter ? React.createElement(config.wrapOuter, props as any, innerEl) : innerEl
113
+ </FinalComponent>
114
+ )
115
+ return config?.wrapOuter ? createElement(config.wrapOuter, props as any, innerEl) : innerEl
109
116
  })
110
117
  component.displayName = config?.displayName
111
118
 
@@ -9,14 +9,14 @@
9
9
  },
10
10
  "devDependencies": {
11
11
  "@contember/vite-plugin": "{version}",
12
+ "@tailwindcss/postcss": "^4",
12
13
  "@types/react": "^18",
13
14
  "@types/react-dom": "^18",
14
15
  "@vitejs/plugin-react": "^4.2.1",
15
- "autoprefixer": "^10",
16
16
  "postcss": "^8",
17
- "tailwindcss": "^3",
17
+ "tailwindcss": "^4",
18
18
  "tailwindcss-animate": "^1.0.7",
19
- "vite": "^5"
19
+ "vite": "^6"
20
20
  },
21
21
  "dependencies": {
22
22
  "@contember/client-content": "{version}",
@@ -37,6 +37,7 @@
37
37
  "@contember/react-uploader": "{version}",
38
38
  "@contember/react-uploader-dropzone": "{version}",
39
39
  "@radix-ui/react-alert-dialog": "^1.1.2",
40
+ "@radix-ui/react-avatar": "^1.1.3",
40
41
  "@radix-ui/react-dialog": "^1.1.2",
41
42
  "@radix-ui/react-dropdown-menu": "^2.1.2",
42
43
  "@radix-ui/react-label": "^2.1.0",
@@ -45,12 +46,14 @@
45
46
  "@radix-ui/react-progress": "^1.1.0",
46
47
  "@radix-ui/react-scroll-area": "^1.2.0",
47
48
  "@radix-ui/react-select": "^2.1.2",
49
+ "@radix-ui/react-separator": "^1.1.2",
48
50
  "@radix-ui/react-slot": "^1.1.0",
49
51
  "@radix-ui/react-switch": "^1.1.1",
50
52
  "@radix-ui/react-toast": "^1.2.2",
51
53
  "@radix-ui/react-toggle": "^1.1.0",
52
54
  "@radix-ui/react-toggle-group": "^1.1.0",
53
55
  "@radix-ui/react-tooltip": "^1.1.3",
56
+ "@sentry/react": "^8.47.0",
54
57
  "class-variance-authority": "^0.7.0",
55
58
  "clsx": "^2.1.1",
56
59
  "lucide-react": "^0.451.0",
@@ -0,0 +1,5 @@
1
+ export default {
2
+ plugins: {
3
+ '@tailwindcss/postcss': {},
4
+ },
5
+ }
@@ -0,0 +1,26 @@
1
+ import * as Sentry from '@sentry/react'
2
+
3
+ const sentryDsn = import.meta.env.VITE_SENTRY_DSN
4
+ const enableSentry = sentryDsn && import.meta.env.MODE === 'production'
5
+ const projectName = import.meta.env.VITE_CONTEMBER_ADMIN_PROJECT_NAME
6
+
7
+ Sentry.init({
8
+ enabled: enableSentry,
9
+ dsn: sentryDsn,
10
+ integrations: [
11
+ Sentry.browserApiErrorsIntegration(),
12
+ Sentry.browserSessionIntegration(),
13
+ Sentry.browserTracingIntegration(),
14
+ Sentry.captureConsoleIntegration({ levels: ['error'] }),
15
+ Sentry.replayIntegration(),
16
+ ],
17
+ initialScope: {
18
+ tags: {
19
+ environment: import.meta.env.MODE,
20
+ projectName: projectName,
21
+ },
22
+ },
23
+ tracesSampleRate: 1,
24
+ replaysSessionSampleRate: 0,
25
+ replaysOnErrorSampleRate: 1,
26
+ })