More IDAA related updates

This commit is contained in:
Scott Idem
2025-06-23 14:15:50 -04:00
parent b59dcf20d5
commit e93c70e0e4
4 changed files with 82 additions and 61 deletions

View File

@@ -43,27 +43,24 @@ if (log_lvl) {
>
{#snippet header()}
<div class="flex flex-row items-center justify-between w-full">
<h3 class="text-base font-semibold">
<!-- <span class="text-sm text-gray-500">
Viewing:
</span> -->
{$idaa_slct.archive_content_obj?.name} - {$lq__archive_content_obj?.archive_content_id}</h3>
</div>
<div class="flex flex-row items-center justify-between w-full">
<h3 class="text-base font-semibold">
<!-- <span class="text-sm text-gray-500">
Viewing:
</span> -->
{$idaa_slct.archive_content_obj?.name} - {$lq__archive_content_obj?.archive_content_id}</h3>
</div>
<button
type="button"
class="btn btn-sm btn-secondary absolute top-2 right-2"
onclick={() => {
$idaa_sess.archives.show__modal_view__archive_content_id = false;
}}
>
<span class="fas fa-times"></span>
Close
</button>
<button
type="button"
class="btn btn-sm btn-secondary absolute top-2 right-2"
onclick={() => {
$idaa_sess.archives.show__modal_view__archive_content_id = false;
}}
>
<span class="fas fa-times"></span>
Close
</button>
{/snippet}
<Media_player

View File

@@ -280,59 +280,69 @@ function add_activity_log(
<!-- Modal: Post (Bulletin Board) view ID -->
<!-- title="{$lq__post_obj?.title ?? 'New Post'} - {$lq__post_obj?.id ?? 'Not Saved Yet'}" -->
<Modal
title="{$lq__post_obj?.title ?? 'New Post'} - {$lq__post_obj?.id ?? 'Not Saved Yet'}"
bind:open={$idaa_sess.bb.show__modal_view__post_id}
autoclose={false}
outsideclose={true}
placement="top-center"
size="lg"
class="bg-white dark:bg-gray-800 text-gray-800 dark:text-gray-200 rounded-lg border-gray-200 dark:border-gray-700 divide-gray-200 dark:divide-gray-700 shadow-md relative flex flex-col mx-auto w-full divide-y"
on:close={() => {
class="top-center bg-white dark:bg-gray-800 text-gray-800 dark:text-gray-200 rounded-lg border-gray-200 dark:border-gray-700 divide-gray-200 dark:divide-gray-700 shadow-md relative flex flex-col mx-auto w-full divide-y"
onclose={() => {
// We want to cancel the inline edit if the modal is closed
$idaa_sess.bb.show__inline_edit__post_obj = false;
}}
>
{#snippet header()}
<div class="flex flex-row items-center justify-between w-full">
<h3 class="text-lg font-semibold">
{#if $ae_loc.trusted_access || $lq__post_obj?.external_person_id === $idaa_loc.novi_uuid}
<button
onclick={() => {
// const url = new URL(location);
// url.searchParams.set('post_id', $lq__post_obj?.post_id_random);
// history.pushState({}, '', url);
// $idaa_sess.bb.show__modal_view = false;
if ($idaa_sess.bb.show__inline_edit__post_obj) {
$idaa_sess.bb.show__inline_edit__post_obj = false;
} else {
$idaa_sess.bb.show__inline_edit__post_obj = true;
}
}}
class="novi_btn btn btn-sm preset-tonal-warning border border-warning-500 hover:preset-filled-warning-500 transition"
title={`Edit meeting: ${$lq__post_obj?.title}`}
>
{#if $idaa_sess.bb.show__inline_edit__post_obj}
<span class="fas fa-times m-1"></span> Cancel Edit
{:else}
<span class="fas fa-edit m-1"></span> Edit
{/if}
</button>
{/if}
<!-- {$lq__post_obj?.title ?? 'New Post'} -->
<span class="">
<span class="fas fa-comment-alt m-1"></span>
{@html $lq__post_obj?.title ?? 'New Post'}
<!-- - {$lq__post_obj?.id ?? 'Not Yet Saved'} -->
</span>
{#if $lq__post_obj?.topic_id}<span class="badge badge-info preset-tonal-secondary"><span class="fas fa-user-md m-1"></span> {$lq__post_obj?.topic_name}</span>{/if}
</h3>
</div>
<div class="flex flex-row items-center justify-between w-full">
<h3 class="text-lg font-semibold">
{#if $ae_loc.trusted_access || $lq__post_obj?.external_person_id === $idaa_loc.novi_uuid}
<button
onclick={() => {
// const url = new URL(location);
// url.searchParams.set('post_id', $lq__post_obj?.post_id_random);
// history.pushState({}, '', url);
// $idaa_sess.bb.show__modal_view = false;
if ($idaa_sess.bb.show__inline_edit__post_obj) {
$idaa_sess.bb.show__inline_edit__post_obj = false;
} else {
$idaa_sess.bb.show__inline_edit__post_obj = true;
}
}}
class="novi_btn btn btn-sm preset-tonal-warning border border-warning-500 hover:preset-filled-warning-500 transition"
title={`Edit meeting: ${$lq__post_obj?.title}`}
>
{#if $idaa_sess.bb.show__inline_edit__post_obj}
<span class="fas fa-times m-1"></span> Cancel Edit
{:else}
<span class="fas fa-edit m-1"></span> Edit
{/if}
</button>
{/if}
<!-- {$lq__post_obj?.title ?? 'New Post'} -->
<span class="">
<span class="fas fa-comment-alt m-1"></span>
{@html $lq__post_obj?.title ?? 'New Post'}
<!-- - {$lq__post_obj?.id ?? 'Not Yet Saved'} -->
</span>
{#if $lq__post_obj?.topic_id}<span class="badge badge-info preset-tonal-secondary"><span class="fas fa-user-md m-1"></span> {$lq__post_obj?.topic_name}</span>{/if}
</h3>
</div>
<button
type="button"
class="btn btn-sm btn-secondary absolute top-2 right-2"
onclick={() => {
$idaa_sess.bb.show__modal_view__post_id = false;
$idaa_sess.bb.show__inline_edit__post_obj = false;
}}
>
<span class="fas fa-times"></span>
Close
</button>
{/snippet}
<Comp__post_obj_id_view
@@ -341,4 +351,18 @@ function add_activity_log(
lq__post_comment_obj={lq__post_comment_obj}
/>
{#snippet footer()}
<button
type="button"
class="btn btn-sm btn-secondary"
onclick={() => {
$idaa_sess.bb.show__modal_view__post_id = false;
$idaa_sess.bb.show__inline_edit__post_obj = false;
}}
>
<span class="fas fa-times"></span>
Close
</button>
{/snippet}
</Modal>

View File

@@ -899,7 +899,7 @@ function send_staff_notification_email() {
{#await prom_api__post_obj}
<span class="fas fa-spinner fa-spin m-1"></span> Saving
{:then}
<span class="fas fa-plus m-1"></span> Save New Event
<span class="fas fa-plus m-1"></span> Save New Post
{/await}
</button>
{/if}

View File

@@ -30,7 +30,7 @@ onMount(() => {
>
<header class="ae_header">
<h3 class="post__title flex flex-row gap-2 items-center h3 border-b border border-gray-200 w-full">
<h3 class="post__title flex flex-row gap-2 items-center h3 border-b border-gray-200 w-full">
<span class="post__title">
<span class="fas fa-comment-alt m-1"></span>
{@html idaa_post_obj.title}