Commit Graph

18 Commits

Author SHA1 Message Date
Amiram_se 907bc23e25 feat(island,tools): share popover, 360 sheet popover, form section and avatar field options, switch frozen track, prediction card link, select, list row, tab links and info tip options, body-compact and stat type tokens, button document reload, list formatting
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 19:34:24 +04:00
Amiram_se d3137973ab feat(island): media strip, media frame with expand badge, list row keep-end, offline freeze, upload tile and toast placement follow-ups
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 18:46:36 +04:00
Amiram_se c6c1aa33b2 feat(island): v6 compositions — list rows, page header, section title, pinned footer, result panel, stat tile, meter, search field, avatar stack, timeline, code input, key-value, analyst card; new chips, segmented, avatar sizes, toast placement, account menu items, post and prediction card names and close reason
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 17:38:43 +04:00
Amiram_se db0fa7c86e feat(island,tools): select, switch, info tip, jalali date helpers
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-09 16:11:12 +04:00
Amiram_se a668b17590 feat(island): count badge, date time, detail row, filter chips, spinner sizes, carousel nav buttons
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-08 22:36:22 +04:00
Amiram_se 2be04f9d1d feat(island): landing type, tokens, section heading, sample frame, fact card
Add the landing's own display type (hero and section Typography variants),
a page container, an image shade and a 720px tablet breakpoint used only by
the landing's grids (0028). Add three domain-free molecules the landing
shares: SectionHeading, SampleFrame (real components with made-up data,
inert and labelled) and FactCard.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 23:02:58 +04:00
Amiram_se 88384fa72d feat(island): post card access and share, action menu, tab links, segmented choice
Island pieces for the channel, post page, composer and dashboard.

- New molecules: ActionMenu (links or actions in a popover), TabLinks (route tabs), SegmentedChoice.
- PostCard: owner footer, share menu on desktop, access note for an open premium post, frozen CTA reason on a locked one.
- LockedTeaser keeps the gate's place while the viewer is unknown; Modal gains sizes; Lightbox and skeleton presets for feeds and headers.
- Button: `pressableWhenFrozen`, a frozen look whose press still calls onClick (explain or check instead of a tooltip).
- TextInput counts UTF-16 units, as the native maxLength does, so the counter reaches the limit with it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 20:29:33 +04:00
Amiram_se f4e9febad7 feat(island): toast close button, own motion and clock, one at a time
Toast follows the updated Lumina design system.

- ✕ «بستن اعلان» on every toast shown by showToast: 44px, its hit area reaching into the padding; the label comes from the Toaster's new `closeLabel`.
- Motion: in over 200ms (rise 16px, fade in), out over 160ms (drop 8px, fade out); reduced motion keeps a plain 120ms fade. The entrance plays once, even when the region moves into a dialog.
- Text wraps evenly; with an action, text past two lines moves the action under it, measured again when the width changes.
- Toast runs its own clock (sonner gets duration Infinity): it pauses while a pointer is on the region (hover, press, hold, swipe), while keyboard focus is inside it, and while the tab is hidden.
- One toast at a time: a new one replaces the old; while keyboard focus is in the region it waits until focus leaves. Every toast gets a fresh id, so `showToast` drops its `id` option.
- The Toaster slot overrides sonner's slide and stack with inline style instead of !important, and `toastOptions` is no longer a prop.
- market: AppShell passes `closeLabel`; showActionError no longer passes an id.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 22:42:11 +04:00
Amiram_se 297f0b2cbd feat(island): focusable choice cards and file fields, state skeleton, timed toasts
- ChoiceCard and FileField forward a ref to their real input, so a form can move focus to the first empty card or upload box.
- SkeletonPreset gains a `state` preset (art, heading, line, action).
- Every toast closes by itself: errors after 8 s (10 with an action), others after 4 s (6 with an action).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-06 21:47:18 +04:00
Amiram_se 9216bc8177 feat(island,tools): form pieces for the profile step
- Atoms: Chip (toggle with aria-pressed), Checkbox, FieldError (alert line
  under a group), LinkButton (a button that looks like a link; SupportLink now
  uses it), RowButton (56px choice row for sheets), and a 96px Avatar size.
- Molecules: ChipGroup (named fieldset of chips with its error), FormSection
  (titled form part with an optional marker and hint), AvatarField (photo
  pick, change, remove, upload progress, failed state with retry).
- Dialog, Sheet and Modal take `onExited`, called once the dialog has left
  the top layer. The page is inert until then, so focus moves there.
- tools/format: `time()` for a time of day in Tehran (`14:05`).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 22:32:43 +04:00
Amiram_se 025c68dd0d feat(island): file field, form skeleton, toast details and link start icon
- FileField molecule: one file for a form, with a picker box, thumbnail,
  name, size, remove button, inline error and upload progress.
- SkeletonPreset gains a `form` preset (heading, n fields, button, link).
- Toast takes a second `description` line; showToast takes a stable `id`,
  so a repeated failure replaces its toast instead of stacking.
- Link takes a leading `iconStart`, such as edit before «ویرایش شماره».

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 20:06:42 +04:00
Amiram_se 86944adb97 feat(island,apps): serve fonts and icon sprite under fixed names
Replace the hashing asset plugin with two build-time plugins that never
rename their files, so an unchanged font or sprite stays in every
visitor's cache across deploys (0011, 0012):

- icon-sprite-plugin builds icons/*.svg with svgo into
  public/icons/symbol-defs.svg. The Icon atom links it as
  symbol-defs.svg?v=<ICON_SPRITE_VERSION>; the file's first line stamps
  its version, so dev warns when the sprite changes without a bump.
- font-copy-plugin copies island fonts/ byte for byte into public/fonts/
  and warns when a font changes under its old name.
- island fonts.css declares both Yekan Bakh faces with root paths and a
  fallback face; theme.css points font-sans and font-latin at them.
- Root layouts preload CRITICAL_FONT_URL. next/font is gone.
- Both apps serve /fonts and /icons as immutable.
- island env, the apps' island-env bootstrap, NEXT_PUBLIC_ISLAND_* and
  NEXT_PUBLIC_CDN_ORIGIN are removed; paths live in island constants.ts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 19:00:46 +04:00
Amiram_se 0bee35290d refactor(island): move dialog to atoms, modal and sheet to molecules
Imports and the root index follow the new paths.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 19:00:28 +04:00
Amiram_se bbf84069c9 feat(island,apps): island asset plugin writes hashed fonts and icon sprite
Add withIslandAssets (island tools/asset-plugin) per ADR 0008. On next dev
and next build it builds the svgo sprite from src/icons and copies the
Yekan Bakh fonts into the app's public/ under content-hashed names, puts
their paths in env (NEXT_PUBLIC_ISLAND_*) and serves them with an
immutable Cache-Control. Files are written in headers(), which only Next
calls, because Nx's next plugin also evaluates the config from the
workspace root.

- island env (setEnv/getEnv); Icon reads the sprite path from it
- icon-sprite-plugin becomes icon-name-extraction (IconName type only);
  the committed sprite.svg is removed
- bull and bear register the plugin, validate the paths, pass them to
  island through their bootstraps, and add an optional CDN origin for fonts
- gitignore the generated files; Nx build outputs include them

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-05 11:58:56 +04:00
Amiram_se cd082e5ed9 feat(libs,island): carry API error details and let fallbacks focus their heading
- HttpError keeps the server's structured `details` (set by mapErrorBody), so
  callers can read a changed price or a frozen unfollow
- ErrorState and StateMessage accept a headingRef; page fallbacks move focus to it

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 21:33:07 +04:00
Amiram_se d68ae9d0a4 feat(island): sync components with the Lumina design system
New components:
- Lightbox, NetworkStatus (+ useOnline), TierOption, SkeletonPreset

Rebuilt to the design system:
- PredictionCard: range bar, open KPIs, closed hero, price ladder, horizon progress, seal, locked veil
- CreatorStats: form curve, outcome split, KPI tiles, insights and streak; null renders nothing
- PostCard, LockedTeaser, MediaCarousel: owner action rules, expanded variant, viewer CTA, locked order
- SubscriptionCard: active/suspended/expired/refunded, compact density, amount and support rows
- Countdown, ResendCode, OtpInput: absolute end times, DS wording and thresholds, WebOTP

Fixes:
- Dialog: waits only for finite exit animations, keeps non-dismissible halts open, focuses the
  panel, closes on scrim presses only, mounts the panel only while open
- Toaster: moves its region into the open dialog so toasts show and stay tappable over sheets
- Button: blocked submit, frozen cursor, loading links; TextInput focus border; Card, Banner,
  ChoiceCard, StepProgress, ErrorState, Amount and Avatar details
- Tokens: muted status tracks, inverse controls, scrim chip, inverse and lightbox focus rings;
  the spinner keeps turning under reduced motion

Adds sonner and svgo; island gets the icons target and the hooks subpath.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 17:23:59 +04:00
Amiram_se 5e35fbd6f2 feat: libs, tools 2026-10-02 19:42:11 +04:00
Amiram_se 7dde8dd6f8 feat: scaffold 2026-10-02 18:19:11 +04:00