-
Notifications
You must be signed in to change notification settings - Fork 178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve captions appearance when there is also a CTA #13477
Conversation
…grid-layer` `amp-story-captions` adds caption in shadow-dom. Thus, parent `div` container of the `amp-story-captions` won't reflect the actual size of the `amp-story-captions`. This will fix this issue by setting `max-height` of the `amp-story-grid-layer.align-bottom` exactly to the shadow-dom component. Additionally, fixed-height layout of the `amp-story-captions` is changed to container in order to occupy only required space.
Any thoughts on trying out |
@swissspidy I tried
May we go with [2.1] approach? |
Interesting! Thanks for sharing the various options, much appreciated! Let's try [2.1] indeed 👍 |
Plugin builds for 292eb55 are ready 🛎️!
|
Size Change: +29 B (0%) Total Size: 2.75 MB ℹ️ View Unchanged
|
Note that two snapshot tests in And that one Karma test is just flakey. Maybe we can make it more robust at some point. |
The goal of the PR is to fix layout of the video subtitles (when present) so that they won't display below CTA button.
Summary
amp-story-captions
adds caption in shadow-dom. Thus, parentdiv
container of theamp-story-captions
won't reflect the actual size of theamp-story-captions
.This will fix this issue by setting
max-height
of theamp-story-grid-layer.align-bottom
exactly to the shadow-dom component.Additionally, fixed-height layout of the
amp-story-captions
is changed to container in order to occupy only required space.User-facing changes
Not applicable.
Testing Instructions
Follow #13425 for the testing instruction.
Reviews
Does this PR have a security-related impact?
No.
Does this PR change what data or activity we track or use?
No.
Does this PR have a legal-related impact?
No.
Checklist
Type: XYZ
label to the PRFixes #13425