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 |
|---|---|---|---|---|
_disabled: {
opacity: '40', | <mask> };
<mask> }
<mask>
<mask> return {
<mask> _text: {
<mask> color: props.isDisabled
<mask> ? disabledTextColor(props)
<mask> : mode(`${c}.500`, `${c}.300`)(props),
<mask> },
<mask> bg: 'transparent',
<mask> _web: {
<mask> outlineWidth: '0',
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_loading: {
opacity: '40', | <mask> _hover: {
<mask> borderColor: mode(`${c}.500`, `${c}.200`)(props),
<mask> bg: transparentize(mode(`${c}.200`, `${c}.400`)(props), 0.5)(props.theme),
<mask> },
<mask> _focusVisible: {
<mask> borderColor: mode(`${c}.700`, `${c}.200`)(props),
<mask> bg: transparentize(mode... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_light: {
_text: {
color: `${colorScheme}.600`,
},
_icon: {
color: `${colorScheme}.600`,
},
_spinner: {
color: `${colorScheme}.600`,
},
_hover: {
bg: `${colorScheme}.600:alpha.10`,
},
_pressed: {
bg: `${colorScheme}.600:al... | <mask> _focusVisible: {
<mask> borderColor: mode(`${c}.700`, `${c}.200`)(props),
<mask> bg: transparentize(mode(`${c}.200`, `${c}.400`)(props), 0.5)(props.theme),
<mask> },
<mask> _pressed: {
<mask> borderColor: mode(`${c}.600`, `${c}.200`)(props),
<mask> bg: transparentize(mo... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_dark: {
_text: {
color: `${colorScheme}.500`,
},
_icon: {
color: `${colorScheme}.500`,
},
_spinner: {
color: `${colorScheme}.500`,
},
_hover: {
bg: `${colorScheme}.500:alpha.10`,
},
_pressed: {
bg: `${colorScheme}.500:alp... | <mask> _pressed: {
<mask> borderColor: mode(`${c}.600`, `${c}.200`)(props),
<mask> bg: transparentize(mode(`${c}.300`, `${c}.500`)(props), 0.5)(props.theme),
<mask> },
<mask> _spinner: {
<mask> size: 'sm',
<mask> },
<mask> };
<mask> }
<mask>
<mask> function variantOutline... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
function variantOutline({ colorScheme }: Dict) { | <mask> },
<mask> };
<mask> }
<mask>
<mask> function variantOutline(props: Dict) {
<mask> const { colorScheme: c } = props;
<mask> const borderColor = mode(`muted.200`, `muted.500`)(props);
<mask> return {
<mask> borderWidth: '1',
<mask> borderColor:
<mask> c === 'muted'
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
borderWidth: '1px',
_disabled: {
opacity: '40',
},
_loading: {
opacity: '40',
},
_light: {
borderColor: 'muted.300',
_text: {
color: `${colorScheme}.600`,
},
_icon: {
color: `${colorScheme}.600`,
},
_spinner: {
color: `${col... | <mask> function variantOutline(props: Dict) {
<mask> const { colorScheme: c } = props;
<mask> const borderColor = mode(`muted.200`, `muted.500`)(props);
<mask> return {
<mask> borderWidth: '1',
<mask> borderColor:
<mask> c === 'muted'
<mask> ? borderColor
<mask> : props.isDi... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
function variantSolid({ colorScheme }: Dict) {
return {
_text: {
color: 'text.50', | <mask> ...variantGhost(props),
<mask> };
<mask> }
<mask>
<mask> function variantSolid(props: Dict) {
<mask> const { colorScheme: c } = props;
<mask> let bg = `${c}.500`;
<mask> if (props.isDisabled) {
<mask> bg = mode(`muted.300`, `muted.500`)(props);
<mask> }
<mask>
<mask> const style... | [
"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/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
color: 'text.50', | <mask> const styleObject = {
<mask> _web: {
<mask> outlineWidth: '0',
<mask> },
<mask> bg,
<mask> _hover: {
<mask> bg: `${c}.600`,
<mask> },
<mask> _pressed: {
<mask> bg: `${c}.700`,
<mask> },
<mask> _focus: {
</s> feat: _icon internal prop and design cha... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_spinner: {
color: 'text.50', | <mask> bg,
<mask> _hover: {
<mask> bg: `${c}.600`,
<mask> },
<mask> _pressed: {
<mask> bg: `${c}.700`,
<mask> },
<mask> _focus: {
<mask> bg: `${c}.600`,
<mask> },
<mask> _loading: {
</s> feat: _icon internal prop and design changes for button and divider </s... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_disabled: {
opacity: '40', | <mask> },
<mask> _pressed: {
<mask> bg: `${c}.700`,
<mask> },
<mask> _focus: {
<mask> bg: `${c}.600`,
<mask> },
<mask> _loading: {
<mask> bg: mode(`warmGray.50`, `${c}.300`)(props),
<mask> opacity: '50',
<mask> },
</s> feat: _icon internal prop and design ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
opacity: '40',
},
_light: {
bg: `${colorScheme}.600`,
_hover: {
bg: `${colorScheme}.700`,
},
_pressed: {
bg: `${colorScheme}.800`,
},
},
_dark: {
bg: `${colorScheme}.600`,
_hover: {
bg: `${colorScheme}.700`,
},
_pressed:... | <mask> _focus: {
<mask> bg: `${c}.600`,
<mask> },
<mask> _loading: {
<mask> bg: mode(`warmGray.50`, `${c}.300`)(props),
<mask> opacity: '50',
<mask> },
<mask> _disabled: { bg: mode(`trueGray.300`, `trueGray.600`)(props) },
<mask> };
<mask>
<mask> return styleObject;... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
<mask> _loading: {
<mask> bg: mode(`warmGray.50`, `${c}.300`)(props),
<mask> opacity: '50',
<mask> },
<mask> _disabled: { bg: mode(`trueGray.300`, `trueGray.600`)(props) },
<mask> };
<mask>
<mask> return styleObject;
<mask> }
<mask>
</s> feat: _icon internal prop and design chan... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts | |
<mask> opacity: '50',
<mask> },
<mask> _disabled: { bg: mode(`trueGray.300`, `trueGray.600`)(props) },
<mask> };
<mask>
<mask> return styleObject;
<mask> }
<mask>
<mask> // function getBg(props: Record<string, any>) {
<mask> // const { theme, status, variant } = props;
<mask> // let {... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts | |
function variantSubtle({ colorScheme }: Dict) {
return { | <mask>
<mask> return styleObject;
<mask> }
<mask>
<mask> // function getBg(props: Record<string, any>) {
<mask> // const { theme, status, variant } = props;
<mask> // let { colorScheme } = props;
<mask>
<mask> // colorScheme = getColorScheme(
<mask> // props,
<mask> // colorScheme !== 'pri... | [
"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/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
color: `${colorScheme}.900`, | <mask> color = mode(`${c}.500`, `${c}.600`)(props);
<mask> }
<mask> const styleObject = {
<mask> _text: {
<mask> color: color,
<mask> },
<mask> _web: {
<mask> outlineWidth: '0',
<mask> },
<mask> bg,
</s> feat: _icon internal prop and design changes for button and divid... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
color: `${colorScheme}.900`, | <mask> const styleObject = {
<mask> _text: {
<mask> color: color,
<mask> },
<mask> _web: {
<mask> outlineWidth: '0',
<mask> },
<mask> bg,
<mask> _hover: {
<mask> _text: { color: mode(`${c}.600`, `${c}.700`)(props) },
<mask> bg: mode(`${c}.200`, `${c}.300`)(pr... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_spinner: {
color: `${colorScheme}.900`,
},
_disabled: {
opacity: '40',
},
_loading: {
opacity: '40', | <mask> },
<mask> _web: {
<mask> outlineWidth: '0',
<mask> },
<mask> bg,
<mask> _hover: {
<mask> _text: { color: mode(`${c}.600`, `${c}.700`)(props) },
<mask> bg: mode(`${c}.200`, `${c}.300`)(props),
<mask> },
<mask> _pressed: {
<mask> _text: { color: mode(`... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_light: {
bg: `${colorScheme}.100`,
_hover: {
bg: `${colorScheme}.200`,
},
_pressed: {
bg: `${colorScheme}.300`,
},
},
_dark: {
bg: `${colorScheme}.300`,
_hover: {
bg: `${colorScheme}.200`,
},
_pressed: {
bg: `${colorSchem... | <mask> _hover: {
<mask> _text: { color: mode(`${c}.600`, `${c}.700`)(props) },
<mask> bg: mode(`${c}.200`, `${c}.300`)(props),
<mask> },
<mask> _pressed: {
<mask> _text: { color: mode(`${c}.700`, `${c}.800`)(props) },
<mask> bg: mode(`${c}.300`, `${c}.400`)(props),
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
<mask> _text: { color: mode(`${c}.700`, `${c}.800`)(props) },
<mask> bg: mode(`${c}.300`, `${c}.400`)(props),
<mask> },
<mask> };
<mask>
<mask> return styleObject;
<mask> }
<mask>
<mask> function variantLink(props: Dict) {
<mask> const { colorScheme: c } = props;
<mask>
</s> feat: _... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts | |
function variantLink({ colorScheme }: Dict) { | <mask>
<mask> return styleObject;
<mask> }
<mask>
<mask> function variantLink(props: Dict) {
<mask> const { colorScheme: c } = props;
<mask>
<mask> return {
<mask> ...variantGhost(props),
<mask> _text: {
<mask> textDecorationLine: Platform.select({
<mask> ios: 'underline',
</... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
color: `${colorScheme}.600`,
},
_spinner: {
color: `${colorScheme}.600`,
},
_disabled: {
opacity: '40',
},
_loading: {
opacity: '40', | <mask> function variantLink(props: Dict) {
<mask> const { colorScheme: c } = props;
<mask>
<mask> return {
<mask> ...variantGhost(props),
<mask> _text: {
<mask> textDecorationLine: Platform.select({
<mask> ios: 'underline',
<mask> web: 'underline',
<mask> }),
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
<mask> : mode(`${c}.500`, `${c}.300`)(props),
<mask> },
<mask> _hover: {
<mask> _text: {
<mask> color: mode(`${c}.600`, `${c}.400`)(props),
<mask> textDecorationLine: 'underline',
<mask> },
<mask> },
<mask> _focusVisible: {
<mask> _text: {
</s> feat... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts | |
_light: { | <mask> color: mode(`${c}.600`, `${c}.400`)(props),
<mask> textDecorationLine: 'underline',
<mask> },
<mask> },
<mask> _focusVisible: {
<mask> _text: {
<mask> color: mode(`${c}.600`, `${c}.400`)(props),
<mask> textDecorationLine: 'underline',
<mask> },
... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
color: `${colorScheme}.600`, | <mask> },
<mask> },
<mask> _focusVisible: {
<mask> _text: {
<mask> color: mode(`${c}.600`, `${c}.400`)(props),
<mask> textDecorationLine: 'underline',
<mask> },
<mask> },
<mask> _pressed: {
<mask> _text: { color: mode(`${c}.700`, `${c}.500`)(props) },
<... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_dark: {
_text: {
color: `${colorScheme}.500`,
}, | <mask> color: mode(`${c}.600`, `${c}.400`)(props),
<mask> textDecorationLine: 'underline',
<mask> },
<mask> },
<mask> _pressed: {
<mask> _text: { color: mode(`${c}.700`, `${c}.500`)(props) },
<mask> },
<mask> };
<mask> }
<mask>
<mask> function variantUnstyled() {
<... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
size: 'xs',
}, | <mask> fontSize: 'md',
<mask> },
<mask> },
<mask> md: {
<mask> px: '3',
<mask> py: '2',
<mask> _text: {
</s> feat: _icon internal prop and design changes for button and divider </s> remove px: '2',
</s> add px: '3', </s> remove variant: 'solid',
</s> add variant: 'link', | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
size: 'xs',
}, | <mask> py: '2',
<mask> _text: {
<mask> fontSize: 'sm',
<mask> },
<mask> },
<mask> sm: {
<mask> px: '2',
<mask> py: '2',
<mask> _text: {
</s> feat: _icon internal prop and design changes for button and divider </s> remove px: '2',
</s> add px: '3', </s> remove _sp... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
size: 'xxs',
}, | <mask> fontSize: 'xs',
<mask> },
<mask> },
<mask> xs: {
<mask> px: '3',
<mask> py: '2',
<mask> _text: {
</s> feat: _icon internal prop and design changes for button and divider </s> remove px: '2',
</s> add px: '3', </s> remove bg,
_hover: {
_text: { color: mode(... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
px: '3', | <mask> fontSize: 'xs',
<mask> },
<mask> },
<mask> xs: {
<mask> px: '2',
<mask> py: '2',
<mask> _text: {
<mask> fontSize: '2xs',
<mask> },
<mask> },
</s> feat: _icon internal prop and design changes for button and divider </s> remove color: mode(`${c}.600`, `${c}.... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
_icon: {
size: 'xxs',
}, | <mask> _text: {
<mask> fontSize: '2xs',
<mask> },
<mask> },
<mask> };
<mask>
<mask> const defaultProps = {
</s> feat: _icon internal prop and design changes for button and divider </s> remove px: '2',
</s> add px: '3', </s> remove variant: 'solid',
</s> add variant: 'link', | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
variant: 'link', | <mask> },
<mask> };
<mask>
<mask> const defaultProps = {
<mask> variant: 'solid',
<mask> size: 'md',
<mask> colorScheme: 'primary',
<mask> };
<mask>
<mask> export const ButtonGroup = {
</s> feat: _icon internal prop and design changes for button and divider </s> remove
return styleObject;
</s> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/button.ts |
<mask> import { mode } from '../tools';
<mask>
<mask> function baseStyle(props: Record<string, any>) {
<mask> const { orientation, thickness } = props;
<mask> const orientationProps =
<mask> orientation === 'vertical'
<mask> ? {
</s> feat: _icon internal prop and design changes for button and div... | [
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/divider.ts | |
_light: {
bg: 'muted.300',
},
_dark: {
bg: 'muted.600',
}, | <mask> height: `${thickness}px`,
<mask> };
<mask>
<mask> return {
<mask> bg: mode('coolGray.200', 'gray.600')(props),
<mask> ...orientationProps,
<mask> };
<mask> }
<mask>
<mask> export default {
</s> feat: _icon internal prop and design changes for button and divider </s> rem... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/12353876a8deeb3b0465277927e664c87872c802 | src/theme/components/divider.ts |
import { useKeyboardBottomInset } from '../../../utils'; | <mask> import { AccessibilityInfo, Platform, SafeAreaView } from 'react-native';
<mask> import Box from '../../primitives/Box';
<mask> import { usePropsResolution } from '../../../hooks';
<mask> import type { IToastContext, IToastInfo, IToast, IToastProps } from './types';
<mask>
<mask> const INSET = 50;
<mask>... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13218c711515acf7f4c7be97d52c38b8ed923273 | src/components/composites/Toast/Toast.tsx |
const bottomInset = useKeyboardBottomInset() * 2; | <mask> ToastContext
<mask> );
<mask>
<mask> const getPositions = () => {
<mask> return Object.keys(toastInfo);
<mask> };
<mask>
</s> fix: toast keyboardavoiding view using bottom inset </s> remove
</s> add import { useKeyboardBottomInset } from '../../../utils'; </s> remove ... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13218c711515acf7f4c7be97d52c38b8ed923273 | src/components/composites/Toast/Toast.tsx |
<SafeAreaView>
<Box
bottom={
['bottom', 'bottom-left', 'bottom-right'].includes(
position
)
? bottomInset + 'px'
: und... | <mask> opacity: 0,
<mask> translateY: transitionConfig[position],
<mask> }}
<mask> >
<mask> <SafeAreaView>{toast.component}</SafeAreaView>
<mask> </PresenceTransition>
<mask> ))... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13218c711515acf7f4c7be97d52c38b8ed923273 | src/components/composites/Toast/Toast.tsx |
pointerEvents={'box-none'} | <mask> accessibilityModal={isModal}
<mask> // @ts-ignore
<mask> accessibilityRole={isModal ? 'dialog' : undefined}
<mask> style={[overlayStyle.wrapper, { opacity: fadeValue }]}
<mask> pointerEvents={
<mask> overlayItem
<mask> ? overlayConfig.disableOverlay
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/135c1d9dbc536e15b3be8b685a6d881d337489d1 | src/core/Overlay/Wrapper.tsx |
{isOverlayOpen && !overlayConfig.disableOverlay && (
<TouchableWithoutFeedback
accessibilityLabel="Close Overlay"
onPress={() => {
if (overlayConfig.closeOnPress) {
handleClose();
}
}}
>
<View style={overlayStyle.backgro... | <mask> : 'auto'
<mask> : 'none'
<mask> }
<mask> >
<mask> <TouchableWithoutFeedback
<mask> accessibilityLabel="Close Overlay"
<mask> onPress={() => {
<mask> if (overlayConfig.closeOnPress) {
<mask> handleClose();
<mask> }
<m... | [
"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/135c1d9dbc536e15b3be8b685a6d881d337489d1 | src/core/Overlay/Wrapper.tsx |
pointerEvents="box-none" | <mask> );
<mask> return (
<mask> <Animated.View
<mask> style={[providerStyle.wrapper, { opacity: fadeValue }]}
<mask> pointerEvents={popoverItem ? 'auto' : 'none'}
<mask> >
<mask> <TouchableWithoutFeedback
<mask> onPress={() => {
<mask> setPopoverItem(null);
<ma... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/135c1d9dbc536e15b3be8b685a6d881d337489d1 | src/core/Popover/Wrapper.tsx |
{popoverItem && (
<TouchableWithoutFeedback
onPress={() => {
setPopoverItem(null);
popoverConfig.onClose && popoverConfig.onClose();
}}
>
<View style={providerStyle.wrapper} />
</TouchableWithoutFeedback>
)} | <mask> <Animated.View
<mask> style={[providerStyle.wrapper, { opacity: fadeValue }]}
<mask> pointerEvents={popoverItem ? 'auto' : 'none'}
<mask> >
<mask> <TouchableWithoutFeedback
<mask> onPress={() => {
<mask> setPopoverItem(null);
<mask> popoverConfig.onCl... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/135c1d9dbc536e15b3be8b685a6d881d337489d1 | src/core/Popover/Wrapper.tsx |
suppressColorAccessibilityWarning: true, | <mask> export default {
<mask> dependencies: {
<mask> 'linear-gradient': require('expo-linear-gradient').LinearGradient,
<mask> },
<mask> suppressAccessibilityWarning: true,
<mask> } as INativebaseConfig;
</s> chore: rename suppress accessibility warning </s> remove suppressAccessibilityWarning?: boo... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | example/nativebase.config.ts |
suppressColorAccessibilityWarning?: boolean; | <mask> };
<mask>
<mask> export interface INativebaseConfig {
<mask> theme?: ITheme;
<mask> suppressAccessibilityWarning?: boolean;
<mask> dependencies?: {
<mask> 'linear-gradient': any;
<mask> };
<mask> }
<mask>
</s> chore: rename suppress accessibility warning </s> remove suppressAccessibili... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | src/core/NativeBaseContext.ts |
let suppressColorAccessibilityWarning = useNativeBaseConfig( | <mask> bg,
<mask> color ?? '',
<mask> ]);
<mask>
<mask> let suppressAccessibilityWarning = useNativeBaseConfig(
<mask> 'NativeBaseConfigProvider'
<mask> ).config.suppressAccessibilityWarning;
<mask>
<mask> let [accessibleColors] = useAccessibleColors();
<mask>
</s> chore: rename suppre... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | src/hooks/useContrastText.ts |
).config.suppressColorAccessibilityWarning; | <mask> ]);
<mask>
<mask> let suppressAccessibilityWarning = useNativeBaseConfig(
<mask> 'NativeBaseConfigProvider'
<mask> ).config.suppressAccessibilityWarning;
<mask>
<mask> let [accessibleColors] = useAccessibleColors();
<mask>
<mask> if (typeof bg !== 'string') {
<mask> return;
</s> c... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | src/hooks/useContrastText.ts |
suppressColorAccessibilityWarning | <mask> trueBg,
<mask> trueColor,
<mask> bg,
<mask> color,
<mask> suppressAccessibilityWarning
<mask> );
<mask>
<mask> return textColor;
<mask> }
<mask>
</s> chore: rename suppress accessibility warning </s> remove if (contrast < 3 && !suppress... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | src/hooks/useContrastText.ts |
suppressColorAccessibilityWarning?: boolean | <mask> trueBg: string,
<mask> trueColor: string,
<mask> bg: string,
<mask> color?: string,
<mask> suppressAccessibilityWarning?: boolean
<mask> ) {
<mask> if (typeof trueBg !== 'string') {
<mask> trueBg = bg;
<mask> }
<mask> let trueContrastColor;
</s> chore: rename suppress accessibility... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | src/hooks/useContrastText.ts |
if (contrast < 3 && !suppressColorAccessibilityWarning) { | <mask> const contrast = getContrastRatio(
<mask> trueBg,
<mask> trueColor ? trueColor : trueContrastColor
<mask> );
<mask> if (contrast < 3 && !suppressAccessibilityWarning) {
<mask> console.warn(
<mask> [
<mask> `NativeBase: The contrast ratio of ${contrast}:1 fo... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13c54ebc0d3a77d168cf6dd3aae7c40cfce93b0f | src/hooks/useContrastText.ts |
import Box from '../../primitives/Box'; | <mask> import React, { memo, forwardRef } from 'react';
<mask> import { Pressable } from '../../primitives/Pressable';
<mask> import Box, { IBoxProps } from '../../primitives/Box';
<mask> import { HStack } from '../../primitives/Stack';
<mask> import Spinner from '../../primitives/Spinner';
<mask> import type { I... | [
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f1d767826b53275c43ffa67d1285fda052b6cb | src/components/composites/Actionsheet/ActionsheetItem.tsx |
<mask> import { Pressable } from '../../primitives/Pressable';
<mask> import Box, { IBoxProps } from '../../primitives/Box';
<mask> import { HStack } from '../../primitives/Stack';
<mask> import Spinner from '../../primitives/Spinner';
<mask> import type { IButtonProps } from '../../primitives/Button';
<mask> imp... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f1d767826b53275c43ffa67d1285fda052b6cb | src/components/composites/Actionsheet/ActionsheetItem.tsx | |
import type { IActionsheetItemProps } from './types'; | <mask> import Spinner from '../../primitives/Spinner';
<mask> import { usePropsResolution } from '../../../hooks';
<mask> import { useHasResponsiveProps } from '../../../hooks/useHasResponsiveProps';
<mask>
<mask> const ActionsheetItem = (
<mask> {
<mask> //@ts-ignore
<mask> children,
</s> fix: acti... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f1d767826b53275c43ffa67d1285fda052b6cb | src/components/composites/Actionsheet/ActionsheetItem.tsx |
}: IActionsheetItemProps, | <mask> isDisabled,
<mask> isLoading,
<mask> spinnerPlacement = 'start',
<mask> ...props
<mask> }: IButtonProps & IBoxProps,
<mask> ref: any
<mask> ) => {
<mask> const {
<mask> _text,
<mask> _stack,
</s> fix: actionsheet item typing fix </s> remove export interface IActionsheetIt... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f1d767826b53275c43ffa67d1285fda052b6cb | src/components/composites/Actionsheet/ActionsheetItem.tsx |
export interface IActionsheetItemProps
extends Omit<InterfaceButtonProps, 'variant' | 'size' | 'colorScheme'> {} | <mask> export interface IActionsheetFooterProps
<mask> extends InterfaceBoxProps<IActionsheetFooterProps> {}
<mask> export interface IActionsheetHeaderProps
<mask> extends InterfaceBoxProps<IActionsheetHeaderProps> {}
<mask> export interface IActionsheetItemProps extends InterfaceButtonProps {}
<mask>
<mask... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f1d767826b53275c43ffa67d1285fda052b6cb | src/components/composites/Actionsheet/types.tsx |
const { getResponsiveStyles } = useResponsiveQuery(); | <mask> 'makeStyledComponent'
<mask> );
<mask> const strictMode = config.strictMode;
<mask>
<mask> const { getResponsiveStyles } = useResponsiveQuery({
<mask> disableCSSMediaQueries: true,
<mask> });
<mask>
<mask> const { styledSystemProps, restProps } = getStyledSystemPropsAndRestProps(
<m... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/hooks/useStyledSystemPropsResolver.ts |
if (queries.query) {
queries.query.forEach((queryRule) => {
if (queryRule.style) {
const flattenQueryStyle = StyleSheet.flatten(queryRule.style); | <mask> .initial,
<mask> ]
<mask> : [];
<mask>
<mask> queries.query.forEach((queryRule) => {
<mask> if (queryRule.style) {
<mask> const flattenQueryStyle = StyleSheet.flatten(queryRule.style);
<mask>
<mask> if (
<mask> typeof queryRule.maxWidth ==... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/common.ts |
if (
typeof queryRule.maxWidth === 'number' &&
typeof queryRule.minWidth === 'number'
) {
if (width >= queryRule.minWidth && width <= queryRule.maxWidth) {
styles.push(
StyleSheet.create({ rangeStyle: flattenQueryStyle }).rangeStyle
... | <mask> queries.query.forEach((queryRule) => {
<mask> if (queryRule.style) {
<mask> const flattenQueryStyle = StyleSheet.flatten(queryRule.style);
<mask>
<mask> if (
<mask> typeof queryRule.maxWidth === 'number' &&
<mask> typeof queryRule.minWidth === 'number'
<mask... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"re... | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/common.ts |
});
return { styles };
} | <mask> .maxWidthStyle
<mask> );
<mask> }
<mask> }
<mask> }
<mask> });
<mask> return { styles };
<mask> }
<mask>
<mask> return {};
<mask> };
<mask>
</s> feat: media query disable using isSSR </s> remove }
});
</s> add });
} </s> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/common.ts |
query?: Query[]; | <mask> };
<mask>
<mask> export type UseResponsiveQueryParams = {
<mask> initial?: StyleSheetStyle | StyleSheetStyle[];
<mask> query: Query[];
<mask> disableCSSMediaQueries?: boolean;
<mask> };
<mask>
<mask> export type DataSet = { [key: string]: string };
<mask>
</s> feat: media query disable using ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/types.ts |
export type GetResponsiveStylesParams = Omit<
UseResponsiveQueryParams,
'disableCSSMediaQueries'
>; | <mask> };
<mask>
<mask> export type DataSet = { [key: string]: string };
<mask>
<mask> export type GetResponsiveStylesParams = UseResponsiveQueryParams;
<mask>
<mask> export type GetResponsiveStylesReturnType = {
<mask> styles?: StyleSheetStyle[];
<mask> dataSet?: DataSet;
<mask> };
</s> feat: media q... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/types.ts |
if (queries.query) {
queries.query.forEach((queryRule) => {
const queryHash = queriesHash + hash(stableHash(queryRule));
const dataAttribute = getDataAttribute(queryRule);
if (dataAttribute) {
const newIdentifier = `[data-${dataAttribute}$="${queryHash}"]`;
dataSet[dataAttribute... | <mask> : undefined;
<mask>
<mask> let dataSet: DataSet = {};
<mask>
<mask> queries.query.forEach((queryRule) => {
<mask> const queryHash = queriesHash + hash(stableHash(queryRule));
<mask> const dataAttribute = getDataAttribute(queryRule);
<mask>
<mask> if (dataAttribute) {
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/useResponsiveQuery.web.ts |
if (mediaRules) {
const mediaQueryRule = getMediaQueryRule(queryRule, mediaRules); | <mask> const flattenQueryStyle = StyleSheet.flatten(queryRule.style);
<mask> const newStyle = createCompileableStyle(i18nStyle(flattenQueryStyle));
<mask> const results = atomic(newStyle);
<mask>
<mask> Object.keys(results).forEach((key) => {
<mask> const oldIdentifier = results[k... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/useResponsiveQuery.web.ts |
// Here by prepending the /*${queryHash}{}*/ comment, we're kind of tricking the regex used by rn-web to verify if a rule is inserted or not.
// Looks safe to me, just need to keep a check if there are any implementation changes in createStyleSheet file in rn-web in future.
// Second argum... | <mask>
<mask> Object.keys(results).forEach((key) => {
<mask> const oldIdentifier = results[key].identifier;
<mask>
<mask> if (process.env.NODE_ENV !== 'production') {
<mask> dataSet[dataAttribute] = oldIdentifier + ' ' + dataSet[dataAttribute];
<mask> }
<mask>
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/useResponsiveQuery.web.ts |
<mask>
<mask> if (process.env.NODE_ENV !== 'production') {
<mask> dataSet[dataAttribute] = oldIdentifier + ' ' + dataSet[dataAttribute];
<mask> }
<mask>
<mask> results[key].rules.forEach((oldRule: string) => {
<mask> // Rule returned by atomic has css selectors, so w... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"k... | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/useResponsiveQuery.web.ts | |
});
} | <mask> `/*${queryHash}{}*/${mediaQueryRule}`,
<mask> MEDIA_QUERY_STYLESHEET_GROUP
<mask> );
<mask> }
<mask> }
<mask> });
<mask>
<mask> return { styles, dataSet };
<mask> };
</s> feat: media query disable using isSSR </s> remove
results[key].rules.forEach((ol... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/13f9cfc1079b4778ec56e57f29116275e54ca4ad | src/utils/useResponsiveQuery/useResponsiveQuery.web.ts |
<mask> colorModeProps: any,
<mask> componentTheme: any,
<mask> currentBreakpoint: number
<mask> ) {
<mask> // TODO: This function needs a lot of comments
<mask> let newProps: any = {};
<mask> for (let property in props) {
<mask> // If the property exists in theme map then get its value
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts | |
// If the property exists in themePropertyMap then get its value | <mask> ) {
<mask> // TODO: This function needs a lot of comments
<mask> let newProps: any = {};
<mask> for (let property in props) {
<mask> // If the property exists in theme map then get its value
<mask> if (themePropertyMap[property]) {
<mask> // TODO: Need some documentation
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
<mask> let newProps: any = {};
<mask> for (let property in props) {
<mask> // If the property exists in theme map then get its value
<mask> if (themePropertyMap[property]) {
<mask> // TODO: Need some documentation
<mask> let propValues = extractPropertyFromFunction(
<mask> propert... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts | |
/**
* If property is functional in componentTheme, get its returned object
*
* @param property : name of the prop
* @param props : all props
* @param theme : provided theme without components
* @param componentTheme : component specific theme
* @returns
*/ | <mask> let [, resultProps] = extractInObject(defaultProps, Object.keys(props));
<mask> return resultProps;
<mask> }
<mask>
<mask> /*
<mask> If property is functional in componentTheme, get its returned object
<mask> */
<mask> const extractPropertyFromFunction = (
<mask> property: string,
<mask> props... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
// Check if the entry in the theme is a function then calling it with all theme and props as params | <mask> theme: any,
<mask> componentTheme: any
<mask> ) => {
<mask> let propValues;
<mask> if (
<mask> componentTheme &&
<mask> typeof componentTheme[themePropertyMap[property]] === 'function'
<mask> ) {
<mask> let funcProps = componentTheme[themePropertyMap[property]]({
<mask> them... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
// If the returned value is nested object then find the property value in it, otherwise return the whole object | <mask> let isNested: boolean = Object.keys(funcProps).some(function (key) {
<mask> return funcProps[key] && typeof funcProps[key] === 'object';
<mask> });
<mask> propValues = isNested
<mask> ? { ...get(funcProps, `${props[property]}`) }
<mask> : { ...funcProps };
<mask> } else {
... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
// If the entry is any value other than function then return the whole object or value | <mask> : { ...funcProps };
<mask> } else {
<mask> propValues = get(
<mask> componentTheme,
<mask> `${themePropertyMap[property]}.${props[property]}`
<mask> );
<mask> }
</s> chore: added docs in comments for use-theme-props </s> remove console.log('propValues &*&', propValues);
<... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
<mask> componentTheme,
<mask> `${themePropertyMap[property]}.${props[property]}`
<mask> );
<mask> }
<mask> console.log('propValues &*&', propValues);
<mask> return propValues;
<mask> };
<mask>
<mask> /*
<mask> Merge _props and apply contrastText color if not passed by theme or user
</s... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts | |
/**
*
* Checks the property and resolves it if it has breakpoints
* @param values : value from props
* @param currentBreakpoint : current value for which breakpoint will be calculated
* @param property : property name
* @returns
*/ | <mask> });
<mask> return newProps;
<mask> }
<mask>
<mask> /*
<mask> Checks the property and resolves it if it has breakpoints
<mask> */
<mask> const resolveValueWithBreakpoint = (
<mask> values: any,
<mask> currentBreakpoint: number,
<mask> property: any
<mask> ) => {
</s> chore: added docs in c... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
// Check the last valid breakpoint value from all values
// If current breakpoint is `md` and we have `base` then `lg`, then last value will be taken(`base` in this case) | <mask> ) => {
<mask> if (hasValidBreakpointFormat(values, property)) {
<mask> return findLastValidBreakpoint(values, currentBreakpoint);
<mask> } else {
<mask> return values;
<mask> }
<mask> };
</s> chore: added docs in comments for use-theme-props </s> remove /*
Checks the property and resolves i... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/143c6f305c2afb82dcf2bfbdd751f86970f227be | src/hooks/useThemeProps/utils.ts |
React.useEffect(() => {
if (value !== undefined && value != numberInputValue)
setNumberInputValue(value);
}, [value, numberInputValue, setNumberInputValue]); | <mask> setNumberInputValue(temp);
<mask> };
<mask> return (
<mask> <NumberInputContext.Provider
<mask> value={{
<mask> ...formControlContext,
<mask> ...newProps,
</s> fix: added controlled value support </s> remove if (value) handleChangeWithoutCheck && handleChangeWithoutC... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1500af548b9bcec48032448f29df9ef614e0ca39 | src/components/composites/NumberInput/NumberInput.tsx |
isControlled: value !== undefined, | <mask> numberInputValue,
<mask> numberInputStepper,
<mask> setNumberInputStepper,
<mask> }}
<mask> >
<mask> {children}
<mask> </NumberInputContext.Provider>
<mask> );
</s> fix: added controlled value support </s> remove if (value) handleChangeWithoutCheck && ha... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1500af548b9bcec48032448f29df9ef614e0ca39 | src/components/composites/NumberInput/NumberInput.tsx |
isControlled, | <mask> handleChange,
<mask> handleChangeWithoutCheck,
<mask> numberInputStepper,
<mask> numberInputValue,
<mask> ...context
<mask> }: INumberInputContext & {
<mask> handleChange?: (value: string | number) => void;
<mask> numberInputStepper?: any;
<mask> } = React.useContext(Numb... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1500af548b9bcec48032448f29df9ef614e0ca39 | src/components/composites/NumberInput/NumberInputField.tsx |
if (isControlled) handleChange && handleChange(value);
else if (value) handleChangeWithoutCheck && handleChangeWithoutCheck(value); | <mask> inputValue = inputValue.replace('-', '');
<mask> inputValue = '-' + inputValue;
<mask> }
<mask> const value = parseInt(inputValue, 10);
<mask> if (value) handleChangeWithoutCheck && handleChangeWithoutCheck(value);
<mask> else handleChangeWithoutCheck && handleChangeWithoutCheck... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1500af548b9bcec48032448f29df9ef614e0ca39 | src/components/composites/NumberInput/NumberInputField.tsx |
<mask> closeOnOverlayClick = false,
<mask> isKeyboardDismissable = true,
<mask> overlayVisible = true,
<mask> backdropVisible = true,
<mask> //@ts-ignore - internal purpose only
<mask> animationPreset = 'fade',
<mask> ...rest
<mask> }: IAlertDialogProps,
<mask> ref: any
<mask> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15939461bd84725194ca5d6d3849a55f19cc5626 | src/components/composites/AlertDialog/AlertDialog.tsx | |
_backdropFade,
_fade,
_slide, | <mask> const {
<mask> contentSize,
<mask> _backdrop,
<mask> _child,
<mask> ...restThemeProps
<mask> } = usePropsResolution('AlertDialog', rest);
<mask>
<mask> const [visible, setVisible] = useControllableState({
<mask> value: isOpen,
<mask> defaultValue: defaultIsOpen,
</s> fix... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15939461bd84725194ca5d6d3849a55f19cc5626 | src/components/composites/AlertDialog/AlertDialog.tsx |
{..._backdropFade} | <mask> entryDuration={200}
<mask> in={visible}
<mask> style={StyleSheet.absoluteFill}
<mask> >
<mask> {overlayVisible && backdropVisible && (
<mask> <Backdrop
<mask> onPress={() => {
</s> fix: added pseudo props for alert-dialog </s> remo... | [
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15939461bd84725194ca5d6d3849a55f19cc5626 | src/components/composites/AlertDialog/AlertDialog.tsx |
<Slide overlay={false} in={visible} duration={200} {..._slide}> | <mask> />
<mask> )}
<mask> </Fade>
<mask> {animationPreset === 'slide' ? (
<mask> <Slide overlay={false} in={visible} duration={200}>
<mask> <FocusScope
<mask> contain={visible}
<mask> autoFocus={visible && !initialFocusRef}... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15939461bd84725194ca5d6d3849a55f19cc5626 | src/components/composites/AlertDialog/AlertDialog.tsx |
{..._fade} | <mask> exitDuration={100}
<mask> entryDuration={200}
<mask> in={visible}
<mask> style={StyleSheet.absoluteFill}
<mask> >
<mask> <FocusScope
<mask> contain={visible}
<mask> autoFocus={visible && !initialFocusRef}
<... | [
"keep",
"keep",
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15939461bd84725194ca5d6d3849a55f19cc5626 | src/components/composites/AlertDialog/AlertDialog.tsx |
import type { IFadeProps, ISlideProps } from '../Transitions'; | <mask> import type { IIconButtonProps } from '../IconButton';
<mask> import type { MutableRefObject } from 'react';
<mask>
<mask> export interface IAlertDialogProps extends IBoxProps {
<mask> /**
<mask> * If true, the AlertDialog will open. Useful for controllable state behaviour
<mask> */
<mask> isO... | [
"keep",
"add",
"keep",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15939461bd84725194ca5d6d3849a55f19cc5626 | src/components/composites/AlertDialog/types.ts |
<mask> import { Platform } from 'react-native';
<mask> import { usePropsResolution } from '../../../hooks/useThemeProps';
<mask> import Box from './../../primitives/Box';
<mask> import type { IDividerProps } from './types';
<mask> import { extractInObject } from '../../../theme/tools';
<mask>
<mask> const Divid... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15b3c361d2d24a7a83e5ac3a5d77cdcacd17c490 | src/components/composites/Divider/index.tsx | |
const { orientation, ...resolvedProps } = usePropsResolution(
'Divider',
props
); | <mask> import type { IDividerProps } from './types';
<mask> import { extractInObject } from '../../../theme/tools';
<mask>
<mask> const Divider = (props: IDividerProps, ref?: any) => {
<mask> const { orientation, ...newProps } = usePropsResolution('Divider', props);
<mask> const [, remainingProps] = extractI... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15b3c361d2d24a7a83e5ac3a5d77cdcacd17c490 | src/components/composites/Divider/index.tsx |
{...resolvedProps} | <mask> const { orientation, ...newProps } = usePropsResolution('Divider', props);
<mask> const [, remainingProps] = extractInObject(newProps, ['size']);
<mask> return (
<mask> <Box
<mask> {...remainingProps}
<mask> ref={ref}
<mask> aria-orientation={orientation}
<mask> //@ts-ig... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/15b3c361d2d24a7a83e5ac3a5d77cdcacd17c490 | src/components/composites/Divider/index.tsx |
startIcon={<Icon name="menu" size={6} type="MaterialIcons" />} | <mask> export default function () {
<mask> return (
<mask> <HStack space={2}>
<mask> <Button
<mask> leftIcon={<Icon name="menu" size={6} type="MaterialIcons" />}
<mask> colorScheme="blue"
<mask> >
<mask> Menu
<mask> </Button>
<mask> <Button
</s> Fixes for... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | example/storybook/stories/components/primitives/Button/icons.tsx |
endIcon={<Icon name="menu" size={6} type="MaterialIcons" />} | <mask> Menu
<mask> </Button>
<mask> <Button
<mask> isDisabled
<mask> rightIcon={<Icon name="menu" size={6} type="MaterialIcons" />}
<mask> colorScheme="cyan"
<mask> >
<mask> Menu
<mask> </Button>
<mask> </HStack>
</s> Fixes for Icon button a... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | example/storybook/stories/components/primitives/Button/icons.tsx |
import Button from '../../primitives/Button';
import { HStack } from '../../primitives/Stack'; | <mask> import React from 'react';
<mask> import { omitUndefined } from '../../../theme/tools/utils';
<mask> import IconButton from '../IconButton';
<mask> import type { IFabProps } from './types';
<mask>
<mask> const Fab = (props: IFabProps) => {
<mask> const { placement, ...newProps } = omitUndefined(props);... | [
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/Fab/Fab.tsx |
const { label, icon, placement, ...newProps } = omitUndefined(props); | <mask> import IconButton from '../IconButton';
<mask> import type { IFabProps } from './types';
<mask>
<mask> const Fab = (props: IFabProps) => {
<mask> const { placement, ...newProps } = omitUndefined(props);
<mask>
<mask> const placementProps: any = {
<mask> topRight: { top: 4, right: 4, position: '... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/Fab/Fab.tsx |
<Button | <mask> bottomRight: { bottom: 4, right: 4, position: 'absolute' },
<mask> bottomLeft: { bottom: 4, left: 4, position: 'absolute' },
<mask> };
<mask> return (
<mask> <IconButton
<mask> variant="unstyled"
<mask> bg="default.200"
<mask> rounded="full"
<mask> zIndex={20}
<m... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/Fab/Fab.tsx |
>
{icon && label ? (
<HStack space={1} justifyContent="center" alignItems="center">
{icon}
{label}
</HStack>
) : (
icon ?? label
)}
</Button> | <mask> zIndex={20}
<mask> p={2}
<mask> {...placementProps[placement]}
<mask> {...newProps}
<mask> />
<mask> );
<mask> };
<mask>
<mask> export default React.memo(Fab);
</s> Fixes for Icon button and changes for Button icon props </s> remove <IconButton
</s> add <Button <... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/Fab/Fab.tsx |
<mask> export { default as Fab } from './Fab';
<mask> // export { default as FabList } from './FabList';
<mask> // export { default as FabItem } from './FabItem';
<mask> export type { IFabProps } from './types';
</s> Fixes for Icon button and changes for Button icon props </s> remove import IconButton from '../Ico... | [
"keep",
"replace",
"replace",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/Fab/index.tsx | |
<mask>
<mask> export type IFabProps = IIconButtonProps & {
<mask> placement?: 'topRight' | 'topLeft' | 'bottomRight' | 'bottomLeft';
<mask> };
<mask> // export type IFabListProps = IBoxProps;
<mask> // export type IFabItemProps = IButtonProps;
</s> Fixes for Icon button and changes for Button icon props </s> ... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/Fab/types.tsx | |
<mask> import React, { forwardRef } from 'react';
<mask> import type { TouchableHighlight, TouchableOpacity } from 'react-native';
<mask> import { Platform } from 'react-native';
<mask> import { useThemeProps } from '../../../hooks';
<mask> import { Button, HStack, IButtonProps } from '../../primitives';
<mask>
... | [
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/IconButton/index.tsx | |
import Button, { IButtonProps } from '../../primitives/Button'; | <mask> import React, { forwardRef } from 'react';
<mask> import type { TouchableHighlight, TouchableOpacity } from 'react-native';
<mask> import { Platform } from 'react-native';
<mask> import { useThemeProps } from '../../../hooks';
<mask> import { Button, HStack, IButtonProps } from '../../primitives';
<mask>
... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/IconButton/index.tsx |
export type IIconButtonProps = Omit<IButtonProps, '_text'> & {
icon: JSX.Element; | <mask> import { Platform } from 'react-native';
<mask> import { useThemeProps } from '../../../hooks';
<mask> import { Button, HStack, IButtonProps } from '../../primitives';
<mask>
<mask> export type IIconButtonProps = IButtonProps & {
<mask> icon?: JSX.Element;
<mask> label?: JSX.Element;
<mask> };
<mas... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/IconButton/index.tsx |
const IconButton = ({ icon, ...props }: IIconButtonProps, ref: any) => { | <mask> icon?: JSX.Element;
<mask> label?: JSX.Element;
<mask> };
<mask>
<mask> const IconButton = ({ icon, label, ...props }: IIconButtonProps, ref: any) => {
<mask> const newProps = useThemeProps('IconButton', props);
<mask> return (
<mask> <Button ref={ref} {...newProps}>
<mask> {icon && l... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/IconButton/index.tsx |
{icon} | <mask> const IconButton = ({ icon, label, ...props }: IIconButtonProps, ref: any) => {
<mask> const newProps = useThemeProps('IconButton', props);
<mask> return (
<mask> <Button ref={ref} {...newProps}>
<mask> {icon && label ? (
<mask> <HStack
<mask> // NOTE: Don't know why but it... | [
"keep",
"keep",
"keep",
"keep",
"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/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/composites/IconButton/index.tsx |
startIcon,
endIcon, | <mask> highlight,
<mask> isLoading,
<mask> isLoadingText,
<mask> size,
<mask> leftIcon,
<mask> rightIcon,
<mask> spinner,
<mask> ...props
<mask> }: IButtonProps & IBoxProps,
<mask> ref: any
<mask> ) => {
</s> Fixes for Icon button and changes for Button icon props </s> re... | [
"keep",
"keep",
"keep",
"keep",
"replace",
"replace",
"keep",
"keep",
"keep",
"keep",
"keep"
] | https://github.com/GeekyAnts/NativeBase/commit/1706397fb9f7c3102ee33c4bf02dbae44f5c4815 | src/components/primitives/Button/index.tsx |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.