Commit Graph

3 Commits

Author SHA1 Message Date
Youzini-afk
702b6ac493 fix(notice): fix compact layout broken by duplicate CSS blocks and missing overflow rules
Root causes:
1. Duplicate .st-bme-notice__title and .st-bme-notice__message blocks (from
   original code) were overriding the new transition-enabled versions,
   stripping transitions and causing missing overflow:hidden on __message.
2. .st-bme-notice::after pseudo-element CSS was accidentally merged into
   .st-bme-notice__message--marquee block during previous edit.
3. Compact layout .st-bme-notice__content had overflow:hidden with no
   min-width constraint, causing the title to collapse to 'ST...'.

Fixes:
- Removed all duplicate CSS blocks; single canonical definitions with transitions
- Restored ::after pseudo-element as separate rule
- Added max-width:320px with overflow:hidden explicitly for compact content
- Added normal content max-width:360px with overflow:hidden
- Restored missing .st-bme-notice__actions base rule with transition
- Added .st-bme-notice__message overflow:hidden for max-height animation
2026-04-29 17:25:19 +08:00
Youzini-afk
fe48e3eec9 feat(notice): add click-to-toggle between compact and detailed display modes
Click anywhere on the notice content area to toggle between compact and
detailed (normal) display modes. A subtle hint label '▸ 简洁' / '▸ 详细'
appears on hover.

CSS transitions animate the layout switch:
- Content area: max-width + opacity crossfade (280ms cubic-bezier)
- Message text: max-height expand/collapse + opacity fade (280ms)
- Actions: max-height + margin collapse + opacity fade (260ms)
- Container: grid-template-columns + padding + border-radius morph (260ms)

The switch uses a two-phase animation: content fades out (180ms), layout
changes via CSS transition, then content fades back in (60ms delay). This
prevents jarring content jumps during the layout shift.
2026-04-29 17:19:49 +08:00
Youzini-afk
feec17f3e3 Reorganize modules into layered directories 2026-04-08 01:17:57 +08:00