ef17b341b14939c2ec439b6184c2fcaf.json 10.2 KB
{"ast":null,"code":"var _interopRequireDefault=require(\"@babel/runtime/helpers/interopRequireDefault\");Object.defineProperty(exports,\"__esModule\",{value:true});exports.addWhitelistedNativeProps=addWhitelistedNativeProps;exports.addWhitelistedUIProps=addWhitelistedUIProps;var _defineProperty2=_interopRequireDefault(require(\"@babel/runtime/helpers/defineProperty\"));var _ReanimatedModule=_interopRequireDefault(require(\"./ReanimatedModule\"));function ownKeys(object,enumerableOnly){var keys=Object.keys(object);if(Object.getOwnPropertySymbols){var symbols=Object.getOwnPropertySymbols(object);if(enumerableOnly)symbols=symbols.filter(function(sym){return Object.getOwnPropertyDescriptor(object,sym).enumerable;});keys.push.apply(keys,symbols);}return keys;}function _objectSpread(target){for(var i=1;i<arguments.length;i++){var source=arguments[i]!=null?arguments[i]:{};if(i%2){ownKeys(source,true).forEach(function(key){(0,_defineProperty2.default)(target,key,source[key]);});}else if(Object.getOwnPropertyDescriptors){Object.defineProperties(target,Object.getOwnPropertyDescriptors(source));}else{ownKeys(source).forEach(function(key){Object.defineProperty(target,key,Object.getOwnPropertyDescriptor(source,key));});}}return target;}var UI_THREAD_PROPS_WHITELIST={opacity:true,transform:true,backgroundColor:true,borderRightColor:true,borderBottomColor:true,borderColor:true,borderEndColor:true,borderLeftColor:true,borderStartColor:true,borderTopColor:true,shadowOpacity:true,shadowRadius:true,scaleX:true,scaleY:true,translateX:true,translateY:true};var NATIVE_THREAD_PROPS_WHITELIST={borderBottomWidth:true,borderEndWidth:true,borderLeftWidth:true,borderRightWidth:true,borderStartWidth:true,borderTopWidth:true,borderWidth:true,bottom:true,flex:true,flexGrow:true,flexShrink:true,height:true,left:true,margin:true,marginBottom:true,marginEnd:true,marginHorizontal:true,marginLeft:true,marginRight:true,marginStart:true,marginTop:true,marginVertical:true,maxHeight:true,maxWidth:true,minHeight:true,minWidth:true,padding:true,paddingBottom:true,paddingEnd:true,paddingHorizontal:true,paddingLeft:true,paddingRight:true,paddingStart:true,paddingTop:true,paddingVertical:true,right:true,start:true,top:true,width:true,zIndex:true,borderBottomEndRadius:true,borderBottomLeftRadius:true,borderBottomRightRadius:true,borderBottomStartRadius:true,borderRadius:true,borderTopEndRadius:true,borderTopLeftRadius:true,borderTopRightRadius:true,borderTopStartRadius:true,opacity:true,elevation:true,fontSize:true,lineHeight:true,textShadowRadius:true,letterSpacing:true,display:true,backfaceVisibility:true,overflow:true,resizeMode:true,fontStyle:true,fontWeight:true,textAlign:true,textDecorationLine:true,fontFamily:true,textAlignVertical:true,fontVariant:true,textDecorationStyle:true,textTransform:true,writingDirection:true,color:true};function configureProps(){_ReanimatedModule.default.configureProps(Object.keys(NATIVE_THREAD_PROPS_WHITELIST),Object.keys(UI_THREAD_PROPS_WHITELIST));}function addWhitelistedNativeProps(props){NATIVE_THREAD_PROPS_WHITELIST=_objectSpread({},NATIVE_THREAD_PROPS_WHITELIST,{},props);configureProps();}function addWhitelistedUIProps(props){UI_THREAD_PROPS_WHITELIST=_objectSpread({},UI_THREAD_PROPS_WHITELIST,{},props);configureProps();}configureProps();","map":{"version":3,"sources":["C:/Users/bluej/Desktop/2_2/searchGuide/searchGuide/node_modules/react-native-reanimated/src/ConfigHelper.js"],"names":["UI_THREAD_PROPS_WHITELIST","opacity","transform","backgroundColor","borderRightColor","borderBottomColor","borderColor","borderEndColor","borderLeftColor","borderStartColor","borderTopColor","shadowOpacity","shadowRadius","scaleX","scaleY","translateX","translateY","NATIVE_THREAD_PROPS_WHITELIST","borderBottomWidth","borderEndWidth","borderLeftWidth","borderRightWidth","borderStartWidth","borderTopWidth","borderWidth","bottom","flex","flexGrow","flexShrink","height","left","margin","marginBottom","marginEnd","marginHorizontal","marginLeft","marginRight","marginStart","marginTop","marginVertical","maxHeight","maxWidth","minHeight","minWidth","padding","paddingBottom","paddingEnd","paddingHorizontal","paddingLeft","paddingRight","paddingStart","paddingTop","paddingVertical","right","start","top","width","zIndex","borderBottomEndRadius","borderBottomLeftRadius","borderBottomRightRadius","borderBottomStartRadius","borderRadius","borderTopEndRadius","borderTopLeftRadius","borderTopRightRadius","borderTopStartRadius","elevation","fontSize","lineHeight","textShadowRadius","letterSpacing","display","backfaceVisibility","overflow","resizeMode","fontStyle","fontWeight","textAlign","textDecorationLine","fontFamily","textAlignVertical","fontVariant","textDecorationStyle","textTransform","writingDirection","color","configureProps","ReanimatedModule","Object","keys","addWhitelistedNativeProps","props","addWhitelistedUIProps"],"mappings":"0VAAA,4E,yxBAKA,GAAIA,CAAAA,yBAAyB,CAAG,CAC9BC,OAAO,CAAE,IADqB,CAE9BC,SAAS,CAAE,IAFmB,CAI9BC,eAAe,CAAE,IAJa,CAK9BC,gBAAgB,CAAE,IALY,CAM9BC,iBAAiB,CAAE,IANW,CAO9BC,WAAW,CAAE,IAPiB,CAQ9BC,cAAc,CAAE,IARc,CAS9BC,eAAe,CAAE,IATa,CAU9BC,gBAAgB,CAAE,IAVY,CAW9BC,cAAc,CAAE,IAXc,CAa9BC,aAAa,CAAE,IAbe,CAc9BC,YAAY,CAAE,IAdgB,CAgB9BC,MAAM,CAAE,IAhBsB,CAiB9BC,MAAM,CAAE,IAjBsB,CAkB9BC,UAAU,CAAE,IAlBkB,CAmB9BC,UAAU,CAAE,IAnBkB,CAAhC,CAyBA,GAAIC,CAAAA,6BAA6B,CAAG,CAClCC,iBAAiB,CAAE,IADe,CAElCC,cAAc,CAAE,IAFkB,CAGlCC,eAAe,CAAE,IAHiB,CAIlCC,gBAAgB,CAAE,IAJgB,CAKlCC,gBAAgB,CAAE,IALgB,CAMlCC,cAAc,CAAE,IANkB,CAOlCC,WAAW,CAAE,IAPqB,CAQlCC,MAAM,CAAE,IAR0B,CASlCC,IAAI,CAAE,IAT4B,CAUlCC,QAAQ,CAAE,IAVwB,CAWlCC,UAAU,CAAE,IAXsB,CAYlCC,MAAM,CAAE,IAZ0B,CAalCC,IAAI,CAAE,IAb4B,CAclCC,MAAM,CAAE,IAd0B,CAelCC,YAAY,CAAE,IAfoB,C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DyB,CA0DlCC,kBAAkB,CAAE,IA1Dc,CA2DlCC,QAAQ,CAAE,IA3DwB,CA4DlCC,UAAU,CAAE,IA5DsB,CA6DlCC,SAAS,CAAE,IA7DuB,CA8DlCC,UAAU,CAAE,IA9DsB,CA+DlCC,SAAS,CAAE,IA/DuB,CAgElCC,kBAAkB,CAAE,IAhEc,CAiElCC,UAAU,CAAE,IAjEsB,CAkElCC,iBAAiB,CAAE,IAlEe,CAmElCC,WAAW,CAAE,IAnEqB,CAoElCC,mBAAmB,CAAE,IApEa,CAqElCC,aAAa,CAAE,IArEmB,CAsElCC,gBAAgB,CAAE,IAtEgB,CAwElCC,KAAK,CAAE,IAxE2B,CAApC,CA2EA,QAASC,CAAAA,cAAT,EAA0B,CACxBC,0BAAiBD,cAAjB,CACEE,MAAM,CAACC,IAAP,CAAYzE,6BAAZ,CADF,CAEEwE,MAAM,CAACC,IAAP,CAAY1F,yBAAZ,CAFF,EAID,CAEM,QAAS2F,CAAAA,yBAAT,CAAmCC,KAAnC,CAA0C,CAC/C3E,6BAA6B,kBACxBA,6BADwB,IAExB2E,KAFwB,CAA7B,CAIAL,cAAc,GACf,CAEM,QAASM,CAAAA,qBAAT,CAA+BD,KAA/B,CAAsC,CAC3C5F,yBAAyB,kBAAQA,yBAAR,IAAsC4F,KAAtC,CAAzB,CACAL,cAAc,GACf,CAEDA,cAAc","sourcesContent":["import ReanimatedModule from './ReanimatedModule';\n\n/**\n * Styles allowed to be direcly updated in UI thread\n */\nlet UI_THREAD_PROPS_WHITELIST = {\n  opacity: true,\n  transform: true,\n  /* colors */\n  backgroundColor: true,\n  borderRightColor: true,\n  borderBottomColor: true,\n  borderColor: true,\n  borderEndColor: true,\n  borderLeftColor: true,\n  borderStartColor: true,\n  borderTopColor: true,\n  /* ios styles */\n  shadowOpacity: true,\n  shadowRadius: true,\n  /* legacy android transform properties */\n  scaleX: true,\n  scaleY: true,\n  translateX: true,\n  translateY: true,\n};\n\n/**\n * Whitelist of view props that can be updated in native thread via UIManagerModule\n */\nlet NATIVE_THREAD_PROPS_WHITELIST = {\n  borderBottomWidth: true,\n  borderEndWidth: true,\n  borderLeftWidth: true,\n  borderRightWidth: true,\n  borderStartWidth: true,\n  borderTopWidth: true,\n  borderWidth: true,\n  bottom: true,\n  flex: true,\n  flexGrow: true,\n  flexShrink: true,\n  height: true,\n  left: true,\n  margin: true,\n  marginBottom: true,\n  marginEnd: true,\n  marginHorizontal: true,\n  marginLeft: true,\n  marginRight: true,\n  marginStart: true,\n  marginTop: true,\n  marginVertical: true,\n  maxHeight: true,\n  maxWidth: true,\n  minHeight: true,\n  minWidth: true,\n  padding: true,\n  paddingBottom: true,\n  paddingEnd: true,\n  paddingHorizontal: true,\n  paddingLeft: true,\n  paddingRight: true,\n  paddingStart: true,\n  paddingTop: true,\n  paddingVertical: true,\n  right: true,\n  start: true,\n  top: true,\n  width: true,\n  zIndex: true,\n  borderBottomEndRadius: true,\n  borderBottomLeftRadius: true,\n  borderBottomRightRadius: true,\n  borderBottomStartRadius: true,\n  borderRadius: true,\n  borderTopEndRadius: true,\n  borderTopLeftRadius: true,\n  borderTopRightRadius: true,\n  borderTopStartRadius: true,\n  opacity: true,\n  elevation: true,\n  fontSize: true,\n  lineHeight: true,\n  textShadowRadius: true,\n  letterSpacing: true,\n  /* strings */\n  display: true,\n  backfaceVisibility: true,\n  overflow: true,\n  resizeMode: true,\n  fontStyle: true,\n  fontWeight: true,\n  textAlign: true,\n  textDecorationLine: true,\n  fontFamily: true,\n  textAlignVertical: true,\n  fontVariant: true,\n  textDecorationStyle: true,\n  textTransform: true,\n  writingDirection: true,\n  /* text color */\n  color: true,\n};\n\nfunction configureProps() {\n  ReanimatedModule.configureProps(\n    Object.keys(NATIVE_THREAD_PROPS_WHITELIST),\n    Object.keys(UI_THREAD_PROPS_WHITELIST)\n  );\n}\n\nexport function addWhitelistedNativeProps(props) {\n  NATIVE_THREAD_PROPS_WHITELIST = {\n    ...NATIVE_THREAD_PROPS_WHITELIST,\n    ...props,\n  };\n  configureProps();\n}\n\nexport function addWhitelistedUIProps(props) {\n  UI_THREAD_PROPS_WHITELIST = { ...UI_THREAD_PROPS_WHITELIST, ...props };\n  configureProps();\n}\n\nconfigureProps();\n"]},"metadata":{},"sourceType":"script"}