@wlloyalty/wll-react-sdk 1.0.107 → 1.0.108

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/native.js CHANGED
@@ -2427,22 +2427,22 @@ var Text = function (_a) {
2427
2427
  var accessibilityRole;
2428
2428
  switch (variant) {
2429
2429
  case 'title':
2430
- accessibilityRole = 'header';
2430
+ accessibilityRole = IS_MOBILE ? 'heading' : 'header';
2431
2431
  break;
2432
2432
  case 'caption':
2433
- accessibilityRole = 'text';
2433
+ accessibilityRole = IS_MOBILE ? 'contentinfo' : 'text';
2434
2434
  break;
2435
2435
  case 'eyebrow':
2436
- accessibilityRole = 'text';
2436
+ accessibilityRole = IS_MOBILE ? 'contentinfo' : 'text';
2437
2437
  break;
2438
2438
  case 'description':
2439
- accessibilityRole = 'paragraph';
2439
+ accessibilityRole = IS_MOBILE ? 'article' : 'paragraph';
2440
2440
  break;
2441
2441
  case 'label':
2442
- accessibilityRole = 'text';
2442
+ accessibilityRole = IS_MOBILE ? 'option' : 'text';
2443
2443
  break;
2444
2444
  default:
2445
- accessibilityRole = 'text';
2445
+ accessibilityRole = IS_MOBILE ? 'contentinfo' : 'text';
2446
2446
  }
2447
2447
  var combinedStyles = [
2448
2448
  styles.base,
@@ -2995,6 +2995,13 @@ var SkeletonTile = function (_a) {
2995
2995
  var style = _a.style;
2996
2996
  var theme = useWllSdk().theme;
2997
2997
  var animatedValue = React__namespace.useRef(new reactNative.Animated.Value(0)).current;
2998
+ var width = reactNative.useWindowDimensions().width;
2999
+ var tileWidth = 1000 / 4;
3000
+ var tileHeight = tileWidth;
3001
+ if (IS_MOBILE) {
3002
+ tileWidth = width / 2 - theme.sizes.lg * 2;
3003
+ tileHeight = tileWidth;
3004
+ }
2998
3005
  React__namespace.useEffect(function () {
2999
3006
  var pulseAnimation = reactNative.Animated.loop(reactNative.Animated.sequence([
3000
3007
  reactNative.Animated.timing(animatedValue, {
@@ -3021,6 +3028,8 @@ var SkeletonTile = function (_a) {
3021
3028
  opacity: opacity,
3022
3029
  backgroundColor: theme.alphaDerivedText[20],
3023
3030
  borderRadius: theme.sizes.borderRadiusLg,
3031
+ width: tileWidth,
3032
+ height: tileHeight,
3024
3033
  },
3025
3034
  style,
3026
3035
  ] }));
@@ -3029,7 +3038,6 @@ var styles$4 = reactNative.StyleSheet.create({
3029
3038
  container: {
3030
3039
  aspectRatio: 1,
3031
3040
  overflow: 'hidden',
3032
- width: 1000 / 4,
3033
3041
  },
3034
3042
  });
3035
3043
 
@@ -4180,7 +4188,7 @@ var Section = function (_a) {
4180
4188
  }
4181
4189
  var renderSectionContent = function () {
4182
4190
  if (isLoading) {
4183
- return (jsxRuntimeExports.jsx(Skeleton, { "aria-label": "Loading section content", numberOfSquares: 4 }));
4191
+ return (jsxRuntimeExports.jsx(Skeleton, { "aria-label": "Loading section content", numberOfSquares: IS_WEB ? 4 : 2 }));
4184
4192
  }
4185
4193
  if (error || !sectionData) {
4186
4194
  return jsxRuntimeExports.jsx(EmptyState, { message: error || 'No section data available.' });
@@ -4376,8 +4384,12 @@ var Group = function (_a) {
4376
4384
  return null;
4377
4385
  }
4378
4386
  var _b = useGroupData(id), groupData = _b.groupData, isLoading = _b.isLoading, error = _b.error;
4387
+ var theme = useWllSdk().theme;
4379
4388
  if (isLoading) {
4380
- return (jsxRuntimeExports.jsx(reactNative.View, { style: commonStyles.emptyContainer, accessible: true, accessibilityLabel: "Loading group data", children: jsxRuntimeExports.jsx(Skeleton, {}) }));
4389
+ return (jsxRuntimeExports.jsx(reactNative.View, { style: {
4390
+ flex: 1,
4391
+ padding: theme.sizes.lg,
4392
+ }, accessible: true, accessibilityLabel: "Loading group data", children: jsxRuntimeExports.jsx(Skeleton, { numberOfSquares: IS_WEB ? 4 : 2 }) }));
4381
4393
  }
4382
4394
  if (error || !groupData) {
4383
4395
  return jsxRuntimeExports.jsx(GroupEmptyState, { message: error || 'No group data available' });