You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1 line
5.0 KiB

{"ast":null,"code":"import _extends from \"@babel/runtime/helpers/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nvar _excluded = [\"children\", \"style\", \"imageStyle\", \"imageRef\"];\nimport * as React from 'react';\nimport { forwardRef } from 'react';\nimport Image from \"../Image\";\nimport StyleSheet from \"../StyleSheet\";\nimport View from \"../View\";\nvar emptyObject = {};\nvar ImageBackground = forwardRef(function (props, forwardedRef) {\n var children = props.children,\n _props$style = props.style,\n style = _props$style === void 0 ? emptyObject : _props$style,\n imageStyle = props.imageStyle,\n imageRef = props.imageRef,\n rest = _objectWithoutPropertiesLoose(props, _excluded);\n var _StyleSheet$flatten = StyleSheet.flatten(style),\n height = _StyleSheet$flatten.height,\n width = _StyleSheet$flatten.width;\n return React.createElement(View, {\n ref: forwardedRef,\n style: style\n }, React.createElement(Image, _extends({}, rest, {\n ref: imageRef,\n style: [{\n width: width,\n height: height,\n zIndex: -1\n }, StyleSheet.absoluteFill, imageStyle]\n })), children);\n});\nImageBackground.displayName = 'ImageBackground';\nexport default ImageBackground;","map":{"version":3,"names":["_extends","_objectWithoutPropertiesLoose","_excluded","React","forwardRef","Image","StyleSheet","View","emptyObject","ImageBackground","props","forwardedRef","children","_props$style","style","imageStyle","imageRef","rest","_StyleSheet$flatten","flatten","height","width","createElement","ref","zIndex","absoluteFill","displayName"],"sources":["/Users/thomaschazot/Documents/But2A/LaSuperMeteo/iut-expo-starter/node_modules/react-native-web/dist/exports/ImageBackground/index.js"],"sourcesContent":["import _extends from \"@babel/runtime/helpers/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/objectWithoutPropertiesLoose\";\nvar _excluded = [\"children\", \"style\", \"imageStyle\", \"imageRef\"];\n\n/**\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n *\n * \n */\nimport * as React from 'react';\nimport { forwardRef } from 'react';\nimport Image from '../Image';\nimport StyleSheet from '../StyleSheet';\nimport View from '../View';\nvar emptyObject = {};\n/**\n * Very simple drop-in replacement for <Image> which supports nesting views.\n */\n\nvar ImageBackground = /*#__PURE__*/forwardRef((props, forwardedRef) => {\n var children = props.children,\n _props$style = props.style,\n style = _props$style === void 0 ? emptyObject : _props$style,\n imageStyle = props.imageStyle,\n imageRef = props.imageRef,\n rest = _objectWithoutPropertiesLoose(props, _excluded);\n\n var _StyleSheet$flatten = StyleSheet.flatten(style),\n height = _StyleSheet$flatten.height,\n width = _StyleSheet$flatten.width;\n\n return /*#__PURE__*/React.createElement(View, {\n ref: forwardedRef,\n style: style\n }, /*#__PURE__*/React.createElement(Image, _extends({}, rest, {\n ref: imageRef,\n style: [{\n // Temporary Workaround:\n // Current (imperfect yet) implementation of <Image> overwrites width and height styles\n // (which is not quite correct), and these styles conflict with explicitly set styles\n // of <ImageBackground> and with our internal layout model here.\n // So, we have to proxy/reapply these styles explicitly for actual <Image> component.\n // This workaround should be removed after implementing proper support of\n // intrinsic content size of the <Image>.\n width,\n height,\n zIndex: -1\n }, StyleSheet.absoluteFill, imageStyle]\n })), children);\n});\nImageBackground.displayName = 'ImageBackground';\nexport default ImageBackground;"],"mappings":"AAAA,OAAOA,QAAQ,MAAM,gCAAgC;AACrD,OAAOC,6BAA6B,MAAM,qDAAqD;AAC/F,IAAIC,SAAS,GAAG,CAAC,UAAU,EAAE,OAAO,EAAE,YAAY,EAAE,UAAU,CAAC;AAU/D,OAAO,KAAKC,KAAK,MAAM,OAAO;AAC9B,SAASC,UAAU,QAAQ,OAAO;AAClC,OAAOC,KAAK;AACZ,OAAOC,UAAU;AACjB,OAAOC,IAAI;AACX,IAAIC,WAAW,GAAG,CAAC,CAAC;AAKpB,IAAIC,eAAe,GAAgBL,UAAU,CAAC,UAACM,KAAK,EAAEC,YAAY,EAAK;EACrE,IAAIC,QAAQ,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