plugin wip

This commit is contained in:
Joey Kimsey
2024-12-17 22:45:47 -05:00
parent 0955fb4175
commit e537771708
42 changed files with 1043 additions and 693 deletions

View File

@ -1,51 +1,56 @@
<form action="" method="post" class="container py-4">
<h2 class="text-center mb-4">Add Bookmark</h2>
<fieldset>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Title</label>
<div class="col-lg-3">
<input type="text" class="form-control" name="title" id="title" required>
</div>
</div>
<div class="mb-4 mt-4">
<div class="offset-md-1 col-10 py-3 context-main-bg">
<legend class="text-center">Add Bookmark</legend>
<hr>
<form method="post" class="container py-4">
<fieldset>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Title</label>
<div class="col-lg-3">
<input type="text" class="form-control" name="title" id="title" required>
</div>
</div>
<div class="mb-3 row">
<label for="url" class="col-lg-5 col-form-label text-end">URL</label>
<div class="col-lg-3">
<input type="text" class="form-control" name="url" id="url" required>
</div>
</div>
<div class="mb-3 row">
<label for="url" class="col-lg-5 col-form-label text-end">URL</label>
<div class="col-lg-3">
<input type="text" class="form-control" name="url" id="url" required>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Description:</label>
<div class="col-lg-3">
<textarea class="form-control" name="description" maxlength="2000" rows="10" cols="50" id="description"></textarea>
</div>
</div>
{folderSelect}
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Privacy</label>
<div class="col-lg-3">
<select id="privacy" name="privacy" class="form-select">
<option value="private">Private</option>
<option value="public">Public</option>
</select>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Color</label>
<div class="col-lg-3" id="colorContainer">
{colorSelect}
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Description:</label>
<div class="col-lg-3">
<textarea class="form-control" name="description" maxlength="2000" rows="10" cols="50" id="description"></textarea>
</div>
</div>
{folderSelect}
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Privacy</label>
<div class="col-lg-3">
<select id="privacy" name="privacy" class="form-select">
<option value="private">Private</option>
<option value="public">Public</option>
</select>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Color</label>
<div class="col-lg-3" id="colorContainer">
{colorSelect}
</div>
</div>
<!-- Hidden Token -->
<input type="hidden" name="token" value="{TOKEN}">
<!-- Hidden Token -->
<input type="hidden" name="token" value="{TOKEN}">
<!-- Submit Button -->
<div class="text-center">
<button type="submit" name="submit" value="submit" class="btn btn-primary btn-lg">Create</button>
</div>
</fieldset>
</form>
<!-- Submit Button -->
<div class="text-center">
<button type="submit" name="submit" value="submit" class="btn btn-primary btn-lg">Create</button>
</div>
</fieldset>
</form>
</div>
</div>

View File

@ -2,11 +2,11 @@
<div class="col-xlg-6 col-lg-6 col-md-6 col-sm-6 bookmark-card">
<div class="card m-3 accordion">
<div class="accordion-item">
<div class="card-header accordion-header bg-{color} context-main" data-bs-target="#Collapse{ID}" data-bs-toggle="collapse" aria-expanded="true" aria-controls="Collapse{ID}">
{title}
<div class="card-header accordion-header text-center bg-{color} context-main" data-bs-target="#Collapse{ID}" data-bs-toggle="collapse" aria-expanded="true" aria-controls="Collapse{ID}">
<span class="h4 text-center">{title}</span>
</div>
<div id="Collapse{ID}" class="accordion-collapse collapse show" style="width:100%; position: relative;">
<div class="card-body accordion-body context-other-bg p-2">
<div id="Collapse{ID}" class="accordion-collapse collapse w-100 position-relative show">
<div class="card-body accordion-body p-2 context-second-bg">
<ul class="list-group">
{bookmarkListRows}
</ul>
@ -14,8 +14,8 @@
<div class="card-footer d-flex justify-content-center align-items-center context-main-bg">
<a href="{ROOT_URL}bookmarks/createBookmark/{ID}" class="btn btn-sm btn-success"><i class="fa fa-fw fa-plus"></i></a></td>
<span class="ms-auto">
<a href="{ROOT_URL}bookmarks/bookmarks/{ID}" class="btn btn-sm btn-primary"><i class="fa fa-fw fa-list"></i></a>
<a href="{ROOT_URL}bookmarks/folders/{ID}" class="btn btn-sm btn-primary"><i class="fa fa-fw fa-info-circle"></i></a></td>
<a href="{ROOT_URL}bookmarks/bookmarks/{ID}" class="btn btn-sm btn-outline-primary"><i class="fa fa-fw fa-list"></i></a>
<a href="{ROOT_URL}bookmarks/folders/{ID}" class="btn btn-sm btn-outline-primary"><i class="fa fa-fw fa-info-circle"></i></a></td>
<a href="{ROOT_URL}bookmarks/editFolder/{ID}" class="btn btn-sm btn-warning"><i class="fa fa-fw fa-pencil"></i></a></td>
<a href="{ROOT_URL}bookmarks/deleteFolder/{ID}" class="btn btn-sm btn-danger"><i class="fa fa-fw fa-trash"></i></a></td>
</span>
@ -26,7 +26,7 @@
</div>
{/LOOP}
{ALT}
<div class="col-xlg-6 col-lg-6 col-md-6 col-sm-6">
<p>no folders</p>
<div class="col-12 text-center h4">
<p>No folders found.</p>
</div>
{/ALT}

View File

@ -1,18 +1,19 @@
{LOOP}
<li class="list-group-item mb-1 context-main-b bg-{color}">
<li class="list-group-item context-main-b bg-{color}">
<a href="{ROOT_URL}bookmarks/bookmark/{ID}" class="context-main">{iconHtml}</a>
<a href="{url}"> {title}</a>
<span class="float-end">
{hideBtn}
{archiveBtn}
{publish}
<a href="{ROOT_URL}bookmarks/editBookmark/{ID}" class="btn btn-sm btn-warning"><i class="fa fa-fw fa-pencil"></i></a>
<a href="{ROOT_URL}bookmarks/deleteBookmark/{ID}" class="btn btn-sm btn-danger"><i class="fa fa-fw fa-trash"></i></a>
</span>
</li>
{/LOOP}
{ALT}
<li class="list-group-item py-1">
<li class="list-group-item context-main context-main-bg">
<p class="list-group text-center">No Bookmarks</p>
</li>
{/ALT}

View File

@ -0,0 +1,27 @@
{LOOP}
<div class="bookmark-card">
<div class="card m-3 accordion">
<div class="accordion-item">
<div class="card-header accordion-header bg-{color} context-main">
<div class="d-flex justify-content-between align-items-center w-100" data-bs-target="#Collapse{ID}" data-bs-toggle="collapse" aria-expanded="true" aria-controls="Collapse{ID}">
<div class="text-center h4">{title}</div>
</div>
</div>
<div id="Collapse{ID}" class="accordion-collapse collapse w-100 position-relative show">
<div class="card-body accordion-body p-2 context-second-bg">
<ul class="list-group">
{bookmarkListRows}
</ul>
</div>
</div>
</div>
</div>
</div>
{/LOOP}
{ALT}
<div class="context-other-bg">
<p class="context-other-bg">no Folders</p>
</div>
{/ALT}

View File

@ -0,0 +1,30 @@
{LOOP}
<li class="list-group-item context-main-bg bg-{color}">
<a href="{ROOT_URL}bookmarks/bookmark/{ID}" class="context-main">{iconHtml}</a>
<a href="{url}"> {title}</a>
<span class="float-end">
<a class="btn btn-sm btn-primary" data-bs-toggle="modal" data-bs-target="#linkShare{ID}">
<i class="fa fa-fw fa-share"></i>
</a>
<div class="modal fade" id="linkShare{ID}" tabindex="-1" style="display: none;" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header">
<h1 class="modal-title fs-5">Share Url</h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<input type="text" value="{SITE_URL}shared/link/{uuid}" name="input" class="w-100 form-control" id="shareLinkUrlInput{ID}">
<button class="btn btn-secondary mt-2" onclick="copyElementText('shareLinkUrlInput{ID}')">Copy</button>
</div>
</div>
</div>
</div>
</span>
</li>
{/LOOP}
{ALT}
<li class="list-group-item context-main context-main-bg">
<p class="list-group text-center">No Bookmarks</p>
</li>
{/ALT}

View File

@ -2,35 +2,45 @@
<div class="col-xlg-6 col-lg-6 col-md-6 col-sm-6 bookmark-card">
<div class="card m-3 accordion">
<div class="accordion-item">
<div class="card-header accordion-header bg-{color} context-main" data-bs-target="#Collapse{ID}" data-bs-toggle="collapse" aria-expanded="true" aria-controls="Collapse{ID}">
{title}{privacyBadge}
<a class="btn btn-sm btn-primary float-end" data-bs-toggle="modal" data-bs-target="#linkShare{ID}">
<i class="fa fa-fw fa-share"></i>
</a>
<div class="modal fade" id="linkShare{ID}" tabindex="-1" style="display: none;" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header">
<h1 class="modal-title fs-5" id="exampleModalCenteredScrollableTitle">Modal title</h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<input type="text" value="{SITE_URL}shared/folder/{uuid}" name="input">
</div>
<div class="card-header accordion-header bg-{color} context-main">
<div class="d-flex justify-content-between align-items-center w-100">
<span data-bs-target="#Collapse{ID}" data-bs-toggle="collapse" aria-expanded="true" aria-controls="Collapse{ID}">
<span class="text-center px-5">{privacyBadge}</span>
<span class="h4 text-center px-5">{title}</span>
</span>
<a class="btn btn-sm btn-primary btn-rounded" data-bs-toggle="modal" data-bs-target="#linkShare{ID}">
<i class="fa fa-fw fa-share"></i>
</a>
</div>
</div>
<div class="modal fade context-main" id="linkShare{ID}" tabindex="-1" style="display: none;" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header context-main-bg">
<h1 class="modal-title fs-5">Share Url</h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body context-second-bg">
<p>This link can be shared with anyone and will show display info as long as it is set to public privacy.</p>
<input type="text" value="{SITE_URL}shared/folder/{uuid}" name="input" class="w-100 form-control" id="shareFolderUrlInput{ID}">
<button class="btn btn-secondary mt-2" onclick="copyElementText('shareFolderUrlInput{ID}')">Copy</button>
</div>
</div>
</div>
</div>
<div id="Collapse{ID}" class="accordion-collapse collapse show" style="width:100%; position: relative;">
<div class="card-body accordion-body context-other-bg p-2">
<div id="Collapse{ID}" class="accordion-collapse collapse w-100 position-relative show">
<div class="card-body accordion-body p-2 context-second-bg">
<ul class="list-group">
{bookmarkListRows}
</ul>
</div>
<div class="card-footer d-flex justify-content-center align-items-center context-main-bg">
<span class="ms-auto">
<a href="{ROOT_URL}bookmarks/bookmarks/{ID}" class="btn btn-sm btn-primary"><i class="fa fa-fw fa-list"></i></a>
<a href="{ROOT_URL}bookmarks/folders/{ID}" class="btn btn-sm btn-primary"><i class="fa fa-fw fa-info-circle"></i></a></td>
<a href="{ROOT_URL}bookmarks/bookmarks/{ID}" class="btn btn-sm btn-outline-primary "><i class="fa fa-fw fa-list"></i></a>
<a href="{ROOT_URL}bookmarks/folders/{ID}" class="btn btn-sm btn-outline-primary"><i class="fa fa-fw fa-info-circle"></i></a></td>
</span>
</div>
</div>
@ -39,7 +49,7 @@
</div>
{/LOOP}
{ALT}
<div class="col-xlg-6 col-lg-6 col-md-6 col-sm-6">
<p>no folders</p>
<div class="context-other-bg">
<p class="context-other-bg">no Folders</p>
</div>
{/ALT}

View File

@ -1,9 +1,9 @@
{LOOP}
<li class="list-group-item mb-1 context-main-b bg-{color}">
<li class="list-group-item context-main-bg bg-{color}">
<a href="{ROOT_URL}bookmarks/bookmark/{ID}" class="context-main">{iconHtml}</a>
<a href="{url}"> {title}</a>{privacyBadge}
<span class="float-end">
<a href="{ROOT_URL}bookmarks/retract/{ID}" class="btn btn-sm btn-success"><i class="fa fa-fw fa-eye"></i></a>
{publish}
<a class="btn btn-sm btn-primary" data-bs-toggle="modal" data-bs-target="#linkShare{ID}">
<i class="fa fa-fw fa-share"></i>
</a>
@ -11,11 +11,12 @@
<div class="modal-dialog modal-dialog-centered modal-dialog-scrollable">
<div class="modal-content">
<div class="modal-header">
<h1 class="modal-title fs-5" id="exampleModalCenteredScrollableTitle">Modal title</h1>
<h1 class="modal-title fs-5">Share Url</h1>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div>
<div class="modal-body">
<input type="text" value="{SITE_URL}shared/link/{uuid}" name="input">
<input type="text" value="{SITE_URL}shared/link/{uuid}" name="input" class="w-100 form-control" id="shareLinkUrlInput{ID}">
<button class="btn btn-secondary mt-2" onclick="copyElementText('shareLinkUrlInput{ID}')">Copy</button>
</div>
</div>
</div>
@ -24,7 +25,7 @@
</li>
{/LOOP}
{ALT}
<li class="list-group-item py-1">
<li class="list-group-item context-main context-main-bg">
<p class="list-group text-center">No Bookmarks</p>
</li>
{/ALT}

View File

@ -1,15 +1,15 @@
<div class="row mt-4">
<div class="offset-md-1 col-5 mr-2 py-3 context-main-bg">
<legend class="text-center">Unsorted Bookmarks</legend>
{bookmarksList}
</div>
<div class="col-5 py-3 ml-2 context-main-bg">
<legend class="text-center">Folders List</legend>
{foldersList}
</div>
<div class="row mt-4 g-1">
<div class="offset-md-1 col-5 mr-2 py-3 context-main-bg">
<legend class="text-center">Unsorted Bookmarks</legend>
{bookmarksList}
</div>
<div class="col-5 py-3 ml-2 context-main-bg">
<legend class="text-center">Folders List</legend>
{foldersList}
</div>
</div>
<div class="row mb-4 mt-4">
<div class="mb-4 mt-4">
<div class="offset-md-1 col-10 py-3 context-main-bg">
<legend class="text-center">Bookmarks</legend>
<hr>

View File

@ -1,41 +1,48 @@
<form action="" method="post" class="container py-4">
<h2 class="text-center mb-4">Create Folder</h2>
<fieldset>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Title</label>
<div class="col-lg-3">
<input type="text" class="form-control" name="title" id="title" required>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Description:</label>
<div class="col-lg-3">
<textarea class="form-control" name="description" maxlength="2000" rows="10" cols="50" id="description"></textarea>
</div>
</div>
{folderSelect}
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Privacy</label>
<div class="col-lg-3">
<select id="privacy" name="privacy" class="form-select">
<option value="private">Private</option>
<option value="public">Public</option>
</select>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Color</label>
<div class="col-lg-3">
{colorSelect}
</div>
</div>
<!-- Hidden Token -->
<input type="hidden" name="token" value="{TOKEN}">
<div class="mb-4 mt-4">
<div class="offset-md-1 col-10 py-3 context-main-bg">
<legend class="text-center">Add Folder</legend>
<hr>
<!-- Submit Button -->
<div class="text-center">
<button type="submit" name="submit" value="submit" class="btn btn-primary btn-lg">Create</button>
</div>
</fieldset>
</form>
<form action="" method="post" class="container py-4">
<fieldset>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Title</label>
<div class="col-lg-3">
<input type="text" class="form-control" name="title" id="title" required>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Description:</label>
<div class="col-lg-3">
<textarea class="form-control" name="description" maxlength="2000" rows="10" cols="50" id="description"></textarea>
</div>
</div>
{folderSelect}
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Privacy</label>
<div class="col-lg-3">
<select id="privacy" name="privacy" class="form-select">
<option value="private">Private</option>
<option value="public">Public</option>
</select>
</div>
</div>
<div class="mb-3 row">
<label for="title" class="col-lg-5 col-form-label text-end">Color</label>
<div class="col-lg-3">
{colorSelect}
</div>
</div>
<!-- Hidden Token -->
<input type="hidden" name="token" value="{TOKEN}">
<!-- Submit Button -->
<div class="text-center">
<button type="submit" name="submit" value="submit" class="btn btn-primary btn-lg">Create</button>
</div>
</fieldset>
</form>
</div>
</div>

View File

@ -0,0 +1,48 @@
<div class="container py-4">
<div class="row justify-content-center">
<div class="col-md-8">
<div class="card shadow">
<!-- Card Header -->
<div class="card-header text-center bg-dark text-white">
<h3 class="card-title mb-0">Bookmark</h3>
</div>
<!-- Card Body -->
<div class="card-body">
<div class="row align-items-center">
<!-- User Details -->
<div class="offset-md-2 col-md-8">
<table class="table table-borderless">
<tbody>
<tr>
<th scope="row">Title:</th>
<td>{title}</td>
</tr>
<tr>
<th scope="row">URL:</th>
<td>{url}</td>
</tr>
<tr>
<th scope="row">Created:</th>
<td>{DTC}{createdAt}{/DTC}</td>
</tr>
<tr>
<th scope="row">Last Refreshed:</th>
<td>{DTC}{refreshedAt}{/DTC}</td>
</tr>
<tr>
<th scope="row" colspan="2">Icon</th>
</tr>
<tr>
<td colspan="2">{iconHtml}</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
</div>

View File

@ -19,17 +19,13 @@
<th scope="row">Title:</th>
<td>{title}</td>
</tr>
<tr>
<th scope="row">Privacy:</th>
<td>{privacy}</td>
</tr>
<tr>
<th scope="row">Color:</th>
<td>{color}</td>
</tr>
<tr>
<th scope="row">Created:</th>
<td>{DTC}{createdAt}{/DTC}</td>
<th scope="row">Added on:</th>
<td>{DTC date}{createdAt}{/DTC}</td>
</tr>
<tr>
<th scope="row" colspan="2">Description</th>
@ -45,4 +41,9 @@
</div>
</div>
</div>
<div class="row justify-content-center">
<div class="col-md-12">
{panel}
</div>
</div>
</div>

View File

@ -5,15 +5,15 @@
<div class="offset-3 col-lg-6 my-4">
<p>Any link or folder can be shared. By default, the extensions and app both default to <strong>private</strong>. On this page, you can quickly see a list of any public links and folders. These "public" items can be shared with anyone who has the link.</p>
</div>
{LOOP}
<div class="col-6 col-md-12">
{panel}
</div>
{/LOOP}
{ALT}
<div class="col-12">
<p class="text-center">No <strong>public</strong> folders found.</p>
</div>
{/ALT}
<div class="row g-3" data-masonry='{ "percentPosition": false }' id="bookmarkSort">
{LOOP}
{panel}
{/LOOP}
{ALT}
<div class="col-12">
<p class="text-center">No <strong>public</strong> folders found.</p>
</div>
{/ALT}
</div>
</div>
</div>

View File

@ -1,83 +0,0 @@
<div class="container py-4">
<div class="row justify-content-center">
<div class="col-md-8">
<div class="card shadow">
<!-- Card Header -->
<div class="card-header text-center bg-dark text-white">
<h3 class="card-title mb-0">Bookmark</h3>
</div>
<!-- Card Body -->
<div class="card-body">
<div class="row align-items-center">
<!-- User Details -->
<div class="offset-md-2 col-md-8">
<table class="table table-borderless">
<tbody>
<tr>
<th scope="row">Title:</th>
<td>{title}</td>
</tr>
<tr>
<th scope="row">URL:</th>
<td>{url}</td>
</tr>
<tr>
<th scope="row">Type:</th>
<td>{linkType}</td>
</tr>
<tr>
<th scope="row">Privacy:</th>
<td>{privacy}</td>
</tr>
<tr>
<th scope="row">Color:</th>
<td>{color}</td>
</tr>
<tr>
<th scope="row">Created:</th>
<td>{DTC}{createdAt}{/DTC}</td>
</tr>
<tr>
<th scope="row">Archived:</th>
<td>{DTC}{archivedAt}{/DTC}</td>
</tr>
<tr>
<th scope="row">Hidden:</th>
<td>{DTC}{hiddenAt}{/DTC}</td>
</tr>
<tr>
<th scope="row">Last Refreshed:</th>
<td>{DTC}{refreshedAt}{/DTC}</td>
</tr>
<tr>
<th scope="row" colspan="2">Description</th>
</tr>
<tr>
<td colspan="2">{description}</td>
</tr>
<tr>
<th scope="row" colspan="2">Icon</th>
</tr>
<tr>
<td colspan="2">{iconHtml}</td>
</tr>
<tr>
<td colspan="2">{icon}</td>
</tr>
<tr>
<th scope="row" colspan="2">Meta</th>
</tr>
<tr>
<td colspan="2">{meta}</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
</div>