mirror of
https://github.com/LukeHagar/sveltesociety.dev.git
synced 2025-12-10 04:21:49 +00:00
design system in place, touched up last pr styling
This commit is contained in:
@@ -7,10 +7,10 @@
|
|||||||
<style>
|
<style>
|
||||||
div {
|
div {
|
||||||
font-size: 1rem;
|
font-size: 1rem;
|
||||||
border: 2px solid #7e7e93;
|
border: 2px solid var(--dark-gray);
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
color: #7e7e93;
|
color: var(--dark-gray);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
@@ -18,13 +18,13 @@
|
|||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
div.small {
|
div.small {
|
||||||
font-size: 0.8em;
|
font-size: var(--font-100);
|
||||||
padding: 3px 10px;
|
padding: 3px 10px;
|
||||||
}
|
}
|
||||||
div:hover {
|
div:hover {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
border-color: var(--color) !important;
|
border-color: var(--primary);
|
||||||
color: var(--color) !important;
|
color: var(--primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
.arrow {
|
.arrow {
|
||||||
@@ -32,25 +32,27 @@
|
|||||||
height: 16px;
|
height: 16px;
|
||||||
-webkit-mask: url(/images/right-arrow.svg) no-repeat center;
|
-webkit-mask: url(/images/right-arrow.svg) no-repeat center;
|
||||||
mask: url(/images/right-arrow.svg) no-repeat center;
|
mask: url(/images/right-arrow.svg) no-repeat center;
|
||||||
background-color: #7e7e93;
|
background-color: var(--dark-gray);
|
||||||
}
|
}
|
||||||
div:hover .arrow {
|
div:hover .arrow {
|
||||||
background-color: #7e7e93;
|
background-color: var(--dark-gray);
|
||||||
}
|
}
|
||||||
.arrow.active {
|
.arrow.active {
|
||||||
background-color: #7e7e93;
|
background-color: var(--dark-gray);
|
||||||
}
|
}
|
||||||
|
|
||||||
.popin {
|
.popin {
|
||||||
font-size: 1rem;
|
min-width: 250px;
|
||||||
|
width: 100%;
|
||||||
|
font-size: var(--font-100);
|
||||||
display: none;
|
display: none;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: calc(100% - 1em);
|
left: var(--s-4);
|
||||||
top: 1em;
|
top: 100%;
|
||||||
z-index: 100;
|
z-index: 100;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
border: 2px solid var(--color);
|
border: 2px solid var(--primary);
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
background: white;
|
background: white;
|
||||||
}
|
}
|
||||||
@@ -58,11 +60,11 @@
|
|||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 700px) {
|
|
||||||
|
@media screen and (min-width: 700px) {
|
||||||
.popin {
|
.popin {
|
||||||
left: 1rem;
|
left: 95%;
|
||||||
right: 1rem;
|
top: var(--s-4);
|
||||||
top: 100%
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -72,5 +74,5 @@
|
|||||||
<slot />
|
<slot />
|
||||||
</span>
|
</span>
|
||||||
<div class="arrow" class:active />
|
<div class="arrow" class:active />
|
||||||
<span class="popin"><slot name="menu"></slot></span>
|
<section class="popin"><slot name="menu"></slot></section>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -46,12 +46,6 @@
|
|||||||
word-break: none;
|
word-break: none;
|
||||||
font-size: var(--font-300);
|
font-size: var(--font-300);
|
||||||
}
|
}
|
||||||
h3 a {
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
h3 a:hover {
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
.active,
|
.active,
|
||||||
.card:hover {
|
.card:hover {
|
||||||
background: #e8f3fe;
|
background: #e8f3fe;
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
</Link>
|
</Link>
|
||||||
{/each}
|
{/each}
|
||||||
<li>
|
<li>
|
||||||
<a href="/">
|
<a href="/" class="logo">
|
||||||
<img alt="Svelte Society Logo" src="/images/logo.svg" />
|
<img alt="Svelte Society Logo" src="/images/logo.svg" />
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@@ -63,6 +63,9 @@
|
|||||||
width: var(--s-12);
|
width: var(--s-12);
|
||||||
height: var(--s-12);
|
height: var(--s-12);
|
||||||
}
|
}
|
||||||
|
.logo {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
@media (min-width: 1280px) {
|
@media (min-width: 1280px) {
|
||||||
ul {
|
ul {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
@@ -14,8 +14,9 @@
|
|||||||
}
|
}
|
||||||
a {
|
a {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
|
border-bottom: transparent;
|
||||||
color: var(--inherit);
|
color: var(--inherit);
|
||||||
transition: border-bottom .2s;
|
transition: var(--link-transition);
|
||||||
font-size: var(--font-200);
|
font-size: var(--font-200);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -6,6 +6,18 @@ body {
|
|||||||
|
|
||||||
a {
|
a {
|
||||||
color: var(--link-color);
|
color: var(--link-color);
|
||||||
|
text-decoration: none;
|
||||||
|
border-bottom: 1px solid var(--link-color);
|
||||||
|
transition: var(--link-transition);
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 > a {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
h3 > a:hover {
|
||||||
|
border-bottom: none;
|
||||||
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
blockquote {
|
blockquote {
|
||||||
|
|||||||
@@ -23,6 +23,7 @@
|
|||||||
--accent: #011627;
|
--accent: #011627;
|
||||||
--orange: #f97316;
|
--orange: #f97316;
|
||||||
--gray: #c1cfda;
|
--gray: #c1cfda;
|
||||||
|
--dark-gray: #7e7e93;
|
||||||
--black: #12130f;
|
--black: #12130f;
|
||||||
--white: #f3f6f9;
|
--white: #f3f6f9;
|
||||||
--success: #29bf12;
|
--success: #29bf12;
|
||||||
@@ -46,7 +47,7 @@
|
|||||||
--font-code: 'Fira Mono', monospace;
|
--font-code: 'Fira Mono', monospace;
|
||||||
|
|
||||||
/************FONT SIZES***************/
|
/************FONT SIZES***************/
|
||||||
--font-100: 0.75rem;
|
--font-100: 0.85rem;
|
||||||
--font-200: clamp(1rem, 1.0655rem + 0.6098vw, 1.25rem);
|
--font-200: clamp(1rem, 1.0655rem + 0.6098vw, 1.25rem);
|
||||||
--font-300: clamp(1.25rem, 1.2494rem + 0.878vw, 1.333rem);
|
--font-300: clamp(1.25rem, 1.2494rem + 0.878vw, 1.333rem);
|
||||||
--font-400: clamp(1.5rem, 1.4627rem + 1.2366vw, 1.777rem);
|
--font-400: clamp(1.5rem, 1.4627rem + 1.2366vw, 1.777rem);
|
||||||
@@ -108,4 +109,8 @@
|
|||||||
0 4px 4px rgba(0, 0, 0, 0.15), 0 8px 8px rgba(0, 0, 0, 0.1), 0 16px 16px rgba(0, 0, 0, 0.05);
|
0 4px 4px rgba(0, 0, 0, 0.15), 0 8px 8px rgba(0, 0, 0, 0.1), 0 16px 16px rgba(0, 0, 0, 0.05);
|
||||||
--shadow-diffuse: 0 1px 1px rgba(0, 0, 0, 0.08), 0 2px 2px rgba(0, 0, 0, 0.12),
|
--shadow-diffuse: 0 1px 1px rgba(0, 0, 0, 0.08), 0 2px 2px rgba(0, 0, 0, 0.12),
|
||||||
0 4px 4px rgba(0, 0, 0, 0.16), 0 8px 8px rgba(0, 0, 0, 0.2);
|
0 4px 4px rgba(0, 0, 0, 0.16), 0 8px 8px rgba(0, 0, 0, 0.2);
|
||||||
|
|
||||||
|
/* ***********TRANSITIONS************* */
|
||||||
|
--link-transition: border-bottom 0.15s ease-out;
|
||||||
|
--menu-transition: scale 0.2s ease-out;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,9 +54,10 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.inputs {
|
.inputs {
|
||||||
display: grid;
|
display: flex;
|
||||||
grid-template-columns: repeat(4, auto);
|
flex-wrap: wrap;
|
||||||
grid-gap: 0.5rem;
|
align-items: stretch;
|
||||||
|
gap: var(--s-2);
|
||||||
margin-right: 2rem;
|
margin-right: 2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -77,11 +78,14 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
ul.popin {
|
ul.popin {
|
||||||
padding: 0.5ex;
|
display: grid;
|
||||||
|
gap: var(--s-2);
|
||||||
|
padding: var(--s-2);
|
||||||
margin: 0;
|
margin: 0;
|
||||||
font-size: 0.7em;
|
font-size: var(--font-100);
|
||||||
max-height: 50vh;
|
max-height: 50vh;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
overflow-x: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
ul.popin li {
|
ul.popin li {
|
||||||
@@ -127,6 +131,10 @@
|
|||||||
margin: 0 1ex 0 0;
|
margin: 0 1ex 0 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.submit {
|
||||||
|
align-self: flex-end;
|
||||||
|
}
|
||||||
|
|
||||||
@media screen and (max-width: 1024px) {
|
@media screen and (max-width: 1024px) {
|
||||||
.controls {
|
.controls {
|
||||||
flex-flow: column-reverse;
|
flex-flow: column-reverse;
|
||||||
@@ -139,8 +147,9 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.searchbar {
|
.searchbar {
|
||||||
align-self: flex-end;
|
align-self: stretch;
|
||||||
margin-bottom: 1ex;
|
margin-bottom: 1ex;
|
||||||
|
width: auto;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -152,11 +161,6 @@
|
|||||||
.inputs {
|
.inputs {
|
||||||
grid-template-columns: auto;
|
grid-template-columns: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.searchbar {
|
|
||||||
width: auto;
|
|
||||||
align-self: stretch;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
<svelte:head>
|
<svelte:head>
|
||||||
@@ -185,7 +189,7 @@
|
|||||||
{/each}
|
{/each}
|
||||||
</ul>
|
</ul>
|
||||||
</Button>
|
</Button>
|
||||||
<Button on:click={() => location.href = "/help/components"}>Submit a component</Button>
|
|
||||||
<Button active={sorting !== ''}>
|
<Button active={sorting !== ''}>
|
||||||
Sort
|
Sort
|
||||||
<ul slot="menu" role="menu" class="popin no-wrap">
|
<ul slot="menu" role="menu" class="popin no-wrap">
|
||||||
@@ -205,6 +209,7 @@
|
|||||||
<li><label><input type="radio" bind:group={packageManager} value="yarn"> Yarn</label></li>
|
<li><label><input type="radio" bind:group={packageManager} value="yarn"> Yarn</label></li>
|
||||||
</ul>
|
</ul>
|
||||||
</Button>
|
</Button>
|
||||||
|
<a href = "/help/components" class="submit">Submit a component</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<input
|
<input
|
||||||
|
|||||||
Reference in New Issue
Block a user