Now with prepend or append to Entry content option.
This commit is contained in:
@@ -7,6 +7,7 @@ let { data, children } = $props();
|
||||
import { goto } from '$app/navigation';
|
||||
import {
|
||||
ArrowDown01, ArrowDown10, ArrowDownUp,
|
||||
BetweenVerticalEnd, BetweenVerticalStart,
|
||||
BookHeart, BookImage, Bookmark, BookOpenText, BriefcaseBusiness,
|
||||
Check, Copy,
|
||||
Expand, Eye, EyeOff,
|
||||
@@ -615,6 +616,51 @@ async function handle_update_journal() {
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<!-- Toggles for the of how to add new content to an existing Journal Entry. append, prepend, and defaults to append -->
|
||||
<div class="flex flex-row flex-wrap gap-1 items-center justify-start">
|
||||
|
||||
<span class="text-sm text-gray-500 hidden sm:inline">
|
||||
Journal Entry Add Content:
|
||||
</span>
|
||||
|
||||
<span class="flex flex-row flex-wrap gap-1 items-center justify-center">
|
||||
<button
|
||||
type="button"
|
||||
onclick={() => {
|
||||
if ($journals_slct.tmp_journal_obj.cfg_json.entry_add_text == 'append') {
|
||||
$journals_slct.tmp_journal_obj.cfg_json.entry_add_text = 'prepend';
|
||||
} else {
|
||||
$journals_slct.tmp_journal_obj.cfg_json.entry_add_text = 'append';
|
||||
}
|
||||
}}
|
||||
class="btn btn-sm variant-ghost-secondary hover:variant-filled-secondary transition *:hover:inline"
|
||||
title="Toggle visibility of Markdown copy button(s) on Journal Entry view page"
|
||||
>
|
||||
{#if $journals_slct.tmp_journal_obj.cfg_json.entry_add_text == 'append'}
|
||||
<!-- <EyeOff strokeWidth="1" color="red" /> -->
|
||||
<ToggleLeft strokeWidth="1" color="red" class="mx-1" />
|
||||
|
||||
<!-- <Plus strokeWidth="2.5" color="green" /> -->
|
||||
<BetweenVerticalEnd strokeWidth="2.5" color="green" />
|
||||
<span class="hidden">
|
||||
Append
|
||||
</span>
|
||||
{:else}
|
||||
<!-- <Eye strokeWidth="2.5" color="green" /> -->
|
||||
<ToggleRight strokeWidth="2.5" color="green" class="mx-1" />
|
||||
<!-- <Minus strokeWidth="2.5" color="green" /> -->
|
||||
<BetweenVerticalStart strokeWidth="2.5" color="green" />
|
||||
<span class="hidden">
|
||||
Prepend
|
||||
</span>
|
||||
{/if}
|
||||
<span class="hidden">
|
||||
Add Content to Journal Entry
|
||||
</span>
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<!-- Select color scheme for the journal entries -->
|
||||
<!-- Should select from the common Tailwind CSS options. Examples: slate, blue, gray, green, orange, red, yellow, etc. -->
|
||||
<!-- Saves to cfg_json.color_scheme -->
|
||||
|
||||
Reference in New Issue
Block a user