react-native-unistyles 2.10.0 → 3.0.0-alpha.1
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +1 -1
- package/android/CMakeLists.txt +35 -17
- package/android/build.gradle +4 -2
- package/android/src/main/cxx/cpp-adapter.cpp +82 -65
- package/android/src/main/java/com/unistyles/UnistylesPackage.kt +19 -9
- package/cxx/common/Breakpoints.h +43 -0
- package/cxx/common/Constants.h +10 -0
- package/cxx/common/Helpers.h +93 -0
- package/cxx/core/HostStyle.cpp +57 -0
- package/cxx/core/HostStyle.h +25 -0
- package/cxx/core/MediaQueries.cpp +87 -0
- package/cxx/core/MediaQueries.h +47 -0
- package/cxx/core/StyleSheet.h +32 -0
- package/cxx/core/StyleSheetRegistry.cpp +45 -0
- package/cxx/core/StyleSheetRegistry.h +26 -0
- package/cxx/core/Unistyle.h +81 -0
- package/cxx/core/UnistyleWrapper.cpp +5 -0
- package/cxx/core/UnistyleWrapper.h +50 -0
- package/cxx/core/UnistylesCommitHook.cpp +53 -0
- package/cxx/core/UnistylesCommitHook.h +27 -0
- package/cxx/core/UnistylesCommitShadowNode.h +26 -0
- package/cxx/core/UnistylesRegistry.cpp +176 -0
- package/cxx/core/UnistylesRegistry.h +59 -0
- package/cxx/core/UnistylesState.cpp +95 -0
- package/cxx/core/UnistylesState.h +50 -0
- package/cxx/hybridObjects/HybridNavigationBar.cpp +17 -0
- package/cxx/hybridObjects/HybridNavigationBar.h +19 -0
- package/cxx/hybridObjects/HybridShadowRegistry.cpp +26 -0
- package/cxx/hybridObjects/HybridShadowRegistry.h +33 -0
- package/cxx/hybridObjects/HybridStatusBar.cpp +17 -0
- package/cxx/hybridObjects/HybridStatusBar.h +19 -0
- package/cxx/hybridObjects/HybridStyleSheet.cpp +245 -0
- package/cxx/hybridObjects/HybridStyleSheet.h +61 -0
- package/cxx/hybridObjects/HybridUnistylesRuntime.cpp +199 -0
- package/cxx/hybridObjects/HybridUnistylesRuntime.h +70 -0
- package/cxx/parser/Parser.cpp +714 -0
- package/cxx/parser/Parser.h +55 -0
- package/cxx/shadowTree/ShadowLeafUpdate.h +13 -0
- package/cxx/shadowTree/ShadowTreeManager.cpp +124 -0
- package/cxx/shadowTree/ShadowTreeManager.h +23 -0
- package/ios/Equatable.swift +64 -0
- package/ios/Extensions.swift +11 -0
- package/ios/NativePlatform+ios.swift +291 -0
- package/ios/NativePlatform.swift +17 -0
- package/ios/NativePlatformListener+ios.swift +41 -0
- package/ios/Unistyles.h +3 -0
- package/ios/UnistylesModuleOnLoad.h +11 -0
- package/ios/UnistylesModuleOnLoad.mm +51 -0
- package/lib/commonjs/common.js +1 -58
- package/lib/commonjs/common.js.map +1 -1
- package/lib/commonjs/index.js +27 -66
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/{utils/mq.js → mq.js} +12 -2
- package/lib/commonjs/mq.js.map +1 -0
- package/lib/commonjs/package.json +1 -0
- package/lib/commonjs/specs/NativePlatform/NativePlatform.nitro.js +25 -0
- package/lib/commonjs/specs/NativePlatform/NativePlatform.nitro.js.map +1 -0
- package/lib/commonjs/specs/NativePlatform/index.js +13 -0
- package/lib/commonjs/specs/NativePlatform/index.js.map +1 -0
- package/lib/commonjs/specs/NavigtionBar/UnistylesNavigationBar.nitro.js +6 -0
- package/lib/commonjs/specs/NavigtionBar/UnistylesNavigationBar.nitro.js.map +1 -0
- package/lib/commonjs/specs/NavigtionBar/index.js +17 -0
- package/lib/commonjs/specs/NavigtionBar/index.js.map +1 -0
- package/lib/commonjs/{types/plugin.js → specs/ShadowRegistry/ShadowRegistry.nitro.js} +1 -1
- package/lib/commonjs/specs/ShadowRegistry/ShadowRegistry.nitro.js.map +1 -0
- package/lib/commonjs/specs/ShadowRegistry/index.js +30 -0
- package/lib/commonjs/specs/ShadowRegistry/index.js.map +1 -0
- package/lib/commonjs/specs/ShadowRegistry/types.js +2 -0
- package/lib/commonjs/specs/ShadowRegistry/types.js.map +1 -0
- package/lib/commonjs/{types/normalizer.js → specs/StatusBar/UnistylesStatusBar.nitro.js} +1 -1
- package/lib/commonjs/specs/StatusBar/UnistylesStatusBar.nitro.js.map +1 -0
- package/lib/commonjs/specs/StatusBar/index.js +33 -0
- package/lib/commonjs/specs/StatusBar/index.js.map +1 -0
- package/lib/commonjs/specs/StyleSheet/UnistylesStyleSheet.nitro.js +6 -0
- package/lib/commonjs/specs/StyleSheet/UnistylesStyleSheet.nitro.js.map +1 -0
- package/lib/commonjs/specs/StyleSheet/index.js +18 -0
- package/lib/commonjs/specs/StyleSheet/index.js.map +1 -0
- package/lib/commonjs/specs/TurboUnistyles/NativeTurboUnistyles.js +8 -0
- package/lib/commonjs/specs/TurboUnistyles/NativeTurboUnistyles.js.map +1 -0
- package/lib/commonjs/specs/TurboUnistyles/index.js +4 -0
- package/lib/commonjs/specs/TurboUnistyles/index.js.map +1 -0
- package/lib/commonjs/{types/unistyles.js → specs/UnistylesRuntime/UnistylesRuntime.nitro.js} +1 -1
- package/lib/commonjs/specs/UnistylesRuntime/UnistylesRuntime.nitro.js.map +1 -0
- package/lib/commonjs/specs/UnistylesRuntime/index.js +26 -0
- package/lib/commonjs/specs/UnistylesRuntime/index.js.map +1 -0
- package/lib/commonjs/specs/index.js +47 -0
- package/lib/commonjs/specs/index.js.map +1 -0
- package/lib/commonjs/specs/index.web.js +24 -0
- package/lib/commonjs/specs/index.web.js.map +1 -0
- package/lib/commonjs/specs/types.js +24 -0
- package/lib/commonjs/specs/types.js.map +1 -0
- package/lib/commonjs/types/accessibility.js +37 -0
- package/lib/commonjs/types/accessibility.js.map +1 -0
- package/lib/commonjs/types/index.js +16 -30
- package/lib/commonjs/types/index.js.map +1 -1
- package/lib/commonjs/types/stylesheet.js +3 -0
- package/lib/commonjs/types/stylesheet.js.map +1 -1
- package/lib/commonjs/types/variants.js +4 -0
- package/lib/module/common.js +2 -56
- package/lib/module/common.js.map +1 -1
- package/lib/module/global.js +1 -1
- package/lib/module/index.js +12 -29
- package/lib/module/index.js.map +1 -1
- package/lib/module/{utils/mq.js → mq.js} +14 -2
- package/lib/module/mq.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/specs/NativePlatform/NativePlatform.nitro.js +23 -0
- package/lib/module/specs/NativePlatform/NativePlatform.nitro.js.map +1 -0
- package/lib/module/specs/NativePlatform/index.js +4 -0
- package/lib/module/specs/NativePlatform/index.js.map +1 -0
- package/lib/module/specs/NavigtionBar/UnistylesNavigationBar.nitro.js +4 -0
- package/lib/module/specs/NavigtionBar/UnistylesNavigationBar.nitro.js.map +1 -0
- package/lib/module/specs/NavigtionBar/index.js +12 -0
- package/lib/module/specs/NavigtionBar/index.js.map +1 -0
- package/lib/module/specs/ShadowRegistry/ShadowRegistry.nitro.js +4 -0
- package/lib/module/specs/ShadowRegistry/ShadowRegistry.nitro.js.map +1 -0
- package/lib/module/specs/ShadowRegistry/index.js +26 -0
- package/lib/module/specs/ShadowRegistry/index.js.map +1 -0
- package/lib/module/specs/ShadowRegistry/types.js +2 -0
- package/lib/module/specs/ShadowRegistry/types.js.map +1 -0
- package/lib/module/specs/StatusBar/UnistylesStatusBar.nitro.js +4 -0
- package/lib/module/specs/StatusBar/UnistylesStatusBar.nitro.js.map +1 -0
- package/lib/module/specs/StatusBar/index.js +28 -0
- package/lib/module/specs/StatusBar/index.js.map +1 -0
- package/lib/module/specs/StyleSheet/UnistylesStyleSheet.nitro.js +4 -0
- package/lib/module/specs/StyleSheet/UnistylesStyleSheet.nitro.js.map +1 -0
- package/lib/module/specs/StyleSheet/index.js +14 -0
- package/lib/module/specs/StyleSheet/index.js.map +1 -0
- package/lib/module/specs/TurboUnistyles/NativeTurboUnistyles.js +9 -0
- package/lib/module/specs/TurboUnistyles/NativeTurboUnistyles.js.map +1 -0
- package/lib/module/specs/TurboUnistyles/index.js +4 -0
- package/lib/module/specs/TurboUnistyles/index.js.map +1 -0
- package/lib/module/specs/UnistylesRuntime/UnistylesRuntime.nitro.js +4 -0
- package/lib/module/specs/UnistylesRuntime/UnistylesRuntime.nitro.js.map +1 -0
- package/lib/module/specs/UnistylesRuntime/index.js +22 -0
- package/lib/module/specs/UnistylesRuntime/index.js.map +1 -0
- package/lib/module/specs/index.js +10 -0
- package/lib/module/specs/index.js.map +1 -0
- package/lib/module/specs/index.web.js +5 -0
- package/lib/module/specs/index.web.js.map +1 -0
- package/lib/module/specs/types.js +20 -0
- package/lib/module/specs/types.js.map +1 -0
- package/lib/module/types/accessibility.js +33 -0
- package/lib/module/types/accessibility.js.map +1 -0
- package/lib/module/types/breakpoints.js +2 -0
- package/lib/module/types/common.js +1 -1
- package/lib/module/types/core.js +2 -0
- package/lib/module/types/index.js +3 -3
- package/lib/module/types/index.js.map +1 -1
- package/lib/module/types/stylesheet.js +5 -0
- package/lib/module/types/stylesheet.js.map +1 -1
- package/lib/module/types/variants.js +2 -0
- package/lib/typescript/example/App.d.ts +4 -0
- package/lib/typescript/example/App.d.ts.map +1 -0
- package/lib/typescript/example/unistyles.d.ts +63 -0
- package/lib/typescript/example/unistyles.d.ts.map +1 -0
- package/lib/typescript/expo-example/App.d.ts +4 -0
- package/lib/typescript/expo-example/App.d.ts.map +1 -0
- package/lib/typescript/expo-example/unistyles.d.ts +63 -0
- package/lib/typescript/expo-example/unistyles.d.ts.map +1 -0
- package/lib/typescript/src/common.d.ts +0 -50
- package/lib/typescript/src/common.d.ts.map +1 -1
- package/lib/typescript/src/index.d.ts +3 -76
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/{utils/mq.d.ts → mq.d.ts} +2 -2
- package/lib/typescript/src/mq.d.ts.map +1 -0
- package/lib/typescript/src/specs/NativePlatform/NativePlatform.nitro.d.ts +57 -0
- package/lib/typescript/src/specs/NativePlatform/NativePlatform.nitro.d.ts.map +1 -0
- package/lib/typescript/src/specs/NativePlatform/index.d.ts +3 -0
- package/lib/typescript/src/specs/NativePlatform/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/NavigtionBar/UnistylesNavigationBar.nitro.d.ts +11 -0
- package/lib/typescript/src/specs/NavigtionBar/UnistylesNavigationBar.nitro.d.ts.map +1 -0
- package/lib/typescript/src/specs/NavigtionBar/index.d.ts +11 -0
- package/lib/typescript/src/specs/NavigtionBar/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/ShadowRegistry/ShadowRegistry.nitro.d.ts +7 -0
- package/lib/typescript/src/specs/ShadowRegistry/ShadowRegistry.nitro.d.ts.map +1 -0
- package/lib/typescript/src/specs/ShadowRegistry/index.d.ts +12 -0
- package/lib/typescript/src/specs/ShadowRegistry/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/ShadowRegistry/types.d.ts +27 -0
- package/lib/typescript/src/specs/ShadowRegistry/types.d.ts.map +1 -0
- package/lib/typescript/src/specs/StatusBar/UnistylesStatusBar.nitro.d.ts +11 -0
- package/lib/typescript/src/specs/StatusBar/UnistylesStatusBar.nitro.d.ts.map +1 -0
- package/lib/typescript/src/specs/StatusBar/index.d.ts +15 -0
- package/lib/typescript/src/specs/StatusBar/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/StyleSheet/UnistylesStyleSheet.nitro.d.ts +9 -0
- package/lib/typescript/src/specs/StyleSheet/UnistylesStyleSheet.nitro.d.ts.map +1 -0
- package/lib/typescript/src/specs/StyleSheet/index.d.ts +28 -0
- package/lib/typescript/src/specs/StyleSheet/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/TurboUnistyles/NativeTurboUnistyles.d.ts +2 -0
- package/lib/typescript/src/specs/TurboUnistyles/NativeTurboUnistyles.d.ts.map +1 -0
- package/lib/typescript/src/specs/TurboUnistyles/index.d.ts +2 -0
- package/lib/typescript/src/specs/TurboUnistyles/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/UnistylesRuntime/UnistylesRuntime.nitro.d.ts +41 -0
- package/lib/typescript/src/specs/UnistylesRuntime/UnistylesRuntime.nitro.d.ts.map +1 -0
- package/lib/typescript/src/specs/UnistylesRuntime/index.d.ts +25 -0
- package/lib/typescript/src/specs/UnistylesRuntime/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/index.d.ts +10 -0
- package/lib/typescript/src/specs/index.d.ts.map +1 -0
- package/lib/typescript/src/specs/index.web.d.ts +4 -0
- package/lib/typescript/src/specs/index.web.d.ts.map +1 -0
- package/lib/typescript/src/specs/types.d.ts +32 -0
- package/lib/typescript/src/specs/types.d.ts.map +1 -0
- package/lib/typescript/src/types/accessibility.d.ts +28 -0
- package/lib/typescript/src/types/accessibility.d.ts.map +1 -0
- package/lib/typescript/src/types/breakpoints.d.ts +12 -5
- package/lib/typescript/src/types/breakpoints.d.ts.map +1 -1
- package/lib/typescript/src/types/common.d.ts +1 -0
- package/lib/typescript/src/types/common.d.ts.map +1 -1
- package/lib/typescript/src/types/index.d.ts +2 -5
- package/lib/typescript/src/types/index.d.ts.map +1 -1
- package/lib/typescript/src/types/stylesheet.d.ts +31 -9
- package/lib/typescript/src/types/stylesheet.d.ts.map +1 -1
- package/lib/typescript/src/types/variants.d.ts +5 -8
- package/lib/typescript/src/types/variants.d.ts.map +1 -1
- package/lib/typescript/web/convert/boxShadow.d.ts +3 -0
- package/lib/typescript/web/convert/boxShadow.d.ts.map +1 -0
- package/lib/typescript/web/convert/breakpoint.d.ts +3 -0
- package/lib/typescript/web/convert/breakpoint.d.ts.map +1 -0
- package/lib/typescript/web/convert/index.d.ts +4 -0
- package/lib/typescript/web/convert/index.d.ts.map +1 -0
- package/lib/typescript/web/convert/shadow.d.ts +2 -0
- package/lib/typescript/web/convert/shadow.d.ts.map +1 -0
- package/lib/typescript/web/convert/style.d.ts +3 -0
- package/lib/typescript/web/convert/style.d.ts.map +1 -0
- package/lib/typescript/web/convert/textShadow.d.ts +3 -0
- package/lib/typescript/web/convert/textShadow.d.ts.map +1 -0
- package/lib/typescript/web/convert/transform.d.ts +5 -0
- package/lib/typescript/web/convert/transform.d.ts.map +1 -0
- package/lib/typescript/web/convert/types.d.ts +13 -0
- package/lib/typescript/web/convert/types.d.ts.map +1 -0
- package/lib/typescript/web/convert/utils.d.ts +8 -0
- package/lib/typescript/web/convert/utils.d.ts.map +1 -0
- package/lib/typescript/web/create.d.ts +2449 -0
- package/lib/typescript/web/create.d.ts.map +1 -0
- package/lib/typescript/web/index.d.ts +2464 -0
- package/lib/typescript/web/index.d.ts.map +1 -0
- package/lib/typescript/web/listener/index.d.ts +2 -0
- package/lib/typescript/web/listener/index.d.ts.map +1 -0
- package/lib/typescript/web/listener/listener.d.ts +10 -0
- package/lib/typescript/web/listener/listener.d.ts.map +1 -0
- package/lib/typescript/web/mock.d.ts +14 -0
- package/lib/typescript/web/mock.d.ts.map +1 -0
- package/lib/typescript/web/mq.d.ts +4 -0
- package/lib/typescript/web/mq.d.ts.map +1 -0
- package/lib/typescript/web/pseudo.d.ts +4 -0
- package/lib/typescript/web/pseudo.d.ts.map +1 -0
- package/lib/typescript/web/registry.d.ts +12 -0
- package/lib/typescript/web/registry.d.ts.map +1 -0
- package/lib/typescript/web/runtime.d.ts +42 -0
- package/lib/typescript/web/runtime.d.ts.map +1 -0
- package/lib/typescript/web/state.d.ts +24 -0
- package/lib/typescript/web/state.d.ts.map +1 -0
- package/lib/typescript/web/useVariants.d.ts +3 -0
- package/lib/typescript/web/useVariants.d.ts.map +1 -0
- package/lib/typescript/web/utils.d.ts +18 -0
- package/lib/typescript/web/utils.d.ts.map +1 -0
- package/nitrogen/generated/android/UnistylesOnLoad.cpp +34 -0
- package/nitrogen/generated/android/UnistylesOnLoad.hpp +25 -0
- package/nitrogen/generated/android/UnistylesOnLoad.kt +1 -0
- package/nitrogen/generated/android/c++/JColorScheme.hpp +61 -0
- package/nitrogen/generated/android/c++/JDimensions.hpp +56 -0
- package/nitrogen/generated/android/c++/JFunc_void_std__vector_UnistyleDependency_.hpp +60 -0
- package/nitrogen/generated/android/c++/JHybridNativePlatformSpec.cpp +145 -0
- package/nitrogen/generated/android/c++/JHybridNativePlatformSpec.hpp +70 -0
- package/nitrogen/generated/android/c++/JInsets.hpp +68 -0
- package/nitrogen/generated/android/c++/JOrientation.hpp +58 -0
- package/nitrogen/generated/android/c++/JUnistyleDependency.hpp +94 -0
- package/nitrogen/generated/android/c++/JUnistylesNativeMiniRuntime.hpp +96 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/ColorScheme.kt +22 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/Dimensions.kt +21 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/Func_void_std__vector_UnistyleDependency_.kt +45 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/HybridNativePlatformSpec.kt +134 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/Insets.kt +24 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/Orientation.kt +21 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/UnistyleDependency.kt +33 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/unistyles/UnistylesNativeMiniRuntime.kt +29 -0
- package/nitrogen/generated/android/unistyles+autolinking.cmake +52 -0
- package/nitrogen/generated/android/unistyles+autolinking.gradle +25 -0
- package/nitrogen/generated/ios/Unistyles+autolinking.rb +56 -0
- package/nitrogen/generated/ios/Unistyles-Swift-Cxx-Bridge.cpp +8 -0
- package/nitrogen/generated/ios/Unistyles-Swift-Cxx-Bridge.hpp +86 -0
- package/nitrogen/generated/ios/Unistyles-Swift-Cxx-Umbrella.hpp +88 -0
- package/nitrogen/generated/ios/c++/HybridNativePlatformSpecSwift.cpp +11 -0
- package/nitrogen/generated/ios/c++/HybridNativePlatformSpecSwift.hpp +151 -0
- package/nitrogen/generated/ios/swift/ColorScheme.swift +44 -0
- package/nitrogen/generated/ios/swift/Dimensions.swift +46 -0
- package/nitrogen/generated/ios/swift/HybridNativePlatformSpec.swift +65 -0
- package/nitrogen/generated/ios/swift/HybridNativePlatformSpecCxx.swift +273 -0
- package/nitrogen/generated/ios/swift/Insets.swift +79 -0
- package/nitrogen/generated/ios/swift/Orientation.swift +40 -0
- package/nitrogen/generated/ios/swift/UnistyleDependency.swift +88 -0
- package/nitrogen/generated/ios/swift/UnistylesNativeMiniRuntime.swift +134 -0
- package/nitrogen/generated/shared/c++/ColorScheme.hpp +82 -0
- package/nitrogen/generated/shared/c++/Dimensions.hpp +72 -0
- package/nitrogen/generated/shared/c++/HybridNativePlatformSpec.cpp +38 -0
- package/nitrogen/generated/shared/c++/HybridNativePlatformSpec.hpp +95 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesNavigationBarSpec.cpp +24 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesNavigationBarSpec.hpp +61 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesRuntimeSpec.cpp +36 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesRuntimeSpec.hpp +88 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesShadowRegistrySpec.cpp +21 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesShadowRegistrySpec.hpp +59 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesStatusBarSpec.cpp +24 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesStatusBarSpec.hpp +61 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesStyleSheetSpec.cpp +22 -0
- package/nitrogen/generated/shared/c++/HybridUnistylesStyleSheetSpec.hpp +60 -0
- package/nitrogen/generated/shared/c++/Insets.hpp +84 -0
- package/nitrogen/generated/shared/c++/Orientation.hpp +78 -0
- package/nitrogen/generated/shared/c++/UnistyleDependency.hpp +76 -0
- package/nitrogen/generated/shared/c++/UnistylesCxxMiniRuntime.hpp +128 -0
- package/nitrogen/generated/shared/c++/UnistylesNativeMiniRuntime.hpp +115 -0
- package/package.json +33 -58
- package/plugin/__tests__/dependencies.spec.js +360 -0
- package/plugin/__tests__/ref.spec.js +991 -0
- package/plugin/__tests__/stylesheet.spec.js +396 -0
- package/plugin/common.js +119 -0
- package/plugin/import.js +8 -0
- package/plugin/index.js +122 -0
- package/plugin/ref.js +179 -0
- package/plugin/style.js +58 -0
- package/plugin/stylesheet.js +147 -0
- package/src/common.ts +0 -58
- package/src/index.ts +11 -52
- package/src/{utils/mq.ts → mq.ts} +13 -4
- package/src/specs/NativePlatform/NativePlatform.nitro.ts +61 -0
- package/src/specs/NativePlatform/index.ts +2 -0
- package/src/specs/NavigtionBar/UnistylesNavigationBar.nitro.ts +10 -0
- package/src/specs/NavigtionBar/index.ts +25 -0
- package/src/specs/ShadowRegistry/ShadowRegistry.nitro.ts +3 -0
- package/src/specs/ShadowRegistry/index.ts +51 -0
- package/src/specs/ShadowRegistry/types.ts +29 -0
- package/src/specs/StatusBar/UnistylesStatusBar.nitro.ts +10 -0
- package/src/specs/StatusBar/index.ts +48 -0
- package/src/specs/StyleSheet/UnistylesStyleSheet.nitro.ts +6 -0
- package/src/specs/StyleSheet/index.ts +44 -0
- package/src/specs/TurboUnistyles/NativeTurboUnistyles.ts +8 -0
- package/src/specs/TurboUnistyles/index.ts +1 -0
- package/src/specs/UnistylesRuntime/UnistylesRuntime.nitro.ts +47 -0
- package/src/specs/UnistylesRuntime/index.ts +64 -0
- package/src/specs/index.ts +23 -0
- package/src/specs/index.web.ts +5 -0
- package/src/specs/types.ts +38 -0
- package/src/types/accessibility.ts +29 -0
- package/src/types/breakpoints.ts +21 -14
- package/src/types/common.ts +1 -0
- package/src/types/index.ts +2 -5
- package/src/types/stylesheet.ts +41 -9
- package/src/types/variants.ts +7 -11
- package/web/convert/boxShadow.ts +72 -0
- package/web/convert/breakpoint.ts +21 -0
- package/web/convert/index.ts +78 -0
- package/web/convert/shadow.ts +68 -0
- package/web/convert/style.ts +94 -0
- package/web/convert/textShadow.ts +69 -0
- package/web/convert/transform.ts +89 -0
- package/web/convert/types.ts +16 -0
- package/web/convert/utils.ts +54 -0
- package/web/create.ts +102 -0
- package/web/index.ts +24 -0
- package/web/listener/index.ts +1 -0
- package/web/listener/listener.ts +33 -0
- package/web/mock.ts +35 -0
- package/web/mq.ts +19 -0
- package/web/pseudo.ts +11 -0
- package/web/registry.ts +41 -0
- package/web/runtime.ts +198 -0
- package/web/state.ts +148 -0
- package/web/useVariants.ts +99 -0
- package/web/utils.ts +95 -0
- package/android/src/main/java/com/unistyles/Models.kt +0 -27
- package/android/src/main/java/com/unistyles/Platform.kt +0 -324
- package/android/src/main/java/com/unistyles/UnistylesModule.kt +0 -217
- package/cxx/Macros.h +0 -11
- package/cxx/UnistylesImpl.cpp +0 -310
- package/cxx/UnistylesModel.cpp +0 -230
- package/cxx/UnistylesModel.h +0 -143
- package/cxx/UnistylesRuntime.cpp +0 -36
- package/cxx/UnistylesRuntime.h +0 -81
- package/ios/UnistylesModule.h +0 -28
- package/ios/UnistylesModule.mm +0 -77
- package/ios/platform/Platform_Shared.h +0 -8
- package/ios/platform/Platform_Shared.mm +0 -160
- package/ios/platform/Platform_iOS.h +0 -20
- package/ios/platform/Platform_iOS.mm +0 -193
- package/ios/platform/Platform_macOS.h +0 -19
- package/ios/platform/Platform_macOS.mm +0 -117
- package/ios/platform/Platform_tvOS.h +0 -16
- package/ios/platform/Platform_tvOS.mm +0 -92
- package/ios/platform/Platform_visionOS.h +0 -19
- package/ios/platform/Platform_visionOS.mm +0 -116
- package/lib/commonjs/core/UnistyleRegistry.js +0 -110
- package/lib/commonjs/core/UnistyleRegistry.js.map +0 -1
- package/lib/commonjs/core/Unistyles.js +0 -39
- package/lib/commonjs/core/Unistyles.js.map +0 -1
- package/lib/commonjs/core/UnistylesModule.js +0 -268
- package/lib/commonjs/core/UnistylesModule.js.map +0 -1
- package/lib/commonjs/core/UnistylesModule.native.js +0 -9
- package/lib/commonjs/core/UnistylesModule.native.js.map +0 -1
- package/lib/commonjs/core/UnistylesModule.windows.js +0 -11
- package/lib/commonjs/core/UnistylesModule.windows.js.map +0 -1
- package/lib/commonjs/core/UnistylesRuntime.js +0 -284
- package/lib/commonjs/core/UnistylesRuntime.js.map +0 -1
- package/lib/commonjs/core/index.js +0 -13
- package/lib/commonjs/core/index.js.map +0 -1
- package/lib/commonjs/core/mocks/UnistylesMockedBridge.js +0 -36
- package/lib/commonjs/core/mocks/UnistylesMockedBridge.js.map +0 -1
- package/lib/commonjs/core/mocks/UnistylesMockedRegistry.js +0 -46
- package/lib/commonjs/core/mocks/UnistylesMockedRegistry.js.map +0 -1
- package/lib/commonjs/core/mocks/UnistylesMockedRuntime.js +0 -122
- package/lib/commonjs/core/mocks/UnistylesMockedRuntime.js.map +0 -1
- package/lib/commonjs/core/mocks/index.js +0 -27
- package/lib/commonjs/core/mocks/index.js.map +0 -1
- package/lib/commonjs/createStyleSheet.js +0 -14
- package/lib/commonjs/createStyleSheet.js.map +0 -1
- package/lib/commonjs/hooks/index.js +0 -34
- package/lib/commonjs/hooks/index.js.map +0 -1
- package/lib/commonjs/hooks/useCSS.js +0 -44
- package/lib/commonjs/hooks/useCSS.js.map +0 -1
- package/lib/commonjs/hooks/useCSS.native.js +0 -9
- package/lib/commonjs/hooks/useCSS.native.js.map +0 -1
- package/lib/commonjs/hooks/useInitialTheme.js +0 -17
- package/lib/commonjs/hooks/useInitialTheme.js.map +0 -1
- package/lib/commonjs/hooks/useUnistyles.js +0 -74
- package/lib/commonjs/hooks/useUnistyles.js.map +0 -1
- package/lib/commonjs/hooks/useVariants.js +0 -14
- package/lib/commonjs/hooks/useVariants.js.map +0 -1
- package/lib/commonjs/normalizer/index.js +0 -32
- package/lib/commonjs/normalizer/index.js.map +0 -1
- package/lib/commonjs/normalizer/module.d.js +0 -2
- package/lib/commonjs/normalizer/module.d.js.map +0 -1
- package/lib/commonjs/normalizer/normalizeStyle.js +0 -59
- package/lib/commonjs/normalizer/normalizeStyle.js.map +0 -1
- package/lib/commonjs/normalizer/normalizer.js +0 -88
- package/lib/commonjs/normalizer/normalizer.js.map +0 -1
- package/lib/commonjs/normalizer/normalizer.macos.js +0 -3
- package/lib/commonjs/normalizer/normalizer.macos.js.map +0 -1
- package/lib/commonjs/plugins/cssMediaQueriesPlugin.js +0 -14
- package/lib/commonjs/plugins/cssMediaQueriesPlugin.js.map +0 -1
- package/lib/commonjs/plugins/index.js +0 -20
- package/lib/commonjs/plugins/index.js.map +0 -1
- package/lib/commonjs/plugins/normalizeWebStylesPlugin.js +0 -12
- package/lib/commonjs/plugins/normalizeWebStylesPlugin.js.map +0 -1
- package/lib/commonjs/types/color.js +0 -2
- package/lib/commonjs/types/color.js.map +0 -1
- package/lib/commonjs/types/normalizer.js.map +0 -1
- package/lib/commonjs/types/plugin.js.map +0 -1
- package/lib/commonjs/types/unistyles.js.map +0 -1
- package/lib/commonjs/useStyles.js +0 -47
- package/lib/commonjs/useStyles.js.map +0 -1
- package/lib/commonjs/utils/breakpoints.js +0 -33
- package/lib/commonjs/utils/breakpoints.js.map +0 -1
- package/lib/commonjs/utils/cssMediaQuery.js +0 -244
- package/lib/commonjs/utils/cssMediaQuery.js.map +0 -1
- package/lib/commonjs/utils/generateId.js +0 -15
- package/lib/commonjs/utils/generateId.js.map +0 -1
- package/lib/commonjs/utils/hash32.js +0 -43
- package/lib/commonjs/utils/hash32.js.map +0 -1
- package/lib/commonjs/utils/index.js +0 -91
- package/lib/commonjs/utils/index.js.map +0 -1
- package/lib/commonjs/utils/mq.js.map +0 -1
- package/lib/commonjs/utils/mqParser.js +0 -89
- package/lib/commonjs/utils/mqParser.js.map +0 -1
- package/lib/commonjs/utils/parseColor.js +0 -35
- package/lib/commonjs/utils/parseColor.js.map +0 -1
- package/lib/commonjs/utils/styles.js +0 -73
- package/lib/commonjs/utils/styles.js.map +0 -1
- package/lib/commonjs/utils/withPlugins.js +0 -15
- package/lib/commonjs/utils/withPlugins.js.map +0 -1
- package/lib/module/core/UnistyleRegistry.js +0 -103
- package/lib/module/core/UnistyleRegistry.js.map +0 -1
- package/lib/module/core/Unistyles.js +0 -33
- package/lib/module/core/Unistyles.js.map +0 -1
- package/lib/module/core/UnistylesModule.js +0 -261
- package/lib/module/core/UnistylesModule.js.map +0 -1
- package/lib/module/core/UnistylesModule.native.js +0 -3
- package/lib/module/core/UnistylesModule.native.js.map +0 -1
- package/lib/module/core/UnistylesModule.windows.js +0 -5
- package/lib/module/core/UnistylesModule.windows.js.map +0 -1
- package/lib/module/core/UnistylesRuntime.js +0 -278
- package/lib/module/core/UnistylesRuntime.js.map +0 -1
- package/lib/module/core/index.js +0 -3
- package/lib/module/core/index.js.map +0 -1
- package/lib/module/core/mocks/UnistylesMockedBridge.js +0 -29
- package/lib/module/core/mocks/UnistylesMockedBridge.js.map +0 -1
- package/lib/module/core/mocks/UnistylesMockedRegistry.js +0 -39
- package/lib/module/core/mocks/UnistylesMockedRegistry.js.map +0 -1
- package/lib/module/core/mocks/UnistylesMockedRuntime.js +0 -114
- package/lib/module/core/mocks/UnistylesMockedRuntime.js.map +0 -1
- package/lib/module/core/mocks/index.js +0 -4
- package/lib/module/core/mocks/index.js.map +0 -1
- package/lib/module/createStyleSheet.js +0 -7
- package/lib/module/createStyleSheet.js.map +0 -1
- package/lib/module/hooks/index.js +0 -5
- package/lib/module/hooks/index.js.map +0 -1
- package/lib/module/hooks/useCSS.js +0 -37
- package/lib/module/hooks/useCSS.js.map +0 -1
- package/lib/module/hooks/useCSS.native.js +0 -2
- package/lib/module/hooks/useCSS.native.js.map +0 -1
- package/lib/module/hooks/useInitialTheme.js +0 -10
- package/lib/module/hooks/useInitialTheme.js.map +0 -1
- package/lib/module/hooks/useUnistyles.js +0 -67
- package/lib/module/hooks/useUnistyles.js.map +0 -1
- package/lib/module/hooks/useVariants.js +0 -7
- package/lib/module/hooks/useVariants.js.map +0 -1
- package/lib/module/normalizer/index.js +0 -3
- package/lib/module/normalizer/index.js.map +0 -1
- package/lib/module/normalizer/module.d.js +0 -2
- package/lib/module/normalizer/module.d.js.map +0 -1
- package/lib/module/normalizer/normalizeStyle.js +0 -52
- package/lib/module/normalizer/normalizeStyle.js.map +0 -1
- package/lib/module/normalizer/normalizer.js +0 -78
- package/lib/module/normalizer/normalizer.js.map +0 -1
- package/lib/module/normalizer/normalizer.macos.js +0 -2
- package/lib/module/normalizer/normalizer.macos.js.map +0 -1
- package/lib/module/plugins/cssMediaQueriesPlugin.js +0 -7
- package/lib/module/plugins/cssMediaQueriesPlugin.js.map +0 -1
- package/lib/module/plugins/index.js +0 -3
- package/lib/module/plugins/index.js.map +0 -1
- package/lib/module/plugins/normalizeWebStylesPlugin.js +0 -6
- package/lib/module/plugins/normalizeWebStylesPlugin.js.map +0 -1
- package/lib/module/types/color.js +0 -2
- package/lib/module/types/color.js.map +0 -1
- package/lib/module/types/normalizer.js +0 -2
- package/lib/module/types/normalizer.js.map +0 -1
- package/lib/module/types/plugin.js +0 -2
- package/lib/module/types/plugin.js.map +0 -1
- package/lib/module/types/unistyles.js +0 -2
- package/lib/module/types/unistyles.js.map +0 -1
- package/lib/module/useStyles.js +0 -40
- package/lib/module/useStyles.js.map +0 -1
- package/lib/module/utils/breakpoints.js +0 -26
- package/lib/module/utils/breakpoints.js.map +0 -1
- package/lib/module/utils/cssMediaQuery.js +0 -237
- package/lib/module/utils/cssMediaQuery.js.map +0 -1
- package/lib/module/utils/generateId.js +0 -7
- package/lib/module/utils/generateId.js.map +0 -1
- package/lib/module/utils/hash32.js +0 -36
- package/lib/module/utils/hash32.js.map +0 -1
- package/lib/module/utils/index.js +0 -8
- package/lib/module/utils/index.js.map +0 -1
- package/lib/module/utils/mq.js.map +0 -1
- package/lib/module/utils/mqParser.js +0 -78
- package/lib/module/utils/mqParser.js.map +0 -1
- package/lib/module/utils/parseColor.js +0 -28
- package/lib/module/utils/parseColor.js.map +0 -1
- package/lib/module/utils/styles.js +0 -64
- package/lib/module/utils/styles.js.map +0 -1
- package/lib/module/utils/withPlugins.js +0 -8
- package/lib/module/utils/withPlugins.js.map +0 -1
- package/lib/typescript/src/core/UnistyleRegistry.d.ts +0 -57
- package/lib/typescript/src/core/UnistyleRegistry.d.ts.map +0 -1
- package/lib/typescript/src/core/Unistyles.d.ts +0 -13
- package/lib/typescript/src/core/Unistyles.d.ts.map +0 -1
- package/lib/typescript/src/core/UnistylesModule.d.ts +0 -21
- package/lib/typescript/src/core/UnistylesModule.d.ts.map +0 -1
- package/lib/typescript/src/core/UnistylesModule.native.d.ts +0 -6
- package/lib/typescript/src/core/UnistylesModule.native.d.ts.map +0 -1
- package/lib/typescript/src/core/UnistylesModule.windows.d.ts +0 -6
- package/lib/typescript/src/core/UnistylesModule.windows.d.ts.map +0 -1
- package/lib/typescript/src/core/UnistylesRuntime.d.ts +0 -179
- package/lib/typescript/src/core/UnistylesRuntime.d.ts.map +0 -1
- package/lib/typescript/src/core/index.d.ts +0 -5
- package/lib/typescript/src/core/index.d.ts.map +0 -1
- package/lib/typescript/src/core/mocks/UnistylesMockedBridge.d.ts +0 -28
- package/lib/typescript/src/core/mocks/UnistylesMockedBridge.d.ts.map +0 -1
- package/lib/typescript/src/core/mocks/UnistylesMockedRegistry.d.ts +0 -21
- package/lib/typescript/src/core/mocks/UnistylesMockedRegistry.d.ts.map +0 -1
- package/lib/typescript/src/core/mocks/UnistylesMockedRuntime.d.ts +0 -79
- package/lib/typescript/src/core/mocks/UnistylesMockedRuntime.d.ts.map +0 -1
- package/lib/typescript/src/core/mocks/index.d.ts +0 -4
- package/lib/typescript/src/core/mocks/index.d.ts.map +0 -1
- package/lib/typescript/src/createStyleSheet.d.ts +0 -8
- package/lib/typescript/src/createStyleSheet.d.ts.map +0 -1
- package/lib/typescript/src/hooks/index.d.ts +0 -5
- package/lib/typescript/src/hooks/index.d.ts.map +0 -1
- package/lib/typescript/src/hooks/useCSS.d.ts +0 -3
- package/lib/typescript/src/hooks/useCSS.d.ts.map +0 -1
- package/lib/typescript/src/hooks/useCSS.native.d.ts +0 -3
- package/lib/typescript/src/hooks/useCSS.native.d.ts.map +0 -1
- package/lib/typescript/src/hooks/useInitialTheme.d.ts +0 -3
- package/lib/typescript/src/hooks/useInitialTheme.d.ts.map +0 -1
- package/lib/typescript/src/hooks/useUnistyles.d.ts +0 -27
- package/lib/typescript/src/hooks/useUnistyles.d.ts.map +0 -1
- package/lib/typescript/src/hooks/useVariants.d.ts +0 -3
- package/lib/typescript/src/hooks/useVariants.d.ts.map +0 -1
- package/lib/typescript/src/normalizer/index.d.ts +0 -3
- package/lib/typescript/src/normalizer/index.d.ts.map +0 -1
- package/lib/typescript/src/normalizer/normalizeStyle.d.ts +0 -3
- package/lib/typescript/src/normalizer/normalizeStyle.d.ts.map +0 -1
- package/lib/typescript/src/normalizer/normalizer.d.ts +0 -11
- package/lib/typescript/src/normalizer/normalizer.d.ts.map +0 -1
- package/lib/typescript/src/normalizer/normalizer.macos.d.ts +0 -1
- package/lib/typescript/src/normalizer/normalizer.macos.d.ts.map +0 -1
- package/lib/typescript/src/plugins/cssMediaQueriesPlugin.d.ts +0 -3
- package/lib/typescript/src/plugins/cssMediaQueriesPlugin.d.ts.map +0 -1
- package/lib/typescript/src/plugins/index.d.ts +0 -3
- package/lib/typescript/src/plugins/index.d.ts.map +0 -1
- package/lib/typescript/src/plugins/normalizeWebStylesPlugin.d.ts +0 -3
- package/lib/typescript/src/plugins/normalizeWebStylesPlugin.d.ts.map +0 -1
- package/lib/typescript/src/types/color.d.ts +0 -4
- package/lib/typescript/src/types/color.d.ts.map +0 -1
- package/lib/typescript/src/types/normalizer.d.ts +0 -20
- package/lib/typescript/src/types/normalizer.d.ts.map +0 -1
- package/lib/typescript/src/types/plugin.d.ts +0 -7
- package/lib/typescript/src/types/plugin.d.ts.map +0 -1
- package/lib/typescript/src/types/unistyles.d.ts +0 -81
- package/lib/typescript/src/types/unistyles.d.ts.map +0 -1
- package/lib/typescript/src/useStyles.d.ts +0 -16
- package/lib/typescript/src/useStyles.d.ts.map +0 -1
- package/lib/typescript/src/utils/breakpoints.d.ts +0 -3
- package/lib/typescript/src/utils/breakpoints.d.ts.map +0 -1
- package/lib/typescript/src/utils/cssMediaQuery.d.ts +0 -4
- package/lib/typescript/src/utils/cssMediaQuery.d.ts.map +0 -1
- package/lib/typescript/src/utils/generateId.d.ts +0 -2
- package/lib/typescript/src/utils/generateId.d.ts.map +0 -1
- package/lib/typescript/src/utils/hash32.d.ts +0 -2
- package/lib/typescript/src/utils/hash32.d.ts.map +0 -1
- package/lib/typescript/src/utils/index.d.ts +0 -9
- package/lib/typescript/src/utils/index.d.ts.map +0 -1
- package/lib/typescript/src/utils/mq.d.ts.map +0 -1
- package/lib/typescript/src/utils/mqParser.d.ts +0 -16
- package/lib/typescript/src/utils/mqParser.d.ts.map +0 -1
- package/lib/typescript/src/utils/parseColor.d.ts +0 -3
- package/lib/typescript/src/utils/parseColor.d.ts.map +0 -1
- package/lib/typescript/src/utils/styles.d.ts +0 -5
- package/lib/typescript/src/utils/styles.d.ts.map +0 -1
- package/lib/typescript/src/utils/withPlugins.d.ts +0 -3
- package/lib/typescript/src/utils/withPlugins.d.ts.map +0 -1
- package/react-native-unistyles.podspec +0 -25
- package/react-native.config.js +0 -11
- package/src/__tests__/mocks.ts +0 -24
- package/src/core/UnistyleRegistry.ts +0 -130
- package/src/core/Unistyles.ts +0 -44
- package/src/core/UnistylesModule.native.ts +0 -7
- package/src/core/UnistylesModule.ts +0 -305
- package/src/core/UnistylesModule.windows.ts +0 -9
- package/src/core/UnistylesRuntime.ts +0 -284
- package/src/core/index.ts +0 -8
- package/src/core/mocks/UnistylesMockedBridge.ts +0 -30
- package/src/core/mocks/UnistylesMockedRegistry.ts +0 -47
- package/src/core/mocks/UnistylesMockedRuntime.ts +0 -144
- package/src/core/mocks/index.ts +0 -3
- package/src/createStyleSheet.ts +0 -8
- package/src/hooks/index.ts +0 -4
- package/src/hooks/useCSS.native.ts +0 -3
- package/src/hooks/useCSS.ts +0 -51
- package/src/hooks/useInitialTheme.ts +0 -11
- package/src/hooks/useUnistyles.ts +0 -74
- package/src/hooks/useVariants.ts +0 -10
- package/src/normalizer/index.ts +0 -2
- package/src/normalizer/normalizeStyle.ts +0 -82
- package/src/normalizer/normalizer.macos.ts +0 -1
- package/src/normalizer/normalizer.ts +0 -100
- package/src/plugins/cssMediaQueriesPlugin.ts +0 -8
- package/src/plugins/index.ts +0 -2
- package/src/plugins/normalizeWebStylesPlugin.ts +0 -7
- package/src/types/color.ts +0 -26
- package/src/types/normalizer.ts +0 -29
- package/src/types/plugin.ts +0 -7
- package/src/types/unistyles.ts +0 -98
- package/src/useStyles.ts +0 -60
- package/src/utils/breakpoints.ts +0 -44
- package/src/utils/cssMediaQuery.ts +0 -268
- package/src/utils/generateId.ts +0 -10
- package/src/utils/hash32.ts +0 -53
- package/src/utils/index.ts +0 -8
- package/src/utils/mqParser.ts +0 -99
- package/src/utils/parseColor.ts +0 -33
- package/src/utils/styles.ts +0 -90
- package/src/utils/withPlugins.ts +0 -13
- package/windows/ExperimentalFeatures.props +0 -40
- package/windows/NuGet.Config +0 -13
- package/windows/ReactNativeUnistyles/PropertySheet.props +0 -16
- package/windows/ReactNativeUnistyles/ReactNativeUnistyles.def +0 -3
- package/windows/ReactNativeUnistyles/ReactNativeUnistyles.h +0 -149
- package/windows/ReactNativeUnistyles/ReactNativeUnistyles.vcxproj +0 -162
- package/windows/ReactNativeUnistyles/ReactNativeUnistyles.vcxproj.filters +0 -25
- package/windows/ReactNativeUnistyles/ReactPackageProvider.cpp +0 -19
- package/windows/ReactNativeUnistyles/ReactPackageProvider.h +0 -21
- package/windows/ReactNativeUnistyles/ReactPackageProvider.idl +0 -9
- package/windows/ReactNativeUnistyles/packages.lock.json +0 -133
- package/windows/ReactNativeUnistyles/pch.cpp +0 -1
- package/windows/ReactNativeUnistyles/pch.h +0 -21
- package/windows/ReactNativeUnistyles.sln +0 -156
- /package/{src/normalizer → web/convert}/module.d.ts +0 -0
@@ -0,0 +1,10 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
import './TurboUnistyles';
|
4
|
+
import { Runtime } from './UnistylesRuntime';
|
5
|
+
import { StyleSheet } from './StyleSheet';
|
6
|
+
import { UnistylesShadowRegistry } from './ShadowRegistry';
|
7
|
+
import { StatusBarStyle, ColorScheme, Orientation } from './types';
|
8
|
+
export { StatusBarStyle, ColorScheme, Orientation };
|
9
|
+
export { UnistylesShadowRegistry, Runtime as UnistylesRuntime, StyleSheet };
|
10
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["Runtime","StyleSheet","UnistylesShadowRegistry","StatusBarStyle","ColorScheme","Orientation","UnistylesRuntime"],"sourceRoot":"../../../src","sources":["specs/index.ts"],"mappings":";;AAAA,OAAO,kBAAkB;AAEzB,SAASA,OAAO,QAAQ,oBAAoB;AAC5C,SAASC,UAAU,QAAQ,cAAc;AACzC,SAASC,uBAAuB,QAAQ,kBAAkB;AAE1D,SAASC,cAAc,EAAEC,WAAW,EAAEC,WAAW,QAAQ,SAAS;AAElE,SACIF,cAAc,EACdC,WAAW,EACXC,WAAW;AAGf,SACIH,uBAAuB,EACvBF,OAAO,IAAIM,gBAAgB,EAC3BL,UAAU","ignoreList":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["getSSRUnistyles"],"sourceRoot":"../../../src","sources":["specs/index.web.ts"],"mappings":";;AAEA,OAAO,MAAMA,eAAe,GAAGA,CAAA,KAAM,EAAyB;AAE9D,cAAc,WAAW","ignoreList":[]}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
export let ColorScheme = /*#__PURE__*/function (ColorScheme) {
|
4
|
+
ColorScheme["Light"] = "light";
|
5
|
+
ColorScheme["Dark"] = "dark";
|
6
|
+
ColorScheme["Unspecified"] = "unspecified";
|
7
|
+
return ColorScheme;
|
8
|
+
}({});
|
9
|
+
export let Orientation = /*#__PURE__*/function (Orientation) {
|
10
|
+
Orientation["Portrait"] = "portrait";
|
11
|
+
Orientation["Landscape"] = "landscape";
|
12
|
+
return Orientation;
|
13
|
+
}({});
|
14
|
+
export let StatusBarStyle = /*#__PURE__*/function (StatusBarStyle) {
|
15
|
+
StatusBarStyle["Default"] = "default";
|
16
|
+
StatusBarStyle["Light"] = "light";
|
17
|
+
StatusBarStyle["Dark"] = "dark";
|
18
|
+
return StatusBarStyle;
|
19
|
+
}({});
|
20
|
+
//# sourceMappingURL=types.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["ColorScheme","Orientation","StatusBarStyle"],"sourceRoot":"../../../src","sources":["specs/types.ts"],"mappings":";;AAGA,WAAYA,WAAW,0BAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA;AAMvB,WAAYC,WAAW,0BAAXA,WAAW;EAAXA,WAAW;EAAXA,WAAW;EAAA,OAAXA,WAAW;AAAA;AAkBvB,WAAYC,cAAc,0BAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAdA,cAAc;EAAA,OAAdA,cAAc;AAAA","ignoreList":[]}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
export let IOSContentSizeCategory = /*#__PURE__*/function (IOSContentSizeCategory) {
|
4
|
+
IOSContentSizeCategory["AccessibilityExtraExtraExtraLarge"] = "accessibilityExtraExtraExtraLarge";
|
5
|
+
IOSContentSizeCategory["AccessibilityExtraExtraLarge"] = "accessibilityExtraExtraLarge";
|
6
|
+
IOSContentSizeCategory["AccessibilityExtraLarge"] = "accessibilityExtraLarge";
|
7
|
+
IOSContentSizeCategory["AccessibilityLarge"] = "accessibilityLarge";
|
8
|
+
IOSContentSizeCategory["AccessibilityMedium"] = "accessibilityMedium";
|
9
|
+
IOSContentSizeCategory["ExtraExtraExtraLarge"] = "xxxLarge";
|
10
|
+
IOSContentSizeCategory["ExtraExtraLarge"] = "xxLarge";
|
11
|
+
IOSContentSizeCategory["ExtraLarge"] = "xLarge";
|
12
|
+
IOSContentSizeCategory["Large"] = "Large";
|
13
|
+
IOSContentSizeCategory["Medium"] = "Medium";
|
14
|
+
IOSContentSizeCategory["Small"] = "Small";
|
15
|
+
IOSContentSizeCategory["ExtraSmall"] = "xSmall";
|
16
|
+
IOSContentSizeCategory["Unspecified"] = "unspecified";
|
17
|
+
return IOSContentSizeCategory;
|
18
|
+
}({});
|
19
|
+
export let AndroidContentSizeCategory = /*#__PURE__*/function (AndroidContentSizeCategory) {
|
20
|
+
AndroidContentSizeCategory["Small"] = "Small";
|
21
|
+
AndroidContentSizeCategory["Default"] = "Default";
|
22
|
+
AndroidContentSizeCategory["Large"] = "Large";
|
23
|
+
AndroidContentSizeCategory["ExtraLarge"] = "ExtraLarge";
|
24
|
+
AndroidContentSizeCategory["Huge"] = "Huge";
|
25
|
+
AndroidContentSizeCategory["ExtraHuge"] = "ExtraHuge";
|
26
|
+
AndroidContentSizeCategory["ExtraExtraHuge"] = "ExtraExtraHuge";
|
27
|
+
return AndroidContentSizeCategory;
|
28
|
+
}({});
|
29
|
+
export let WebContentSizeCategory = /*#__PURE__*/function (WebContentSizeCategory) {
|
30
|
+
WebContentSizeCategory["Unspecified"] = "web-unspecified";
|
31
|
+
return WebContentSizeCategory;
|
32
|
+
}({});
|
33
|
+
//# sourceMappingURL=accessibility.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["IOSContentSizeCategory","AndroidContentSizeCategory","WebContentSizeCategory"],"sourceRoot":"../../../src","sources":["types/accessibility.ts"],"mappings":";;AAAA,WAAYA,sBAAsB,0BAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAA,OAAtBA,sBAAsB;AAAA;AAgBlC,WAAYC,0BAA0B,0BAA1BA,0BAA0B;EAA1BA,0BAA0B;EAA1BA,0BAA0B;EAA1BA,0BAA0B;EAA1BA,0BAA0B;EAA1BA,0BAA0B;EAA1BA,0BAA0B;EAA1BA,0BAA0B;EAAA,OAA1BA,0BAA0B;AAAA;AAUtC,WAAYC,sBAAsB,0BAAtBA,sBAAsB;EAAtBA,sBAAsB;EAAA,OAAtBA,sBAAsB;AAAA","ignoreList":[]}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
|
1
|
+
"use strict";
|
2
2
|
//# sourceMappingURL=common.js.map
|
package/lib/module/types/core.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
export
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
export { AndroidContentSizeCategory, IOSContentSizeCategory, WebContentSizeCategory } from './accessibility';
|
4
4
|
//# sourceMappingURL=index.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/index.ts"],"mappings":"
|
1
|
+
{"version":3,"names":["AndroidContentSizeCategory","IOSContentSizeCategory","WebContentSizeCategory"],"sourceRoot":"../../../src","sources":["types/index.ts"],"mappings":";;AAoBA,SAASA,0BAA0B,EAAEC,sBAAsB,EAAEC,sBAAsB,QAAQ,iBAAiB","ignoreList":[]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/stylesheet.ts"],"mappings":"","ignoreList":[]}
|
1
|
+
{"version":3,"names":["create","stylesheet"],"sourceRoot":"../../../src","sources":["types/stylesheet.ts"],"mappings":";;AASA;;AAsEA,MAAMA,MAAM,GAA0BC,UAAwC,IAAoEA,UAA2E;AAAA","ignoreList":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../../../example/App.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA2B,MAAM,OAAO,CAAA;AAG/C,OAAO,aAAa,CAAA;AAEpB,eAAO,MAAM,GAAG,yBAoBf,CAAA"}
|
@@ -0,0 +1,63 @@
|
|
1
|
+
declare const lightTheme: {
|
2
|
+
colors: {
|
3
|
+
backgroundColor: string;
|
4
|
+
typography: string;
|
5
|
+
accent: string;
|
6
|
+
barbie: string;
|
7
|
+
oak: string;
|
8
|
+
sky: string;
|
9
|
+
fog: string;
|
10
|
+
aloes: string;
|
11
|
+
blood: string;
|
12
|
+
};
|
13
|
+
gap: (v: number) => number;
|
14
|
+
};
|
15
|
+
declare const darkTheme: {
|
16
|
+
colors: {
|
17
|
+
backgroundColor: string;
|
18
|
+
typography: string;
|
19
|
+
accent: string;
|
20
|
+
barbie: string;
|
21
|
+
oak: string;
|
22
|
+
sky: string;
|
23
|
+
fog: string;
|
24
|
+
aloes: string;
|
25
|
+
blood: string;
|
26
|
+
};
|
27
|
+
gap: (v: number) => number;
|
28
|
+
};
|
29
|
+
declare const premiumTheme: {
|
30
|
+
colors: {
|
31
|
+
backgroundColor: string;
|
32
|
+
typography: string;
|
33
|
+
accent: string;
|
34
|
+
barbie: string;
|
35
|
+
oak: string;
|
36
|
+
sky: string;
|
37
|
+
fog: string;
|
38
|
+
aloes: string;
|
39
|
+
blood: string;
|
40
|
+
};
|
41
|
+
gap: (v: number) => number;
|
42
|
+
};
|
43
|
+
declare const breakpoints: {
|
44
|
+
xs: number;
|
45
|
+
sm: number;
|
46
|
+
md: number;
|
47
|
+
lg: number;
|
48
|
+
xl: number;
|
49
|
+
};
|
50
|
+
type AppBreakpoints = typeof breakpoints;
|
51
|
+
type AppThemes = {
|
52
|
+
light: typeof lightTheme;
|
53
|
+
dark: typeof darkTheme;
|
54
|
+
premium: typeof premiumTheme;
|
55
|
+
};
|
56
|
+
declare module 'react-native-unistyles' {
|
57
|
+
interface UnistylesThemes extends AppThemes {
|
58
|
+
}
|
59
|
+
interface UnistylesBreakpoints extends AppBreakpoints {
|
60
|
+
}
|
61
|
+
}
|
62
|
+
export {};
|
63
|
+
//# sourceMappingURL=unistyles.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"unistyles.d.ts","sourceRoot":"","sources":["../../../example/unistyles.ts"],"names":[],"mappings":"AAWA,QAAA,MAAM,UAAU;;;;;;;;;;;;aAOH,MAAM;CAClB,CAAA;AAED,QAAA,MAAM,SAAS;;;;;;;;;;;;aAOF,MAAM;CAClB,CAAA;AAED,QAAA,MAAM,YAAY;;;;;;;;;;;;aAOL,MAAM;CAClB,CAAA;AAED,QAAA,MAAM,WAAW;;;;;;CAMhB,CAAA;AAED,KAAK,cAAc,GAAG,OAAO,WAAW,CAAA;AACxC,KAAK,SAAS,GAAG;IACb,KAAK,EAAE,OAAO,UAAU,CAAA;IACxB,IAAI,EAAE,OAAO,SAAS,CAAA;IACtB,OAAO,EAAE,OAAO,YAAY,CAAA;CAC/B,CAAA;AAED,OAAO,QAAQ,wBAAwB,CAAC;IACpC,UAAiB,eAAgB,SAAQ,SAAS;KAAG;IAErD,UAAiB,oBAAqB,SAAQ,cAAc;KAAG;CAClE"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../../../expo-example/App.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAGvC,OAAO,aAAa,CAAA;AAEpB,MAAM,CAAC,OAAO,UAAU,GAAG,sBAyC1B"}
|
@@ -0,0 +1,63 @@
|
|
1
|
+
declare const lightTheme: {
|
2
|
+
colors: {
|
3
|
+
backgroundColor: string;
|
4
|
+
typography: string;
|
5
|
+
accent: string;
|
6
|
+
barbie: string;
|
7
|
+
oak: string;
|
8
|
+
sky: string;
|
9
|
+
fog: string;
|
10
|
+
aloes: string;
|
11
|
+
blood: string;
|
12
|
+
};
|
13
|
+
gap: (v: number) => number;
|
14
|
+
};
|
15
|
+
declare const darkTheme: {
|
16
|
+
colors: {
|
17
|
+
backgroundColor: string;
|
18
|
+
typography: string;
|
19
|
+
accent: string;
|
20
|
+
barbie: string;
|
21
|
+
oak: string;
|
22
|
+
sky: string;
|
23
|
+
fog: string;
|
24
|
+
aloes: string;
|
25
|
+
blood: string;
|
26
|
+
};
|
27
|
+
gap: (v: number) => number;
|
28
|
+
};
|
29
|
+
declare const premiumTheme: {
|
30
|
+
colors: {
|
31
|
+
backgroundColor: string;
|
32
|
+
typography: string;
|
33
|
+
accent: string;
|
34
|
+
barbie: string;
|
35
|
+
oak: string;
|
36
|
+
sky: string;
|
37
|
+
fog: string;
|
38
|
+
aloes: string;
|
39
|
+
blood: string;
|
40
|
+
};
|
41
|
+
gap: (v: number) => number;
|
42
|
+
};
|
43
|
+
declare const breakpoints: {
|
44
|
+
xs: number;
|
45
|
+
sm: number;
|
46
|
+
md: number;
|
47
|
+
lg: number;
|
48
|
+
xl: number;
|
49
|
+
};
|
50
|
+
type AppBreakpoints = typeof breakpoints;
|
51
|
+
type AppThemes = {
|
52
|
+
light: typeof lightTheme;
|
53
|
+
dark: typeof darkTheme;
|
54
|
+
premium: typeof premiumTheme;
|
55
|
+
};
|
56
|
+
declare module 'react-native-unistyles' {
|
57
|
+
interface UnistylesThemes extends AppThemes {
|
58
|
+
}
|
59
|
+
interface UnistylesBreakpoints extends AppBreakpoints {
|
60
|
+
}
|
61
|
+
}
|
62
|
+
export {};
|
63
|
+
//# sourceMappingURL=unistyles.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"unistyles.d.ts","sourceRoot":"","sources":["../../../expo-example/unistyles.ts"],"names":[],"mappings":"AAWA,QAAA,MAAM,UAAU;;;;;;;;;;;;aAOH,MAAM;CAClB,CAAA;AAED,QAAA,MAAM,SAAS;;;;;;;;;;;;aAOF,MAAM;CAClB,CAAA;AAED,QAAA,MAAM,YAAY;;;;;;;;;;;;aAOL,MAAM;CAClB,CAAA;AAED,QAAA,MAAM,WAAW;;;;;;CAMhB,CAAA;AAED,KAAK,cAAc,GAAG,OAAO,WAAW,CAAA;AACxC,KAAK,SAAS,GAAG;IACb,KAAK,EAAE,OAAO,UAAU,CAAA;IACxB,IAAI,EAAE,OAAO,SAAS,CAAA;IACtB,OAAO,EAAE,OAAO,YAAY,CAAA;CAC/B,CAAA;AAED,OAAO,QAAQ,wBAAwB,CAAC;IACpC,UAAiB,eAAgB,SAAQ,SAAS;KAAG;IAErD,UAAiB,oBAAqB,SAAQ,cAAc;KAAG;CAClE"}
|
@@ -1,54 +1,4 @@
|
|
1
|
-
export declare const warn: (message: string) => void;
|
2
1
|
export declare const isWeb: boolean;
|
3
2
|
export declare const isIOS: boolean;
|
4
3
|
export declare const isAndroid: boolean;
|
5
|
-
export declare const isMobile: boolean;
|
6
|
-
export declare const isServer: boolean;
|
7
|
-
export declare const isDev: boolean;
|
8
|
-
export declare const isTest: boolean;
|
9
|
-
export declare const ScreenOrientation: {
|
10
|
-
readonly Landscape: "landscape";
|
11
|
-
readonly Portrait: "portrait";
|
12
|
-
};
|
13
|
-
export declare enum IOSContentSizeCategory {
|
14
|
-
AccessibilityExtraExtraExtraLarge = "accessibilityExtraExtraExtraLarge",
|
15
|
-
AccessibilityExtraExtraLarge = "accessibilityExtraExtraLarge",
|
16
|
-
AccessibilityExtraLarge = "accessibilityExtraLarge",
|
17
|
-
AccessibilityLarge = "accessibilityLarge",
|
18
|
-
AccessibilityMedium = "accessibilityMedium",
|
19
|
-
ExtraExtraExtraLarge = "xxxLarge",
|
20
|
-
ExtraExtraLarge = "xxLarge",
|
21
|
-
ExtraLarge = "xLarge",
|
22
|
-
Large = "Large",
|
23
|
-
Medium = "Medium",
|
24
|
-
Small = "Small",
|
25
|
-
ExtraSmall = "xSmall",
|
26
|
-
Unspecified = "unspecified"
|
27
|
-
}
|
28
|
-
export declare enum AndroidContentSizeCategory {
|
29
|
-
Small = "Small",
|
30
|
-
Default = "Default",
|
31
|
-
Large = "Large",
|
32
|
-
ExtraLarge = "ExtraLarge",
|
33
|
-
Huge = "Huge",
|
34
|
-
ExtraHuge = "ExtraHuge",
|
35
|
-
ExtraExtraHuge = "ExtraExtraHuge"
|
36
|
-
}
|
37
|
-
export declare enum UnistylesEventType {
|
38
|
-
Theme = "theme",
|
39
|
-
Layout = "layout",
|
40
|
-
Plugin = "plugin"
|
41
|
-
}
|
42
|
-
export declare enum UnistylesError {
|
43
|
-
RuntimeUnavailable = "Unistyles runtime is not available. Make sure you followed the installation instructions",
|
44
|
-
ThemeNotFound = "You are trying to get a theme that is not registered with UnistylesRegistry",
|
45
|
-
ThemeNotRegistered = "You are trying to set a theme that was not registered with UnistylesRegistry",
|
46
|
-
ThemeNotSelected = "Your themes are registered, but you didn't select the initial theme",
|
47
|
-
ThemesCannotBeEmpty = "You are trying to register empty themes object",
|
48
|
-
BreakpointsCannotBeEmpty = "You are trying to register empty breakpoints object",
|
49
|
-
BreakpointsMustStartFromZero = "You are trying to register breakpoints that don't start from 0",
|
50
|
-
InvalidPluginName = "Plugin name can't start from reserved prefix __unistyles",
|
51
|
-
DuplicatePluginName = "You are trying to register a plugin with a name that is already registered",
|
52
|
-
CantRemoveInternalPlugin = "You are trying to remove an internal unistyles plugin"
|
53
|
-
}
|
54
4
|
//# sourceMappingURL=common.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../src/common.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,
|
1
|
+
{"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../../src/common.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,KAAK,SAAwB,CAAA;AAC1C,eAAO,MAAM,KAAK,SAAwB,CAAA;AAC1C,eAAO,MAAM,SAAS,SAA4B,CAAA"}
|
@@ -1,77 +1,4 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
import type { UnistylesThemes, UnistylesBreakpoints } from './global';
|
5
|
-
import { ScreenOrientation, AndroidContentSizeCategory, IOSContentSizeCategory } from './common';
|
6
|
-
import { useStyles } from './useStyles';
|
7
|
-
import { createStyleSheet } from './createStyleSheet';
|
8
|
-
/**
|
9
|
-
* Utility to interact with the Unistyles
|
10
|
-
* (should be called only once)
|
11
|
-
*/
|
12
|
-
declare const UnistylesRegistry: {
|
13
|
-
/**
|
14
|
-
* Register themes to be used in the app
|
15
|
-
* @param themes - Key value pair of themes
|
16
|
-
*/
|
17
|
-
addThemes: (themes: UnistylesThemes) => {
|
18
|
-
addBreakpoints: (breakpoints: UnistylesBreakpoints) => {
|
19
|
-
addThemes: any;
|
20
|
-
addConfig: (config: import("./types").UnistylesConfig) => {
|
21
|
-
addBreakpoints: any;
|
22
|
-
addThemes: any;
|
23
|
-
};
|
24
|
-
};
|
25
|
-
addConfig: (config: import("./types").UnistylesConfig) => {
|
26
|
-
addBreakpoints: (breakpoints: UnistylesBreakpoints) => {
|
27
|
-
addThemes: any;
|
28
|
-
addConfig: any;
|
29
|
-
};
|
30
|
-
addThemes: any;
|
31
|
-
};
|
32
|
-
};
|
33
|
-
/**
|
34
|
-
* Register breakpoints to be used in the app
|
35
|
-
* @param breakpoints - Key value pair of breakpoints
|
36
|
-
*/
|
37
|
-
addBreakpoints: (breakpoints: UnistylesBreakpoints) => {
|
38
|
-
addThemes: (themes: UnistylesThemes) => {
|
39
|
-
addBreakpoints: any;
|
40
|
-
addConfig: (config: import("./types").UnistylesConfig) => {
|
41
|
-
addBreakpoints: any;
|
42
|
-
addThemes: any;
|
43
|
-
};
|
44
|
-
};
|
45
|
-
addConfig: (config: import("./types").UnistylesConfig) => {
|
46
|
-
addBreakpoints: any;
|
47
|
-
addThemes: (themes: UnistylesThemes) => {
|
48
|
-
addBreakpoints: any;
|
49
|
-
addConfig: any;
|
50
|
-
};
|
51
|
-
};
|
52
|
-
};
|
53
|
-
/**
|
54
|
-
* Register additional config to customize the Unistyles
|
55
|
-
* @param config - Key value pair of config
|
56
|
-
*/
|
57
|
-
addConfig: (config: import("./types").UnistylesConfig) => {
|
58
|
-
addBreakpoints: (breakpoints: UnistylesBreakpoints) => {
|
59
|
-
addThemes: (themes: UnistylesThemes) => {
|
60
|
-
addBreakpoints: any;
|
61
|
-
addConfig: any;
|
62
|
-
};
|
63
|
-
addConfig: any;
|
64
|
-
};
|
65
|
-
addThemes: (themes: UnistylesThemes) => {
|
66
|
-
addBreakpoints: (breakpoints: UnistylesBreakpoints) => {
|
67
|
-
addThemes: any;
|
68
|
-
addConfig: any;
|
69
|
-
};
|
70
|
-
addConfig: any;
|
71
|
-
};
|
72
|
-
};
|
73
|
-
};
|
74
|
-
declare const UnistylesRuntime: import("./core").UnistylesRuntime;
|
75
|
-
export { mq, useStyles, useInitialTheme, createStyleSheet, ScreenOrientation, AndroidContentSizeCategory, IOSContentSizeCategory, UnistylesRegistry, UnistylesRuntime };
|
76
|
-
export type { UnistylesTheme, UnistylesThemes, UnistylesBreakpoints, UnistylesPlugin, UnistylesValues, UnistyleText, UnistyleView, UnistyleImage, ExtractVariantNames as UnistylesVariants };
|
1
|
+
export * from './specs';
|
2
|
+
export { mq } from './mq';
|
3
|
+
export type { UnistylesThemes, UnistylesBreakpoints } from './global';
|
77
4
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAEA,cAAc,SAAS,CAAA;AACvB,OAAO,EAAE,EAAE,EAAE,MAAM,MAAM,CAAA;AACzB,YAAY,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA"}
|
@@ -1,5 +1,5 @@
|
|
1
|
-
import type { Nullable } from '
|
2
|
-
import type { UnistylesBreakpoints } from '
|
1
|
+
import type { Nullable } from './types';
|
2
|
+
import type { UnistylesBreakpoints } from './global';
|
3
3
|
type MQValue = keyof UnistylesBreakpoints | number;
|
4
4
|
type MQHandler = {
|
5
5
|
only: {
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"mq.d.ts","sourceRoot":"","sources":["../../../src/mq.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AACvC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAEpD,KAAK,OAAO,GAAG,MAAM,oBAAoB,GAAG,MAAM,CAAA;AAElD,KAAK,SAAS,GAAG;IACb,IAAI,EAAE;QACF,KAAK,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;QACxD,MAAM,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;KAC5D,CAAC;IACF,KAAK,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG;QAC7C,GAAG,EAAE;YACD,MAAM,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;SAC3D,CAAA;KACJ,CAAC;IACF,MAAM,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG;QAC9C,GAAG,EAAE;YACD,KAAK,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;SAC1D,CAAA;KACJ,CAAA;CACJ,CAAA;AAwBD;;;GAGG;AACH,eAAO,MAAM,EAAE,EAAE,SAiBhB,CAAA"}
|
@@ -0,0 +1,57 @@
|
|
1
|
+
import type { HybridObject } from 'react-native-nitro-modules';
|
2
|
+
import { type Dimensions, type Insets } from '../types';
|
3
|
+
type ColorScheme = 'dark' | 'light' | 'unspecified';
|
4
|
+
type Orientation = 'portrait' | 'landscape';
|
5
|
+
export declare enum UnistyleDependency {
|
6
|
+
Theme = 0,
|
7
|
+
ThemeName = 1,
|
8
|
+
AdaptiveThemes = 2,
|
9
|
+
Breakpoints = 3,
|
10
|
+
Variants = 4,
|
11
|
+
ColorScheme = 5,
|
12
|
+
Dimensions = 6,
|
13
|
+
Orientation = 7,
|
14
|
+
ContentSizeCategory = 8,
|
15
|
+
Insets = 9,
|
16
|
+
PixelRatio = 10,
|
17
|
+
FontScale = 11,
|
18
|
+
StatusBar = 12,
|
19
|
+
NavigationBar = 13
|
20
|
+
}
|
21
|
+
export interface UnistylesNativeMiniRuntime {
|
22
|
+
readonly colorScheme: ColorScheme;
|
23
|
+
readonly screen: Dimensions;
|
24
|
+
readonly contentSizeCategory: string;
|
25
|
+
readonly insets: Insets;
|
26
|
+
readonly pixelRatio: number;
|
27
|
+
readonly fontScale: number;
|
28
|
+
readonly rtl: boolean;
|
29
|
+
readonly statusBar: Dimensions;
|
30
|
+
readonly navigationBar: Dimensions;
|
31
|
+
readonly orientation: Orientation;
|
32
|
+
}
|
33
|
+
export interface NativePlatform extends HybridObject<{
|
34
|
+
ios: 'swift';
|
35
|
+
android: 'kotlin';
|
36
|
+
}> {
|
37
|
+
getInsets(): Insets;
|
38
|
+
getColorScheme(): ColorScheme;
|
39
|
+
getFontScale(): number;
|
40
|
+
getPixelRatio(): number;
|
41
|
+
getOrientation(): Orientation;
|
42
|
+
getContentSizeCategory(): string;
|
43
|
+
getScreenDimensions(): Dimensions;
|
44
|
+
getStatusBarDimensions(): Dimensions;
|
45
|
+
getNavigationBarDimensions(): Dimensions;
|
46
|
+
getPrefersRtlDirection(): boolean;
|
47
|
+
setRootViewBackgroundColor(color: number): void;
|
48
|
+
setNavigationBarBackgroundColor?(color: number): void;
|
49
|
+
setNavigationBarHidden?(isHidden: boolean): void;
|
50
|
+
setStatusBarHidden(isHidden: boolean): void;
|
51
|
+
setStatusBarBackgroundColor?(color: number): void;
|
52
|
+
setImmersiveMode(isEnabled: boolean): void;
|
53
|
+
getMiniRuntime(): UnistylesNativeMiniRuntime;
|
54
|
+
registerPlatformListener(callback: (dependencies: Array<UnistyleDependency>) => void): void;
|
55
|
+
}
|
56
|
+
export {};
|
57
|
+
//# sourceMappingURL=NativePlatform.nitro.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"NativePlatform.nitro.d.ts","sourceRoot":"","sources":["../../../../../src/specs/NativePlatform/NativePlatform.nitro.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAC9D,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,MAAM,EAAE,MAAM,UAAU,CAAA;AAEvD,KAAK,WAAW,GAAG,MAAM,GAAG,OAAO,GAAG,aAAa,CAAA;AACnD,KAAK,WAAW,GAAG,UAAU,GAAG,WAAW,CAAA;AAE3C,oBAAY,kBAAkB;IAC1B,KAAK,IAAI;IACT,SAAS,IAAI;IACb,cAAc,IAAI;IAClB,WAAW,IAAI;IACf,QAAQ,IAAI;IACZ,WAAW,IAAI;IACf,UAAU,IAAI;IACd,WAAW,IAAI;IACf,mBAAmB,IAAI;IACvB,MAAM,IAAI;IACV,UAAU,KAAK;IACf,SAAS,KAAK;IACd,SAAS,KAAK;IACd,aAAa,KAAK;CACrB;AAED,MAAM,WAAW,0BAA0B;IACvC,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAC;IAClC,QAAQ,CAAC,MAAM,EAAE,UAAU,CAAC;IAC5B,QAAQ,CAAC,mBAAmB,EAAE,MAAM,CAAC;IACrC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,GAAG,EAAE,OAAO,CAAA;IACrB,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;IAC/B,QAAQ,CAAC,aAAa,EAAE,UAAU,CAAA;IAClC,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAA;CACpC;AAID,MAAM,WAAW,cAAe,SAAQ,YAAY,CAAC;IAAE,GAAG,EAAE,OAAO,CAAC;IAAC,OAAO,EAAE,QAAQ,CAAA;CAAE,CAAC;IACrF,SAAS,IAAI,MAAM,CAAC;IACpB,cAAc,IAAI,WAAW,CAAC;IAC9B,YAAY,IAAI,MAAM,CAAC;IACvB,aAAa,IAAI,MAAM,CAAC;IACxB,cAAc,IAAI,WAAW,CAAC;IAC9B,sBAAsB,IAAI,MAAM,CAAC;IACjC,mBAAmB,IAAI,UAAU,CAAC;IAClC,sBAAsB,IAAI,UAAU,CAAC;IACrC,0BAA0B,IAAI,UAAU,CAAC;IACzC,sBAAsB,IAAI,OAAO,CAAC;IAElC,0BAA0B,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IAChD,+BAA+B,CAAC,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACtD,sBAAsB,CAAC,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAAC;IACjD,kBAAkB,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAAC;IAC5C,2BAA2B,CAAC,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IAClD,gBAAgB,CAAC,SAAS,EAAE,OAAO,GAAG,IAAI,CAAC;IAG3C,cAAc,IAAI,0BAA0B,CAAC;IAC7C,wBAAwB,CAAC,QAAQ,EAAE,CAAC,YAAY,EAAE,KAAK,CAAC,kBAAkB,CAAC,KAAK,IAAI,GAAG,IAAI,CAAA;CAC9F"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/specs/NativePlatform/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,cAAc,EAAE,0BAA0B,EAAE,MAAM,wBAAwB,CAAA;AACxF,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA"}
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import type { HybridObject } from 'react-native-nitro-modules';
|
2
|
+
export interface UnistylesNavigationBar extends HybridObject<{
|
3
|
+
ios: 'c++';
|
4
|
+
android: 'c++';
|
5
|
+
}> {
|
6
|
+
readonly width: number;
|
7
|
+
readonly height: number;
|
8
|
+
setBackgroundColor(color: number): void;
|
9
|
+
setHidden(isHidden: boolean): void;
|
10
|
+
}
|
11
|
+
//# sourceMappingURL=UnistylesNavigationBar.nitro.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"UnistylesNavigationBar.nitro.d.ts","sourceRoot":"","sources":["../../../../../src/specs/NavigtionBar/UnistylesNavigationBar.nitro.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAG9D,MAAM,WAAW,sBAAuB,SAAQ,YAAY,CAAC;IAAE,GAAG,EAAE,KAAK,CAAC;IAAC,OAAO,EAAE,KAAK,CAAA;CAAE,CAAC;IACxF,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACxC,SAAS,CAAC,QAAQ,EAAE,OAAO,GAAG,IAAI,CAAA;CACrC"}
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import type { UnistylesNavigationBar as UnistylesNavigationBarSpec } from './UnistylesNavigationBar.nitro';
|
2
|
+
import type { Color } from '../types';
|
3
|
+
interface PrivateUnistylesNavigationBar extends Omit<UnistylesNavigationBarSpec, 'setBackgroundColor'> {
|
4
|
+
setBackgroundColor(color?: string): void;
|
5
|
+
_setBackgroundColor(color?: Color): void;
|
6
|
+
}
|
7
|
+
export declare const attachNavigationBarJSMethods: (hybridObject: UnistylesNavigationBar) => void;
|
8
|
+
type PrivateMethods = '_setBackgroundColor' | 'dispose';
|
9
|
+
export type UnistylesNavigationBar = Omit<PrivateUnistylesNavigationBar, PrivateMethods>;
|
10
|
+
export {};
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/specs/NavigtionBar/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,IAAI,0BAA0B,EAAE,MAAM,gCAAgC,CAAA;AAC1G,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,UAAU,CAAA;AAErC,UAAU,6BAA8B,SAAQ,IAAI,CAAC,0BAA0B,EAAE,oBAAoB,CAAC;IAClG,kBAAkB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzC,mBAAmB,CAAC,KAAK,CAAC,EAAE,KAAK,GAAG,IAAI,CAAA;CAC3C;AAED,eAAO,MAAM,4BAA4B,iBAAkB,sBAAsB,SAShF,CAAA;AAED,KAAK,cAAc,GACb,qBAAqB,GACrB,SAAS,CAAA;AAEf,MAAM,MAAM,sBAAsB,GAAG,IAAI,CAAC,6BAA6B,EAAE,cAAc,CAAC,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"ShadowRegistry.nitro.d.ts","sourceRoot":"","sources":["../../../../../src/specs/ShadowRegistry/ShadowRegistry.nitro.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAE9D,MAAM,WAAW,uBAAwB,SAAQ,YAAY,CAAC;IAAE,GAAG,EAAE,KAAK,CAAC;IAAC,OAAO,EAAE,KAAK,CAAA;CAAE,CAAC;CAAG"}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
import type { UnistylesShadowRegistry as UnistylesShadowRegistrySpec } from './ShadowRegistry.nitro';
|
2
|
+
import type { ShadowNode, Unistyle, ViewHandle } from './types';
|
3
|
+
interface ShadowRegistry extends UnistylesShadowRegistrySpec {
|
4
|
+
add(handle?: ViewHandle, style?: Unistyle): void;
|
5
|
+
remove(handle?: ViewHandle, style?: Unistyle): void;
|
6
|
+
link(node: ShadowNode, style: Unistyle): void;
|
7
|
+
unlink(node: ShadowNode, style: Unistyle): void;
|
8
|
+
}
|
9
|
+
type PrivateMethods = 'add' | 'remove' | 'link' | 'unlink';
|
10
|
+
export declare const UnistylesShadowRegistry: Omit<ShadowRegistry, PrivateMethods>;
|
11
|
+
export {};
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/specs/ShadowRegistry/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,uBAAuB,IAAI,2BAA2B,EAAE,MAAM,wBAAwB,CAAA;AACpG,OAAO,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAE/D,UAAU,cAAe,SAAQ,2BAA2B;IAExD,GAAG,CAAC,MAAM,CAAC,EAAE,UAAU,EAAE,KAAK,CAAC,EAAE,QAAQ,GAAG,IAAI,CAAC;IACjD,MAAM,CAAC,MAAM,CAAC,EAAE,UAAU,EAAE,KAAK,CAAC,EAAE,QAAQ,GAAG,IAAI,CAAC;IAEpD,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,QAAQ,GAAG,IAAI,CAAC;IAC9C,MAAM,CAAC,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,QAAQ,GAAG,IAAI,CAAA;CAClD;AAiCD,KAAK,cAAc,GACb,KAAK,GACL,QAAQ,GACR,MAAM,GACN,QAAQ,CAAA;AAEd,eAAO,MAAM,uBAAuB,EAA2B,IAAI,CAAC,cAAc,EAAE,cAAc,CAAC,CAAA"}
|
@@ -0,0 +1,27 @@
|
|
1
|
+
export type StateNode = {
|
2
|
+
node?: ShadowNode;
|
3
|
+
};
|
4
|
+
export type ShadowNode = {
|
5
|
+
__hostObjectShadowNodeWrapper: any;
|
6
|
+
};
|
7
|
+
export type ViewHandle = {
|
8
|
+
__internalInstanceHandle?: {
|
9
|
+
stateNode?: StateNode;
|
10
|
+
};
|
11
|
+
getScrollResponder?: () => {
|
12
|
+
getNativeScrollRef?: () => ({
|
13
|
+
__internalInstanceHandle?: {
|
14
|
+
stateNode?: StateNode;
|
15
|
+
};
|
16
|
+
});
|
17
|
+
};
|
18
|
+
getNativeScrollRef?: () => ({
|
19
|
+
__internalInstanceHandle?: {
|
20
|
+
stateNode?: StateNode;
|
21
|
+
};
|
22
|
+
});
|
23
|
+
};
|
24
|
+
export type Unistyle = {
|
25
|
+
__unid?: number;
|
26
|
+
};
|
27
|
+
//# sourceMappingURL=types.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/specs/ShadowRegistry/types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,SAAS,GAAG;IACpB,IAAI,CAAC,EAAE,UAAU,CAAA;CACpB,CAAA;AAED,MAAM,MAAM,UAAU,GAAG;IACrB,6BAA6B,EAAE,GAAG,CAAA;CACrC,CAAA;AAED,MAAM,MAAM,UAAU,GAAG;IACrB,wBAAwB,CAAC,EAAE;QACvB,SAAS,CAAC,EAAE,SAAS,CAAA;KACxB,CAAC;IACF,kBAAkB,CAAC,EAAE,MAAM;QACvB,kBAAkB,CAAC,EAAE,MAAM,CAAC;YACxB,wBAAwB,CAAC,EAAE;gBACvB,SAAS,CAAC,EAAE,SAAS,CAAA;aACxB,CAAA;SACJ,CAAC,CAAA;KACL,CAAC;IACF,kBAAkB,CAAC,EAAE,MAAM,CAAC;QACxB,wBAAwB,CAAC,EAAE;YACvB,SAAS,CAAC,EAAE,SAAS,CAAA;SACxB,CAAA;KACJ,CAAC,CAAA;CACL,CAAA;AAED,MAAM,MAAM,QAAQ,GAAG;IACnB,MAAM,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA"}
|