자잘한 리팩토링

This commit is contained in:
static
2025-01-09 03:56:06 +09:00
parent 66daebe577
commit 8873337ede
13 changed files with 46 additions and 64 deletions

View File

@@ -19,7 +19,7 @@
}}
class="w-full rounded-xl active:bg-gray-100"
>
<div class="flex w-full items-stretch justify-between p-2 transition active:scale-95">
<div class="flex w-full justify-between p-2 transition active:scale-95">
<div>
{@render children?.()}
</div>

View File

@@ -4,12 +4,12 @@
import { AdaptiveDiv } from "$lib/components/divs";
interface Props {
bottom?: string;
icon: Component<SvelteHTMLElements["svg"]>;
offset?: string;
onclick?: () => void;
}
let { bottom = "bottom-20", icon: Icon, onclick }: Props = $props();
let { icon: Icon, offset = "bottom-20", onclick }: Props = $props();
const click = () => {
setTimeout(() => {
@@ -19,13 +19,13 @@
</script>
<div class="pointer-events-none fixed inset-0">
<div class="absolute right-0 w-full {bottom}">
<div class="absolute w-full {offset}">
<AdaptiveDiv>
<div class="relative">
<div class="pointer-events-auto absolute bottom-4 right-4">
<div class="absolute bottom-4 right-4">
<button
onclick={click}
class="flex h-14 w-14 items-center justify-center rounded-full bg-gray-300 shadow-lg transition active:scale-95 active:bg-gray-400"
class="pointer-events-auto flex h-14 w-14 items-center justify-center rounded-full bg-gray-300 shadow-lg transition active:scale-95 active:bg-gray-400"
>
<Icon class="text-xl" />
</button>