fix(ci): repair mobile tests and lint diagnostics

Restore the saved-list filter import and test the actual sheet backdrop. Remove unsafe fixture assertions and apply formatting reported by CI.

Reuse the current lint results and compare base files in sequence so warning diagnostics can finish without exhausting the heap.
This commit is contained in:
Maurice
2026-12-04 09:48:37 +01:00
parent faaa56eda6
commit 814e4f047e
10 changed files with 59 additions and 45 deletions
@@ -178,7 +178,8 @@ describe('IcsSubscribeModal on the phone', () => {
fireEvent.click(screen.getByRole('button', { name: 'Close' }));
expect(onClose).toHaveBeenCalledTimes(1);
const backdrop = document.querySelector('[data-m-scrim]')!.parentElement!;
const backdrop = screen.getByRole('dialog', { name: defaultProps.title }).closest('[role="presentation"]');
if (!backdrop) throw new Error('Expected the sheet backdrop');
fireEvent.click(backdrop);
expect(onClose).toHaveBeenCalledTimes(2);
@@ -5,6 +5,7 @@ import type { useCollections } from '../../../pages/collections/useCollections';
import MListRow from '../../components/MListRow';
import { CollFilterSection, CollFiltersSheet, DropRow } from './MCollFilterKit';
import { categoryMeta, STATUS_SPEC } from './collectionsMobileModel';
import { savedListFilterCount } from './savedListFilterCount';
type Collections = ReturnType<typeof useCollections>;
type Group = 'status' | 'category' | 'tags' | 'rating' | 'sort';
@@ -19,14 +19,15 @@ import { useSettingsStore } from '../../../store/settingsStore';
import MSheet from '../../components/MSheet';
import MSkeleton from '../../components/MSkeleton';
import MConfirmSheet from '../settings/MConfirmSheet';
import { formOptionClass } from '../trip/sheets/formOptionClass';
import {
FIELD_CLS,
FORM_LABEL_CLS,
FormSheetBody,
FormSheetFooter,
FormSheetHeader,
FormSheetSection } from '../trip/sheets/PlSheetChrome';
import { formOptionClass } from '../trip/sheets/formOptionClass';
FormSheetSection,
} from '../trip/sheets/PlSheetChrome';
/** A kept tour's measures as the small pills of the phone's rows. */
function MeasurePills({ tour }: { tour: CollectionTourItem }) {
@@ -9,7 +9,8 @@ import {
FormSheetBody,
FormSheetFooter,
FormSheetHeader,
FormSheetSection } from '../trip/sheets/PlSheetChrome';
FormSheetSection,
} from '../trip/sheets/PlSheetChrome';
import { formOptionClass } from '../trip/sheets/formOptionClass';
export default function MJourneyInviteFrame({
@@ -1,5 +1,5 @@
export function formOptionClass(active: boolean) {
return `flex min-h-10 items-center gap-1.5 rounded-full border px-3 py-1.5 text-start text-caption font-semibold ${
active ? 'border-transparent bg-m-act text-m-actfg' : 'border-m-rowbr bg-m-sheetop text-m-ink'
}`
}`;
}