feat: refine ISAC design and prepare production deployment
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
<script lang="ts">
|
||||
import { page } from '$app/state';
|
||||
|
||||
let { compact = false }: { compact?: boolean } = $props();
|
||||
const permissions = $derived((page.data.permissions as string[] | undefined) ?? []);
|
||||
const can = (permission: string) => permissions.includes('*') || permissions.includes(permission);
|
||||
const publishesDirectly = $derived(can('data.manage'));
|
||||
const canSubmit = $derived(publishesDirectly || (can('data.propose') && Boolean(page.data.contributorMode?.enabled)));
|
||||
</script>
|
||||
|
||||
{#if canSubmit}
|
||||
<p class="mutation-consequence" class:compact class:direct={publishesDirectly} role="note">
|
||||
<b>{publishesDirectly ? 'DIRECT PUBLISH' : 'OVERSIGHT REVIEW'}</b>
|
||||
<span>{publishesDirectly ? 'Changes publish immediately and create an audit event.' : 'Saving creates a proposal; live data remains unchanged until Oversight approves it.'}</span>
|
||||
</p>
|
||||
{/if}
|
||||
Reference in New Issue
Block a user