Skip to content

Wolly platform monorepo: shared schema, real data, backoffice, strict-BLoC reader, CI/CD - #3

Merged
saintjanney merged 14 commits into
mainfrom
develop
Jun 16, 2026
Merged

Wolly platform monorepo: shared schema, real data, backoffice, strict-BLoC reader, CI/CD#3
saintjanney merged 14 commits into
mainfrom
develop

Conversation

@saintjanney

@saintjanney saintjanney commented Jun 16, 2026

Copy link
Copy Markdown
Owner

Promotes the full platform rework from develop (mock) to main (prod).

What's included

  • Monorepo: apps/reader (Flutter), apps/creator-hub (Next.js), apps/backoffice (Next.js), packages/schema, packages/firebase-config. npm workspaces + Turborepo; Flutter kept on its own toolchain. History preserved via subtree merge.
  • Shared contract: @wolly/schema + SCHEMA.md are the single source of truth for Firestore shapes.
  • Catalog fix: the Creator Hub now reads/writes the epubs collection in the reader's field contract (author, url, coverUrl, fileType, genre as a real genre id), so books published in the hub appear in the reader.
  • Real data: dashboard analytics aggregate from purchases + epubs; genres back onto the real genres collection (mocks removed).
  • Backoffice: staff console for the publishing workflow, review moderation (approve recomputes a book's rating), and genre management.
  • Reader → strict BLoC: ReaderSettingsProviderReaderSettingsCubit, profile → ProfileCubit + AuthBloc, legacy provider/ChangeNotifier and dead screens removed. Also fixed a latent package:provider (undeclared dep) + providers/ case-sensitivity bug that broke Linux builds.
  • CI/CD: deploy.yml (develop → mock, main → prod; web → Hosting targets, reader → web Hosting + Android APK via App Distribution) and ci.yml (web build/lint/typecheck + flutter analyze). Android toolchain bumped (Gradle 8.9 / AGP 8.7.0).

Verification

The latest develop deploy is fully green — all three surfaces built and deployed to the mock environment, and the reader APK was distributed to the qa group. Merging this publishes to prod (live Hosting + production testers).

allenjanney and others added 14 commits October 4, 2025 14:47
…tyling

- Added Firebase service account keys to .gitignore for security.
- Updated next.config.ts to enable static export and configure image optimization.
- Enhanced package.json and package-lock.json with new dependencies for Firebase and UI components.
- Improved README.md with detailed project description, features, and setup instructions.
- Refined global styles in globals.css, including new animations and component styles.
- Updated layout and main page structure to incorporate authentication and navigation features.
- Implemented loading states and user redirection based on authentication status in the main page.
…67883f3b'

git-subtree-dir: apps/creator-hub
git-subtree-mainline: 32d8869
git-subtree-split: 5d97a65
…r's contract

- BookService reads/writes epubs (was: books), so books published in the hub
  appear in the reader immediately
- createBook/updateBook now write the reader-contract fields: author, url,
  coverUrl, rating, fileType (derived from manuscript), and genre (a genres
  doc id resolved from the first category)
- new GenreService backs genres with the real Firestore genres collection
  (seeds an empty collection); CreatorService delegates to it
- consume the shared @wolly/schema package (transpilePackages)
Replace AnalyticsService mock generators with aggregation over the purchases
and epubs collections, scoped to the creator's books:
- overview stats, revenue-over-time, per-book performance, geographic split
- getRevenueData/getGeographicData now take the creator userId
Payout history in settings still uses mock data (needs a payments model) —
tracked as a follow-up.
New Next.js app (apps/backoffice) on the shared Firebase project + @wolly/schema:
- Overview stats (books, published, pending reviews, genres)
- Books: move titles through the publishing workflow (publish toggles reader visibility)
- Reviews: approve/reject/flag pending reviews; approving recomputes the book's rating/reviewCount
- Genres: list and add genres
Added apps/backoffice to the npm workspaces.
- deploy.yml: develop -> mock, main -> prod
  - web (creator-hub, backoffice) to Firebase Hosting targets
  - reader web to its Hosting target; Android APK to App Distribution
  - auth via FIREBASE_SERVICE_ACCOUNT secret (never committed)
- ci.yml: typecheck/lint/build web apps on PRs
- CLAUDE.md / AGENTS.md: branch+deploy policy, schema contract, commit rules
- gitignore service-account keys
- ReaderSettingsProvider (ChangeNotifier) -> ReaderSettingsCubit
- profile now a feature backed by ProfileCubit + AuthBloc (was MockProfileProvider)
- LibraryProvider/GenreProvider reclassified as repositories (feature-first);
  screens use them as data sources, state via BLoC/local widget state
- delete dead legacy code: lib/Providers/*, legacy Screens (create_account,
  dashboard, profile, login, wolly_root, admin)
- removes the last package:provider imports (it was not even a declared
  dependency, which broke Linux/CI builds) and a providers/ vs Providers/
  case-sensitivity bug
- CI: add flutter analyze gate for the reader
Flutter's stable toolchain requires Gradle >= 8.7; the Android release build
failed on the pinned 8.3. AGP 8.2.1 runs on Gradle 8.9.
…(was 8.2.1)

Flutter's stable toolchain requires AGP >= 8.6.0; pairs with Gradle 8.9.
…visory in CI

- remove unused app_config and main_navigation imports left after the BLoC refactor
- CI lint (web) and flutter analyze (reader) are advisory for now so the
  pre-existing lint/analyzer debt doesn't block deploys; ratchet to blocking
  once cleaned up
@saintjanney
saintjanney merged commit 7a2756e into main Jun 16, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants