Skip to content

[FIR-296] Extend ff-avatar with numeric size, name initials, shape and tones - #62

Merged
mfg1986 merged 5 commits into
developfrom
feature/FIR-296_avatar-numeric-tones
Jul 23, 2026
Merged

[FIR-296] Extend ff-avatar with numeric size, name initials, shape and tones#62
mfg1986 merged 5 commits into
developfrom
feature/FIR-296_avatar-numeric-tones

Conversation

@mfg1986

@mfg1986 mfg1986 commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

What

Additive extension of ff-avatar covering Flydocs' real usage (86 hub-avatar uses, mostly decorative icon-chips with tones — FIR-296, FF-CAT-07):

  • size widened to 'sm' | 'md' | 'lg' | number — literal px with proportional initials scaling
  • name → auto-derived initials (compound names, unicode, whitespace; explicit initials still wins)
  • round (default true) / cornerRadius for square shapes
  • tone — decorative background palette, same 7 semantic values as FfBadgeColor; component tokens consumed with fallback (FIR-316 pattern), zero hex literals

No breaking changes: no default flipped, no export renamed; VR suite 15/15 with zero baseline diffs (default rendering untouched). Contract, catalog demos and both packages' [Unreleased] changelogs updated.

How to verify

  • pnpm nx test design-system — 627/627 (initials derivation edge cases + round-wins-over-cornerRadius contract covered)
  • pnpm nx serve playground --port 4311 → /catalog/avatar: new sections for numeric size, name initials, shape and tones

Traceability

Board ticket without owning PASO: key in branch and commit subjects.

mfg1986 added 5 commits July 23, 2026 10:59
…round/cornerRadius and tone

Adds a literal pixel size, automatic initials from `name` (explicit
`initials` still overrides it), an optional square shape via
`round`/`cornerRadius`, and a decorative `tone` background palette
mirroring ff-badge's color axis. Additive only: default rendering
(size 'md', round circle, no tone) is unchanged.
Widens size to accept a literal pixel number and adds name, round,
cornerRadius and tone, matching the ff-avatar implementation.
Covers numeric size, name-derived initials (with explicit override),
round/cornerRadius and all FfAvatarTone values, following the
existing DemoSection idiom.
Adds Unreleased entries to design-system and design-system-contract
changelogs for the additive ff-avatar API.
@mfg1986
mfg1986 merged commit 3741878 into develop Jul 23, 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