temp(badges): restrict Email Link to Administrator + Edit Mode only
Was: visible to everyone pre-print, Trusted+Edit for reprints. Now: Administrator + Edit Mode only (all three locations). Temporarily restricted for Axonius 2026 — restore broader access after event. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -47,6 +47,7 @@ let lq__event_badge_template_obj = $derived(
|
||||
|
||||
// Access level shortcuts
|
||||
let is_trusted = $derived($ae_loc.trusted_access === true);
|
||||
let is_admin = $derived($ae_loc.administrator_access === true);
|
||||
|
||||
// IMPORTANT: $ae_loc.edit_mode is the GLOBAL AE Edit Mode — a UI preference that
|
||||
// reveals editable fields, debug info, and advanced options app-wide. It is NOT
|
||||
@@ -423,9 +424,9 @@ $effect(() => {
|
||||
</a>
|
||||
{/if}
|
||||
|
||||
<!-- Email review link: available before first print, or staff+edit for reprints.
|
||||
TODO: replace alert with actual email API call -->
|
||||
{#if !is_printed || (is_trusted && is_edit_mode)}
|
||||
<!-- Email review link: Administrator + Edit Mode only
|
||||
Temporarily restricted — TODO: restore broader access after Axonius 2026 -->
|
||||
{#if is_admin && is_edit_mode}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-sm preset-tonal-surface flex items-center gap-1"
|
||||
|
||||
@@ -269,9 +269,9 @@ let can_edit_fields: string[] = $derived.by(() => {
|
||||
</button>
|
||||
{/if}
|
||||
|
||||
<!-- 3. Email Review Link: all if not printed; Trusted+Edit if printed
|
||||
TODO: replace alert with actual email API call -->
|
||||
{#if !is_printed || (is_trusted && is_edit_mode)}
|
||||
<!-- 3. Email Review Link: Administrator + Edit Mode only
|
||||
Temporarily restricted — TODO: restore broader access after Axonius 2026 -->
|
||||
{#if is_administrator && is_edit_mode}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-sm preset-tonal-surface flex items-center gap-1"
|
||||
|
||||
@@ -41,6 +41,7 @@ let copy_status: Record<string, 'idle' | 'copied'> = $state({});
|
||||
|
||||
// Access level shortcuts
|
||||
let is_trusted = $derived($ae_loc.trusted_access === true);
|
||||
let is_admin = $derived($ae_loc.administrator_access === true);
|
||||
let is_public = $derived($ae_loc.public_access === true); // public passcode or higher — may print first prints
|
||||
let is_edit_mode = $derived($ae_loc.edit_mode === true);
|
||||
|
||||
@@ -310,9 +311,9 @@ let visible_badge_obj_li = $derived(
|
||||
</button>
|
||||
{/if}
|
||||
|
||||
<!-- 4. Email Review Link: all if not printed; Trusted + Edit Mode if printed
|
||||
TODO: replace alert with actual email API call -->
|
||||
{#if !is_printed || (is_trusted && is_edit_mode)}
|
||||
<!-- 4. Email Review Link: Administrator + Edit Mode only
|
||||
Temporarily restricted — TODO: restore broader access after Axonius 2026 -->
|
||||
{#if is_admin && is_edit_mode}
|
||||
<button
|
||||
type="button"
|
||||
class="hover:text-primary-800-200 hover:bg-primary-200-800 active:bg-surface-200-700 flex items-center gap-1 px-3 py-2 text-base font-bold transition-colors duration-1000 hover:duration-300 min-w-0 preset-tonal-primary rounded-lg border border-primary-200-800"
|
||||
|
||||
Reference in New Issue
Block a user