Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 32 additions & 11 deletions css/reset.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,33 @@
Remove all the styles of the "User-Agent-Stylesheet", except for the 'display' property
- The "symbol *" part is to solve Firefox SVG sprite bug
*/
*:where(:not(html, iframe, canvas, img, svg, video, audio):not(svg *, symbol *)) {
*:where(:not(
html,
iframe, canvas,
img, svg, video, audio,
input, textarea, select, button,
table, caption, tbody, tfoot, thead, tr, th, td
):not(svg *, symbol *)) {
all: unset;
display: revert;
}

/* Preferred box-sizing value */
*,
*::before,
*::after {
box-sizing: border-box;
/* Reset form elements while keeping essential ui styles */
:where(input, textarea, select, button, option, optgroup ) {
all: revert;
margin: unset;
font: unset;
appearance: auto;
}

/* resets table styles nicely so html attribute features are still preserved */
:where(table, caption, tbody, tfoot, thead, tr, th, td) {
margin: unset;
padding: unset;
border:unset;
background: unset;
border-collapse: collapse;
border-spacing: 0;
}

/* Reapply the pointer cursor for anchor tags */
Expand All @@ -35,11 +52,6 @@ img {
max-block-size: 100%;
}

/* removes spacing between cells in tables */
table {
border-collapse: collapse;
}

/* Safari - solving issue when using user-select:none on the <body> text input doesn't working */
input, textarea {
-webkit-user-select: auto;
Expand Down Expand Up @@ -96,4 +108,13 @@ meter {
/* Revert Modal native behavior */
:where(dialog:modal) {
all: revert;
}



/* Preferred box-sizing value */
*,
*::before,
*::after {
box-sizing: border-box;
}