mirror of
https://github.com/kmc7468/arkvault.git
synced 2025-12-16 06:58:46 +00:00
Modal, BeforeContinueModal 컴포넌트 추가
This commit is contained in:
@@ -1,10 +1,25 @@
|
||||
<script lang="ts">
|
||||
import { Button, TextButton } from "$lib/components/buttons";
|
||||
import { BottomDiv } from "$lib/components/divs";
|
||||
import BeforeContinueModal from "./BeforeContinueModal.svelte";
|
||||
|
||||
import IconKey from "~icons/material-symbols/key";
|
||||
|
||||
let { data } = $props();
|
||||
|
||||
let isBeforeContinueModalOpen = $state(false);
|
||||
|
||||
const exportKeyPair = () => {
|
||||
// TODO
|
||||
console.log(data.pubKeyBase64);
|
||||
console.log(data.privKeyBase64);
|
||||
};
|
||||
|
||||
const continueWithoutExport = () => {
|
||||
isBeforeContinueModalOpen = false;
|
||||
|
||||
// TODO
|
||||
};
|
||||
</script>
|
||||
|
||||
<svetle:head>
|
||||
@@ -27,17 +42,22 @@
|
||||
</div>
|
||||
<BottomDiv>
|
||||
<div class="w-full">
|
||||
<Button
|
||||
onclick={() => {
|
||||
// TODO
|
||||
console.log(data.privKeyBase64);
|
||||
console.log(data.pubKeyBase64);
|
||||
}}>암호 키 내보내기</Button
|
||||
>
|
||||
<Button onclick={exportKeyPair}>암호 키 내보내기</Button>
|
||||
</div>
|
||||
<div class="w-fit">
|
||||
<TextButton>내보내지 않을래요</TextButton>
|
||||
<TextButton
|
||||
onclick={() => {
|
||||
isBeforeContinueModalOpen = true;
|
||||
}}
|
||||
>
|
||||
내보내지 않을래요
|
||||
</TextButton>
|
||||
</div>
|
||||
</BottomDiv>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<BeforeContinueModal
|
||||
bind:isOpen={isBeforeContinueModalOpen}
|
||||
onContinueClick={continueWithoutExport}
|
||||
/>
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
<script lang="ts">
|
||||
import { Modal } from "$lib/components";
|
||||
import { Button } from "$lib/components/buttons";
|
||||
|
||||
interface Props {
|
||||
onContinueClick: () => void;
|
||||
isOpen: boolean;
|
||||
}
|
||||
|
||||
let { onContinueClick, isOpen = $bindable() }: Props = $props();
|
||||
</script>
|
||||
|
||||
<Modal bind:isOpen>
|
||||
<div class="space-y-4 px-1">
|
||||
<div class="space-y-2">
|
||||
<p class="break-keep text-xl font-bold">내보내지 않고 계속할까요?</p>
|
||||
<p class="break-keep">
|
||||
보안상의 이유로 지금 시점 이후로는 암호 키를 파일로 내보낼 수 없어요.
|
||||
</p>
|
||||
</div>
|
||||
<div class="flex gap-2">
|
||||
<Button
|
||||
color="gray"
|
||||
onclick={() => {
|
||||
isOpen = false;
|
||||
}}>아니요</Button
|
||||
>
|
||||
<Button onclick={onContinueClick}>계속합니다</Button>
|
||||
</div>
|
||||
</div>
|
||||
</Modal>
|
||||
Reference in New Issue
Block a user