@rebasepro/app 0.10.0 → 0.10.1-canary.0a881d4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (128) hide show
  1. package/dist/auth/types.d.ts +2 -1
  2. package/dist/collections/collection_view_config.d.ts +32 -0
  3. package/dist/collections/entity_image_preview.d.ts +2 -0
  4. package/dist/collections/filter-operator-resolution.d.ts +32 -0
  5. package/dist/collections/index.d.ts +8 -0
  6. package/dist/collections/navigation_from_path.d.ts +34 -0
  7. package/dist/collections/navigation_utils.d.ts +20 -0
  8. package/dist/collections/parent_references_from_path.d.ts +7 -0
  9. package/dist/collections/property_presentation.d.ts +20 -0
  10. package/dist/collections/title-property.d.ts +43 -0
  11. package/dist/components/Debug/UIReferenceView.d.ts +10 -3
  12. package/dist/components/LoginView/LoginView.d.ts +1 -1
  13. package/dist/components/RebaseAuth.d.ts +1 -1
  14. package/dist/components/common/types.d.ts +1 -1
  15. package/dist/components/common/useColumnsIds.d.ts +5 -4
  16. package/dist/components/common/useDataTableController.d.ts +3 -3
  17. package/dist/contexts/AnalyticsContext.d.ts +1 -1
  18. package/dist/contexts/AuthControllerContext.d.ts +1 -1
  19. package/dist/contexts/CollectionScopeContext.d.ts +4 -4
  20. package/dist/contexts/ComponentOverrideContext.d.ts +1 -1
  21. package/dist/contexts/CustomizationControllerContext.d.ts +1 -1
  22. package/dist/contexts/DialogsProvider.d.ts +1 -1
  23. package/dist/contexts/UserConfigurationPersistenceContext.d.ts +1 -1
  24. package/dist/core/PluginLifecycleManager.d.ts +1 -1
  25. package/dist/core/PluginProviderStack.d.ts +1 -1
  26. package/dist/core/RebaseProps.d.ts +2 -1
  27. package/dist/hooks/data/delete.d.ts +4 -4
  28. package/dist/hooks/data/save.d.ts +5 -5
  29. package/dist/hooks/data/useCollection.d.ts +2 -2
  30. package/dist/hooks/data/useFetch.d.ts +2 -2
  31. package/dist/hooks/data/useRelationSelector.d.ts +2 -2
  32. package/dist/hooks/useAnalyticsController.d.ts +1 -1
  33. package/dist/hooks/useAuthController.d.ts +2 -1
  34. package/dist/hooks/useAuthSubscription.d.ts +2 -1
  35. package/dist/hooks/useBuildLocalConfigurationPersistence.d.ts +1 -1
  36. package/dist/hooks/useComponentOverride.d.ts +1 -1
  37. package/dist/hooks/useCustomizationController.d.ts +1 -1
  38. package/dist/hooks/useDialogsController.d.ts +1 -1
  39. package/dist/hooks/usePermissions.d.ts +5 -5
  40. package/dist/hooks/useRebaseContext.d.ts +2 -1
  41. package/dist/hooks/useRebaseRegistry.d.ts +1 -1
  42. package/dist/hooks/useSlot.d.ts +1 -1
  43. package/dist/hooks/useSnackbarController.d.ts +1 -1
  44. package/dist/hooks/useStudioBridge.d.ts +2 -1
  45. package/dist/hooks/useUserConfigurationPersistence.d.ts +1 -1
  46. package/dist/i18n/RebaseI18nProvider.d.ts +1 -1
  47. package/dist/index.d.ts +1 -0
  48. package/dist/index.es.js +799 -121
  49. package/dist/index.es.js.map +1 -1
  50. package/dist/locales/de.d.ts +1 -1
  51. package/dist/locales/en.d.ts +1 -1
  52. package/dist/locales/es.d.ts +1 -1
  53. package/dist/locales/fr.d.ts +1 -1
  54. package/dist/locales/hi.d.ts +1 -1
  55. package/dist/locales/it.d.ts +1 -1
  56. package/dist/locales/pt.d.ts +1 -1
  57. package/dist/util/previews.d.ts +10 -5
  58. package/dist/vitePlugin.js +1 -1
  59. package/package.json +9 -7
  60. package/src/auth/types.ts +2 -1
  61. package/src/collections/collection_view_config.ts +57 -0
  62. package/src/collections/entity_image_preview.ts +48 -0
  63. package/src/collections/filter-operator-resolution.ts +81 -0
  64. package/src/collections/index.ts +8 -0
  65. package/src/collections/navigation_from_path.ts +123 -0
  66. package/src/collections/navigation_utils.ts +171 -0
  67. package/src/collections/parent_references_from_path.ts +59 -0
  68. package/src/collections/property_presentation.ts +224 -0
  69. package/src/collections/title-property.ts +264 -0
  70. package/src/components/Debug/UIReferenceView.tsx +31 -27
  71. package/src/components/Debug/collection-views/CardViewDemo.tsx +4 -2
  72. package/src/components/Debug/collection-views/CollectionTableDemo.tsx +2 -2
  73. package/src/components/Debug/collection-views/KanbanBoardDemo.tsx +1 -2
  74. package/src/components/Debug/crm-dashboard/CalendarWidget.tsx +5 -7
  75. package/src/components/Debug/crm-dashboard/CrmDashboardDemo.tsx +14 -20
  76. package/src/components/Debug/crm-dashboard/DashboardMetrics.tsx +7 -9
  77. package/src/components/Debug/crm-dashboard/PipelineOverview.tsx +8 -10
  78. package/src/components/Debug/crm-dashboard/RecentActivity.tsx +25 -27
  79. package/src/components/Debug/crm-dashboard/TaskFilters.tsx +7 -9
  80. package/src/components/Debug/crm-dashboard/TaskTable.tsx +8 -10
  81. package/src/components/LoginView/LoginView.tsx +55 -4
  82. package/src/components/RebaseAuth.tsx +1 -1
  83. package/src/components/common/types.tsx +1 -1
  84. package/src/components/common/useColumnsIds.tsx +24 -23
  85. package/src/components/common/useDataTableController.tsx +4 -4
  86. package/src/contexts/AnalyticsContext.tsx +1 -1
  87. package/src/contexts/AuthControllerContext.tsx +1 -1
  88. package/src/contexts/CollectionScopeContext.tsx +6 -5
  89. package/src/contexts/ComponentOverrideContext.tsx +1 -1
  90. package/src/contexts/CustomizationControllerContext.tsx +1 -1
  91. package/src/contexts/DialogsProvider.tsx +1 -1
  92. package/src/contexts/UserConfigurationPersistenceContext.tsx +1 -1
  93. package/src/core/PluginLifecycleManager.tsx +2 -1
  94. package/src/core/PluginProviderStack.tsx +1 -1
  95. package/src/core/Rebase.tsx +4 -3
  96. package/src/core/RebaseProps.tsx +2 -1
  97. package/src/core/RebaseRouter.tsx +1 -1
  98. package/src/hooks/data/delete.ts +5 -4
  99. package/src/hooks/data/save.ts +6 -5
  100. package/src/hooks/data/useCollection.tsx +3 -2
  101. package/src/hooks/data/useFetch.tsx +4 -3
  102. package/src/hooks/data/useRelationSelector.tsx +3 -2
  103. package/src/hooks/useAnalyticsController.tsx +1 -1
  104. package/src/hooks/useAuthController.tsx +2 -1
  105. package/src/hooks/useAuthSubscription.ts +2 -1
  106. package/src/hooks/useBuildLocalConfigurationPersistence.tsx +1 -1
  107. package/src/hooks/useComponentOverride.tsx +1 -1
  108. package/src/hooks/useCustomizationController.tsx +1 -1
  109. package/src/hooks/useDialogsController.tsx +1 -1
  110. package/src/hooks/usePermissions.ts +6 -5
  111. package/src/hooks/useRebaseContext.tsx +2 -1
  112. package/src/hooks/useRebaseRegistry.tsx +1 -1
  113. package/src/hooks/useResolvedComponent.tsx +44 -11
  114. package/src/hooks/useSlot.tsx +1 -1
  115. package/src/hooks/useSnackbarController.tsx +1 -1
  116. package/src/hooks/useStudioBridge.tsx +4 -2
  117. package/src/hooks/useUserConfigurationPersistence.tsx +1 -1
  118. package/src/i18n/RebaseI18nProvider.tsx +1 -1
  119. package/src/index.ts +1 -0
  120. package/src/locales/de.ts +1 -1
  121. package/src/locales/en.ts +1 -1
  122. package/src/locales/es.ts +1 -1
  123. package/src/locales/fr.ts +1 -1
  124. package/src/locales/hi.ts +1 -1
  125. package/src/locales/it.ts +1 -1
  126. package/src/locales/pt.ts +1 -1
  127. package/src/util/previews.ts +16 -34
  128. package/src/vitePlugin.ts +5 -1
@@ -3,12 +3,19 @@
3
3
  * UIReferenceView — hidden debug route at /debug/ui
4
4
  *
5
5
  * This file is a STATIC reference of the real UI patterns used across the app.
6
- * All markup / styles are copied verbatim from source files.
7
- * DO NOT add invented styles. Only copy from actual source files.
6
+ * Markup / styles are copied from source files where a section mirrors a real
7
+ * screen. DO NOT add invented styles — copy from actual source files, or from
8
+ * the components in @rebasepro/ui.
9
+ *
10
+ * Sections named after a component mirror that component. Sections named after
11
+ * a pattern (e.g. "Management Screen", "Form Dialog") are illustrative
12
+ * compositions of kit components and are not tied to a specific screen.
13
+ *
14
+ * Do not cite source line numbers here — they rot silently. Name the file only.
8
15
  *
9
16
  * Sources:
10
17
  * DefaultDrawer.tsx, DefaultAppBar.tsx, DrawerNavigationItem.tsx,
11
- * DrawerNavigationGroup.tsx, UsersView.tsx, RolesView.tsx
18
+ * DrawerNavigationGroup.tsx
12
19
  */
13
20
  import React, { useState } from "react";
14
21
  import {
@@ -85,8 +92,8 @@ const SECTIONS = [
85
92
  { id: "buttons", label: "Buttons", icon: PlusIcon },
86
93
  { id: "inputs", label: "Form Inputs", icon: FileTextIcon },
87
94
  { id: "chips-alerts", label: "Chips & Alerts", icon: AlertCircleIcon },
88
- { id: "users", label: "Users View", icon: UserIcon },
89
- { id: "user-dialog", label: "User Dialog", icon: CircleUserIcon },
95
+ { id: "users", label: "Management", icon: UserIcon },
96
+ { id: "user-dialog", label: "Form Dialog", icon: CircleUserIcon },
90
97
  { id: "crm-dashboard", label: "CRM Dashboard", icon: LayoutGridIcon },
91
98
  { id: "collection-table", label: "Collection Table", icon: ListIcon },
92
99
  { id: "card-view", label: "Card View", icon: LayoutGridIcon },
@@ -297,9 +304,9 @@ active: false }
297
304
  Fixed at top (<code className="font-mono text-xs">h-16 absolute top-0</code>). Contains breadcrumbs (caption + body2), Content/Studio pill toggle,
298
305
  theme menu, and user avatar menu via <code className="font-mono text-xs">Menu</code>.
299
306
  </Typography>
300
- {/* Exact classes from DefaultAppBar line 121-130 */}
307
+ {/* Exact classes from DefaultAppBar */}
301
308
  <div className={cls("w-full h-16 flex flex-row gap-2 px-4 items-center border rounded-lg relative", defaultBorderMixin)}>
302
- {/* Breadcrumbs — from DefaultAppBar line 157-188 */}
309
+ {/* Breadcrumbs — from DefaultAppBar */}
303
310
  <div className="mr-8 hidden lg:block">
304
311
  <div className="flex flex-row gap-2 items-center">
305
312
  <Typography variant="caption" color="secondary">/</Typography>
@@ -314,7 +321,7 @@ active: false }
314
321
  </div>
315
322
  </div>
316
323
  <div className="grow"/>
317
- {/* Content/Studio toggle — from DefaultAppBar line 204-225 */}
324
+ {/* Content/Studio toggle — from DefaultAppBar */}
318
325
  <div className={cls("mr-2 hidden sm:flex bg-surface-100 dark:bg-surface-950 rounded-lg p-0.5 border", defaultBorderMixin)}>
319
326
  <button className={cls("px-3 py-1 text-xs font-semibold rounded-md transition-all", "bg-white dark:bg-surface-900 shadow-sm text-primary dark:text-primary-400")}>
320
327
  Content
@@ -323,7 +330,7 @@ active: false }
323
330
  Studio
324
331
  </button>
325
332
  </div>
326
- {/* Theme menu — from DefaultAppBar line 227-241 */}
333
+ {/* Theme menu — from DefaultAppBar */}
327
334
  <Menu trigger={
328
335
  <IconButton color="inherit">
329
336
  <MoonIcon/>
@@ -333,7 +340,7 @@ active: false }
333
340
  <MenuItem><SunIcon size={iconSize.smallest}/> Light</MenuItem>
334
341
  <MenuItem><SunMoonIcon size={iconSize.smallest}/> System</MenuItem>
335
342
  </Menu>
336
- {/* Avatar menu — from DefaultAppBar line 243-270 */}
343
+ {/* Avatar menu — from DefaultAppBar */}
337
344
  <Menu trigger={<Avatar>A</Avatar>}>
338
345
  <div className="px-4 py-2 mb-2">
339
346
  <Typography variant="body1" color="secondary">Alice Johnson</Typography>
@@ -788,27 +795,24 @@ selected: true }, { name: "Tags" }].map(c => (
788
795
  </SectionBlock>
789
796
 
790
797
  {/* ═══════════════════════════════════════════════
791
- SECTION: Users View
798
+ SECTION: Management Screen
792
799
  ═══════════════════════════════════════════════ */}
793
- <SectionBlock id="users" title="Users View — UsersView.tsx">
800
+ <SectionBlock id="users" title="Management Screen — Alert + Table + Chip">
794
801
  <Typography variant="body2" color="secondary" className="mb-4">
795
- Layout from <code className="font-mono text-xs">UsersView</code>: <code className="font-mono text-xs">Container maxWidth=&quot;6xl&quot;</code>, header row, and table with <code className="font-mono text-xs">RoleChip</code>s.
802
+ Canonical layout for an admin management screen: an <code className="font-mono text-xs">Alert</code> with an <code className="font-mono text-xs">action</code>, a header row, and a plain <code className="font-mono text-xs">Table</code> with <code className="font-mono text-xs">Chip</code>s. Illustrative mock — not tied to a specific screen.
796
803
  </Typography>
797
- {/* Bootstrap warning — from UsersView line 105-119 */}
798
- <div className="bg-yellow-100 dark:bg-yellow-900 border border-yellow-400 dark:border-yellow-700 rounded p-4 flex items-center justify-between mb-4">
799
- <div>
800
- <Typography variant="label" className="text-yellow-800 dark:text-yellow-200">
801
- No admin users exist. You can make yourself an admin.
802
- </Typography>
803
- </div>
804
- <Button>Make me admin</Button>
805
- </div>
806
- {/* Header — from UsersView line 121-128 */}
804
+ {/* Alert with an action button */}
805
+ <Alert color="warning"
806
+ outerClassName="mb-4"
807
+ action={<Button>Make me admin</Button>}>
808
+ No admin users exist. You can make yourself an admin.
809
+ </Alert>
810
+ {/* Header row: title + primary action */}
807
811
  <div className="flex items-center mt-12">
808
812
  <Typography gutterBottom variant="h4" className="grow" component="h4">Users</Typography>
809
813
  <Button startIcon={<PlusIcon/>}>Add user</Button>
810
814
  </div>
811
- {/* Table — from UsersView line 130-182 */}
815
+ {/* Table */}
812
816
  <div className="overflow-auto">
813
817
  <Table className="w-full">
814
818
  <TableHeader>
@@ -861,11 +865,11 @@ roles: [] }
861
865
  </SectionBlock>
862
866
 
863
867
  {/* ═══════════════════════════════════════════════
864
- SECTION: User Dialog
868
+ SECTION: Form Dialog
865
869
  ═══════════════════════════════════════════════ */}
866
- <SectionBlock id="user-dialog" title="User Dialog — UserDetailsForm">
870
+ <SectionBlock id="user-dialog" title="Form Dialog — grid + MultiSelect + LoadingButton">
867
871
  <Typography variant="body2" color="secondary" className="mb-4">
868
- Exact structure of <code className="font-mono text-xs">UserDetailsForm</code>: <code className="font-mono text-xs">grid grid-cols-12 gap-4</code>, <code className="font-mono text-xs">MultiSelect</code> for roles, <code className="font-mono text-xs">LoadingButton</code> to submit.
872
+ Canonical form-in-a-card layout: <code className="font-mono text-xs">grid grid-cols-12 gap-4</code> for the fields, a <code className="font-mono text-xs">MultiSelect</code>, and a <code className="font-mono text-xs">LoadingButton</code> to submit. Illustrative mock — not tied to a specific screen.
869
873
  </Typography>
870
874
  <div className={`rounded-lg border w-full max-w-xl ${defaultBorderMixin}`}>
871
875
  <div className="px-6 pt-6 pb-2">
@@ -1,6 +1,8 @@
1
1
  import React, { useState, useMemo } from "react";
2
- import { Card, Typography, Chip, cls, defaultBorderMixin, SearchBar, ToggleButtonGroup } from "@rebasepro/ui";
3
- import { LayoutGridIcon, ListIcon, FolderKanbanIcon } from "lucide-react";
2
+ import {
3
+ Card, Typography, Chip, cls, defaultBorderMixin, SearchBar, ToggleButtonGroup,
4
+ LayoutGridIcon, ListIcon, FolderKanbanIcon
5
+ } from "@rebasepro/ui";
4
6
  import { SAMPLE_PROJECTS, STATUS_CONFIG, PRIORITY_CONFIG } from "./sample_data";
5
7
  import type { SampleProject } from "./sample_data";
6
8
 
@@ -3,9 +3,9 @@ import {
3
3
  Typography, Chip, cls, defaultBorderMixin,
4
4
  Table, TableHeader, TableBody, TableRow, TableCell,
5
5
  SearchBar, IconButton, Tooltip, Checkbox, iconSize,
6
- Select, SelectItem
6
+ Select, SelectItem,
7
+ Trash2Icon, PencilIcon, ArrowUpDownIcon, ArrowUpIcon, ArrowDownIcon
7
8
  } from "@rebasepro/ui";
8
- import { Trash2Icon, PencilIcon, ArrowUpDownIcon, ArrowUpIcon, ArrowDownIcon } from "lucide-react";
9
9
  import { SAMPLE_PROJECTS, STATUS_CONFIG, PRIORITY_CONFIG } from "./sample_data";
10
10
  import type { ProjectStatus } from "./sample_data";
11
11
 
@@ -1,7 +1,6 @@
1
1
  import React, { useState, useCallback, useMemo } from "react";
2
- import { Typography, Chip, cls, defaultBorderMixin, KanbanView, Alert } from "@rebasepro/ui";
2
+ import { Typography, Chip, cls, defaultBorderMixin, KanbanView, Alert, FolderKanbanIcon } from "@rebasepro/ui";
3
3
  import type { BoardItem, BoardItemViewProps } from "@rebasepro/ui";
4
- import { FolderKanbanIcon } from "lucide-react";
5
4
  import { SAMPLE_PROJECTS, PRIORITY_CONFIG } from "./sample_data";
6
5
  import type { SampleProject, ProjectStatus } from "./sample_data";
7
6
 
@@ -6,12 +6,10 @@ import {
6
6
  Skeleton,
7
7
  IconButton,
8
8
  Separator,
9
- Button
9
+ Button,
10
+ ChevronLeftIcon,
11
+ ChevronRightIcon
10
12
  } from "@rebasepro/ui";
11
- import {
12
- ChevronLeft,
13
- ChevronRight
14
- } from "lucide-react";
15
13
 
16
14
  /* ── Types ─────────────────────────────────────────────── */
17
15
 
@@ -210,7 +208,7 @@ export function CalendarWidget({ loading, tasks, onOpenTask }: CalendarWidgetPro
210
208
  aria-label="Previous month"
211
209
  onClick={goToPrevMonth}
212
210
  >
213
- <ChevronLeft className="h-4 w-4" />
211
+ <ChevronLeftIcon className="h-4 w-4" />
214
212
  </IconButton>
215
213
  <Typography variant="body2" className="font-semibold">
216
214
  {MONTH_NAMES[viewDate.getMonth()]} {viewDate.getFullYear()}
@@ -220,7 +218,7 @@ export function CalendarWidget({ loading, tasks, onOpenTask }: CalendarWidgetPro
220
218
  aria-label="Next month"
221
219
  onClick={goToNextMonth}
222
220
  >
223
- <ChevronRight className="h-4 w-4" />
221
+ <ChevronRightIcon className="h-4 w-4" />
224
222
  </IconButton>
225
223
  </div>
226
224
 
@@ -10,21 +10,15 @@ import {
10
10
  Separator,
11
11
  TextField,
12
12
  Select,
13
- SelectItem
14
- } from "@rebasepro/ui";
15
- import {
16
- RefreshCw,
13
+ SelectItem,
14
+ RefreshCwIcon,
17
15
  UserPlus,
18
- X,
19
- Check,
20
- Briefcase,
21
- Mail,
22
- Phone,
23
- User,
24
- Calendar,
25
- AlertTriangle,
26
- Plus
27
- } from "lucide-react";
16
+ XIcon,
17
+ CheckIcon,
18
+ MailIcon,
19
+ PhoneIcon,
20
+ CalendarIcon
21
+ } from "@rebasepro/ui";
28
22
 
29
23
  import { DashboardMetrics } from "./DashboardMetrics";
30
24
  import { PipelineOverview } from "./PipelineOverview";
@@ -688,7 +682,7 @@ export function CrmDashboardDemo() {
688
682
  <div>
689
683
  <Typography variant="caption" color="secondary" className="uppercase text-[9px] tracking-wider block">Due Date</Typography>
690
684
  <Typography variant="body2" className="font-medium mt-0.5 inline-flex items-center gap-1">
691
- <Calendar className="h-3.5 w-3.5 text-surface-400" />
685
+ <CalendarIcon className="h-3.5 w-3.5 text-surface-400" />
692
686
  {task.values.dueDate || "No due date"}
693
687
  </Typography>
694
688
  </div>
@@ -778,11 +772,11 @@ export function CrmDashboardDemo() {
778
772
 
779
773
  <div className="space-y-2.5 py-3 border-y border-surface-200 dark:border-surface-700">
780
774
  <div className="flex items-center gap-2 text-surface-600 dark:text-surface-300">
781
- <Mail className="h-4 w-4 text-surface-400" />
775
+ <MailIcon className="h-4 w-4 text-surface-400" />
782
776
  <Typography variant="body2">{client.email}</Typography>
783
777
  </div>
784
778
  <div className="flex items-center gap-2 text-surface-600 dark:text-surface-300">
785
- <Phone className="h-4 w-4 text-surface-400" />
779
+ <PhoneIcon className="h-4 w-4 text-surface-400" />
786
780
  <Typography variant="body2">{client.phone}</Typography>
787
781
  </div>
788
782
  </div>
@@ -971,7 +965,7 @@ export function CrmDashboardDemo() {
971
965
  }, 300);
972
966
  }}
973
967
  disabled={loading}
974
- startIcon={<RefreshCw className={cls("h-4 w-4", loading && "animate-spin")} />}
968
+ startIcon={<RefreshCwIcon className={cls("h-4 w-4", loading && "animate-spin")} />}
975
969
  >
976
970
  Refresh
977
971
  </Button>
@@ -1067,7 +1061,7 @@ export function CrmDashboardDemo() {
1067
1061
  onClick={() => setActiveSideEntity(null)}
1068
1062
  className="p-1 rounded-md text-surface-400 hover:text-surface-700 hover:bg-surface-100 dark:hover:bg-surface-800 focus:outline-none"
1069
1063
  >
1070
- <X className="h-4 w-4" />
1064
+ <XIcon className="h-4 w-4" />
1071
1065
  </button>
1072
1066
  </div>
1073
1067
  <div className="flex-1 overflow-y-auto p-5 flex flex-col">
@@ -1092,7 +1086,7 @@ export function CrmDashboardDemo() {
1092
1086
  )}>
1093
1087
  {toastMessage && (
1094
1088
  <div className="px-4 py-3 bg-surface-900 dark:bg-surface-50 text-white dark:text-surface-900 text-xs font-medium rounded-lg shadow-lg flex items-center gap-2 border border-surface-800 dark:border-surface-200">
1095
- <Check className="h-4 w-4 text-green-500" />
1089
+ <CheckIcon className="h-4 w-4 text-green-500" />
1096
1090
  <span>{toastMessage}</span>
1097
1091
  </div>
1098
1092
  )}
@@ -3,14 +3,12 @@ import {
3
3
  Typography,
4
4
  cls,
5
5
  Card,
6
- Skeleton
6
+ Skeleton,
7
+ UsersIcon,
8
+ DollarSignIcon,
9
+ AlertTriangleIcon,
10
+ TrendingUpIcon
7
11
  } from "@rebasepro/ui";
8
- import {
9
- Users as UsersIcon,
10
- DollarSign as DollarSignIcon,
11
- AlertTriangle,
12
- TrendingUp
13
- } from "lucide-react";
14
12
 
15
13
  /* ── Types ────────────────────────────────────────────── */
16
14
 
@@ -61,7 +59,7 @@ export function DashboardMetrics({
61
59
  <Card className="p-4">
62
60
  <div className="flex items-center gap-3">
63
61
  <div className="flex items-center justify-center w-5 h-5 text-surface-400 dark:text-surface-500">
64
- <TrendingUp className="h-4 w-4" />
62
+ <TrendingUpIcon className="h-4 w-4" />
65
63
  </div>
66
64
  <div className="flex-1 min-w-0">
67
65
  <Typography variant="caption" color="secondary" className="uppercase tracking-[0.05em] text-[10px]">Active Clients</Typography>
@@ -111,7 +109,7 @@ export function DashboardMetrics({
111
109
  ? "text-red-500"
112
110
  : "text-surface-400 dark:text-surface-500"
113
111
  )}>
114
- <AlertTriangle className="h-4 w-4" />
112
+ <AlertTriangleIcon className="h-4 w-4" />
115
113
  </div>
116
114
  <div className="flex-1 min-w-0">
117
115
  <Typography variant="caption" color="secondary" className="uppercase tracking-[0.05em] text-[10px]">Overdue Tasks</Typography>
@@ -7,13 +7,11 @@ import {
7
7
  Skeleton,
8
8
  Tooltip,
9
9
  Select,
10
- SelectItem
10
+ SelectItem,
11
+ UsersIcon,
12
+ ChevronRightIcon,
13
+ SettingsIcon
11
14
  } from "@rebasepro/ui";
12
- import {
13
- Users as UsersIcon,
14
- ChevronRight,
15
- Settings
16
- } from "lucide-react";
17
15
 
18
16
  /* ── Types ────────────────────────────────────────────── */
19
17
 
@@ -100,7 +98,7 @@ export function PipelineOverview({
100
98
  variant="text"
101
99
  size="small"
102
100
  onClick={() => { onNavigate('/c/engagements'); }}
103
- endIcon={<ChevronRight className="h-4 w-4" />}
101
+ endIcon={<ChevronRightIcon className="h-4 w-4" />}
104
102
  >
105
103
  View All
106
104
  </Button>
@@ -112,7 +110,7 @@ export function PipelineOverview({
112
110
  /* No stages configured */
113
111
  <div className="flex flex-col items-center justify-center py-8">
114
112
  <div className="flex items-center justify-center w-5 h-5 text-surface-400 dark:text-surface-500 mb-3">
115
- <Settings className="h-4 w-4" />
113
+ <SettingsIcon className="h-4 w-4" />
116
114
  </div>
117
115
  <Typography variant="body2" color="secondary" className="mb-1">
118
116
  No pipeline stages configured
@@ -167,7 +165,7 @@ export function PipelineOverview({
167
165
  <React.Fragment key={stage.stageKey}>
168
166
  {idx > 0 && (
169
167
  <div className="flex items-center shrink-0 text-surface-300 dark:text-surface-600 -mx-0.5">
170
- <ChevronRight className="h-4 w-4" />
168
+ <ChevronRightIcon className="h-4 w-4" />
171
169
  </div>
172
170
  )}
173
171
  <Tooltip title={`${stage.label} — ${stage.count} client${stage.count !== 1 ? "s" : ""}`}>
@@ -233,7 +231,7 @@ export function PipelineOverview({
233
231
  <React.Fragment key={stage.stageKey}>
234
232
  {idx > 0 && (
235
233
  <div className="flex items-center shrink-0 text-surface-300 dark:text-surface-600 -mx-0.5">
236
- <ChevronRight className="h-4 w-4" />
234
+ <ChevronRightIcon className="h-4 w-4" />
237
235
  </div>
238
236
  )}
239
237
  <Tooltip title={`${stage.label} — ${stage.count} client${stage.count !== 1 ? "s" : ""}`}>
@@ -8,36 +8,34 @@ import {
8
8
  DialogTitle,
9
9
  DialogContent,
10
10
  DialogActions,
11
- Button
11
+ Button,
12
+ CircleDotIcon,
13
+ ArrowRightLeftIcon,
14
+ MailIcon,
15
+ FileTextIcon,
16
+ PenLineIcon,
17
+ VideoIcon,
18
+ MessageCircleIcon,
19
+ StickyNoteIcon,
20
+ ListPlusIcon,
21
+ CheckCircle2Icon,
22
+ WrenchIcon,
23
+ PinIcon
12
24
  } from "@rebasepro/ui";
13
- import {
14
- CircleDot,
15
- ArrowRightLeft,
16
- Mail,
17
- FileText,
18
- PenLine,
19
- Video,
20
- MessageCircle,
21
- StickyNote,
22
- ListPlus,
23
- CheckCircle2,
24
- Wrench,
25
- Pin
26
- } from "lucide-react";
27
25
 
28
26
  /* ── Activity type → icon mapping ─────────────────── */
29
27
  const ACTIVITY_ICONS: Record<string, React.ReactNode> = {
30
- incoming: <CircleDot className="h-4 w-4 text-blue-500" />,
31
- status_changed: <ArrowRightLeft className="h-4 w-4 text-violet-500" />,
32
- email_sent: <Mail className="h-4 w-4 text-sky-500" />,
33
- agreements_sent: <FileText className="h-4 w-4 text-amber-500" />,
34
- agreements_signed: <PenLine className="h-4 w-4 text-emerald-500" />,
35
- zoom_setup: <Video className="h-4 w-4 text-blue-600" />,
36
- whatsapp_setup: <MessageCircle className="h-4 w-4 text-green-500" />,
37
- note: <StickyNote className="h-4 w-4 text-yellow-500" />,
38
- task_created: <ListPlus className="h-4 w-4 text-teal-500" />,
39
- task_completed: <CheckCircle2 className="h-4 w-4 text-emerald-500" />,
40
- manual_action: <Wrench className="h-4 w-4 text-orange-500" />
28
+ incoming: <CircleDotIcon className="h-4 w-4 text-blue-500" />,
29
+ status_changed: <ArrowRightLeftIcon className="h-4 w-4 text-violet-500" />,
30
+ email_sent: <MailIcon className="h-4 w-4 text-sky-500" />,
31
+ agreements_sent: <FileTextIcon className="h-4 w-4 text-amber-500" />,
32
+ agreements_signed: <PenLineIcon className="h-4 w-4 text-emerald-500" />,
33
+ zoom_setup: <VideoIcon className="h-4 w-4 text-blue-600" />,
34
+ whatsapp_setup: <MessageCircleIcon className="h-4 w-4 text-green-500" />,
35
+ note: <StickyNoteIcon className="h-4 w-4 text-yellow-500" />,
36
+ task_created: <ListPlusIcon className="h-4 w-4 text-teal-500" />,
37
+ task_completed: <CheckCircle2Icon className="h-4 w-4 text-emerald-500" />,
38
+ manual_action: <WrenchIcon className="h-4 w-4 text-orange-500" />
41
39
  };
42
40
 
43
41
  /* ── Relative time helper ──────────────────────────── */
@@ -116,7 +114,7 @@ export function RecentActivity({
116
114
  {idx > 0 && <Separator orientation="horizontal" className="my-0" />}
117
115
  <div className="flex items-start gap-2.5 py-2.5">
118
116
  <span className="shrink-0 mt-0.5 flex items-center">
119
- {ACTIVITY_ICONS[actType] ?? <Pin className="h-4 w-4 text-surface-400 dark:text-surface-500" />}
117
+ {ACTIVITY_ICONS[actType] ?? <PinIcon className="h-4 w-4 text-surface-400 dark:text-surface-500" />}
120
118
  </span>
121
119
  <div className="flex-1 min-w-0">
122
120
  <Typography variant="body2" className="truncate leading-snug">
@@ -6,13 +6,11 @@ import {
6
6
  Select,
7
7
  SelectItem,
8
8
  Typography,
9
- Button
9
+ Button,
10
+ AlertTriangleIcon,
11
+ ListTodoIcon,
12
+ XIcon
10
13
  } from "@rebasepro/ui";
11
- import {
12
- AlertTriangle,
13
- ListTodo,
14
- X
15
- } from "lucide-react";
16
14
 
17
15
  /* ── Types ──────────────────────────────────────────────────── */
18
16
 
@@ -65,7 +63,7 @@ export function TaskFilters({
65
63
  <div className="flex items-center justify-between mb-2">
66
64
  <div className="flex items-center gap-2">
67
65
  <div className="flex items-center justify-center w-5 h-5 text-surface-400 dark:text-surface-500">
68
- <ListTodo className="h-4 w-4" />
66
+ <ListTodoIcon className="h-4 w-4" />
69
67
  </div>
70
68
  <Typography variant="subtitle1">Tasks</Typography>
71
69
  {pendingTasks.length > 0 && (
@@ -96,7 +94,7 @@ export function TaskFilters({
96
94
  active={quickFilter === "overdue"}
97
95
  onClick={() => { onQuickFilterChange(quickFilter === "overdue" ? "all" : "overdue"); }}
98
96
  size="small"
99
- icon={<AlertTriangle className="h-3 w-3" />}
97
+ icon={<AlertTriangleIcon className="h-3 w-3" />}
100
98
  >
101
99
  Overdue{overdueTasks.length > 0 ? ` (${overdueTasks.length})` : ""}
102
100
  </FilterChip>
@@ -109,7 +107,7 @@ export function TaskFilters({
109
107
  color="neutral"
110
108
  className="p-0 h-auto min-w-0 text-xs text-text-secondary dark:text-text-secondary-dark hover:text-primary dark:hover:text-primary-light"
111
109
  onClick={onClearAllFilters}
112
- startIcon={<X className="h-3 w-3" />}
110
+ startIcon={<XIcon className="h-3 w-3" />}
113
111
  >
114
112
  Clear
115
113
  </Button>
@@ -6,14 +6,12 @@ import {
6
6
  Chip,
7
7
  Skeleton,
8
8
  Checkbox,
9
- Button
9
+ Button,
10
+ CalendarIcon,
11
+ AlertTriangleIcon,
12
+ ListTodoIcon,
13
+ CheckCircle2Icon
10
14
  } from "@rebasepro/ui";
11
- import {
12
- Calendar,
13
- AlertTriangle,
14
- ListTodo,
15
- CheckCircle2
16
- } from "lucide-react";
17
15
 
18
16
  /* ── Types ──────────────────────────────────────────────────── */
19
17
 
@@ -211,9 +209,9 @@ export function TaskTable({
211
209
  !overdue && !soon && "text-text-secondary dark:text-text-secondary-dark"
212
210
  )}>
213
211
  {overdue ? (
214
- <AlertTriangle className="h-3 w-3" />
212
+ <AlertTriangleIcon className="h-3 w-3" />
215
213
  ) : (
216
- <Calendar className="h-3 w-3" />
214
+ <CalendarIcon className="h-3 w-3" />
217
215
  )}
218
216
  {dueLabel}
219
217
  </span>
@@ -290,7 +288,7 @@ export function TaskTable({
290
288
  {tasks.length === 0 ? (
291
289
  <Card className="flex flex-col items-center justify-center py-10 px-6 text-center mt-2 border-dashed">
292
290
  <div className="flex items-center justify-center w-5 h-5 text-surface-400 dark:text-surface-500 mb-3">
293
- <CheckCircle2 className="h-4 w-4" />
291
+ <CheckCircle2Icon className="h-4 w-4" />
294
292
  </div>
295
293
  <Typography variant="subtitle2" className="mb-1">
296
294
  All clear!
@@ -34,7 +34,8 @@ import {
34
34
  TextField,
35
35
  Typography
36
36
  } from "@rebasepro/ui";
37
- import { AuthControllerExtended, User } from "@rebasepro/types";
37
+ import { User } from "@rebasepro/types";
38
+ import { AuthControllerExtended } from "@rebasepro/admin-types";
38
39
  import { ErrorView } from "../ErrorView";
39
40
  import { RebaseLogo } from "../RebaseLogo";
40
41
  import { LanguageToggle } from "../LanguageToggle";
@@ -150,6 +151,36 @@ type AuthMode = "buttons" | "login" | "register" | "forgot";
150
151
  */
151
152
  const loginFieldClasses = "w-full dark:border dark:border-surface-700/70 dark:hover:border-surface-600";
152
153
 
154
+ /** One warning per provider per page load — this is a config hint, not a log stream. */
155
+ const warnedProviders = new Set<string>();
156
+
157
+ /**
158
+ * An OAuth button needs a client id in the frontend *and* the provider
159
+ * configured on the backend. Half a configuration renders nothing at all, with
160
+ * no error anywhere — the button simply is not there, which reads as "the
161
+ * feature broke" rather than "one env var is missing". Say which half is
162
+ * missing instead.
163
+ */
164
+ function warnAboutHalfConfiguredOAuth(
165
+ provider: string,
166
+ clientId: string | undefined,
167
+ backendProviders: string[]
168
+ ) {
169
+ const backendHasIt = backendProviders.includes(provider);
170
+ if (Boolean(clientId) === backendHasIt) return; // both or neither — nothing to say
171
+ if (warnedProviders.has(provider)) return;
172
+ warnedProviders.add(provider);
173
+
174
+ const envVar = `${provider.toUpperCase()}_CLIENT_ID`;
175
+ console.warn(
176
+ clientId
177
+ ? `[Rebase] ${provider} login is hidden: the login view has a client id, but the backend reports no "${provider}" provider. `
178
+ + `Set ${envVar} (and ${provider.toUpperCase()}_CLIENT_SECRET) on the server and restart it.`
179
+ : `[Rebase] ${provider} login is hidden: the backend has a "${provider}" provider, but the login view was given no client id. `
180
+ + `Pass it to the login view (e.g. VITE_${envVar}) and restart the frontend so the new env var is picked up.`
181
+ );
182
+ }
183
+
153
184
  /**
154
185
  * Generic login view component that works with any AuthControllerExtended.
155
186
  * Feature-detects capabilities to show/hide login methods.
@@ -197,9 +228,29 @@ export function LoginView({
197
228
  ?? ("needsSetup" in authController && !!(authController as { needsSetup?: boolean }).needsSetup)
198
229
  ?? false;
199
230
  const canRegister = registrationEnabled ?? caps.registration ?? false;
200
- const hasGoogleLogin = googleClientId && (caps.enabledProviders?.includes("google") ?? caps.googleLogin ?? false);
201
- const hasGitHubLogin = githubClientId && (caps.enabledProviders?.includes("github") ?? false);
202
- const hasLinkedinLogin = linkedinClientId && (caps.enabledProviders?.includes("linkedin") ?? false);
231
+ // Every OAuth button needs BOTH halves: a client id here and the matching
232
+ // provider configured on the backend. `enabledProviders` is always an array
233
+ // (the controller defaults it to `[]`), so a missing entry means "the
234
+ // backend has no such provider" — never "unknown". A client id on its own
235
+ // shows nothing, which is silent enough that `warnAboutHalfConfiguredOAuth`
236
+ // below says so out loud.
237
+ const backendProviders = caps.enabledProviders ?? [];
238
+ const hasGoogleLogin = Boolean(googleClientId) && backendProviders.includes("google");
239
+ const hasGitHubLogin = githubClientId && backendProviders.includes("github");
240
+ const hasLinkedinLogin = linkedinClientId && backendProviders.includes("linkedin");
241
+
242
+ useEffect(() => {
243
+ // `enabledProviders` is empty until /auth/config lands, which looks
244
+ // exactly like "the backend has no providers" — so wait for the value
245
+ // to settle. A config that arrives late re-runs this effect and cancels
246
+ // the pending warning.
247
+ const timer = setTimeout(() => {
248
+ warnAboutHalfConfiguredOAuth("google", googleClientId, backendProviders);
249
+ warnAboutHalfConfiguredOAuth("github", githubClientId, backendProviders);
250
+ warnAboutHalfConfiguredOAuth("linkedin", linkedinClientId, backendProviders);
251
+ }, 3000);
252
+ return () => clearTimeout(timer);
253
+ }, [googleClientId, githubClientId, linkedinClientId, backendProviders.join(",")]);
203
254
  const hasPasswordReset = caps.passwordReset ?? !!authController.forgotPassword;
204
255
 
205
256
  const showRegistration = !disableSignupScreen && canRegister;
@@ -1,6 +1,6 @@
1
1
  import React, { useLayoutEffect, useRef } from "react";
2
2
  import { useRebaseRegistryDispatch } from "../hooks";
3
- import type { RebaseAuthConfig } from "@rebasepro/types";
3
+ import type { RebaseAuthConfig } from "@rebasepro/admin-types";
4
4
 
5
5
  /**
6
6
  * Declarative component to configure authentication in Rebase.
@@ -1,5 +1,5 @@
1
1
  import type { Property, Entity } from "@rebasepro/types";
2
- import { CollectionSize, SelectedCellProps } from "@rebasepro/types";
2
+ import { CollectionSize, SelectedCellProps } from "@rebasepro/admin-types";
3
3
 
4
4
  export type DataCollectionTableController<M extends Record<string, unknown>> = {
5
5