@nightkatana/kronosys-app 1.0.0-beta.21 → 1.0.0-beta.22

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 (46) hide show
  1. package/README.md +1 -1
  2. package/app/changelog/page.tsx +87 -19
  3. package/app/globals.css +10 -8
  4. package/app/guide/page.tsx +71 -34
  5. package/app/implementation/page.tsx +70 -60
  6. package/app/licenses/page.tsx +79 -47
  7. package/app/logs/page.tsx +103 -47
  8. package/app/page.tsx +104 -169
  9. package/app/reporting/page.tsx +1918 -1436
  10. package/app/settings/page.tsx +66 -44
  11. package/components/KronosysPayloadProvider.tsx +19 -5
  12. package/components/dashboard/AppShellHeaderKronoFocus.tsx +78 -0
  13. package/components/dashboard/AppShellHeaderToolbarLayout.tsx +36 -0
  14. package/components/dashboard/AppShellHeaderUtilityRibbon.tsx +19 -0
  15. package/components/dashboard/AppShellHeaderWallClock.tsx +23 -17
  16. package/components/dashboard/AppShellRouteNav.tsx +336 -209
  17. package/components/dashboard/AppShellToolbarCommandCenter.tsx +225 -0
  18. package/components/dashboard/AppShellToolbarRouteNav.tsx +204 -0
  19. package/components/dashboard/DashboardCommandCenter.tsx +119 -30
  20. package/components/dashboard/KronoFocusPanel.tsx +287 -260
  21. package/components/dashboard/LanguageMenu.tsx +23 -7
  22. package/components/dashboard/PageRefreshButton.tsx +42 -16
  23. package/components/dashboard/ReportingTour.tsx +20 -2
  24. package/components/dashboard/SessionListPanel.tsx +4 -4
  25. package/components/dashboard/ThemeToggle.tsx +4 -3
  26. package/components/dashboard/useAnchoredFloatingPortalStyle.ts +9 -2
  27. package/components/dashboard/useKronoFocusLiveSeconds.ts +4 -2
  28. package/lib/appShellHeaderClasses.ts +22 -3
  29. package/lib/appShellToolbarChrome.ts +112 -0
  30. package/lib/appShellToolbarDeferredIntents.ts +112 -0
  31. package/lib/appShellToolbarSessionSlices.ts +67 -0
  32. package/lib/dashboardCopy.ts +78 -29
  33. package/lib/dashboardQuickSearch.ts +37 -6
  34. package/lib/dashboardUrlSession.ts +36 -0
  35. package/lib/generatedUserChangelog.ts +14 -0
  36. package/lib/implementationNotes.ts +18 -14
  37. package/lib/reportingAggregate.ts +68 -9
  38. package/lib/reportingMetricHelp.ts +8 -8
  39. package/lib/reportingStrings.ts +118 -9
  40. package/lib/reportingTagWeekBreakdown.ts +55 -13
  41. package/lib/settingsCopy.ts +6 -7
  42. package/lib/userGuideCopy.ts +29 -26
  43. package/package.json +7 -5
  44. package/server/db.ts +6 -4
  45. package/server/dbSchema.ts +2 -2
  46. package/components/dashboard/AppShellCommandCenterPlaceholder.tsx +0 -17
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nightkatana/kronosys-app",
3
- "version": "1.0.0-beta.21",
3
+ "version": "1.0.0-beta.22",
4
4
  "description": "Kronosys — application Next.js (UI + API + SQLite).",
5
5
  "license": "MIT",
6
6
  "author": "nightkatana",
@@ -45,6 +45,10 @@
45
45
  "@dnd-kit/sortable": "^10.0.0",
46
46
  "@dnd-kit/utilities": "^3.2.2",
47
47
  "@tailwindcss/postcss": "^4",
48
+ "@types/node": "^22.15.21",
49
+ "@types/react": "^19",
50
+ "@types/react-dom": "^19",
51
+ "better-sqlite3": "^11.10.0",
48
52
  "date-fns": "^4.1.0",
49
53
  "fflate": "^0.8.2",
50
54
  "lucide-react": "^1.8.0",
@@ -55,16 +59,14 @@
55
59
  "react-dom": "19.2.4",
56
60
  "react-markdown": "^10.1.0",
57
61
  "tailwindcss": "^4",
58
- "typescript": "^5.9.3",
59
- "@types/node": "^22.15.21",
60
- "@types/react": "^19",
61
- "@types/react-dom": "^19"
62
+ "typescript": "^5.9.3"
62
63
  },
63
64
  "devDependencies": {
64
65
  "@changesets/cli": "^2.31.0",
65
66
  "@playwright/test": "^1.59.1",
66
67
  "@testing-library/react": "^16.3.0",
67
68
  "@testing-library/user-event": "^14.6.1",
69
+ "@types/better-sqlite3": "^7.6.13",
68
70
  "@vitest/coverage-v8": "^4.1.5",
69
71
  "eslint": "^9",
70
72
  "eslint-config-next": "16.2.3",
package/server/db.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { DatabaseSync } from "node:sqlite";
1
+ import Database from "better-sqlite3";
2
2
  import * as path from "node:path";
3
3
 
4
4
  import { ensureDataDirectory, resetDataDirectoryCache } from "@/lib/dataDir";
@@ -6,7 +6,9 @@ import { ensureCoreSchema } from "./dbSchema";
6
6
 
7
7
  const DB_NAME = "kronosys.sqlite";
8
8
 
9
- let db: DatabaseSync | null = null;
9
+ type SqliteDatabase = InstanceType<typeof Database>;
10
+
11
+ let db: SqliteDatabase | null = null;
10
12
 
11
13
  /** Ferme la connexion SQLite (tests ou changement de `TRACE_DATA_DIR` / cache de résolution). */
12
14
  export function resetSqliteConnection(): void {
@@ -21,13 +23,13 @@ export function resetSqliteConnection(): void {
21
23
  resetDataDirectoryCache();
22
24
  }
23
25
 
24
- export function getSqlite(): DatabaseSync {
26
+ export function getSqlite(): SqliteDatabase {
25
27
  if (db) {
26
28
  return db;
27
29
  }
28
30
  const dir = ensureDataDirectory();
29
31
  const file = path.join(dir, DB_NAME);
30
- db = new DatabaseSync(file);
32
+ db = new Database(file);
31
33
  db.exec("PRAGMA journal_mode = WAL;");
32
34
  ensureCoreSchema(db);
33
35
  return db;
@@ -1,6 +1,6 @@
1
- import type { DatabaseSync } from "node:sqlite";
1
+ import Database from "better-sqlite3";
2
2
 
3
- export function ensureCoreSchema(db: DatabaseSync): void {
3
+ export function ensureCoreSchema(db: InstanceType<typeof Database>): void {
4
4
  db.exec(`
5
5
  CREATE TABLE IF NOT EXISTS app_meta (
6
6
  key TEXT PRIMARY KEY NOT NULL,
@@ -1,17 +0,0 @@
1
- "use client";
2
-
3
- /**
4
- * Réserve la même largeur que {@link DashboardCommandCenter} lorsque la palette n’est pas
5
- * disponible sur une route (navigation stable entre pages).
6
- */
7
- export function AppShellCommandCenterPlaceholder() {
8
- return (
9
- <div
10
- className="invisible pointer-events-none flex shrink-0 items-center gap-1.5"
11
- aria-hidden
12
- >
13
- <div className="inline-flex h-10 w-[9.5rem] max-w-[min(42vw,11rem)] shrink-0 items-center rounded-lg px-2 sm:w-44 sm:max-w-none sm:px-2.5" />
14
- <div className="inline-flex size-10 shrink-0 items-center justify-center rounded-lg" />
15
- </div>
16
- );
17
- }