saravanakumardb1
e6ccaec2fe
fix(fastify-sse): add X-Accel-Buffering header to per-request startSSE
...
Aligns with hub.ts which already includes this header. Prevents
nginx/Traefik from buffering SSE chunks behind a reverse proxy.
2026-03-29 12:47:13 -07:00
saravanakumardb1
e194365711
fix(use-theme): add SSR safety guards for window access
...
setTheme, toggleTheme, and storage event listener now check
typeof window before accessing localStorage/addEventListener.
Prevents crashes in Next.js server components.
2026-03-29 12:46:18 -07:00
saravanakumardb1
6f4957d821
fix(use-keyboard-shortcuts): enforce symmetric modifier matching
...
Modifiers (shift, alt, meta) are now checked in both directions:
when not required, the physical key must NOT be pressed either.
Before: Cmd+K shortcut would fire on Cmd+Shift+K or Cmd+Alt+K.
After: exact modifier combination is enforced.
4 regression tests added.
2026-03-29 12:45:32 -07:00
saravanakumardb1
31cf7c0c6f
feat(ollama-client): shared Ollama API client package
2026-03-29 12:43:01 -07:00
saravanakumardb1
bfa55998a2
feat(use-keyboard-shortcuts): shared React keyboard shortcuts hook
2026-03-29 12:40:43 -07:00
saravanakumardb1
0f5dc91648
feat(use-theme): shared React theme toggle hook
2026-03-29 12:40:06 -07:00
saravanakumardb1
c28dbc873e
feat(fastify-sse): add per-request SSE helpers
2026-03-29 12:38:57 -07:00
saravanakumardb1
f808a3c05d
fix(ui): use extensionless imports + bundler resolution for source-consumed package
2026-03-29 02:03:48 -07:00
saravanakumardb1
a8d37bd103
feat(ui): add Sidebar, StatCard, LoadingSpinner components + README docs — Level 3 component coverage
2026-03-29 00:19:45 -07:00
saravanakumardb1
b7cb44267b
feat(design-tokens): add per-product CSS exports and regenerate all token files
2026-03-28 23:16:19 -07:00
saravanakumardb1
11a832e271
feat(ui): add Storybook for @bytelyst/ui component library
...
- Storybook 8 with React Vite framework + a11y addon
- Stories for Button (7 variants), Badge (6), Input (5), Card (4)
- Dark/elevated/light background presets
- Run: pnpm --filter @bytelyst/ui storybook
2026-03-28 00:59:25 -07:00
saravanakumardb1
5da71f3735
feat(ui): add Input, Textarea, Card, Label, Select, Separator components to @bytelyst/ui
...
- Input: with label, error, hint, a11y attributes
- Textarea: resizable with label, error, hint
- Card: with CardHeader, CardTitle, CardDescription sub-components
- Label: with required indicator
- Select: native select with chevron icon, label, error
- Separator: horizontal/vertical with ARIA roles
- All components use --bl-* design token CSS variables
- 12 total components in @bytelyst/ui
2026-03-28 00:33:38 -07:00
saravanakumardb1
6b6f147de7
feat(design-tokens): extend generator with per-product Swift + Kotlin native themes
...
- Add generateProductSwift() and generateProductKotlin() to generate.ts
- Add PRODUCT_NATIVE_MAP for 10 products (ChronoMind, JarvisJr, PeakPulse, LysnrAI, NomGap, ActionTrail, FlowMonk, NoteLett, LocalMemGPT, LocalLLMLab)
- Output 20 native token files in generated/native/
- Fix TS type narrowing for gradient objects (line 382)
- Update DESIGN_SYSTEM_AUDIT.md with Appendix G remediation results
2026-03-28 00:25:03 -07:00
saravanakumardb1
46ee14371c
fix(ci): add --pool forks to all vitest test scripts to fix kill EPERM on Node v25
...
Root cause: tinypool worker teardown calls kill() which returns EPERM
in the act_runner host environment on Node.js v25.2.1. Tests pass but
the vitest process crashes during cleanup, causing CI failure.
Fix: --pool forks CLI flag on every package/service test script, plus
pool: 'forks' in all vitest.config.ts files. This uses child_process.fork()
worker management which handles termination cleanly.
60 package.json files updated, 10 vitest.config.ts files updated.
2026-03-27 23:23:38 -07:00
saravanakumardb1
252403f74e
feat(ui): create @bytelyst/ui with Button, Toast, Modal, ConfirmDialog, Badge, EmptyState
2026-03-27 16:29:37 -07:00
saravanakumardb1
b3a1ee5db9
feat(design-tokens): per-product CSS generation for all 11 products
2026-03-27 16:24:58 -07:00
saravanakumardb1
915f59f595
feat(design-tokens): add actiontrail, notelett, localmemgpt, localllmlab product palettes
2026-03-27 16:23:13 -07:00
saravanakumardb1
b6348fd4fe
fix(security): harden npm publish — add .npmrc + publishConfig to all 57 packages
...
- Created .npmrc with @bytelyst scoped registry pointing to local Gitea
- Added publishConfig.registry to all 57 @bytelyst/* package.json files
- Created scripts/harden-publish-config.sh for future re-runs
- Prevents accidental publish to npmjs.org or corporate JFrog registry
2026-03-26 21:51:05 -07:00
saravanakumardb1
adfa5b9fec
fix(react-auth): align source version with published package
2026-03-23 18:36:15 -07:00
saravanakumardb1
841cdf3a16
fix(platform-service+events): 3 more gaps in diagnostics + delivery
...
- diagnostics/subscribers: wire session.created email notification to
target user using existing 'diagnostics-session-created' template
(was just logging instead of sending the email)
- events/types: add missing 'currency' field to payment.failed schema
(payment.succeeded had it, payment.failed did not — inconsistency)
- delivery/subscribers: use event.payload.currency instead of hardcoded
empty string in payment-failed email variables
- Typecheck clean, 1483/1483 tests pass
2026-03-22 01:20:24 -07:00
saravanakumardb1
1576b699b0
feat(platform-service): resolve all P3 TODOs — diagnostics notifications + test cleanup
...
- diagnostics/subscribers: notify admin via email when debug session is
cancelled (looks up session creator via getSession + getUserById)
- diagnostics/subscribers: email session summary (logs/traces/screenshots)
to admin when debug session completes
- diagnostics/subscribers: send Slack alert via dispatchSlack for FATAL
logs ingested during debug sessions (on-call engineer notification)
- feedback-client/integration.test.ts: replace TODO-4 with clear NOTE,
fix unused var lint errors
- feedback-client/gdpr.test.ts: mark lifecycle policy as accepted,
remove console.log + unused blobPath variable
- Update WORKSPACE_TODO_AUDIT.md — P3 section: all 5 resolved
- Typecheck clean, 1483/1483 tests pass
2026-03-22 01:03:51 -07:00
saravanakumardb1
9471d4c56f
fix(test): add @vitest-environment happy-dom to React UI test files
...
6 test files across 4 packages (auth-ui, dashboard-components,
dashboard-shell, react-auth) failed with 'document is not defined'
when run from the monorepo root because the root vitest config uses
environment: 'node'. The package-local configs set happy-dom but are
ignored when vitest is invoked from root.
Fix: Add per-file '// @vitest-environment happy-dom' annotations,
which is the recommended vitest pattern for mixed-environment monorepos.
This ensures tests work regardless of which config is loaded.
Recovers 148 tests across 6 files.
2026-03-21 16:21:42 -07:00
saravanakumardb1
7613d6890f
feat(field-encrypt): admin-panel encryption toggle via feature flags
...
- FieldEncryptorConfig.enabled: false returns NullFieldEncryptor (no-op)
- NullFieldEncryptor stores plaintext as-is, decrypt returns ct directly
- 7 new tests for toggle behavior (50/50 total)
- encryption_enabled added to COMMON_FLAGS (seeded for all 10 products)
2026-03-21 15:24:19 -07:00
saravanakumardb1
4a47db72ae
fix(flags): SSE stream endpoint + client — pass productId via query string
...
EventSource API cannot set custom headers, so the SSE /flags/stream
endpoint and feature-flag-client were broken for streaming mode:
- Server: accept productId and token from query string as fallback
when x-product-id / authorization headers are absent
- Client: pass productId (and optional auth token) as query params
when constructing the EventSource URL
2026-03-21 12:12:14 -07:00
saravanakumardb1
ca6a4d41d8
feat(flags): production-grade feature flag system — multi-variate, segments, audit, SSE, scheduling, prerequisites
...
- types.ts: multi-variate flags (boolean/string/number/JSON), targeting rules with 18 operators, scheduling (enableAt/disableAt/gradual rollout), prerequisites, segments, audit log, evaluation context
- evaluator.ts: pure evaluation engine — schedule checking, prerequisite dependencies (circular detection), individual targeting, targeting rules (AND clauses), segment matching, percentage rollout (FNV-1a), OS version/platform/region filtering
- repository.ts: 3 collections — feature_flags, flag_segments, flag_audit_log
- routes.ts: 18 endpoints — flag CRUD, toggle, archive, kill switch (with tag filter), segment CRUD, audit log, POST /flags/evaluate (multi-variate), SSE /flags/stream, legacy /flags/poll backward-compat
- seed.ts: updated to produce full FeatureFlagDoc with variations, version
- flags.test.ts: 63 tests — schema validation, evaluator engine, targeting rules, segments, prerequisites, scheduling, gradual rollouts, multi-variate, version comparison, deterministic hashing
- @bytelyst/events: added flag.created, flag.updated, flag.deleted, flag.kill_switch event types
- @bytelyst/feature-flag-client: multi-variate support (getValue, getEvaluation, getAllEvaluations), SSE streaming mode, onChange listeners, auth token injection
- event-dispatcher.ts + webhooks/types.ts: wired new flag events
2026-03-21 11:44:49 -07:00
saravanakumardb1
ce08587680
feat(secure-storage-web): create @bytelyst/secure-storage-web — encrypted IndexedDB storage
...
- IndexedDB-backed key-value store with non-extractable AES-256-GCM CryptoKey
- Key material never leaves browser crypto subsystem
- API: set, get, delete, clear, has, keys — all async
- Namespace isolation for multi-app usage
- Falls back to localStorage when SubtleCrypto unavailable
- 16 Vitest tests (fake-indexeddb), all passing
- Add IndexedDB globals to root ESLint config
2026-03-21 11:19:19 -07:00
saravanakumardb1
1bce981f43
feat(client-encrypt): create @bytelyst/client-encrypt — Web Crypto API encryption
...
- AES-256-GCM via SubtleCrypto (browsers + React Native with polyfill)
- Wire-compatible EncryptedField with @bytelyst/field-encrypt (server) and
BLFieldEncrypt (Swift/Kotlin native SDKs)
- encryptField, decryptField, generateKey, keyFromHex, keyToHex
- PBKDF2 key derivation (600k iterations per OWASP 2023)
- isEncryptedField type guard, toHex/fromHex helpers
- 22 Vitest tests, all passing
- Add Web Crypto globals to root ESLint config
2026-03-21 11:15:27 -07:00
saravanakumardb1
9bb322113a
feat(native-sdks): add Keychain/SecureStore key derivation to BLFieldEncrypt
...
- Swift: getOrCreateKey(service:account:), loadKey(), deleteKey()
- Generates random AES-256 key, persists as hex in BLKeychain
- Subsequent calls return the same key for stable per-device DEK
- Kotlin: getOrCreateKey(store:account:), loadKey(), deleteKey()
- Generates random AES-256 key, persists as hex in BLSecureStore
- Uses EncryptedSharedPreferences for at-rest protection
- All existing tests still pass (21/21 Kotlin)
2026-03-21 11:10:02 -07:00
saravanakumardb1
ee762b4612
feat(native-sdks): add BLFieldEncrypt to Swift + Kotlin platform SDKs
...
- Swift: BLFieldEncrypt.swift + BLFieldEncryptTests.swift (22 tests)
- CryptoKit AES-256-GCM, BLEncryptedField Codable struct
- encrypt/decrypt, AAD support, generateKey, keyFromHex, isEncrypted
- Data hex helpers (hexString, init?(hexString:))
- Kotlin: BLFieldEncrypt.kt + BLFieldEncryptTest.kt (21 tests)
- javax.crypto AES-256-GCM, BLEncryptedField data class
- encrypt/decrypt, AAD support, generateKey, keyFromHex, isEncrypted
- ByteArray/String hex extension functions
- Wire-compatible: same EncryptedField JSON structure as @bytelyst/field-encrypt (TS)
- { __encrypted: true, v: 1, alg: 'aes-256-gcm', ct, iv, tag, dekId }
- All hex-encoded, 12-byte IV, 16-byte auth tag
- Fix: ByteLystPlatform.kt getString() → read() (pre-existing compile error)
2026-03-21 10:58:02 -07:00
saravanakumardb1
b8ce14c259
test(broadcast-client): cover deep links and client
2026-03-21 10:56:49 -07:00
saravanakumardb1
bb3f5385fc
feat(field-encrypt): create @bytelyst/field-encrypt package with AES-256-GCM envelope encryption
...
- 10 source files: types, aes-gcm, 3 key providers (memory/env/akv), envelope, key-cache, dek-store, guards, migration, factory
- 42 Vitest tests: AES-GCM roundtrips, tamper detection, unicode, 100KB payloads, key providers, DEK cache TTL/LRU, envelope lifecycle, migration (dry-run + idempotent), config validation
- AKV MEK creation script (scripts/create-encryption-keys.sh) for 10 product MEKs
- .env.example updated with FIELD_ENCRYPT_* vars
2026-03-21 09:18:10 -07:00
saravanakumardb1
6856d23a2e
fix(swift-sdk): resolve BLAuditLogger + BLCrashReporter build errors in ByteLystPlatform
...
- BLAuditLogger is an enum (static API) — cannot be constructed; use .Type reference + configure()
- BLCrashReporter is @MainActor — defer construction to start() via Task { @MainActor }
2026-03-20 23:28:47 -07:00
saravanakumardb1
b9e37bb8b4
feat(telemetry-client,diagnostics-client): add createWebTelemetry + createWebDiagnostics convenience factories
...
- telemetry-client: createWebTelemetry() wraps createTelemetryClient() with web defaults
- diagnostics-client: createWebDiagnostics() wraps DiagnosticsClient with install ID + web defaults
- Eliminates ~70 lines of boilerplate per web app
- 11/11 telemetry tests pass, 21/21 diagnostics tests pass
2026-03-20 18:47:18 -07:00
saravanakumardb1
0d8c0a5ffe
feat(backend-flags,backend-telemetry): create shared flag registry + telemetry buffer packages
...
- @bytelyst/backend-flags: createFlagRegistry() with defaults, 6 tests
- @bytelyst/backend-telemetry: createTelemetryBuffer() with enabled switch, 5 tests
2026-03-20 08:02:17 -07:00
saravanakumardb1
08661bbd97
feat(backend-config): create @bytelyst/backend-config package with shared Zod schema
...
- baseBackendConfigSchema: PORT, HOST, NODE_ENV, CORS_ORIGIN, SERVICE_NAME,
DB_PROVIDER, COSMOS_*, JWT_SECRET, PLATFORM_JWKS_URL
- parseBackendConfig() helper for env parsing
- Products extend via baseBackendConfigSchema.extend({...})
- 8 tests passing
2026-03-20 07:51:22 -07:00
saravanakumardb1
ea2cb4c0e6
fix(fastify-auth): support getter functions for jwtSecret/jwksUrl
...
Allows dynamic config resolution (e.g. test mocks that change config between calls).
Options can now be string | (() => string) for both jwtSecret and jwksUrl.
2026-03-20 07:38:26 -07:00
saravanakumardb1
f61a1f0b04
feat(fastify-auth): create @bytelyst/fastify-auth package with JWT auth + request context
...
- createAuthMiddleware(): RS256 JWKS + HS256 fallback (parameterized)
- createRequestContext(): productId validation + getUserId()
- Fastify request type augmentation for jwtPayload
- 15 tests passing
2026-03-20 07:30:53 -07:00
saravanakumardb1
f56672508a
chore: update dependencies
2026-03-19 21:25:30 -07:00
saravanakumardb1
70635ba80e
feat(kotlin-sdk): add ByteLystPlatform unified entry point + 2 new test files (4.2)
...
New source:
- ByteLystPlatform.kt — unified entry point wiring all services via Context + Config
(secureStore, client, auth, telemetry, flags, killSwitch, auditLog)
- start(userId?) / stop() lifecycle for telemetry + flags
- Mirrors Swift ByteLystPlatform API
New tests (2 files):
- BLKillSwitchResultTest — ok(), disabled, default, copy
- BLTelemetryEventTest — serialize, deserialize, optional fields
2026-03-19 21:09:24 -07:00
saravanakumardb1
933390e89b
feat(swift-sdk): add ByteLystPlatform unified entry point + 5 new test files (4.1)
...
New source:
- ByteLystPlatform.swift — unified entry point wiring all services
(config, client, telemetry, flags, killSwitch, crashReporter, keychain, auditLog, auth)
- BLKeychainAccessor — convenience wrapper binding BLKeychain to a bundleId
- start(userId:) / stop() lifecycle for telemetry + flags + killSwitch
New tests (5 files, ~25 test cases):
- ByteLystPlatformTests — init, start/stop, idempotency, keychain accessor
- BLPlatformConfigTests — default + custom init
- BLKillSwitchClientTests — default state, reset
- BLFeatureFlagClientTests — empty flags, unknown key, stop
- BLTelemetryClientTests — installId stability, session rotation, track/flush
Also: add .build/ and .swiftpm/ to .gitignore
2026-03-19 21:05:58 -07:00
saravanakumardb1
1fda345d38
feat(dashboard-shell): add @bytelyst/dashboard-shell package (4.3) — 41 tests
...
Components:
- DashboardShell — main layout combining sidebar + topbar + content area
- Sidebar — collapsible nav with sections, badges, active state, auto-settings link
- TopBar — user avatar/menu, notifications bell, sign out, custom actions
- ProfilePage — avatar, name/email form, loading/error/success states
- BillingPage — current plan card, status badge, trial info, plan comparison grid
- SettingsPage — section-based layout with empty state
Features:
- NavItem[] or NavSection[] for flat or grouped navigation
- ShellFeatures toggle: profile, billing, settings, notifications, themeToggle
- ShellUser with avatar, role, initials fallback
- onNavigate callback for SPA routers (Next.js, etc.)
- Collapsible sidebar with toggle button
- All styled via --bl-shell-* CSS custom properties with fallbacks
- 41 tests covering all components
2026-03-19 20:54:28 -07:00
saravanakumardb1
6354711f97
feat(create-app): add CLI Scaffolder (3.1) — interactive product repo generator
...
Scaffolder (scaffolder.ts):
- Interactive prompts: product name/ID/tagline/domain, port, platforms, features
- --from product.json flag to skip prompts (non-interactive)
- --dry-run preview mode
- Generates backend (always) + web (Next.js) + mobile (Expo) based on selection
- Template engine with {{VARIABLE}} and {{#IF FEATURE}} conditional blocks
- Backend scaffold: Fastify 5, Zod config, JWT auth, datastore, server.ts
- Web scaffold: Next.js 16 App Router, layout, page, product-config
- Mobile scaffold: Expo with app.json, index screen
- Root files: product.json, .gitignore, .env.example, README.md
Tests: 26 passing (11 template-engine + 15 scaffolder)
Tested with ActionTrail product.json dry-run — correct output
2026-03-19 20:31:35 -07:00
saravanakumardb1
43439e9c85
feat(auth-ui): complete Auth UI Kit (3.2) — 7 new components, 54 tests
...
New components:
- RegisterForm — name, email, password, confirm, terms, password strength
- ForgotPasswordForm — email input with success/error states, back link
- ResetPasswordForm — new password + confirm with strength indicator
- VerifyEmailForm — 6-digit code input with resend, numeric-only filter
- OnboardingShell — step indicator, progress bar, back/next/complete nav
- AuthPageLayout — full-page centered card with product branding
- PasswordStrengthBar — visual bar + label (weak/fair/good/strong)
Existing components preserved: LoginForm, MfaChallenge, SocialButtons
All styled via --bl-* CSS custom properties for product theming
54 tests (13 existing + 41 new) — all passing
2026-03-19 20:25:57 -07:00
saravanakumardb1
f051942ef6
feat(create-app): add API Route Generator (3.3) + AGENTS.md Auto-Generator (3.4)
...
3.3 API Route Generator (api-routes.ts):
- Two modes: 'direct' (Cosmos DB CRUD) and 'proxy' (backend fetch)
- Generates route.ts + [id]/route.ts (Next.js App Router named exports)
- Direct mode also generates lib/schemas/ + lib/repositories/ files
- withErrorHandler HOF wrapper, Zod validation, auth check
- Dry-run preview, configurable methods, skip existing files
3.4 AGENTS.md Auto-Generator (agents-md.ts):
- Reads shared/product.json for identity, port, domain
- Scans repo for backend modules, lib files, test counts
- Generates full AGENTS.md with identity, layout, stack, conventions
- --update preserves CUSTOM sections
- Creates CLAUDE.md, .cursorrules, .windsurfrules symlinks
2026-03-19 20:17:02 -07:00
saravanakumardb1
c3f81cc97a
fix(kotlin-sdk): add platform query parameter to kill-switch URL
...
BLKillSwitchClient was missing the platform query parameter that
BLFeatureFlagClient already sends. This caused the test
'sends correct query parameters' to fail.
2026-03-19 20:03:26 -07:00
saravanakumardb1
6ba86e0bf4
fix: replace corepack pnpm with pnpm in pretest/predev scripts
...
Node 25 removed corepack as a built-in. Replace all 'corepack pnpm'
invocations with direct 'pnpm' calls since pnpm is installed globally.
Affected: platform-service, tracker-web, blob, testing, LLM dashboard
2026-03-19 19:57:16 -07:00
saravanakumardb1
a0dafcd693
feat(config): overhaul product manifest schema + 51 tests
...
- Redesigned schema to match real-world product.json files across ecosystem
- Changed 'id' → 'productId' (matches all existing files)
- Support bundleId as string OR per-platform object
- Added backendPort, tagline, primarySurface, appStore, bundleIds fields
- Added legacy identity fields (licensePrefix, configDirName, envVarPrefix, etc.)
- Added duplicate container name validation via superRefine
- Fixed loadProductManifestSync: require() → readFileSync (ESM-safe)
- Added BundleIdSchema and AppStoreSchema exports
- Added 'mac' platform option
- 51 new tests covering all schemas, validation, file loading, real-world manifests
2026-03-19 19:43:46 -07:00
saravanakumardb1
6a79742605
chore(kotlin-sdk): add .gitignore and remove tracked build artifacts
2026-03-19 19:02:44 -07:00
saravanakumardb1
35487137e1
feat(kotlin-sdk): restore 13 deferred UI files — diagnostics, clients, Compose UI, passkeys, deep links
...
- Move 5 diagnostics files into src/main/.../diagnostics/ (DiagnosticsTypes, DiagnosticsClient, BreadcrumbTrail, DeviceStateCollector, NetworkInterceptor)
- Move 3 API clients (BLBroadcastClient, BLSurveyClient, BLFeedbackClient) — fix toMediaType, serializer pattern, coroutine imports
- Move 2 pure Kotlin files (DeepLinkRouter, BLPasskeyManager)
- Move 3 Compose UI files into src/main/.../ui/ (BLAuthUI, SurveyUI, BroadcastUI)
- Move 2 test files (DiagnosticsTypesTest, BLAuthClientSmartAuthTest) — fix JUnit5, Device JSON, serializer
- Add coil-compose dependency for AsyncImage
- Add appVersion/osVersion fields to BLPlatformConfig
- Fix OkHttp Headers iteration (name/value indexed access)
- Fix BroadcastUI string comparisons for status/style/priority
- Remove _deferred_ui/ directory — all files now compile in src/
- 57 tests total, 56 pass (1 pre-existing BLKillSwitchClientTest failure)
2026-03-19 18:25:35 -07:00
saravanakumardb1
90f8f64937
ci: update CI/CD configuration
2026-03-19 18:11:27 -07:00