-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Closed
Labels
Description
High-level requirements
| Consideration | Ready when | Status |
|---|---|---|
| Component compatibility | Conformance with 0.1 (see below) | ✅ |
| Testing | Unit tests and e2e tests from 0.1 | ✅ |
| Internationalization | n/a | n/a |
| Analytics | n/a | n/a |
| Accessibility | Audit performed, 0.1 for reference | ✅ |
| Page experience | Audit performed | ✅ |
| Documentation | Written | ✅ |
| Storybook | Samples written | ✅ |
Component compatibility
Attributes to support:
-
min-font-size -
max-font-size
Migration Notes:
- 1.0 resizes to clientHeight and clientWidth, whereas 0.1 resize to offsetHeight and offsetWidth. The difference here is the exclusion of margins and borders from the fit-text coverage area.
Open tasks:
- Initial implementation in ✨ [amp-fit-text] Initial Bento component #28169
- Do not depend on
childrento resize in [amp-fit-text:1.0] Use ResizeObserver for content changes #28496 - Watch for attribute mutations in Bento mode.
- Remove the specifically attached MutationObserver for attributes in
amp-fit-textwhen a generic one is in place inPreactBaseElement. - The generic one should call
mutatedAttributesCallbackto handle Bento mode. - In AMP mode this will cause it to be doubly called -- need to fine tune this.
- Remove the specifically attached MutationObserver for attributes in
- Resolve infinite render issue when observing mutations on both
subtreeandattributes. - Support passing in a parser callback for PreactBaseElement
props -
Investigate e2e test failures foramp4ads-presetenvironments -
Remove constantline-heightand support configuringlineHeight - Polyfill ResizeObserver
- Make attrs media based
Reactions are currently unavailable