Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auth Migration, Calendar and Other Misc. Fixes #406

Merged
merged 28 commits into from
Dec 15, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
d7baf69
Bump @sveltejs/kit
dependabot[bot] Nov 25, 2024
9bc20be
Initial migration to new session based auth system with AllAuth
seanmorley15 Nov 29, 2024
f119e6f
Refactor settings.py to remove unused authentication configurations a…
seanmorley15 Nov 29, 2024
b86c725
Enhance admin security by integrating secure_admin_login from AllAuth…
seanmorley15 Nov 29, 2024
c65fcc2
Migrate to session based auth
seanmorley15 Nov 29, 2024
84566b8
User profile settings API and remove old Dj-Rest-Auth code
seanmorley15 Nov 30, 2024
50dc042
Refactor user serializers, update Docker configurations, and remove u…
seanmorley15 Dec 1, 2024
4ecad7f
Update nl.json
seanmorley15 Dec 2, 2024
dc29f48
Add 'Northern Lights' theme and update localization and Tailwind conf…
seanmorley15 Dec 2, 2024
21d8b37
Merge pull request #395 from seanmorley15/update-nl
seanmorley15 Dec 2, 2024
88dbd41
Merge pull request #375 from seanmorley15/dependabot/npm_and_yarn/fro…
seanmorley15 Dec 3, 2024
a39e22b
Add new dashboard
seanmorley15 Dec 3, 2024
d44cb06
Refactor AdventureCard usage and integrate event calendar components
seanmorley15 Dec 4, 2024
6410580
Add calendar route and integrate calendar component in Navbar
seanmorley15 Dec 4, 2024
6a00a2e
Refactor Docker Compose configuration and enhance email management in…
seanmorley15 Dec 7, 2024
0272c6b
Refactor user admin settings and enhance email management functionality
seanmorley15 Dec 12, 2024
2ccbf4b
Update email verification and password reset flows; refactor Docker C…
seanmorley15 Dec 12, 2024
54d7a1a
Update forgot password link to point to user reset-password route
seanmorley15 Dec 12, 2024
673a56c
Add MFA to login screen
seanmorley15 Dec 12, 2024
7b7db1c
Refactor email management and localization; update requirements and s…
seanmorley15 Dec 13, 2024
1b54f8e
Implement TOTP 2FA modal; add QR code generation and recovery codes m…
seanmorley15 Dec 13, 2024
9bf0849
Add multi-factor authentication (MFA) support; update localization an…
seanmorley15 Dec 14, 2024
0376709
Enhance localization support; update error messages and add translati…
seanmorley15 Dec 14, 2024
c0fd91e
Add emoji picker to category dropdown; implement toggle functionality…
seanmorley15 Dec 14, 2024
4839edd
Update password reset form and add more localization for error messages
seanmorley15 Dec 14, 2024
0c27f4b
Add download adventures as ICS calendar
seanmorley15 Dec 14, 2024
c966b73
Fix formatting in README.md for better readability
seanmorley15 Dec 14, 2024
10dbafd
Update button label in NewTransportation component to Create
seanmorley15 Dec 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add emoji picker to category dropdown; implement toggle functionality…
… and handle emoji selection
  • Loading branch information
seanmorley15 committed Dec 14, 2024
commit c0fd91ef8da7e0d805cb4397780f335300fe6c4d
1 change: 1 addition & 0 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"type": "module",
"dependencies": {
"@lukulent/svelte-umami": "^0.0.3",
"emoji-picker-element": "^1.26.0",
"qrcode": "^1.5.4",
"svelte-i18n": "^4.0.1",
"svelte-maplibre": "^0.9.8"
Expand Down
8 changes: 8 additions & 0 deletions frontend/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

58 changes: 41 additions & 17 deletions frontend/src/lib/components/CategoryDropdown.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@
num_adventures: 0
};

let isOpen = false;
let isOpen: boolean = false;
let isEmojiPickerVisible: boolean = false;

function toggleEmojiPicker() {
isEmojiPickerVisible = !isEmojiPickerVisible;
}

function toggleDropdown() {
isOpen = !isOpen;
Expand All @@ -31,6 +36,10 @@
selectCategory(new_category);
}

function handleEmojiSelect(event: CustomEvent) {
new_category.icon = event.detail.unicode;
}

// Close dropdown when clicking outside
let dropdownRef: HTMLDivElement;

Expand All @@ -46,6 +55,9 @@
document.removeEventListener('click', handleClickOutside);
};
});
onMount(async () => {
await import('emoji-picker-element');
});
</script>

<div class="mt-2 relative" bind:this={dropdownRef}>
Expand All @@ -59,23 +71,35 @@
<div class="absolute z-10 w-full mt-1 bg-base-300 rounded shadow-lg p-2">
<!-- svelte-ignore a11y-click-events-have-key-events -->
<!-- svelte-ignore a11y-no-static-element-interactions -->
<div class="flex items-center gap-2">
<input
type="text"
placeholder={$t('categories.category_name')}
class="input input-bordered w-full max-w-xs"
bind:value={new_category.display_name}
/>
<input
type="text"
placeholder={$t('categories.icon')}
class="input input-bordered w-full max-w-xs"
bind:value={new_category.icon}
/>
<button on:click={custom_category} type="button" class="btn btn-primary"
>{$t('adventures.add')}</button
>
<div class="flex flex-col gap-2">
<div class="flex items-center gap-2">
<input
type="text"
placeholder={$t('categories.category_name')}
class="input input-bordered w-full max-w-xs"
bind:value={new_category.display_name}
/>
<input
type="text"
placeholder={$t('categories.icon')}
class="input input-bordered w-full max-w-xs"
bind:value={new_category.icon}
/>
<button on:click={toggleEmojiPicker} type="button" class="btn btn-secondary">
{isEmojiPickerVisible ? 'Hide' : 'Show'} Emoji Picker
</button>
<button on:click={custom_category} type="button" class="btn btn-primary">
{$t('adventures.add')}
</button>
</div>

{#if isEmojiPickerVisible}
<div class="mt-2">
<emoji-picker on:emoji-click={handleEmojiSelect}></emoji-picker>
</div>
{/if}
</div>

<div class="flex flex-wrap gap-2 mt-2">
<!-- Sort the categories dynamically before rendering -->
{#each categories
Expand Down
Loading