@wlloyalty/wll-react-sdk 1.0.75 → 1.0.76

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
@@ -3656,7 +3656,9 @@ var Grid = function (_a) {
3656
3656
  };
3657
3657
  }
3658
3658
  else {
3659
- var tileWidth = SCREEN_WIDTH / columns;
3659
+ var horizontalPadding = GRID_GAP;
3660
+ var tileWidth = (SCREEN_WIDTH - horizontalPadding * 2 - (columns - 1) * GRID_GAP) /
3661
+ columns;
3660
3662
  return {
3661
3663
  width: tileWidth,
3662
3664
  marginBottom: GRID_GAP,
@@ -3692,11 +3694,12 @@ var Grid = function (_a) {
3692
3694
  return true;
3693
3695
  };
3694
3696
  if (shouldStartNewContainer(currentTiles, tile, nextTile)) {
3695
- var isLastInRow = (tileContainers.length + 1) % columnsPerRow === 0;
3697
+ (tileContainers.length + 1) % columnsPerRow === 0;
3696
3698
  tileContainers.push(jsxRuntimeExports.jsx(reactNative.View, { style: [
3697
- // @ts-ignore Web uses CSS calc strings for responsive layouts, while ViewStyle expects numbers
3698
3699
  getTileWidth(columnsPerRow),
3699
- !isLastInRow && { marginRight: GRID_GAP },
3700
+ index % columnsPerRow !== columnsPerRow - 1 && {
3701
+ marginRight: GRID_GAP,
3702
+ },
3700
3703
  ], children: jsxRuntimeExports.jsx(TileContainer, { tiles: currentTiles }) }, "container-".concat(index)));
3701
3704
  currentTiles = [];
3702
3705
  }