Skip to content

Commit

Permalink
Merge pull request #17077 from Snuffleupagus/css-rm-unneeded-alpha
Browse files Browse the repository at this point in the history
Remove unnecessary alpha-value from CSS `rgb` colors
  • Loading branch information
timvandermeij committed Oct 7, 2023
2 parents 905ad1f + 4ebddcb commit 89d8c63
Show file tree
Hide file tree
Showing 9 changed files with 95 additions and 95 deletions.
4 changes: 2 additions & 2 deletions test/annotation_layer_builder_overrides.css
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
.fileAttachmentAnnotation:not(.hasFillAlpha)
.popupTriggerArea {
opacity: 0.2;
background: rgb(255 255 0 / 1);
box-shadow: 0 2px 10px rgb(255 255 0 / 1);
background: rgb(255 255 0);
box-shadow: 0 2px 10px rgb(255 255 0);
}
.annotationLayer .fileAttachmentAnnotation.hasFillAlpha {
outline: 2px solid yellow;
Expand Down
4 changes: 2 additions & 2 deletions test/xfa_layer_builder_overrides.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@

.xfaLink {
opacity: 0.2;
background: rgb(255 255 0 / 1);
box-shadow: 0 2px 10px rgb(255 255 0 / 1);
background: rgb(255 255 0);
box-shadow: 0 2px 10px rgb(255 255 0);
}
10 changes: 5 additions & 5 deletions web/annotation_layer_builder.css
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,8 @@
:is(.linkAnnotation, .buttonWidgetAnnotation.pushButton):not(.hasBorder)
> a:hover {
opacity: 0.2;
background-color: rgb(255 255 0 / 1);
box-shadow: 0 2px 10px rgb(255 255 0 / 1);
background-color: rgb(255 255 0);
box-shadow: 0 2px 10px rgb(255 255 0);
}

.annotationLayer .linkAnnotation.hasBorder:hover {
Expand Down Expand Up @@ -291,9 +291,9 @@
}

.annotationLayer .popup {
background-color: rgb(255 255 153 / 1);
background-color: rgb(255 255 153);
box-shadow: 0 calc(2px * var(--scale-factor)) calc(5px * var(--scale-factor))
rgb(136 136 136 / 1);
rgb(136 136 136);
border-radius: calc(2px * var(--scale-factor));
outline: 1.5px solid rgb(255 255 74);
padding: calc(6px * var(--scale-factor));
Expand Down Expand Up @@ -327,7 +327,7 @@
}

.annotationLayer .popupContent {
border-top: 1px solid rgb(51 51 51 / 1);
border-top: 1px solid rgb(51 51 51);
margin-top: calc(2px * var(--scale-factor));
padding-top: calc(2px * var(--scale-factor));
}
Expand Down
20 changes: 10 additions & 10 deletions web/debugger.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
font: message-box;
}
#PDFBug {
background-color: rgb(255 255 255 / 1);
border: 1px solid rgb(102 102 102 / 1);
background-color: rgb(255 255 255);
border: 1px solid rgb(102 102 102);
position: fixed;
top: 32px;
right: 0;
Expand All @@ -33,8 +33,8 @@
width: var(--panel-width);
}
#PDFBug .controls {
background: rgb(238 238 238 / 1);
border-bottom: 1px solid rgb(102 102 102 / 1);
background: rgb(238 238 238);
border-bottom: 1px solid rgb(102 102 102);
padding: 3px;
}
#PDFBug .panels {
Expand All @@ -50,7 +50,7 @@
}
.debuggerShowText,
.debuggerHideText:hover {
background-color: rgb(255 255 0 / 1);
background-color: rgb(255 255 0);
}
#PDFBug .stats {
font-family: courier;
Expand Down Expand Up @@ -82,7 +82,7 @@
}

#viewer.textLayer-visible .canvasWrapper {
background-color: rgb(128 255 128 / 1);
background-color: rgb(128 255 128);
}

#viewer.textLayer-visible .canvasWrapper canvas {
Expand All @@ -91,7 +91,7 @@

#viewer.textLayer-visible .textLayer span {
background-color: rgb(255 255 0 / 0.1);
color: rgb(0 0 0 / 1);
color: rgb(0 0 0);
border: solid 1px rgb(255 0 0 / 0.5);
box-sizing: border-box;
}
Expand All @@ -101,11 +101,11 @@
}

#viewer.textLayer-hover .textLayer span:hover {
background-color: rgb(255 255 255 / 1);
color: rgb(0 0 0 / 1);
background-color: rgb(255 255 255);
color: rgb(0 0 0);
}

#viewer.textLayer-shadow .textLayer span {
background-color: rgb(255 255 255 / 0.6);
color: rgb(0 0 0 / 1);
color: rgb(0 0 0);
}
2 changes: 1 addition & 1 deletion web/pdf_viewer.css
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
overflow: visible;
border: var(--page-border);
background-clip: content-box;
background-color: rgb(255 255 255 / 1);
background-color: rgb(255 255 255);
}

.pdfViewer .dummyPage {
Expand Down
4 changes: 2 additions & 2 deletions web/text_layer_builder.css
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
*/

:root {
--highlight-bg-color: rgb(180 0 170 / 1);
--highlight-selected-bg-color: rgb(0 100 0 / 1);
--highlight-bg-color: rgb(180 0 170);
--highlight-selected-bg-color: rgb(0 100 0);
}

@media screen and (forced-colors: active) {
Expand Down
34 changes: 17 additions & 17 deletions web/viewer-geckoview.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@
--toolbar-icon-opacity: 1;
--doorhanger-icon-opacity: 0.9;

--main-color: rgb(12 12 13 / 1);
--body-bg-color: rgb(212 212 215 / 1);
--main-color: rgb(12 12 13);
--body-bg-color: rgb(212 212 215);
--scrollbar-color: auto;
--scrollbar-bg-color: auto;
--field-color: rgb(6 6 6 / 1);
--field-bg-color: rgb(255 255 255 / 1);
--field-border-color: rgb(187 187 188 / 1);
--doorhanger-bg-color: rgb(255 255 255 / 1);
--field-color: rgb(6 6 6);
--field-bg-color: rgb(255 255 255);
--field-border-color: rgb(187 187 188);
--doorhanger-bg-color: rgb(255 255 255);
--dialog-button-border: none;
--dialog-button-bg-color: rgb(12 12 13 / 0.1);
--dialog-button-hover-bg-color: rgb(12 12 13 / 0.3);
Expand All @@ -48,16 +48,16 @@

@media (prefers-color-scheme: dark) {
:root {
--main-color: rgb(249 249 250 / 1);
--body-bg-color: rgb(42 42 46 / 1);
--scrollbar-color: rgb(121 121 123 / 1);
--scrollbar-bg-color: rgb(35 35 39 / 1);
--field-color: rgb(250 250 250 / 1);
--field-bg-color: rgb(64 64 68 / 1);
--field-border-color: rgb(115 115 115 / 1);
--doorhanger-bg-color: rgb(74 74 79 / 1);
--dialog-button-bg-color: rgb(92 92 97 / 1);
--dialog-button-hover-bg-color: rgb(115 115 115 / 1);
--main-color: rgb(249 249 250);
--body-bg-color: rgb(42 42 46);
--scrollbar-color: rgb(121 121 123);
--scrollbar-bg-color: rgb(35 35 39);
--field-color: rgb(250 250 250);
--field-bg-color: rgb(64 64 68);
--field-border-color: rgb(115 115 115);
--doorhanger-bg-color: rgb(74 74 79);
--dialog-button-bg-color: rgb(92 92 97);
--dialog-button-hover-bg-color: rgb(115 115 115);

--toolbar-bg-color: #2b2a33;
--toolbar-divider-color: #5b5b66;
Expand Down Expand Up @@ -288,7 +288,7 @@ dialog .buttonRow {
}

dialog :link {
color: rgb(255 255 255 / 1);
color: rgb(255 255 255);
}

#passwordDialog {
Expand Down
Loading

0 comments on commit 89d8c63

Please sign in to comment.