Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: remove duplicate style properties #16226

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 0 additions & 1 deletion docs/src/assets/scss/components/resources.scss
Expand Up @@ -27,7 +27,6 @@
display: block;
height: 100%;
width: 100%;
// object-fit: cover;
object-fit: contain;
}
}
Expand Down
5 changes: 2 additions & 3 deletions docs/src/assets/scss/components/search.scss
Expand Up @@ -65,12 +65,11 @@
.search .search-results {
font-size: .875rem;
background-color: var(--body-background-color);
position: relative;
z-index: 10;
width: 100%;
border-radius: 0 0 var(--border-radius) var(--border-radius);
border: 1px solid var(--divider-color);
position: rekative;
position: relative;
top: .25rem;
max-height: 400px;
overflow-y: auto;
Expand Down Expand Up @@ -112,8 +111,8 @@
}

.search .search-results__item__title {
font-size: var(--step-0);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is intentionally duplicate. The first is used when the browser support variables and the second is used when the browser does not support variables.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added intentional properties and removed only duplicate properties & fixed typos.

font-size: .875rem;
font-size: var(--step-0);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we keep the original order here, with the variable version coming first?

margin-bottom: 0;
font-family: var(--text-font);

Expand Down
2 changes: 0 additions & 2 deletions docs/src/assets/scss/forms.scss
Expand Up @@ -26,7 +26,6 @@

.label__text.label__text {
display: flex;
font-size: .875rem;
align-items: center;
gap: .5rem;
font-size: .875rem;
Expand All @@ -45,7 +44,6 @@ input {
font: inherit;
font-size: 1rem;
display: block;
line-height: 1.3;
min-width: 0;
line-height: 1.3;
max-width: 100%;
Expand Down
1 change: 0 additions & 1 deletion docs/src/assets/scss/languages.scss
Expand Up @@ -13,7 +13,6 @@

a {
color: inherit;
display: block;
width: 100%;
padding: .75rem .1rem;
text-decoration: none;
Expand Down
1 change: 0 additions & 1 deletion docs/src/assets/scss/syntax-highlighter.scss
Expand Up @@ -36,7 +36,6 @@ pre[class*="language-"] {
padding: 1.5rem;
margin: 1.5rem 0;
overflow: auto;
background-color: var(--color-neutral-50);
border-radius: var(--border-radius);

background-color: var(--lightest-background-color);
Expand Down
14 changes: 6 additions & 8 deletions docs/src/assets/scss/tokens/spacing.scss
Expand Up @@ -6,15 +6,7 @@

--fluid-screen: 100vw;
--fluid-bp: calc((var(--fluid-screen) - var(--fluid-min-width) / 16 * 1rem) / (var(--fluid-max-width) - var(--fluid-min-width)));
}

@media screen and (min-width: 1024px) {
:root {
--fluid-screen: calc(var(--fluid-max-width) * 1px);
}
}

:root {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this removed accidentally?

--fc-3xs-min: (var(--fc-s-min) * 0.25);
--fc-3xs-max: (var(--fc-s-max) * 0.25);

Expand Down Expand Up @@ -75,3 +67,9 @@
--space-l-3xl: calc(((var(--fc-l-min) / 16) * 1rem) + (var(--fc-3xl-max) - var(--fc-l-min)) * var(--fluid-bp));
--space-s-l: calc(((var(--fc-s-min) / 16) * 1rem) + (var(--fc-l-max) - var(--fc-s-min)) * var(--fluid-bp));
}

@media screen and (min-width: 1024px) {
:root {
--fluid-screen: calc(var(--fluid-max-width) * 1px);
}
}
16 changes: 6 additions & 10 deletions docs/src/assets/scss/tokens/typography.scss
@@ -1,20 +1,18 @@
/* @link https://utopia.fyi/type/calculator?c=320,16,1.125,1280,16,1.25,6,2,&s=0.75|0.5|0.25,1.5|2|3|4|6,s-l */

:root {
--fluid-min-width: 320;
--fluid-max-width: 1280;

--fluid-screen: 100vw;
--fluid-bp: calc((var(--fluid-screen) - var(--fluid-min-width) / 16 * 1rem) / (var(--fluid-max-width) - var(--fluid-min-width)));
}

@media screen and (min-width: 1280px) {
:root {
--fluid-screen: calc(var(--fluid-max-width) * 1px);
}
}

:root {
--fluid-min-width: 320;
--fluid-max-width: 1280;

--fluid-screen: 100vw;
--fluid-bp: calc((var(--fluid-screen) - var(--fluid-min-width) / 16 * 1rem) / (var(--fluid-max-width) - var(--fluid-min-width)));

--f--2-min: 12.64;
--f--2-max: 10.24;
--step--2: calc(((var(--f--2-min) / 16) * 1rem) + (var(--f--2-max) - var(--f--2-min)) * var(--fluid-bp));
Expand Down Expand Up @@ -50,9 +48,7 @@
--f-6-min: 32.44;
--f-6-max: 61.04;
--step-6: calc(((var(--f-6-min) / 16) * 1rem) + (var(--f-6-max) - var(--f-6-min)) * var(--fluid-bp));
}

:root {
--mono-font: "Space Mono", monospace;
--text-font: "Inter",
-apple-system,
Expand Down
1 change: 0 additions & 1 deletion docs/src/assets/scss/versions.scss
Expand Up @@ -14,7 +14,6 @@

a {
color: var(--link-color);
display: block;
width: 100%;
padding: 1rem .5rem;
text-decoration: none;
Expand Down