fix(desktop): stabilize legacy WebKit connection grid
This commit is contained in:
2 files changed
+12
-1
No files matched your search
@@ -1,8 +1,10 @@
|
|||||||
/* Keep these classic media queries outside the Vite/Tailwind transform pipeline.
|
/* Keep these classic media queries outside the Vite/Tailwind transform pipeline.
|
||||||
* Older WebKit ignores the range syntax emitted by the production CSS build. */
|
* Older WebKit ignores the range syntax emitted by the production CSS build and
|
||||||
|
* needs definite inline sizes for flex items that contain fractional grids. */
|
||||||
@media (min-width: 640px) {
|
@media (min-width: 640px) {
|
||||||
[data-slot="dialog-content"].connection-dialog-content--picker {
|
[data-slot="dialog-content"].connection-dialog-content--picker {
|
||||||
width: calc(100vw - 2rem) !important;
|
width: calc(100vw - 2rem) !important;
|
||||||
|
min-width: 38rem !important;
|
||||||
height: 720px !important;
|
height: 720px !important;
|
||||||
max-width: 880px !important;
|
max-width: 880px !important;
|
||||||
}
|
}
|
||||||
@@ -47,6 +49,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.connection-db-picker-results {
|
.connection-db-picker-results {
|
||||||
|
width: 0 !important;
|
||||||
min-width: 0 !important;
|
min-width: 0 !important;
|
||||||
flex: 1 1 0% !important;
|
flex: 1 1 0% !important;
|
||||||
}
|
}
|
||||||
@@ -56,8 +59,13 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.connection-db-picker-grid {
|
.connection-db-picker-grid {
|
||||||
|
width: 100% !important;
|
||||||
grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
|
grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.connection-db-picker-option {
|
||||||
|
min-width: 0 !important;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (min-width: 1024px) {
|
@media (min-width: 1024px) {
|
||||||
|
|||||||
@@ -53,6 +53,9 @@ describe("legacy WebView CSS fallbacks", () => {
|
|||||||
expect(desktopIndexSource).toContain('href="/connection-dialog-legacy.css"');
|
expect(desktopIndexSource).toContain('href="/connection-dialog-legacy.css"');
|
||||||
expect(connectionDialogLegacyCss).toContain("@media (min-width: 640px)");
|
expect(connectionDialogLegacyCss).toContain("@media (min-width: 640px)");
|
||||||
expect(connectionDialogLegacyCss).toContain("@media (min-width: 1024px)");
|
expect(connectionDialogLegacyCss).toContain("@media (min-width: 1024px)");
|
||||||
|
expect(connectionDialogLegacyCss).toContain("min-width: 38rem !important;");
|
||||||
|
expect(connectionDialogLegacyCss).toContain("width: 0 !important;");
|
||||||
|
expect(connectionDialogLegacyCss).toContain(".connection-db-picker-option");
|
||||||
expect(connectionDialogLegacyCss).not.toContain("width >=");
|
expect(connectionDialogLegacyCss).not.toContain("width >=");
|
||||||
expect(connectionDialogSource).not.toContain("@media (min-width: 640px)");
|
expect(connectionDialogSource).not.toContain("@media (min-width: 640px)");
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in new issue
Block a user