@impulse-ui-native/toolkit 2.3.5 → 2.4.0

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/README.md CHANGED
@@ -66,7 +66,9 @@ import { SafeAreaProvider } from "react-native-safe-area-context";
66
66
  import { Stack } from "expo-router";
67
67
 
68
68
  import {
69
- LayerCenter,
69
+ OverlayHost,
70
+ OverlayProvider,
71
+ OverlayStore,
70
72
  PortalProvider,
71
73
  PortalsHost,
72
74
  PortalStore,
@@ -74,17 +76,20 @@ import {
74
76
  } from "@impulse-ui-native/toolkit";
75
77
 
76
78
  const portalStore = new PortalStore();
79
+ const overlayStore = new OverlayStore();
77
80
 
78
81
  export default function RootLayout() {
79
82
  return (
80
83
  <GestureHandlerRootView style={{ flex: 1 }}>
81
84
  <SafeAreaProvider>
82
85
  <ThemeProvider>
83
- <PortalProvider store={portalStore}>
84
- <Stack />
85
- <LayerCenter />
86
- <PortalsHost />
87
- </PortalProvider>
86
+ <OverlayProvider store={overlayStore}>
87
+ <PortalProvider store={portalStore}>
88
+ <Stack />
89
+ <OverlayHost />
90
+ <PortalsHost />
91
+ </PortalProvider>
92
+ </OverlayProvider>
88
93
  </ThemeProvider>
89
94
  </SafeAreaProvider>
90
95
  </GestureHandlerRootView>
@@ -92,18 +97,19 @@ export default function RootLayout() {
92
97
  }
93
98
  ```
94
99
 
95
- Keep `portalStore` outside the component so the same store survives every render. In an application that does not use Expo Router, replace `<Stack />` with your navigator or root application content and keep the surrounding hierarchy unchanged.
100
+ Keep `overlayStore` and `portalStore` outside the component so the same stores survive every render. In an application that does not use Expo Router, replace `<Stack />` with your navigator or root application content and keep the surrounding hierarchy unchanged.
96
101
 
97
102
  | Root element | Purpose |
98
103
  | ------------------------ | ------------------------------------------------------------------------ |
99
104
  | `GestureHandlerRootView` | Enables native gesture handling for flyouts and gesture-driven controls. |
100
105
  | `SafeAreaProvider` | Supplies safe-area measurements to primitives and overlays. |
101
106
  | `ThemeProvider` | Supplies primitive, semantic, and component design tokens. |
107
+ | `OverlayProvider` | Connects imperative overlays to the stable `OverlayStore`. |
102
108
  | `PortalProvider` | Connects the tree to the stable `PortalStore`. |
103
- | `LayerCenter` | Renders flyouts registered through the app-wide layer registry. |
109
+ | `OverlayHost` | Renders components registered through the app-wide overlay store. |
104
110
  | `PortalsHost` | Renders content sent to the default portal host. |
105
111
 
106
- `LayerCenter` and `PortalsHost` should be siblings of the navigator and children of `PortalProvider`. Mount only one of each at the root.
112
+ `OverlayHost` and `PortalsHost` should be siblings of the navigator and children of their matching providers. Mount only one of each at the root.
107
113
 
108
114
  ## Basic usage
109
115
 
@@ -136,7 +142,7 @@ export function SignInForm() {
136
142
 
137
143
  ## Selects and flyouts
138
144
 
139
- `Select`, `MultiSelect`, and the date/time pickers use the root `LayerCenter`. Once the application setup above is in place, a select can be rendered anywhere below it:
145
+ `Select`, `MultiSelect`, and the date/time pickers use the root `PortalsHost`. Once the application setup above is in place, a select can be rendered anywhere below it:
140
146
 
141
147
  ```tsx
142
148
  import { useState } from "react";
@@ -164,7 +170,7 @@ export function DepartmentField() {
164
170
  }
165
171
  ```
166
172
 
167
- Do not mount another `LayerCenter` beside the control; registered overlays are rendered by the single application-level instance.
173
+ Do not mount another host beside the control; portal content and registered overlays are rendered by the application-level `PortalsHost` and `OverlayHost`.
168
174
 
169
175
  ## Theming
170
176
 
@@ -198,7 +204,7 @@ Theme overrides are deep partials. Hooks including `useTheme`, `useColors`, `use
198
204
  - Date and time: `DatePicker`, `DateRangePicker`, `DatetimePicker`, `DatetimeRangePicker`, and `TimePicker`.
199
205
  - Charts: line, bar, pie, multi-series chart components, axes, grids, labels, hooks, and utilities.
200
206
  - Feedback: `Skeleton`, `DataView`, `LoadingView`, `EmptyView`, and `ErrorView`.
201
- - Navigation and overlays: `Stepper`, `Flyout`, `LayerCenter`, the flyout registry, `Portal`, `PortalProvider`, `PortalStore`, and portal hosts.
207
+ - Navigation and overlays: `Stepper`, `Flyout`, `OverlayHost`, `OverlayProvider`, `OverlayStore`, overlay registration types, `Portal`, `PortalProvider`, `PortalStore`, and portal hosts.
202
208
  - Data utilities: `EchoInstance`, echo hooks, and typed Axios/TanStack Query endpoint factories.
203
209
 
204
210
  ## Icons
@@ -223,7 +229,7 @@ The toolkit uses ES modules and declares itself side-effect free, allowing compa
223
229
  ## Troubleshooting
224
230
 
225
231
  - If gestures do not respond, verify that `GestureHandlerRootView` is the outermost application view and has `flex: 1`.
226
- - If a select or registered flyout does not appear, verify that one `LayerCenter` is mounted inside the root providers.
232
+ - If a registered flyout does not appear, verify that one `OverlayHost` is mounted inside the matching `OverlayProvider`.
227
233
  - If portal content does not appear, verify that `PortalProvider` and `PortalsHost` use the same stable store and host name.
228
234
  - If content overlaps a notch or system bar, verify that `SafeAreaProvider` wraps the themed application.
229
235
  - If a native dependency was just installed, rebuild the native application rather than relying only on a JavaScript refresh.
package/dist/index.d.mts CHANGED
@@ -1,6 +1,6 @@
1
1
  export * from '@impulse-ui-native/core';
2
2
  export * from '@impulse-ui-native/theme';
3
- export * from '@impulse-ui-native/layers';
3
+ export * from '@impulse-ui-native/overlay';
4
4
  export * from '@impulse-ui-native/portal';
5
5
  export * from '@impulse-ui-native/charts';
6
6
  export * from '@impulse-ui-native/primitives';
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  export * from "@impulse-ui-native/core";
2
2
  export * from "@impulse-ui-native/theme";
3
- export * from "@impulse-ui-native/layers";
3
+ export * from "@impulse-ui-native/overlay";
4
4
  export * from "@impulse-ui-native/portal";
5
5
  export * from "@impulse-ui-native/charts";
6
6
  export * from "@impulse-ui-native/primitives";
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"sourcesContent":["// Core foundation\nexport * from \"@impulse-ui-native/core\";\nexport * from \"@impulse-ui-native/theme\";\n\n// Layout & containers\nexport * from \"@impulse-ui-native/layers\";\nexport * from \"@impulse-ui-native/portal\";\n\n// Components\nexport * from \"@impulse-ui-native/charts\";\nexport * from \"@impulse-ui-native/primitives\";\nexport * from \"@impulse-ui-native/flyout\";\nexport * from \"@impulse-ui-native/input\";\nexport * from \"@impulse-ui-native/stepper\";\nexport * from \"@impulse-ui-native/data-state\";\nexport * from \"@impulse-ui-native/skeleton\";\nexport * from \"@impulse-ui-native/select\";\nexport * from \"@impulse-ui-native/datetime\";\n\n// Utilities\nexport * from \"@impulse-ui-native/echo\";\nexport * from \"@impulse-ui-native/endpoint\";\n\n// Types\nexport * from \"@impulse-ui-native/types\";\n"],"mappings":"AACA,cAAc;AACd,cAAc;AAGd,cAAc;AACd,cAAc;AAGd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AAGd,cAAc;AACd,cAAc;AAGd,cAAc;","names":[]}
1
+ {"version":3,"sources":["../src/index.ts"],"sourcesContent":["// Core foundation\nexport * from \"@impulse-ui-native/core\";\nexport * from \"@impulse-ui-native/theme\";\n\n// Layout & containers\nexport * from \"@impulse-ui-native/overlay\";\nexport * from \"@impulse-ui-native/portal\";\n\n// Components\nexport * from \"@impulse-ui-native/charts\";\nexport * from \"@impulse-ui-native/primitives\";\nexport * from \"@impulse-ui-native/flyout\";\nexport * from \"@impulse-ui-native/input\";\nexport * from \"@impulse-ui-native/stepper\";\nexport * from \"@impulse-ui-native/data-state\";\nexport * from \"@impulse-ui-native/skeleton\";\nexport * from \"@impulse-ui-native/select\";\nexport * from \"@impulse-ui-native/datetime\";\n\n// Utilities\nexport * from \"@impulse-ui-native/echo\";\nexport * from \"@impulse-ui-native/endpoint\";\n\n// Types\nexport * from \"@impulse-ui-native/types\";\n"],"mappings":"AACA,cAAc;AACd,cAAc;AAGd,cAAc;AACd,cAAc;AAGd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AACd,cAAc;AAGd,cAAc;AACd,cAAc;AAGd,cAAc;","names":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@impulse-ui-native/toolkit",
3
- "version": "2.3.5",
3
+ "version": "2.4.0",
4
4
  "description": "The complete ImpulseUI Native component toolkit for building React Native applications.",
5
5
  "keywords": [
6
6
  "react-native",
@@ -28,22 +28,22 @@
28
28
  ],
29
29
  "sideEffects": false,
30
30
  "dependencies": {
31
- "@impulse-ui-native/echo": "2.3.5",
32
- "@impulse-ui-native/core": "2.3.5",
33
- "@impulse-ui-native/charts": "2.3.5",
34
- "@impulse-ui-native/endpoint": "2.3.5",
35
- "@impulse-ui-native/flyout": "2.3.5",
36
- "@impulse-ui-native/stepper": "2.3.5",
37
- "@impulse-ui-native/input": "2.3.5",
38
- "@impulse-ui-native/layers": "2.3.5",
39
- "@impulse-ui-native/types": "2.3.5",
40
- "@impulse-ui-native/theme": "2.3.5",
41
- "@impulse-ui-native/primitives": "2.3.5",
42
- "@impulse-ui-native/data-state": "2.3.5",
43
- "@impulse-ui-native/select": "2.3.5",
44
- "@impulse-ui-native/portal": "2.3.5",
45
- "@impulse-ui-native/skeleton": "2.3.5",
46
- "@impulse-ui-native/datetime": "2.3.5"
31
+ "@impulse-ui-native/core": "2.4.0",
32
+ "@impulse-ui-native/flyout": "2.4.0",
33
+ "@impulse-ui-native/echo": "2.4.0",
34
+ "@impulse-ui-native/stepper": "2.4.0",
35
+ "@impulse-ui-native/charts": "2.4.0",
36
+ "@impulse-ui-native/overlay": "2.4.0",
37
+ "@impulse-ui-native/types": "2.4.0",
38
+ "@impulse-ui-native/theme": "2.4.0",
39
+ "@impulse-ui-native/input": "2.4.0",
40
+ "@impulse-ui-native/primitives": "2.4.0",
41
+ "@impulse-ui-native/select": "2.4.0",
42
+ "@impulse-ui-native/endpoint": "2.4.0",
43
+ "@impulse-ui-native/data-state": "2.4.0",
44
+ "@impulse-ui-native/skeleton": "2.4.0",
45
+ "@impulse-ui-native/portal": "2.4.0",
46
+ "@impulse-ui-native/datetime": "2.4.0"
47
47
  },
48
48
  "devDependencies": {
49
49
  "@types/react": "~19.2.14",