forked from liou666/polyglot
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
liuxinqi
committed
Apr 13, 2023
1 parent
a0c20d5
commit 47f5b09
Showing
9 changed files
with
148 additions
and
136 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<script setup lang="ts"> | ||
import InputKit from '@/components/widgets/InputKit.vue' | ||
import { OPEN_KEY, OPEN_PROXY } from '@/constant' | ||
const openKey = useLocalStorage(OPEN_KEY, '') | ||
const proxy = useLocalStorage(OPEN_PROXY, '') | ||
</script> | ||
|
||
<template> | ||
<div flex="~ col gap-3" items-center> | ||
<div flex w-50 text-sm> | ||
<InputKit v-model="openKey"> | ||
<template #mainIcon> | ||
<i inline-block mr-1 rotate-115 i-ic:baseline-key /> | ||
</template> | ||
<template #mainText> | ||
点击设置OpenAi Key | ||
</template> | ||
</InputKit> | ||
</div> | ||
<div flex w-50 text-sm> | ||
<InputKit v-model="proxy" h-4 input-type="text"> | ||
<template #mainIcon> | ||
<i inline-block mr-1 text-sm i-carbon:server-proxy /> | ||
</template> | ||
<template #mainText> | ||
点击设置代理 | ||
</template> | ||
</InputKit> | ||
</div> | ||
</div> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<script setup lang="ts"> | ||
import Modal from './widgets/Modal.vue' | ||
import NewChat from './NewChat.vue' | ||
import Setting from './Setting.vue' | ||
const isDark = useDark() | ||
const toggleDark = useToggle(isDark) | ||
const addVisible = ref(false) | ||
const settingVisible = ref(false) | ||
</script> | ||
|
||
<template> | ||
<div py-1> | ||
<div | ||
nav-item | ||
@click="() => toggleDark()" | ||
> | ||
<i icon-btn dark:i-carbon-moon i-carbon:sun /> | ||
<span v-if="isDark">Light Mode</span> | ||
<span v-else>Dark Mode</span> | ||
</div> | ||
<div | ||
nav-item | ||
@click="addVisible = true" | ||
> | ||
<i icon-btn i-ic:baseline-person-add-alt /> | ||
<span>New Chat</span> | ||
</div> | ||
<div nav-item @click="settingVisible = true"> | ||
<i icon-btn i-carbon:settings /> | ||
<span>Setting</span> | ||
</div> | ||
</div> | ||
|
||
<Modal v-model:visible="addVisible" class="dark:bg-[#111111] bg-white" center max-w-120 p6> | ||
<NewChat @close="addVisible = false" /> | ||
</Modal> | ||
|
||
<Modal v-model:visible="settingVisible" h20 class="dark:bg-[#111111] bg-white" center max-w-80 p6> | ||
<Setting /> | ||
</Modal> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
Oops, something went wrong.