Merge branch 'main' into main
This commit is contained in:
@@ -10,7 +10,9 @@
|
||||
import BackgroundDom from "./BackgroundDom.svelte";
|
||||
import SideBarArrow from "../UI/GUI/SideBarArrow.svelte";
|
||||
import VisualNovelMain from "../VisualNovel/VisualNovelMain.svelte";
|
||||
import ModuleChatMenu from "../Setting/Pages/Module/ModuleChatMenu.svelte";
|
||||
let openChatList = false
|
||||
let openModuleList = false
|
||||
|
||||
const wallPaper = `background: url(${defaultWallpaper})`
|
||||
const externalStyles =
|
||||
@@ -40,7 +42,7 @@
|
||||
<ResizeBox />
|
||||
{/if}
|
||||
{/if}
|
||||
<DefaultChatScreen customStyle={bgImg.length > 2 ? `${externalStyles}`: ''} bind:openChatList/>
|
||||
<DefaultChatScreen customStyle={bgImg.length > 2 ? `${externalStyles}`: ''} bind:openChatList bind:openModuleList/>
|
||||
</div>
|
||||
</div>
|
||||
{:else if $DataBase.theme === 'waifu'}
|
||||
@@ -55,7 +57,7 @@
|
||||
{/if}
|
||||
{/if}
|
||||
<div class="h-full w-2xl" style:width="{42 * ($DataBase.waifuWidth / 100)}rem" class:halfwp={$selectedCharID >= 0 && $CurrentCharacter.viewScreen !== 'none'}>
|
||||
<DefaultChatScreen customStyle={`${externalStyles}backdrop-filter: blur(4px);`} bind:openChatList/>
|
||||
<DefaultChatScreen customStyle={`${externalStyles}backdrop-filter: blur(4px);`} bind:openChatList bind:openModuleList/>
|
||||
</div>
|
||||
</div>
|
||||
{:else if $DataBase.theme === 'waifuMobile'}
|
||||
@@ -66,7 +68,7 @@
|
||||
class:per33={$selectedCharID >= 0 && $CurrentCharacter.viewScreen !== 'none'}
|
||||
class:h-full={!($selectedCharID >= 0 && $CurrentCharacter.viewScreen !== 'none')}
|
||||
>
|
||||
<DefaultChatScreen customStyle={`${externalStyles}backdrop-filter: blur(4px);`} bind:openChatList/>
|
||||
<DefaultChatScreen customStyle={`${externalStyles}backdrop-filter: blur(4px);`} bind:openChatList bind:openModuleList/>
|
||||
</div>
|
||||
{#if $selectedCharID >= 0}
|
||||
{#if $CurrentCharacter.viewScreen !== 'none'}
|
||||
@@ -79,6 +81,8 @@
|
||||
{/if}
|
||||
{#if openChatList}
|
||||
<ChatList close={() => {openChatList = false}}/>
|
||||
{:else if openModuleList}
|
||||
<ModuleChatMenu close={() => {openModuleList = false}}/>
|
||||
{/if}
|
||||
|
||||
<style>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<script lang="ts">
|
||||
import Suggestion from './Suggestion.svelte';
|
||||
import { CameraIcon, DatabaseIcon, DicesIcon, GlobeIcon, ImagePlusIcon, LanguagesIcon, Laugh, MenuIcon, MicOffIcon, RefreshCcwIcon, ReplyIcon, Send, StepForwardIcon } from "lucide-svelte";
|
||||
import { CameraIcon, DatabaseIcon, DicesIcon, GlobeIcon, ImagePlusIcon, LanguagesIcon, Laugh, MenuIcon, MicOffIcon, PackageIcon, RefreshCcwIcon, ReplyIcon, Send, StepForwardIcon } from "lucide-svelte";
|
||||
import { CurrentCharacter, CurrentChat, CurrentUsername, selectedCharID, CurrentUserIcon, CurrentShowMemoryLimit,CurrentSimpleCharacter } from "../../ts/stores";
|
||||
import Chat from "./Chat.svelte";
|
||||
import { DataBase, type Message, type character, type groupChat } from "../../ts/storage/database";
|
||||
@@ -36,6 +36,7 @@
|
||||
let doingChatInputTranslate = false
|
||||
let currentCharacter:character|groupChat = $CurrentCharacter
|
||||
let toggleStickers:boolean = false
|
||||
export let openModuleList = false
|
||||
export let openChatList:boolean = false
|
||||
|
||||
async function send(){
|
||||
@@ -582,7 +583,7 @@
|
||||
{/if}
|
||||
|
||||
{#if openMenu}
|
||||
<div class="absolute right-2 bottom-16 p-5 bg-darkbg flex flex-col gap-3 text-textcolor" on:click={(e) => {
|
||||
<div class="absolute right-2 bottom-16 p-5 bg-darkbg flex flex-col gap-3 text-textcolor rounded-md" on:click={(e) => {
|
||||
e.stopPropagation()
|
||||
}}>
|
||||
{#if $CurrentCharacter.type === 'group'}
|
||||
@@ -664,9 +665,15 @@
|
||||
<ReplyIcon />
|
||||
<span class="ml-2">{language.autoSuggest}</span>
|
||||
</div>
|
||||
<div class="flex items-center cursor-pointer hover:text-green-500 transition-colors" on:click={reroll}>
|
||||
<RefreshCcwIcon />
|
||||
<span class="ml-2">{language.reroll}</span>
|
||||
|
||||
|
||||
<div class="flex items-center cursor-pointer hover:text-green-500 transition-colors" on:click={() => {
|
||||
$CurrentChat.modules ??= []
|
||||
openModuleList = true
|
||||
openMenu = false
|
||||
}}>
|
||||
<PackageIcon />
|
||||
<span class="ml-2">{language.modules}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user