Skip to content

Commit

Permalink
fix: add readonly to collection
Browse files Browse the repository at this point in the history
  • Loading branch information
segunadebayo committed Sep 15, 2023
1 parent 195473b commit c280490
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/fuzzy-moose-divide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@zag-js/collection": patch
---

Add support for readonly items in collection type
2 changes: 1 addition & 1 deletion packages/utilities/collection/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export interface CollectionOptions<T extends CollectionItem = CollectionItem> {
/**
* The options of the select
*/
items: T[]
items: T[] | readonly T[]
/**
* The value of the item
*/
Expand Down

4 comments on commit c280490

@vercel
Copy link

@vercel vercel bot commented on c280490 Sep 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

zag-nextjs – ./examples/next-ts

zag-two.vercel.app
zag-nextjs-chakra-ui.vercel.app
zag-nextjs-git-main-chakra-ui.vercel.app

@vercel
Copy link

@vercel vercel bot commented on c280490 Sep 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

zag-solid – ./examples/solid-ts

zag-solid-git-main-chakra-ui.vercel.app
zag-solid-chakra-ui.vercel.app
zag-solid.vercel.app

@vercel
Copy link

@vercel vercel bot commented on c280490 Sep 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

zag-vue – ./examples/vue-ts

zag-vue-chakra-ui.vercel.app
zag-vue-git-main-chakra-ui.vercel.app
zag-vue.vercel.app

@vercel
Copy link

@vercel vercel bot commented on c280490 Sep 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.