@hanzogui/sheet 2.0.0 → 2.0.4

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,4 +1,4 @@
1
- // Type declarations for @hanzogui/sheet/controller path resolution
1
+ // Type declarations for @hanzo/gui-sheet/controller path resolution
2
2
  // Runtime uses exports field -> dist/esm/controller.mjs
3
3
 
4
4
  export { SheetController } from '../src/SheetController'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hanzogui/sheet",
3
- "version": "2.0.0",
3
+ "version": "2.0.4",
4
4
  "license": "MIT",
5
5
  "source": "src/index.ts",
6
6
  "type": "module",
@@ -56,27 +56,27 @@
56
56
  "clean": "hanzo-gui-build clean"
57
57
  },
58
58
  "dependencies": {
59
- "@hanzogui/adapt": "2.0.0",
60
- "@hanzogui/animate-presence": "2.0.0",
61
- "@hanzogui/animations-react-native": "2.0.0-rc.29",
62
- "@hanzogui/compose-refs": "2.0.0-rc.29",
63
- "@hanzogui/constants": "2.0.0-rc.29",
64
- "@hanzogui/core": "2.0.0-rc.29",
65
- "@hanzogui/create-context": "2.0.0-rc.29",
66
- "@hanzogui/helpers": "2.0.0-rc.29",
67
- "@hanzogui/native": "2.0.0-rc.29",
68
- "@hanzogui/portal": "2.0.0",
69
- "@hanzogui/remove-scroll": "2.0.0",
70
- "@hanzogui/scroll-view": "2.0.0",
71
- "@hanzogui/stacks": "2.0.0",
72
- "@hanzogui/use-constant": "2.0.0-rc.29",
73
- "@hanzogui/use-controllable-state": "2.0.0-rc.29",
74
- "@hanzogui/use-did-finish-ssr": "2.0.0-rc.29",
75
- "@hanzogui/use-keyboard-visible": "2.0.0-rc.29",
76
- "@hanzogui/z-index-stack": "2.0.0"
59
+ "@hanzogui/adapt": "2.0.1",
60
+ "@hanzogui/animate-presence": "2.0.1",
61
+ "@hanzogui/animations-react-native": "2.0.1",
62
+ "@hanzogui/compose-refs": "2.0.1",
63
+ "@hanzogui/constants": "2.0.1",
64
+ "@hanzogui/core": "2.0.1",
65
+ "@hanzogui/create-context": "2.0.1",
66
+ "@hanzogui/helpers": "2.0.1",
67
+ "@hanzogui/native": "2.0.1",
68
+ "@hanzogui/portal": "2.0.1",
69
+ "@hanzogui/remove-scroll": "2.0.1",
70
+ "@hanzogui/scroll-view": "2.0.1",
71
+ "@hanzogui/stacks": "2.0.1",
72
+ "@hanzogui/use-constant": "2.0.1",
73
+ "@hanzogui/use-controllable-state": "2.0.1",
74
+ "@hanzogui/use-did-finish-ssr": "2.0.1",
75
+ "@hanzogui/use-keyboard-visible": "2.0.1",
76
+ "@hanzogui/z-index-stack": "2.0.1"
77
77
  },
78
78
  "devDependencies": {
79
- "@hanzogui/build": "2.0.0-rc.29",
79
+ "@hanzogui/build": "2.0.1",
80
80
  "react": ">=19",
81
81
  "react-native": "0.83.2",
82
82
  "react-native-gesture-handler": "~2.30.0"
package/src/Sheet.tsx CHANGED
@@ -1,5 +1,5 @@
1
- import { styled } from '@hanzogui/core'
2
- import { XStack, YStack } from '@hanzogui/stacks'
1
+ import { styled } from '@hanzo/gui-core'
2
+ import { XStack, YStack } from '@hanzo/gui-stacks'
3
3
 
4
4
  import { SHEET_HANDLE_NAME, SHEET_NAME, SHEET_OVERLAY_NAME } from './constants'
5
5
  import { createSheet } from './createSheet'
@@ -1,4 +1,4 @@
1
- import { createContextScope } from '@hanzogui/create-context'
1
+ import { createContextScope } from '@hanzo/gui-create-context'
2
2
 
3
3
  import { SHEET_NAME } from './constants'
4
4
  import type { SheetContextValue } from './useSheetProviderProps'
@@ -1,5 +1,5 @@
1
1
  import React, { useId, useRef } from 'react'
2
- import { useEvent } from '@hanzogui/core'
2
+ import { useEvent } from '@hanzo/gui-core'
3
3
  import type { ReactNode } from 'react'
4
4
 
5
5
  import type { SheetControllerContextValue } from './useSheetController'
@@ -1,7 +1,7 @@
1
- import { ProvideAdaptContext, useAdaptContext } from '@hanzogui/adapt'
2
- import { AnimatePresence } from '@hanzogui/animate-presence'
3
- import { useComposedRefs } from '@hanzogui/compose-refs'
4
- import { isWeb, useIsomorphicLayoutEffect } from '@hanzogui/constants'
1
+ import { ProvideAdaptContext, useAdaptContext } from '@hanzo/gui-adapt'
2
+ import { AnimatePresence } from '@hanzo/gui-animate-presence'
3
+ import { useComposedRefs } from '@hanzo/gui-compose-refs'
4
+ import { isWeb, useIsomorphicLayoutEffect } from '@hanzo/gui-constants'
5
5
  import {
6
6
  LayoutMeasurementController,
7
7
  View as GuiView,
@@ -9,9 +9,9 @@ import {
9
9
  useDidFinishSSR,
10
10
  useEvent,
11
11
  useThemeName,
12
- } from '@hanzogui/core'
13
- import { getSafeArea } from '@hanzogui/native'
14
- import { needsPortalRepropagation, Portal } from '@hanzogui/portal'
12
+ } from '@hanzo/gui-core'
13
+ import { getSafeArea } from '@hanzo/gui-native'
14
+ import { needsPortalRepropagation, Portal } from '@hanzo/gui-portal'
15
15
  import React, { useState } from 'react'
16
16
  import type {
17
17
  Animated,
@@ -37,7 +37,7 @@ const hiddenSize = 10_000.1
37
37
  let _cachedSafeAreaTop: number | undefined
38
38
  function getSafeAreaTopInset(): number {
39
39
  if (_cachedSafeAreaTop !== undefined) return _cachedSafeAreaTop
40
- // use @hanzogui/native abstraction - returns 0 when not enabled
40
+ // use @hanzo/gui-native abstraction - returns 0 when not enabled
41
41
  _cachedSafeAreaTop = getSafeArea().getInsets().top
42
42
  return _cachedSafeAreaTop
43
43
  }
@@ -1,8 +1,8 @@
1
- import { composeRefs } from '@hanzogui/compose-refs'
2
- import { isWeb, View, type GetRef } from '@hanzogui/core'
3
- import type { ScrollViewProps } from '@hanzogui/scroll-view'
4
- import { ScrollView } from '@hanzogui/scroll-view'
5
- import { useControllableState } from '@hanzogui/use-controllable-state'
1
+ import { composeRefs } from '@hanzo/gui-compose-refs'
2
+ import { isWeb, View, type GetRef } from '@hanzo/gui-core'
3
+ import type { ScrollViewProps } from '@hanzo/gui-scroll-view'
4
+ import { ScrollView } from '@hanzo/gui-scroll-view'
5
+ import { useControllableState } from '@hanzo/gui-use-controllable-state'
6
6
  import React, { useEffect, useRef, useState } from 'react'
7
7
  import type { ScrollView as RNScrollView } from 'react-native'
8
8
  import { useGestureSheetContext } from './GestureSheetContext'
@@ -1,18 +1,18 @@
1
- import { useComposedRefs } from '@hanzogui/compose-refs'
2
- import { useIsomorphicLayoutEffect } from '@hanzogui/constants'
1
+ import { useComposedRefs } from '@hanzo/gui-compose-refs'
2
+ import { useIsomorphicLayoutEffect } from '@hanzo/gui-constants'
3
3
  import type {
4
4
  GetProps,
5
5
  ViewProps,
6
6
  GuiComponent,
7
7
  GuiComponentExpectingVariants,
8
8
  GuiElement,
9
- } from '@hanzogui/core'
10
- import { View } from '@hanzogui/core'
11
- import { composeEventHandlers, withStaticProperties } from '@hanzogui/helpers'
12
- import { resolveViewZIndex } from '@hanzogui/portal'
13
- import { RemoveScroll } from '@hanzogui/remove-scroll'
14
- import { useDidFinishSSR } from '@hanzogui/use-did-finish-ssr'
15
- import { StackZIndexContext } from '@hanzogui/z-index-stack'
9
+ } from '@hanzo/gui-core'
10
+ import { View } from '@hanzo/gui-core'
11
+ import { composeEventHandlers, withStaticProperties } from '@hanzo/gui-helpers'
12
+ import { resolveViewZIndex } from '@hanzo/gui-portal'
13
+ import { RemoveScroll } from '@hanzo/gui-remove-scroll'
14
+ import { useDidFinishSSR } from '@hanzo/gui-use-did-finish-ssr'
15
+ import { StackZIndexContext } from '@hanzo/gui-z-index-stack'
16
16
  import type { ForwardRefExoticComponent, FunctionComponent, RefAttributes } from 'react'
17
17
  import { forwardRef, memo, useMemo, useEffect, useRef } from 'react'
18
18
  import type { View as RNView } from 'react-native'
@@ -1,11 +1,11 @@
1
1
  /**
2
- * Re-export gesture state from @hanzogui/native.
2
+ * Re-export gesture state from @hanzo/gui-native.
3
3
  * Sheet uses this for backward compatibility with existing code.
4
4
  */
5
5
 
6
- import { getGestureHandler, type GestureState } from '@hanzogui/native'
6
+ import { getGestureHandler, type GestureState } from '@hanzo/gui-native'
7
7
 
8
- export type { GestureState as GestureHandlerState } from '@hanzogui/native'
8
+ export type { GestureState as GestureHandlerState } from '@hanzo/gui-native'
9
9
 
10
10
  // backward compat helpers
11
11
  export function isGestureHandlerEnabled(): boolean {
@@ -1,4 +1,4 @@
1
- import { YStack } from '@hanzogui/stacks'
1
+ import { YStack } from '@hanzo/gui-stacks'
2
2
  import type { FunctionComponent } from 'react'
3
3
  import { useEffect, useRef } from 'react'
4
4
  import { View } from 'react-native'
@@ -1,8 +1,8 @@
1
1
  /**
2
- * Legacy setup - prefer `import '@hanzogui/native/setup-gesture-handler'` instead.
2
+ * Legacy setup - prefer `import '@hanzo/gui-native/setup-gesture-handler'` instead.
3
3
  */
4
4
 
5
- import { getGestureHandler } from '@hanzogui/native'
5
+ import { getGestureHandler } from '@hanzo/gui-native'
6
6
 
7
7
  export function isGestureHandlerEnabled(): boolean {
8
8
  return getGestureHandler().isEnabled
package/src/types.tsx CHANGED
@@ -1,7 +1,7 @@
1
- import type { AnimatedNumberStrategy, TransitionProp } from '@hanzogui/core'
2
- import type { ScopedProps } from '@hanzogui/create-context'
3
- import type { PortalProps } from '@hanzogui/portal'
4
- import type { RemoveScroll } from '@hanzogui/remove-scroll'
1
+ import type { AnimatedNumberStrategy, TransitionProp } from '@hanzo/gui-core'
2
+ import type { ScopedProps } from '@hanzo/gui-create-context'
3
+ import type { PortalProps } from '@hanzo/gui-portal'
4
+ import type { RemoveScroll } from '@hanzo/gui-remove-scroll'
5
5
  import type { ReactNode } from 'react'
6
6
  import type React from 'react'
7
7
 
@@ -21,11 +21,11 @@ let isKeyboardControllerEnabled: () => boolean = () => false
21
21
  let getKeyboardControllerState: () => any = () => ({})
22
22
 
23
23
  try {
24
- const nativeModule = require('@hanzogui/native')
24
+ const nativeModule = require('@hanzo/gui-native')
25
25
  isKeyboardControllerEnabled = nativeModule.isKeyboardControllerEnabled
26
26
  getKeyboardControllerState = nativeModule.getKeyboardControllerState
27
27
  } catch {
28
- // @hanzogui/native not available
28
+ // @hanzo/gui-native not available
29
29
  }
30
30
 
31
31
  export function useKeyboardControllerSheet(
@@ -1,4 +1,4 @@
1
- import { useControllableState } from '@hanzogui/use-controllable-state'
1
+ import { useControllableState } from '@hanzo/gui-use-controllable-state'
2
2
 
3
3
  import type { SheetProps } from './types'
4
4
  import { useSheetController } from './useSheetController'
@@ -1,8 +1,8 @@
1
1
  import React from 'react'
2
- import type { GuiElement } from '@hanzogui/core'
3
- import { useConfiguration } from '@hanzogui/core'
4
- import { useConstant } from '@hanzogui/use-constant'
5
- import { useControllableState } from '@hanzogui/use-controllable-state'
2
+ import type { GuiElement } from '@hanzo/gui-core'
3
+ import { useConfiguration } from '@hanzo/gui-core'
4
+ import { useConstant } from '@hanzo/gui-use-constant'
5
+ import { useControllableState } from '@hanzo/gui-use-controllable-state'
6
6
 
7
7
  import type { ScrollBridge, SheetProps } from './types'
8
8
  import type { SheetOpenState } from './useSheetOpenState'