|
1 | 1 | <script lang="ts">
|
2 |
| - import { CardGrid, BoxAvatar, Alert } from '$lib/components'; |
| 2 | + import { CardGrid, BoxAvatar } from '$lib/components'; |
3 | 3 | import { Container } from '$lib/layout';
|
4 | 4 | import { Button } from '$lib/elements/forms';
|
5 | 5 | import { sdk } from '$lib/stores/sdk';
|
|
14 | 14 | import { Submit, trackEvent, trackError } from '$lib/actions/analytics';
|
15 | 15 | import { collection } from '../../store';
|
16 | 16 | import { page } from '$app/stores';
|
| 17 | + import { Alert } from '@appwrite.io/pink-svelte'; |
17 | 18 |
|
18 | 19 | let showDelete = false;
|
19 | 20 | let permissions = $doc?.$permissions;
|
|
85 | 86 | <svelte:fragment slot="aside">
|
86 | 87 | {#if $collection.documentSecurity}
|
87 | 88 | {#if showPermissionAlert}
|
88 |
| - <Alert type="info" dismissible on:dismiss={() => (showPermissionAlert = false)}> |
89 |
| - <svelte:fragment slot="title">Document security is enabled</svelte:fragment> |
90 |
| - <p class="text"> |
91 |
| - Users will be able to access this document if they have been granted <b |
92 |
| - >either document or collection permissions. |
93 |
| - </b> |
94 |
| - </p> |
95 |
| - </Alert> |
| 89 | + <Alert.Inline |
| 90 | + status="info" |
| 91 | + title="Document security is enabled" |
| 92 | + dismissible |
| 93 | + on:dismiss={() => (showPermissionAlert = false)}> |
| 94 | + Users will be able to access this document if they have been granted <b |
| 95 | + >either document or collection permissions.</b> |
| 96 | + </Alert.Inline> |
96 | 97 | {/if}
|
97 | 98 | {#if permissions}
|
98 | 99 | <Permissions bind:permissions />
|
99 | 100 | {/if}
|
100 | 101 | {:else}
|
101 |
| - <Alert type="info"> |
102 |
| - <svelte:fragment slot="title">Document security is disabled</svelte:fragment> |
103 |
| - <p class="text"> |
104 |
| - If you want to assign document permissions. Go to Collection settings and |
105 |
| - enable document security. Otherwise, only collection permissions will be |
106 |
| - used. |
107 |
| - </p> |
108 |
| - </Alert> |
| 102 | + <Alert.Inline status="info" title="Document security is disabled"> |
| 103 | + If you want to assign document permissions. Go to Collection settings and enable |
| 104 | + document security. Otherwise, only collection permissions will be used. |
| 105 | + </Alert.Inline> |
109 | 106 | {/if}
|
110 | 107 | </svelte:fragment>
|
111 | 108 |
|
|
0 commit comments