diff --git a/src/routes/idaa/(idaa)/+layout.svelte b/src/routes/idaa/(idaa)/+layout.svelte index f3123092..6021624d 100644 --- a/src/routes/idaa/(idaa)/+layout.svelte +++ b/src/routes/idaa/(idaa)/+layout.svelte @@ -1,199 +1,211 @@ {#if !browser} -

+

Loading...

{:else if novi_verifying} -
-

+

+

Verifying identity...

@@ -208,10 +220,13 @@ {$idaa_loc.novi_email ?? 'email not set'} {:else} -

IDAA Novi UUID not found!

+

+ IDAA Novi UUID not found! +

{/if} {:else} -
+

diff --git a/src/routes/idaa/(idaa)/+page.svelte b/src/routes/idaa/(idaa)/+page.svelte index 9dd26cf6..d2425380 100644 --- a/src/routes/idaa/(idaa)/+page.svelte +++ b/src/routes/idaa/(idaa)/+page.svelte @@ -1,65 +1,76 @@
-
-

IDAA Module Dashboard

-

Select a customized module to continue

-
+
+

IDAA Module Dashboard

+

Select a customized module to continue

+
- {#if $ae_loc.trusted_access} - + {:else} +
+ +

Access Restricted

+

+ You must be signed in with Trusted Access or higher + to view these modules. +

+
+ Return Home + +
+
+ {/if}
diff --git a/src/routes/idaa/(idaa)/archives/+layout.svelte b/src/routes/idaa/(idaa)/archives/+layout.svelte index e981d7fb..82b75bff 100644 --- a/src/routes/idaa/(idaa)/archives/+layout.svelte +++ b/src/routes/idaa/(idaa)/archives/+layout.svelte @@ -1,53 +1,53 @@ {@render children?.()} diff --git a/src/routes/idaa/(idaa)/archives/+page.svelte b/src/routes/idaa/(idaa)/archives/+page.svelte index 3dcd0bd3..992cad1e 100644 --- a/src/routes/idaa/(idaa)/archives/+page.svelte +++ b/src/routes/idaa/(idaa)/archives/+page.svelte @@ -1,146 +1,146 @@ @@ -161,23 +161,21 @@ novi_uuid: $idaa_loc.novi_uuid, novi_email: $idaa_loc.novi_email, novi_full_name: $idaa_loc.novi_full_name - }} -> + }}> {#await lq__archive_obj_li} -
- + Loading archives... + >Loading archives...
{:then} {#if $lq__archive_obj_li && $lq__archive_obj_li?.length} {:else} -
-

+

+

No archives found.

diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/+page.svelte b/src/routes/idaa/(idaa)/archives/[archive_id]/+page.svelte index 5a2f1895..9e2357b6 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/+page.svelte +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/+page.svelte @@ -1,317 +1,315 @@ @@ -329,22 +327,19 @@ -

+ class="ae_header archive__header flex w-full flex-row flex-wrap items-center justify-evenly gap-2">

+ flex max-w-full + min-w-1/2 flex-row items-center justify-center gap-2 + text-2xl + font-bold + "> {$lq__archive_obj?.name ?? 'Archive'} @@ -360,29 +355,24 @@
+ flex max-w-full min-w-1/4 flex-row items-center + justify-evenly + gap-2 + "> + class="float-right flex flex-row flex-wrap items-center justify-end gap-1"> {#if $lq__archive_obj?.topic_name} - {$lq__archive_obj?.topic_name} + {$lq__archive_obj?.topic_name} {/if} {#if $ae_loc.trusted_access && $lq__archive_obj?.hide} Hidden + > Hidden {/if} {#if $ae_loc.administrator_access && !$lq__archive_obj?.enable} Not enabled + > Not enabled {/if}
@@ -397,26 +387,23 @@ novi_uuid: $idaa_loc.novi_uuid, novi_email: $idaa_loc.novi_email, novi_full_name: $idaa_loc.novi_full_name - }} - > + }}>

+ border-b-surface-300-700 mb-2 flex w-full flex-row + items-center + justify-center gap-2 border-b + p-1 pb-2 + "> + "> View Other Archives @@ -426,7 +413,6 @@ - + class="top-center relative mx-auto flex w-full flex-col divide-y divide-gray-200 rounded-lg border-gray-200 bg-white text-gray-800 shadow-md dark:divide-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-200"> {#snippet header()} -
+

{#if $ae_loc.trusted_access} @@ -452,9 +437,8 @@ $idaa_slct.archive_id; $idaa_sess.archives.show__modal_edit__archive_id = false; }} - class="novi_btn btn btn-sm preset-tonal-warning border border-warning-500 hover:preset-filled-warning-500 transition" - title={`View meeting: ${$lq__archive_obj?.name}`} - > + class="novi_btn btn btn-sm preset-tonal-warning border-warning-500 hover:preset-filled-warning-500 border transition" + title={`View meeting: ${$lq__archive_obj?.name}`}> View @@ -475,24 +459,21 @@ onclick={() => { $idaa_sess.archives.show__modal_view__archive_id = false; $idaa_sess.archives.show__modal_edit__archive_id = false; - }} - > + }}> Close {/snippet} - + class="top-center relative mx-auto flex w-full flex-col divide-y divide-gray-200 rounded-lg border-gray-200 bg-white text-gray-800 shadow-md dark:divide-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-200"> {#snippet header()} -
+

{#if $ae_loc.trusted_access} @@ -505,9 +486,8 @@ $idaa_sess.archives.show__modal_edit__archive_content_id = false; }} - class="novi_btn btn btn-sm preset-tonal-warning border border-warning-500 hover:preset-filled-warning-500 transition" - title={`View meeting: ${$lq__archive_content_obj?.name}`} - > + class="novi_btn btn btn-sm preset-tonal-warning border-warning-500 hover:preset-filled-warning-500 border transition" + title={`View meeting: ${$lq__archive_content_obj?.name}`}> Cancel @@ -528,14 +508,12 @@ onclick={() => { $idaa_sess.archives.show__modal_view__archive_content_id = false; $idaa_sess.archives.show__modal_edit__archive_content_id = false; - }} - > + }}> Close {/snippet} - diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts b/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts index 43c8a910..2f432cd7 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/+page.ts @@ -42,7 +42,9 @@ export const load = (async ({ params, parent }) => { }) .then((results) => { if (!results) { - console.warn(`ae IDAA Archives [archive_id] +page.ts: Archive ${archive_id} not found via API or Cache.`); + console.warn( + `ae IDAA Archives [archive_id] +page.ts: Archive ${archive_id} not found via API or Cache.` + ); } }); } diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_id_edit.svelte b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_id_edit.svelte index 23ac177e..a0fca178 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_id_edit.svelte +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_id_edit.svelte @@ -1,331 +1,387 @@
+ class:ae_create={!$idaa_slct.archive_content_id}>
@@ -452,8 +446,7 @@
+ class="ae_section archive_content__general space-y-2 rounded border border-gray-200 p-2">
@@ -496,12 +487,10 @@ bind:value={ $idaa_slct.archive_content_obj.archive_content_type } - class="select w-52" - > + class="select w-52"> + >Hosted File in Æ @@ -536,11 +525,10 @@ {#if $idaa_slct.archive_content_id}
+ !$idaa_slct.archive_content_id}>

Upload/Manage Hosted File

{#if !$idaa_slct.archive_content_obj?.hosted_file_id} @@ -549,7 +537,7 @@ {#if $ae_loc.trusted_access} @@ -571,8 +558,7 @@
+ class="upload"> + log_lvl={1}> {#snippet label()}
+ class="flex flex-col items-center gap-2 py-2">
+ class="bg-primary-500/10 text-primary-500 rounded-full p-3">

+ class="text-primary-500 font-bold"> Upload archive files

@@ -621,8 +603,7 @@

+ class=""> + bind:slct_hosted_file_obj />
{/if} {:else} @@ -728,8 +708,7 @@ }); } }} - class="novi_btn btn btn-sm preset-tonal-error float-right" - > + class="novi_btn btn btn-sm preset-tonal-error float-right"> {#await prom_api__archive_content_obj__hosted_file} {:then} @@ -765,8 +744,7 @@ value={$idaa_slct.archive_content_obj.filename ? $idaa_slct.archive_content_obj.filename : 'unknown'} - class="input w-full" - /> + class="input w-full" /> {/if}
{:else}
+ class="ae_section archive_content__hosted_file space-y-2 rounded border border-gray-200 p-2"> Save the form first before uploading a file.
{/if}
+ class="ae_section archive_content__original space-y-2 rounded border border-gray-200 p-2">

Original

@@ -850,10 +822,9 @@ .original_timezone : $ae_loc.current_timezone} class="select w-56" - title="Select the original timezone" - > + title="Select the original timezone"> - {#each ($lq__lu_time_zone ?? []) as lu_timezone (lu_timezone.name)} + {#each $lq__lu_time_zone ?? [] as lu_timezone (lu_timezone.name)} @@ -868,8 +839,7 @@ ? $idaa_slct.archive_content_obj .original_timezone : $ae_loc.current_timezone} - class="input w-56" - /> + class="input w-56" /> {/if}
@@ -881,204 +851,193 @@ id="original_location" name="original_location" value={$idaa_slct.archive_content_obj.original_location} - class="input w-96" - /> + class="input w-96" />
{#if $ae_loc.trusted_access} -
+
-
- +
-
- Hide -
- - -
-
- - -
-
- -
- Priority -
- - -
-
- - -
-
-
- - - - - - - - {#if $ae_loc.administrator_access} + class="flex w-full flex-col flex-wrap items-center justify-center gap-2 md:flex-row md:justify-stretch"> + class="flex grow flex-row flex-wrap items-center justify-evenly gap-1">
+ class="form-check flex flex-row items-center justify-center gap-1"> Enable + class="legend form-check-label text-sm font-semibold" + >Hide
+ +
+
+ + +
+
+ +
+ Priority +
+ - + class="radio form-check-input" /> +
- + class="radio form-check-input" /> +
- {:else} - - {/if} - - {#if $ae_loc.trusted_access} - - {/if} + class=" + col-sm-1 + flex grow flex-row flex-wrap items-center justify-evenly + gap-1 + "> + -
- {$lq__archive_content_obj?.updated_on - ? `DB Updated on: ${$lq__archive_content_obj?.updated_on}` - : ''} - {$idaa_slct.archive_content_obj?.updated_on - ? `SLCT Updated on: ${$idaa_slct.archive_content_obj?.updated_on}` - : ''} -
+ + + + {#if $ae_loc.administrator_access} + +
+ Enable +
+ + +
+
+ + +
+
+
+ {:else} + + {/if} + + + {#if $ae_loc.trusted_access} + + {/if} + +
+ {$lq__archive_content_obj?.updated_on + ? `DB Updated on: ${$lq__archive_content_obj?.updated_on}` + : ''} + {$idaa_slct.archive_content_obj?.updated_on + ? `SLCT Updated on: ${$idaa_slct.archive_content_obj?.updated_on}` + : ''} +
@@ -1087,10 +1046,9 @@
+ d-flex align-items-center justify-content-between flex w-full flex-row + items-center justify-between gap-1 + "> diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_li.svelte b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_li.svelte index 3242a821..a8e9e0b8 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_li.svelte +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_content_obj_li.svelte @@ -1,74 +1,75 @@
+ class="archive_list flex w-full flex-col items-center justify-center gap-2"> {#if $ae_loc.trusted_access && $ae_loc.edit_mode} -
-
{/if} {#if $idaa_sess.archives.show_list__archive_content_li_group == idaa_archive_content_obj.group}
-
+ $ae_loc.edit_mode}> +

{@html idaa_archive_content_obj.name} + >{@html idaa_archive_content_obj.name}

{#if idaa_archive_content_obj.original_location} @@ -197,18 +200,16 @@

{idaa_archive_content_obj.original_location} + >{idaa_archive_content_obj.original_location}

{/if}
{#if idaa_archive_content_obj.description}
{@html idaa_archive_content_obj.description}
{/if} + class="archive__description rounded-lg bg-white p-2 text-sm font-normal text-wrap whitespace-pre-wrap shadow-md">{@html idaa_archive_content_obj.description}{/if}
+ class="ae_options flex flex-row flex-wrap items-center justify-center gap-2"> {#if idaa_archive_content_obj?.hosted_file_id} {#if $ae_loc.trusted_access && idaa_archive_content_obj?.hosted_file_id} @@ -271,14 +270,12 @@ max_filename={30} classes="novi_btn btn btn-sm lg:btn-md preset-tonal-primary hover:preset-filled-primary-500 min-w-72 lg:min-w-96" linked_to_type="archive_content" - linked_to_id={idaa_archive_content_obj.archive_content_id} - /> + linked_to_id={idaa_archive_content_obj.archive_content_id} /> {/if} {:else} + title="No file linked."> @@ -304,8 +301,7 @@ $idaa_slct.archive_content_id; }} class="novi_btn btn btn-sm preset-tonal-warning hover:preset-filled-warning-500 transition" - title={`Edit archive content: ${idaa_archive_content_obj?.name}`} - > + title={`Edit archive content: ${idaa_archive_content_obj?.name}`}> Edit Content {/if} @@ -314,16 +310,13 @@
{#if idaa_archive_content_obj?.description}
+ class="archive_content__description ae_description">
+ class="ae_label archive_content__description text-sm"> Description:
+ class="ae_value archive_content__description"> {@html idaa_archive_content_obj?.description}
@@ -331,16 +324,13 @@ {#if idaa_archive_content_obj?.content_html}
+ class="archive_content__content_html ae_content_html">
+ class="ae_label archive_content__content_html text-sm"> Content:
+ class="ae_value archive_content__content_html"> {@html idaa_archive_content_obj?.content_html}
@@ -349,37 +339,31 @@
+ !idaa_archive_content_obj?.original_timezone}> Original date/time: + >Original date/time: {#if idaa_archive_content_obj.original_datetime} {ae_util.iso_datetime_formatter( idaa_archive_content_obj.original_datetime, 'datetime_12_long' - )} + )} {/if} {#if idaa_archive_content_obj.original_timezone} Timezone: {idaa_archive_content_obj.original_timezone} + >{idaa_archive_content_obj.original_timezone} {/if}
+ class="ae_meta mt-2 flex flex-col items-center justify-center gap-1 text-sm text-gray-500 sm:flex-row" + class:hidden={!$ae_loc.administrator_access}> + class:hidden={!idaa_archive_content_obj.archive_content_type}> Type: {idaa_archive_content_obj.archive_content_type} @@ -391,8 +375,7 @@ + class:hidden={!idaa_archive_content_obj.updated_on}> Updated on: {ae_util.iso_datetime_formatter( idaa_archive_content_obj.updated_on, 'datetime_12_long' diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_edit.svelte b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_edit.svelte index 3744dfaa..34f1226f 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_edit.svelte +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_edit.svelte @@ -1,287 +1,284 @@
+ bind:clientHeight={$ae_loc.iframe_height_modal_body}> {#await update_archive_obj_promise}
@@ -300,8 +297,7 @@
+ class="ae_section archive__general space-y-2 rounded border border-gray-200 p-2">
@@ -330,14 +325,12 @@ + placeholder="Your archive description here..." />
+ class="ae_section archive__original space-y-2 rounded border border-gray-200 p-2">

Original

@@ -382,10 +373,9 @@ ? $idaa_slct.archive_obj.original_timezone : $ae_loc.current_timezone} class="select w-56" - title="Select the original timezone" - > + title="Select the original timezone"> - {#each ($lq__lu_time_zone ?? []) as lu_timezone (lu_timezone.name)} + {#each $lq__lu_time_zone ?? [] as lu_timezone (lu_timezone.name)} @@ -398,8 +388,7 @@ value={$idaa_slct.archive_obj.original_timezone ? $idaa_slct.archive_obj.original_timezone : $ae_loc.current_timezone} - class="input w-56" - /> + class="input w-56" /> {/if}
@@ -440,8 +429,7 @@ ? $idaa_slct.archive_obj.original_location : ''} placeholder="Location" - class="input w-full" - /> + class="input w-full" />
@@ -511,208 +497,197 @@ $idaa_slct.archive_obj.cfg_json, null, 2 - )} + )} {/if} {#if $ae_loc.trusted_access} -
+
-
- +
-
- Hide -
- - -
-
- - -
-
- -
- Priority -
- - -
-
- - -
-
-
- - - - - - - - {#if $ae_loc.administrator_access} + class="flex w-full flex-col flex-wrap items-center justify-center gap-2 md:flex-row md:justify-stretch"> + class="flex grow flex-row flex-wrap items-center justify-evenly gap-1">
+ class="form-check flex flex-row items-center justify-center gap-1"> Enable + class="legend form-check-label text-sm font-semibold" + >Hide
- + bind:group={$idaa_slct.archive_obj.hide} + class="radio form-check-input" /> +
+ +
+
+ +
+ Priority +
+ + +
+
+ - + class="radio form-check-input" /> +
- {:else} - - {/if} - - {#if $ae_loc.trusted_access} - - {/if} + class=" + col-sm-1 + flex grow flex-row flex-wrap items-center justify-evenly + gap-1 + "> + -
- {$lq__archive_obj?.updated_on - ? `DB Updated on: ${$lq__archive_obj?.updated_on}` - : ''} - {$idaa_slct.archive_obj?.updated_on - ? `SLCT Updated on: ${$idaa_slct.archive_obj?.updated_on}` - : ''} -
+ + + + {#if $ae_loc.administrator_access} + +
+ Enable +
+ + +
+
+ + +
+
+
+ {:else} + + {/if} + + + {#if $ae_loc.trusted_access} + + {/if} + +
+ {$lq__archive_obj?.updated_on + ? `DB Updated on: ${$lq__archive_obj?.updated_on}` + : ''} + {$idaa_slct.archive_obj?.updated_on + ? `SLCT Updated on: ${$idaa_slct.archive_obj?.updated_on}` + : ''} +
{/if}
+ class="ae_section ae_options flex flex-row items-center justify-center gap-1"> @@ -738,8 +713,7 @@ preset-filled-warning-200-800 hover:preset-filled-error-200-800 transition " - title="Disable this archive content" - > + title="Disable this archive content"> Delete diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_view.svelte b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_view.svelte index e97570cf..1e0285a4 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_view.svelte +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__archive_obj_id_view.svelte @@ -1,50 +1,49 @@
+ class="svelte_component ae_section ae_view archive_obj view__archive_obj m-2 flex flex-col flex-wrap items-center justify-center gap-2 rounded-lg bg-white" + bind:clientHeight={$ae_loc.iframe_height_modal_body}> diff --git a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__modal_media_player.svelte b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__modal_media_player.svelte index 6917410e..2d86bc29 100644 --- a/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__modal_media_player.svelte +++ b/src/routes/idaa/(idaa)/archives/[archive_id]/ae_idaa_comp__modal_media_player.svelte @@ -1,38 +1,38 @@ @@ -46,10 +46,9 @@ outsideclose={true} placement="top-center" size="xl" - 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" -> + class="top-center relative mx-auto flex w-full flex-col divide-y divide-gray-200 rounded-lg border-gray-200 bg-white text-gray-800 shadow-md dark:divide-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-200"> {#snippet header()} -
+

{idaa_archive_obj.original_location} + >{idaa_archive_obj.original_location}

{/if}
{#if idaa_archive_obj.description}
{@html idaa_archive_obj.description}
{/if} + class="archive__description word-break novi_text_wrap max-w-(--breakpoint-md) rounded-lg bg-white p-2 text-sm font-normal text-wrap whitespace-pre-wrap shadow-md">{@html idaa_archive_obj.description}{/if}
diff --git a/src/routes/idaa/(idaa)/bb/+layout.svelte b/src/routes/idaa/(idaa)/bb/+layout.svelte index 34163d99..35c190bb 100644 --- a/src/routes/idaa/(idaa)/bb/+layout.svelte +++ b/src/routes/idaa/(idaa)/bb/+layout.svelte @@ -1,114 +1,114 @@ {@render children?.()} diff --git a/src/routes/idaa/(idaa)/bb/+page.svelte b/src/routes/idaa/(idaa)/bb/+page.svelte index f1bef1f1..004065b4 100644 --- a/src/routes/idaa/(idaa)/bb/+page.svelte +++ b/src/routes/idaa/(idaa)/bb/+page.svelte @@ -1,241 +1,247 @@ diff --git a/src/routes/idaa/(idaa)/bb/+page.ts b/src/routes/idaa/(idaa)/bb/+page.ts index 8b038b52..9649efda 100644 --- a/src/routes/idaa/(idaa)/bb/+page.ts +++ b/src/routes/idaa/(idaa)/bb/+page.ts @@ -17,7 +17,9 @@ export const load = (async ({ params, parent }) => { let ae_acct = data[account_id]; if (!ae_acct) { - console.warn(`ae IDAA Bulletin Board +page.ts: Account ${account_id} not found in parent data. Initializing ghost acct.`); + console.warn( + `ae IDAA Bulletin Board +page.ts: Account ${account_id} not found in parent data. Initializing ghost acct.` + ); ae_acct = { api: data.ae_api || {}, slct: { @@ -27,24 +29,28 @@ export const load = (async ({ params, parent }) => { } if (browser) { - const load_post_obj_li = posts_func.load_ae_obj_li__post({ - api_cfg: ae_acct.api, - for_obj_type: 'account', - for_obj_id: account_id, - inc_comment_li: false, - enabled: 'enabled', - hidden: 'not_hidden', - limit: 19, - order_by_li: { updated_on: 'DESC', created_on: 'DESC' }, - try_cache: true, - log_lvl: log_lvl - }).then(posts => { - // REVIEW AGAIN: The backend now supports filtering out archived posts based on the 'archive_on' field. - // Workaround: V3 Search does not permit 'archive_on' field yet. - // Filter locally for posts that are not archived yet. - const now = new Date(); - return (posts || []).filter((p: any) => !p.archive_on || new Date(p.archive_on) > now); - }); + const load_post_obj_li = posts_func + .load_ae_obj_li__post({ + api_cfg: ae_acct.api, + for_obj_type: 'account', + for_obj_id: account_id, + inc_comment_li: false, + enabled: 'enabled', + hidden: 'not_hidden', + limit: 19, + order_by_li: { updated_on: 'DESC', created_on: 'DESC' }, + try_cache: true, + log_lvl: log_lvl + }) + .then((posts) => { + // REVIEW AGAIN: The backend now supports filtering out archived posts based on the 'archive_on' field. + // Workaround: V3 Search does not permit 'archive_on' field yet. + // Filter locally for posts that are not archived yet. + const now = new Date(); + return (posts || []).filter( + (p: any) => !p.archive_on || new Date(p.archive_on) > now + ); + }); if (log_lvl) { console.log(`load_post_obj_li = `, load_post_obj_li); } diff --git a/src/routes/idaa/(idaa)/bb/[post_id]/+page.svelte b/src/routes/idaa/(idaa)/bb/[post_id]/+page.svelte index f0c4a4bf..f185064d 100644 --- a/src/routes/idaa/(idaa)/bb/[post_id]/+page.svelte +++ b/src/routes/idaa/(idaa)/bb/[post_id]/+page.svelte @@ -1,122 +1,124 @@ @@ -134,17 +136,17 @@ -
+

+ flex max-w-full + min-w-1/2 flex-row items-center justify-center gap-2 + text-2xl + font-bold + "> {$lq__post_obj?.name ? $lq__post_obj?.name : 'BB Post'} @@ -152,28 +154,26 @@
+ flex max-w-full min-w-1/4 flex-row items-center + justify-evenly + gap-2 + "> - + {#if $lq__post_obj?.topic_name} {$lq__post_obj?.topic_name} + > + {$lq__post_obj?.topic_name} {/if} {#if $ae_loc.trusted_access && $lq__post_obj?.hide} Hidden + > Hidden {/if} {#if $ae_loc.administrator_access && !$lq__post_obj?.enable} Not enabled + > Not enabled {/if}
@@ -181,28 +181,28 @@
+ border-b-surface-300-700 mb-2 flex w-full flex-row + items-center + justify-evenly gap-2 border-b + p-1 pb-2 + "> - Back to Posts List + "> + Back to + Posts List {#if $idaa_sess.bb.edit__post_obj} - @@ -257,7 +260,12 @@ {#if $idaa_sess.bb.edit__post_obj || $idaa_loc.bb.edit__post_obj} - + {:else} - + {/if} diff --git a/src/routes/idaa/(idaa)/bb/[post_id]/+page.ts b/src/routes/idaa/(idaa)/bb/[post_id]/+page.ts index ae388c5b..5c061d45 100644 --- a/src/routes/idaa/(idaa)/bb/[post_id]/+page.ts +++ b/src/routes/idaa/(idaa)/bb/[post_id]/+page.ts @@ -21,7 +21,10 @@ export const load = (async ({ params, parent }) => { if (browser) { if (log_lvl) { - console.log(`ae_idaa_posts posts [post_id] +page.ts: post_id = `, post_id); + console.log( + `ae_idaa_posts posts [post_id] +page.ts: post_id = `, + post_id + ); } // NOTE: Fire in background — do NOT await. Newly created posts are already in Dexie // (saved by create_ae_obj__post), so the liveQuery renders immediately. For direct @@ -36,7 +39,9 @@ export const load = (async ({ params, parent }) => { }) .then((results) => { if (!results) { - console.warn(`ae IDAA BB [post_id] +page.ts: Post ${post_id} not found via API or Cache.`); + console.warn( + `ae IDAA BB [post_id] +page.ts: Post ${post_id} not found via API or Cache.` + ); } }); } diff --git a/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_comment_obj_id_edit.svelte b/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_comment_obj_id_edit.svelte index c739017a..9f7abd04 100644 --- a/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_comment_obj_id_edit.svelte +++ b/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_comment_obj_id_edit.svelte @@ -1,315 +1,342 @@
+ bind:clientHeight={$ae_loc.iframe_height_modal_body}> {#await prom_api__post_comment_obj} -
Saving...
+
+ Saving... +
{:then} {#if prom_api__post_comment_obj} @@ -450,7 +490,8 @@ Copy and paste link: ${
- @@ -474,27 +515,25 @@ Copy and paste link: ${
+ class="ae_section post_comment__general_information space-y-1 rounded border border-gray-200 p-1">

Commenter's Information

Comment as Anonymous + >Comment as Anonymous
${ name="anonymous" value={false} bind:group={post_comment_form.anonymous} - class="radio" - /> + class="radio" /> + >No, include my name and email address
${ name="anonymous" value={true} bind:group={post_comment_form.anonymous} - class="radio" - /> + class="radio" /> + >Yes, the post will be listed as + Anonymous
- {#if $ae_loc.trusted_access} -
+
-
- +
-
- Hide -
- - -
-
- - -
-
- -
- Priority -
- - -
-
- - -
-
-
- - - - - - - - {#if $ae_loc.administrator_access} + class="flex w-full flex-col flex-wrap items-center justify-center gap-2 md:flex-row md:justify-stretch"> -
- Enable + class="form-check flex grow flex-row flex-wrap items-center justify-evenly gap-2"> +
+ Hide
- + bind:group={post_comment_form.hide} + class="radio form-check-input" /> +
- + bind:group={post_comment_form.hide} + class="radio form-check-input" /> + +
+
+ +
+ Priority +
+ + +
+
+ +
- {/if} - + + + + + + + + {#if $ae_loc.administrator_access} + +
+ Enable +
+ + +
+
+ + +
+
+
+ {/if} +
@@ -769,10 +818,9 @@ Copy and paste link:
${
+ d-flex align-items-center justify-content-between flex w-full flex-row + items-center justify-between gap-1 + ">
{#if $idaa_slct.post_comment_id} @@ -783,8 +831,7 @@ Copy and paste link: ${ novi_btn btn btn-md preset-tonal-primary preset-outlined-primary-800-200 hover:preset-filled-primary-200-800 transition - " - > + "> {#await prom_api__post_comment_obj} Saving {:then} @@ -796,7 +843,11 @@ Copy and paste link: ${ type="submit" disabled={disable_submit_btn} onclick={() => { - if (!confirm('Are you sure you want to add this comment?')) { + if ( + !confirm( + 'Are you sure you want to add this comment?' + ) + ) { return false; } // handle_save_post_comment_obj({post_id: $idaa_slct.post_id, method: 'create'}); @@ -805,8 +856,7 @@ Copy and paste link: ${ novi_btn btn btn-md preset-tonal-warning preset-outlined-warning-800-200 hover:preset-filled-warning-200-800 transition - " - > + "> {#await prom_api__post_comment_obj} Saving {:then} @@ -817,10 +867,13 @@ Copy and paste link: ${ {#if $idaa_slct.post_comment_id} {#if $ae_loc.administrator_access} - {:else if $ae_loc.trusted_access} - {:else} - {/if} @@ -887,7 +945,8 @@ Copy and paste link: ${
- diff --git a/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_edit.svelte b/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_edit.svelte index 5747cacf..323f528b 100644 --- a/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_edit.svelte +++ b/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_edit.svelte @@ -1,344 +1,360 @@
+ bind:clientHeight={$ae_loc.iframe_height_modal_body}> {#await prom_api__post_obj} -
Saving...
+
+ Saving... +
{:then} {#if prom_api__post_obj} @@ -437,10 +465,15 @@ Copy and paste link:
${lin
- @@ -467,13 +499,12 @@ Copy and paste link: ${lin
+ class="ae_section post__general_information space-y-2 rounded border border-gray-200 p-2"> ${lin + placeholder="Your post content here..." /> -
- -
-
+ {#if $idaa_slct.post_obj?.linked_li_json && $idaa_slct.post_obj.linked_li_json.length} -
+
- Linked files: + Linked files: {#each $idaa_slct.post_obj.linked_li_json as linked_obj, index (linked_obj.hosted_file_id ?? index)} - + {#if $ae_loc.authenticated_access} - {@const file_id = linked_obj?.hosted_file_id || linked_obj?.id || linked_obj?.hosted_file_id} + {@const file_id = + linked_obj?.hosted_file_id || + linked_obj?.id || + linked_obj?.hosted_file_id} {#if file_id} - {@const ext = (linked_obj.extension || linked_obj.file_extension || ae_util.guess_file_extension(linked_obj.filename) || '').toLowerCase()} + {@const ext = ( + linked_obj.extension || + linked_obj.file_extension || + ae_util.guess_file_extension( + linked_obj.filename + ) || + '' + ).toLowerCase()} {#if ['png', 'jpg', 'jpeg', 'gif', 'webp', 'svg'].includes(ext)}
{linked_obj.filename} + class="border-surface-500/20 h-auto max-w-32 rounded border object-cover shadow-sm" />
{/if} -
+
+ max_filename={30} /> - @@ -704,20 +795,23 @@ Copy and paste link: ${lin
+ class="preset-tonal-surface hover:preset-filled-surface-100-900 flex flex-row gap-2"> + class="radio form-check-input" /> + "Anonymous"
-
- ${lin name="email" value={$idaa_slct.post_obj?.email ? $idaa_slct.post_obj?.email - : ($idaa_loc.novi_email ?? '')} - /> + : ($idaa_loc.novi_email ?? '')} /> {/if}
- + Notify me of comments?
+ class="preset-tonal-surface hover:preset-filled-surface-100-900 flex flex-row gap-2"> - + class="radio form-check-input" /> +
+ class="preset-tonal-surface hover:preset-filled-surface-100-900 flex flex-row gap-2"> - + class="radio form-check-input" /> +
@@ -898,161 +998,166 @@ Copy and paste link: ${lin {#if $ae_loc.trusted_access} -
+
-
- - -
- Hide -
- - -
-
- - -
-
- -
- Priority -
- - -
-
- - -
-
-
- +
- - - - - - {#if $ae_loc.administrator_access} + class="flex w-full flex-col flex-wrap items-center justify-center gap-2 md:flex-row md:justify-stretch"> -
- Enable + class="flex grow flex-row flex-wrap items-center justify-evenly gap-2"> +
+ Hide
- + bind:group={$idaa_slct.post_obj.hide} + class="radio form-check-input" /> +
- + bind:group={$idaa_slct.post_obj.hide} + class="radio form-check-input" /> + +
+
+ +
+ Priority +
+ + +
+
+ +
- {:else} - - {/if} - - {#if $ae_loc.trusted_access} - - {/if} + + + + + + + {#if $ae_loc.administrator_access} + +
+ Enable +
+ + +
+
+ + +
+
+
+ {:else} + + {/if} + + + {#if $ae_loc.trusted_access} + + {/if}
@@ -1061,10 +1166,9 @@ Copy and paste link:
${lin
+ d-flex align-items-center justify-content-between flex w-full flex-row + items-center justify-between gap-1 + ">
{#if $idaa_slct.post_id} @@ -1075,8 +1179,7 @@ Copy and paste link: ${lin novi_btn btn btn-md preset-tonal-primary preset-outlined-primary-800-200 hover:preset-filled-primary-200-800 transition - " - > + "> {#await prom_api__post_obj} Saving {:then} @@ -1088,7 +1191,11 @@ Copy and paste link: ${lin type="submit" disabled={disable_submit_btn} onclick={() => { - if (!confirm('Are you sure you want to create this post?')) { + if ( + !confirm( + 'Are you sure you want to create this post?' + ) + ) { return false; } // handle_save_post_obj({post_id: $idaa_slct.post_id, method: 'create'}); @@ -1098,8 +1205,7 @@ Copy and paste link: ${lin btn preset-tonal-warning hover:preset-filled-warning-200-800 transition - " - > + "> {#await prom_api__post_obj} Saving {:then} @@ -1110,9 +1216,14 @@ Copy and paste link: ${lin {#if $idaa_slct.post_id} {#if $ae_loc.administrator_access} - {:else if $ae_loc.trusted_access} - {:else} - {/if} @@ -1176,7 +1294,8 @@ Copy and paste link: ${lin
- diff --git a/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_view.svelte b/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_view.svelte index f23c7c36..7ffed665 100644 --- a/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_view.svelte +++ b/src/routes/idaa/(idaa)/bb/ae_idaa_comp__post_obj_id_view.svelte @@ -1,49 +1,56 @@
- - + class="svelte_component ae_section ae_view post_obj view__post_obj space-y-2">
+ class="post__content reset_css rounded-lg bg-white p-2 text-sm font-normal text-wrap shadow-md"> {@html $lq__post_obj?.content}
{#if $lq__post_obj?.linked_li_json && $lq__post_obj?.linked_li_json.length} -
+
- Linked files: + Linked files: {#each $lq__post_obj.linked_li_json as linked_obj, index (linked_obj.hosted_file_id ?? index)} - {#if $ae_loc.authenticated_access} - {@const file_id = linked_obj?.hosted_file_id || linked_obj?.id} + {@const file_id = + linked_obj?.hosted_file_id || linked_obj?.id} {#if file_id} - {@const ext = (linked_obj.extension || linked_obj.file_extension || ae_util.guess_file_extension(linked_obj.filename) || '').toLowerCase()} + {@const ext = ( + linked_obj.extension || + linked_obj.file_extension || + ae_util.guess_file_extension( + linked_obj.filename + ) || + '' + ).toLowerCase()} {#if ['png', 'jpg', 'jpeg', 'gif', 'webp', 'svg'].includes(ext)}
{linked_obj.filename} + class="h-fit w-fit min-w-96 rounded-lg object-cover shadow-md" />
{:else} + max_filename={30} /> {/if} {/if} {/if} @@ -99,8 +112,7 @@