Comparing version 4.3.0 to 4.3.1
@@ -5,2 +5,3 @@ import React from 'react'; | ||
import { useSx } from '../use-sx'; | ||
import { get } from '../css/get'; | ||
function Indicator(props) { | ||
@@ -10,4 +11,4 @@ const { colors } = useDripsyTheme().theme; | ||
let { color } = props; | ||
if (typeof color === 'string' && colors?.[color]) { | ||
color = colors[color]; | ||
if (typeof color === 'string' && colors) { | ||
color = get(colors, color) ?? color; | ||
} | ||
@@ -14,0 +15,0 @@ return (<NativeActivityIndicator {...props} color={color} style={[props.style, props.sx && sx(props.sx)]}/>); |
@@ -6,2 +6,3 @@ import React, { forwardRef } from 'react'; | ||
import { useDripsyTheme } from '../use-dripsy-theme'; | ||
import { get } from '../css/get'; | ||
const DripsyInput = createThemedComponent(rTextInput, { | ||
@@ -20,4 +21,4 @@ themeKey: 'forms', | ||
Object.keys(colorKeys).forEach((key) => { | ||
if (props[key] && theme?.colors && key in theme.colors) { | ||
props[key] = theme.colors[props[key]]; | ||
if (props[key] && theme?.colors) { | ||
props[key] = get(theme.colors, props[key]) ?? props[key]; | ||
} | ||
@@ -24,0 +25,0 @@ }); |
@@ -6,2 +6,3 @@ import { LinearGradient as ExpoLinearGradient } from 'expo-linear-gradient'; | ||
import { styled, useDripsyTheme, } from '../core'; | ||
import { get } from '../core/css/get'; | ||
const Grad = styled(React.memo(function Gradient({ style, stretch, gradient, colors, ...props }) { | ||
@@ -12,3 +13,3 @@ const { colors: themeColors, linearGradients } = useDripsyTheme().theme; | ||
// Return an empty array if the colors come back as undefined | ||
return (colorArray?.map((color) => themeColors?.[color] ?? color) ?? []); | ||
return (colorArray?.map((color) => themeColors ? get(themeColors, color) : color) ?? []); | ||
}; | ||
@@ -15,0 +16,0 @@ let gradientColors = []; |
@@ -6,2 +6,10 @@ # Change Log | ||
## [4.3.1](https://github.com/nandorojo/dripsy/compare/v4.2.0...v4.3.1) (2023-05-16) | ||
**Note:** Version bump only for package dripsy | ||
# [4.3.0](https://github.com/nandorojo/dripsy/compare/v4.2.0...v4.3.0) (2023-05-16) | ||
@@ -8,0 +16,0 @@ |
{ | ||
"name": "dripsy", | ||
"version": "4.3.0", | ||
"version": "4.3.1", | ||
"description": "🍷 A super-simple responsive design system for React Native Web.", | ||
@@ -42,9 +42,2 @@ "main": "build/index.js", | ||
"homepage": "https://github.com/nandorojo/dripsy#readme", | ||
"jest": { | ||
"preset": "react-native", | ||
"modulePathIgnorePatterns": [ | ||
"<rootDir>/example/node_modules", | ||
"<rootDir>/lib/" | ||
] | ||
}, | ||
"eslintIgnore": [ | ||
@@ -90,3 +83,3 @@ "node_modules/", | ||
"sideEffects": false, | ||
"gitHead": "9d409492bcf88c99d0e2888a440f7d074a4e6f35" | ||
"gitHead": "b5dfbbd904e1d3d8c4f8e50d2c923fe1c26e8fce" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
304026
207
4523