Skip to content

[🐞]Qwik v2: interactive element does not update multiple array items; only one item toggles per click #7795

@ToanTrinh01

Description

@ToanTrinh01

Which component is affected?

Qwik Runtime

Describe the bug

Toggling "Select all" on a list backed by an array updates only one item per click. Repeated clicks progress through the array; once all are selected, further clicks toggle only the first item.

Reproduction

https://github.com/ToanTrinh01/v2-synchronized-repo

Steps to reproduce

  1. Run pnpm install
  2. Run pnpm dev
  3. Navigate to http://localhost:5173/
  4. Click the "Select all" trigger repeatedly.
  5. Observe that only one array element updates per click.

Expected

One click updates all items in the array to the target state (all selected or all deselected).

Actual

Only a single array element updates per click (advances index-by-index); after all are selected, only the first item toggles on further clicks.

System Info

System:
    OS: macOS 15.5
    CPU: (10) arm64 Apple M1 Pro
    Memory: 132.14 MB / 16.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.12.2 - ~/.nvm/versions/node/v20.12.2/bin/node
    npm: 10.5.0 - ~/.nvm/versions/node/v20.12.2/bin/npm
    pnpm: 9.14.2 - ~/.nvm/versions/node/v20.12.2/bin/pnpm
  Browsers:
    Chrome: 138.0.7204.184
    Safari: 18.5
  npmPackages:
    typescript: 5.4.5 => 5.4.5 
    undici: * => 7.13.0 
    vite: 5.3.5 => 5.3.5

Additional Information

No response

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions