docstring_tokens
stringlengths
0
76.5k
code_tokens
stringlengths
75
1.81M
label_window
listlengths
4
2.12k
html_url
stringlengths
74
116
file_name
stringlengths
3
311
import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import React, { memo, forwardRef } from 'react'; <mask> import { View } from 'react-native'; <mask> import { usePropsResolutionTest } from '../../../hooks/useThemeProps'; <mask> import Text from './../Text'; <mask> import { makeStyledComponent } from '../../../utils/styled'; <mask> import type { IBoxProps ...
[ "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Box/index.tsx
const { _text, ...resolvedProps } = usePropsResolution('Box', props);
<mask> let MemoizedGradient: any = undefined; <mask> <mask> const Box = ({ children, ...props }: IBoxProps, ref: any) => { <mask> // const { _text, ...resolvedProps } = useThemeProps('Box', props); <mask> const { _text, ...resolvedProps } = usePropsResolutionTest('Box', props); <mask> let Gradient = useNat...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Box/index.tsx
import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import React, { memo, forwardRef } from 'react'; <mask> import Spinner from '../Spinner'; <mask> import { usePropsResolutionTest } from '../../../hooks/useThemeProps'; <mask> import { default as Box, IBoxProps } from '../Box'; <mask> import HStack from '../Stack/HStack'; <mask> import { Pressable } from '....
[ "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Button/Button.tsx
} = usePropsResolution('Button', props);
<mask> _pressed, <mask> _focusVisible, <mask> _stack, <mask> ...resolvedProps <mask> } = usePropsResolutionTest('Button', props); <mask> <mask> const pressableProps = { <mask> ...resolvedProps, <mask> _hover, <mask> _pressed, </s> feat: added support for gradiant and contrast...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Button/Button.tsx
import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import React, { forwardRef, memo } from 'react'; <mask> import { Pressable as RNPressable } from 'react-native'; <mask> import { composeEventHandlers } from '../../../utils'; <mask> import type { IPressableProps } from './types'; <mask> import { <mask> usePropsResolution, <mask> usePropsResolutionTest...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Pressable/Pressable.tsx
} = usePropsResolution('Pressable', props, {
<mask> onHoverOut, <mask> onFocus, <mask> onBlur, <mask> ...resolvedProps <mask> } = usePropsResolutionTest('Pressable', props, { <mask> isHovered, <mask> isPressed, <mask> isFocused, <mask> isFocusVisible, <mask> }); </s> feat: added support for gradiant and contrast text...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Pressable/Pressable.tsx
import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import React, { memo, forwardRef, useRef } from 'react'; <mask> import { Text as NativeText } from 'react-native'; <mask> import { <mask> usePropsResolutionTest, <mask> usePropsResolution, <mask> } from '../../../hooks/useThemeProps'; <mask> import type { ITextProps } from './types'; <mask> import { ...
[ "keep", "keep", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Text/index.tsx
} = usePropsResolution('Text', props);
<mask> fontStyle: propFontStyle, <mask> _hover, <mask> fontSize = 'md', <mask> ...reslovedProps <mask> } = usePropsResolutionTest('Text', props); <mask> <mask> const _ref = useRef(null); <mask> // TODO: might have to add this condition <mask> const { isHovered } = useHover({}, _hover ?...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/components/primitives/Text/index.tsx
export { usePropsResolutionTest } from './useThemeProps/usePropsResolutionTest';
<mask> export { useThemeProps, usePropsWithComponentTheme } from './useThemeProps'; <mask> // TODO: instead export only this. <mask> export { usePropsResolution } from './useThemeProps'; <mask> export { useTheme } from './useTheme'; <mask> export { useToken } from './useToken'; <mask> export { useSafeArea } from ...
[ "keep", "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/index.ts
<mask> export { useThemeProps } from './useProps'; <mask> export { usePropsResolution } from './usePropsResolution'; <mask> export { usePropsResolutionTest } from './usePropsResolutionTest'; <mask> export { usePropsWithComponentTheme } from './usePropsWithComponentTheme'; </s> feat: added support for gradiant and ...
[ "keep", "keep", "replace", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/index.ts
import { useFlattenProps } from './useFlattenProps'; const specificityOrder = [ 'p', 'padding', 'px', 'py', 'pt', 'pb', 'pl', 'pr', 'paddingTop', 'paddingBottom', 'paddingLeft', 'paddingRight', 'm', 'margin', 'mx', 'my', 'mt', 'mb', 'ml', 'mr', 'marginTop', 'marginBottom', ...
<mask> import { useColorMode } from '../../core/color-mode'; <mask> import { omitUndefined, extractInObject } from '../../theme/tools'; <mask> import { useContrastText } from '../useContrastText'; <mask> import { useBreakpointResolvedProps } from '../useBreakpointResolvedProps'; <mask> <mask> // TODO: have to re...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
let marginMap: any = { mx: ['marginRight', 'marginLeft'], my: ['marginTop', 'marginBottom'], mt: ['marginTop'], mb: ['marginBottom'], mr: ['marginRight'], ml: ['marginLeft'],
<mask> '_hover', <mask> '_pressed', <mask> '_focused', <mask> ]; <mask> const pseudoPropsMap = { <mask> _web: 'web', <mask> _ios: 'ios', <mask> _android: 'android', <mask> <mask> _light: 'light', <mask> _dark: 'dark', <mask> <mask> // TODO: have to add more interactionProps and statePro...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
marginMap.margin = [...marginMap.mx, ...marginMap.my]; marginMap.m = marginMap.margin; marginMap.marginTop = marginMap.mt; marginMap.marginBottom = marginMap.mb; marginMap.marginLeft = marginMap.ml; marginMap.marginRight = marginMap.mr; let paddingMap: any = { px: ['paddingRight', 'paddingLeft'], py: ['paddingTop'...
<mask> _indeterminate: 'isIndeterminate', <mask> _checked: 'isChecked', <mask> }; <mask> <mask> /** <mask> * @summary Check weather provided property should be resolved or not. based on plaform, colormode and state <mask> * @arg {string} property - . <mask> * @arg {object} platform - . <mask> * @arg {...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "ke...
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
paddingMap.padding = [...paddingMap.px, ...paddingMap.py]; paddingMap.p = paddingMap.padding; paddingMap.paddingTop = paddingMap.pt; paddingMap.paddingBottom = paddingMap.pb; paddingMap.paddingLeft = paddingMap.pl; paddingMap.paddingRight = paddingMap.pr;
<mask> return false; <mask> } <mask> }; <mask> <mask> let flattenProps: any = {}; <mask> let propertyDepth: any = {}; <mask> <mask> /** <mask> * @summary Resolved pseudo props and returns a flattened object. <mask> * @arg {object} {props, platform, colorMode, state} - . <mask> * @arg {number} curr...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
const specificityMaps: any = { ...paddingMap, ...marginMap,
<mask> <mask> let flattenProps: any = {}; <mask> let propertyDepth: any = {}; <mask> <mask> /** <mask> * @summary Resolved pseudo props and returns a flattened object. <mask> * @arg {object} {props, platform, colorMode, state} - . <mask> * @arg {number} currentDepth - . <mask> * @returns {object} Resolve...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "re...
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
let [flattenProps, specificityMap] = useFlattenProps(
<mask> componentTheme.defaultProps || {}, <mask> cleanIncomingProps <mask> ); <mask> // STEP 2: flatten them <mask> pseudoPropsResolver( <mask> { <mask> props: incomingWithDefaultProps, <mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mask> s...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
<mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mask> state: state || {}, <mask> }, <mask> // some high value <mask> 2 <mask> ); <mask> <mask> // STEP 2.5: resolving responsive props <mask> const responsiveProps = {}; </s> feat: added support fo...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
flattenProps = { ...flattenProps, ...responsivelyResolvedProps, };
<mask> }); <mask> <mask> const responsivelyResolvedProps = useBreakpointResolvedProps(responsiveProps); <mask> <mask> flattenProps = { ...flattenProps, ...responsivelyResolvedProps }; <mask> // STEP 3: Pass it to baseStyle, then variant and then size and resolve them. <mask> <mask> // NOTE: Resolov...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
let componentBaseStyle = {}, flattenBaseStyle, baseSpecificityMap;
<mask> flattenProps = { ...flattenProps, ...responsivelyResolvedProps }; <mask> // STEP 3: Pass it to baseStyle, then variant and then size and resolve them. <mask> <mask> // NOTE: Resoloving baseStyle <mask> let componentBaseStyle = {}; <mask> if (componentTheme.baseStyle) { <mask> componentBaseS...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
[flattenBaseStyle, baseSpecificityMap] = useFlattenProps(
<mask> ...flattenProps, <mask> ...colorModeProps, <mask> }); <mask> <mask> pseudoPropsResolver( <mask> { <mask> props: componentBaseStyle, <mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mask> state: state ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
currentSpecificityMap: specificityMap,
<mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mask> state: state || {}, <mask> }, <mask> 1 <mask> ); <mask> } <mask> </s> feat: added support for gradiant and contrast text </s> remove // some high value </s> add </s> remove pseu...
[ "keep", "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
<mask> ); <mask> } <mask> <mask> // NOTE: Resolving variants <mask> // const variant = resolveValueWithBreakpoint( <mask> // flattenProps.variant, <mask> // currentBreakpoint, <mask> // 'variant' <mask> // ); <mask> const variant = flattenProps.variant; <mask> <mask> let compon...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
let componentVariantProps = {}, flattenVariantStyle, variantSpecificityMap;
<mask> // 'variant' <mask> // ); <mask> const variant = flattenProps.variant; <mask> <mask> let componentVariantProps = {}; <mask> // Extracting props from variant <mask> if (variant && componentTheme.variants && componentTheme.variants[variant]) { <mask> componentVariantProps = <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
[flattenVariantStyle, variantSpecificityMap] = useFlattenProps(
<mask> ...flattenProps, <mask> ...colorModeProps, <mask> }); <mask> <mask> pseudoPropsResolver( <mask> { <mask> props: componentVariantProps, <mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mask> state: sta...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
currentSpecificityMap: baseSpecificityMap || specificityMap,
<mask> colormode: colorModeProps.colorMode, <mask> state: state || {}, <mask> }, <mask> 1 <mask> ); <mask> <mask> // We remove variant from original props if we found it in the componentTheme </s> feat: added support for gradiant and contrast text </s> remove // some hig...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
<mask> flattenProps.variant = undefined; <mask> } <mask> <mask> // NOTE: Resolving size <mask> // const size = resolveValueWithBreakpoint( <mask> // flattenProps.size, <mask> // currentBreakpoint, <mask> // 'size' <mask> // ); <mask> <mask> const size = flattenProps.size; <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
let componentSizeProps = {}, flattenSizeStyle;
<mask> // ); <mask> <mask> const size = flattenProps.size; <mask> <mask> let componentSizeProps = {}; <mask> // Extracting props from size <mask> if (size && componentTheme.sizes && componentTheme.sizes[size]) { <mask> // Type - sizes: {lg: 1}. Refer icon theme <mask> if ( <mask> typ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
flattenProps.size = componentTheme.sizes[size];
<mask> if ( <mask> typeof componentTheme.sizes[size] === 'string' || <mask> typeof componentTheme.sizes[size] === 'number' <mask> ) { <mask> flattenProps.size = undefined; <mask> //@ts-ignore <mask> componentSizeProps.size = componentTheme.sizes[size]; <mask> } <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
// componentSizeProps.size = componentTheme.sizes[size];
<mask> typeof componentTheme.sizes[size] === 'number' <mask> ) { <mask> flattenProps.size = undefined; <mask> //@ts-ignore <mask> componentSizeProps.size = componentTheme.sizes[size]; <mask> } <mask> // Type - sizes: (props) => ({lg: {px: 1}}). Refer heading theme <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
[flattenSizeStyle] = useFlattenProps(
<mask> flattenProps.size = undefined; <mask> componentSizeProps = componentTheme.sizes[size]; <mask> } <mask> <mask> pseudoPropsResolver( <mask> { <mask> props: componentSizeProps, <mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mas...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
currentSpecificityMap: variantSpecificityMap || baseSpecificityMap || specificityMap,
<mask> props: componentSizeProps, <mask> platform: Platform.OS, <mask> colormode: colorModeProps.colorMode, <mask> state: state || {}, <mask> }, <mask> 1 <mask> ); <mask> } </s> feat: added support for gradiant and contrast text </s> remove pseudoPropsResol...
[ "keep", "keep", "keep", "add", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
// // STEP 4: merge const defaultStyles = merge( flattenBaseStyle, flattenVariantStyle, flattenSizeStyle ); flattenProps = overrideDefaultProps(flattenProps, defaultStyles);
<mask> 1 <mask> ); <mask> } <mask> <mask> // STEP 4: Merge <mask> <mask> // STEP 5: linear Grad and contrastText <mask> let ignore: any = []; <mask> if ( <mask> flattenProps.bg?.linearGradient || </s> feat: added support for gradiant and contrast text </s> remove // STEP 5: linear...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
// // STEP 5: linear Grad and contrastText
<mask> } <mask> <mask> // STEP 4: Merge <mask> <mask> // STEP 5: linear Grad and contrastText <mask> let ignore: any = []; <mask> if ( <mask> flattenProps.bg?.linearGradient || <mask> flattenProps.background?.linearGradient || <mask> flattenProps.bgColor?.linearGradient || </s> feat: ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
// // NOTE: seprating bg props when linearGardiant is available
<mask> return get(theme.colors, color, color); <mask> }); <mask> ignore = ['bg', 'background', 'backgroundColor', 'bgColor']; <mask> } <mask> // NOTE: seprating bg props when linearGardiant is available <mask> const [gradientProps] = extractInObject(flattenProps, ignore); <mask> <mask> le...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
// flattenProps = {}; // propertyDepth = {};
<mask> ...gradientProps, <mask> }); <mask> // STEP 6: Return <mask> <mask> flattenProps = {}; <mask> propertyDepth = {}; <mask> <mask> return resolvedProps; <mask> } </s> feat: added support for gradiant and contrast text </s> remove // ...gradientProps, </s> add ...gradientProps, </s...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolution.tsx
flattenProps.size = componentTheme.sizes[size];
<mask> if ( <mask> typeof componentTheme.sizes[size] === 'string' || <mask> typeof componentTheme.sizes[size] === 'number' <mask> ) { <mask> flattenProps.size = undefined; <mask> //@ts-ignore <mask> componentSizeProps.size = componentTheme.sizes[size]; <mask> } <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
// componentSizeProps.size = componentTheme.sizes[size];
<mask> typeof componentTheme.sizes[size] === 'number' <mask> ) { <mask> flattenProps.size = undefined; <mask> //@ts-ignore <mask> componentSizeProps.size = componentTheme.sizes[size]; <mask> } <mask> // Type - sizes: (props) => ({lg: {px: 1}}). Refer heading theme <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
let ignore: any = []; if ( flattenProps.bg?.linearGradient || flattenProps.background?.linearGradient || flattenProps.bgColor?.linearGradient || flattenProps.backgroundColor?.linearGradient ) { let bgProp = 'bg'; if (flattenProps.background?.linearGradient) { bgProp = 'background'; ...
<mask> <mask> flattenProps = overrideDefaultProps(flattenProps, defaultStyles); <mask> <mask> // // STEP 5: linear Grad and contrastText <mask> // let ignore: any = []; <mask> // if ( <mask> // flattenProps.bg?.linearGradient || <mask> // flattenProps.background?.linearGradient || <mask> //...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "re...
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
const [gradientProps] = extractInObject(flattenProps, ignore);
<mask> // }); <mask> // ignore = ['bg', 'background', 'backgroundColor', 'bgColor']; <mask> // } <mask> // // NOTE: seprating bg props when linearGardiant is available <mask> // const [gradientProps] = extractInObject(flattenProps, ignore); <mask> <mask> // let bgColor = <mask> // flattenPr...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
let bgColor = flattenProps.bg ?? flattenProps.backgroundColor ?? flattenProps.bgColor;
<mask> // } <mask> // // NOTE: seprating bg props when linearGardiant is available <mask> // const [gradientProps] = extractInObject(flattenProps, ignore); <mask> <mask> // let bgColor = <mask> // flattenProps.bg ?? flattenProps.backgroundColor ?? flattenProps.bgColor; <mask> <mask> // const con...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
const contrastTextColor = useContrastText( bgColor, flattenProps?._text?.color );
<mask> <mask> // let bgColor = <mask> // flattenProps.bg ?? flattenProps.backgroundColor ?? flattenProps.bgColor; <mask> <mask> // const contrastTextColor = useContrastText( <mask> // bgColor, <mask> // flattenProps?._text?.color <mask> // ); <mask> <mask> // flattenProps._text = <mask...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
flattenProps._text = contrastTextColor && flattenProps?._text?.color === undefined ? { color: contrastTextColor, ...flattenProps._text, } : flattenProps._text;
<mask> // bgColor, <mask> // flattenProps?._text?.color <mask> // ); <mask> <mask> // flattenProps._text = <mask> // contrastTextColor && flattenProps?._text?.color === undefined <mask> // ? { <mask> // color: contrastTextColor, <mask> // ...flattenProps._text, <mask...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
...gradientProps,
<mask> <mask> const resolvedProps = omitUndefined({ <mask> ...flattenProps, <mask> ...ignoredProps, <mask> // ...gradientProps, <mask> }); <mask> // STEP 6: Return <mask> <mask> // flattenProps = {}; <mask> // propertyDepth = {}; </s> feat: added support for gradiant and contrast text...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8c8f25bf84172d867d3f6146ef6fc1d75f965c51
src/hooks/useThemeProps/usePropsResolutionTest.tsx
<mask> ], <mask> "scripts": { <mask> "test": "node_modules/.bin/jest", <mask> "typescript": "tsc --noEmit", <mask> "lint": "eslint \"**/*.{js,ts,tsx}\"", <mask> "prepare": "bob build", <mask> "release": "release-it", <mask> "example": "yarn --cwd example", <mask> "pods": "cd exa...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8d507391100dd373a67513dad78847b96eae6db8
package.json
"lint-staged": { "src/**/*.{js,ts,tsx}": [ "eslint" ], "example/**/*.{js,ts,tsx}": [ "eslint" ], "*.{json,md,html}": [ "prettier --write" ] },
<mask> "bootstrap": "yarn example && yarn && yarn pods", <mask> "build:web": "rollup --config", <mask> "bundle:analysis": "visualize-bundle" <mask> }, <mask> "version": "3.0.6", <mask> "license": "Apache-2.0", <mask> "private": false, <mask> "main": "lib/commonjs/index", <mask> "module"...
[ "keep", "keep", "keep", "add", "keep", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8d507391100dd373a67513dad78847b96eae6db8
package.json
"lint-staged": "^11.1.1",
<mask> "husky": "^4.2.5", <mask> "jest": "^26.0.1", <mask> "jest-expo": "^40.0.1", <mask> "metro-react-native-babel-preset": "^0.64.0", <mask> "pod-install": "^0.1.0", <mask> "postinstall-postinstall": "^2.1.0", <mask> "prettier": "^2.0.5", <mask> "react": "16.11.0", <mask> ...
[ "keep", "keep", "add", "keep", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8d507391100dd373a67513dad78847b96eae6db8
package.json
"pre-commit": "yarn lint-staged && yarn prepare"
<mask> }, <mask> "husky": { <mask> "hooks": { <mask> "commit-msg": "commitlint -E HUSKY_GIT_PARAMS", <mask> "pre-commit": "yarn lint && yarn prepare" <mask> } <mask> }, <mask> "commitlint": { <mask> "extends": [ <mask> "@commitlint/config-conventional" </s> chore: add li...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8d507391100dd373a67513dad78847b96eae6db8
package.json
"cli.js",
<mask> }, <mask> "eslintIgnore": [ <mask> "node_modules/", <mask> "lib/", <mask> "example/webpack.config.js", <mask> "example/babel.config.js", <mask> "example/metro.config.js" <mask> ], </s> chore: add lint staged on pre commit </s> remove "pre-commit": "yarn lint && yarn prepa...
[ "keep", "keep", "keep", "add", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8d507391100dd373a67513dad78847b96eae6db8
package.json
<mask> import type { ISelectProps } from './types'; <mask> import { usePopover } from '../../../core'; <mask> import Button from '../Button'; <mask> import { ScrollView } from 'react-native'; <mask> import { SelectContext } from './Context'; <mask> import { useThemeProps } from '../../../hooks'; <mask> import { ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
const updatedChildren = React.Children.map(children, (child: any) => { return React.cloneElement( child, { variant: variant, }, child.props.children ); });
<mask> let triggerRef = React.useRef(); <mask> const { isHovered } = useHover({}, ref ?? triggerRef); <mask> let [isOpen, toggle] = React.useState<boolean>(false); <mask> let itemsList: Array<{ label: string; value: string }> = React.Children.map( <mask> updatedChildren, <mask> (child: any) => { ...
[ "keep", "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
updatedChildren,
<mask> let triggerRef = React.useRef(); <mask> const { isHovered } = useHover({}, ref ?? triggerRef); <mask> let [isOpen, toggle] = React.useState<boolean>(false); <mask> let itemsList: Array<{ label: string; value: string }> = React.Children.map( <mask> children, <mask> (child: any) => { <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
return { label: child.props.label, value: child.props.value, variant: child.props.variant, };
<mask> let [isOpen, toggle] = React.useState<boolean>(false); <mask> let itemsList: Array<{ label: string; value: string }> = React.Children.map( <mask> children, <mask> (child: any) => { <mask> return { label: child.props.label, value: child.props.value }; <mask> } <mask> ); <mask> co...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
variant: 'styled',
<mask> itemsList, <mask> _item, <mask> width, <mask> }, <mask> }); <mask> toggle(true); <mask> } </s> fix: removed context and aligned with variant props </s> remove }, } = usePopover(); console.log(variant); </s> add width, } = parentComp...
[ "keep", "keep", "add", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
<mask> ? dropdownCloseIcon <mask> : null; <mask> const placeholderProps = selectedItem ? {} : _placeholder; <mask> <mask> console.log('newProps = ', newProps); <mask> console.log('varaiant = ', variant); <mask> <mask> const StyledSelect = ( <mask> <Button <mask> onPress={openMe...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
{updatedChildren}
<mask> {...(Platform.OS === 'web' && _web)} <mask> {...(isInvalid && _isInvalid)} <mask> {...(isHovered && _hover)} <mask> > <mask> {children} <mask> </StyledNativePicker> <mask> ); <mask> return ( <mask> <SelectContext.Provider <mask> value={{ </s> fix: removed ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
return variant === 'styled' ? StyledSelect : NativeSelect;
<mask> > <mask> {children} <mask> </StyledNativePicker> <mask> ); <mask> return ( <mask> <SelectContext.Provider <mask> value={{ <mask> variant: variant, <mask> }} <mask> > <mask> {variant === 'styled' ? StyledSelect : NativeSelect} <mask> </SelectCont...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/Select.tsx
import type { ISelectItemProps } from './types';
<mask> import React from 'react'; <mask> import type { ISelectItemProps, ISelectContextProps } from './types'; <mask> import { usePopover } from '../../../core'; <mask> import Button from '../Button'; <mask> import Text from '../Text'; <mask> import { Picker as RNPicker } from '@react-native-picker/picker'; <mas...
[ "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
import { useThemeProps } from '../../../hooks';
<mask> import { usePopover } from '../../../core'; <mask> import Button from '../Button'; <mask> import Text from '../Text'; <mask> import { Picker as RNPicker } from '@react-native-picker/picker'; <mask> import { SelectContext } from './Context'; <mask> <mask> export const Item = ({ <mask> isDisabled, <mas...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
const { parentComponentConfig } = usePopover(); const { ...newProps } = useThemeProps('SelectItem', props); if (parentComponentConfig?.variant === 'styled') { const {
<mask> _label, <mask> style, <mask> ...props <mask> }: ISelectItemProps) => { <mask> const { variant }: ISelectContextProps = React.useContext(SelectContext); <mask> const { <mask> parentComponentConfig: { <mask> selectedValue, <mask> closeMenu, <mask> selectedItemBg, <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
width, } = parentComponentConfig;
<mask> _selectedItem, <mask> onValueChange, <mask> itemsList, <mask> _item, <mask> }, <mask> } = usePopover(); <mask> console.log(variant); <mask> <mask> let currentIndex = -1; <mask> itemsList.forEach((item: any, index: number) => { <mask> if (item.value === value) {...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
let currentIndex = -1; itemsList.forEach((item: any, index: number) => { if (item.value === value) { currentIndex = index; } }); let textProps = { ..._item, ..._label }; if (selectedValue === value) { textProps = { ..._selectedItem };
<mask> }, <mask> } = usePopover(); <mask> console.log(variant); <mask> <mask> let currentIndex = -1; <mask> itemsList.forEach((item: any, index: number) => { <mask> if (item.value === value) { <mask> currentIndex = index; <mask> } <mask> }); <mask> let textProps = { ..._item, ....
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
return ( <Button width={width ?? 150} {...newProps} bg={selectedValue === value ? selectedItemBg : undefined} justifyContent="flex-start" style={style} onPress={() => { if (!isDisabled) { onValueChange(value, currentIndex); clos...
<mask> itemsList.forEach((item: any, index: number) => { <mask> if (item.value === value) { <mask> currentIndex = index; <mask> } <mask> }); <mask> let textProps = { ..._item, ..._label }; <mask> if (selectedValue === value) { <mask> textProps = { ..._selectedItem }; <mask> } <mask...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
<mask> let textProps = { ..._item, ..._label }; <mask> if (selectedValue === value) { <mask> textProps = { ..._selectedItem }; <mask> } <mask> <mask> return variant === 'styled' ? ( <mask> <Button <mask> p={1} <mask> px={2} <mask> rounded={0} <mask> minH={0} <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "re...
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/SelectItem.tsx
<mask> label: string; <mask> value: string; <mask> _label?: ITextProps; <mask> }; <mask> export type ISelectContextProps = { <mask> variant?: string; <mask> }; <mask> <mask> export type ISelectComponentType = ((props: ISelectProps) => JSX.Element) & { <mask> Item: React.MemoExoticComponent<(props: ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/components/primitives/Select/types.ts
import { Select, SelectItem } from './select';
<mask> ActionsheetHeader, <mask> ActionsheetFooter, <mask> ActionsheetItem, <mask> } from './actionsheet'; <mask> import { Select, Picker } from './select'; <mask> import { Alert, AlertDescription, AlertTitle } from './alert'; <mask> import Avatar from './avatar'; <mask> import AvatarBadge from './avatar-...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/index.ts
SelectItem,
<mask> Progress, <mask> Radio, <mask> ScaleFade, <mask> Select, <mask> Picker, <mask> Skeleton, <mask> Slide, <mask> SlideFade, <mask> Slider, <mask> SliderThumb, </s> fix: removed context and aligned with variant props </s> remove import { Select, Picker } from './select'; </s> add impo...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/index.ts
// styled const styled = (props: Record<string, any>) => {
<mask> import { mode } from '../tools/colors'; <mask> <mask> // Select <mask> export const styled = (props: Record<string, any>) => { <mask> return { <mask> pl: 2, <mask> pr: 0, <mask> border: 1, <mask> borderColor: mode('gray.600', 'gray.400')(props), </s> fix: removed context and aligned ...
[ "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
variant: 'styled',
<mask> <mask> // styled <mask> const styled = (props: Record<string, any>) => { <mask> return { <mask> pl: 2, <mask> pr: 0, <mask> border: 1, <mask> borderColor: mode('gray.600', 'gray.400')(props), </s> fix: removed context and aligned with variant props </s> remove // Select export const s...
[ "keep", "keep", "keep", "add", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
// native const native = (props: Record<string, any>) => {
<mask> }, <mask> }; <mask> }; <mask> <mask> // Picker <mask> export const native = (props: Record<string, any>) => { <mask> return { <mask> _android: { <mask> p: 2, <mask> color: mode('gray.800', 'gray.50')(props), <mask> }, </s> fix: removed context and aligned with variant pro...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
variant: 'native',
<mask> const native = (props: Record<string, any>) => { <mask> return { <mask> _android: { <mask> p: 2, <mask> color: mode('gray.800', 'gray.50')(props), <mask> }, <mask> _ios: {}, </s> fix: removed context and aligned with variant props </s> remove // Picker export const native = (pro...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
// Select
<mask> native: native, <mask> }; <mask> <mask> export const Select = { <mask> variants, <mask> defaultProps: { <mask> variant: 'native', <mask> }, </s> fix: removed context and aligned with variant props </s> remove // SelectItem export const SelectItem = {}; </s> add </s> remove // Select expor...
[ "keep", "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
<mask> defaultProps: { <mask> variant: 'native', <mask> }, <mask> }; <mask> // SelectItem <mask> export const SelectItem = {}; <mask> <mask> // SelectIcon <mask> export const SelectIcon = {}; </s> fix: removed context and aligned with variant props </s> remove // SelectIcon export const SelectIcon = ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
// SelectIcon - only for styled variant export const SelectItem = { baseStyle: { p: 1, px: 2, borderRadius: 0, minH: 0, }, };
<mask> }; <mask> // SelectItem <mask> export const SelectItem = {}; <mask> <mask> // SelectIcon <mask> export const SelectIcon = {}; </s> fix: removed context and aligned with variant props </s> remove // SelectItem export const SelectItem = {}; </s> add </s> remove // Picker export const native = (props: Rec...
[ "keep", "keep", "keep", "keep", "replace", "replace" ]
https://github.com/GeekyAnts/NativeBase/commit/8ddcc7433046c3f3bb6e616546ce467c0d0a2876
src/theme/components/select.ts
import type { Text as TextType } from 'react-native';
<mask> import React from 'react'; <mask> import { Text } from 'react-native'; <mask> import styled from 'styled-components/native'; <mask> import { <mask> border, <mask> color, <mask> flexbox, <mask> layout, </s> feat: forwardref in essential components </s> remove const Text = ({ children, style, ...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Heading/index.tsx
const Heading = ({ isTruncated, ...props }: IHeadingProps, ref: any) => {
<mask> customLayout, <mask> customTypography <mask> ); <mask> <mask> const Heading = ({ isTruncated, ...props }: IHeadingProps) => { <mask> const newProps = usePropsConfig('Heading', props); <mask> return ( <mask> <StyledHeading numberOfLines={isTruncated ? 1 : 999999} {...newProps} /> <mask> );...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Heading/index.tsx
<StyledHeading numberOfLines={isTruncated ? 1 : 999999} {...newProps} ref={ref} />
<mask> <mask> const Heading = ({ isTruncated, ...props }: IHeadingProps) => { <mask> const newProps = usePropsConfig('Heading', props); <mask> return ( <mask> <StyledHeading numberOfLines={isTruncated ? 1 : 999999} {...newProps} /> <mask> ); <mask> }; <mask> <mask> export default Heading; <mask> e...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Heading/index.tsx
export default React.forwardRef<TextType, IHeadingProps>(Heading);
<mask> <StyledHeading numberOfLines={isTruncated ? 1 : 999999} {...newProps} /> <mask> ); <mask> }; <mask> <mask> export default Heading; <mask> export type { IHeadingProps }; </s> feat: forwardref in essential components </s> remove <StyledHeading numberOfLines={isTruncated ? 1 : 999999} {...newProps...
[ "keep", "keep", "keep", "keep", "replace", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Heading/index.tsx
import type { View as ViewType } from 'react-native';
<mask> import React from 'react'; <mask> import { TouchableWithoutFeedback, StyleSheet } from 'react-native'; <mask> import View from './../View'; <mask> import styled from 'styled-components/native'; <mask> import { addTextAndPropsToStrings } from '../../../utils'; <mask> import type { ILinkProps } from './props...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Link/index.tsx
const Link = ( { style, href, isUnderlined = true, onClick, isExternal, children, m, mt, mr, ml, mb, p, pt, pl, pr, pb, w, width, h, height, ...props }: ILinkProps, ref: any ) => {
<mask> ); <mask> }); <mask> }; <mask> <mask> const Link = ({ <mask> style, <mask> href, <mask> isUnderlined = true, <mask> onClick, <mask> isExternal, <mask> children, <mask> m, <mask> mt, <mask> mr, <mask> ml, <mask> mb, <mask> p, <mask> pt, <mask> pl, <mask> pr...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "re...
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Link/index.tsx
<TouchableWithoutFeedback {...linkProps} {...newProps} ref={ref}>
<mask> const { linkProps } = useLink({ href, onClick, isExternal }); <mask> <mask> return ( <mask> <Box {...layoutProps}> <mask> <TouchableWithoutFeedback {...linkProps} {...newProps}> <mask> <StyledLink <mask> {...newProps} <mask> textDecorationLine={isUnderlined ? 'u...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Link/index.tsx
export default React.forwardRef<ViewType, ILinkProps>(Link);
<mask> </Box> <mask> ); <mask> }; <mask> <mask> export default Link; <mask> export type { ILinkProps }; </s> feat: forwardref in essential components </s> remove export default Text; </s> add export default React.forwardRef<TextType, ITextProps>(Text); </s> remove export default Heading; </s> add export...
[ "keep", "keep", "keep", "keep", "replace", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Link/index.tsx
import type { ActivityIndicator as ActivityIndicatorType } from 'react-native';
<mask> import React from 'react'; <mask> import { ActivityIndicator } from 'react-native'; <mask> import styled from 'styled-components/native'; <mask> import { color, space, position } from 'styled-system'; <mask> import { useToken, usePropsConfig } from '../../../hooks'; <mask> import type { ISpinnerProps } fro...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Spinner/index.tsx
const Spinner = (props: ISpinnerProps, ref: any) => {
<mask> color, <mask> space, <mask> position <mask> ); <mask> const Spinner = (props: ISpinnerProps) => { <mask> const newProps = usePropsConfig('Spinner', props); <mask> const spinnerColor = useToken('colors', newProps.color); <mask> const { spinnerProps } = useSpinner(props); <mask> <mask> ret...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Spinner/index.tsx
return ( <StyledSpinner {...spinnerProps} {...newProps} color={spinnerColor} ref={ref} /> );
<mask> const newProps = usePropsConfig('Spinner', props); <mask> const spinnerColor = useToken('colors', newProps.color); <mask> const { spinnerProps } = useSpinner(props); <mask> <mask> return <StyledSpinner {...spinnerProps} {...newProps} color={spinnerColor} />; <mask> }; <mask> <mask> export defau...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Spinner/index.tsx
export default React.forwardRef<ActivityIndicatorType, ISpinnerProps>(Spinner);
<mask> <mask> return <StyledSpinner {...spinnerProps} {...newProps} color={spinnerColor} />; <mask> }; <mask> <mask> export default Spinner; <mask> export type { ISpinnerProps }; </s> feat: forwardref in essential components </s> remove return <StyledSpinner {...spinnerProps} {...newProps} color={spinnerCo...
[ "keep", "keep", "keep", "keep", "replace", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Spinner/index.tsx
import type { Text as TextType } from 'react-native';
<mask> import React from 'react'; <mask> import { Text as NativeText } from 'react-native'; <mask> import styled from 'styled-components/native'; <mask> import { <mask> color, <mask> position, <mask> space, <mask> typography, </s> feat: forwardref in essential components </s> remove const Spinner = (pr...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Text/index.tsx
const Text = ( { children, style, isTruncated, noOfLines, bold, italic, sub, highlight, underline, strikeThrough, ...props }: ITextProps, ref: any ) => {
<mask> customLayout, <mask> customTypography <mask> ); <mask> <mask> const Text = ({ <mask> children, <mask> style, <mask> isTruncated, <mask> noOfLines, <mask> bold, <mask> italic, <mask> sub, <mask> highlight, <mask> underline, <mask> strikeThrough, <mask> ...props <mask> }...
[ "keep", "keep", "keep", "keep", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Text/index.tsx
ref={ref}
<mask> fontSize={sub ? 10 : newProps.fontSize} <mask> style={style} <mask> > <mask> {children} <mask> </StyledText> <mask> ); <mask> }; </s> feat: forwardref in essential components </s> remove <TouchableWithoutFeedback {...linkProps} {...newProps}> </s> add <TouchableWi...
[ "keep", "add", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Text/index.tsx
export default React.forwardRef<TextType, ITextProps>(Text);
<mask> </StyledText> <mask> ); <mask> }; <mask> <mask> export default Text; <mask> export type { ITextProps }; </s> feat: forwardref in essential components </s> remove export default Link; </s> add export default React.forwardRef<ViewType, ILinkProps>(Link); </s> remove export default Heading; </s> add...
[ "keep", "keep", "keep", "keep", "replace", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8e3337584993b6ccf9dbc4bb55d63c729db3ebac
src/components/primitives/Text/index.tsx
fontSize: platform === "ios" && variables.platformStyle !== "material" ? variables.iconHeaderSize - 3 : variables.iconHeaderSize - 2, marginTop: 0,
<mask> ".transparent": { <mask> marginLeft: -3, <mask> "NativeBase.Icon": { <mask> color: variables.toolbarBtnColor, <mask> fontSize: variables.iconHeaderSize, <mask> marginTop: 2, <mask> marginRight: 2, <mask> marginLeft: 2...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
marginLeft: 2, paddingtop: 0
<mask> color: variables.toolbarBtnColor, <mask> fontSize: variables.iconHeaderSize, <mask> marginTop: 2, <mask> marginRight: 2, <mask> marginLeft: 2 <mask> }, <mask> "NativeBase.IconNB": { <mask> color: variables.toolbar...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
fontSize: platform === "ios" && variables.platformStyle !== "material" ? variables.iconHeaderSize - 3 : variables.iconHeaderSize - 2, marginTop: 0,
<mask> marginLeft: 2 <mask> }, <mask> "NativeBase.IconNB": { <mask> color: variables.toolbarBtnColor, <mask> fontSize: variables.iconHeaderSize, <mask> marginTop: 2, <mask> marginRight: 2, <mask> marginLeft: 2 <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
marginLeft: 2, paddingTop: 0
<mask> color: variables.toolbarBtnColor, <mask> fontSize: variables.iconHeaderSize, <mask> marginTop: 2, <mask> marginRight: 2, <mask> marginLeft: 2 <mask> }, <mask> "NativeBase.Text": { <mask> color: variables.toolbarBt...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
platform === "ios" && variables.platformStyle !== "material" ? variables.iconHeaderSize - 3
<mask> borderRadius: 50, <mask> "NativeBase.Icon": { <mask> color: variables.toolbarBtnColor, <mask> fontSize: <mask> platform === "ios" <mask> ? variables.iconHeaderSize - 6 <mask> : variables.iconHeaderSize - 2, <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
marginTop: 0,
<mask> fontSize: <mask> platform === "ios" <mask> ? variables.iconHeaderSize - 6 <mask> : variables.iconHeaderSize - 2, <mask> marginTop: 2, <mask> marginLeft: 2, <mask> marginRight: 2 <mask> }, <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
marginRight: 2, paddingTop: 0
<mask> ? variables.iconHeaderSize - 6 <mask> : variables.iconHeaderSize - 2, <mask> marginTop: 2, <mask> marginLeft: 2, <mask> marginRight: 2 <mask> }, <mask> "NativeBase.IconNB": { <mask> color: variables.toolba...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
platform === "ios" && variables.platformStyle !== "material" ? variables.iconHeaderSize - 3
<mask> }, <mask> "NativeBase.IconNB": { <mask> color: variables.toolbarBtnColor, <mask> fontSize: <mask> platform === "ios" <mask> ? variables.iconHeaderSize - 6 <mask> : variables.iconHeaderSize - 2, <mask> ma...
[ "keep", "keep", "keep", "keep", "replace", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
marginTop: 0,
<mask> fontSize: <mask> platform === "ios" <mask> ? variables.iconHeaderSize - 6 <mask> : variables.iconHeaderSize - 2, <mask> marginTop: 2, <mask> marginLeft: 2, <mask> marginRight: 2 <mask> }, <mask> ...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
marginRight: 2, paddingTop: 0
<mask> ? variables.iconHeaderSize - 6 <mask> : variables.iconHeaderSize - 2, <mask> marginTop: 2, <mask> marginLeft: 2, <mask> marginRight: 2 <mask> }, <mask> "NativeBase.Text": { <mask> color: variables.toolbarB...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8ec844c28ec58d5af2afb2a9d309e68fd8093709
src/theme/components/Header.js
style: [{
<mask> } <mask> <mask> renderIcon() { <mask> return React.cloneElement(this.props.iosIcon, { <mask> style: { <mask> fontSize: 22, <mask> lineHeight: 26, <mask> color: this.props.placeholderIconColor <mask> } <mask> }); </s> Added support to style iosIcon of pi...
[ "keep", "keep", "keep", "keep", "replace", "keep", "keep", "keep", "keep", "keep" ]
https://github.com/GeekyAnts/NativeBase/commit/8f13d6408d1fbb01bc23bb9ce57dec9053752792
src/basic/Picker.ios.js