Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Persist defaultItems in the collection store #2559

Merged
merged 2 commits into from Jun 17, 2023

Conversation

diegohaz
Copy link
Member

@diegohaz diegohaz commented Jun 17, 2023

This PR fixes the defaultItems prop on the collection store and other stores that use it. The default items passed to the collection were being overridden when new items were added.

@changeset-bot
Copy link

changeset-bot bot commented Jun 17, 2023

🦋 Changeset detected

Latest commit: efb1f2f

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 4 packages
Name Type
@ariakit/core Patch
@ariakit/react Patch
@ariakit/react-core Patch
@ariakit/test Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel
Copy link

vercel bot commented Jun 17, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
ariakit ✅ Ready (Inspect) Visit Preview Jun 17, 2023 0:46am
1 Ignored Deployment
Name Status Preview Updated (UTC)
reakit ⬜️ Ignored (Inspect) Jun 17, 2023 0:46am

@codesandbox-ci
Copy link

codesandbox-ci bot commented Jun 17, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit efb1f2f:

Sandbox Source
Ariakit Configuration

@diegohaz diegohaz merged commit b1b20bd into main Jun 17, 2023
14 checks passed
@diegohaz diegohaz deleted the collection-store-default-items branch June 17, 2023 12:53
@github-actions github-actions bot mentioned this pull request Jun 17, 2023
diegohaz pushed a commit that referenced this pull request Jun 18, 2023
This PR was opened by the [Changesets
release](https://github.com/changesets/action) GitHub action. When
you're ready to do a release, you can merge this and the packages will
be published to npm automatically. If you're not ready to do a release
yet, that's fine, whenever you add more changesets to main, this PR will
be updated.


# Releases
## @ariakit/core@0.2.6

### Patch Changes

- Fixed `defaultItems` passed to the collection store being overriden
when new items are added.
([#2559](#2559))

## @ariakit/react@0.2.10

### Patch Changes

- Fixed `defaultItems` passed to the collection store being overriden
when new items are added.
([#2559](#2559))

- Fixed `Combobox` with the `autoSelect` prop not allowing the user to
scroll when the list of items is virtualized.
([#2562](#2562))

- Fixed `Composite` not moving focus to items by pressing the arrow keys
when the active item isn't rendered.
([#2561](#2561))

- Fixed `CompositeItem` not being tabbable before hydration.
([#2565](#2565))

-   Updated dependencies: `@ariakit/react-core@0.2.10`.

## @ariakit/react-core@0.2.10

### Patch Changes

- Fixed `defaultItems` passed to the collection store being overriden
when new items are added.
([#2559](#2559))

- Fixed `Combobox` with the `autoSelect` prop not allowing the user to
scroll when the list of items is virtualized.
([#2562](#2562))

- Fixed `Composite` not moving focus to items by pressing the arrow keys
when the active item isn't rendered.
([#2561](#2561))

- Fixed `CompositeItem` not being tabbable before hydration.
([#2565](#2565))

-   Updated dependencies: `@ariakit/core@0.2.6`.

## @ariakit/test@0.1.14

### Patch Changes

-   Updated dependencies: `@ariakit/core@0.2.6`.

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant