diff --git a/jest.config.cjs b/jest.config.cjs
index 8cbf894..5faa4b6 100644
--- a/jest.config.cjs
+++ b/jest.config.cjs
@@ -1,5 +1,5 @@
/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */
module.exports = {
- preset: 'ts-jest',
- testEnvironment: 'node',
-};
\ No newline at end of file
+ preset: 'ts-jest',
+ testEnvironment: 'node'
+};
diff --git a/src/lib/components/ComponentIndex/ArrowButton.svelte b/src/lib/components/ComponentIndex/ArrowButton.svelte
index 104f503..612083f 100644
--- a/src/lib/components/ComponentIndex/ArrowButton.svelte
+++ b/src/lib/components/ComponentIndex/ArrowButton.svelte
@@ -1,83 +1,83 @@
-
-Package Manager
-
-
\ No newline at end of file
+ Package Manager
+
@@ -19,5 +18,4 @@
text-align: start;
display: block;
}
-
diff --git a/src/lib/layouts/Recipe.svelte b/src/lib/layouts/Recipe.svelte
index 0a5b837..19fc81f 100644
--- a/src/lib/layouts/Recipe.svelte
+++ b/src/lib/layouts/Recipe.svelte
@@ -1,75 +1,75 @@
-
-
Table of Contents
- {#each $categories as node}
-
- {#if $page.path.includes(node.path)}
-
- {/if}
- {/each}
-
-
- {title}
-
-
+
+
Table of Contents
+ {#each $categories as node}
+
+ {#if $page.path.includes(node.path)}
+
+ {/if}
+ {/each}
+
+
+ {title}
+
+
diff --git a/src/lib/layouts/RecipeCategory.svelte b/src/lib/layouts/RecipeCategory.svelte
index ae185c6..6dd1444 100644
--- a/src/lib/layouts/RecipeCategory.svelte
+++ b/src/lib/layouts/RecipeCategory.svelte
@@ -1,85 +1,85 @@
-
-
Table of Contents
- {#each $categories as node}
-
- {#if $page.path.includes(node.path)}
-
- {/if}
- {/each}
-
-
- {title}
-
+
+
Table of Contents
+ {#each $categories as node}
+
+ {#if $page.path.includes(node.path)}
+
+ {/if}
+ {/each}
+
+
+ {title}
+
-
-
+
+
diff --git a/src/lib/utils/sort.test.ts b/src/lib/utils/sort.test.ts
index d1ff6e4..9839ad8 100644
--- a/src/lib/utils/sort.test.ts
+++ b/src/lib/utils/sort.test.ts
@@ -1,58 +1,61 @@
import { compare } from './sort';
-describe("sort", () => {
- const mock = [{
- "addedOn": "2019-09-29T14:39:13Z",
- "category": "Svelte",
- "description": "Boilerplate with TypeScript, Webpack, Storybook, Travis CI, SCSS, Babel, EsLint, Prettier, Jest",
- "stars": 51,
- "tags": [],
- "title": "agusID/boilerplate-svelte",
- "url": "https://github.com/agusID/boilerplate-svelte"
- },
- {
- "addedOn": "2020-09-29T14:39:13Z",
- "category": "Svelte",
- "description": "An example repo of a Svelte app that is IE11 compatible",
- "stars": 27,
- "tags": [],
- "title": "angelozehr/svelte-example-museums",
- "url": "https://github.com/angelozehr/svelte-example-museums"
- }];
-
- it("should sort by added_desc", () => {
- mock.sort(compare("added_desc"));
- expect(mock[0].title).toEqual("angelozehr/svelte-example-museums");
- expect(mock[1].title).toEqual("agusID/boilerplate-svelte");
- });
-
- it("should sort by added_asc", () => {
- mock.sort(compare("added_asc"));
- expect(mock[0].title).toEqual("agusID/boilerplate-svelte");
- expect(mock[1].title).toEqual("angelozehr/svelte-example-museums");
- });
-
- it("should sort by name_asc", () => {
- mock.sort(compare("name_asc"));
- expect(mock[0].title).toEqual("agusID/boilerplate-svelte");
- expect(mock[1].title).toEqual("angelozehr/svelte-example-museums");
- });
-
- it("should sort by name_desc", () => {
- mock.sort(compare("name_desc"));
- expect(mock[0].title).toEqual("angelozehr/svelte-example-museums");
- expect(mock[1].title).toEqual("agusID/boilerplate-svelte");
- });
-
- it("should sort by stars_asc", () => {
- mock.sort(compare("stars_asc"));
- expect(mock[0].title).toEqual("angelozehr/svelte-example-museums");
- expect(mock[1].title).toEqual("agusID/boilerplate-svelte");
- });
-
- it("should sort by stars_desc", () => {
- mock.sort(compare("stars_desc"));
- expect(mock[0].title).toEqual("agusID/boilerplate-svelte");
- expect(mock[1].title).toEqual("angelozehr/svelte-example-museums");
- });
-});
\ No newline at end of file
+describe('sort', () => {
+ const mock = [
+ {
+ addedOn: '2019-09-29T14:39:13Z',
+ category: 'Svelte',
+ description:
+ 'Boilerplate with TypeScript, Webpack, Storybook, Travis CI, SCSS, Babel, EsLint, Prettier, Jest',
+ stars: 51,
+ tags: [],
+ title: 'agusID/boilerplate-svelte',
+ url: 'https://github.com/agusID/boilerplate-svelte'
+ },
+ {
+ addedOn: '2020-09-29T14:39:13Z',
+ category: 'Svelte',
+ description: 'An example repo of a Svelte app that is IE11 compatible',
+ stars: 27,
+ tags: [],
+ title: 'angelozehr/svelte-example-museums',
+ url: 'https://github.com/angelozehr/svelte-example-museums'
+ }
+ ];
+
+ it('should sort by added_desc', () => {
+ mock.sort(compare('added_desc'));
+ expect(mock[0].title).toEqual('angelozehr/svelte-example-museums');
+ expect(mock[1].title).toEqual('agusID/boilerplate-svelte');
+ });
+
+ it('should sort by added_asc', () => {
+ mock.sort(compare('added_asc'));
+ expect(mock[0].title).toEqual('agusID/boilerplate-svelte');
+ expect(mock[1].title).toEqual('angelozehr/svelte-example-museums');
+ });
+
+ it('should sort by name_asc', () => {
+ mock.sort(compare('name_asc'));
+ expect(mock[0].title).toEqual('agusID/boilerplate-svelte');
+ expect(mock[1].title).toEqual('angelozehr/svelte-example-museums');
+ });
+
+ it('should sort by name_desc', () => {
+ mock.sort(compare('name_desc'));
+ expect(mock[0].title).toEqual('angelozehr/svelte-example-museums');
+ expect(mock[1].title).toEqual('agusID/boilerplate-svelte');
+ });
+
+ it('should sort by stars_asc', () => {
+ mock.sort(compare('stars_asc'));
+ expect(mock[0].title).toEqual('angelozehr/svelte-example-museums');
+ expect(mock[1].title).toEqual('agusID/boilerplate-svelte');
+ });
+
+ it('should sort by stars_desc', () => {
+ mock.sort(compare('stars_desc'));
+ expect(mock[0].title).toEqual('agusID/boilerplate-svelte');
+ expect(mock[1].title).toEqual('angelozehr/svelte-example-museums');
+ });
+});
diff --git a/src/routes/__layout.svelte b/src/routes/__layout.svelte
index 55271fe..e113a4b 100644
--- a/src/routes/__layout.svelte
+++ b/src/routes/__layout.svelte
@@ -27,7 +27,7 @@
\ No newline at end of file
+ main {
+ padding: var(--s-10) var(--s-5) var(--s-20);
+ }
+
diff --git a/src/routes/about/__layout.svelte b/src/routes/about/__layout.svelte
index c7d02bf..25ed9b1 100644
--- a/src/routes/about/__layout.svelte
+++ b/src/routes/about/__layout.svelte
@@ -1,22 +1,23 @@
- About Svelte Society
+ About Svelte Society
-
+
\ No newline at end of file
+ .wrapper {
+ max-width: 65ch;
+ }
+ .wrapper :global(h2),
+ .wrapper :global(h3) {
+ margin-top: 2rem;
+ margin-bottom: 1.25rem;
+ }
+ .wrapper :global(p) {
+ margin-bottom: 1.25rem;
+ }
+ .wrapper :global(li) {
+ margin-bottom: 1.1rem;
+ }
+
diff --git a/src/routes/cheatsheet/cheat-sheet.js b/src/routes/cheatsheet/cheat-sheet.js
index 1825890..11f1c60 100644
--- a/src/routes/cheatsheet/cheat-sheet.js
+++ b/src/routes/cheatsheet/cheat-sheet.js
@@ -1,12 +1,12 @@
-const replPath = 'https://svelte.dev/repl'
-const docPath = 'https://svelte.dev/docs'
+const replPath = 'https://svelte.dev/repl';
+const docPath = 'https://svelte.dev/docs';
export const cheatSheet = [
- {
- title: "Svelte Component",
- repl: `${replPath}/6a5416148c4b410b8ee0325eef54b107`,
- doc: `${docPath}#Component_format`,
- content: `
+ {
+ title: 'Svelte Component',
+ repl: `${replPath}/6a5416148c4b410b8ee0325eef54b107`,
+ doc: `${docPath}#Component_format`,
+ content: `
@@ -31,12 +31,12 @@ export const cheatSheet = [
`
- },
- {
- title: "Expressions",
- repl: `${replPath}/27bd55a7357046f2911923069dee9d86`,
- doc: `${docPath}#Text_expressions`,
- content: `
@@ -355,14 +346,12 @@ import Widget from '.Widget.svelte'
...
`
-
- },
- {
- title: "Lifecycle",
- repl: `${replPath}/ca959a7e552a4b35aa678dbe9a2d2b48`,
- doc: `${docPath}#svelte`,
- content:
- `
+ },
+ {
+ title: 'Lifecycle',
+ repl: `${replPath}/ca959a7e552a4b35aa678dbe9a2d2b48`,
+ doc: `${docPath}#svelte`,
+ content: `
@@ -423,13 +409,12 @@ onMount(() => {
// Other transitions
[Blur, Scale, Fly, Draw, Slide]
`
- },
- {
- title: "Reactive Expressions",
- repl: `${replPath}/0f7793bf7b0745f1b356327fad4a71e1`,
- doc: `${docPath}#2_Assignments_are_reactive`,
- content:
-`
`
- },
-]
+ }
+];
diff --git a/src/routes/cheatsheet/index.svelte b/src/routes/cheatsheet/index.svelte
index b9be128..46d8efd 100644
--- a/src/routes/cheatsheet/index.svelte
+++ b/src/routes/cheatsheet/index.svelte
@@ -20,11 +20,11 @@
\ No newline at end of file
+ main {
+ display: flex;
+ flex-wrap: wrap;
+ align-items: stretch;
+ justify-items: stretch;
+ gap: var(--s-10);
+ }
+
diff --git a/src/routes/components/components.js b/src/routes/components/components.js
index 4116204..f8b2b11 100644
--- a/src/routes/components/components.js
+++ b/src/routes/components/components.js
@@ -1,24 +1,24 @@
const components = new Array(6)
-.fill({
- image: "/preview-image.png",
- title: "svelte-tooltip",
- description:
- "A tooltip action that you can attach to any element and pass in a Svelte component...",
- tags: [],
- stars: 511,
- addedOn: new Date(),
- category: "forms"
-})
-.concat(
- new Array(3).fill({
- image: "/preview-image.png",
- title: "svelte-ui",
- description:
- "A tooltip action that you can attach to any element and pass in a Svelte component...",
- tags: [],
- stars: 511,
- addedOn: new Date(),
- category: "ui"
- })
-);
-export default components;
\ No newline at end of file
+ .fill({
+ image: '/preview-image.png',
+ title: 'svelte-tooltip',
+ description:
+ 'A tooltip action that you can attach to any element and pass in a Svelte component...',
+ tags: [],
+ stars: 511,
+ addedOn: new Date(),
+ category: 'forms'
+ })
+ .concat(
+ new Array(3).fill({
+ image: '/preview-image.png',
+ title: 'svelte-ui',
+ description:
+ 'A tooltip action that you can attach to any element and pass in a Svelte component...',
+ tags: [],
+ stars: 511,
+ addedOn: new Date(),
+ category: 'ui'
+ })
+ );
+export default components;
diff --git a/src/routes/components/components.json b/src/routes/components/components.json
index 58b1d81..039f399 100644
--- a/src/routes/components/components.json
+++ b/src/routes/components/components.json
@@ -2216,12 +2216,7 @@
"description": "Add OAuth2 authorization in Svelte (and SvelteKit, works with SSR)",
"npm": "@macfja/svelte-oauth2",
"stars": 3,
- "tags": [
- "auth",
- "integrations",
- "ssr",
- "third party services"
- ],
+ "tags": ["auth", "integrations", "ssr", "third party services"],
"url": "https://github.com/macfja/svelte-oauth2#readme",
"addedOn": "2021-09-10T20:00:00.000Z"
}
diff --git a/src/routes/components/index.svelte b/src/routes/components/index.svelte
index 5a0c690..5144d88 100644
--- a/src/routes/components/index.svelte
+++ b/src/routes/components/index.svelte
@@ -83,7 +83,7 @@
-
+