mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-10-23 15:36:33 +00:00
fix(assistant): lint, types and tests for the CI round
- agent loop and decisions without await in loops: steps as recursion, calls and applied changes in order through one promise chain, the independent reads and claims in parallel; part mapping in its own helpers - place card, header and weather strip without refs or components created in render; long hooks and components split; state reset during render - trip notes only in a turn's tool session, never an undo's; map view reported only while the assistant can run - place strip scrolls through the strip's own smooth scroll, no physical side - tests follow the raised limits and the new card fields; toasts read through a mocked useToast instead of a window global; baselines lowered where the counts fell
This commit is contained in:
@@ -4,7 +4,8 @@
|
||||
import { afterEach, describe, expect, it, vi } from 'vitest';
|
||||
|
||||
import { render } from '../../../tests/helpers/render';
|
||||
import Kbd, { isApplePlatform } from './Kbd';
|
||||
import { isApplePlatform } from '../../utils/applePlatform';
|
||||
import Kbd from './Kbd';
|
||||
|
||||
afterEach(() => vi.restoreAllMocks());
|
||||
|
||||
|
||||
@@ -18,8 +18,3 @@ export default function Kbd({ keys, className = '' }: { keys: readonly string[];
|
||||
</kbd>
|
||||
);
|
||||
}
|
||||
|
||||
/** Whether shortcuts here read with ⌘ rather than Ctrl. */
|
||||
export function isApplePlatform(): boolean {
|
||||
return typeof navigator !== 'undefined' && /Mac|iPhone|iPad|iPod/.test(navigator.userAgent);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user