Revert to naive times in CommandK menu
This commit is contained in:
parent
d2ea11dd79
commit
f1fc3cbbc1
@ -48,7 +48,6 @@ import CommandKItem from './CommandKItem';
|
||||
import { GRID_HOMEPAGE_ENABLED } from '@/site/config';
|
||||
import { DialogDescription, DialogTitle } from '@radix-ui/react-dialog';
|
||||
import * as VisuallyHidden from '@radix-ui/react-visually-hidden';
|
||||
import { Timezone } from '@/utility/timezone';
|
||||
|
||||
const DIALOG_TITLE = 'Global Command-K Menu';
|
||||
const DIALOG_DESCRIPTION = 'For searching photos, views, and settings';
|
||||
@ -77,13 +76,11 @@ export default function CommandKClient({
|
||||
serverSections = [],
|
||||
showDebugTools,
|
||||
footer,
|
||||
timezone,
|
||||
}: {
|
||||
tags: Tags
|
||||
serverSections?: CommandKSection[]
|
||||
showDebugTools?: boolean
|
||||
footer?: string
|
||||
timezone: Timezone
|
||||
}) {
|
||||
const pathname = usePathname();
|
||||
|
||||
@ -169,7 +166,7 @@ export default function CommandKClient({
|
||||
items: photos.map(photo => ({
|
||||
label: titleForPhoto(photo),
|
||||
keywords: getKeywordsForPhoto(photo),
|
||||
annotation: <PhotoDate {...{ photo, timezone }} />,
|
||||
annotation: <PhotoDate {...{ photo, timezone: undefined }} />,
|
||||
accessory: <PhotoSmall photo={photo} />,
|
||||
path: pathForPhoto({ photo }),
|
||||
})),
|
||||
@ -187,7 +184,7 @@ export default function CommandKClient({
|
||||
setIsLoading(false);
|
||||
});
|
||||
}
|
||||
}, [queryDebounced, isPending, timezone]);
|
||||
}, [queryDebounced, isPending]);
|
||||
|
||||
useEffect(() => {
|
||||
if (queryLive === '') {
|
||||
|
||||
@ -22,12 +22,8 @@ import { labelForFilmSimulation } from '@/vendors/fujifilm';
|
||||
import { getUniqueFocalLengths } from '@/photo/db/query';
|
||||
import { formatFocalLength } from '@/focal';
|
||||
import { TbCone } from 'react-icons/tb';
|
||||
import { cookies } from 'next/headers';
|
||||
import { TIMEZONE_COOKIE_NAME } from '@/utility/timezone';
|
||||
|
||||
export default async function CommandK() {
|
||||
const timezone = (await cookies()).get(TIMEZONE_COOKIE_NAME)?.value;
|
||||
|
||||
const [
|
||||
count,
|
||||
tags,
|
||||
@ -92,6 +88,5 @@ export default async function CommandK() {
|
||||
]}
|
||||
showDebugTools={ADMIN_DEBUG_TOOLS_ENABLED}
|
||||
footer={photoQuantityText(count, false)}
|
||||
timezone={timezone}
|
||||
/>;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user