@strapi/ui-primitives 2.0.0 → 2.0.2

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.
@@ -1,10 +1,10 @@
1
+ import { Slot } from '@radix-ui/react-slot';
1
2
  /**
2
3
  * An internal fork of Radix UI's `Collection` component.
3
4
  *
4
5
  * We've added a subscription API to allow us to subscribe to changes in the collection via the useCollection hook.
5
6
  */
6
7
  import * as React from 'react';
7
- import { Slot } from '@radix-ui/react-slot';
8
8
  import type * as Radix from '@radix-ui/react-primitive';
9
9
  type SlotProps = Radix.ComponentPropsWithoutRef<typeof Slot>;
10
10
  interface CollectionProps extends SlotProps {
@@ -33,6 +33,6 @@ declare function createCollection<ItemElement extends HTMLElement, ItemData = ob
33
33
  } & ItemData)[], prevState: ({
34
34
  ref: React.RefObject<ItemElement>;
35
35
  } & ItemData)[]) => void) => () => boolean;
36
- }, import("@radix-ui/react-context").CreateScope];
36
+ }, import('@radix-ui/react-context').CreateScope];
37
37
  export { createCollection };
38
38
  export type { CollectionProps, CollectionProviderProps };
@@ -1,9 +1,8 @@
1
- import * as React from 'react';
2
1
  import { DismissableLayer } from '@radix-ui/react-dismissable-layer';
3
- import * as PopperPrimitive from '@radix-ui/react-popper';
4
2
  import { Portal as PortalPrimitive } from '@radix-ui/react-portal';
5
- import { Primitive } from '@radix-ui/react-primitive';
6
- import type { ComponentPropsWithoutRef } from '@radix-ui/react-primitive';
3
+ import { Primitive, ComponentPropsWithoutRef } from '@radix-ui/react-primitive';
4
+ import * as React from 'react';
5
+ import * as PopperPrimitive from '@radix-ui/react-popper';
7
6
  type AutocompleteObject = {
8
7
  type: 'none';
9
8
  filter?: never;
@@ -0,0 +1 @@
1
+ export {};
@@ -1,6 +1,5 @@
1
+ import { Primitive, ComponentPropsWithoutRef } from '@radix-ui/react-primitive';
1
2
  import * as React from 'react';
2
- import { Primitive } from '@radix-ui/react-primitive';
3
- import type { ComponentPropsWithoutRef } from '@radix-ui/react-primitive';
4
3
  /**
5
4
  * VirtualizedViewport - Renders only visible items for performance optimization
6
5
  * Used when Combobox/Select has many items (>100)
@@ -1,3 +1,8 @@
1
+ import { DismissableLayer } from '@radix-ui/react-dismissable-layer';
2
+ import { FocusScope } from '@radix-ui/react-focus-scope';
3
+ import { Portal as PortalPrimitive } from '@radix-ui/react-portal';
4
+ import { Primitive } from '@radix-ui/react-primitive';
5
+ import { Scope } from '@radix-ui/react-context';
1
6
  /**
2
7
  * We've forked this from RadixUI to add primarily support for multi-select.
3
8
  * This is on their roadmap – https://github.com/radix-ui/primitives/issues/1193
@@ -12,18 +17,13 @@
12
17
  * Hopefully in the future we can remove this fork ✌🏼
13
18
  */
14
19
  import * as React from 'react';
15
- import { DismissableLayer } from '@radix-ui/react-dismissable-layer';
16
- import { FocusScope } from '@radix-ui/react-focus-scope';
17
20
  import * as PopperPrimitive from '@radix-ui/react-popper';
18
- import { Portal as PortalPrimitive } from '@radix-ui/react-portal';
19
- import { Primitive } from '@radix-ui/react-primitive';
20
- import type { Scope } from '@radix-ui/react-context';
21
21
  import type * as Radix from '@radix-ui/react-primitive';
22
22
  type Direction = 'ltr' | 'rtl';
23
23
  type ScopedProps<P> = P & {
24
24
  __scopeSelect?: Scope;
25
25
  };
26
- declare const createSelectScope: import("@radix-ui/react-context").CreateScope;
26
+ declare const createSelectScope: import('@radix-ui/react-context').CreateScope;
27
27
  interface SharedSelectProps {
28
28
  children?: React.ReactNode;
29
29
  open?: boolean;
@@ -0,0 +1 @@
1
+ export {};