-
Notifications
You must be signed in to change notification settings - Fork 385
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
For the 'Preview AMP' button, replace tooltip with title attribute #4601
Conversation
Prevents an issue where the tooltip is cut off.
Should this be to the |
<Button | ||
className="amp-editor-post-preview" | ||
href={ href } | ||
title={ __( 'Preview AMP', 'amp' ) } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The label
attribute is changed to title
.
But other than that, this diff is just from indentation. There's no other change to <Button>
Develop branch, yes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That works! Thanks.
Prevents an issue where the tooltip is cut off.
Nice, thanks! |
Why was this particular tooltip cut off, but all other tooltips in that area work just fine? |
Because Gutenberg was using some slot-fill mechanism to locate the tooltip element elsewhere in the DOM so that it could be positioned over the element without other DOM elements overlapping. This wasn't the case for the AMP preview button. |
…phtml-2004041903580 * 'develop' of github.com:ampproject/amp-wp: (48 commits) Bump https-proxy-agent from 2.2.2 to 2.2.4 (#4596) Update dependency babel-jest to v25.3.0 (#4550) Update dependency core-js to v3.6.5 (#4558) For the 'Preview AMP' button, use a title instead of a tooltip (#4601) Bump stable tag to 1.5.3 Fix handling of Mustache templates (#4583) Stub request based on test scenario (#4588) Return early instead of storing eventual return value in variable Improve phpdoc and logic conditions Update links in pull request template Update contributing.md with link to wiki Remove engineering.md now that it is on the wiki Remove project-management.md since only applicable to Stories Add conditions for comment feed, trackback, robots, and favicon Fix typo in global phpdoc Update tests after block-library/style.css changes in Gutenberg 7.9 (#4579) Remove special conditions for Reader mode; remove need for $exit condition in redirects Fix translators comment Add comment explaining short-circuit behavior when query var is present Update version for _doing_it_wrong() from 1.5.3 to 1.6.0 ...
…filter-list-table-row-actions * 'develop' of github.com:ampproject/amp-wp: (56 commits) Bump https-proxy-agent from 2.2.2 to 2.2.4 (#4596) Update dependency babel-jest to v25.3.0 (#4550) Update dependency core-js to v3.6.5 (#4558) For the 'Preview AMP' button, use a title instead of a tooltip (#4601) Update pull request template based on new workflow Bump stable tag to 1.5.3 Fix handling of Mustache templates (#4583) Stub request based on test scenario (#4588) Return early instead of storing eventual return value in variable Improve phpdoc and logic conditions Update links in pull request template Update contributing.md with link to wiki Remove engineering.md now that it is on the wiki Remove project-management.md since only applicable to Stories Add conditions for comment feed, trackback, robots, and favicon Fix typo in global phpdoc Update tests after block-library/style.css changes in Gutenberg 7.9 (#4579) Remove special conditions for Reader mode; remove need for $exit condition in redirects Fix translators comment Add comment explaining short-circuit behavior when query var is present ...
…widgets-registration * 'develop' of github.com:ampproject/amp-wp: (88 commits) Fix grammar typo Bump CSS cache version Update composer.lock Use patch file instead of diff Update patch: Fix parsing CSS selectors which contain commas Update php-css-parser to dev-master#bc6ec74; remove patches/php-css-parser-138-extended.patch Add test to demonstrate failure to parse class names containing escaped fractions Restrict metaboxes which appear on the validated URL screen Update hook priority in test_add_admin_hooks Restrict row actions for taxonomy terms Add test for disable-inline-width on amp-img Exclude data-ampdevmode attribute exclusion rule Update spec to 2004142326360 to remove container layout from amp-list Bump https-proxy-agent from 2.2.2 to 2.2.4 (#4596) Update dependency babel-jest to v25.3.0 (#4550) Update dependency core-js to v3.6.5 (#4558) For the 'Preview AMP' button, use a title instead of a tooltip (#4601) Update pull request template based on new workflow Bump stable tag to 1.5.3 Fix handling of Mustache templates (#4583) ...
Summary
This fixes an issue where the tooltip was cut off:
Now, the
<Button>
has atitle
attribute, instead of being wrapped in a<Tooltip>
:Fixes #4590
Checklist