Merge pull request #14530 from Snuffleupagus/findResultsCount-height

Avoid the `findResultsCount` span taking up (vertical) space when hidden (PR 13261 follow-up)
This commit is contained in:
Tim van der Meij 2022-02-05 14:47:45 +01:00 committed by GitHub
commit 48139a0059
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 6 deletions

View File

@ -163,7 +163,6 @@ class PDFFindBar {
}
matchCountMsg.then(msg => {
this.findResultsCount.textContent = msg;
this.findResultsCount.classList.toggle("hidden", !total);
// Since `updateResultsCount` may be called from `PDFFindController`,
// ensure that the width of the findbar is always updated correctly.
this._adjustWidth();

View File

@ -502,7 +502,7 @@ html[dir="rtl"] #outerContainer.sidebarOpen #loadingBar {
.findbar.wrapContainers > div {
clear: both;
}
.findbar.wrapContainers > div#findbarMessageContainer {
.findbar.wrapContainers > div.findbarMessageContainer {
height: auto;
}
html[dir="ltr"] .findbar {
@ -691,6 +691,8 @@ html[dir="ltr"] .doorHangerRight:before {
#findMsg {
color: rgba(251, 0, 0, 1);
}
#findResultsCount:empty,
#findMsg:empty {
display: none;
}

View File

@ -141,11 +141,10 @@ See https://github.com/adobe-type-tools/cmap-resources
<label for="findEntireWord" class="toolbarLabel" data-l10n-id="find_entire_word_label">Whole Words</label>
</div>
<div id="findbarOptionsThreeContainer">
<span id="findResultsCount" class="toolbarLabel hidden"></span>
<div class="findbarMessageContainer">
<span id="findResultsCount" class="toolbarLabel"></span>
</div>
<div id="findbarMessageContainer">
<div class="findbarMessageContainer">
<span id="findMsg" class="toolbarLabel"></span>
</div>
</div> <!-- findbar -->