chore: eslint 10 (#26490)

This commit is contained in:
Daniel Dietzler
2026-02-24 14:24:18 +01:00
committed by GitHub
parent 30f6d4439e
commit 55ee9f76da
22 changed files with 195 additions and 179 deletions

View File

@@ -46,6 +46,7 @@
userSettings,
allowEdit = false,
showOwner = false,
// eslint-disable-next-line no-useless-assignment
albumGroupIds = $bindable([]),
empty,
}: Props = $props();

View File

@@ -223,7 +223,7 @@
}
void tracker.invoke(async () => {
let hasNext = false;
let hasNext: boolean;
if ($slideshowState === SlideshowState.PlaySlideshow && $slideshowNavigation === SlideshowNavigation.Shuffle) {
hasNext = order === 'previous' ? slideshowHistory.previous() : slideshowHistory.next();

View File

@@ -42,16 +42,7 @@
}
function ratioSelected(ratio: AspectRatioOption): boolean {
let currentRatioRotated;
if (ratio.value === 'original') {
const { width, height } = transformManager.cropImageSize;
// Account for rotation when comparing to original
if (isRotated) {
currentRatioRotated = `${height}:${width}`;
}
currentRatioRotated = `${width}:${height}`;
}
currentRatioRotated = rotatedRatio(ratio);
const currentRatioRotated = rotatedRatio(ratio);
return transformManager.cropAspectRatio === currentRatioRotated;
}

View File

@@ -47,6 +47,7 @@
let {
searchName = $bindable(),
// eslint-disable-next-line no-useless-assignment
searchedPeopleLocal = $bindable(),
type,
numberPeopleToSearch = maximumLengthSearchPeople,

View File

@@ -277,7 +277,7 @@
afterNavigate(({ from, to }) => {
memoryStore.ready().then(
() => {
let target = null;
let target;
if (to?.params?.assetId) {
target = to;
} else if (from?.params?.assetId) {

View File

@@ -21,8 +21,10 @@
let {
places = $bindable([]),
searchQuery = '',
// eslint-disable-next-line no-useless-assignment
searchResultCount = $bindable(0),
userSettings,
// eslint-disable-next-line no-useless-assignment
placesGroupIds = $bindable([]),
}: Props = $props();

View File

@@ -50,6 +50,7 @@
onScrubKeyDown = undefined,
startScrub = undefined,
stopScrub = undefined,
// eslint-disable-next-line no-useless-assignment
scrubberWidth = $bindable(),
}: Props = $props();

View File

@@ -332,7 +332,7 @@
const monthsLength = timelineManager.months.length;
for (let i = -1; i < monthsLength + 1; i++) {
let monthGroup: ViewportTopMonth;
let monthGroupHeight = 0;
let monthGroupHeight: number;
if (i === -1) {
// lead-in
monthGroup = 'lead-in';

View File

@@ -32,6 +32,7 @@
let {
timelineManager,
// eslint-disable-next-line no-useless-assignment
invisible = $bindable(false),
removeAction,
withStacked = false,

View File

@@ -1004,7 +1004,7 @@ class TransformManager implements EditToolManager {
];
}
let cursorName = '';
let cursorName: string;
if (onTopLeftCorner || onBottomRightCorner) {
cursorName = 'nwse-resize';
} else if (onTopRightCorner || onBottomLeftCorner) {

View File

@@ -122,6 +122,7 @@ export async function retrieveRange(timelineManager: TimelineManager, start: Ass
const assetOrder: AssetOrder = timelineManager.getAssetOrder();
if (plainDateTimeCompare(assetOrder === AssetOrder.Desc, startAsset.localDateTime, endAsset.localDateTime) < 0) {
[startAsset, endAsset] = [endAsset, startAsset];
// eslint-disable-next-line no-useless-assignment
[startMonthGroup, endMonthGroup] = [endMonthGroup, startMonthGroup];
}