({props, collection, gridListRef: ref}: GridListInnerProps<T>)
| 241 | } |
| 242 | |
| 243 | function GridListInner<T>({props, collection, gridListRef: ref}: GridListInnerProps<T>) { |
| 244 | [props, ref] = useContextProps(props, ref, SelectableCollectionContext); |
| 245 | let { |
| 246 | // eslint-disable-next-line @typescript-eslint/no-unused-vars |
| 247 | shouldUseVirtualFocus, |
| 248 | filter, |
| 249 | disallowTypeAhead, |
| 250 | UNSTABLE_focusOnEntry, |
| 251 | ...DOMCollectionProps |
| 252 | } = props; |
| 253 | let { |
| 254 | dragAndDropHooks, |
| 255 | keyboardNavigationBehavior = 'arrow', |
| 256 | layout = 'stack', |
| 257 | orientation = 'vertical' |
| 258 | } = props; |
| 259 | let { |
| 260 | CollectionRoot, |
| 261 | isVirtualized, |
| 262 | layoutDelegate, |
| 263 | dropTargetDelegate: ctxDropTargetDelegate |
| 264 | } = useContext(CollectionRendererContext); |
| 265 | let gridlistState = useListState({ |
| 266 | ...DOMCollectionProps, |
| 267 | collection, |
| 268 | children: undefined, |
| 269 | layoutDelegate |
| 270 | }); |
| 271 | |
| 272 | let filteredState = UNSTABLE_useFilteredListState(gridlistState as ListState<T>, filter); |
| 273 | let collator = useCollator({usage: 'search', sensitivity: 'base'}); |
| 274 | let {disabledBehavior, disabledKeys} = filteredState.selectionManager; |
| 275 | let {direction} = useLocale(); |
| 276 | let keyboardDelegate = useMemo( |
| 277 | () => |
| 278 | new ListKeyboardDelegate({ |
| 279 | collection: filteredState.collection, |
| 280 | collator, |
| 281 | ref, |
| 282 | disabledKeys, |
| 283 | disabledBehavior, |
| 284 | layoutDelegate, |
| 285 | layout, |
| 286 | orientation, |
| 287 | direction |
| 288 | }), |
| 289 | [ |
| 290 | filteredState.collection, |
| 291 | ref, |
| 292 | layout, |
| 293 | orientation, |
| 294 | disabledKeys, |
| 295 | disabledBehavior, |
| 296 | layoutDelegate, |
| 297 | collator, |
| 298 | direction |
| 299 | ] |
| 300 | ); |
nothing calls this directly
no test coverage detected