{"ast":null,"code":"import _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nconst _excluded = [\"status\", \"disabled\", \"onPress\", \"theme\", \"testID\"];\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 StyleSheet from \"react-native-web/dist/exports/StyleSheet\";\nimport View from \"react-native-web/dist/exports/View\";\nimport { getSelectionControlIOSColor } from \"./utils\";\nimport { useInternalTheme } from \"../../core/theming\";\nimport MaterialCommunityIcon from \"../MaterialCommunityIcon\";\nimport TouchableRipple from \"../TouchableRipple/TouchableRipple\";\nconst CheckboxIOS = _ref => {\n  let {\n      status,\n      disabled,\n      onPress,\n      theme: themeOverrides,\n      testID\n    } = _ref,\n    rest = _objectWithoutPropertiesLoose(_ref, _excluded);\n  const theme = useInternalTheme(themeOverrides);\n  const checked = status === 'checked';\n  const indeterminate = status === 'indeterminate';\n  const {\n    checkedColor,\n    rippleColor\n  } = getSelectionControlIOSColor({\n    theme,\n    disabled,\n    customColor: rest.color\n  });\n  const icon = indeterminate ? 'minus' : 'check';\n  const opacity = indeterminate || checked ? 1 : 0;\n  return React.createElement(TouchableRipple, _extends({}, rest, {\n    borderless: true,\n    rippleColor: rippleColor,\n    onPress: onPress,\n    disabled: disabled,\n    accessibilityRole: \"checkbox\",\n    accessibilityState: {\n      disabled,\n      checked\n    },\n    accessibilityLiveRegion: \"polite\",\n    style: styles.container,\n    testID: testID,\n    theme: theme\n  }), React.createElement(View, {\n    style: {\n      opacity\n    }\n  }, React.createElement(MaterialCommunityIcon, {\n    allowFontScaling: false,\n    name: icon,\n    size: 24,\n    color: checkedColor,\n    direction: \"ltr\"\n  })));\n};\nCheckboxIOS.displayName = 'Checkbox.IOS';\nconst styles = StyleSheet.create({\n  container: {\n    borderRadius: 18,\n    padding: 6\n  }\n});\nexport default CheckboxIOS;\nexport { CheckboxIOS };","map":{"version":3,"names":["React","StyleSheet","View","getSelectionControlIOSColor","useInternalTheme","MaterialCommunityIcon","TouchableRipple","CheckboxIOS","_ref","status","disabled","onPress","theme","themeOverrides","testID","rest","_objectWithoutPropertiesLoose","_excluded","checked","indeterminate","checkedColor","rippleColor","customColor","color","icon","opacity","createElement","_extends","borderless","accessibilityRole","accessibilityState","accessibilityLiveRegion","style","styles","container","allowFontScaling","name","size","direction","displayName","create","borderRadius","padding"],"sources":["/Users/pmouli/Documents/GitHub.nosync/boots-strapper/mobile/node_modules/react-native-paper/src/components/Checkbox/CheckboxIOS.tsx"],"sourcesContent":["import * as React from 'react';\nimport { GestureResponderEvent, StyleSheet, View } from 'react-native';\n\nimport { getSelectionControlIOSColor } from './utils';\nimport { useInternalTheme } from '../../core/theming';\nimport type { $RemoveChildren, ThemeProp } from '../../types';\nimport MaterialCommunityIcon from '../MaterialCommunityIcon';\nimport TouchableRipple from '../TouchableRipple/TouchableRipple';\n\nexport type Props = $RemoveChildren<typeof TouchableRipple> & {\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 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 * This component follows platform guidelines for iOS, but can be used\n * on any platform.\n *\n * @extends TouchableRipple props https://callstack.github.io/react-native-paper/docs/components/TouchableRipple\n */\nconst CheckboxIOS = ({\n  status,\n  disabled,\n  onPress,\n  theme: themeOverrides,\n  testID,\n  ...rest\n}: Props) => {\n  const theme = useInternalTheme(themeOverrides);\n  const checked = status === 'checked';\n  const indeterminate = status === 'indeterminate';\n\n  const { checkedColor, rippleColor } = getSelectionControlIOSColor({\n    theme,\n    disabled,\n    customColor: rest.color,\n  });\n\n  const icon = indeterminate ? 'minus' : 'check';\n  const opacity = indeterminate || checked ? 1 : 0;\n\n  return (\n    <TouchableRipple\n      {...rest}\n      borderless\n      rippleColor={rippleColor}\n      onPress={onPress}\n      disabled={disabled}\n      accessibilityRole=\"checkbox\"\n      accessibilityState={{ disabled, checked }}\n      accessibilityLiveRegion=\"polite\"\n      style={styles.container}\n      testID={testID}\n      theme={theme}\n    >\n      <View style={{ opacity }}>\n        <MaterialCommunityIcon\n          allowFontScaling={false}\n          name={icon}\n          size={24}\n          color={checkedColor}\n          direction=\"ltr\"\n        />\n      </View>\n    </TouchableRipple>\n  );\n};\n\nCheckboxIOS.displayName = 'Checkbox.IOS';\n\nconst styles = StyleSheet.create({\n  container: {\n    borderRadius: 18,\n    padding: 6,\n  },\n});\n\nexport default CheckboxIOS;\n\n// @component-docs ignore-next-line\nexport { CheckboxIOS };\n"],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAAA,OAAAC,UAAA;AAAA,OAAAC,IAAA;AAG9B,SAASC,2BAA2B;AACpC,SAASC,gBAAgB;AAEzB,OAAOC,qBAAqB;AAC5B,OAAOC,eAAe;AAoCtB,MAAMC,WAAW,GAAGC,IAAA,IAOP;EAAA,IAPQ;MACnBC,MAAM;MACNC,QAAQ;MACRC,OAAO;MACPC,KAAK,EAAEC,cAAc;MACrBC;IAEK,CAAC,GAAAN,IAAA;IADHO,IAAA,GAAAC,6BAAA,CAAAR,IAAA,EAAAS,SAAA;EAEH,MAAML,KAAK,GAAGR,gBAAgB,CAACS,cAAc,CAAC;EAC9C,MAAMK,OAAO,GAAGT,MAAM,KAAK,SAAS;EACpC,MAAMU,aAAa,GAAGV,MAAM,KAAK,eAAe;EAEhD,MAAM;IAAEW,YAAY;IAAEC;EAAY,CAAC,GAAGlB,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