Skip to content

Commit 8ead89f

Browse files
ABCrimsonclaude
andcommitted
chore: fix docs Iterator.range bug, align tsdown targets, cleanup
- Fix non-existent Iterator.range() in virtualization docs (use Array.from) - Align tsdown target to 'esnext' in create-modern-cmdk and command-search-wasm - Remove unused variable in keyboard E2E test - Use --ease-out token instead of identity linear() in playground item transition Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 655fd6a commit 8ead89f

5 files changed

Lines changed: 10 additions & 12 deletions

File tree

apps/docs/guide/virtualization.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,12 @@ Virtualization is opt-out, not opt-in. When your filtered results exceed the thr
1111

1212
import { Command } from 'modern-cmdk/react';
1313

14-
// Generate 10,000 items using Iterator Helpers
15-
const items = Iterator.range(0, 10_000)
16-
.map((i) => ({ id: `item-${i}`, label: `Item ${i}`, value: `item-${i}` }))
17-
.toArray();
14+
// Generate 10,000 items using Iterator Helpers (ES2026)
15+
const items = Array.from({ length: 10_000 }, (_, i) => ({
16+
id: `item-${i}`,
17+
label: `Item ${i}`,
18+
value: `item-${i}`,
19+
}));
1820

1921
function LargeList() {
2022
return (

apps/playground/src/styles.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -467,8 +467,8 @@
467467
font-size: 0.875rem;
468468
color: var(--text-secondary);
469469
transition:
470-
background-color var(--duration-fast) linear(0, 0.25, 0.5, 0.75, 1),
471-
color var(--duration-fast) ease;
470+
background-color var(--duration-fast) var(--ease-out),
471+
color var(--duration-fast) var(--ease-out);
472472

473473
&[data-active] {
474474
background: var(--bg-active);

packages/command-search-wasm/tsdown.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export default defineConfig({
99
sourcemap: true,
1010
clean: true,
1111
outDir: 'dist',
12-
target: 'es2026',
12+
target: 'esnext',
1313
treeshake: true,
1414
minify: false,
1515
define: {

packages/create-modern-cmdk/tsdown.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export default defineConfig({
77
sourcemap: true,
88
clean: true,
99
outDir: 'dist',
10-
target: 'es2026',
10+
target: 'esnext',
1111
treeshake: true,
1212
minify: false,
1313
platform: 'node',

tests/e2e/keyboard.spec.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -247,10 +247,6 @@ test.describe('Keyboard Navigation', () => {
247247
const input = page.getByRole('combobox');
248248
await input.focus();
249249

250-
// If there are pages, the initial page should be visible
251-
const pages = page.locator('[data-command-page]');
252-
const _initialPageCount = await pages.count();
253-
254250
// Pressing Backspace with empty input should attempt to pop page
255251
await expect(input).toHaveValue('');
256252
await input.press('Backspace');

0 commit comments

Comments
 (0)