Implement album creation on web (#365)

* Added album creation button functionality

* Added input for album title

* Added select photos button

* Added page to select assets

* Show photo selection timeline

* Implemented update album name mechanism:

* Added selection mechanism

* Added selection mechanism with existing assets in album

* Refactored and added comments

* Refactored and added comments - 2

* Refactor album app bar

* Added modal for select user

* Implemented choose users

* Added additional share user button

* Added rule to show add users button
This commit is contained in:
Alex
2022-07-22 09:44:22 -05:00
committed by GitHub
parent 02bde51caf
commit 1d34976dd0
14 changed files with 787 additions and 154 deletions

View File

@@ -0,0 +1,39 @@
<script lang="ts">
import { createEventDispatcher, onMount } from 'svelte';
import Close from 'svelte-material-icons/Close.svelte';
export let backIcon = Close;
let appBarBorder = '';
const dispatch = createEventDispatcher();
onMount(() => {
window.onscroll = () => {
if (window.pageYOffset > 80) {
appBarBorder = 'border border-gray-200 bg-gray-50';
} else {
appBarBorder = '';
}
};
});
</script>
<div class="fixed top-0 w-full bg-transparent z-[100]">
<div
id="asset-selection-app-bar"
class={`flex justify-between ${appBarBorder} rounded-lg p-2 mx-2 mt-2 transition-all place-items-center`}
>
<div class="flex place-items-center gap-6">
<button
on:click={() => dispatch('close-button-click')}
id="immich-circle-icon-button"
class={`rounded-full p-3 flex place-items-center place-content-center text-gray-600 transition-all hover:bg-gray-200`}
>
<svelte:component this={backIcon} size="24" />
</button>
<slot name="leading" />
</div>
<div class="flex place-items-center gap-6 mr-4">
<slot name="trailing" />
</div>
</div>
</div>