#542
Strike and rewrite
A rewrite line: one struck-out word with an animated pen line, followed by an animated highlighted replacement.
Hand this to your AI. It names the exact library parts, timings and accessibility promises of this demo.
Build the "Strike and rewrite" pattern (@codeatlasdev/ui demo #542, display/strike-through) in my app.
Call get_demo({ ids: ["#542"] }) first and keep its structure. It needs @codeatlasdev/[email protected].
Use: Editorial strike-through-and-rewrite effects where the removed text stays announced as deleted and the animation respects reduced motion.
Keep these library parts, with the props and tokens the demo uses:
- Highlight, StrikeThrough from "@codeatlasdev/ui"
Behaviour to keep:
- `<StrikeThrough animated>workarounds</StrikeThrough>` draws the line on mount
- `<Highlight animated>one-shot components</Highlight>` follows as the replacement
- The paragraph uses `--ca-font-size-h4`
Reduced motion: the demo handles it; keep that branch.
Keyboard: not an interactive control.
Change only the copy and the data. Use the theme tokens (--ca-*), never raw colours. Library parts
- Highlight
@codeatlasdev/ui - StrikeThrough
@codeatlasdev/ui
How it is built
- `<StrikeThrough animated>workarounds</StrikeThrough>` draws the line on mount
- `<Highlight animated>one-shot components</Highlight>` follows as the replacement
- The paragraph uses `--ca-font-size-h4`
Related
Loading source.