@react-types/shared 3.0.0-nightly.2060 → 3.0.0-nightly.2068

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-types/shared",
3
- "version": "3.0.0-nightly.2060+bd5adc8a8",
3
+ "version": "3.0.0-nightly.2068+536f42d9f",
4
4
  "description": "Spectrum UI components in React",
5
5
  "license": "Apache-2.0",
6
6
  "types": "src/index.d.ts",
@@ -14,5 +14,5 @@
14
14
  "publishConfig": {
15
15
  "access": "public"
16
16
  },
17
- "gitHead": "bd5adc8a81623b6727fdc0521f47f9baa04517bb"
17
+ "gitHead": "536f42d9fef70d1ac060e774354b803e9af70b8c"
18
18
  }
@@ -133,10 +133,10 @@ export interface Collection<T> extends Iterable<T> {
133
133
  getKeys(): Iterable<Key>,
134
134
 
135
135
  /** Get an item by its key. */
136
- getItem(key: Key): T,
136
+ getItem(key: Key): T | null,
137
137
 
138
138
  /** Get an item by the index of its key. */
139
- at(idx: number): T,
139
+ at(idx: number): T | null,
140
140
 
141
141
  /** Get the key that comes before the given key in the collection. */
142
142
  getKeyBefore(key: Key): Key | null,
@@ -160,7 +160,7 @@ export interface Node<T> {
160
160
  /** A unique key for the node. */
161
161
  key: Key,
162
162
  /** The object value the node was created from. */
163
- value: T,
163
+ value: T | null,
164
164
  /** The level of depth this node is at in the heirarchy. */
165
165
  level: number,
166
166
  /** Whether this item has children, even if not loaded yet. */
@@ -181,11 +181,11 @@ export interface Node<T> {
181
181
  /** A function that should be called to wrap the rendered node. */
182
182
  wrapper?: (element: ReactElement) => ReactElement,
183
183
  /** The key of the parent node. */
184
- parentKey?: Key,
184
+ parentKey?: Key | null,
185
185
  /** The key of the node before this node. */
186
- prevKey?: Key,
186
+ prevKey?: Key | null,
187
187
  /** The key of the node after this node. */
188
- nextKey?: Key,
188
+ nextKey?: Key | null,
189
189
  /** Additional properties specific to a particular node type. */
190
190
  props?: any,
191
191
  /** @private */