Skip to content

Commit

Permalink
npm run prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
twm committed Nov 4, 2024
1 parent 4aefd8d commit 9fb65bd
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 19 deletions.
20 changes: 10 additions & 10 deletions src/lib/FracInput.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script lang="ts">
import { run } from 'svelte/legacy';
import { run } from "svelte/legacy"
import { frac, parseFrac } from "$lib/frac"
Expand All @@ -26,12 +26,12 @@
}
interface Props {
id: string;
value: number;
min?: number | null;
max?: number | null;
step?: number | null;
required?: boolean;
id: string
value: number
min?: number | null
max?: number | null
step?: number | null
required?: boolean
}
let {
Expand All @@ -40,8 +40,8 @@
min = null,
max = null,
step = null,
required = false
}: Props = $props();
required = false,
}: Props = $props()
let focused: boolean = $state(false)
let input: HTMLInputElement = $state()
Expand All @@ -60,7 +60,7 @@
displayValue = rawValue
}
}
});
})
</script>

<span class="range">
Expand Down
4 changes: 2 additions & 2 deletions src/lib/Layout.svelte
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<script>
interface Props {
children?: import('svelte').Snippet;
children?: import("svelte").Snippet
}
let { children }: Props = $props();
let { children }: Props = $props()
</script>

<div class="wrapper">
Expand Down
11 changes: 6 additions & 5 deletions src/lib/PartList.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,12 @@
}
let gap = 0.5
let totalWidth = $derived($parts.reduce((max, part) => Math.max(max, part.length), 0))
let totalHeight = $derived($parts.reduce(
(total, part) => total + (part.width + gap) * part.count,
-gap
))
let totalWidth = $derived(
$parts.reduce((max, part) => Math.max(max, part.length), 0)
)
let totalHeight = $derived(
$parts.reduce((total, part) => total + (part.width + gap) * part.count, -gap)
)
</script>

<h2>Part List</h2>
Expand Down
4 changes: 2 additions & 2 deletions src/routes/+layout.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
import normalizeCss from "$lib/vendor/normalize.css/normalize-8.0.1.css?url"
import stylesCss from "$lib/styles.css?url"
interface Props {
children?: import('svelte').Snippet;
children?: import("svelte").Snippet
}
let { children }: Props = $props();
let { children }: Props = $props()
</script>

<svelte:head>
Expand Down

0 comments on commit 9fb65bd

Please sign in to comment.