Skip to content

styles update #116

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

Merged
merged 15 commits into from
Dec 13, 2022
Merged
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,15 @@
</script>

<p>
The <code>{name}</code> package is {speed} fast.
Download version {version} from
The <code>{name}</code> package is {speed} fast. Download version {version}
from
<a {href}>npm</a>
and <a href={website}>learn more here</a>
</p>

<style>
code {
font-family: Menlo;
background: #eee;
padding: 0.1em 0.2em;
border-radius: 0.2em;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,10 @@
border-radius: 0.2em;
background-color: #ffdfd3;
}

@media (prefers-color-scheme: dark) {
span {
background-color: #4f352b;
}
}
</style>
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,10 @@
border-radius: 0.2em;
background-color: #ffdfd3;
}

@media (prefers-color-scheme: dark) {
span {
background-color: #4f352b;
}
}
</style>
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script>
async function getRandomNumber() {
const res = await fetch(
`tutorial/random-number`
`https://svelte.dev/tutorial/random-number`
);
const text = await res.text();

Expand All @@ -19,9 +19,7 @@
}
</script>

<button on:click={handleClick}>
generate random number
</button>
<button on:click={handleClick}> generate random number </button>

<!-- replace this element -->
<p>{promise}</p>
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script>
async function getRandomNumber() {
const res = await fetch(
`tutorial/random-number`
`https://svelte.dev/tutorial/random-number`
);
const text = await res.text();

Expand All @@ -19,9 +19,7 @@
}
</script>

<button on:click={handleClick}>
generate random number
</button>
<button on:click={handleClick}> generate random number </button>

{#await promise}
<p>...waiting</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ You can customise the fallback error page. Create a `src/error.html` file:
<head>
<meta charset="utf-8" />
<title>%sveltekit.error.message%</title>
<style>
body {
color: #ff531a;
}
</style>
</head>
<body>
<h1>Game over</h1>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
<head>
<meta charset="utf-8" />
<title>%sveltekit.error.message%</title>
<style>
body {
color: #ff531a;
}
</style>
</head>
<body>
<h1>Game over</h1>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@
}

p {
color: #777;
opacity: 0.9;
margin: 0;
}

.discussion {
background-color: #eee;
background-color: rgba(82, 81, 75, 0.1);
border-top: 1px #ccc solid;
}
</style>
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,12 @@
}

p {
color: #777;
opacity: 0.9;
margin: 0;
}

.discussion {
background-color: #eee;
background-color: rgba(82, 81, 75, 0.1);
border-top: 1px #ccc solid;
}
</style>
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
div {
padding: 1em;
margin: 0 0 1em 0;
background-color: #eee;
border: 1px solid #ff3e00;
}

.active {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
div {
padding: 1em;
margin: 0 0 1em 0;
background-color: #eee;
border: 1px solid #ff3e00;
}

.active {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
content: attr(data-name) ' layout';
left: 1em;
top: -1em;
background-color: white;
background-color: #ff531a;
color: white;
padding: 0.5em;
line-height: 1;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
<style>
marquee {
font-family: 'Comic Sans MS';
color: purple;
color: #e60073;
}
</style>
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: $env/static/public
title: $env/dynamic/public
---

As with [private environment variables](/tutorial/env-static-private), it's preferable to use static values if possible, but if necessary we can use dynamic values instead:
Expand Down
20 changes: 20 additions & 0 deletions content/tutorial/common/src/app.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,26 @@
.error {
color: red;
}

code {
background: hsl(206, 20%, 80%);
}

@media (prefers-color-scheme: dark) {
body {
background: hsl(0, 0%, 18%);
color: hsl(0, 0%, 90%);
}
code {
background: hsl(0, 0%, 40%);
}
a {
color: hsl(204, 100%, 63%);
}
nav {
background-color: #1a0d01;
}
}
</style>
</head>
<body>
Expand Down
1 change: 1 addition & 0 deletions content/tutorial/common/static/svelte-logo-mask.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions content/tutorial/common/static/tutorial/dark-theme.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
body {
background-color: #333;
color: whitesmoke;
transition: all 0.5s;
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions content/tutorial/common/static/tutorial/icons/folder.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions content/tutorial/common/static/tutorial/icons/gif.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions content/tutorial/common/static/tutorial/icons/md.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions content/tutorial/common/static/tutorial/icons/xlsx.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"@sveltejs/adapter-auto": "1.0.0-next.90",
"@sveltejs/adapter-vercel": "1.0.0-next.85",
"@sveltejs/kit": "next",
"@sveltejs/site-kit": "^2.1.2",
"@sveltejs/site-kit": "^3.0.2",
"@types/diff": "^5.0.2",
"@types/marked": "^4.0.8",
"@types/prismjs": "^1.26.0",
Expand Down
20 changes: 7 additions & 13 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/app.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" class="theme-default typo-default">
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%sveltekit.assets%/favicon.png" />
Expand Down
3 changes: 2 additions & 1 deletion src/lib/components/Modal.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@
transform: translate(-50%, -50%);
width: calc(100vw - 2rem);
max-width: 56rem;
background: white;
background: var(--sk-back-2);
color: var(--sk-text-2);
padding: 2rem;
border: none;
border-radius: 0.5rem;
Expand Down
67 changes: 0 additions & 67 deletions src/lib/components/PreloadingIndicator.svelte

This file was deleted.

2 changes: 1 addition & 1 deletion src/lib/components/SplitPane.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@
top: 0;
width: 100%;
height: 100%;
background: rgba(255, 255, 255, 0.01);
background: rgba(255, 255, 255, 0.0001);
}

.divider {
Expand Down
2 changes: 1 addition & 1 deletion src/lib/components/filetree/ContextMenu.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
}

button {
color: var(--text);
color: var(--sk-text-2);
width: 100%;
text-align: left;
border: 0px;
Expand Down
Loading