diff --git a/app/lib/features/chat/conversation/chat_task_presentation.dart b/app/lib/features/chat/conversation/chat_task_presentation.dart index 1a31a194..9560b912 100644 --- a/app/lib/features/chat/conversation/chat_task_presentation.dart +++ b/app/lib/features/chat/conversation/chat_task_presentation.dart @@ -2,6 +2,7 @@ import 'package:flutter/material.dart'; import '../domain/chat_task_metadata.dart'; import '../../../ui/text/monospace.dart'; +import '../../../ui/theme/app_design_tokens.dart'; Color taskSecondary(BuildContext context) => Theme.of(context).colorScheme.onSurfaceVariant; @@ -72,6 +73,9 @@ class ChatTaskSurface extends StatelessWidget { @override Widget build(BuildContext context) => Card.filled( + // A design with its own panel fill (Paper's page under a hairline) + // draws the card in it rather than a filled tone. + color: AppDesignTokens.of(context).panel, margin: EdgeInsets.zero, child: Padding(padding: padding, child: child), ); diff --git a/app/notes/design-paper.md b/app/notes/design-paper.md new file mode 100644 index 00000000..9252a746 --- /dev/null +++ b/app/notes/design-paper.md @@ -0,0 +1,38 @@ +# Paper design + +A calm reading design (Settings > Design > Paper): warm paper page (sepia +charcoal "night paper" in dark), Source Serif 4 for reading text and titles, +the interface font for chrome, ink colours with one deep-blue accent, 8px +corners, hairline rules and a whisper of shadow only on menus, dialogs, sheets +and snack bars. + +## Tokens added to `AppDesignTokens` (all default to the Default look) + +- `transcript` (`TranscriptStyle.bubbles | prompt | manuscript`): how the chat + draws turns. Terminal = `prompt`; Paper = `manuscript` (block-quote operator + turns with a small-caps "YOU", serif prose, marginal activity note, italic + editorial notes for follow-ups/auto-continue). `tokens.terminal` now means + `transcript == prompt`. +- `composer` (`pill | underline`): Paper's composer is an underlined writing + area (`composer_underline.dart`). +- `selectedRow` (`tonal | framed | washed`): AppListRow's open row; replaces + the hard-coded Terminal frame. Terminal = `framed` (unchanged look). +- `reading` (`ReadingType`: family, height, measure in ch, scale, + figureWidth): reading text style (`chatMessageTextStyle`) and the chat + reading column width (`chatReadingWidthOf`). +- `panel`: fill of a flat design's own panels (settings groups, floating bar + pieces, task cards, the usage banner); `panelFill()` and `frameSide` helpers. +- `chatColorSaturation`: quietens chat colours (`chatColorShade`). + +## Adding a design + +See the `AppDesign` doc comment: add the enum value (id, label, one line), +a `_theme.dart` builder, its tokens and a `swatch`. Floating pieces +(app choice menu, code Copy hover, graph edge tooltip) follow the theme's +`popupMenuTheme`; custom radii go through `tokens.corners()` / `shape()`. + +## Font + +`fonts/source-serif-4/` (OFL, see fonts/README.md), plain assets loaded on +demand by `ensurePaperFonts()` when Paper's theme is first built; no network +font fetch. Its italic has no `smcp`, so small caps are spaced capitals.