- {{#unless @crate.categories.isPending}}
- {{#if @crate.categories}}
-
+ {{#unless @crate.categories.isPending}}
+ {{#if @crate.categories}}
+
{{date-format-distance-to-now @invite.created_at addSuffix=true}}
diff --git a/app/components/pending-owner-invite-row.module.css b/app/components/pending-owner-invite-row.module.css
index b09caf08b1a..7ac468fe911 100644
--- a/app/components/pending-owner-invite-row.module.css
+++ b/app/components/pending-owner-invite-row.module.css
@@ -7,6 +7,10 @@
.crate-column {
width: 200px;
+
+ h3 {
+ margin: 0;
+ }
}
.date-column {
diff --git a/app/components/rendered-html.module.css b/app/components/rendered-html.module.css
index 2654db671d0..0e6aa06280b 100644
--- a/app/components/rendered-html.module.css
+++ b/app/components/rendered-html.module.css
@@ -18,20 +18,20 @@
code {
display: block;
overflow-x: auto;
- padding: 1em;
+ padding: var(--space-s);
background-color: #f6f8fa;
font-size: 85%;
- border-radius: 6px;
+ border-radius: var(--space-3xs);
}
}
p, li {
code {
background-color: #f6f8fa;
- border-radius: 6px;
+ border-radius: var(--space-3xs);
font-size: 85%;
margin: 0;
- padding: .2em .4em;
+ padding: var(--space-4xs) var(--space-3xs);
}
}
@@ -46,7 +46,7 @@
th, td {
border: 1px solid #dfe2e5;
- padding: 6px 13px;
+ padding: var(--space-2xs) var(--space-s);
}
}
}
diff --git a/app/components/rev-dep-row.module.css b/app/components/rev-dep-row.module.css
index ac3f746e49c..046a114adaf 100644
--- a/app/components/rev-dep-row.module.css
+++ b/app/components/rev-dep-row.module.css
@@ -6,9 +6,9 @@
position: relative;
font-size: 18px;
- padding: 15px 25px;
+ padding: var(--space-s) var(--space-m);
background-color: white;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
box-shadow: var(--shadow);
transition: all var(--transition-slow);
@@ -41,7 +41,7 @@
.link {
color: var(--crate-color);
font-weight: 500;
- margin-right: 15px;
+ margin-right: var(--space-s);
outline: none;
&:hover {
@@ -74,7 +74,7 @@
font-variant: tabular-nums;
@media only screen and (max-width: 550px) {
- margin-top: 10px;
+ margin-top: var(--space-xs);
}
}
@@ -86,14 +86,19 @@
}
.description {
- margin-top: 10px;
+ margin-top: var(--space-2xs);
color: var(--crate-color);
font-size: 90%;
+ line-height: 1.5;
+
+ @media only screen and (max-width: 550px) {
+ margin-top: var(--space-xs);
+ }
}
.description-placeholder {
height: 1em;
width: 70%;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
opacity: var(--placeholder-opacity);
}
diff --git a/app/components/search-form.module.css b/app/components/search-form.module.css
index d663caa6c91..078e7bae6bc 100644
--- a/app/components/search-form.module.css
+++ b/app/components/search-form.module.css
@@ -1,29 +1,29 @@
.form {
- --border-radius: 15px;
- --submit-icon-size: 16px;
- --submit-button-padding-left: 8px;
- --submit-button-padding-right: 10px;
+ --border-radius: 5000px;
+ --submit-icon-size: 1em;
+ --submit-button-padding-left: var(--space-2xs);
+ --submit-button-padding-right: var(--space-xs);
--submit-button-width: calc(var(--submit-button-padding-left) + var(--submit-icon-size) + var(--submit-button-padding-right));
- --input-padding: 5px;
- --input-padding-left: 10px;
+ --input-padding: var(--space-3xs);
+ --input-padding-left: var(--space-xs);
--input-padding-right: calc(var(--submit-button-width) + var(--input-padding));
position: relative;
+ font-size: calc(var(--space-s) * 0.9);
&.size-big {
- --border-radius: 30px;
--input-padding: 8px;
--input-padding-left: 16px;
- --submit-icon-size: 20px;
--submit-button-padding-left: 12px;
--submit-button-padding-right: 16px;
+
+ font-size: var(--space-s);
}
}
.input {
- --search-form-focus-shadow: 0 0 0 4px var(--yellow500);
+ --search-form-focus-shadow: 0 0 0 var(--space-3xs) var(--yellow500);
- font-size: 90%;
border: none;
color: black;
width: 100%;
@@ -32,10 +32,6 @@
box-shadow: 1px 2px 4px 0 var(--green900);
transition: box-shadow var(--transition-fast);
- .size-big & {
- font-size: 125%;
- }
-
&:focus {
outline: none;
box-shadow: var(--search-form-focus-shadow),
diff --git a/app/components/settings-page.module.css b/app/components/settings-page.module.css
index cf32d985989..215e1d1cd7b 100644
--- a/app/components/settings-page.module.css
+++ b/app/components/settings-page.module.css
@@ -1,6 +1,6 @@
.page {
display: grid;
- gap: 16px;
+ gap: var(--space-s);
@media (--min-m) {
grid-template:
@@ -11,6 +11,6 @@
.content {
h2:first-child {
- margin-top: 4px;
+ margin-top: var(--space-3xs);
}
}
diff --git a/app/components/settings/api-tokens.module.css b/app/components/settings/api-tokens.module.css
index ec238d1d255..a6e583f29f9 100644
--- a/app/components/settings/api-tokens.module.css
+++ b/app/components/settings/api-tokens.module.css
@@ -18,15 +18,15 @@
}
.token-list {
- margin: 24px 0;
+ margin: var(--space-m) 0;
padding: 0;
list-style: none;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
background-color: white;
box-shadow: 0 2px 3px hsla(51, 50%, 44%, .35);
> * {
- padding: 24px;
+ padding: var(--space-m);
}
> * + * {
@@ -49,44 +49,44 @@
}
.new-token-form {
- padding: 24px;
- border-radius: 6px;
+ padding: var(--space-m);
+ border-radius: var(--space-3xs);
background-color: white;
box-shadow: 0 2px 3px hsla(51, 50%, 44%, .35);
- margin: 24px 0;
+ margin-top: var(--space-m);
.input {
- padding: 8px;
+ padding: var(--space-2xs);
width: 100%;
border: 1px solid #ada796;
- border-radius: 4px;
+ border-radius: var(--space-3xs);
}
}
.actions {
- margin-top: 12px;
+ margin-top: var(--space-s);
display: flex;
align-items: center;
}
.spinner {
- margin-left: 10px
+ margin-left: var(--space-xs);
}
.save-button {
composes: yellow-button small from '../../styles/shared/buttons.module.css';
flex-grow: 1;
- border-radius: 4px;
+ border-radius: var(--space-3xs);
}
.revoke-button {
composes: tan-button small from '../../styles/shared/buttons.module.css';
flex-grow: 1;
- border-radius: 4px;
+ border-radius: var(--space-3xs);
}
.new-token {
- margin: 24px 0;
+ margin-top: var(--space-s);
}
.new-token-explainer {
@@ -100,19 +100,19 @@
background: var(--main-color);
color: white;
font-family: var(--font-monospace);
- border-radius: 4px;
- margin-top: 16px;
+ border-radius: var(--space-3xs);
+ margin-top: var(--space-xs);
}
.token-value {
- padding: 20px;
+ padding: var(--space-s);
user-select: all;
}
.copy-button {
composes: button-reset from '../../styles/shared/buttons.module.css';
align-self: stretch;
- padding: 0 16px;
+ padding: 0 var(--space-s);
cursor: pointer;
&:hover {
@@ -125,18 +125,18 @@
}
.copy-button-icon {
- width: 24px;
- height: 24px;
+ width: auto;
+ height: 1.3em;
}
.empty-state {
display: grid;
place-items: center;
align-content: center;
- margin: 24px 0;
- padding: 64px;
+ margin: var(--space-m) 0;
+ padding: var(--space-xl-2xl);
border: 2px black dashed;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
background-color: white;
box-shadow: 0 2px 3px hsla(51, 50%, 44%, .35);
}
@@ -147,7 +147,7 @@
.empty-state-button {
composes: yellow-button small from '../../styles/shared/buttons.module.css';
- margin-top: 20px;
+ margin-top: var(--space-m);
border-radius: 4px;
}
@@ -155,16 +155,11 @@
.new-token-form {
display: grid;
grid-template-columns: 1fr auto;
- align-items: center;
- padding: 16px 24px;
-
- .input {
- padding: 8px;
- margin-right: 16px;
- }
+ align-items: stretch;
+ padding: var(--space-s) var(--space-m);
.actions {
- margin: 0 0 0 16px;
+ margin: 0 0 0 var(--space-xs);
}
}
@@ -181,7 +176,7 @@
.actions {
grid-area: actions;
align-self: start;
- margin: 0 0 0 16px;
+ margin: 0 0 0 var(--space-xs);
}
.new-token {
diff --git a/app/components/side-menu.module.css b/app/components/side-menu.module.css
index 2a8fcb207ac..880066e3424 100644
--- a/app/components/side-menu.module.css
+++ b/app/components/side-menu.module.css
@@ -4,6 +4,6 @@
padding: 0;
> * + * {
- margin-top: 8px;
+ margin-top: var(--space-3xs);
}
}
diff --git a/app/components/side-menu/item.module.css b/app/components/side-menu/item.module.css
index 42cb7a45636..8229b3db974 100644
--- a/app/components/side-menu/item.module.css
+++ b/app/components/side-menu/item.module.css
@@ -1,7 +1,7 @@
.link {
display: block;
- padding: 10px 12px;
- border-radius: 6px;
+ padding: var(--space-2xs) var(--space-xs);
+ border-radius: var(--space-3xs);
color: var(--main-color-light);
transition: all var(--transition-medium) ease-in;
diff --git a/app/components/sort-dropdown.module.css b/app/components/sort-dropdown.module.css
index 7fbf0746605..c381235aa76 100644
--- a/app/components/sort-dropdown.module.css
+++ b/app/components/sort-dropdown.module.css
@@ -1,12 +1,12 @@
.trigger {
background-color: var(--main-bg-dark);
font-size: 85%;
- padding: 10px;
+ padding: var(--space-2xs);
border: none;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
}
.icon {
color: #1a9c5d;
- margin-right: 0.5em;
+ margin-right: var(--space-2xs);
}
diff --git a/app/components/stats-value.module.css b/app/components/stats-value.module.css
index d73bd6563e8..14a0a585f0c 100644
--- a/app/components/stats-value.module.css
+++ b/app/components/stats-value.module.css
@@ -6,26 +6,26 @@
}
.value {
- font-size: 30px;
+ font-size: var(--space-m-l);
font-weight: bold;
- line-height: 30px;
+ line-height: 1em;
}
.label {
grid-column: 1;
grid-row: 2;
color: #76838a;
- font-size: 16px;
+ font-size: var(--space-s);
font-weight: normal;
- line-height: 27px;
+ line-height: 1.6;
}
.icon {
grid-column: 2;
grid-row: 1 / 3;
- width: 40px;
- height: 40px;
- margin-left: 16px;
- margin-top: 4px;
+ width: var(--space-l-xl);
+ height: var(--space-l-xl);
+ margin-left: var(--space-s);
+ margin-top: var(--space-3xs);
color: #76838a;
}
diff --git a/app/components/version-list/row.module.css b/app/components/version-list/row.module.css
index fc62a5ae863..8940d9477d4 100644
--- a/app/components/version-list/row.module.css
+++ b/app/components/version-list/row.module.css
@@ -8,9 +8,9 @@
align-items: center;
position: relative;
font-size: 18px;
- padding: 15px 25px;
+ padding: var(--space-s) var(--space-m);
background-color: white;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
box-shadow: var(--shadow);
transition: all var(--transition-slow);
@@ -59,6 +59,7 @@
@media only screen and (max-width: 550px) {
grid-template-columns: auto;
+ margin: 0 var(--space-s);
}
}
@@ -66,10 +67,10 @@
flex-shrink: 0;
display: grid;
place-items: center;
- width: 3em;
- height: 3em;
+ width: var(--space-xl);
+ height: var(--space-xl);
overflow: hidden;
- margin-right: 20px;
+ margin-right: var(--space-s);
font-weight: 500;
font-variant-numeric: tabular-nums;
color: var(--fg-color);
@@ -84,12 +85,12 @@
}
.row:hover &, .row.focused & {
- border: 2px solid white;
+ border: var(--space-4xs) solid white;
box-shadow: 0 1px 3px var(--fg-color);
}
@media only screen and (max-width: 550px) {
- margin: 0 10px 10px;
+ margin: 0 0 var(--space-s);
}
}
@@ -115,7 +116,7 @@
.metadata {
flex-grow: 1;
- margin-left: 30px;
+ margin-left: var(--space-m);
color: var(--grey600);
text-transform: uppercase;
letter-spacing: .7px;
@@ -138,7 +139,7 @@
svg {
height: 1em;
width: auto;
- margin-right: 2px;
+ margin-right: var(--space-4xs);
margin-bottom: -.1em;
}
@@ -146,12 +147,20 @@
text-transform: none;
letter-spacing: normal;
}
+
+ > * + * {
+ margin-top: var(--space-2xs);
+
+ @media only screen and (max-width: 750px) {
+ margin-top: var(--space-xs);
+ }
+ }
}
.avatar {
height: 1.5em;
width: auto;
- margin-left: 3px;
+ margin-left: var(--space-4xs);
margin-bottom: -.4em;
border-radius: 50%;
box-shadow: 0 1px 1px 0 var(--grey600);
@@ -159,12 +168,8 @@
}
.metadata-row {
- &:not(:first-child) {
- margin-top: 10px;
- }
-
- > *:not(:first-child) {
- margin-left: 20px;
+ > * + * {
+ margin-left: var(--space-s);
}
@media only screen and (max-width: 750px) {
@@ -172,11 +177,9 @@
flex-direction: column;
align-items: flex-start;
- > * {
- &:not(:first-child) {
- margin-left: 0;
- margin-top: 10px;
- }
+ > * + * {
+ margin-left: 0;
+ margin-top: var(--space-xs);
}
}
}
@@ -193,13 +196,13 @@
.feature-list {
padding: 0;
- margin: 10px 5px;
+ margin: var(--space-xs) var(--space-2xs);
list-style: none;
}
.yank-button {
position: relative;
- margin-left: 10px;
+ margin-left: var(--space-xs);
@media only screen and (max-width: 550px) {
display: none;
diff --git a/app/styles/application.module.css b/app/styles/application.module.css
index e7bbf4c8f67..a32ae646fd9 100644
--- a/app/styles/application.module.css
+++ b/app/styles/application.module.css
@@ -46,6 +46,33 @@
--placeholder-bg: hsl(212, 7%, 57%);
--placeholder-bg2: hsl(213, 16%, 75%);
+
+ /* see https://utopia.fyi/space/calculator?c=320,14,1.2,1140,18,1.25,5,2,&s=0.75|0.5|0.25|0.125,1.5|2|3|4|6,s-l */
+
+ --space-4xs: clamp(0.13rem, calc(0.13rem + 0.00vw), 0.13rem);
+ --space-3xs: clamp(0.25rem, calc(0.23rem + 0.12vw), 0.31rem);
+ --space-2xs: clamp(0.44rem, calc(0.39rem + 0.24vw), 0.56rem);
+ --space-xs: clamp(0.69rem, calc(0.61rem + 0.37vw), 0.88rem);
+ --space-s: clamp(0.88rem, calc(0.78rem + 0.49vw), 1.13rem);
+ --space-m: clamp(1.31rem, calc(1.17rem + 0.73vw), 1.69rem);
+ --space-l: clamp(1.75rem, calc(1.55rem + 0.98vw), 2.25rem);
+ --space-xl: clamp(2.63rem, calc(2.33rem + 1.46vw), 3.38rem);
+ --space-2xl: clamp(3.50rem, calc(3.11rem + 1.95vw), 4.50rem);
+ --space-3xl: clamp(5.25rem, calc(4.66rem + 2.93vw), 6.75rem);
+
+ /* One-up pairs */
+ --space-4xs-3xs: clamp(0.13rem, calc(0.05rem + 0.37vw), 0.31rem);
+ --space-3xs-2xs: clamp(0.25rem, calc(0.13rem + 0.61vw), 0.56rem);
+ --space-2xs-xs: clamp(0.44rem, calc(0.27rem + 0.85vw), 0.88rem);
+ --space-xs-s: clamp(0.69rem, calc(0.52rem + 0.85vw), 1.13rem);
+ --space-s-m: clamp(0.88rem, calc(0.56rem + 1.59vw), 1.69rem);
+ --space-m-l: clamp(1.31rem, calc(0.95rem + 1.83vw), 2.25rem);
+ --space-l-xl: clamp(1.75rem, calc(1.12rem + 3.17vw), 3.38rem);
+ --space-xl-2xl: clamp(2.63rem, calc(1.89rem + 3.66vw), 4.50rem);
+ --space-2xl-3xl: clamp(3.50rem, calc(2.23rem + 6.34vw), 6.75rem);
+
+ /* Custom pairs */
+ --space-s-l: clamp(0.88rem, calc(0.34rem + 2.68vw), 2.25rem);
}
[data-theme="new-design"] {
@@ -99,7 +126,7 @@ a:not([href]) {
pre:global(.terminal) {
background: var(--main-color);
color: white;
- padding: 20px;
+ padding: var(--space-s);
font-family: var(--font-monospace);
}
@@ -109,8 +136,10 @@ abbr[title] {
}
noscript {
+ display: grid;
+ justify-items: center;
+ padding: var(--space-m);
color: white;
- padding: 10px 0;
}
:global {
@@ -144,9 +173,10 @@ noscript {
}
.inner-main {
+ --main-layout-padding: var(--space-s);
+
composes: width-limit;
display: flex;
flex-direction: column;
- margin: 15px 0;
- padding: 0 15px;
+ padding: var(--main-layout-padding);
}
diff --git a/app/styles/catch-all.module.css b/app/styles/catch-all.module.css
index 4f4919c42fe..5fb92043369 100644
--- a/app/styles/catch-all.module.css
+++ b/app/styles/catch-all.module.css
@@ -7,7 +7,7 @@
.content {
display: grid;
place-items: center;
- margin: 25px 0;
+ margin: var(--space-m) 0;
}
.logo {
diff --git a/app/styles/categories.module.css b/app/styles/categories.module.css
index f18fc7e874e..205c68d420b 100644
--- a/app/styles/categories.module.css
+++ b/app/styles/categories.module.css
@@ -4,7 +4,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -13,16 +13,17 @@
.list {
background-color: white;
- padding: 0 20px;
- margin-bottom: 20px;
-}
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+ margin-bottom: var(--space-s);
-.row {
- width: 100%;
- border-bottom: 2px solid var(--gray-border);
- padding: 20px 0;
+ > * {
+ padding: var(--space-s);
+ }
- &:last-of-type { border: none; }
+ > * + * {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
+ }
}
.crate-count {
@@ -31,13 +32,13 @@
.description {
composes: small from './shared/typography.module.css';
- margin-top: 4px;
- line-height: 1.2rem;
+ margin-top: var(--space-2xs);
+ line-height: 1.5;
}
.categories-footer {
width: 100%;
- padding: 1em;
+ margin: var(--space-2xs) 0;
text-align: center;
font-size: 85%;
}
diff --git a/app/styles/category-slugs.module.css b/app/styles/category-slugs.module.css
index c20ebb72cbf..546572210aa 100644
--- a/app/styles/category-slugs.module.css
+++ b/app/styles/category-slugs.module.css
@@ -1,14 +1,21 @@
.list {
background-color: white;
- padding: 20px 20px 0;
- margin: 0;
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+ margin-bottom: var(--space-s);
dt {
- margin-bottom: 5px;
+ padding: var(--space-s);
+ padding-bottom: var(--space-2xs);
+ font-family: var(--font-monospace);
font-weight: bold;
}
dd {
- margin-bottom: 20px;
+ margin: 0 var(--space-s) var(--space-s);
+ }
+
+ > * + dt {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
}
}
diff --git a/app/styles/category/index.module.css b/app/styles/category/index.module.css
index 36485d74649..38005284293 100644
--- a/app/styles/category/index.module.css
+++ b/app/styles/category/index.module.css
@@ -9,16 +9,16 @@
.subcategories {
background-color: white;
- padding: 0 20px;
- margin-bottom: 20px;
-}
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+ margin-bottom: var(--space-s);
-.subcategory {
- border-bottom: 2px solid var(--gray-border);
- padding: 20px 0;
+ > * {
+ padding: var(--space-s);
+ }
- &:last-of-type {
- border: none;
+ > * + * {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
}
}
@@ -28,14 +28,14 @@
}
.category-description {
- margin-top: 6px;
+ margin-top: var(--space-2xs);
}
.results-meta {
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -43,5 +43,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/crate/reverse-dependencies.module.css b/app/styles/crate/reverse-dependencies.module.css
index f458071171d..df3842a6c4c 100644
--- a/app/styles/crate/reverse-dependencies.module.css
+++ b/app/styles/crate/reverse-dependencies.module.css
@@ -1,20 +1,18 @@
.results-meta {
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.list {
list-style: none;
- margin: 0 0 20px;
+ margin: 0 0 var(--space-s);
padding: 0;
- li {
- &:not(:first-child) {
- margin-top: 10px;
- }
+ > * + * {
+ margin-top: var(--space-2xs);
}
}
.no-results {
text-align: center;
- margin: 20px;
+ margin: var(--space-m) 0;
}
diff --git a/app/styles/crate/settings.module.css b/app/styles/crate/settings.module.css
index d97762664f4..870400b5ce5 100644
--- a/app/styles/crate/settings.module.css
+++ b/app/styles/crate/settings.module.css
@@ -1,26 +1,21 @@
-.me-email {
- border-bottom: 5px solid var(--gray-border);
- padding-bottom: 20px;
- margin-bottom: 20px;
-}
-
.email-form {
display: flex;
justify-content: space-between;
align-items: center;
flex-wrap: wrap;
- border: 2px solid var(--gray-border);
- padding: 10px 20px;
+ gap: var(--space-s);
+ padding: var(--space-s) var(--space-m);
+ background-color: white;
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
}
.email-input-label {
font-weight: bold;
- margin-right: 10px;
}
.email-input {
width: 400px;
- margin-right: 10px;
}
.submit-button {
@@ -29,18 +24,20 @@
.list {
background-color: white;
- padding: 0 20px;
-}
-
-.row {
- border-bottom: 2px solid var(--gray-border);
- padding: 20px 0;
- display: flex;
- justify-content: space-between;
- align-items: center;
- flex-wrap: wrap;
-
- &:last-of-type { border: none; }
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+
+ > * {
+ padding: var(--space-s) var(--space-m);
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ flex-wrap: wrap;
+ }
+
+ > * + * {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
+ }
}
.email-column {
diff --git a/app/styles/crate/version-dependencies.module.css b/app/styles/crate/version-dependencies.module.css
index 2667802ce94..7e5d72fb0ae 100644
--- a/app/styles/crate/version-dependencies.module.css
+++ b/app/styles/crate/version-dependencies.module.css
@@ -3,10 +3,8 @@
margin: 0;
padding: 0;
- li {
- &:not(:first-child) {
- margin-top: 10px;
- }
+ > * + * {
+ margin-top: var(--space-2xs);
}
}
diff --git a/app/styles/crate/version.module.css b/app/styles/crate/version.module.css
index 8c3d73fd2f2..ba979a5f5e4 100644
--- a/app/styles/crate/version.module.css
+++ b/app/styles/crate/version.module.css
@@ -8,15 +8,15 @@
.docs {
--shadow: 0 2px 3px hsla(51, 50%, 44%, .35);
- margin-bottom: 25px;
- padding: 25px;
+ margin-bottom: var(--space-l);
+ padding: var(--space-m) var(--space-l);
background-color: white;
- border-radius: 5px;
+ border-radius: var(--space-3xs);
box-shadow: var(--shadow);
@media only screen and (max-width: 550px) {
- margin-left: -15px;
- margin-right: -15px;
+ margin-left: calc(var(--main-layout-padding) * -1);
+ margin-right: calc(var(--main-layout-padding) * -1);
border-radius: 0;
}
@@ -26,11 +26,12 @@
}
.no-readme {
- padding: 40px 15px;
+ padding: var(--space-l) var(--space-s);
text-align: center;
font-size: 20px;
font-weight: 300;
overflow-wrap: break-word;
+ line-height: 1.5;
code {
font-size: 18px;
@@ -41,38 +42,38 @@
.placeholder-title {
width: 30%;
height: 25px;
- margin: 15px 0 25px;
- border-radius: 5px;
+ margin: var(--space-s) 0 var(--space-m);
+ border-radius: var(--space-3xs);
opacity: 0.6;
}
.placeholder-subtitle {
width: 50%;
height: 20px;
- margin: 35px 0 25px;
- border-radius: 5px;
+ margin: var(--space-l) 0 var(--space-m);
+ border-radius: var(--space-3xs);
opacity: 0.6;
}
.placeholder-text {
width: 100%;
height: 16px;
- margin-top: 15px;
- border-radius: 5px;
+ margin-top: var(--space-xs);
+ border-radius: var(--space-3xs);
opacity: 0.3;
}
.sidebar {
@media only screen and (min-width: 890px) {
- margin-top: 20px;
- margin-left: 20px;
+ margin-top: var(--space-m);
+ margin-left: var(--space-m);
}
}
.crate-downloads {
display: flex;
flex-wrap: wrap;
- margin-top: 25px;
+ margin-top: var(--space-l);
border-top: 5px solid var(--gray-border);
h3 { width: 100%; }
@@ -86,7 +87,7 @@
.stat {
border-left: 1px solid var(--gray-border);
- padding: 10px 20px;
+ padding: var(--space-s) var(--space-m);
display: flex;
flex-wrap: wrap;
flex-direction: column;
@@ -95,7 +96,7 @@
.num {
font-size: 160%;
font-weight: bold;
- margin-bottom: 4px;
+ margin-bottom: var(--space-3xs);
}
.num__align {
@@ -111,8 +112,7 @@
.graph {
flex-grow: 10;
width: 100%;
- margin: 30px 0;
- padding-bottom: 20px;
+ margin: var(--space-xs) 0 var(--space-m);
h4 {
color: var(--main-color-light);
@@ -139,12 +139,12 @@
padding: 10px;
border: none;
border-radius: 5px;
-
+
.trigger-label {
min-width: 65px;
}
}
-
+
.dropdown-button {
background: none;
border: 0;
diff --git a/app/styles/crate/versions.module.css b/app/styles/crate/versions.module.css
index 19da67b5142..6ea10305341 100644
--- a/app/styles/crate/versions.module.css
+++ b/app/styles/crate/versions.module.css
@@ -2,7 +2,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 10px;
+ margin-bottom: var(--space-2xs);
@media only screen and (max-width: 550px) {
display: block;
@@ -14,18 +14,15 @@
@media only screen and (max-width: 550px) {
display: block;
- margin-bottom: 15px;
+ margin-bottom: var(--space-s);
}
}
-
.list {
list-style: none;
- margin: 10px 0 0;
+ margin: var(--space-2xs) 0 var(--space-s);
padding: 0;
- li {
- &:not(:first-child) {
- margin-top: 10px;
- }
+ > * + * {
+ margin-top: var(--space-2xs);
}
}
diff --git a/app/styles/crates.module.css b/app/styles/crates.module.css
index fcc92e45647..3c1dce5b772 100644
--- a/app/styles/crates.module.css
+++ b/app/styles/crates.module.css
@@ -2,7 +2,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -10,5 +10,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/dashboard.module.css b/app/styles/dashboard.module.css
index c7fbe7436ff..e3ac7371d87 100644
--- a/app/styles/dashboard.module.css
+++ b/app/styles/dashboard.module.css
@@ -5,14 +5,13 @@
.header-icon {
flex-shrink: 0;
- margin-right: 10px;
+ margin-right: var(--space-2xs);
width: 32px;
height: 32px;
}
.stats {
margin-left: auto;
- padding: 10px;
.num {
font-size: 30px;
@@ -26,11 +25,24 @@
.stats-label {
composes: small from './shared/typography.module.css';
- margin-left: 5px;
+ margin-left: var(--space-2xs);
}
.my-info {
display: flex;
+ gap: var(--space-s);
+
+ h2 {
+ display: flex;
+ align-items: center;
+ gap: var(--space-3xs);
+ font-size: 1.05em;
+ margin: 0;
+
+ > * {
+ flex-shrink: 0;
+ }
+ }
@media only screen and (max-width: 750px) {
flex-direction: column;
@@ -40,27 +52,19 @@
.my-crate-lists {
flex-direction: column;
flex-grow: 2;
- margin-right: 20px;
.header {
display: flex;
justify-content: space-between;
align-items: center;
+ }
- h2 {
- font-size: 105%;
- line-height: 20px;
- }
-
- svg {
- display: inline-block;
- vertical-align: text-top;
- }
+ > ul {
+ margin: var(--space-s) 0;
}
@media only screen and (max-width: 750px) {
order: 1;
- margin-right: 0;
}
}
@@ -78,12 +82,6 @@
.my-feed {
flex-grow: 5;
- h2 { font-size: 105%; }
-
- svg {
- display: inline-block;
- vertical-align: text-top;
- }
@media only screen and (max-width: 750px) {
order: 0;
@@ -91,23 +89,25 @@
}
.feed {
- background: white;
- padding: 0 20px 20px;
+ background-color: white;
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+ margin: var(--space-s) 0;
}
.feed-list {
+ list-style: none;
margin: 0;
padding: 0;
-}
-.feed-row {
- display: flex;
- align-items: baseline;
- padding: 20px 0;
- border-bottom: 2px solid var(--gray-border);
+ > * {
+ display: flex;
+ align-items: baseline;
+ padding: var(--space-s);
+ }
- &:last-of-type {
- border: none;
+ > * + * {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
}
}
@@ -122,16 +122,21 @@
}
.load-more {
- display: block;
- text-align: center;
- width: 100%;
- padding: 10px;
- outline: 0;
- border: 0;
- background-color: #dbd9cf;
- color: white;
-
- &:hover, &:focus {
- background-color: #c5c2b2;
+ padding: var(--space-s);
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
+
+ button {
+ display: block;
+ text-align: center;
+ width: 100%;
+ padding: var(--space-2xs);
+ outline: 0;
+ border: 0;
+ background-color: #dbd9cf;
+ color: white;
+
+ &:hover, &:focus {
+ background-color: #c5c2b2;
+ }
}
}
diff --git a/app/styles/index.module.css b/app/styles/index.module.css
index 0dc305ee92a..bf51cdccc1a 100644
--- a/app/styles/index.module.css
+++ b/app/styles/index.module.css
@@ -1,27 +1,11 @@
-.title-header {
- text-align: center;
+.hero-buttons {
+ display: flex;
+ flex-wrap: wrap;
+ justify-content: center;
+ gap: var(--space-s);
border-bottom: 5px solid var(--gray-border);
- margin-top: 25px;
- padding-bottom: 40px;
-
- @media only screen and (max-width: 570px) {
- margin-top: 0;
- }
-
- h1 {
- font-size: 50px;
- @media only screen and (max-width: 370px) {
- font-size: 40px;
- }
- }
-
- .links a:not(:first-child) {
- margin: 0 20px;
- @media only screen and (max-width: 570px) {
- clear: both;
- margin: 20px 0 0 0;
- }
- }
+ margin-top: var(--space-s);
+ padding-bottom: var(--space-l);
}
.hero-button {
@@ -33,68 +17,69 @@
}
.blurb {
- margin: 30px 0 40px 0;
+ margin: var(--space-l) var(--space-s);
display: flex;
+ gap: var(--space-l);
- .intro { flex: 6; line-height: 25px; padding: 10px;}
-
- .stats {
- flex: 4;
- display: flex;
+ @media only screen and (max-width: 650px) {
flex-direction: column;
+ align-items: center;
+ }
+}
- padding: 10px;
+.intro {
+ flex: 6;
+ line-height: 1.5;
+}
- .crates { margin-top: 16px; }
- }
+.stats {
+ flex: 4;
+ display: flex;
+ flex-direction: column;
- @media only screen and (max-width: 530px) {
- flex-direction: column;
- .stats {
- border: none;
- margin: 32px auto 0;
- }
+ > * + * {
+ margin-top: var(--space-s);
}
}
.lists {
- display: flex;
- flex-wrap: wrap;
- justify-content: left;
-
- > section {
- margin: 0;
- padding: 0 15px;
- width: 33.33%;
- @media only screen and (max-width: 750px) {
- width: 50%;
- }
- @media only screen and (max-width: 550px) {
- width: 100%;
- }
+ display: grid;
+ grid-template-columns: 1fr 1fr 1fr;
+ gap: var(--space-s);
+ padding: 0 var(--space-s);
+
+ @media only screen and (max-width: 750px) {
+ grid-template-columns: 1fr 1fr;
+ }
+
+ @media only screen and (max-width: 550px) {
+ grid-template-columns: 1fr;
}
h2 {
- font-size: 105%;
- line-height: 20px;
+ font-size: 1.05rem;
}
}
.list {
list-style: none;
padding: 0;
+
+ > * + * {
+ margin-top: var(--space-2xs);
+ }
}
.error-message {
- line-height: 25px;
+ line-height: 1.5;
}
.try-again-button {
composes: yellow-button from './shared/buttons.module.css';
align-self: center;
- margin: 20px 0;
+ margin: var(--space-s) 0;
.spinner {
- margin-left: 7px;
+ margin-left: var(--space-2xs);
}
}
diff --git a/app/styles/keyword/index.module.css b/app/styles/keyword/index.module.css
index ac17d47d41b..6113a849814 100644
--- a/app/styles/keyword/index.module.css
+++ b/app/styles/keyword/index.module.css
@@ -2,7 +2,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -10,5 +10,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/keywords.module.css b/app/styles/keywords.module.css
index 8706dfc4369..11f08c02cbc 100644
--- a/app/styles/keywords.module.css
+++ b/app/styles/keywords.module.css
@@ -2,7 +2,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -11,16 +11,16 @@
.list {
background-color: white;
- padding: 0 20px;
- margin-bottom: 20px;
-}
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+ margin-bottom: var(--space-s);
-.row {
- border-bottom: 2px solid var(--gray-border);
- padding: 20px 0;
+ > * {
+ padding: var(--space-s);
+ }
- &:last-of-type {
- border: none;
+ > * + * {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
}
}
diff --git a/app/styles/me/crates.module.css b/app/styles/me/crates.module.css
index ac17d47d41b..6113a849814 100644
--- a/app/styles/me/crates.module.css
+++ b/app/styles/me/crates.module.css
@@ -2,7 +2,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -10,5 +10,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/me/following.module.css b/app/styles/me/following.module.css
index ac17d47d41b..6113a849814 100644
--- a/app/styles/me/following.module.css
+++ b/app/styles/me/following.module.css
@@ -2,7 +2,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -10,5 +10,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/me/pending-invites.module.css b/app/styles/me/pending-invites.module.css
index 19813a7a861..9e78660a3fe 100644
--- a/app/styles/me/pending-invites.module.css
+++ b/app/styles/me/pending-invites.module.css
@@ -1,13 +1,14 @@
.list {
- background: white;
-}
+ background-color: white;
+ border-radius: var(--space-3xs);
+ box-shadow: 0 1px 3px hsla(51, 90%, 42%, .35);
+ margin-bottom: var(--space-s);
-.row {
- margin: 0;
- padding: 20px;
- border-bottom: 2px solid #d5d3cb;
+ > * {
+ padding: var(--space-s);
+ }
- &:last-of-type {
- border: none;
+ > * + * {
+ border-top: 1px solid hsla(51, 90%, 42%, .25);
}
}
diff --git a/app/styles/search.module.css b/app/styles/search.module.css
index 2c3df955803..b8dfc930484 100644
--- a/app/styles/search.module.css
+++ b/app/styles/search.module.css
@@ -2,16 +2,16 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.warning {
- margin: 0 0 16px;
- padding: 8px;
+ margin: 0 0 var(--space-s);
+ padding: var(--space-2xs);
color: var(--orange-700);
background: var(--orange-100);
- border-left: solid var(--orange-400) 4px;
- border-radius: 2px;
+ border-left: solid var(--orange-400) var(--space-3xs);
+ border-radius: var(--space-4xs);
}
.sort-by-label {
@@ -19,11 +19,11 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
.try-again-button {
composes: yellow-button from './shared/buttons.module.css';
align-self: center;
- margin-top: 20px;
+ margin-top: var(--space-m);
}
diff --git a/app/styles/settings/appearance.module.css b/app/styles/settings/appearance.module.css
index 8a4d790e653..6edbb804e60 100644
--- a/app/styles/settings/appearance.module.css
+++ b/app/styles/settings/appearance.module.css
@@ -1,19 +1,19 @@
.themes-form {
display: flex;
- gap: 8px;
+ gap: var(--space-xs);
flex-wrap: wrap;
}
.theme-label {
display: inline-block;
- padding: 16px;
+ padding: var(--space-s);
background: white;
- border-radius: 6px;
+ border-radius: var(--space-3xs);
box-shadow: 0 2px 3px hsla(51, 50%, 44%, .35);
}
.theme-preview {
width: 200px;
height: 160px;
- margin-bottom: 16px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/settings/email-notifications.module.css b/app/styles/settings/email-notifications.module.css
index 55542931c63..d6effb89b8c 100644
--- a/app/styles/settings/email-notifications.module.css
+++ b/app/styles/settings/email-notifications.module.css
@@ -1,5 +1,5 @@
.me-email-notifications {
- padding-bottom: 20px;
+ margin-bottom: var(--space-s);
display: flex;
flex-direction: column;
@@ -20,20 +20,19 @@
.notifications-row {
display: flex;
flex-direction: row;
+ align-items: center;
+ gap: var(--space-2xs);
}
.select-all-button,
.deselect-all-button {
composes: yellow-button small from '../shared/buttons.module.css';
- margin-right: 1rem;
}
.notifications-error,
.notifications-success {
border-top-width: 0;
font-weight: bold;
-
- padding: 0 10px 10px 20px;
}
.notifications-error {
@@ -44,7 +43,6 @@
color: green;
}
-
.update-notifications-button {
composes: yellow-button from '../shared/buttons.module.css';
}
diff --git a/app/styles/settings/profile.module.css b/app/styles/settings/profile.module.css
index 207473bf069..532969b5626 100644
--- a/app/styles/settings/profile.module.css
+++ b/app/styles/settings/profile.module.css
@@ -1,11 +1,15 @@
.me-profile {
- margin-bottom: 24px;
+ margin-bottom: var(--space-s);
+
+ .info {
+ display: flex;
+ }
- .info { display: flex; }
dl {
- margin: 0 0 0 30px;
- line-height: 150%;
+ margin: 0 0 0 var(--space-m);
+ line-height: 1.5;
font-size: 110%;
+
dt {
font-weight: bold;
width: 150px;
@@ -13,7 +17,15 @@
float: left;
clear: both;
}
- dd { float: left; margin-left: 10px; }
+
+ dd {
+ float: left;
+ margin-left: var(--space-xs);
+ }
+ }
+
+ p {
+ line-height: 1.5;
}
@media only screen and (max-width: 550px) {
@@ -22,7 +34,7 @@
}
.me-email {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
display: flex;
flex-direction: column;
}
diff --git a/app/styles/settings/tokens.module.css b/app/styles/settings/tokens.module.css
deleted file mode 100644
index e69de29bb2d..00000000000
diff --git a/app/styles/shared/buttons.module.css b/app/styles/shared/buttons.module.css
index bdddf18bfd8..8157106dde7 100644
--- a/app/styles/shared/buttons.module.css
+++ b/app/styles/shared/buttons.module.css
@@ -20,7 +20,7 @@
--bg-color-top-dark: #fed585;
--bg-color-bottom-dark: #fdbb39;
- padding: 15px 40px;
+ padding: var(--space-xs) var(--space-m-l);
display: inline-flex;
align-items: center;
justify-content: center;
@@ -29,14 +29,14 @@
font-weight: bold;
border: none;
outline: 0;
- border-radius: 30px;
+ border-radius: 5000px;
background: linear-gradient(to bottom, var(--bg-color-top) 0%, var(--bg-color-bottom) 100%);
cursor: pointer;
img, svg {
float: left;
display: inline-block;
- margin-right: 10px;
+ margin-right: var(--space-2xs);
}
&:hover, &:focus, &.active {
@@ -68,6 +68,5 @@
}
.small {
- padding: 10px 20px;
- border-radius: 30px;
+ padding: var(--space-2xs) var(--space-s);
}
diff --git a/app/styles/team.module.css b/app/styles/team.module.css
index a2afe7c5ce0..fae9e65e1ac 100644
--- a/app/styles/team.module.css
+++ b/app/styles/team.module.css
@@ -8,13 +8,13 @@
}
h2 {
- margin-top: 10px;
+ margin-top: var(--space-2xs);
color: var(--main-color-light);
}
}
.avatar {
- margin-right: 20px;
+ margin-right: var(--space-m);
}
.header-row {
@@ -23,7 +23,7 @@
}
.github-link {
- margin-left: 16px;
+ margin-left: var(--space-s);
&, &:hover {
color: var(--main-color);
@@ -39,7 +39,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -47,5 +47,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/styles/user.module.css b/app/styles/user.module.css
index 05440329514..536031f91ca 100644
--- a/app/styles/user.module.css
+++ b/app/styles/user.module.css
@@ -1,10 +1,7 @@
.header {
display: flex;
align-items: center;
-
- h1 {
- padding: 0 10px;
- }
+ gap: var(--space-xs);
}
.github-link {
@@ -22,7 +19,7 @@
display: flex;
align-items: center;
justify-content: space-between;
- margin-bottom: 25px;
+ margin-bottom: var(--space-s);
}
.sort-by-label {
@@ -30,5 +27,5 @@
}
.list {
- margin-bottom: 20px;
+ margin-bottom: var(--space-s);
}
diff --git a/app/templates/categories.hbs b/app/templates/categories.hbs
index 1be504632e2..fce9af2f46f 100644
--- a/app/templates/categories.hbs
+++ b/app/templates/categories.hbs
@@ -24,7 +24,7 @@
- {{category.category}}
+ {{~category.category~}}
{{format-num category.crates_cnt}} {{if (eq category.crates_cnt 1) "crate" "crates"}}
diff --git a/app/templates/dashboard.hbs b/app/templates/dashboard.hbs
index 093c7f0b58c..9a9dc67f5b2 100644
--- a/app/templates/dashboard.hbs
+++ b/app/templates/dashboard.hbs
@@ -47,7 +47,7 @@
{{#each this.myFeed as |version|}}
-
+
-
{{ version.crateName }}
{{ version.num }}
@@ -55,20 +55,19 @@
{{date-format-distance-to-now version.created_at addSuffix=true}}
-
+
{{/each}}
- {{#if this.loadMoreTask.isRunning}}
-
-
-
- {{else}}
- {{#if this.hasMore}}
-
diff --git a/app/templates/index.hbs b/app/templates/index.hbs
index 9c4b923fc71..fa9b049f808 100644
--- a/app/templates/index.hbs
+++ b/app/templates/index.hbs
@@ -1,15 +1,13 @@
-