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 |
|---|---|---|---|---|
const StyledScrollView: any = makeStyledComponent(RNScrollView); | <mask> } from '../../../hooks';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import type { IScrollViewProps } from './types';
<mask>
<mask> const StyledScrollView: any = makeStyledBox(RNScrollView);
<mask>
<mask> export const ScrollView = forwardRef((props: IScrollViewProps, ref: any) => {
<mask> const {
<mask> _contentContainerStyle,
<mask> contentContainerStyle,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledSectionList: any = makeStyledBox(RNSectionList);
</s> add const StyledSectionList: any = makeStyledComponent(RNSectionList); </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/ScrollView/ScrollView.tsx |
} = usePropsResolution('ScrollView', props); | <mask> const {
<mask> _contentContainerStyle,
<mask> contentContainerStyle,
<mask> ...resolvedProps
<mask> } = usePropsResolution('ScrollView', props, ['contentContainerStyle']);
<mask> const resolved_ContentContainerStyle = useStyledSystemPropsResolver(
<mask> _contentContainerStyle
<mask> );
<mask>
<mask> return (
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledScrollView: any = makeStyledBox(RNScrollView);
</s> add const StyledScrollView: any = makeStyledComponent(RNScrollView); </s> remove const { ...resolvedProps } = usePropsResolution('FlatList', props, {
ignoreProps: ['data', 'renderItem', 'keyExtractor'],
});
</s> add const { ...resolvedProps } = usePropsResolution('FlatList', props); </s> remove const { ...resolvedProps } = usePropsResolution('SectionList', props, {
ignoreProps: [
'sections',
'renderItem',
'keyExtractor',
'renderSectionHeader',
],
});
</s> add const { ...resolvedProps } = usePropsResolution('SectionList', props); </s> remove const StyledSectionList: any = makeStyledBox(RNSectionList);
</s> add const StyledSectionList: any = makeStyledComponent(RNSectionList); </s> remove const StyledSpinner = styled(ActivityIndicator)<ISpinnerProps>(
color,
space,
position
);
</s> add const StyledSpinner = makeStyledComponent(ActivityIndicator); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/ScrollView/ScrollView.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React, { forwardRef } from 'react';
<mask> import { SectionList as RNSectionList } from 'react-native';
<mask> import { usePropsResolution } from '../../../hooks';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import type { ISectionListProps } from './types';
<mask>
<mask> const StyledSectionList: any = makeStyledBox(RNSectionList);
<mask>
<mask> export const SectionList = forwardRef((props: ISectionListProps, ref: any) => {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledSectionList: any = makeStyledBox(RNSectionList);
</s> add const StyledSectionList: any = makeStyledComponent(RNSectionList); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/SectionList/SectionList.tsx |
const StyledSectionList: any = makeStyledComponent(RNSectionList); | <mask> import { usePropsResolution } from '../../../hooks';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import type { ISectionListProps } from './types';
<mask>
<mask> const StyledSectionList: any = makeStyledBox(RNSectionList);
<mask>
<mask> export const SectionList = forwardRef((props: ISectionListProps, ref: any) => {
<mask> const { ...resolvedProps } = usePropsResolution('SectionList', props, {
<mask> ignoreProps: [
<mask> 'sections',
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const { ...resolvedProps } = usePropsResolution('SectionList', props, {
ignoreProps: [
'sections',
'renderItem',
'keyExtractor',
'renderSectionHeader',
],
});
</s> add const { ...resolvedProps } = usePropsResolution('SectionList', props); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove const StyledKeyboardAvoidingView: any = makeStyledBox(RNKeyboardAvoidingView);
</s> add const StyledKeyboardAvoidingView: any = makeStyledComponent(
RNKeyboardAvoidingView
); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/SectionList/SectionList.tsx |
const { ...resolvedProps } = usePropsResolution('SectionList', props); | <mask>
<mask> const StyledSectionList: any = makeStyledBox(RNSectionList);
<mask>
<mask> export const SectionList = forwardRef((props: ISectionListProps, ref: any) => {
<mask> const { ...resolvedProps } = usePropsResolution('SectionList', props, {
<mask> ignoreProps: [
<mask> 'sections',
<mask> 'renderItem',
<mask> 'keyExtractor',
<mask> 'renderSectionHeader',
<mask> ],
<mask> });
<mask>
<mask> return <StyledSectionList {...resolvedProps} ref={ref} />;
<mask> });
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const { ...resolvedProps } = usePropsResolution('FlatList', props, {
ignoreProps: ['data', 'renderItem', 'keyExtractor'],
});
</s> add const { ...resolvedProps } = usePropsResolution('FlatList', props); </s> remove const StyledSectionList: any = makeStyledBox(RNSectionList);
</s> add const StyledSectionList: any = makeStyledComponent(RNSectionList); </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/SectionList/SectionList.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React, { forwardRef } from 'react';
<mask> import { View as RNView } from 'react-native';
<mask> import { usePropsResolution } from '../../../hooks';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import type { IViewProps } from './types';
<mask>
<mask> const StyledView: any = makeStyledBox(RNView);
<mask>
<mask> export const View = forwardRef((props: IViewProps, ref: any) => {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/View/View.tsx |
const StyledView: any = makeStyledComponent(RNView); | <mask> import { usePropsResolution } from '../../../hooks';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import type { IViewProps } from './types';
<mask>
<mask> const StyledView: any = makeStyledBox(RNView);
<mask>
<mask> export const View = forwardRef((props: IViewProps, ref: any) => {
<mask> const { ...resolvedProps } = usePropsResolution('View', props);
<mask>
<mask> return <StyledView {...resolvedProps} ref={ref} />;
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledView: any = styled(RNView)<IViewProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove const StyledSectionList: any = makeStyledBox(RNSectionList);
</s> add const StyledSectionList: any = makeStyledComponent(RNSectionList); </s> remove const StyledKeyboardAvoidingView: any = makeStyledBox(RNKeyboardAvoidingView);
</s> add const StyledKeyboardAvoidingView: any = makeStyledComponent(
RNKeyboardAvoidingView
); </s> remove const { ...resolvedProps } = usePropsResolution('FlatList', props, {
ignoreProps: ['data', 'renderItem', 'keyExtractor'],
});
</s> add const { ...resolvedProps } = usePropsResolution('FlatList', props); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/basic/View/View.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import get from 'lodash.get';
<mask> import React from 'react';
<mask> import { Animated, Easing, StyleSheet } from 'react-native';
<mask> import styled from 'styled-components/native';
<mask> import { border, color } from 'styled-system';
<mask> import { useTheme, useThemeProps } from '../../../hooks';
<mask> import { canUseDom } from '../../../utils';
<mask> import { default as Box, IBoxProps } from '../../primitives/Box';
<mask> import type { ICircularProgressProps } from './types';
<mask> import { themeTools } from '../../../theme';
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { default as Box, IBoxProps } from '../../primitives/Box';
</s> add import { default as Box } from '../../primitives/Box'; </s> remove const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
</s> add const StyleAnimatedView = makeStyledComponent(Animated.View); </s> remove import styled from 'styled-components/native';
</s> add </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import styled from 'styled-components/native';
import { border, color, flexbox, layout, space, position } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/composites/CircularProgress/CircularProgress.tsx |
import { default as Box } from '../../primitives/Box'; | <mask> import styled from 'styled-components/native';
<mask> import { border, color } from 'styled-system';
<mask> import { useTheme, useThemeProps } from '../../../hooks';
<mask> import { canUseDom } from '../../../utils';
<mask> import { default as Box, IBoxProps } from '../../primitives/Box';
<mask> import type { ICircularProgressProps } from './types';
<mask> import { themeTools } from '../../../theme';
<mask>
<mask> const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
<mask>
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import styled from 'styled-components/native';
import { border, color } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
</s> add const StyleAnimatedView = makeStyledComponent(Animated.View); </s> remove import styled from 'styled-components/native';
</s> add </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/composites/CircularProgress/CircularProgress.tsx |
const StyleAnimatedView = makeStyledComponent(Animated.View); | <mask> import { default as Box, IBoxProps } from '../../primitives/Box';
<mask> import type { ICircularProgressProps } from './types';
<mask> import { themeTools } from '../../../theme';
<mask>
<mask> const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
<mask>
<mask> const CircularProgress = (
<mask> { value, isIndeterminate, max, min, ...props }: ICircularProgressProps,
<mask> ref: any
<mask> ) => {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { default as Box, IBoxProps } from '../../primitives/Box';
</s> add import { default as Box } from '../../primitives/Box'; </s> remove import styled from 'styled-components/native';
import { border, color } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/composites/CircularProgress/CircularProgress.tsx |
<mask> import React from 'react';
<mask> import styled from 'styled-components/native';
<mask> import Box from '../../primitives/Box';
<mask> import { useThemeProps } from '../../../hooks';
<mask> import type { ITagProps } from './types';
<mask>
<mask> const StyledTag = styled(Box)<ITagProps>({});
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add </s> remove import { default as Box, IBoxProps } from '../../primitives/Box';
</s> add import { default as Box } from '../../primitives/Box'; </s> remove import styled from 'styled-components/native';
import { border, color } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import styled from 'styled-components/native';
import { color, space, position } from 'styled-system';
</s> add | [
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/composites/Tag/index.tsx | |
<mask> import Box from '../../primitives/Box';
<mask> import { useThemeProps } from '../../../hooks';
<mask> import type { ITagProps } from './types';
<mask>
<mask> const StyledTag = styled(Box)<ITagProps>({});
<mask>
<mask> const Tag = ({ style, ...props }: ITagProps, ref: any) => {
<mask> let newProps = useThemeProps('Tag', props);
<mask> return <StyledTag style={style} {...newProps} ref={ref} />;
<mask> };
<mask>
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; </s> remove import styled from 'styled-components/native';
</s> add </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import { default as Box, IBoxProps } from '../../primitives/Box';
</s> add import { default as Box } from '../../primitives/Box'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/composites/Tag/index.tsx | |
return <Box style={style} {...newProps} ref={ref} />; | <mask> const StyledTag = styled(Box)<ITagProps>({});
<mask>
<mask> const Tag = ({ style, ...props }: ITagProps, ref: any) => {
<mask> let newProps = useThemeProps('Tag', props);
<mask> return <StyledTag style={style} {...newProps} ref={ref} />;
<mask> };
<mask>
<mask> export default React.memo(React.forwardRef(Tag));
<mask> export type { ITagProps };
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add </s> remove const { ...resolvedProps } = usePropsResolution('FlatList', props, {
ignoreProps: ['data', 'renderItem', 'keyExtractor'],
});
</s> add const { ...resolvedProps } = usePropsResolution('FlatList', props); </s> remove export const makeStyledBox = (Comp: any) => {
</s> add export const makeStyledComponent = (Comp: any) => { </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove const { ...resolvedProps } = usePropsResolution('SectionList', props, {
ignoreProps: [
'sections',
'renderItem',
'keyExtractor',
'renderSectionHeader',
],
});
</s> add const { ...resolvedProps } = usePropsResolution('SectionList', props); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/composites/Tag/index.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React, { memo, forwardRef } from 'react';
<mask> import { View } from 'react-native';
<mask> import { usePropsResolution } from '../../../hooks';
<mask> import Text from './../Text';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import type { IBoxProps } from './types';
<mask> import { useSafeArea } from '../../../hooks/useSafeArea';
<mask> import { useNativeBaseConfig } from '../../../core/NativeBaseContext';
<mask>
<mask> const StyledBox = makeStyledBox(View);
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
import { color, space, position } from 'styled-system';
</s> add </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Box/index.tsx |
const StyledBox = makeStyledComponent(View); | <mask> import type { IBoxProps } from './types';
<mask> import { useSafeArea } from '../../../hooks/useSafeArea';
<mask> import { useNativeBaseConfig } from '../../../core/NativeBaseContext';
<mask>
<mask> const StyledBox = makeStyledBox(View);
<mask>
<mask> let MemoizedGradient: any = undefined;
<mask>
<mask> const Box = ({ children, ...props }: IBoxProps, ref: any) => {
<mask> // const { _text, ...resolvedProps } = useThemeProps('Box', props);
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); </s> remove const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
</s> add const StyleAnimatedView = makeStyledComponent(Animated.View); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Box/index.tsx |
MemoizedGradient = makeStyledComponent(Gradient); | <mask> resolvedProps.backgroundColor?.linearGradient;
<mask>
<mask> if (Gradient) {
<mask> if (!MemoizedGradient) {
<mask> MemoizedGradient = makeStyledBox(Gradient);
<mask> }
<mask>
<mask> Gradient = MemoizedGradient;
<mask>
<mask> let startObj = { x: 1, y: 0 };
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove let val = get(theme[scale], value, value);
</s> add const originalRawValue = rawValue;
if (scale === 'colors') {
if (rawValue?.match(/^.*?(?=:alpha)/)) {
rawValue = rawValue?.match(/^.*?(?=:alpha)/)[0];
}
}
let val = get(theme[scale], rawValue, rawValue);
if (scale === 'colors') {
}
if (scale === 'colors') {
const alpha: string = originalRawValue?.match(/:alpha\.\d\d?\d?/)
? originalRawValue?.match(/:alpha\.\d\d?\d?/)[0].split('.')[1]
: '1';
const resolvedAlpha = get(theme['opacity'], alpha, alpha);
let color = tinycolor(val);
val =
resolvedAlpha === '1'
? val
: color.setAlpha(resolvedAlpha).toString();
} </s> remove const rawValue = props[key];
</s> add let rawValue = props[key]; </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Box/index.tsx |
<StyledBox debug ref={ref} {...safeAreaProps}> | <mask> }
<mask> }
<mask>
<mask> return (
<mask> <StyledBox ref={ref} {...safeAreaProps}>
<mask> {React.Children.map(children, (child) =>
<mask> typeof child === 'string' ? <Text {..._text}>{child}</Text> : child
<mask> )}
<mask> </StyledBox>
<mask> );
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove let val = get(theme[scale], value, value);
</s> add const originalRawValue = rawValue;
if (scale === 'colors') {
if (rawValue?.match(/^.*?(?=:alpha)/)) {
rawValue = rawValue?.match(/^.*?(?=:alpha)/)[0];
}
}
let val = get(theme[scale], rawValue, rawValue);
if (scale === 'colors') {
}
if (scale === 'colors') {
const alpha: string = originalRawValue?.match(/:alpha\.\d\d?\d?/)
? originalRawValue?.match(/:alpha\.\d\d?\d?/)[0].split('.')[1]
: '1';
const resolvedAlpha = get(theme['opacity'], alpha, alpha);
let color = tinycolor(val);
val =
resolvedAlpha === '1'
? val
: color.setAlpha(resolvedAlpha).toString();
} </s> remove onBlur={(e) => {
</s> add onBlur={(e: any) => { </s> remove onFocus={(e) => {
</s> add onFocus={(e: any) => { </s> remove } = usePropsResolution('ScrollView', props, ['contentContainerStyle']);
</s> add } = usePropsResolution('ScrollView', props); </s> remove const StyledSpinner = styled(ActivityIndicator)<ISpinnerProps>(
color,
space,
position
);
</s> add const StyledSpinner = makeStyledComponent(ActivityIndicator); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Box/index.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React, { memo, forwardRef } from 'react';
<mask> import { useToken, usePropsResolution } from '../../../hooks';
<mask> import styled from 'styled-components/native';
<mask> import {
<mask> border,
<mask> color,
<mask> flexbox,
<mask> layout,
<mask> space,
<mask> typography,
<mask> position,
<mask> } from 'styled-system';
<mask> import {
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customLayout,
<mask> customExtra,
<mask> customShadow,
<mask> customTypography,
<mask> customPosition,
<mask> } from '../../../utils/customProps';
<mask> import { Svg, G } from './nbSvg';
<mask> import type { IIconProps } from './types';
<mask> import { questionOutlineIconPath } from './Icons/questionIconPath';
<mask>
<mask> const SVG = styled(Svg)<IIconProps>(
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const SVG = styled(Svg)<IIconProps>(
color,
space,
layout,
flexbox,
border,
typography,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout,
customTypography
);
</s> add const SVG = makeStyledComponent(Svg); </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
</s> add | [
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep"... | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Icon/SVGIcon.tsx |
const SVG = makeStyledComponent(Svg); | <mask> import { Svg, G } from './nbSvg';
<mask> import type { IIconProps } from './types';
<mask> import { questionOutlineIconPath } from './Icons/questionIconPath';
<mask>
<mask> const SVG = styled(Svg)<IIconProps>(
<mask> color,
<mask> space,
<mask> layout,
<mask> flexbox,
<mask> border,
<mask> typography,
<mask> position,
<mask> customPosition,
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customShadow,
<mask> customExtra,
<mask> customLayout,
<mask> customTypography
<mask> );
<mask>
<mask> const SVGIcon = ({ children, ...props }: IIconProps, ref: any) => {
<mask> const {
<mask> focusable,
<mask> stroke,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout
);
</s> add const StyledNBSwitch = makeStyledComponent(RNSwitch); </s> remove const StyledView: any = styled(RNView)<IViewProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"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/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Icon/SVGIcon.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import { Image as RNImage } from 'react-native';
<mask> import Text from '../Text';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { IImageProps } from './types';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask>
<mask> const StyledImage = makeStyledBox(RNImage);
<mask>
<mask> const Image = ({ source, ...props }: IImageProps, ref: any) => {
<mask> const {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledImage = makeStyledBox(RNImage);
</s> add const StyledImage = makeStyledComponent(RNImage); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Image/index.tsx |
const StyledImage = makeStyledComponent(RNImage); | <mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { IImageProps } from './types';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask>
<mask> const StyledImage = makeStyledBox(RNImage);
<mask>
<mask> const Image = ({ source, ...props }: IImageProps, ref: any) => {
<mask> const {
<mask> alt,
<mask> fallbackSource,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Image/index.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import { useToken } from '../../../hooks';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import { useHover } from '@react-native-aria/interactions';
<mask> import { mergeRefs } from '../../../utils';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import { useResolvedFontFamily } from '../../../hooks/useResolvedFontFamily';
<mask>
<mask> const StyledInput = makeStyledBox(TextInput);
<mask>
<mask> const InputBase = (
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledInput = makeStyledBox(TextInput);
</s> add const StyledInput = makeStyledComponent(TextInput); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Input/InputBase.tsx |
const StyledInput = makeStyledComponent(TextInput); | <mask> import { mergeRefs } from '../../../utils';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import { useResolvedFontFamily } from '../../../hooks/useResolvedFontFamily';
<mask>
<mask> const StyledInput = makeStyledBox(TextInput);
<mask>
<mask> const InputBase = (
<mask> {
<mask> onKeyPress,
<mask> onFocus,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout
);
</s> add const StyledNBSwitch = makeStyledComponent(RNSwitch); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Input/InputBase.tsx |
onFocus={(e: any) => { | <mask> onKeyPress={(e: any) => {
<mask> e.persist();
<mask> onKeyPress && onKeyPress(e);
<mask> }}
<mask> onFocus={(e) => {
<mask> handleFocus(true, onFocus ? () => onFocus(e) : () => {});
<mask> }}
<mask> onBlur={(e) => {
<mask> handleFocus(false, onBlur ? () => onBlur(e) : () => {});
<mask> }}
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove onBlur={(e) => {
</s> add onBlur={(e: any) => { </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove <StyledBox ref={ref} {...safeAreaProps}>
</s> add <StyledBox debug ref={ref} {...safeAreaProps}> </s> remove let val = get(theme[scale], value, value);
</s> add const originalRawValue = rawValue;
if (scale === 'colors') {
if (rawValue?.match(/^.*?(?=:alpha)/)) {
rawValue = rawValue?.match(/^.*?(?=:alpha)/)[0];
}
}
let val = get(theme[scale], rawValue, rawValue);
if (scale === 'colors') {
}
if (scale === 'colors') {
const alpha: string = originalRawValue?.match(/:alpha\.\d\d?\d?/)
? originalRawValue?.match(/:alpha\.\d\d?\d?/)[0].split('.')[1]
: '1';
const resolvedAlpha = get(theme['opacity'], alpha, alpha);
let color = tinycolor(val);
val =
resolvedAlpha === '1'
? val
: color.setAlpha(resolvedAlpha).toString();
} | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Input/InputBase.tsx |
onBlur={(e: any) => { | <mask> }}
<mask> onFocus={(e) => {
<mask> handleFocus(true, onFocus ? () => onFocus(e) : () => {});
<mask> }}
<mask> onBlur={(e) => {
<mask> handleFocus(false, onBlur ? () => onBlur(e) : () => {});
<mask> }}
<mask> {...(Platform.OS === 'web'
<mask> ? {
<mask> disabled: isDisabled,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove onFocus={(e) => {
</s> add onFocus={(e: any) => { </s> remove <StyledBox ref={ref} {...safeAreaProps}>
</s> add <StyledBox debug ref={ref} {...safeAreaProps}> </s> remove let val = get(theme[scale], value, value);
</s> add const originalRawValue = rawValue;
if (scale === 'colors') {
if (rawValue?.match(/^.*?(?=:alpha)/)) {
rawValue = rawValue?.match(/^.*?(?=:alpha)/)[0];
}
}
let val = get(theme[scale], rawValue, rawValue);
if (scale === 'colors') {
}
if (scale === 'colors') {
const alpha: string = originalRawValue?.match(/:alpha\.\d\d?\d?/)
? originalRawValue?.match(/:alpha\.\d\d?\d?/)[0].split('.')[1]
: '1';
const resolvedAlpha = get(theme['opacity'], alpha, alpha);
let color = tinycolor(val);
val =
resolvedAlpha === '1'
? val
: color.setAlpha(resolvedAlpha).toString();
} </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Input/InputBase.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import { composeEventHandlers } from '../../../utils';
<mask> import type { IPressableProps } from './types';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import { useFocusRing } from '@react-native-aria/focus';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask>
<mask> const useHover = () => {
<mask> const [isHovered, setHovered] = React.useState(false);
<mask> return {
<mask> pressableProps: {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Pressable/Pressable.tsx |
const StyledPressable = makeStyledComponent(RNPressable); | <mask> isPressed,
<mask> };
<mask> };
<mask>
<mask> const StyledPressable = makeStyledBox(RNPressable);
<mask>
<mask> const Pressable = (
<mask> {
<mask> children,
<mask> onPressIn,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add </s> remove const StyledComponent = makeStyledBox(Component as AnyStyledComponent);
</s> add const StyledComponent = makeStyledComponent(
Component as AnyStyledComponent
); </s> remove MemoizedGradient = makeStyledBox(Gradient);
</s> add MemoizedGradient = makeStyledComponent(Gradient); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Pressable/Pressable.tsx |
<mask> import React, { memo, forwardRef } 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 { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { ISpinnerProps } from './types';
<mask>
<mask> const StyledSpinner = styled(ActivityIndicator)<ISpinnerProps>(
<mask> color,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledSpinner = styled(ActivityIndicator)<ISpinnerProps>(
color,
space,
position
);
</s> add const StyledSpinner = makeStyledComponent(ActivityIndicator); </s> remove import styled from 'styled-components/native';
</s> add </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add | [
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Spinner/index.tsx | |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React, { memo, forwardRef } from 'react';
<mask> import { ActivityIndicator } from 'react-native';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { ISpinnerProps } from './types';
<mask>
<mask> const StyledSpinner = makeStyledComponent(ActivityIndicator);
<mask> const Spinner = (props: ISpinnerProps, ref: any) => {
<mask> const resolvedProps = usePropsResolution('Spinner', props);
<mask> return (
<mask> <StyledSpinner
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledSpinner = styled(ActivityIndicator)<ISpinnerProps>(
color,
space,
position
);
</s> add const StyledSpinner = makeStyledComponent(ActivityIndicator); </s> remove import styled from 'styled-components/native';
import { color, space, position } from 'styled-system';
</s> add </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Spinner/index.tsx |
const StyledSpinner = makeStyledComponent(ActivityIndicator); | <mask> import { color, space, position } from 'styled-system';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { ISpinnerProps } from './types';
<mask>
<mask> const StyledSpinner = styled(ActivityIndicator)<ISpinnerProps>(
<mask> color,
<mask> space,
<mask> position
<mask> );
<mask> const Spinner = (props: ISpinnerProps, ref: any) => {
<mask> const resolvedProps = usePropsResolution('Spinner', props);
<mask> return (
<mask> <StyledSpinner
<mask> accessible
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import styled from 'styled-components/native';
import { color, space, position } from 'styled-system';
</s> add </s> remove const StyledView: any = styled(RNView)<IViewProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Spinner/index.tsx |
<mask> import React, { memo, forwardRef } from 'react';
<mask> import { useToggleState } from '@react-stately/toggle';
<mask> import { StyleSheet, ViewStyle, Switch as RNSwitch } from 'react-native';
<mask> import styled from 'styled-components/native';
<mask> import isNil from 'lodash.isnil';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import { useToken } from '../../../hooks';
<mask> import { border, color, flexbox, layout, space, position } from 'styled-system';
<mask> import {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
import { color, space, position } from 'styled-system';
</s> add </s> remove import styled from 'styled-components/native';
import { border, color, flexbox, layout, space, position } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Switch/index.tsx | |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import styled from 'styled-components/native';
<mask> import isNil from 'lodash.isnil';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import { useToken } from '../../../hooks';
<mask> import { border, color, flexbox, layout, space, position } from 'styled-system';
<mask> import {
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customLayout,
<mask> customExtra,
<mask> customShadow,
<mask> customPosition,
<mask> } from '../../../utils/customProps';
<mask> import type { ISwitchProps } from './types';
<mask> import { mergeRefs } from '../../../utils';
<mask> import { useHover } from '@react-native-aria/interactions';
<mask>
<mask> const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout
);
</s> add const StyledNBSwitch = makeStyledComponent(RNSwitch); </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Switch/index.tsx |
const StyledNBSwitch = makeStyledComponent(RNSwitch); | <mask> import type { ISwitchProps } from './types';
<mask> import { mergeRefs } from '../../../utils';
<mask> import { useHover } from '@react-native-aria/interactions';
<mask>
<mask> const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
<mask> color,
<mask> space,
<mask> layout,
<mask> flexbox,
<mask> border,
<mask> position,
<mask> customPosition,
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customShadow,
<mask> customExtra,
<mask> customLayout
<mask> );
<mask>
<mask> const Switch = (
<mask> {
<mask> style,
<mask> onToggle,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove const StyledView: any = styled(RNView)<IViewProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove const SVG = styled(Svg)<IIconProps>(
color,
space,
layout,
flexbox,
border,
typography,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout,
customTypography
);
</s> add const SVG = makeStyledComponent(Svg); </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"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/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Switch/index.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { ITextProps } from './types';
<mask> import { useHover } from '@react-native-aria/interactions';
<mask> import { mergeRefs } from '../../../utils/mergeRefs';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import { useResolvedFontFamily } from '../../../hooks/useResolvedFontFamily';
<mask>
<mask> const StyledText = makeStyledBox(NativeText);
<mask>
<mask> const Text = ({ children, ...props }: ITextProps, ref: any) => {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledInput = makeStyledBox(TextInput);
</s> add const StyledInput = makeStyledComponent(TextInput); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Text/index.tsx |
const StyledText = makeStyledComponent(NativeText); | <mask> import { mergeRefs } from '../../../utils/mergeRefs';
<mask> import { makeStyledBox } from '../../../utils/styled';
<mask> import { useResolvedFontFamily } from '../../../hooks/useResolvedFontFamily';
<mask>
<mask> const StyledText = makeStyledBox(NativeText);
<mask>
<mask> const Text = ({ children, ...props }: ITextProps, ref: any) => {
<mask> const {
<mask> isTruncated,
<mask> noOfLines,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledInput = makeStyledBox(TextInput);
</s> add const StyledInput = makeStyledComponent(TextInput); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledImage = makeStyledBox(RNImage);
</s> add const StyledImage = makeStyledComponent(RNImage); | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/Text/index.tsx |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React from 'react';
<mask> import styled from 'styled-components/native';
<mask> import { TouchableHighlight } from 'react-native';
<mask> import { border, color, flexbox, layout, space, position } from 'styled-system';
<mask> import {
<mask> customBorder,
<mask> customBackground,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove import styled from 'styled-components/native';
import { border, color, flexbox, layout, space, position } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import styled from 'styled-components/native';
</s> add </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/TouchableItem/index.tsx |
<mask> import React from 'react';
<mask> import styled from 'styled-components/native';
<mask> import { TouchableHighlight } from 'react-native';
<mask> import { border, color, flexbox, layout, space, position } from 'styled-system';
<mask> import {
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customLayout,
<mask> customExtra,
<mask> customPosition,
<mask> customShadow,
<mask> customTypography,
<mask> } from '../../../utils/customProps';
<mask>
<mask> const TouchableItem = styled(TouchableHighlight)<any>(
<mask> color,
<mask> space,
<mask> layout,
<mask> flexbox,
<mask> border,
<mask> position,
<mask> customPosition,
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customShadow,
<mask> customExtra,
<mask> customTypography,
<mask> customLayout
<mask> );
<mask>
<mask> export default React.memo(TouchableItem);
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout
);
</s> add const StyledNBSwitch = makeStyledComponent(RNSwitch); </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
... | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/TouchableItem/index.tsx | |
import { makeStyledComponent } from '../../../utils/styled'; | <mask> import React from 'react';
<mask> import styled from 'styled-components/native';
<mask> import { border, color, flexbox, layout, space, position } from 'styled-system';
<mask> import { View as RNView } from 'react-native';
<mask> import {
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import styled from 'styled-components/native';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove import styled from 'styled-components/native';
</s> add </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/View/index.tsx |
<mask> import React from 'react';
<mask> import styled from 'styled-components/native';
<mask> import { border, color, flexbox, layout, space, position } from 'styled-system';
<mask> import { View as RNView } from 'react-native';
<mask> import {
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customLayout,
<mask> customExtra,
<mask> customShadow,
<mask> customTypography,
<mask> customPosition,
<mask> } from '../../../utils/customProps';
<mask>
<mask> import { useThemeProps } from '../../../hooks/useThemeProps';
<mask> import { useSafeArea } from '../../../hooks/useSafeArea';
<mask> import type { IViewProps } from './types';
<mask> const StyledView: any = styled(RNView)<IViewProps>(
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove import styled from 'styled-components/native';
import { border, color, flexbox, layout, space, position } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const StyledView: any = styled(RNView)<IViewProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import styled from 'styled-components/native';
import {
border,
color,
flexbox,
layout,
space,
typography,
position,
} from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/View/index.tsx | |
const StyledView: any = makeStyledComponent(RNView); | <mask>
<mask> import { useThemeProps } from '../../../hooks/useThemeProps';
<mask> import { useSafeArea } from '../../../hooks/useSafeArea';
<mask> import type { IViewProps } from './types';
<mask> const StyledView: any = styled(RNView)<IViewProps>(
<mask> color,
<mask> space,
<mask> layout,
<mask> flexbox,
<mask> border,
<mask> position,
<mask> customPosition,
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
<mask> customShadow,
<mask> customExtra,
<mask> customTypography,
<mask> customLayout
<mask> );
<mask>
<mask> const View = (props: IViewProps, ref: any) => {
<mask> const viewProps = useThemeProps('View', props);
<mask> const safeAreaProps = useSafeArea(viewProps);
<mask> return <StyledView {...safeAreaProps} ref={ref} />;
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customShadow,
customTypography,
customPosition,
} from '../../../utils/customProps';
</s> add </s> remove import { border, color, flexbox, layout, space, position } from 'styled-system';
import {
customBorder,
customBackground,
customOutline,
customLayout,
customExtra,
customPosition,
customShadow,
customTypography,
} from '../../../utils/customProps';
const TouchableItem = styled(TouchableHighlight)<any>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customTypography,
customLayout
);
</s> add </s> remove const StyledNBSwitch = styled(RNSwitch)<ISwitchProps>(
color,
space,
layout,
flexbox,
border,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout
);
</s> add const StyledNBSwitch = makeStyledComponent(RNSwitch); </s> remove const StyledView: any = makeStyledBox(RNView);
</s> add const StyledView: any = makeStyledComponent(RNView); </s> remove const SVG = styled(Svg)<IIconProps>(
color,
space,
layout,
flexbox,
border,
typography,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout,
customTypography
);
</s> add const SVG = makeStyledComponent(Svg); | [
"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/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/components/primitives/View/index.tsx |
import { makeStyledComponent } from '../utils/styled'; | <mask> import type { AnyStyledComponent } from 'styled-components';
<mask> import { usePropsWithComponentTheme } from '../hooks/useThemeProps/usePropsWithComponentTheme';
<mask> import type { ComponentTheme } from '../theme';
<mask> import type { FactoryComponentProps } from './types';
<mask> import { makeStyledBox } from '../utils/styled';
<mask>
<mask> export default function <P>(
<mask> Component: React.ComponentType<P>,
<mask> componentTheme?: ComponentTheme
<mask> ) {
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { default as Box, IBoxProps } from '../../primitives/Box';
</s> add import { default as Box } from '../../primitives/Box'; </s> remove import styled from 'styled-components/native';
import { border, color } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/factory/component.tsx |
const StyledComponent = makeStyledComponent(
Component as AnyStyledComponent
); | <mask> componentTheme?: ComponentTheme
<mask> ) {
<mask> return React.forwardRef(
<mask> ({ children, ...props }: P & FactoryComponentProps, ref: any) => {
<mask> const StyledComponent = makeStyledBox(Component as AnyStyledComponent);
<mask> const calculatedProps = usePropsWithComponentTheme(componentTheme, props);
<mask> return (
<mask> <StyledComponent {...(calculatedProps as P)} ref={ref}>
<mask> {children}
<mask> </StyledComponent>
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove export const makeStyledBox = (Comp: any) => {
</s> add export const makeStyledComponent = (Comp: any) => { </s> remove const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
</s> add const StyleAnimatedView = makeStyledComponent(Animated.View); </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/factory/component.tsx |
it('tests alpha opacity resolution', () => {
const { getByTestId } = render(
<Provider>
<Box p={2} bg="primary.400:alpha.50" testID="test">
hello world
</Box>
</Provider>
);
const box = getByTestId('test');
expect(box.props.style.backgroundColor).toBe(
'rgba(34, 211, 238, ' + defaultTheme.opacity['50'] + ')'
);
}); | <mask> backgroundColor: newTheme.colors.cyan['500'],
<mask> });
<mask> });
<mask> });
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const { ...resolvedProps } = usePropsResolution('FlatList', props, {
ignoreProps: ['data', 'renderItem', 'keyExtractor'],
});
</s> add const { ...resolvedProps } = usePropsResolution('FlatList', props); </s> remove const { ...resolvedProps } = usePropsResolution('SectionList', props, {
ignoreProps: [
'sections',
'renderItem',
'keyExtractor',
'renderSectionHeader',
],
});
</s> add const { ...resolvedProps } = usePropsResolution('SectionList', props); </s> remove const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
</s> add const StyleAnimatedView = makeStyledComponent(Animated.View); </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove const SVG = styled(Svg)<IIconProps>(
color,
space,
layout,
flexbox,
border,
typography,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout,
customTypography
);
</s> add const SVG = makeStyledComponent(Svg); | [
"keep",
"keep",
"add",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/hooks/useThemeProps/usePropsResolution.test.tsx |
import opacity from './opacity'; | <mask> import sizes from './sizes';
<mask> import { spacing } from './space';
<mask> import typography from './typography';
<mask>
<mask> const theme = {
<mask> borders,
<mask> breakpoints,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/theme/base/index.ts |
opacity, | <mask> space: spacing,
<mask> shadows,
<mask> };
<mask>
<mask> export type ITheme = typeof theme;
<mask>
<mask> export const themePropertyMap: any = {
<mask> borderRadius: 'radii',
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; </s> remove const StyledScrollView: any = makeStyledBox(RNScrollView);
</s> add const StyledScrollView: any = makeStyledComponent(RNScrollView); </s> remove const StyledPressable = makeStyledBox(RNPressable);
</s> add const StyledPressable = makeStyledComponent(RNPressable); </s> remove const StyledSectionList: any = makeStyledBox(RNSectionList);
</s> add const StyledSectionList: any = makeStyledComponent(RNSectionList); </s> remove const StyledKeyboardAvoidingView: any = makeStyledBox(RNKeyboardAvoidingView);
</s> add const StyledKeyboardAvoidingView: any = makeStyledComponent(
RNKeyboardAvoidingView
); | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/theme/base/index.ts |
import tinycolor from 'tinycolor2'; | <mask> import { StyleSheet } from 'react-native';
<mask> import { get } from 'lodash';
<mask> import { resolveValueWithBreakpoint } from '../hooks/useThemeProps/utils';
<mask>
<mask> export const layout = {
<mask> width: {
<mask> property: 'width',
<mask> scale: 'sizes',
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove import styled from 'styled-components/native';
import { border, color } from 'styled-system';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; </s> remove import { makeStyledBox } from '../../../utils/styled';
</s> add import { makeStyledComponent } from '../../../utils/styled'; | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/theme/styled-system.ts |
let rawValue = props[key]; | <mask> }: any) => {
<mask> let styleFromProps: any = {};
<mask> let restProps: any = {};
<mask> for (let key in props) {
<mask> const rawValue = props[key];
<mask>
<mask> if (key in propConfig) {
<mask> const value = resolveValueWithBreakpoint(
<mask> rawValue,
<mask> currentBreakpoint,
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove let val = get(theme[scale], value, value);
</s> add const originalRawValue = rawValue;
if (scale === 'colors') {
if (rawValue?.match(/^.*?(?=:alpha)/)) {
rawValue = rawValue?.match(/^.*?(?=:alpha)/)[0];
}
}
let val = get(theme[scale], rawValue, rawValue);
if (scale === 'colors') {
}
if (scale === 'colors') {
const alpha: string = originalRawValue?.match(/:alpha\.\d\d?\d?/)
? originalRawValue?.match(/:alpha\.\d\d?\d?/)[0].split('.')[1]
: '1';
const resolvedAlpha = get(theme['opacity'], alpha, alpha);
let color = tinycolor(val);
val =
resolvedAlpha === '1'
? val
: color.setAlpha(resolvedAlpha).toString();
} </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove MemoizedGradient = makeStyledBox(Gradient);
</s> add MemoizedGradient = makeStyledComponent(Gradient); </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/theme/styled-system.ts |
const originalRawValue = rawValue;
if (scale === 'colors') {
if (rawValue?.match(/^.*?(?=:alpha)/)) {
rawValue = rawValue?.match(/^.*?(?=:alpha)/)[0];
}
}
let val = get(theme[scale], rawValue, rawValue);
if (scale === 'colors') {
}
if (scale === 'colors') {
const alpha: string = originalRawValue?.match(/:alpha\.\d\d?\d?/)
? originalRawValue?.match(/:alpha\.\d\d?\d?/)[0].split('.')[1]
: '1';
const resolvedAlpha = get(theme['opacity'], alpha, alpha);
let color = tinycolor(val);
val =
resolvedAlpha === '1'
? val
: color.setAlpha(resolvedAlpha).toString();
} | <mask> styleFromProps = { ...styleFromProps, [key]: value };
<mask> } else if (config) {
<mask> //@ts-ignore
<mask> const { property, scale, properties, transformer } = config;
<mask> let val = get(theme[scale], value, value);
<mask> if (transformer) {
<mask> val = transformer(val);
<mask> }
<mask> if (typeof val === 'string' && val.endsWith('px')) {
<mask> val = parseInt(val, 10);
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove MemoizedGradient = makeStyledBox(Gradient);
</s> add MemoizedGradient = makeStyledComponent(Gradient); </s> remove const rawValue = props[key];
</s> add let rawValue = props[key]; </s> remove const StyleAnimatedView = styled(Animated.View)<IBoxProps>(color, border);
</s> add const StyleAnimatedView = makeStyledComponent(Animated.View); </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove const StyledTag = styled(Box)<ITagProps>({});
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/theme/styled-system.ts |
export const makeStyledComponent = (Comp: any) => { | <mask> customLayout,
<mask> ];
<mask>
<mask> // @ts-ignore
<mask> export const makeStyledBox = (Comp: any) => {
<mask> return React.forwardRef(
<mask> ({ style: propStyle, children, debug, ...props }: any, ref: any) => {
<mask> const theme = useTheme();
<mask> const windowWidth = useWindowDimensions().width;
<mask>
</s> feat: alpha opacity in colors and remove styled system (#3850) </s> remove const StyledComponent = makeStyledBox(Component as AnyStyledComponent);
</s> add const StyledComponent = makeStyledComponent(
Component as AnyStyledComponent
); </s> remove const StyledBox = makeStyledBox(View);
</s> add const StyledBox = makeStyledComponent(View); </s> remove const StyledText = makeStyledBox(NativeText);
</s> add const StyledText = makeStyledComponent(NativeText); </s> remove const SVG = styled(Svg)<IIconProps>(
color,
space,
layout,
flexbox,
border,
typography,
position,
customPosition,
customBorder,
customBackground,
customOutline,
customShadow,
customExtra,
customLayout,
customTypography
);
</s> add const SVG = makeStyledComponent(Svg); </s> remove return <StyledTag style={style} {...newProps} ref={ref} />;
</s> add return <Box style={style} {...newProps} ref={ref} />; | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2414fd352793a5bc0b9240cf65d6efb3f26c0367 | src/utils/styled.tsx |
_backdrop={{ bg: 'pink.100' }} | <mask> <Button onPress={() => setShowModal(true)}>Button</Button>
<mask> <Modal
<mask> isOpen={showModal}
<mask> onClose={() => setShowModal(false)}
<mask> overlayVisible={false}
<mask> _backdrop={{ opacity: 0.8, bg: 'pink.100' }}
<mask> >
<mask> <Modal.Content maxWidth="400px">
<mask> <Modal.CloseButton />
<mask> <Modal.Header>Modal Title</Modal.Header>
<mask> <Modal.Body>
</s> fix: broken examples and components </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', </s> remove size: 'xs',
</s> add size: 'sm', </s> remove {...props}
</s> add </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | example/storybook/stories/components/composites/Modal/CustomBackdrop.tsx |
bg="gray.600" | <mask> >
<mask> <Card width={64} p={6} py={8}>
<mask> <VStack alignItems="center" space={5}>
<mask> <Avatar
<mask> source={{
<mask> uri: 'https://docs.nativebase.io/img/nativebaselogo.svg',
<mask> }}
<mask> size="lg"
<mask> >
</s> fix: broken examples and components </s> remove overlayVisible={false}
_backdrop={{ opacity: 0.8, bg: 'pink.100' }}
</s> add _backdrop={{ bg: 'pink.100' }} </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | example/storybook/stories/components/primitives/Link/CompositeLink.tsx |
"react-native": "https://github.com/expo/react-native/archive/sdk-40.0.1.tar.gz", | <mask> "pod-install": "^0.1.0",
<mask> "postinstall-postinstall": "^2.1.0",
<mask> "prettier": "^2.0.5",
<mask> "react": "16.11.0",
<mask> "react-native": "^0.64.2",
<mask> "react-native-safe-area-context": "^3.1.9",
<mask> "react-native-svg": "^12.1.0",
<mask> "react-test-renderer": "^16.9.0",
<mask> "release-it": "^13.5.8",
<mask> "rollup": "^2.34.1",
</s> fix: broken examples and components </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove import { useTheme } from '../../../hooks';
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | package.json |
bg={props.bg || 'rgb(0, 0, 0)'}
opacity="0.3" | <mask> left={0}
<mask> right={0}
<mask> accessible={false}
<mask> importantForAccessibility="no"
<mask> bg={props.bg || 'rgba(0, 0, 0, 0.3)'}
<mask> {...props}
<mask> ></Pressable>
<mask> );
<mask> };
<mask>
</s> fix: broken examples and components </s> remove {...props}
</s> add </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/components/composites/Backdrop/index.tsx |
<mask> return (
<mask> <Box position="absolute" right={1} top={1} zIndex={1} ref={ref}>
<mask> <IconButton
<mask> {...newProps}
<mask> {...props}
<mask> icon={<CloseIcon {..._icon} />}
<mask> onPress={onClose}
<mask> />
<mask> </Box>
<mask> );
</s> fix: broken examples and components </s> remove bg={props.bg || 'rgba(0, 0, 0, 0.3)'}
</s> add bg={props.bg || 'rgb(0, 0, 0)'}
opacity="0.3" </s> remove overlayVisible={false}
_backdrop={{ opacity: 0.8, bg: 'pink.100' }}
</s> add _backdrop={{ bg: 'pink.100' }} </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/components/composites/Popover/PopoverCloseButton.tsx | |
'_text', | <mask> ...stylingProps.layout,
<mask> ...stylingProps.flexbox,
<mask> ...stylingProps.position,
<mask> ]);
<mask>
<mask> // Swap hooks depending on whether this checkbox is inside a CheckboxGroup.
<mask> // This is a bit unorthodox. Typically, hooks cannot be called in a conditional,
</s> fix: broken examples and components </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/components/primitives/Checkbox/Checkbox.tsx |
'_text', | <mask> ...stylingProps.margin,
<mask> ...stylingProps.layout,
<mask> ...stylingProps.flexbox,
<mask> ...stylingProps.position,
<mask> ]);
<mask>
<mask> // Swap hooks depending on whether this checkbox is inside a CheckboxGroup.
<mask> // This is a bit unorthodox. Typically, hooks cannot be called in a conditional,
<mask> // but since the checkbox won't move in and out of a group, it should be safe.
<mask> const { inputProps } = groupState
</s> fix: broken examples and components </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove size: 'xs',
</s> add size: 'sm', </s> remove import { useTheme } from '../../../hooks';
</s> add | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/components/primitives/Checkbox/Checkbox.web.tsx |
<mask> import React, { memo, forwardRef, useRef } from 'react';
<mask> import { Text as NativeText, useWindowDimensions } from 'react-native';
<mask> import { useTheme } from '../../../hooks';
<mask> import styled from 'styled-components/native';
<mask> import {
<mask> color,
<mask> position,
<mask> space,
</s> fix: broken examples and components </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', | [
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/components/primitives/Text/index.tsx | |
import { useResolvedFontFamily } from '../../../hooks/useResolvedFontFamily'; | <mask> } from 'styled-system';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import {
<mask> customBorder,
<mask> customBackground,
<mask> customOutline,
</s> fix: broken examples and components </s> remove import { useTheme } from '../../../hooks';
</s> add </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove size: 'xs',
</s> add size: 'sm', </s> remove bg: 'transaprarent',
</s> add bg: 'transparent', | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/components/primitives/Text/index.tsx |
<mask> import { mergeRefs } from '../../../utils/mergeRefs';
<mask> import isNil from 'lodash.isnil';
<mask> import { isResponsiveAnyProp } from '../../../theme/tools';
<mask>
<mask> type IUseResolvedFontFamily = {
<mask> fontFamily: string;
<mask> fontStyle: string;
<mask> fontWeight: string | number;
<mask> };
<mask>
<mask> // Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
<mask> function useResolvedFontFamily(props: IUseResolvedFontFamily) {
<mask> const { fontFamily, fontStyle, fontWeight } = props;
<mask>
<mask> const { fontConfig, fontWeights, fonts } = useTheme();
<mask> const fontToken = fonts[fontFamily];
<mask>
<mask> if (fontConfig && fontConfig[fontToken]) {
<mask> // fontWeights are also specified using "400"
<mask> const parsedFontWeight = parseInt(fontWeight as any);
<mask> let fontWeightNumber = Number.isNaN(parsedFontWeight)
<mask> ? fontWeights[fontWeight]
<mask> : fontWeight;
<mask> let fontVariants = fontConfig[fontToken][fontWeightNumber];
<mask> if (typeof fontVariants === 'object') {
<mask> if (fontVariants[fontStyle]) return fontVariants[fontStyle];
<mask> } else {
<mask> return fontVariants;
<mask> }
<mask> }
<mask> }
<mask>
<mask> const StyledText = styled(NativeText)<ITextProps>(
<mask> color,
<mask> space,
<mask> position,
<mask> layout,
</s> fix: broken examples and components </s> remove size: 'xs',
</s> add size: 'sm', </s> remove import { useTheme } from '../../../hooks';
</s> add </s> remove {...props}
</s> add | [
"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/2464949cde114539697de7fd3d580d8e49d1515c | src/components/primitives/Text/index.tsx | |
bg: 'transparent', | <mask> },
<mask> },
<mask> _disabled: {
<mask> _interactionBox: {
<mask> bg: 'transaprarent',
<mask> },
<mask> opacity: 0.4,
<mask> },
<mask> _pressed: {
<mask> _interactionBox: {
</s> fix: broken examples and components </s> remove overlayVisible={false}
_backdrop={{ opacity: 0.8, bg: 'pink.100' }}
</s> add _backdrop={{ bg: 'pink.100' }} </s> remove size: 'xs',
</s> add size: 'sm', </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove import { useTheme } from '../../../hooks';
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/theme/components/checkbox.ts |
size: 'sm', | <mask> import { mode } from '../tools';
<mask>
<mask> export const PopoverCloseButton = {
<mask> baseStyle: (props: any) => ({
<mask> size: 'xs',
<mask> p: 2,
<mask> mt: 'auto',
<mask> _icon: {
<mask> size: 3,
<mask> color: mode('gray.800', 'gray.100')(props),
</s> fix: broken examples and components </s> remove type IUseResolvedFontFamily = {
fontFamily: string;
fontStyle: string;
fontWeight: string | number;
};
// Android doesn't support fontWeight or fontStyle properties. So, we pass fontFamily instead.
function useResolvedFontFamily(props: IUseResolvedFontFamily) {
const { fontFamily, fontStyle, fontWeight } = props;
const { fontConfig, fontWeights, fonts } = useTheme();
const fontToken = fonts[fontFamily];
if (fontConfig && fontConfig[fontToken]) {
// fontWeights are also specified using "400"
const parsedFontWeight = parseInt(fontWeight as any);
let fontWeightNumber = Number.isNaN(parsedFontWeight)
? fontWeights[fontWeight]
: fontWeight;
let fontVariants = fontConfig[fontToken][fontWeightNumber];
if (typeof fontVariants === 'object') {
if (fontVariants[fontStyle]) return fontVariants[fontStyle];
} else {
return fontVariants;
}
}
}
</s> add </s> remove import { useTheme } from '../../../hooks';
</s> add </s> remove overlayVisible={false}
_backdrop={{ opacity: 0.8, bg: 'pink.100' }}
</s> add _backdrop={{ bg: 'pink.100' }} | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/2464949cde114539697de7fd3d580d8e49d1515c | src/theme/components/popover.ts |
disabled: true | <mask> this.state = {
<mask> modalVisible: false,
<mask> defaultDate: new Date(),
<mask> chosenDate: undefined,
<mask> enabled: true
<mask> };
<mask> }
<mask>
<mask> componentDidMount = () => {
<mask> this.setState({
</s> Changed enabled to disabled for Date Picker </s> remove enabled: this.props.enabled === false ? false : true
</s> add disabled: this.props.disabled ? true : false </s> remove onPress={this.state.enabled ? this.showDatePicker.bind(this) : undefined}
</s> add onPress={ !this.state.disabled ? this.showDatePicker.bind(this) : undefined } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/246c112275483f14fa74b0c34ef0810b0558fc9a | src/basic/DatePicker.js |
disabled: this.props.disabled ? true : false | <mask>
<mask> componentDidMount = () => {
<mask> this.setState({
<mask> defaultDate: this.props.defaultDate ? this.props.defaultDate : new Date(),
<mask> enabled: this.props.enabled === false ? false : true
<mask> });
<mask> if (!this.props.placeHolderText && this.props.defaultDate) {
<mask> this.setState({ chosenDate: this.props.defaultDate })
<mask> }
<mask> };
</s> Changed enabled to disabled for Date Picker </s> remove enabled: true
</s> add disabled: true </s> remove onPress={this.state.enabled ? this.showDatePicker.bind(this) : undefined}
</s> add onPress={ !this.state.disabled ? this.showDatePicker.bind(this) : undefined } | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/246c112275483f14fa74b0c34ef0810b0558fc9a | src/basic/DatePicker.js |
onPress={ !this.state.disabled ? this.showDatePicker.bind(this) : undefined } | <mask> return (
<mask> <View>
<mask> <View>
<mask> <Text
<mask> onPress={this.state.enabled ? this.showDatePicker.bind(this) : undefined}
<mask> style={[
<mask> { padding: 10, color: variables.datePickerTextColor },
<mask> this.state.chosenDate ? this.props.textStyle : this.props.placeHolderTextStyle
<mask> ]}
<mask> >
</s> Changed enabled to disabled for Date Picker </s> remove enabled: this.props.enabled === false ? false : true
</s> add disabled: this.props.disabled ? true : false </s> remove enabled: true
</s> add disabled: true | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/246c112275483f14fa74b0c34ef0810b0558fc9a | src/basic/DatePicker.js |
platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); | <mask> const deviceWidth = Dimensions.get("window").width;
<mask> const platform = Platform.OS;
<mask> const platformStyle = undefined;
<mask> const isIphoneX =
<mask> platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
<mask>
<mask> export default {
<mask> platformStyle,
<mask> platform,
<mask>
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
</s> add platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); </s> remove platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
</s> add platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
</s> add toolbarHeight: platform === "ios" ? 64 : 56, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/commonColor.js |
footerHeight: 55, | <mask> return this.fontSizeBase * 1.4;
<mask> },
<mask>
<mask> // Footer
<mask> footerHeight: isIphoneX ? 89 : 55,
<mask> footerDefaultBg: platform === "ios" ? "#F8F8F8" : "#3F51B5",
<mask> footerPaddingBottom: isIphoneX ? 34 : 0,
<mask>
<mask> // FooterTab
<mask> tabBarTextColor: platform === "ios" ? "#737373" : "#bfc6ea",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/commonColor.js |
footerPaddingBottom: 0, | <mask>
<mask> // Footer
<mask> footerHeight: isIphoneX ? 89 : 55,
<mask> footerDefaultBg: platform === "ios" ? "#F8F8F8" : "#3F51B5",
<mask> footerPaddingBottom: isIphoneX ? 34 : 0,
<mask>
<mask> // FooterTab
<mask> tabBarTextColor: platform === "ios" ? "#737373" : "#bfc6ea",
<mask> tabBarTextSize: platform === "ios" ? 14 : 11,
<mask> activeTab: platform === "ios" ? "#007aff" : "#fff",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
</s> add toolbarHeight: platform === "ios" ? 64 : 56, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/commonColor.js |
toolbarHeight: platform === "ios" ? 64 : 56, | <mask>
<mask> // Header
<mask> toolbarBtnColor: platform === "ios" ? "#007aff" : "#fff",
<mask> toolbarDefaultBg: platform === "ios" ? "#F8F8F8" : "#3F51B5",
<mask> toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
<mask> toolbarSearchIconSize: platform === "ios" ? 20 : 23,
<mask> toolbarInputColor: platform === "ios" ? "#CECDD2" : "#fff",
<mask> searchBarHeight: platform === "ios" ? 30 : 40,
<mask> searchBarInputHeight: platform === "ios" ? 30 : 50,
<mask> toolbarBtnTextColor: platform === "ios" ? "#007aff" : "#fff",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
</s> add toolbarHeight: platform === "ios" ? 64 : 56, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/commonColor.js |
platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); | <mask> const deviceWidth = Dimensions.get("window").width;
<mask> const platform = Platform.OS;
<mask> const platformStyle = "material";
<mask> const isIphoneX =
<mask> platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
<mask>
<mask> export default {
<mask> platformStyle,
<mask> platform,
<mask>
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
</s> add platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); </s> remove platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
</s> add platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
</s> add toolbarHeight: platform === "ios" ? 64 : 56, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/material.js |
footerHeight: 55, | <mask> return this.fontSizeBase * 1.4;
<mask> },
<mask>
<mask> // Footer
<mask> footerHeight: isIphoneX ? 89 : 55,
<mask> footerDefaultBg: "#3F51B5",
<mask> footerPaddingBottom: isIphoneX ? 34 : 0,
<mask>
<mask> // FooterTab
<mask> tabBarTextColor: "#bfc6ea",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/material.js |
footerPaddingBottom: 0, | <mask>
<mask> // Footer
<mask> footerHeight: isIphoneX ? 89 : 55,
<mask> footerDefaultBg: "#3F51B5",
<mask> footerPaddingBottom: isIphoneX ? 34 : 0,
<mask>
<mask> // FooterTab
<mask> tabBarTextColor: "#bfc6ea",
<mask> tabBarTextSize: 11,
<mask> activeTab: "#fff",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/material.js |
platform === "ios" && (deviceHeight === 812 || deviceWidth === 812); | <mask> const deviceWidth = Dimensions.get("window").width;
<mask> const platform = Platform.OS;
<mask> const platformStyle = undefined;
<mask> const isIphoneX =
<mask> platform === "ios" && deviceHeight === 812 && deviceWidth === 375;
<mask>
<mask> export default {
<mask> platformStyle,
<mask> platform,
<mask>
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/platform.js |
footerHeight: 55, | <mask> return this.fontSizeBase * 1.4;
<mask> },
<mask>
<mask> // Footer
<mask> footerHeight: isIphoneX ? 89 : 55,
<mask> footerDefaultBg: platform === "ios" ? "#F8F8F8" : "#3F51B5",
<mask> footerPaddingBottom: isIphoneX ? 34 : 0,
<mask>
<mask> // FooterTab
<mask> tabBarTextColor: platform === "ios" ? "#6b6b6b" : "#b3c7f9",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/platform.js |
footerPaddingBottom: 0, | <mask>
<mask> // Footer
<mask> footerHeight: isIphoneX ? 89 : 55,
<mask> footerDefaultBg: platform === "ios" ? "#F8F8F8" : "#3F51B5",
<mask> footerPaddingBottom: isIphoneX ? 34 : 0,
<mask>
<mask> // FooterTab
<mask> tabBarTextColor: platform === "ios" ? "#6b6b6b" : "#b3c7f9",
<mask> tabBarTextSize: platform === "ios" ? 14 : 11,
<mask> activeTab: platform === "ios" ? "#007aff" : "#fff",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove footerPaddingBottom: isIphoneX ? 34 : 0,
</s> add footerPaddingBottom: 0, </s> remove footerHeight: isIphoneX ? 89 : 55,
</s> add footerHeight: 55, </s> remove toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
</s> add toolbarHeight: platform === "ios" ? 64 : 56, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/platform.js |
toolbarHeight: platform === "ios" ? 64 : 56, | <mask>
<mask> // Header
<mask> toolbarBtnColor: platform === "ios" ? "#007aff" : "#fff",
<mask> toolbarDefaultBg: platform === "ios" ? "#F8F8F8" : "#3F51B5",
<mask> toolbarHeight: platform === "ios" ? (isIphoneX ? 88 : 64) : 56,
<mask> toolbarSearchIconSize: platform === "ios" ? 20 : 23,
<mask> toolbarInputColor: platform === "ios" ? "#CECDD2" : "#fff",
<mask> searchBarHeight: platform === "ios" ? 30 : 40,
<mask> searchBarInputHeight: platform === "ios" ? 30 : 50,
<mask> toolbarBtnTextColor: platform === "ios" ? "#007aff" : "#fff",
</s> Changed variables file based on Safe area implementation of branch feat/SafeArea | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25bd4cac459d3075be1bd026abb3f63b29dc37fd | src/theme/variables/platform.js |
import {
TouchableOpacity,
Platform,
TouchableOpacityProps,
} from 'react-native'; | <mask> import React from 'react';
<mask> import { TouchableOpacity, Platform } from 'react-native';
<mask> import Icon from '../Icon';
<mask> import Box from '../Box';
<mask> import { useThemeProps } from '../../../hooks';
<mask> import type { IRadioProps } from './types';
<mask> import { mergeRefs } from './../../../utils';
</s> fix: radio web accessibility - cleanup </s> remove import type { IFormControlContext } from 'native-base';
import { FormControlContext } from '../../composites/FormControl/FormControl';
import { Box } from '..';
import type { IRadioContext } from './types';
</s> add </s> remove let { children } = props;
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
const inputRef = React.useRef(null);
let { inputProps } = useRadio(props, contextState.state, inputRef);
| <mask> });
<mask>
<mask> // only calling below function when icon exist.
<mask> const sizedIcon = () =>
<mask> //@ts-ignore
<mask> React.cloneElement(icon, {
<mask> size,
<mask> color:
</s> fix: radio web accessibility - cleanup </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove const RadioGroup = ({ size, colorScheme, ...props }: any) => {
</s> add const RadioGroup = ({ size, colorScheme, ...props }: IRadioGroupProps) => { </s> remove let { children } = props;
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add </s> remove isDisabled: boolean;
isReadOnly: boolean;
</s> add | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
? inputProps.disabled | <mask> size,
<mask> color:
<mask> //@ts-ignore
<mask> icon.props.color ?? isSelected
<mask> ? contextState.isDisabled
<mask> ? borderColor
<mask> : activeColor
<mask> : borderColor,
<mask> });
<mask>
</s> fix: radio web accessibility - cleanup </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove isHovered && !contextState.isDisabled
</s> add isHovered && !inputProps.disabled </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
<mask> : activeColor
<mask> : borderColor,
<mask> });
<mask>
<mask> const inputRef = React.useRef(null);
<mask> let { inputProps } = useRadio(
<mask> {
<mask> isReadOnly: contextState.isReadOnly,
<mask> isDisabled: contextState.isDisabled,
<mask> ...props,
<mask> },
<mask> contextState.state,
<mask> inputRef
<mask> );
<mask>
<mask> let isSelected = contextState.state.selectedValue === props.value;
<mask>
<mask> const _ref = React.useRef(null);
<mask> const { isHovered } = useHover({}, _ref);
<mask>
</s> fix: radio web accessibility - cleanup </s> remove isHovered && !contextState.isDisabled
</s> add isHovered && !inputProps.disabled </s> remove let { children } = props;
</s> add </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx | |
const mergedRefs = mergeRefs([_ref, ref]); | <mask> const _ref = React.useRef(null);
<mask> const { isHovered } = useHover({}, _ref);
<mask>
<mask> const outlineColor =
<mask> isHovered && !inputProps.disabled
<mask> ? activeColor
<mask> : isSelected
<mask> ? inputProps.disabled
</s> fix: radio web accessibility - cleanup </s> remove isHovered && !contextState.isDisabled
</s> add isHovered && !inputProps.disabled </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
isHovered && !inputProps.disabled | <mask> const _ref = React.useRef(null);
<mask> const { isHovered } = useHover({}, _ref);
<mask>
<mask> const outlineColor =
<mask> isHovered && !contextState.isDisabled
<mask> ? activeColor
<mask> : isSelected
<mask> ? contextState.isDisabled
<mask> ? borderColor
<mask> : activeColor
</s> fix: radio web accessibility - cleanup </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
? inputProps.disabled | <mask> const outlineColor =
<mask> isHovered && !contextState.isDisabled
<mask> ? activeColor
<mask> : isSelected
<mask> ? contextState.isDisabled
<mask> ? borderColor
<mask> : activeColor
<mask> : borderColor;
<mask> let component = (
<mask> <Box
</s> fix: radio web accessibility - cleanup </s> remove isHovered && !contextState.isDisabled
</s> add isHovered && !inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
opacity={inputProps.disabled ? 0.4 : 1} | <mask> flexDirection="row"
<mask> justifyContent="center"
<mask> alignItems="center"
<mask> {...newProps}
<mask> opacity={contextState.isDisabled ? 0.4 : 1}
<mask> {...(Platform.OS === 'web'
<mask> ? {
<mask> disabled: contextState.isDisabled,
<mask> cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
<mask> }
</s> fix: radio web accessibility - cleanup </s> remove disabled: contextState.isDisabled,
cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
</s> add disabled: inputProps.disabled,
cursor: inputProps.disabled ? 'not-allowed' : 'auto', </s> remove backgroundColor={contextState.isDisabled ? 'muted.200' : 'transparent'}
</s> add backgroundColor={inputProps.disabled ? 'muted.200' : 'transparent'} </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove isHovered && !contextState.isDisabled
</s> add isHovered && !inputProps.disabled | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
disabled: inputProps.disabled,
cursor: inputProps.disabled ? 'not-allowed' : 'auto', | <mask> {...newProps}
<mask> opacity={contextState.isDisabled ? 0.4 : 1}
<mask> {...(Platform.OS === 'web'
<mask> ? {
<mask> disabled: contextState.isDisabled,
<mask> cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
<mask> }
<mask> : {})}
<mask> >
<mask> <Box
<mask> borderColor={outlineColor}
</s> fix: radio web accessibility - cleanup </s> remove opacity={contextState.isDisabled ? 0.4 : 1}
</s> add opacity={inputProps.disabled ? 0.4 : 1} </s> remove backgroundColor={contextState.isDisabled ? 'muted.200' : 'transparent'}
</s> add backgroundColor={inputProps.disabled ? 'muted.200' : 'transparent'} </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
backgroundColor={inputProps.disabled ? 'muted.200' : 'transparent'} | <mask> : {})}
<mask> >
<mask> <Box
<mask> borderColor={outlineColor}
<mask> backgroundColor={contextState.isDisabled ? 'muted.200' : 'transparent'}
<mask> borderWidth={1}
<mask> display="flex"
<mask> justifyContent="center"
<mask> alignItems="center"
<mask> borderRadius={999}
</s> fix: radio web accessibility - cleanup </s> remove disabled: contextState.isDisabled,
cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
</s> add disabled: inputProps.disabled,
cursor: inputProps.disabled ? 'not-allowed' : 'auto', </s> remove opacity={contextState.isDisabled ? 0.4 : 1}
</s> add opacity={inputProps.disabled ? 0.4 : 1} </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove //@ts-ignore
</s> add </s> remove {children}
</s> add {props.children} | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
? inputProps.disabled | <mask> type="MaterialCommunityIcons"
<mask> size={size}
<mask> color={
<mask> isSelected
<mask> ? contextState.isDisabled
<mask> ? borderColor
<mask> : activeColor
<mask> : 'transparent'
<mask> }
<mask> opacity={isSelected ? 1 : 0}
</s> fix: radio web accessibility - cleanup </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove isHovered && !contextState.isDisabled
</s> add isHovered && !inputProps.disabled </s> remove opacity={contextState.isDisabled ? 0.4 : 1}
</s> add opacity={inputProps.disabled ? 0.4 : 1} </s> remove disabled: contextState.isDisabled,
cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
</s> add disabled: inputProps.disabled,
cursor: inputProps.disabled ? 'not-allowed' : 'auto', | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
<label ref={_ref}> | <mask> );
<mask> return (
<mask> <>
<mask> {Platform.OS === 'web' ? (
<mask> <label>
<mask> <VisuallyHidden>
<mask> <input {...inputProps} ref={ref}></input>
<mask> </VisuallyHidden>
<mask>
<mask> {component}
</s> fix: radio web accessibility - cleanup </s> remove //@ts-ignore
</s> add </s> remove ref={mergeRefs([ref, _ref])}
{...inputProps}
</s> add ref={mergedRefs}
{...(inputProps as TouchableOpacityProps)} </s> remove let { children } = props;
</s> add </s> remove opacity={contextState.isDisabled ? 0.4 : 1}
</s> add opacity={inputProps.disabled ? 0.4 : 1} </s> remove disabled: contextState.isDisabled,
cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
</s> add disabled: inputProps.disabled,
cursor: inputProps.disabled ? 'not-allowed' : 'auto', | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
<mask>
<mask> {component}
<mask> </label>
<mask> ) : (
<mask> //@ts-ignore
<mask> <TouchableOpacity
<mask> activeOpacity={1}
<mask> ref={mergeRefs([ref, _ref])}
<mask> {...inputProps}
<mask> >
</s> fix: radio web accessibility - cleanup </s> remove ref={mergeRefs([ref, _ref])}
{...inputProps}
</s> add ref={mergedRefs}
{...(inputProps as TouchableOpacityProps)} </s> remove <label>
</s> add <label ref={_ref}> </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove backgroundColor={contextState.isDisabled ? 'muted.200' : 'transparent'}
</s> add backgroundColor={inputProps.disabled ? 'muted.200' : 'transparent'} | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx | |
ref={mergedRefs}
{...(inputProps as TouchableOpacityProps)} | <mask> ) : (
<mask> //@ts-ignore
<mask> <TouchableOpacity
<mask> activeOpacity={1}
<mask> ref={mergeRefs([ref, _ref])}
<mask> {...inputProps}
<mask> >
<mask> {component}
<mask> </TouchableOpacity>
<mask> )}
<mask> </>
</s> fix: radio web accessibility - cleanup </s> remove //@ts-ignore
</s> add </s> remove <label>
</s> add <label ref={_ref}> </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove ? contextState.isDisabled
</s> add ? inputProps.disabled </s> remove backgroundColor={contextState.isDisabled ? 'muted.200' : 'transparent'}
</s> add backgroundColor={inputProps.disabled ? 'muted.200' : 'transparent'} | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/Radio.tsx |
import Box from '../Box';
import {
FormControlContext,
IFormControlContext,
} from '../../composites/FormControl';
import type { IRadioContext, IRadioGroupProps } from './types'; | <mask> import React from 'react';
<mask> import { useRadioGroupState } from '@react-stately/radio';
<mask> import { useRadioGroup } from '@react-native-aria/radio';
<mask>
<mask> export let RadioContext = React.createContext<IRadioContext>(
<mask> {} as IRadioContext
<mask> );
</s> fix: radio web accessibility - cleanup </s> remove import type { IFormControlContext } from 'native-base';
import { FormControlContext } from '../../composites/FormControl/FormControl';
import { Box } from '..';
import type { IRadioContext } from './types';
</s> add </s> remove import { TouchableOpacity, Platform } from 'react-native';
</s> add import {
TouchableOpacity,
Platform,
TouchableOpacityProps,
} from 'react-native'; </s> remove const RadioGroup = ({ size, colorScheme, ...props }: any) => {
</s> add const RadioGroup = ({ size, colorScheme, ...props }: IRadioGroupProps) => { </s> remove let { children } = props;
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/RadioGroup.tsx |
<mask> import React from 'react';
<mask> import { useRadioGroupState } from '@react-stately/radio';
<mask> import { useRadioGroup } from '@react-native-aria/radio';
<mask> import type { IFormControlContext } from 'native-base';
<mask> import { FormControlContext } from '../../composites/FormControl/FormControl';
<mask> import { Box } from '..';
<mask> import type { IRadioContext } from './types';
<mask>
<mask> export let RadioContext = React.createContext<IRadioContext>(
<mask> {} as IRadioContext
<mask> );
<mask>
</s> fix: radio web accessibility - cleanup </s> remove import { TouchableOpacity, Platform } from 'react-native';
</s> add import {
TouchableOpacity,
Platform,
TouchableOpacityProps,
} from 'react-native'; </s> remove const RadioGroup = ({ size, colorScheme, ...props }: any) => {
</s> add const RadioGroup = ({ size, colorScheme, ...props }: IRadioGroupProps) => { </s> remove let { children } = props;
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/RadioGroup.tsx | |
const RadioGroup = ({ size, colorScheme, ...props }: IRadioGroupProps) => { | <mask> export let RadioContext = React.createContext<IRadioContext>(
<mask> {} as IRadioContext
<mask> );
<mask>
<mask> const RadioGroup = ({ size, colorScheme, ...props }: any) => {
<mask> const formControlContext: IFormControlContext = React.useContext(
<mask> FormControlContext
<mask> );
<mask> let { children } = props;
<mask> let state = useRadioGroupState(props);
</s> fix: radio web accessibility - cleanup </s> remove let { children } = props;
</s> add </s> remove import type { IFormControlContext } from 'native-base';
import { FormControlContext } from '../../composites/FormControl/FormControl';
import { Box } from '..';
import type { IRadioContext } from './types';
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/RadioGroup.tsx |
<mask> const RadioGroup = ({ size, colorScheme, ...props }: any) => {
<mask> const formControlContext: IFormControlContext = React.useContext(
<mask> FormControlContext
<mask> );
<mask> let { children } = props;
<mask> let state = useRadioGroupState(props);
<mask> let { radioGroupProps } = useRadioGroup(props, state);
<mask> return (
<mask> <RadioContext.Provider
<mask> value={{
</s> fix: radio web accessibility - cleanup </s> remove const RadioGroup = ({ size, colorScheme, ...props }: any) => {
</s> add const RadioGroup = ({ size, colorScheme, ...props }: IRadioGroupProps) => { </s> remove import type { IFormControlContext } from 'native-base';
import { FormControlContext } from '../../composites/FormControl/FormControl';
import { Box } from '..';
import type { IRadioContext } from './types';
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/RadioGroup.tsx | |
<mask> ...formControlContext,
<mask> size,
<mask> colorScheme,
<mask> state,
<mask> isDisabled: props.isDisabled,
<mask> isReadOnly: props.isReadOnly,
<mask> }}
<mask> >
<mask> <Box alignItems="flex-start" {...radioGroupProps} {...props}>
<mask> {children}
<mask> </Box>
</s> fix: radio web accessibility - cleanup </s> remove {children}
</s> add {props.children} </s> remove const RadioGroup = ({ size, colorScheme, ...props }: any) => {
</s> add const RadioGroup = ({ size, colorScheme, ...props }: IRadioGroupProps) => { </s> remove isDisabled: boolean;
isReadOnly: boolean;
</s> add </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add </s> remove let { children } = props;
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/RadioGroup.tsx | |
{props.children} | <mask> isReadOnly: props.isReadOnly,
<mask> }}
<mask> >
<mask> <Box alignItems="flex-start" {...radioGroupProps} {...props}>
<mask> {children}
<mask> </Box>
<mask> </RadioContext.Provider>
<mask> );
<mask> };
<mask>
</s> fix: radio web accessibility - cleanup </s> remove isDisabled: props.isDisabled,
isReadOnly: props.isReadOnly,
</s> add </s> remove isDisabled: boolean;
isReadOnly: boolean;
</s> add </s> remove backgroundColor={contextState.isDisabled ? 'muted.200' : 'transparent'}
</s> add backgroundColor={inputProps.disabled ? 'muted.200' : 'transparent'} </s> remove disabled: contextState.isDisabled,
cursor: contextState.isDisabled ? 'not-allowed' : 'auto',
</s> add disabled: inputProps.disabled,
cursor: inputProps.disabled ? 'not-allowed' : 'auto', </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/RadioGroup.tsx |
<mask> size?: 'sm' | 'md' | 'lg';
<mask> // Custom props
<mask> style?: any;
<mask> state: RadioGroupState;
<mask> isDisabled: boolean;
<mask> isReadOnly: boolean;
<mask> };
<mask>
<mask> export type IUseRadioGroupReturnType = {
<mask> radioGroupProps: {
<mask> accessibilityRole: AccessibilityRole;
</s> fix: radio web accessibility - cleanup </s> remove import type { IFormControlContext } from 'native-base';
import { FormControlContext } from '../../composites/FormControl/FormControl';
import { Box } from '..';
import type { IRadioContext } from './types';
</s> add </s> remove {children}
</s> add {props.children} </s> remove const inputRef = React.useRef(null);
let { inputProps } = useRadio(
{
isReadOnly: contextState.isReadOnly,
isDisabled: contextState.isDisabled,
...props,
},
contextState.state,
inputRef
);
</s> add </s> remove isDisabled: props.isDisabled,
isReadOnly: props.isReadOnly,
</s> add | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/25db086f8464d501cecfeb4a22bdfabd866c0fbc | src/components/primitives/Radio/types.tsx | |
<Box mx={5} w={250}> | <mask> <Stack mx={5} space={4} alignItems="center" w="100%">
<mask> <Text>onChangeValue - {onChangeValue}</Text>
<mask> <Text>onChangeEndValue - {onChangeEndValue}</Text>
<mask>
<mask> <Box mx={5} w="250">
<mask> <Slider
<mask> defaultValue={70}
<mask> colorScheme="cyan"
<mask> onChange={(v) => {
<mask> setOnChangeValue(Math.floor(v));
</s> fix: styled system cleanup (#3873)
* fix: stack actionsheet icon button padding
* fix: fab padding
* fix: shadow not working in new styled system
* fix: boxsize support
* fix: slider gone in storybook </s> remove const { children, divider, reversed, ...remainingProps } = props;
const { space, direction, ...newProps }: any = usePropsResolution(
'Stack',
remainingProps
);
</s> add const {
children,
space,
direction,
divider,
reversed,
...remainingProps
} = props;
const newProps: any = usePropsResolution('Stack', remainingProps);
const {
space: resolvedSpace,
direction: resolvedDirection,
} = useBreakpointResolvedProps({ space, direction }); </s> remove const windowWidth = useWindowDimensions().width;
const currentBreakpoint = React.useMemo(
//@ts-ignore
() => getClosestBreakpoint(theme.breakpoints, windowWidth),
//@ts-ignore
[windowWidth, theme.breakpoints]
);
</s> add const currentBreakpoint = useNativeBaseConfig('makeStyledComponent')
.currentBreakpoint; </s> remove <Box flexDirection={direction} {...newProps} ref={ref}>
</s> add <Box flexDirection={resolvedDirection} {...newProps} ref={ref}> </s> remove export default () => {
return {
0: {
shadowColor: colors.black,
shadowOffset: {
width: 0,
height: 1,
},
shadowOpacity: 0.18,
shadowRadius: 1.0,
elevation: 1,
</s> add export default {
0: {
shadowColor: colors.black,
shadowOffset: {
width: 0,
height: 1, | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/27609936d69249cafd0c400bf4826f7c0e101831 | example/storybook/stories/components/primitives/Slider/Value.tsx |
<Modal.Content {...newProps} ref={ref} safeAreaBottom> | <mask> <Box py={5} {...panResponder.panHandlers} collapsable={false} />
<mask> </>
<mask> ) : null}
<mask>
<mask> <Modal.Content {...newProps} debug="1234" ref={ref} safeAreaBottom>
<mask> {!hideDragIndicator ? (
<mask> <>
<mask> {/* Hack. Fix later. Add -2 negative margin to remove the padding added by ActionSheetContent */}
<mask> <Box
<mask> py={5}
</s> fix: styled system cleanup (#3873)
* fix: stack actionsheet icon button padding
* fix: fab padding
* fix: shadow not working in new styled system
* fix: boxsize support
* fix: slider gone in storybook </s> remove <Box flexDirection={direction} {...newProps} ref={ref}>
</s> add <Box flexDirection={resolvedDirection} {...newProps} ref={ref}> </s> remove space,
direction === 'row' ? 'X' : 'Y',
</s> add resolvedSpace,
resolvedDirection === 'row' ? 'X' : 'Y', </s> remove icon={<CloseIcon size={themeProps._closeIcon} />}
</s> add icon={<CloseIcon {...themeProps._closeIcon} />} </s> remove const currentBreakpoint = React.useMemo(
() => getClosestBreakpoint(theme.breakpoints, windowWidth),
[windowWidth, theme.breakpoints]
);
</s> add const currentBreakpoint = useNativeBaseConfig('usePropsResolution')
.currentBreakpoint; </s> remove <Box mx={5} w="250">
</s> add <Box mx={5} w={250}> | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/27609936d69249cafd0c400bf4826f7c0e101831 | src/components/composites/Actionsheet/ActionsheetContent.tsx |
icon={<CloseIcon {...themeProps._closeIcon} />} | <mask> <IconButton
<mask> onPress={() => {
<mask> hideToast(id);
<mask> }}
<mask> icon={<CloseIcon size={themeProps._closeIcon} />}
<mask> />
<mask> ) : undefined
<mask> }
<mask> {...rest}
<mask> >
</s> fix: styled system cleanup (#3873)
* fix: stack actionsheet icon button padding
* fix: fab padding
* fix: shadow not working in new styled system
* fix: boxsize support
* fix: slider gone in storybook </s> remove <Modal.Content {...newProps} debug="1234" ref={ref} safeAreaBottom>
</s> add <Modal.Content {...newProps} ref={ref} safeAreaBottom> </s> remove <NativeBaseConfigProvider config={config}>
</s> add <NativeBaseConfigProvider
config={config}
currentBreakpoint={currentBreakpoint}
> </s> remove const windowWidth = useWindowDimensions().width;
const currentBreakpoint = React.useMemo(
//@ts-ignore
() => getClosestBreakpoint(theme.breakpoints, windowWidth),
//@ts-ignore
[windowWidth, theme.breakpoints]
);
</s> add const currentBreakpoint = useNativeBaseConfig('makeStyledComponent')
.currentBreakpoint; </s> remove space,
direction === 'row' ? 'X' : 'Y',
</s> add resolvedSpace,
resolvedDirection === 'row' ? 'X' : 'Y', </s> remove <Box flexDirection={direction} {...newProps} ref={ref}>
</s> add <Box flexDirection={resolvedDirection} {...newProps} ref={ref}> | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/27609936d69249cafd0c400bf4826f7c0e101831 | src/components/composites/Toast/Toast.tsx |
import { useBreakpointResolvedProps } from '../../../hooks'; | <mask> import { getSpacedChildren } from '../../../utils';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import type { IBoxProps } from '../Box';
<mask> import type { ResponsiveValue } from '../../types';
<mask>
<mask> export interface IStackProps extends IBoxProps {
<mask> /**
<mask> * The divider element to use between elements.
<mask> */
<mask> divider?: JSX.Element;
</s> fix: styled system cleanup (#3873)
* fix: stack actionsheet icon button padding
* fix: fab padding
* fix: shadow not working in new styled system
* fix: boxsize support
* fix: slider gone in storybook </s> remove import React from 'react';
</s> add </s> remove import { useWindowDimensions } from 'react-native';
</s> add </s> remove import {
getClosestBreakpoint,
omitUndefined,
extractInObject,
} from './../../theme/tools';
</s> add import { omitUndefined, extractInObject } from './../../theme/tools'; </s> remove import { Platform } from 'react-native';
import { platformSpecificSpaceUnits } from '../theme/tools/utils';
</s> add import { Platform, useWindowDimensions } from 'react-native';
import {
getClosestBreakpoint,
platformSpecificSpaceUnits,
} from '../theme/tools/utils'; | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/27609936d69249cafd0c400bf4826f7c0e101831 | src/components/primitives/Stack/Stack.tsx |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.