react-native-ui-lib 7.38.1-snapshot.6305 → 7.38.1-snapshot.6307

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-ui-lib",
3
- "version": "7.38.1-snapshot.6305",
3
+ "version": "7.38.1-snapshot.6307",
4
4
  "main": "src/index.js",
5
5
  "types": "src/index.d.ts",
6
6
  "author": "Ethan Sharabi <ethan.shar@gmail.com>",
@@ -162,29 +162,30 @@ declare const Avatar: React.ForwardRefExoticComponent<Pick<AccessibilityProps, "
162
162
  * Image props object
163
163
  */
164
164
  imageProps?: Partial<Omit<import("react-native").ImageProps, "source"> & Pick<import("react-native").ImageBackgroundProps, "imageStyle"> & Partial<Record<"margin" | "marginL" | "marginT" | "marginR" | "marginB" | "marginH" | "marginV", boolean>> & import("../..").RecorderProps & {
165
+ /**
166
+ * Avatar colors to be used when useAutoColors is true
167
+ */
165
168
  sourceTransformer?: ((props: any) => import("../image").ImageSourceType) | undefined;
166
169
  assetName?: string | undefined;
167
170
  assetGroup?: string | undefined;
168
171
  tintColor?: string | undefined;
169
- supportRTL?: boolean | undefined;
172
+ supportRTL?: boolean | undefined; /**
173
+ * Background color for Avatar
174
+ */
170
175
  cover?: boolean | undefined;
171
176
  aspectRatio?: number | undefined;
172
- overlayType?: string | undefined;
177
+ overlayType?: string | undefined; /**
178
+ * Image props object
179
+ */
173
180
  overlayIntensity?: import("../overlay").OverlayIntensityType | undefined;
174
181
  overlayColor?: string | undefined;
175
182
  customOverlayContent?: React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactElement<any, string | React.JSXElementConstructor<any>>[] | undefined;
176
183
  errorSource?: import("../image").ImageSourceType;
177
- imageId?: string | undefined; /**
178
- * Listener-callback for when an image's (uri) loading
179
- * fails (equiv. to Image.onError()).
180
- */
184
+ imageId?: string | undefined;
181
185
  useBackgroundContainer?: boolean | undefined;
182
186
  width?: string | number | undefined;
183
187
  height?: string | number | undefined;
184
- source: import("../image").ImageSourceType; /**
185
- * Hash the name (or label) to get a color, so each name will have a specific color.
186
- * Default is false.
187
- */
188
+ source: import("../image").ImageSourceType;
188
189
  } & AnimatedImageProps> | undefined;
189
190
  /**
190
191
  * Image style object used to pass additional style props
@@ -290,29 +291,30 @@ declare const _default: React.ForwardRefExoticComponent<Pick<AccessibilityProps,
290
291
  * Image props object
291
292
  */
292
293
  imageProps?: Partial<Omit<import("react-native").ImageProps, "source"> & Pick<import("react-native").ImageBackgroundProps, "imageStyle"> & Partial<Record<"margin" | "marginL" | "marginT" | "marginR" | "marginB" | "marginH" | "marginV", boolean>> & import("../..").RecorderProps & {
294
+ /**
295
+ * Avatar colors to be used when useAutoColors is true
296
+ */
293
297
  sourceTransformer?: ((props: any) => import("../image").ImageSourceType) | undefined;
294
298
  assetName?: string | undefined;
295
299
  assetGroup?: string | undefined;
296
300
  tintColor?: string | undefined;
297
- supportRTL?: boolean | undefined;
301
+ supportRTL?: boolean | undefined; /**
302
+ * Background color for Avatar
303
+ */
298
304
  cover?: boolean | undefined;
299
305
  aspectRatio?: number | undefined;
300
- overlayType?: string | undefined;
306
+ overlayType?: string | undefined; /**
307
+ * Image props object
308
+ */
301
309
  overlayIntensity?: import("../overlay").OverlayIntensityType | undefined;
302
310
  overlayColor?: string | undefined;
303
311
  customOverlayContent?: React.ReactElement<any, string | React.JSXElementConstructor<any>> | React.ReactElement<any, string | React.JSXElementConstructor<any>>[] | undefined;
304
312
  errorSource?: import("../image").ImageSourceType;
305
- imageId?: string | undefined; /**
306
- * Listener-callback for when an image's (uri) loading
307
- * fails (equiv. to Image.onError()).
308
- */
313
+ imageId?: string | undefined;
309
314
  useBackgroundContainer?: boolean | undefined;
310
315
  width?: string | number | undefined;
311
316
  height?: string | number | undefined;
312
- source: import("../image").ImageSourceType; /**
313
- * Hash the name (or label) to get a color, so each name will have a specific color.
314
- * Default is false.
315
- */
317
+ source: import("../image").ImageSourceType;
316
318
  } & AnimatedImageProps> | undefined;
317
319
  /**
318
320
  * Image style object used to pass additional style props
@@ -16,6 +16,7 @@ import AnimatedImage from "../animatedImage";
16
16
  import * as AvatarHelper from "../../helpers/AvatarHelper";
17
17
  import { useThemeProps } from "../../hooks";
18
18
  import { isSvg } from "../../utils/imageUtils";
19
+ import Constants from "../../commons/Constants";
19
20
  export let BadgePosition = /*#__PURE__*/function (BadgePosition) {
20
21
  BadgePosition["TOP_RIGHT"] = "TOP_RIGHT";
21
22
  BadgePosition["TOP_LEFT"] = "TOP_LEFT";
@@ -149,7 +150,7 @@ const Avatar = forwardRef((props, ref) => {
149
150
  const renderImage = () => {
150
151
  if (source !== undefined) {
151
152
  // Looks like reanimated does not support SVG
152
- const ImageContainer = animate && !isSvg(source) ? AnimatedImage : Image;
153
+ const ImageContainer = animate && !isSvg(source) && !Constants.isWeb ? AnimatedImage : Image;
153
154
  return <ImageContainer style={_imageStyle} source={source} onLoadStart={onImageLoadStart} onLoadEnd={onImageLoadEnd} onError={onImageLoadError} testID={`${testID}.image`} width={size} height={size} containerStyle={_baseContainerStyle} {...imageProps} />;
154
155
  }
155
156
  };
@@ -156,7 +156,7 @@ class Image extends PureComponent {
156
156
  } = modifiers;
157
157
  return (
158
158
  // @ts-ignore
159
- <ImageView style={[Constants.isWeb && source?.dimensions, tintColor && {
159
+ <ImageView style={[tintColor && {
160
160
  tintColor
161
161
  }, shouldFlipRTL && styles.rtlFlipped, width && {
162
162
  width
@@ -1,27 +0,0 @@
1
- console.log(`inside index.web.js`);
2
- export const icons = {
3
- get check() {
4
- return {uri: require('./check.png'), dimensions: {width: 24, height: 24}};
5
- },
6
- get checkSmall() {
7
- return {uri: require('./check-small.png'), dimensions: {width: 24, height: 24}};
8
- },
9
- get minusSmall() {
10
- return {uri: require('./minusSmall.png'), dimensions: {width: 24, height: 24}};
11
- },
12
- get plusSmall() {
13
- return {uri: require('./plusSmall.png'), dimensions: {width: 24, height: 24}};
14
- },
15
- get search() {
16
- return {uri: require('./search.png'), dimensions: {width: 24, height: 24}};
17
- },
18
- get x() {
19
- return {uri: require('./x.png'), dimensions: {width: 24, height: 24}};
20
- },
21
- get xMedium() {
22
- return {uri: require('./xMedium.png'), dimensions: {width: 24, height: 24}};
23
- },
24
- get xFlat() {
25
- return {uri: require('./xFlat.png'), dimensions: {width: 24, height: 24}};
26
- }
27
- };
@@ -1,5 +0,0 @@
1
- export const images = {
2
- get gradient() {
3
- return {uri: require('./gradient.png'), dimensions: {width: 56, height: 2}};
4
- }
5
- };