-
Notifications
You must be signed in to change notification settings - Fork 145
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update message detail to show push preview
- Loading branch information
1 parent
ea87937
commit 543fca4
Showing
2 changed files
with
34 additions
and
0 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
31 changes: 31 additions & 0 deletions
31
src/routes/console/project-[project]/messaging/message-[message]/pushPreview.svelte
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 lang="ts"> | ||
import { CardGrid, Heading } from '$lib/components'; | ||
import { FormList, InputText, InputTextarea } from '$lib/elements/forms'; | ||
import { message } from './store'; | ||
import PushPhone from '../pushPhone.svelte'; | ||
</script> | ||
|
||
<CardGrid> | ||
<div class="grid-1-2-col-1 u-flex-vertical u-cross-start u-gap-16"> | ||
<Heading tag="h6" size="7">Preview</Heading> | ||
<PushPhone title={$message.data.title} body={$message.data.body} /> | ||
</div> | ||
<svelte:fragment slot="aside"> | ||
<FormList> | ||
<InputText id="title" label="Title" disabled={true} bind:value={$message.data.title}> | ||
</InputText> | ||
<InputTextarea | ||
id="message" | ||
label="Message" | ||
disabled={true} | ||
bind:value={$message.data.body}> | ||
</InputTextarea> | ||
</FormList> | ||
</svelte:fragment> | ||
|
||
<svelte:fragment slot="actions"> | ||
<!-- TODO: Add support for editing draft messages --> | ||
<!-- <Button disabled={$message.status !== 'draft'} on:click={() => console.log('click')} | ||
>Edit message</Button> --> | ||
</svelte:fragment> | ||
</CardGrid> |