-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add bridge luanguage and update ui
- Loading branch information
Showing
24 changed files
with
662 additions
and
750 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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
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,54 @@ | ||
<script> | ||
import { isLanguageModalOpen } from '../store/modalLanguage'; | ||
import { locales } from '../i18nLocal' | ||
import { locale } from 'svelte-i18n'; | ||
function closeLangModal() { | ||
$isLanguageModalOpen = false | ||
} | ||
const onWindowKeydownPressed = (event) => { | ||
if (event.key === 'Escape') { | ||
$isLanguageModalOpen = false | ||
} | ||
}; | ||
const switchLang = (value)=>{ | ||
locale.set(value); | ||
isLanguageModalOpen.set(false); | ||
} | ||
</script> | ||
|
||
|
||
<svelte:window on:keydown={onWindowKeydownPressed} /> | ||
|
||
<div class="language_modal"> | ||
<div class="inner"> | ||
<div class="Modal-header-wrapper"> | ||
<div class="Modal-title-bar"> | ||
<div class="Modal-title">Select Language</div> | ||
<div class="Modal-close-button"> | ||
<button type="button" class="cursor-pointer font-sans text-lg" | ||
on:click={closeLangModal}> | ||
× | ||
</button> | ||
</div> | ||
</div> | ||
</div> | ||
<div class="dividerline"></div> | ||
<div class="languagebox"> | ||
{#each Object.keys(locales) as item (item)} | ||
<div class="menu-item flexbox" on:keydown={onWindowKeydownPressed} on:click={() => switchLang(item)}> | ||
<div class="menu-item-group fs12">{locales[item]}</div> | ||
<div class="network-dropdown-menu-item-img flexbox"> | ||
{#if $locale === item} | ||
<button type="button" class="cursor-pointer font-sans text-lg"> | ||
✓ | ||
</button> | ||
{/if} | ||
</div> | ||
</div> | ||
{/each} | ||
</div> | ||
</div> | ||
</div> |
Oops, something went wrong.