DLNA renderers, app updates told like Librarian, acquisition without Lidarr, Collection and admin rework (M502–M505, M542) #156
@@ -15,7 +15,9 @@
|
|||||||
title,
|
title,
|
||||||
subtitle,
|
subtitle,
|
||||||
imageUrl,
|
imageUrl,
|
||||||
state,
|
// Renamed inside the component: a binding called `state` would make
|
||||||
|
// `$state` read as a store subscription instead of the rune.
|
||||||
|
state: cardState,
|
||||||
attribution,
|
attribution,
|
||||||
onRequest,
|
onRequest,
|
||||||
onSnooze,
|
onSnooze,
|
||||||
@@ -48,13 +50,13 @@
|
|||||||
);
|
);
|
||||||
|
|
||||||
function handleRequest() {
|
function handleRequest() {
|
||||||
if (state === 'requestable') onRequest?.();
|
if (cardState === 'requestable') onRequest?.();
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<article
|
<article
|
||||||
class="card rounded-lg border border-border bg-surface p-3"
|
class="card rounded-lg border border-border bg-surface p-3"
|
||||||
data-state={state}
|
data-state={cardState}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
class="art flex aspect-square w-full items-center justify-center overflow-hidden rounded-md bg-surface-hover"
|
class="art flex aspect-square w-full items-center justify-center overflow-hidden rounded-md bg-surface-hover"
|
||||||
@@ -83,16 +85,16 @@
|
|||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
<div class="badge-row" data-testid="badge-row">
|
<div class="badge-row" data-testid="badge-row">
|
||||||
{#if state === 'kept'}
|
{#if cardState === 'kept'}
|
||||||
<span class="kept-pill" role="status">Kept</span>
|
<span class="kept-pill" role="status">Kept</span>
|
||||||
{:else if state === 'snoozed'}
|
{:else if cardState === 'snoozed'}
|
||||||
<span class="snoozed-pill" role="status">Not right now</span>
|
<span class="snoozed-pill" role="status">Not right now</span>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="actions pt-3" data-testid="actions">
|
<div class="actions pt-3" data-testid="actions">
|
||||||
{#if state === 'snoozed'}
|
{#if cardState === 'snoozed'}
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
aria-label={`Bring ${title} back`}
|
aria-label={`Bring ${title} back`}
|
||||||
@@ -101,7 +103,7 @@
|
|||||||
>
|
>
|
||||||
Undo
|
Undo
|
||||||
</button>
|
</button>
|
||||||
{:else if state === 'requestable'}
|
{:else if cardState === 'requestable'}
|
||||||
<div class="flex items-center gap-2">
|
<div class="flex items-center gap-2">
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
@@ -129,7 +131,7 @@
|
|||||||
</button>
|
</button>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
{:else if state === 'kept'}
|
{:else if cardState === 'kept'}
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
disabled
|
disabled
|
||||||
|
|||||||
Reference in New Issue
Block a user