UNPKG

repoweaver

Version:

A GitHub App that skillfully weaves multiple templates together to create and update repositories with intelligent merge strategies

1 lines 4.17 kB
{"ast":null,"code":"import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nconst _excluded = [\"theme\"];\nfunction _extends() {\n return _extends = Object.assign ? Object.assign.bind() : function (n) {\n for (var e = 1; e < arguments.length; e++) {\n var t = arguments[e];\n for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);\n }\n return n;\n }, _extends.apply(null, arguments);\n}\nimport * as React from 'react';\nimport Platform from \"react-native-web/dist/exports/Platform\";\nimport CheckboxAndroid from \"./CheckboxAndroid\";\nimport CheckboxIOS from \"./CheckboxIOS\";\nimport { useInternalTheme } from \"../../core/theming\";\nconst Checkbox = _ref => {\n let {\n theme: themeOverrides\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, _excluded);\n const theme = useInternalTheme(themeOverrides);\n return Platform.OS === 'ios' ? React.createElement(CheckboxIOS, _extends({}, props, {\n theme: theme\n })) : React.createElement(CheckboxAndroid, _extends({}, props, {\n theme: theme\n }));\n};\nexport default Checkbox;\nconst CheckboxWithTheme = Checkbox;\nexport { CheckboxWithTheme as Checkbox };","map":{"version":3,"names":["React","Platform","CheckboxAndroid","CheckboxIOS","useInternalTheme","Checkbox","_ref","theme","themeOverrides","props","_objectWithoutPropertiesLoose","_excluded","OS","createElement","_extends","CheckboxWithTheme"],"sources":["/Users/pmouli/Documents/GitHub.nosync/boots-strapper/mobile/node_modules/react-native-paper/src/components/Checkbox/Checkbox.tsx"],"sourcesContent":["import * as React from 'react';\nimport { GestureResponderEvent, Platform } from 'react-native';\n\nimport CheckboxAndroid from './CheckboxAndroid';\nimport CheckboxIOS from './CheckboxIOS';\nimport { useInternalTheme } from '../../core/theming';\nimport type { ThemeProp } from '../../types';\n\nexport type Props = {\n /**\n * Status of checkbox.\n */\n status: 'checked' | 'unchecked' | 'indeterminate';\n /**\n * Whether checkbox is disabled.\n */\n disabled?: boolean;\n /**\n * Function to execute on press.\n */\n onPress?: (e: GestureResponderEvent) => void;\n /**\n * Custom color for unchecked checkbox.\n */\n uncheckedColor?: string;\n /**\n * Custom color for checkbox.\n */\n color?: string;\n /**\n * @optional\n */\n theme?: ThemeProp;\n /**\n * testID to be used on tests.\n */\n testID?: string;\n};\n\n/**\n * Checkboxes allow the selection of multiple options from a set.\n *\n * ## Usage\n * ```js\n * import * as React from 'react';\n * import { Checkbox } from 'react-native-paper';\n *\n * const MyComponent = () => {\n * const [checked, setChecked] = React.useState(false);\n *\n * return (\n * <Checkbox\n * status={checked ? 'checked' : 'unchecked'}\n * onPress={() => {\n * setChecked(!checked);\n * }}\n * />\n * );\n * };\n *\n * export default MyComponent;\n * ```\n */\nconst Checkbox = ({ theme: themeOverrides, ...props }: Props) => {\n const theme = useInternalTheme(themeOverrides);\n return Platform.OS === 'ios' ? (\n <CheckboxIOS {...props} theme={theme} />\n ) : (\n <CheckboxAndroid {...props} theme={theme} />\n );\n};\n\nexport default Checkbox;\n\n// @component-docs ignore-next-line\nconst CheckboxWithTheme = Checkbox;\n// @component-docs ignore-next-line\nexport { CheckboxWithTheme as Checkbox };\n"],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAAA,OAAAC,QAAA;AAG9B,OAAOC,eAAe;AACtB,OAAOC,WAAW;AAClB,SAASC,gBAAgB;AA0DzB,MAAMC,QAAQ,GAAGC,IAAA,IAAgD;EAAA,IAA/C;MAAEC,KAAK,EAAEC;IAAgC,CAAC,GAAAF,IAAA;IAAdG,KAAA,GAAAC,6BAAA,CAAAJ,IAAA,EAAAK,SAAA;EAC5C,MAAMJ,KAAK,GAAGH,gBAAgB,CAACI,cAAc,CAAC;EAC9C,OAAOP,QAAQ,CAACW,EAAE,KAAK,KAAK,GAC1BZ,KAAA,CAAAa,aAAA,CAACV,WAAW,EAAAW,QAAA,KAAKL,KAAK;IAAEF,KAAK,EAAEA;EAAM,EAAE,CAAC,GAExCP,KAAA,CAAAa,aAAA,CAACX,eAAe,EAAAY,QAAA,KAAKL,KAAK;IAAEF,KAAK,EAAEA;EAAM,EAAE,CAC5C;AACH,CAAC;AAED,eAAeF,QAAQ;AAGvB,MAAMU,iBAAiB,GAAGV,QAAQ;AAElC,SAASU,iBAAiB,IAAIV,QAAQ","ignoreList":[]},"metadata":{"hasCjsExports":false},"sourceType":"module","externalDependencies":[]}