Skip to content

Rework the Application blocks in the workspace style - #45

Merged
yyyyaaa merged 16 commits into
mainfrom
phat/application-revamp
Sep 25, 2026
Merged

yyyyaaa merged 16 commits into
mainfrom
phat/application-revamp

Conversation

@yyyyaaa

@yyyyaaa yyyyaaa commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Brings every block under the docs site's Application menu onto the visual language of Agents Builder and Billing, through a shared workspace-kit. Public contracts, adapters, policies, and host-owned behaviour are unchanged; new props are optional.

Shared foundation

  • workspace-kit now owns the Billing surfaces (panels, tables, stat tiles, empty states) and the Agents Builder canvas (pan/zoom, node cards, wires); both keep their existing exports.
  • Published as the @constructive-io/ui/workspace-kit npm subpath (not from the root, since it needs motion ≥ 13.4).
  • Collapsed rail rows are centred squares; nav rows gain an optional link mode for host routers.

Blocks

  • Org Chart: rebuilt on the shared canvas (React Flow dropped) with a details panel, folding teams, drag-to-reassign with a keyboard alternative, and loading/empty states. New optional props: showDetails, onSelectNode, defaultCollapsedIds.
  • Storage: Storage Browser rebuilt on the workspace shell; the Storage feature pack renders it; docs unified into one Storage section (/blocks/storage, /blocks/storage/browser; the old /blocks/storage-browser is removed).
  • App access and Organizations: pill tabs with counts, responsive tables, member access in a side panel, and the hierarchy on Org Chart. Fixes selects that showed raw values.
  • Notifications: an inbox grouped by day with unread/category filters, hover actions, and unread shown by type weight and a tinted tile (no dots).
  • Console Kit: new ConsoleShell on the workspace shell (host-routed links, account menu, phone drawer), with restyled loading, unavailable, error, and sign-in states. The docs preview renders the real shell.
  • Schema Builder: sidebar with a guide line and field counts, pill tabs, and a shared frame for Relationships, Indexes, and Policies. Hovering one end of a relationship highlights the other. Also a calmer fields table, a compact Types library, and checkbox-style constraint cards with consistent form spacing.
  • Model Selector: model details open as a side card beside the highlighted row, like a submenu. Reasoning levels are a stacked menu, and crossing rows on the way to the card no longer swaps it.
  • JSON documents: blocks-ui selects show option labels; patterned strings lower to single-line inputs.

Docs site

  • Schema Builder preview runs on a full project-tracker schema (every relationship kind, several index methods, RLS policies) plus a feature tour.
  • JSON documents page follows the shared Application layout with a framed live preview and pagination.
  • The sidebar moves to the workspace scale: 32px rows, collapsible sentence-case sections, and a guide line with a blue segment for the current page.

Test plan

  • pnpm check (package parity, all test suites)
  • pnpm build:registry, with exact registry dependency edges
  • Clean registry installs: org-chart, agents-builder, billing-account, billing-console, storage-browser, feature-pack-storage, console-module-storage, preset-b2b-storage, the App access and Organizations packs and modules, feature-pack-notifications, console-module-notifications, console-kit-core, console-kit-nextjs, preset-full, schema-builder
  • pnpm build:pages artifact verification (98 public routes, 16 preview routes)
  • Production Storybook build
  • Browser QA in dark, light, and phone widths for each block and the docs sidebar

Generated with Devin

Move the generic surfaces (panel, table surface, stat tile, key-value list,
empty state) from billing-kit and the Agents Builder pan-and-zoom canvas
(viewport, node shell, wires, zoom controls) into workspace-kit so every
application block can use them. billing-kit keeps re-exporting its surfaces.

Publish the kit as the subpath-only npm export @constructive-io/ui/workspace-kit
(it needs motion >= 13.4) so npm-built packages such as Schema Builder can use it.
Replace React Flow with the shared workspace canvas: double-framed person
cards, bezier reporting lines, folding teams, a details panel with the
reporting chain highlighted, drag-to-reassign with a drop preview and hint,
and a searchable change-manager dialog so the chart works from the keyboard
as an ARIA tree. Existing props are unchanged; showDetails, onSelectNode, and
defaultCollapsedIds are new and optional.
Buckets move into the workspace sidebar (a drawer on phones), files list on
a table surface with type-tinted glyphs and hover actions, a floating bar
acts on the selection, and files dropped on the list upload through the new
onDropFiles. The detail, bucket, and upload sheets, badges, breadcrumb, and
empty states share the workspace look. Folders (kind), host size labels,
onOpenFolder, and selectable let a host that lists prefixes reuse the same
browser. All additions are optional.
The pack keeps its resource, policy, and action contract but renders the
Storage Browser: buckets in the sidebar, folder crumbs, local search and
sort, uploads by button or drop, and confirmed deletes. Shared pack loading
and empty states use the workspace surfaces, and date-only timestamps no
longer show a midnight time. Org Chart and Storage docs previews load lazily.
Storage gets a single sidebar entry with an overview and tabs for the
Storage Browser (now at /blocks/storage/browser) and the feature pack, on a
shared doc-section model that Billing now uses too.
Section tabs become a pill track with counts, member, invitation, and
credential lists move onto table surfaces with tinted role and status labels,
member access opens in a side panel, and settings and capability checklists
sit in divided cards. Organizations gains an organization switcher in its
header and draws its hierarchy on the Org Chart canvas, with drag or keyboard
reassignment, position edits, and removals routed through the host actions.
Form state that followed incoming data now adjusts during render, and three
selects show labels instead of raw values. Pack contracts are unchanged.
Notifications group by the day they arrived, unread ones carry a tinted
bell tile and stronger type while read ones recede, and the inbox filters by
read state and category. Row actions appear on hover or focus and stay
visible on touch. The pack contract is unchanged.
Collapsed sidebar rows kept their full-width, left-padded layout, so icons sat
off-centre with extra space on the right. They are now centred squares that
match the rail's icon buttons, section headings no longer leave an empty
strip in the icon rail, and rows gain an optional link mode for hosts that
route through their own link component.
Console Kit renders through a new ConsoleShell on the shared workspace shell:
features in the sidebar as host-routed links with quiet state glyphs, the
account menu at its foot, a slim location bar, and the standard drawer on
phones instead of a bottom tab bar. Loading, unavailable, incompatible, load
failure, and sign-in states share the workspace surfaces, and the docs
preview renders the real shell. The configuration contract is unchanged.
The active pill used the card colour, which sits darker than the muted track
in dark mode, so the selected tab and filter barely showed. Tint it with the
foreground instead.
The sidebar, header, and all four tabs move onto the workspace scale:
- sidebar rows without repeated icons, one guide line with a blue segment
  for the current table, and field counts that give way to the actions menu
- pill tabs with icons and a quiet system-tables toggle
- Relationships, Indexes, and Policies share one view frame, card, badge,
  and empty state; pointing at one end of a relationship lights the other
- a calmer fields table, a one-line Types library, and raised rail tiles
  that read in light mode
- constraint cards behave as checkboxes, and every field in the field
  editor follows one spacing rhythm

Policy presentation and field key lookups are shared helpers, and field
rows are memoized. Adapter contracts and behaviour are unchanged.
The preview now runs on a project-tracker schema with relationships of every
kind, several index methods, and row-level security on every table, served
by a deterministic adapter. A feature tour describes each tab and where to
find it in the preview.
A select showed the stored value instead of its label once an option was
picked, a patterned string (a slug, a code) lowered to a textarea, and the
page title used a display size inside forms.
…n blocks

Lead with a framed live preview (with a full-page route), follow the shared
section order, add pagination, and pair the generated form with tabs for the
schema, the document, and the submitted values.
Rows drop to 32px with 13px type and instant hover, section headings become
quiet sentence-case collapsibles with counts (Application included, so every
heading aligns), and each section hangs off one guide line with a blue segment
marking the current page, as in the Schema Builder sidebar.
@tenki-reviewer

tenki-reviewer Bot commented Sep 25, 2026 •

Copy link
Copy Markdown

Review complete. No issues found — approved ✅.


The diff for this PR is empty — no changed files were detected at head SHA 48a74d9, so there is nothing to review.

Reviewed commit: 48a74d9

The detail strip sat below the list, so moving the pointer toward it crossed
other rows and swapped it out. It now opens beside the highlighted row like a
submenu, with reasoning levels as a stacked menu, and rows crossed on the way
to it wait before taking it over. It opens on the current model, flips left
when there is no room, and stacks below the list on narrow screens.
@yyyyaaa
yyyyaaa merged commit ead48d5 into main Sep 25, 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.

1 participant