This repository has been archived by the owner on Jun 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 11
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
gantrol
committed
Mar 2, 2023
1 parent
7ec17eb
commit 073c728
Showing
13 changed files
with
81 additions
and
75 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,15 @@ | ||
<script> | ||
import { popupPageI18nValue } from "~utils/constants"; | ||
export let promises; | ||
export let hidden = false; | ||
</script> | ||
|
||
{#await Promise.all(promises)} | ||
<p>{popupPageI18nValue.WAITING}</p> | ||
{:then _} | ||
<slot></slot> | ||
{:catch err} | ||
<p>{err}</p> | ||
{/await} | ||
<div class:hidden={hidden}> | ||
{#await Promise.all(promises)} | ||
<progress class="progress w-56"></progress> | ||
{:then _} | ||
<slot></slot> | ||
{:catch err} | ||
<p>{err}</p> | ||
{/await} | ||
</div> | ||
|
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 |
---|---|---|
@@ -1,53 +1,35 @@ | ||
<script> | ||
import Collapse from "~components/Collapse.svelte"; | ||
import { exportSettingsI18nValue, exportTypes, exportWidthTemplateKeys, popupPageI18nValue } from "~utils/constants"; | ||
import { exportSettingsI18nValue, exportTypes, exportWidthTemplateKeys } from "~utils/constants"; | ||
import { exportSettings } from "~utils/store/stores"; | ||
import PromiseWaiting from "~components/PromiseWaiting.svelte"; | ||
import SimpleSelect from "~components/SimpleSelect.svelte"; | ||
export let hidden = false; | ||
let promises = [ | ||
exportSettings.init(), | ||
]; | ||
</script> | ||
|
||
<PromiseWaiting {promises}> | ||
<Collapse | ||
title={popupPageI18nValue.EXPORT_SETTINGS_TITLE} | ||
default_open={true} | ||
> | ||
<PromiseWaiting {promises} {hidden}> | ||
{#each $exportSettings as message, i} | ||
<div class="form-control"> | ||
<div class="input-group"> | ||
<label class="label cursor-pointer"> | ||
<input type="checkbox" bind:checked={message.on} class="checkbox checkbox-primary" /> | ||
<input type="checkbox" bind:checked={message.on} class="checkbox checkbox-primary checkbox-xs" /> | ||
</label> | ||
<select | ||
class="select" | ||
bind:value="{message.type}"> | ||
{#each Object.keys(exportTypes) as key} | ||
<option value={exportTypes[key]}> | ||
{exportTypes[key]} | ||
</option> | ||
{/each} | ||
</select> | ||
<select | ||
class="select" | ||
bind:value="{message.size_template}"> | ||
{#each Object.keys(exportWidthTemplateKeys) as key} | ||
<option value={exportWidthTemplateKeys[key]}> | ||
{exportSettingsI18nValue[key]} | ||
</option> | ||
{/each} | ||
</select> | ||
|
||
<!-- <SimpleSelect--> | ||
<!-- bind:bind_value="{message.size_template}"--> | ||
<!-- keys={exportWidthTemplateKeys}--> | ||
<!-- values={exportSettingsI18nValue}--> | ||
<!-- />--> | ||
<SimpleSelect | ||
bind:bind_value="{message.type}" | ||
keys={exportTypes} | ||
values={exportSettingsI18nValue} | ||
/> | ||
<SimpleSelect | ||
bind:bind_value="{message.size_template}" | ||
keys={exportWidthTemplateKeys} | ||
values={exportSettingsI18nValue} | ||
/> | ||
</div> | ||
</div> | ||
{/each} | ||
</Collapse> | ||
</PromiseWaiting> | ||
|
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