mirror of
https://github.com/Lapikud/lapikud.github.io.git
synced 2026-08-08 19:49:13 +00:00
fixes
This commit is contained in:
@@ -1,10 +1,9 @@
|
|||||||
<script>
|
<script>
|
||||||
import Button from "./Button.svelte";
|
import Button from "./Button.svelte";
|
||||||
import ButtonBorderless from "./ButtonBorderless.svelte";
|
|
||||||
|
|
||||||
// Props
|
// Props
|
||||||
export let name = "";
|
export let name = "";
|
||||||
export let variant = "default"; // 'default' | 'borderless' aka 'Button' | 'ButtonBorderless'
|
export let border = false;
|
||||||
|
|
||||||
let isOpen = false;
|
let isOpen = false;
|
||||||
|
|
||||||
@@ -22,27 +21,7 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="relative inline-block" on:focusout={handleFocusOut}>
|
<div class="relative inline-block" on:focusout={handleFocusOut}>
|
||||||
{#if variant === "borderless"}
|
<Button onClick={toggle} border={border}>
|
||||||
<ButtonBorderless onClick={toggle}>
|
|
||||||
{name}
|
|
||||||
<svg
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
fill="none"
|
|
||||||
viewBox="0 0 24 24"
|
|
||||||
stroke-width="2"
|
|
||||||
stroke="currentColor"
|
|
||||||
class="w-5 ml-2 mt-1 transition-transform inline-block"
|
|
||||||
style:transform={isOpen ? "rotate(180deg)" : "none"}
|
|
||||||
>
|
|
||||||
<path
|
|
||||||
stroke-linecap="round"
|
|
||||||
stroke-linejoin="round"
|
|
||||||
d="m19.5 8.25-7.5 7.5-7.5-7.5"
|
|
||||||
/>
|
|
||||||
</svg>
|
|
||||||
</ButtonBorderless>
|
|
||||||
{:else}
|
|
||||||
<Button onClick={toggle}>
|
|
||||||
{name}
|
{name}
|
||||||
<svg
|
<svg
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
@@ -60,7 +39,6 @@
|
|||||||
/>
|
/>
|
||||||
</svg>
|
</svg>
|
||||||
</Button>
|
</Button>
|
||||||
{/if}
|
|
||||||
|
|
||||||
<div
|
<div
|
||||||
class="absolute mt-2 rounded-md shadow-lg bg-white ring-1 ring-black/5 overflow-hidden flex flex-col"
|
class="absolute mt-2 rounded-md shadow-lg bg-white ring-1 ring-black/5 overflow-hidden flex flex-col"
|
||||||
|
|||||||
@@ -5,5 +5,4 @@ export { default as Grid } from './layout/Grid.svelte'
|
|||||||
export { default as Center } from './layout/Center.svelte'
|
export { default as Center } from './layout/Center.svelte'
|
||||||
|
|
||||||
export { default as Button } from './Button.svelte'
|
export { default as Button } from './Button.svelte'
|
||||||
export { default as ButtonBorderless } from './ButtonBorderless.svelte'
|
|
||||||
export { default as Dropdown } from './Dropdown.svelte'
|
export { default as Dropdown } from './Dropdown.svelte'
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
<script>
|
<script>
|
||||||
import {
|
import {
|
||||||
Button,
|
Button,
|
||||||
ButtonBorderless,
|
|
||||||
Container,
|
Container,
|
||||||
Card,
|
Card,
|
||||||
Stack,
|
Stack,
|
||||||
@@ -19,9 +18,7 @@
|
|||||||
“Lapikud”.
|
“Lapikud”.
|
||||||
</p>
|
</p>
|
||||||
<Button href="/docs/getting-started">Get Started</Button>
|
<Button href="/docs/getting-started">Get Started</Button>
|
||||||
<ButtonBorderless href="/docs/components"
|
<Button href="/docs/components">Explore Components</Button>
|
||||||
>Explore Components</ButtonBorderless
|
|
||||||
>
|
|
||||||
</Card>
|
</Card>
|
||||||
|
|
||||||
<Grid min="250px" gap="var(--space-4)">
|
<Grid min="250px" gap="var(--space-4)">
|
||||||
|
|||||||
@@ -1 +0,0 @@
|
|||||||
<div>testing</div>
|
|
||||||
Reference in New Issue
Block a user