Merge branch 'develop'

master
sct 2 years ago
commit ba84a32c0d

@ -226,12 +226,13 @@ class PlexAPI {
id: string,
options: { addedAt: number } = {
addedAt: Date.now() - 1000 * 60 * 60,
}
},
mediaType: 'movie' | 'show'
): Promise<PlexLibraryItem[]> {
const response = await this.plexClient.query<PlexLibraryResponse>({
uri: `/library/sections/${id}/all?sort=addedAt%3Adesc&addedAt>>=${Math.floor(
options.addedAt / 1000
)}`,
uri: `/library/sections/${id}/all?type=${
mediaType === 'show' ? '4' : '1'
}&sort=addedAt%3Adesc&addedAt>>=${Math.floor(options.addedAt / 1000)}`,
extraHeaders: {
'X-Plex-Container-Start': `0`,
'X-Plex-Container-Size': `500`,

@ -96,7 +96,8 @@ class PlexScanner
// We remove 10 minutes from the last scan as a buffer
addedAt: library.lastScan - 1000 * 60 * 10,
}
: undefined
: undefined,
library.type
);
// Bundle items up by rating keys

@ -37,6 +37,7 @@ const AirDateBadge = ({ airDate }: AirDateBadgeProps) => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
})}
</Badge>
{showRelative && (

@ -167,7 +167,9 @@ const MobileMenu = () => {
</Transition>
<div className="padding-bottom-safe border-t border-gray-600 bg-gray-800 bg-opacity-90 backdrop-blur">
<div className="flex h-full items-center justify-between px-6 py-4 text-gray-100">
{filteredLinks.slice(0, 4).map((link) => {
{filteredLinks
.slice(0, filteredLinks.length === 5 ? 5 : 4)
.map((link) => {
const isActive =
router.pathname.match(link.activeRegExp) && !isOpen;
return (
@ -187,7 +189,7 @@ const MobileMenu = () => {
</Link>
);
})}
{filteredLinks.length > 4 && (
{filteredLinks.length > 4 && filteredLinks.length !== 5 && (
<button
className={`flex flex-col items-center space-y-1 ${
isOpen ? 'text-indigo-500' : ''

@ -621,6 +621,7 @@ const MovieDetails = ({ movie }: MovieDetailsProps) => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
})}
</span>
</span>
@ -640,6 +641,7 @@ const MovieDetails = ({ movie }: MovieDetailsProps) => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
})}
</span>
</div>

@ -91,11 +91,13 @@ const PersonDetails = () => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
}),
deathdate: intl.formatDate(data.deathday, {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
}),
})
);
@ -106,6 +108,7 @@ const PersonDetails = () => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
}),
})
);

@ -844,6 +844,7 @@ const TvDetails = ({ tv }: TvDetailsProps) => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
})}
</span>
</div>
@ -858,6 +859,7 @@ const TvDetails = ({ tv }: TvDetailsProps) => {
year: 'numeric',
month: 'long',
day: 'numeric',
timeZone: 'UTC',
})}
</span>
</div>

@ -452,8 +452,9 @@
@apply hidden;
}
input[type='range']::-webkit-slider-thumb {
@apply rounded-full bg-indigo-500;
input[type='range']::-webkit-slider-thumb,
input[type='range']::-moz-range-thumb {
@apply rounded-full border-0 bg-indigo-500;
pointer-events: all;
width: 16px;
height: 16px;

Loading…
Cancel
Save