Remove tag order admin insight

This commit is contained in:
Sam Becker 2025-07-10 21:19:14 -05:00
parent 88e680f12b
commit 94af65c045
3 changed files with 0 additions and 29 deletions

View File

@ -46,7 +46,6 @@ export default async function AdminAppInsights() {
photosCount, photosCount,
photosCountNeedSync, photosCountNeedSync,
photosCountPortrait, photosCountPortrait,
tagsCount: tags.length,
})} })}
photoStats={{ photoStats={{
photosCount, photosCount,

View File

@ -4,7 +4,6 @@ import ScoreCard from '@/components/ScoreCard';
import ScoreCardRow from '@/components/ScoreCardRow'; import ScoreCardRow from '@/components/ScoreCardRow';
import { dateRangeForPhotos } from '@/photo'; import { dateRangeForPhotos } from '@/photo';
import { FaCircleInfo, FaRegCalendar } from 'react-icons/fa6'; import { FaCircleInfo, FaRegCalendar } from 'react-icons/fa6';
import { HiMiniArrowsUpDown } from 'react-icons/hi2';
import { MdAspectRatio } from 'react-icons/md'; import { MdAspectRatio } from 'react-icons/md';
import { PiWarningBold } from 'react-icons/pi'; import { PiWarningBold } from 'react-icons/pi';
import { TbSparkles } from 'react-icons/tb'; import { TbSparkles } from 'react-icons/tb';
@ -117,7 +116,6 @@ export default function AdminAppInsightsClient({
noConfiguredMeta, noConfiguredMeta,
photosNeedSync, photosNeedSync,
photoMatting, photoMatting,
camerasFirst,
gridFirst, gridFirst,
noStaticOptimization, noStaticOptimization,
} = insights; } = insights;
@ -385,23 +383,6 @@ export default function AdminAppInsightsClient({
/> />
</>} </>}
/>} />}
{(camerasFirst || debug) && <ScoreCardRow
icon={<HiMiniArrowsUpDown
size={17}
className="translate-x-[-1px]"
/>}
content="Move cameras above tags in sidebar"
expandContent={<>
Now that you have more than a few tags, consider
showing cameras first in the sidebar by setting
{' '}
<EnvVar
variable="NEXT_PUBLIC_CATEGORY_VISIBILITY"
value="cameras, tags, recipes, films"
trailingContent="."
/>
</>}
/>}
{(gridFirst || debug) && <ScoreCardRow {(gridFirst || debug) && <ScoreCardRow
icon={<IoMdGrid size={18} className="translate-y-[-1px]" />} icon={<IoMdGrid size={18} className="translate-y-[-1px]" />}
content="Grid homepage" content="Grid homepage"

View File

@ -9,7 +9,6 @@ import {
MATTE_PHOTOS, MATTE_PHOTOS,
IS_META_DESCRIPTION_CONFIGURED, IS_META_DESCRIPTION_CONFIGURED,
IS_META_TITLE_CONFIGURED, IS_META_TITLE_CONFIGURED,
CATEGORY_VISIBILITY,
HAS_STATIC_OPTIMIZATION, HAS_STATIC_OPTIMIZATION,
GRID_HOMEPAGE_ENABLED, GRID_HOMEPAGE_ENABLED,
AI_TEXT_GENERATION_ENABLED, AI_TEXT_GENERATION_ENABLED,
@ -18,7 +17,6 @@ import { PhotoDateRange } from '@/photo';
import { getGitHubMeta } from '@/platforms/github'; import { getGitHubMeta } from '@/platforms/github';
const BASIC_PHOTO_INSTALLATION_COUNT = 32; const BASIC_PHOTO_INSTALLATION_COUNT = 32;
const TAG_COUNT_THRESHOLD = 12;
const AdminAppInsightCode = [ const AdminAppInsightCode = [
'noFork', 'noFork',
@ -32,7 +30,6 @@ const _INSIGHTS_TEMPLATE = [
'noConfiguredDomain', 'noConfiguredDomain',
'noConfiguredMeta', 'noConfiguredMeta',
'photoMatting', 'photoMatting',
'camerasFirst',
'gridFirst', 'gridFirst',
'noStaticOptimization', 'noStaticOptimization',
] as const; ] as const;
@ -129,11 +126,9 @@ export const getAllInsights = ({
photosCountNeedSync, photosCountNeedSync,
photosCount, photosCount,
photosCountPortrait, photosCountPortrait,
tagsCount,
}: Parameters<typeof getSignificantInsights>[0] & { }: Parameters<typeof getSignificantInsights>[0] & {
photosCount: number photosCount: number
photosCountPortrait: number photosCountPortrait: number
tagsCount: number
}) => ({ }) => ({
...getSignificantInsights({ codeMeta, photosCountNeedSync }), ...getSignificantInsights({ codeMeta, photosCountNeedSync }),
noFork: !codeMeta?.isForkedFromBase && !codeMeta?.isBaseRepo, noFork: !codeMeta?.isForkedFromBase && !codeMeta?.isBaseRepo,
@ -142,10 +137,6 @@ export const getAllInsights = ({
!IS_META_TITLE_CONFIGURED || !IS_META_TITLE_CONFIGURED ||
!IS_META_DESCRIPTION_CONFIGURED, !IS_META_DESCRIPTION_CONFIGURED,
photoMatting: photosCountPortrait > 0 && !MATTE_PHOTOS, photoMatting: photosCountPortrait > 0 && !MATTE_PHOTOS,
camerasFirst: (
tagsCount > TAG_COUNT_THRESHOLD &&
CATEGORY_VISIBILITY[0] !== 'cameras'
),
gridFirst: ( gridFirst: (
photosCount >= BASIC_PHOTO_INSTALLATION_COUNT && photosCount >= BASIC_PHOTO_INSTALLATION_COUNT &&
!GRID_HOMEPAGE_ENABLED !GRID_HOMEPAGE_ENABLED