зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1570821 - limit height for variable tooltip and decrease left padding r=davidwalsh
Added and if statement to `calculateMaxHeight()` to prevent it from exceeding 250, and decreased the padding of the `.object-node` selector. Differential Revision: https://phabricator.services.mozilla.com/D41478 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
243b7d4b1e
Коммит
151cfd6cab
|
@ -52,6 +52,10 @@
|
|||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.popover .preview-popup .object-node {
|
||||
padding-inline-start: 0px;
|
||||
}
|
||||
|
||||
.preview-token:hover {
|
||||
cursor: default;
|
||||
}
|
||||
|
|
|
@ -84,10 +84,14 @@ export class Popup extends Component<Props> {
|
|||
if (!editorRef) {
|
||||
return "auto";
|
||||
}
|
||||
return (
|
||||
editorRef.getBoundingClientRect().height +
|
||||
editorRef.getBoundingClientRect().top
|
||||
);
|
||||
|
||||
const { height, top } = editorRef.getBoundingClientRect();
|
||||
const maxHeight = height + top;
|
||||
if (maxHeight < 250) {
|
||||
return maxHeight;
|
||||
}
|
||||
|
||||
return 250;
|
||||
};
|
||||
|
||||
renderFunctionPreview() {
|
||||
|
|
Загрузка…
Ссылка в новой задаче