@proximus/lavender-skeleton-native 0.1.0-alpha.8 → 0.1.0-beta.0
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/dist/CardSkeleton.d.ts +1 -1
- package/dist/CardSkeleton.d.ts.map +1 -1
- package/dist/CardSkeleton.js +3 -2
- package/dist/CarouselSkeleton.d.ts +1 -1
- package/dist/CarouselSkeleton.d.ts.map +1 -1
- package/dist/CarouselSkeleton.js +3 -2
- package/dist/DataUsageSkeleton.d.ts +1 -1
- package/dist/DataUsageSkeleton.d.ts.map +1 -1
- package/dist/DataUsageSkeleton.js +3 -2
- package/dist/MessageCardSkeleton.d.ts +1 -1
- package/dist/MessageCardSkeleton.d.ts.map +1 -1
- package/dist/MessageCardSkeleton.js +3 -2
- package/dist/Skeleton.d.ts.map +1 -1
- package/dist/Skeleton.js +3 -2
- package/dist/StatusSkeleton.d.ts +1 -1
- package/dist/StatusSkeleton.d.ts.map +1 -1
- package/dist/StatusSkeleton.js +3 -2
- package/dist/TileSkeleton.d.ts.map +1 -1
- package/dist/TileSkeleton.js +4 -4
- package/dist/types.d.ts +1 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/CardSkeleton.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ISkeletonProps } from './types';
|
|
3
|
-
export declare function PxCardSkeleton({ inverted, containerStyle }: ISkeletonProps): React.JSX.Element;
|
|
3
|
+
export declare function PxCardSkeleton({ inverted, containerStyle, testID, }: ISkeletonProps): React.JSX.Element;
|
|
4
4
|
//# sourceMappingURL=CardSkeleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CardSkeleton.d.ts","sourceRoot":"","sources":["../src/CardSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"CardSkeleton.d.ts","sourceRoot":"","sources":["../src/CardSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAGzC,wBAAgB,cAAc,CAAC,EAC7B,QAAQ,EACR,cAAc,EACd,MAAM,GACP,EAAE,cAAc,qBAuBhB"}
|
package/dist/CardSkeleton.js
CHANGED
|
@@ -2,9 +2,10 @@ import { View } from 'react-native';
|
|
|
2
2
|
import { PxSkeleton } from './Skeleton';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
|
-
|
|
5
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
6
|
+
export function PxCardSkeleton({ inverted, containerStyle, testID, }) {
|
|
6
7
|
const { theme } = useTheme();
|
|
7
|
-
return (React.createElement(View, { style: [containerStyle, { borderRadius: theme.t('RadiusMain').number }] },
|
|
8
|
+
return (React.createElement(View, { style: [containerStyle, { borderRadius: theme.t('RadiusMain').number }], ...e2eID(testID) },
|
|
8
9
|
React.createElement(PxSkeleton, { variant: 'assetL', inverted: inverted, expand: true }),
|
|
9
10
|
React.createElement(View, { style: {
|
|
10
11
|
gap: theme.t('SpacingSMobile').number,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ISkeletonProps } from './types';
|
|
3
|
-
export declare function PxCarouselSkeleton({ inverted, itemsVisible, containerStyle, }: {
|
|
3
|
+
export declare function PxCarouselSkeleton({ inverted, itemsVisible, containerStyle, testID, }: {
|
|
4
4
|
itemsVisible?: number;
|
|
5
5
|
} & ISkeletonProps): React.JSX.Element;
|
|
6
6
|
//# sourceMappingURL=CarouselSkeleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CarouselSkeleton.d.ts","sourceRoot":"","sources":["../src/CarouselSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"CarouselSkeleton.d.ts","sourceRoot":"","sources":["../src/CarouselSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAGzC,wBAAgB,kBAAkB,CAAC,EACjC,QAAQ,EACR,YAAgB,EAChB,cAAc,EACd,MAAM,GACP,EAAE;IACD,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB,GAAG,cAAc,qBAsCjB"}
|
package/dist/CarouselSkeleton.js
CHANGED
|
@@ -2,7 +2,8 @@ import { View } from 'react-native';
|
|
|
2
2
|
import { PxSkeleton } from './Skeleton';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
|
-
|
|
5
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
6
|
+
export function PxCarouselSkeleton({ inverted, itemsVisible = 1, containerStyle, testID, }) {
|
|
6
7
|
const { theme } = useTheme();
|
|
7
8
|
const panelVariant = itemsVisible === 1 ? 'panel' : 'panelS';
|
|
8
9
|
return (React.createElement(View, { style: [
|
|
@@ -11,7 +12,7 @@ export function PxCarouselSkeleton({ inverted, itemsVisible = 1, containerStyle,
|
|
|
11
12
|
gap: theme.t('SpacingSMobile').number,
|
|
12
13
|
borderRadius: theme.t('RadiusMain').number,
|
|
13
14
|
},
|
|
14
|
-
] },
|
|
15
|
+
], ...e2eID(testID) },
|
|
15
16
|
React.createElement(View, { style: {
|
|
16
17
|
flexDirection: 'row',
|
|
17
18
|
gap: theme.t('SpacingSMobile').number,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ISkeletonProps } from './types';
|
|
3
|
-
export declare function PxDataUsageSkeleton({ inverted, containerStyle, }: ISkeletonProps): React.JSX.Element;
|
|
3
|
+
export declare function PxDataUsageSkeleton({ inverted, containerStyle, testID, }: ISkeletonProps): React.JSX.Element;
|
|
4
4
|
//# sourceMappingURL=DataUsageSkeleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataUsageSkeleton.d.ts","sourceRoot":"","sources":["../src/DataUsageSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"DataUsageSkeleton.d.ts","sourceRoot":"","sources":["../src/DataUsageSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAGzC,wBAAgB,mBAAmB,CAAC,EAClC,QAAQ,EACR,cAAc,EACd,MAAM,GACP,EAAE,cAAc,qBAmChB"}
|
|
@@ -3,7 +3,8 @@ import { PxSkeleton } from './Skeleton';
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
5
|
import { PxStatusSkeleton } from './StatusSkeleton';
|
|
6
|
-
|
|
6
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
7
|
+
export function PxDataUsageSkeleton({ inverted, containerStyle, testID, }) {
|
|
7
8
|
const { theme } = useTheme();
|
|
8
9
|
return (React.createElement(View, { style: [
|
|
9
10
|
containerStyle,
|
|
@@ -13,7 +14,7 @@ export function PxDataUsageSkeleton({ inverted, containerStyle, }) {
|
|
|
13
14
|
padding: theme.t('PaddingSMobile').number,
|
|
14
15
|
backgroundColor: theme.t('ColorBackgroundSurfaceLight'),
|
|
15
16
|
},
|
|
16
|
-
] },
|
|
17
|
+
], ...e2eID(testID) },
|
|
17
18
|
React.createElement(View, { style: {
|
|
18
19
|
gap: theme.t('SpacingXsMobile').number,
|
|
19
20
|
} },
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ISkeletonProps } from './types';
|
|
3
|
-
export declare function PxMessageCardSkeleton({ inverted, containerStyle, }: ISkeletonProps): React.JSX.Element;
|
|
3
|
+
export declare function PxMessageCardSkeleton({ inverted, containerStyle, testID, }: ISkeletonProps): React.JSX.Element;
|
|
4
4
|
//# sourceMappingURL=MessageCardSkeleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageCardSkeleton.d.ts","sourceRoot":"","sources":["../src/MessageCardSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"MessageCardSkeleton.d.ts","sourceRoot":"","sources":["../src/MessageCardSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAGzC,wBAAgB,qBAAqB,CAAC,EACpC,QAAQ,EACR,cAAc,EACd,MAAM,GACP,EAAE,cAAc,qBAkChB"}
|
|
@@ -2,7 +2,8 @@ import { View } from 'react-native';
|
|
|
2
2
|
import { PxSkeleton } from './Skeleton';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
|
-
|
|
5
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
6
|
+
export function PxMessageCardSkeleton({ inverted, containerStyle, testID, }) {
|
|
6
7
|
const { theme } = useTheme();
|
|
7
8
|
return (React.createElement(View, { style: [
|
|
8
9
|
containerStyle,
|
|
@@ -12,7 +13,7 @@ export function PxMessageCardSkeleton({ inverted, containerStyle, }) {
|
|
|
12
13
|
padding: theme.t('PaddingSMobile').number,
|
|
13
14
|
gap: theme.t('SpacingSMobile').number,
|
|
14
15
|
},
|
|
15
|
-
] },
|
|
16
|
+
], ...e2eID(testID) },
|
|
16
17
|
React.createElement(View, { style: {
|
|
17
18
|
flexDirection: 'row',
|
|
18
19
|
gap: theme.t('SpacingSMobile').number,
|
package/dist/Skeleton.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Skeleton.d.ts","sourceRoot":"","sources":["../src/Skeleton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAC3D,OAAO,EAIL,SAAS,EAGT,SAAS,EACT,SAAS,EACV,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"Skeleton.d.ts","sourceRoot":"","sources":["../src/Skeleton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAC3D,OAAO,EAIL,SAAS,EAGT,SAAS,EACT,SAAS,EACV,MAAM,cAAc,CAAC;AAQtB,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG;IAC9C,uBAAuB;IACvB,OAAO,EACH,UAAU,GACV,UAAU,GACV,UAAU,GACV,MAAM,GACN,OAAO,GACP,SAAS,GACT,SAAS,GACT,SAAS,GACT,QAAQ,GACR,QAAQ,GACR,OAAO,GACP,QAAQ,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,cAAc,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IACtC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAeF,wBAAgB,UAAU,CAAC,KAAK,EAAE,qBAAqB,qBAsFtD"}
|
package/dist/Skeleton.js
CHANGED
|
@@ -2,6 +2,7 @@ import React, { useEffect, useRef, useState } from 'react';
|
|
|
2
2
|
import { Animated, Easing, StyleSheet, View, } from 'react-native';
|
|
3
3
|
import LinearGradient from 'react-native-linear-gradient';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
5
6
|
const DURATION = 1500;
|
|
6
7
|
const ANGLE = 18;
|
|
7
8
|
function useColors({ inverted }) {
|
|
@@ -15,7 +16,7 @@ function useColors({ inverted }) {
|
|
|
15
16
|
return { backgroundColor, highlightColor, highlightColorWithOpacity };
|
|
16
17
|
}
|
|
17
18
|
export function PxSkeleton(props) {
|
|
18
|
-
const { inverted = false, containerStyle, variant, expand = false } = props;
|
|
19
|
+
const { inverted = false, containerStyle, variant, expand = false, testID, } = props;
|
|
19
20
|
const [layout, setLayout] = useState({ width: 0, height: 0 });
|
|
20
21
|
const translateX = useRef(new Animated.Value(0)).current;
|
|
21
22
|
const { theme } = useTheme();
|
|
@@ -54,7 +55,7 @@ export function PxSkeleton(props) {
|
|
|
54
55
|
], onLayout: (e) => {
|
|
55
56
|
const { width, height } = e.nativeEvent.layout;
|
|
56
57
|
setLayout({ width, height });
|
|
57
|
-
} },
|
|
58
|
+
}, ...e2eID(testID) },
|
|
58
59
|
React.createElement(Animated.View, { style: {
|
|
59
60
|
position: 'absolute',
|
|
60
61
|
top: -3 * layout.height, // ensure coverage when rotated
|
package/dist/StatusSkeleton.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ISkeletonProps } from './types';
|
|
3
|
-
export declare function PxStatusSkeleton({ inverted, containerStyle }: ISkeletonProps): React.JSX.Element;
|
|
3
|
+
export declare function PxStatusSkeleton({ inverted, containerStyle, testID, }: ISkeletonProps): React.JSX.Element;
|
|
4
4
|
//# sourceMappingURL=StatusSkeleton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StatusSkeleton.d.ts","sourceRoot":"","sources":["../src/StatusSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"StatusSkeleton.d.ts","sourceRoot":"","sources":["../src/StatusSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAGzC,wBAAgB,gBAAgB,CAAC,EAC/B,QAAQ,EACR,cAAc,EACd,MAAM,GACP,EAAE,cAAc,qBAehB"}
|
package/dist/StatusSkeleton.js
CHANGED
|
@@ -2,12 +2,13 @@ import { View } from 'react-native';
|
|
|
2
2
|
import { PxSkeleton } from './Skeleton';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
|
-
|
|
5
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
6
|
+
export function PxStatusSkeleton({ inverted, containerStyle, testID, }) {
|
|
6
7
|
const { theme } = useTheme();
|
|
7
8
|
return (React.createElement(View, { style: [
|
|
8
9
|
containerStyle,
|
|
9
10
|
{ flexDirection: 'row', gap: theme.t('Spacing2xsMobile').number },
|
|
10
|
-
] },
|
|
11
|
+
], ...e2eID(testID) },
|
|
11
12
|
React.createElement(PxSkeleton, { variant: 'assetXS', inverted: inverted }),
|
|
12
13
|
React.createElement(PxSkeleton, { variant: 'body', inverted: inverted })));
|
|
13
14
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TileSkeleton.d.ts","sourceRoot":"","sources":["../src/TileSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"TileSkeleton.d.ts","sourceRoot":"","sources":["../src/TileSkeleton.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAuBzC,wBAAgB,eAAe,CAAC,EAAE,QAAQ,EAAE,cAAc,EAAE,EAAE,cAAc,qBAmB3E"}
|
package/dist/TileSkeleton.js
CHANGED
|
@@ -2,16 +2,16 @@ import { View } from 'react-native';
|
|
|
2
2
|
import { PxSkeleton } from './Skeleton';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import { useTheme } from '@proximus/lavender-styling-native';
|
|
5
|
-
|
|
5
|
+
import { e2eID } from '@proximus/lavender-common-native';
|
|
6
|
+
function PxTileSkeleton({ inverted, testID }) {
|
|
6
7
|
const { theme } = useTheme();
|
|
7
8
|
return (React.createElement(View, { style: {
|
|
8
9
|
alignItems: 'center',
|
|
9
10
|
gap: theme.t('SpacingSMobile').number,
|
|
10
|
-
|
|
11
|
-
borderBottomStartRadius: theme.t('RadiusMain').number,
|
|
11
|
+
borderRadius: theme.t('RadiusMain').number,
|
|
12
12
|
padding: theme.t('PaddingSMobile').number,
|
|
13
13
|
backgroundColor: theme.t('ColorBackgroundSurfaceLight'),
|
|
14
|
-
} },
|
|
14
|
+
}, ...e2eID(testID) },
|
|
15
15
|
React.createElement(PxSkeleton, { variant: 'assetS', inverted: inverted }),
|
|
16
16
|
React.createElement(PxSkeleton, { variant: 'headingS', inverted: inverted })));
|
|
17
17
|
}
|
package/dist/types.d.ts
CHANGED
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEpD,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEpD,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IACtC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB"}
|