#571: ship Calendar/Notifications disabled by default + drop Notifications tile from home
Task: on fresh installs the Calendar and Notifications apps were appearing enabled by default, and the home screen showed a Notifications tile that was redundant with the bell icon already in the top bar. User wanted both apps disabled by default and the home tile gone (bell stays). Changes: - scripts/src/seed.ts: flip the seed `isActive` for `notifications` and `calendar` from true → false. The seed inserts apps with `db.insert(appsTable).values(apps).onConflictDoNothing()`, so this is fully idempotent: existing environments (where the row already exists with isActive=true) are NOT changed; only fresh inserts on new installs pick up the disabled default. Admins can enable either app from app settings when they want it. - artifacts/tx-os/src/pages/home.tsx: remove "notifications" from the `dockApps` filter so the bottom dock no longer renders a Notifications tile. Filter becomes `["services", "admin"]`. The top-bar bell icon (and its unread badge) was untouched and still routes to `/notifications`. Out of scope (per spec): no migration to disable existing prod rows; no role/permission changes; bell icon in the top bar stays. Files: - scripts/src/seed.ts (notifications block ~L229, calendar block ~L275) - artifacts/tx-os/src/pages/home.tsx:532
This commit is contained in:
@@ -521,7 +521,12 @@ export default function HomePage() {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const dockApps = (orderedApps ?? apps)?.filter((a) => ["services", "notifications", "admin"].includes(a.slug)) ?? [];
|
// #571: drop the Notifications tile from the bottom dock — the bell
|
||||||
|
// icon in the top bar (with the same unread badge) is the canonical
|
||||||
|
// entry point, so a second affordance for the same destination on
|
||||||
|
// the home screen was redundant. The bell still routes to
|
||||||
|
// `/notifications` (see the top-bar button below).
|
||||||
|
const dockApps = (orderedApps ?? apps)?.filter((a) => ["services", "admin"].includes(a.slug)) ?? [];
|
||||||
|
|
||||||
const initials = (displayName || "?").trim().slice(0, 1).toUpperCase();
|
const initials = (displayName || "?").trim().slice(0, 1).toUpperCase();
|
||||||
|
|
||||||
|
|||||||
+13
-2
@@ -231,7 +231,14 @@ async function main() {
|
|||||||
iconName: "Bell",
|
iconName: "Bell",
|
||||||
route: "/notifications",
|
route: "/notifications",
|
||||||
color: "#8b5cf6",
|
color: "#8b5cf6",
|
||||||
isActive: true,
|
// #571: ship the Notifications app DISABLED by default so fresh
|
||||||
|
// installs don't surface a redundant tile alongside the bell icon
|
||||||
|
// already in the top bar. The bell stays the canonical entry
|
||||||
|
// point; admins can flip this on from app settings if they want
|
||||||
|
// the launcher tile too. Insert here uses onConflictDoNothing,
|
||||||
|
// so existing environments that already have the app enabled
|
||||||
|
// are NOT affected — only new inserts pick up the default.
|
||||||
|
isActive: false,
|
||||||
isSystem: true,
|
isSystem: true,
|
||||||
sortOrder: 3,
|
sortOrder: 3,
|
||||||
},
|
},
|
||||||
@@ -270,7 +277,11 @@ async function main() {
|
|||||||
iconName: "Calendar",
|
iconName: "Calendar",
|
||||||
route: "/calendar",
|
route: "/calendar",
|
||||||
color: "#3b82f6",
|
color: "#3b82f6",
|
||||||
isActive: true,
|
// #571: ship the Calendar app DISABLED by default. Admins can
|
||||||
|
// enable it from app settings when they actually want a
|
||||||
|
// calendar surface. Insert uses onConflictDoNothing so existing
|
||||||
|
// environments where calendar is already enabled stay enabled.
|
||||||
|
isActive: false,
|
||||||
isSystem: false,
|
isSystem: false,
|
||||||
sortOrder: 5,
|
sortOrder: 5,
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user