You've already forked immich
mirror of
https://github.com/immich-app/immich.git
synced 2025-06-27 05:11:11 +02:00
refactor(web): albums list (1) (#7660)
* refactor: albums list * fix: rename filename * chore: fix merge * pr feedback * chore: fix merge * pr feedback --------- Co-authored-by: Alex Tran <alex.tran1502@gmail.com>
This commit is contained in:
@ -1,29 +0,0 @@
|
||||
<script lang="ts">
|
||||
import type { Sort } from '../../../routes/(user)/albums/+page.svelte';
|
||||
|
||||
export let albumViewSettings: string;
|
||||
export let option: Sort;
|
||||
|
||||
const handleSort = () => {
|
||||
if (albumViewSettings === option.title) {
|
||||
option.sortDesc = !option.sortDesc;
|
||||
} else {
|
||||
albumViewSettings = option.title;
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<th class="{option.widthClass} text-sm font-medium"
|
||||
><button
|
||||
class="rounded-lg p-2 hover:bg-immich-dark-primary hover:dark:bg-immich-dark-primary/50"
|
||||
on:click={() => handleSort()}
|
||||
>
|
||||
{#if albumViewSettings === option.title}
|
||||
{#if option.sortDesc}
|
||||
↓
|
||||
{:else}
|
||||
↑
|
||||
{/if}
|
||||
{/if}{option.title}</button
|
||||
></th
|
||||
>
|
Reference in New Issue
Block a user