react-native-unit-components 3.1.0 → 3.1.2-beta.1

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.
Files changed (52) hide show
  1. package/lib/commonjs/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.js +3 -26
  2. package/lib/commonjs/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.js.map +1 -1
  3. package/lib/commonjs/components/UNBottomSheetComponent/UNBottomSheetComponent.js +37 -37
  4. package/lib/commonjs/components/UNBottomSheetComponent/UNBottomSheetComponent.js.map +1 -1
  5. package/lib/commonjs/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.js +6 -4
  6. package/lib/commonjs/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.js.map +1 -1
  7. package/lib/commonjs/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.js +7 -6
  8. package/lib/commonjs/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.js.map +1 -1
  9. package/lib/commonjs/helpers/BottomSheet/BottomSheet.js +21 -12
  10. package/lib/commonjs/helpers/BottomSheet/BottomSheet.js.map +1 -1
  11. package/lib/commonjs/helpers/BottomSheet/BottomSheet.styles.js +4 -2
  12. package/lib/commonjs/helpers/BottomSheet/BottomSheet.styles.js.map +1 -1
  13. package/lib/commonjs/hooks/useSafeAreaDimensions.js +5 -1
  14. package/lib/commonjs/hooks/useSafeAreaDimensions.js.map +1 -1
  15. package/lib/commonjs/unitComponentsSdkManager/UnitComponentsSdkManager.js +1 -1
  16. package/lib/commonjs/unitComponentsSdkManager/UnitComponentsSdkManager.js.map +1 -1
  17. package/lib/module/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.js +4 -27
  18. package/lib/module/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.js.map +1 -1
  19. package/lib/module/components/UNBottomSheetComponent/UNBottomSheetComponent.js +38 -38
  20. package/lib/module/components/UNBottomSheetComponent/UNBottomSheetComponent.js.map +1 -1
  21. package/lib/module/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.js +6 -4
  22. package/lib/module/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.js.map +1 -1
  23. package/lib/module/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.js +6 -5
  24. package/lib/module/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.js.map +1 -1
  25. package/lib/module/helpers/BottomSheet/BottomSheet.js +22 -13
  26. package/lib/module/helpers/BottomSheet/BottomSheet.js.map +1 -1
  27. package/lib/module/helpers/BottomSheet/BottomSheet.styles.js +4 -2
  28. package/lib/module/helpers/BottomSheet/BottomSheet.styles.js.map +1 -1
  29. package/lib/module/hooks/useSafeAreaDimensions.js +5 -1
  30. package/lib/module/hooks/useSafeAreaDimensions.js.map +1 -1
  31. package/lib/module/unitComponentsSdkManager/UnitComponentsSdkManager.js +1 -1
  32. package/lib/module/unitComponentsSdkManager/UnitComponentsSdkManager.js.map +1 -1
  33. package/lib/typescript/src/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.d.ts.map +1 -1
  34. package/lib/typescript/src/components/UNBottomSheetComponent/UNBottomSheetComponent.d.ts.map +1 -1
  35. package/lib/typescript/src/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.d.ts +1 -0
  36. package/lib/typescript/src/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.d.ts.map +1 -1
  37. package/lib/typescript/src/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.d.ts +1 -0
  38. package/lib/typescript/src/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.d.ts.map +1 -1
  39. package/lib/typescript/src/helpers/BottomSheet/BottomSheet.d.ts.map +1 -1
  40. package/lib/typescript/src/helpers/BottomSheet/BottomSheet.styles.d.ts +4 -2
  41. package/lib/typescript/src/helpers/BottomSheet/BottomSheet.styles.d.ts.map +1 -1
  42. package/lib/typescript/src/hooks/useSafeAreaDimensions.d.ts.map +1 -1
  43. package/lib/typescript/src/unitComponentsSdkManager/UnitComponentsSdkManager.d.ts.map +1 -1
  44. package/package.json +1 -1
  45. package/src/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.ts +4 -29
  46. package/src/components/UNBottomSheetComponent/UNBottomSheetComponent.tsx +58 -53
  47. package/src/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.tsx +7 -4
  48. package/src/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.tsx +8 -5
  49. package/src/helpers/BottomSheet/BottomSheet.styles.ts +4 -2
  50. package/src/helpers/BottomSheet/BottomSheet.tsx +21 -10
  51. package/src/hooks/useSafeAreaDimensions.ts +5 -1
  52. package/src/unitComponentsSdkManager/UnitComponentsSdkManager.ts +1 -1
@@ -17,8 +17,10 @@ export const getStylesObject = fadeAnim => {
17
17
  opacity: fadeAnim
18
18
  },
19
19
  container: {
20
- position: 'relative',
21
- flex: 1,
20
+ position: 'absolute',
21
+ bottom: 0,
22
+ left: 0,
23
+ right: 0,
22
24
  shadowColor: VARIABLES.COLORS.BLACK,
23
25
  shadowOffset: {
24
26
  width: 0,
@@ -1 +1 @@
1
- {"version":3,"names":["StyleSheet","VARIABLES","getStylesObject","fadeAnim","create","outsideContainer","position","top","bottom","right","left","animation","backgroundColor","flex","opacity","container","shadowColor","COLORS","BLACK","shadowOffset","width","height","shadowOpacity","shadowRadius","elevation","borderTopLeftRadius","borderTopRightRadius","WHITE","overflow","lineContainer","alignItems","line","borderRadius","marginTop","SILVER_FLAKE","outerContent","innerContent","closeButton","display","justifyContent","padding","zIndex"],"sourceRoot":"../../../../src","sources":["helpers/Bott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AW,EAAE;MACX/B,QAAQ,EAAE,UAAU;MACpBgC,OAAO,EAAE,MAAM;MACfR,UAAU,EAAE,QAAQ;MACpBS,cAAc,EAAE,QAAQ;MACxBnB,KAAK,EAAE,EAAE;MACTC,MAAM,EAAE,EAAE;MACVT,eAAe,EAAEX,SAAS,CAACgB,MAAM,CAACU,KAAK;MACvCK,YAAY,EAAE,EAAE;MAChBQ,OAAO,EAAE,CAAC;MACVjC,GAAG,EAAE,EAAE;MACPE,KAAK,EAAE,EAAE;MACTgC,MAAM,EAAE;IACV;EACF,CAAC,CAAC;AACJ,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["StyleSheet","VARIABLES","getStylesObject","fadeAnim","create","outsideContainer","position","top","bottom","right","left","animation","backgroundColor","flex","opacity","container","shadowColor","COLORS","BLACK","shadowOffset","width","height","shadowOpacity","shadowRadius","elevation","borderTopLeftRadius","borderTopRightRadius","WHITE","overflow","lineContainer","alignItems","line","borderRadius","marginTop","SILVER_FLAKE","outerContent","innerContent","closeButton","display","justifyContent","padding","zIndex"],"sourceRoot":"../../../../src","sources":["helpers/BottomSheet/BottomSheet.styles.ts"],"mappings":"AAAA,SAASA,UAAU,QAAQ,cAAc;AAEzC,SAASC,SAAS,QAAQ,wBAAwB;;AAElD;AACA,OAAO,MAAMC,eAAe,GAAIC,QAAa,IAAK;EAChD,OAAOH,UAAU,CAACI,MAAM,CAAC;IACvBC,gBAAgB,EAAE;MAChBC,QAAQ,EAAE,UAAU;MACpBC,GAAG,EAAE,CAAC;MACNC,MAAM,EAAE,CAAC;MACTC,KAAK,EAAE,CAAC;MACRC,IAAI,EAAE;IACR,CAAC;IACDC,SAAS,EAAE;MACTC,eAAe,EAAE,OAAO;MACxBC,IAAI,EAAE,CAAC;MACPC,OAAO,EAAEX;IACX,CAAC;IACDY,SAAS,EAAE;MACTT,QAAQ,EAAE,UAAU;MACpBE,MAAM,EAAE,CAAC;MACTE,IAAI,EAAE,CAAC;MACPD,KAAK,EAAE,CAAC;MACRO,WAAW,EAAEf,SAAS,CAACgB,MAAM,CAACC,KAAK;MACnCC,YAAY,EAAE;QACZC,KAAK,EAAE,CAAC;QACRC,MAAM,EAAE;MACV,CAAC;MACDC,aAAa,EAAE,IAAI;MACnBC,YAAY,EAAE,IAAI;MAClBC,SAAS,EAAE,EAAE;MACbC,mBAAmB,EAAE,EAAE;MACvBC,oBAAoB,EAAE,EAAE;MACxBd,eAAe,EAAEX,SAAS,CAACgB,MAAM,CAACU,KAAK;MACvCC,QAAQ,EAAE;IACZ,CAAC;IACDC,aAAa,EAAE;MACbJ,mBAAmB,EAAE,EAAE;MACvBC,oBAAoB,EAAE,EAAE;MACxBI,UAAU,EAAE;IACd,CAAC;IACDC,IAAI,EAAE;MACJX,KAAK,EAAE,EAAE;MACTC,MAAM,EAAE,CAAC;MACTW,YAAY,EAAE,CAAC;MACfC,SAAS,EAAE,EAAE;MACbrB,eAAe,EAAEX,SAAS,CAACgB,MAAM,CAACiB;IACpC,CAAC;IACDC,YAAY,EAAE;MACZtB,IAAI,EAAE,CAAC;IACT,CAAC;IACDuB,YAAY,EAAE;MACZvB,IAAI,EAAE,CAAC;IACT,CAAC;IACDwB,WAAW,EAAE;MACX/B,QAAQ,EAAE,UAAU;MACpBgC,OAAO,EAAE,MAAM;MACfR,UAAU,EAAE,QAAQ;MACpBS,cAAc,EAAE,QAAQ;MACxBnB,KAAK,EAAE,EAAE;MACTC,MAAM,EAAE,EAAE;MACVT,eAAe,EAAEX,SAAS,CAACgB,MAAM,CAACU,KAAK;MACvCK,YAAY,EAAE,EAAE;MAChBQ,OAAO,EAAE,CAAC;MACVjC,GAAG,EAAE,EAAE;MACPE,KAAK,EAAE,EAAE;MACTgC,MAAM,EAAE;IACV;EACF,CAAC,CAAC;AACJ,CAAC","ignoreList":[]}
@@ -21,7 +21,8 @@ const calculateFullScreenHeight = () => {
21
21
  if (isAndroid15AndAbove) {
22
22
  return isEdgeToEdgeActive ? screenHeight : windowHeight;
23
23
  } else if (isAndroid10To14) {
24
- return windowHeight + insets.top;
24
+ // screenHeight is stable even when translucent status bar alters windowHeight
25
+ return screenHeight;
25
26
  }
26
27
  return windowHeight;
27
28
  };
@@ -30,6 +31,9 @@ const calculateContentHeight = () => {
30
31
  if (isAndroid15AndAbove && !isEdgeToEdgeActive) {
31
32
  return windowHeight;
32
33
  }
34
+ if (isAndroid10To14) {
35
+ return fullScreenHeight - insets.top - insets.bottom;
36
+ }
33
37
  return fullScreenHeight - insets.top;
34
38
  };
35
39
  const contentHeight = calculateContentHeight();
@@ -1 +1 @@
1
- {"version":3,"names":["Dimensions","Platform","initialWindowMetrics","isAndroid","OS","isAndroid10To14","Version","isAndroid15AndAbove","insets","top","bottom","left","right","windowHeight","get","height","screenHeight","heightDifference","Math","abs","isEdgeToEdgeActive","effectiveBottomInset","calculateFullScreenHeight","fullScreenHeight","calculateContentHeight","contentHeight","useSafeAreaDimensions","isAndroid10AndAbove"],"sourceRoot":"../../../src","sources":["hooks/useSafeAreaDimensions.ts"],"mappings":"AAAA,SAASA,UAAU,EAAEC,QAAQ,QAAQ,cAAc;AACnD,SAASC,oBAAoB,QAAQ,gCAAgC;AAErE,MAAMC,SAAS,GAAGF,QAAQ,CAACG,EAAE,KAAK,SAAS;AAC3C,MAAMC,eAAe,GAAGF,SAAS,IAAIF,QAAQ,CAACK,OAAO,IAAI,EAAE,IAAIL,QAAQ,CAACK,OAAO,GAAG,EAAE;AACpF,MAAMC,mBAAmB,GAAGJ,SAAS,IAAIF,QAAQ,CAACK,OAAO,IAAI,EAAE;AAE/D,MAAME,MAAM,GAAGN,oBAAoB,EAAEM,MAAM,IAAI;EAAEC,GAAG,EAAE,CAAC;EAAEC,MAAM,EAAE,CAAC;EAAEC,IAAI,EAAE,CAAC;EAAEC,KAAK,EAAE;AAAE,CAAC;AACvF,MAAMC,YAAY,GAAGb,UAAU,CAACc,GAAG,CAAC,QAAQ,CAAC,CAACC,MAAM;AACpD,MAAMC,YAAY,GAAGhB,UAAU,CAACc,GAAG,CAAC,QAAQ,CAAC,CAACC,MAAM;;AAEpD;AACA;AACA,MAAME,gBAAgB,GAAGC,IAAI,CAACC,GAAG,CAACH,YAAY,GAAGH,YAAY,CAAC;AAC9D,MAAMO,kBAAkB,GAAGb,mBAAmB,IAAIU,gBAAgB,GAAG,EAAE;AAEvE,MAAMI,oBAAoB,GAAGD,kBAAkB,GAAGZ,MAAM,CAACE,MAAM,GAAG,CAAC;AAEnE,MAAMY,yBAAyB,GAAGA,CAAA,KAAc;EAC9C,IAAIf,mBAAmB,EAAE;IACvB,OAAOa,kBAAkB,GAAGJ,YAAY,GAAGH,YAAY;EACzD,CAAC,MAAM,IAAIR,eAAe,EAAE;IAC1B,OAAOQ,YAAY,GAAGL,MAAM,CAACC,GAAG;EAClC;EACA,OAAOI,YAAY;AACrB,CAAC;AAED,MAAMU,gBAAgB,GAAGD,yBAAyB,CAAC,CAAC;AAEpD,MAAME,sBAAsB,GAAGA,CAAA,KAAc;EAC3C,IAAIjB,mBAAmB,IAAI,CAACa,kBAAkB,EAAE;IAC9C,OAAOP,YAAY;EACrB;EACA,OAAOU,gBAAgB,GAAGf,MAAM,CAACC,GAAG;AACtC,CAAC;AAED,MAAMgB,aAAa,GAAGD,sBAAsB,CAAC,CAAC;AAE9C,OAAO,MAAME,qBAAqB,GAAGA,CAAA,KAAM;EACzC,OAAO;IACLlB,MAAM;IACNe,gBAAgB;IAChBE,aAAa;IACbE,mBAAmB,EAAExB,SAAS,IAAIF,QAAQ,CAACK,OAAO,IAAI,EAAE;IACxDc,kBAAkB;IAClBC;EACF,CAAC;AACH,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["Dimensions","Platform","initialWindowMetrics","isAndroid","OS","isAndroid10To14","Version","isAndroid15AndAbove","insets","top","bottom","left","right","windowHeight","get","height","screenHeight","heightDifference","Math","abs","isEdgeToEdgeActive","effectiveBottomInset","calculateFullScreenHeight","fullScreenHeight","calculateContentHeight","contentHeight","useSafeAreaDimensions","isAndroid10AndAbove"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;EAC3C,IAAIjB,mBAAmB,IAAI,CAACa,kBAAkB,EAAE;IAC9C,OAAOP,YAAY;EACrB;EACA,IAAIR,eAAe,EAAE;IACnB,OAAOkB,gBAAgB,GAAGf,MAAM,CAACC,GAAG,GAAGD,MAAM,CAACE,MAAM;EACtD;EACA,OAAOa,gBAAgB,GAAGf,MAAM,CAACC,GAAG;AACtC,CAAC;AAED,MAAMgB,aAAa,GAAGD,sBAAsB,CAAC,CAAC;AAE9C,OAAO,MAAME,qBAAqB,GAAGA,CAAA,KAAM;EACzC,OAAO;IACLlB,MAAM;IACNe,gBAAgB;IAChBE,aAAa;IACbE,mBAAmB,EAAExB,SAAS,IAAIF,QAAQ,CAACK,OAAO,IAAI,EAAE;IACxDc,kBAAkB;IAClBC;EACF,CAAC;AACH,CAAC","ignoreList":[]}
@@ -14,7 +14,7 @@ import UNSnapshotProtectionHelper from '../nativeModulesHelpers/UNSanpshotProtec
14
14
  import { loadIosFontBase64 } from '../nativeModulesHelpers/UNFontFileHelper/UNFontFileHelper';
15
15
  export class UnitComponentsSDK {
16
16
  static securitySettings = UNComponentsSDKConstants.securitySettings;
17
- static sdkVersion = '3.1.0';
17
+ static sdkVersion = '3.1.2-beta.1';
18
18
  static iosFontBase64Map = {};
19
19
  static init = async (env, theme, language, fonts, webVersioningStrategy = UNComponentsSDKConstants.webSDKRecommendedStrategy, securitySettings = UNComponentsSDKConstants.securitySettings) => {
20
20
  try {
@@ -1 +1 @@
1
- {"version":3,"names":["Platform","fetchUnitScript","UnitComponentsUiManager","warnClientIfNeeded","UNComponentsSDKConstants","setTheme","setLanguage","setCustomerToken","store","UserDataKeys","UNStoreManagerHelper","UnitComponentsHelpersManager","UNSecurityManagerHelper","UNComponentsSnapshotProtectionStrategy","UNSnapshotProtectionHelper","loadIosFontBase64","UnitComponentsSDK","securitySettings","sdkVersion","iosFontBase64Map","init","env","theme","language","fonts","webVersioningStrategy","webSDKRecommendedStrategy","ui","helpers","isJailbroke","isDeviceJailbroke","Error","OS","dispatch","shouldProtectFromSnapshot","snapshotProtectionStrategy","None","setIosSecurity","e","console","log","isInitialized","undefined","setPushProvisioningModule","pushProvisionModule","getPushProvisionModule","getSecuritySettings","setSignedNonce","signedNonce","getEnv","getWebVersioningStrategy","getFonts","getSignedNonce","customerToken","getSdkVersion","cleanUserData","cleanValue","unitCustomerToken","unitVerifiedCustomerToken","unitApplicationFormVerifiedToken"],"sourceRoot":"../../../src","sources":["unitComponentsSdkManager/UnitComponentsSdkManager.ts"],"mappings":"AAAA,SAAwBA,QAAQ,QAAQ,cAAc;AACtD,SAASC,eAAe,QAAQ,yBAAyB;AACzD,SAASC,uBAAuB,QAAQ,mDAAmD;AAE3F,SAASC,kBAAkB,QAAQ,sCAAsC;AACzE,SAASC,wBAAwB,QAAQ,+BAA+B;AAExE,SAASC,QAAQ,EAAEC,WAAW,EAAEC,gBAAgB,QAAQ,8BAA8B;AACtF,SAASC,KAAK,QAAQ,gBAAgB;AAEtC,SAASC,YAAY,QAAQ,mCAAmC;AAChE,OAAOC,oBAAoB,MAAM,iEAAiE;AAClG,SAASC,4BAA4B,QAAQ,6DAA6D;AAC1G,OAAOC,uBAAuB,MAAM,0CAA0C;AAC9E,SAAuCC,sCAAsC,QAAQ,kCAAkC;AACvH,OAAOC,0BAA0B,MAAM,+EAA+E;AACtH,SAASC,iBAAiB,QAAQ,2DAA2D;AAE7F,OAAO,MAAMC,iBAAiB,CAAC;EAM7B,OAAiBC,gBAAgB,GAAiCb,wBAAwB,CAACa,gBAAgB;EAI3G,OAAiBC,UAAU,GAAG,OAAO;EACrC,OAAOC,gBAAgB,GAA2B,CAAC,CAAC;EAEpD,OAAcC,IAAI,GAAG,MAAAA,CACnBC,GAA4B,EAC5BC,KAAc,EACdC,QAAiB,EACjBC,KAAe,EACfC,qBAAwD,GAAGrB,wBAAwB,CAACsB,yBAAyB,EAC7GT,gBAA8C,GAAGb,wBAAwB,CAACa,gBAAgB,KACvF;IACH,IAAI;MACF,IAAI,CAACQ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GAAGA,mBAAmB;EAChD,CAAC;EAED,OAAcC,sBAAsB,GAAGA,CAAA,KAAM;IAC3C,OAAO,IAAI,CAACD,mBAAmB;EACjC,CAAC;EAED,OAAcE,mBAAmB,GAAGA,CAAA,KAAM;IACxC,OAAO,IAAI,CAAC7B,gBAAgB;EAC9B,CAAC;;EAED;AACF;AACA;EACE,OAAc8B,cAAc,GAAIC,WAAmB,IAAK;IACtD,IAAI,CAACA,WAAW,GAAGA,WAAW;EAChC,CAAC;EAED,OAAcC,MAAM,GAAGA,CAAA,KAAM;IAC3B,OAAO,IAAI,CAAC5B,GAAG;EACjB,CAAC;EAED,OAAc6B,wBAAwB,GAAGA,CAAA,KAAM;IAC7C,OAAO,IAAI,CAACzB,qBAAqB;EACnC,CAAC;EAED,OAAc0B,QAAQ,GAAGA,CAAA,KAAM;IAC7B,OAAO,IAAI,CAAC3B,KAAK;EACnB,CAAC;;EAED;AACF;AACA;EACE,OAAc4B,cAAc,GAAGA,CAAA,KAAM;IACnC,OAAO,IAAI,CAACJ,WAAW;EACzB,CAAC;EAED,OAAczC,gBAAgB,GAAI8C,aAAqB,IAAK;IAC1D7C,KAAK,CAACyB,QAAQ,CAAC1B,gBAAgB,CAAC8C,aAAa,CAAC,CAAC;EACjD,CAAC;EAED,OAAcC,aAAa,GAAGA,CAAA,KAAM;IAClC,OAAO,IAAI,CAACpC,UAAU;EACxB,CAAC;EAED,OAAcqC,aAAa,GAAGA,CAAA,KAAM;IAClC7C,oBAAoB,CAAC8C,UAAU,CAAC/C,YAAY,CAACgD,iBAAiB,CAAC;IAC/D/C,oBAAoB,CAAC8C,UAAU,CAAC/C,YAAY,CAACiD,yBAAyB,CAAC;IACvEhD,oBAAoB,CAAC8C,UAAU,CAAC/C,YAAY,CAACkD,gCAAgC,CAAC;EAChF,CAAC;AAEH","ignoreList":[]}
1
+ {"version":3,"names":["Platform","fetchUnitScript","UnitComponentsUiManager","warnClientIfNeeded","UNComponentsSDKConstants","setTheme","setLanguage","setCustomerToken","store","UserDataKeys","UNStoreManagerHelper","UnitComponentsHelpersManager","UNSecurityManagerHelper","UNComponentsSnapshotProtectionStrategy","UNSnapshotProtectionHelper","loadIosFontBase64","UnitComponentsSDK","securitySettings","sdkVersion","iosFontBase64Map","init","env","theme","language","fonts","webVersioningStrategy","webSDKRecommendedStrategy","ui","helpers","isJailbroke","isDeviceJailbroke","Error","OS","dispatch","shouldProtectFromSnapshot","snapshotProtectionStrategy","None","setIosSecurity","e","console","log","isInitialized","undefined","setPushProvisioningModule","pushProvisionModule","getPushProvisionModule","getSecuritySettings","setSignedNonce","signedNonce","getEnv","getWebVersioningStrategy","getFonts","getSignedNonce","customerToken","getSdkVersion","cleanUserData","cleanValue","unitCustomerToken","unitVerifiedCustomerToken","unitApplicationFormVerifiedToken"],"sourceRoot":"../../../src","sources":["unitComponentsSdkManager/UnitComponentsSdkManager.ts"],"mappings":"AAAA,SAAwBA,QAAQ,QAAQ,cAAc;AACtD,SAASC,eAAe,QAAQ,yBAAyB;AACzD,SAASC,uBAAuB,QAAQ,mDAAmD;AAE3F,SAASC,kBAAkB,QAAQ,sCAAsC;AACzE,SAASC,wBAAwB,QAAQ,+BAA+B;AAExE,SAASC,QAAQ,EAAEC,WAAW,EAAEC,gBAAgB,QAAQ,8BAA8B;AACtF,SAASC,KAAK,QAAQ,gBAAgB;AAEtC,SAASC,YAAY,QAAQ,mCAAmC;AAChE,OAAOC,oBAAoB,MAAM,iEAAiE;AAClG,SAASC,4BAA4B,QAAQ,6DAA6D;AAC1G,OAAOC,uBAAuB,MAAM,0CAA0C;AAC9E,SAAuCC,sCAAsC,QAAQ,kCAAkC;AACvH,OAAOC,0BAA0B,MAAM,+EAA+E;AACtH,SAASC,iBAAiB,QAAQ,2DAA2D;AAE7F,OAAO,MAAMC,iBAAiB,CAAC;EAM7B,OAAiBC,gBAAgB,GAAiCb,wBAAwB,CAACa,gBAAgB;EAI3G,OAAiBC,UAAU,GAAG,cAAc;EAC5C,OAAOC,gBAAgB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C8C,UAAU,CAAC/C,YAAY,CAACiD,yBAAyB,CAAC;IACvEhD,oBAAoB,CAAC8C,UAAU,CAAC/C,YAAY,CAACkD,gCAAgC,CAAC;EAChF,CAAC;AAEH","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"UNBottomSheetComponent.constants.d.ts","sourceRoot":"","sources":["../../../../../src/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,4CAA4C,MAAM,CAAC;AA4BhE,eAAO,MAAM,oBAAoB,QAAkC,CAAC;AAEpE,eAAO,MAAM,WAAW,KAAK,CAAC;AAC9B,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,YAAY,KAAK,CAAC;AAC/B,eAAO,MAAM,aAAa,KAAK,CAAC;AAChC,eAAO,MAAM,gBAAgB,QAA+B,CAAC"}
1
+ {"version":3,"file":"UNBottomSheetComponent.constants.d.ts","sourceRoot":"","sources":["../../../../../src/components/UNBottomSheetComponent/UNBottomSheetComponent.constants.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,4CAA4C,MAAM,CAAC;AAIhE,eAAO,MAAM,oBAAoB,QAAiF,CAAC;AAEnH,eAAO,MAAM,WAAW,KAAK,CAAC;AAC9B,eAAO,MAAM,cAAc,KAAK,CAAC;AACjC,eAAO,MAAM,YAAY,KAAK,CAAC;AAC/B,eAAO,MAAM,aAAa,KAAK,CAAC;AAChC,eAAO,MAAM,gBAAgB,QAA+B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"UNBottomSheetComponent.d.ts","sourceRoot":"","sources":["../../../../../src/components/UNBottomSheetComponent/UNBottomSheetComponent.tsx"],"names":[],"mappings":";;AA8OA,wBAAsD"}
1
+ {"version":3,"file":"UNBottomSheetComponent.d.ts","sourceRoot":"","sources":["../../../../../src/components/UNBottomSheetComponent/UNBottomSheetComponent.tsx"],"names":[],"mappings":";;AAmPA,wBAAsD"}
@@ -2,6 +2,7 @@
2
2
  import { NativeComponentData } from '../../../../types/internal/bottomSheet.types';
3
3
  export interface UNBottomSheetNativeComponentProps {
4
4
  nativeComponentData: NativeComponentData;
5
+ containerHeight: number;
5
6
  }
6
7
  declare const UNBottomSheetNativeComponent: (props: UNBottomSheetNativeComponentProps) => JSX.Element;
7
8
  export default UNBottomSheetNativeComponent;
@@ -1 +1 @@
1
- {"version":3,"file":"UNBottomSheetNativeComponent.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.tsx"],"names":[],"mappings":";AACA,OAAO,EAEL,mBAAmB,EAEpB,MAAM,8CAA8C,CAAC;AAiBtD,MAAM,WAAW,iCAAiC;IAChD,mBAAmB,EAAE,mBAAmB,CAAC;CAC1C;AAED,QAAA,MAAM,4BAA4B,UAAW,iCAAiC,gBAkI7E,CAAC;AAEF,eAAe,4BAA4B,CAAC"}
1
+ {"version":3,"file":"UNBottomSheetNativeComponent.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/UNBottomSheetComponent/components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent.tsx"],"names":[],"mappings":";AACA,OAAO,EAEL,mBAAmB,EAEpB,MAAM,8CAA8C,CAAC;AAiBtD,MAAM,WAAW,iCAAiC;IAChD,mBAAmB,EAAE,mBAAmB,CAAC;IACzC,eAAe,EAAE,MAAM,CAAC;CACzB;AAED,QAAA,MAAM,4BAA4B,UAAW,iCAAiC,gBAoI7E,CAAC;AAEF,eAAe,4BAA4B,CAAC"}
@@ -5,6 +5,7 @@ export interface UNBottomSheetSlotComponentProps {
5
5
  requestRenderingEvent: RequestRenderingEvent;
6
6
  componentName?: WebComponentType;
7
7
  componentResourceId?: string;
8
+ containerHeight: number;
8
9
  }
9
10
  declare const UNBottomSheetSlotComponent: (props: UNBottomSheetSlotComponentProps) => JSX.Element;
10
11
  export default UNBottomSheetSlotComponent;
@@ -1 +1 @@
1
- {"version":3,"file":"UNBottomSheetSlotComponent.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.tsx"],"names":[],"mappings":";AACA,OAAO,EAAoB,gBAAgB,EAAE,MAAM,+CAA+C,CAAC;AAUnG,OAAO,EACL,qBAAqB,EAEtB,MAAM,yDAAyD,CAAC;AA2BjE,MAAM,WAAW,+BAA+B;IAC9C,qBAAqB,EAAE,qBAAqB,CAAC;IAC7C,aAAa,CAAC,EAAE,gBAAgB,CAAC;IACjC,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAC9B;AAED,QAAA,MAAM,0BAA0B,UAAW,+BAA+B,gBA2LzE,CAAC;AAEF,eAAe,0BAA0B,CAAC"}
1
+ {"version":3,"file":"UNBottomSheetSlotComponent.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/UNBottomSheetComponent/components/UNBottomSheetSlotComponent/UNBottomSheetSlotComponent.tsx"],"names":[],"mappings":";AACA,OAAO,EAAoB,gBAAgB,EAAE,MAAM,+CAA+C,CAAC;AAUnG,OAAO,EACL,qBAAqB,EAEtB,MAAM,yDAAyD,CAAC;AA2BjE,MAAM,WAAW,+BAA+B;IAC9C,qBAAqB,EAAE,qBAAqB,CAAC;IAC7C,aAAa,CAAC,EAAE,gBAAgB,CAAC;IACjC,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,eAAe,EAAE,MAAM,CAAC;CACzB;AAED,QAAA,MAAM,0BAA0B,UAAW,+BAA+B,gBA6LzE,CAAC;AAEF,eAAe,0BAA0B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheet.d.ts","sourceRoot":"","sources":["../../../../../src/helpers/BottomSheet/BottomSheet.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,SAAS,EAA+B,MAAM,OAAO,CAAC;AAgBtE,OAAO,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAC;AAGpF,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,SAAS,CAAC;IACpB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,MAAM,CAAC;IAC1B,wBAAwB,EAAE,OAAO,CAAC;IAClC,mBAAmB,EAAE,MAAM,IAAI,CAAC;IAChC,6BAA6B,EAAE,OAAO,CAAC;IACvC,WAAW,CAAC,EAAE,0BAA0B,CAAC;IACzC,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,eAAe,EAAE,MAAM,CAAA;CACxB;AAED,QAAA,MAAM,WAAW,UAAW,gBAAgB,gBA2M3C,CAAC;AAEF,eAAe,WAAW,CAAC"}
1
+ {"version":3,"file":"BottomSheet.d.ts","sourceRoot":"","sources":["../../../../../src/helpers/BottomSheet/BottomSheet.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,SAAS,EAA+B,MAAM,OAAO,CAAC;AAetE,OAAO,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAC;AAGpF,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,SAAS,CAAC;IACpB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,MAAM,CAAC;IAC1B,wBAAwB,EAAE,OAAO,CAAC;IAClC,mBAAmB,EAAE,MAAM,IAAI,CAAC;IAChC,6BAA6B,EAAE,OAAO,CAAC;IACvC,WAAW,CAAC,EAAE,0BAA0B,CAAC;IACzC,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,eAAe,EAAE,MAAM,CAAA;CACxB;AAED,QAAA,MAAM,WAAW,UAAW,gBAAgB,gBAuN3C,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -12,8 +12,10 @@ export declare const getStylesObject: (fadeAnim: any) => {
12
12
  opacity: any;
13
13
  };
14
14
  container: {
15
- position: "relative";
16
- flex: number;
15
+ position: "absolute";
16
+ bottom: number;
17
+ left: number;
18
+ right: number;
17
19
  shadowColor: string;
18
20
  shadowOffset: {
19
21
  width: number;
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheet.styles.d.ts","sourceRoot":"","sources":["../../../../../src/helpers/BottomSheet/BottomSheet.styles.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,eAAe,aAAc,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+D5C,CAAC"}
1
+ {"version":3,"file":"BottomSheet.styles.d.ts","sourceRoot":"","sources":["../../../../../src/helpers/BottomSheet/BottomSheet.styles.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,eAAe,aAAc,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiE5C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"useSafeAreaDimensions.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useSafeAreaDimensions.ts"],"names":[],"mappings":"AAsCA,eAAO,MAAM,qBAAqB;;;;;;;CASjC,CAAC"}
1
+ {"version":3,"file":"useSafeAreaDimensions.d.ts","sourceRoot":"","sources":["../../../../src/hooks/useSafeAreaDimensions.ts"],"names":[],"mappings":"AA0CA,eAAO,MAAM,qBAAqB;;;;;;;CASjC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"UnitComponentsSdkManager.d.ts","sourceRoot":"","sources":["../../../../src/unitComponentsSdkManager/UnitComponentsSdkManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAY,MAAM,cAAc,CAAC;AAEvD,OAAO,EAAE,uBAAuB,EAAE,MAAM,mDAAmD,CAAC;AAC5F,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AAG3D,OAAO,K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O,0BACQ,iCAAiC,qBACtC,4BAA4B,mBA4B9C;IAEF,OAAc,aAAa,gBAEzB;IAEF,OAAc,yBAAyB,yBAA0B,oBAAoB,UAEnF;IAEF,OAAc,sBAAsB,+DAElC;IAEF,OAAc,mBAAmB,qCAE/B;IAEF;;OAEG;IACH,OAAc,cAAc,gBAAiB,MAAM,UAEjD;IAEF,OAAc,MAAM,4CAElB;IAEF,OAAc,wBAAwB,0CAEpC;IAEF,OAAc,QAAQ,4BAEpB;IAEF;;OAEG;IACH,OAAc,cAAc,2BAE1B;IAEF,OAAc,gBAAgB,kBAAmB,MAAM,UAErD;IAEF,OAAc,aAAa,eAEzB;IAEF,OAAc,aAAa,aAIzB;CAEH"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-unit-components",
3
- "version": "3.1.0",
3
+ "version": "3.1.2-beta.1",
4
4
  "description": "Unit React Native components",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -1,35 +1,10 @@
1
- import { Dimensions, Platform } from 'react-native';
2
- import { initialWindowMetrics } from 'react-native-safe-area-context';
1
+ import { Dimensions } from 'react-native';
3
2
 
4
3
  export const BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE = 0.9;
5
4
 
6
- const windowHeight = Dimensions.get('window').height;
7
- const screenHeight = Dimensions.get('screen').height;
8
- const statusBarHeight = initialWindowMetrics?.insets.top ?? 0;
9
- const isAndroid = Platform.OS === 'android';
10
- const isAndroid15AndAbove = isAndroid && Platform.Version >= 35;
11
-
12
- // Android 15+ edge-to-edge detection
13
- const isEdgeToEdgeActive = isAndroid15AndAbove && Math.abs(screenHeight - windowHeight) < 10;
14
-
15
- // Calculate overFullScreenHeight based on platform
16
- const calculateOverFullScreenHeight = (): number => {
17
- if (!isAndroid) {
18
- // iOS: simple percentage of window height
19
- return windowHeight * BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE;
20
- }
21
-
22
- // Android: adjust for edge-to-edge status
23
- const topMargin = screenHeight * (1 - BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE);
24
- if (isEdgeToEdgeActive) {
25
- return screenHeight - topMargin;
26
- } else {
27
- // Edge-to-edge opted out: status bar is outside window, adjust margin
28
- return windowHeight - (topMargin - statusBarHeight);
29
- }
30
- };
31
-
32
- export const overFullScreenHeight = calculateOverFullScreenHeight();
5
+ // Fallback value for components rendered outside the measured container (e.g. UNAddToWalletComponent).
6
+ // The bottom sheet itself uses layout-measured containerHeight instead of this value.
7
+ export const overFullScreenHeight = Dimensions.get('screen').height * BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE;
33
8
 
34
9
  export const TOP_PADDING = 48;
35
10
  export const BOTTOM_PADDING = 24;
@@ -1,6 +1,6 @@
1
1
  /* eslint-disable @typescript-eslint/no-explicit-any */
2
2
  import React, { useEffect, useState } from 'react';
3
- import { View } from 'react-native';
3
+ import { LayoutChangeEvent, View } from 'react-native';
4
4
  import BottomSheet from '../../helpers/BottomSheet/BottomSheet';
5
5
  import { RequestRenderingEvent, UnitComponentsMessage } from '../../messages/webMessages/unitComponentsMessages';
6
6
 
@@ -19,7 +19,7 @@ import {
19
19
  import { withReduxStore } from '../../helpers/store/helpers';
20
20
  import { useEventListener } from '../../hooks/useEventListener';
21
21
  import { useDispatch, useSelector } from 'react-redux';
22
- import { overFullScreenHeight } from './UNBottomSheetComponent.constants';
22
+ import { BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE } from './UNBottomSheetComponent.constants';
23
23
  import { RootState } from '../../store';
24
24
  import {
25
25
  resetBottomSheetSlice,
@@ -34,11 +34,9 @@ import UNBottomSheetSlotComponent from './components/UNBottomSheetSlotComponent/
34
34
  import UNBottomSheetNativeComponent from './components/UNBottomSheetNativeComponent/UNBottomSheetNativeComponent';
35
35
  import { WebComponentType } from '../../types/internal/webComponent.types';
36
36
  import { getNativeComponentDataFromEvent } from './UNBottomSheetComponent.utils';
37
- import { useSafeAreaDimensions } from '../../hooks/useSafeAreaDimensions';
38
37
 
39
38
  const UNBottomSheetComponent = () => {
40
39
  const dispatch = useDispatch();
41
- const { fullScreenHeight } = useSafeAreaDimensions();
42
40
 
43
41
  const isBottomSheetActive = useSelector((state: RootState) => state.bottomSheet.isBottomSheetActive);
44
42
  const isComponentLoading = useSelector((state: RootState) => state.bottomSheet.isComponentLoading);
@@ -49,55 +47,58 @@ const UNBottomSheetComponent = () => {
49
47
  const shouldEnableBottomSheetScroll = useSelector((state: RootState) => state.bottomSheet.shouldEnableBottomSheetScroll);
50
48
  const [renderingType, setRenderingType] = useState<BottomSheetRenderingType>();
51
49
  const [height, setHeight] = useState(0);
52
- const [sliderMaxHeight, setSliderMaxHeight] = useState(overFullScreenHeight);
50
+ const [sliderMaxHeight, setSliderMaxHeight] = useState(0);
51
+ const [containerHeight, setContainerHeight] = useState(0);
53
52
  const [nativeComponentData, setNativeComponentData] = useState<NativeComponentData>();
54
53
  const [requestRenderingEventData, setRequestRenderingEventData] = useState<RequestRenderingEvent>();
55
54
  const [componentParams, setComponentParams] = useState<{
56
55
  componentName?: WebComponentType,
57
56
  componentResourceId?: string
58
57
  }>();
59
-
58
+
60
59
  const [currentBottomSheetRenderingMessage, setCurrentBottomSheetRenderingMessage] = useState<BottomSheetRenderingMessage>();
61
60
  const styles = getStylesObject();
62
61
 
62
+ const handleContainerLayout = (e: LayoutChangeEvent) => {
63
+ setContainerHeight(e.nativeEvent.layout.height);
64
+ };
65
+
63
66
  useEffect(() => {
64
- const setHeightFromNativePlace = () => {
67
+ if (containerHeight === 0) return;
68
+
69
+ const computedOverFullScreenHeight = containerHeight * BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE;
70
+
71
+ // Always set sliderMaxHeight when containerHeight is available,
72
+ // so the BottomSheet can mount and render children (which may need to load before reporting height).
73
+ if (nativePlace === BottomSheetNativePlaceType.modal) {
74
+ setSliderMaxHeight(containerHeight);
75
+ } else {
76
+ setSliderMaxHeight(computedOverFullScreenHeight);
77
+ }
78
+
79
+ if (!shouldShowBottomSheet) {
80
+ setHeight(0);
81
+ } else {
82
+ // For overFullScreen/modal, set the known height immediately so the WebView
83
+ // has space to load (older Android WebViews won't fire events with 0 height).
84
+ // For menu/contentHeight, wait until content reports its height.
65
85
  switch (nativePlace) {
66
- // In the case of overFullScreen, set the height to the overFullScreenHeight.
67
86
  case BottomSheetNativePlaceType.overFullScreen:
68
- setHeight(overFullScreenHeight);
87
+ setHeight(computedOverFullScreenHeight);
69
88
  break;
70
89
  case BottomSheetNativePlaceType.modal:
71
- setHeight(fullScreenHeight);
90
+ setHeight(containerHeight);
72
91
  break;
73
92
  default:
74
- // In general, we want the bottom sheet to fully contain the component,
75
- // thus adjusting its height to the component height, up to the maximum of overFullScreenHeight.
76
- if (componentHeight) {
77
- setHeight(componentHeight < overFullScreenHeight ? componentHeight : overFullScreenHeight);
93
+ if (!isComponentLoading && componentHeight) {
94
+ setHeight(componentHeight < computedOverFullScreenHeight ? componentHeight : computedOverFullScreenHeight);
95
+ } else {
96
+ setHeight(0);
78
97
  }
79
98
  break;
80
99
  }
81
- };
82
-
83
- const setSliderMaxHeightFromNativePlace = () => {
84
- if (nativePlace === BottomSheetNativePlaceType.modal) {
85
- setSliderMaxHeight(fullScreenHeight);
86
- } else {
87
- setSliderMaxHeight(overFullScreenHeight);
88
- }
89
- };
90
-
91
- // Check if the inner contained component is still loading or the bottom sheet should not be shown.
92
- if (isComponentLoading || !shouldShowBottomSheet) {
93
- // If so, hide the bottom sheet by setting the height to 0.
94
- setHeight(0);
95
- } else {
96
- // If not, display the bottom sheet by calculating and setting the height based on the native place type.
97
- setHeightFromNativePlace();
98
- setSliderMaxHeightFromNativePlace();
99
100
  }
100
- }, [componentHeight, nativePlace, isComponentLoading, shouldShowBottomSheet]);
101
+ }, [componentHeight, nativePlace, isComponentLoading, shouldShowBottomSheet, containerHeight]);
101
102
 
102
103
  useEffect(() => {
103
104
  const resetBottomSheetManagerState = () => {
@@ -106,7 +107,7 @@ const UNBottomSheetComponent = () => {
106
107
  setNativeComponentData(undefined);
107
108
  setRenderingType(undefined);
108
109
  setHeight(0);
109
- setSliderMaxHeight(overFullScreenHeight);
110
+ setSliderMaxHeight(0);
110
111
  };
111
112
 
112
113
  if (!isBottomSheetActive) {
@@ -198,6 +199,7 @@ const UNBottomSheetComponent = () => {
198
199
  requestRenderingEvent={requestRenderingEventData}
199
200
  componentName={componentParams?.componentName}
200
201
  componentResourceId={componentParams?.componentResourceId}
202
+ containerHeight={containerHeight}
201
203
  />
202
204
  ) : null;
203
205
 
@@ -205,6 +207,7 @@ const UNBottomSheetComponent = () => {
205
207
  return nativeComponentData ? (
206
208
  <UNBottomSheetNativeComponent
207
209
  nativeComponentData={nativeComponentData}
210
+ containerHeight={containerHeight}
208
211
  />
209
212
  ) : null;
210
213
 
@@ -212,26 +215,28 @@ const UNBottomSheetComponent = () => {
212
215
  return null;
213
216
  }
214
217
  };
218
+
219
+ if (!isBottomSheetActive) return null;
220
+
215
221
  return (
216
- <View
217
- pointerEvents={isBottomSheetActive ? undefined : 'none'}
218
- style={styles.container}
219
- >
220
- <BottomSheet
221
- isOpen={isBottomSheetActive}
222
- onOpen={() => dispatch(setIsBottomSheetActive(true))}
223
- onClose={() => dispatch(setIsBottomSheetActive(false))}
224
- height={height}
225
- animationDuration={200}
226
- expandToMaxHeightEnabled={false}
227
- handleWebViewScroll={() => handleWebViewScroll()}
228
- shouldEnableBottomSheetScroll={shouldEnableBottomSheetScroll}
229
- nativePlace={nativePlace}
230
- isComponentLoading={isComponentLoading}
231
- sliderMaxHeight={sliderMaxHeight}
232
- >
233
- {renderBottomSheetComponent()}
234
- </BottomSheet>
222
+ <View style={styles.container} onLayout={handleContainerLayout}>
223
+ {containerHeight > 0 && sliderMaxHeight > 0 && (
224
+ <BottomSheet
225
+ isOpen={isBottomSheetActive}
226
+ onOpen={() => dispatch(setIsBottomSheetActive(true))}
227
+ onClose={() => dispatch(setIsBottomSheetActive(false))}
228
+ height={height}
229
+ animationDuration={200}
230
+ expandToMaxHeightEnabled={false}
231
+ handleWebViewScroll={() => handleWebViewScroll()}
232
+ shouldEnableBottomSheetScroll={shouldEnableBottomSheetScroll}
233
+ nativePlace={nativePlace}
234
+ isComponentLoading={isComponentLoading}
235
+ sliderMaxHeight={sliderMaxHeight}
236
+ >
237
+ {renderBottomSheetComponent()}
238
+ </BottomSheet>
239
+ )}
235
240
  </View>
236
241
  );
237
242
  };
@@ -7,7 +7,7 @@ import {
7
7
  import { useDispatch } from 'react-redux';
8
8
  import { setComponentHeight, setScrollState, setShouldEnableBottomSheetScroll } from '../../../../slices/BottomSheetSlice';
9
9
  import { UNAddToWalletComponent } from '../../../../nativeComponents/UNAddToWallet/UNAddToWalletComponent';
10
- import { overFullScreenHeight } from '../../UNBottomSheetComponent.constants';
10
+ import { BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE } from '../../UNBottomSheetComponent.constants';
11
11
  import { useSafeAreaDimensions } from '../../../../hooks/useSafeAreaDimensions';
12
12
  import UNACHCreditComponent from '../../../UNACHCreditComponent/UNACHCreditComponent';
13
13
  import UNCheckDepositComponent from '../../../UNCheckDepositComponent/UNCheckDepositComponent';
@@ -22,11 +22,14 @@ import UNKeyboardAvoidingView from '../../../../helpers/UNKeyboardAvoidingView/U
22
22
 
23
23
  export interface UNBottomSheetNativeComponentProps {
24
24
  nativeComponentData: NativeComponentData;
25
+ containerHeight: number;
25
26
  }
26
27
 
27
28
  const UNBottomSheetNativeComponent = (props: UNBottomSheetNativeComponentProps) => {
28
29
  const dispatch = useDispatch();
29
- const { contentHeight, effectiveBottomInset } = useSafeAreaDimensions();
30
+ const { insets, effectiveBottomInset } = useSafeAreaDimensions();
31
+ const overFullScreenHeight = props.containerHeight * BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE;
32
+ const modalContentHeight = props.containerHeight - insets.top;
30
33
  const [height, setHeight] = useState<number>(0);
31
34
  const [paddingTop, setPaddingTop] = useState<number>(0);
32
35
  const [paddingBottom, setPaddingBottom] = useState<number>(0);
@@ -67,7 +70,7 @@ const UNBottomSheetNativeComponent = (props: UNBottomSheetNativeComponentProps)
67
70
  adjustedHeight = overFullScreenHeight;
68
71
  break;
69
72
  case BottomSheetNativePlaceType.modal:
70
- adjustedHeight = contentHeight;
73
+ adjustedHeight = modalContentHeight;
71
74
  break;
72
75
  default:
73
76
  return;
@@ -79,7 +82,7 @@ const UNBottomSheetNativeComponent = (props: UNBottomSheetNativeComponentProps)
79
82
  };
80
83
 
81
84
  setBottomSheetNativeComponentViewHeight();
82
- }, [props.nativeComponentData.nativePlace, contentHeight, dispatch]);
85
+ }, [props.nativeComponentData.nativePlace, modalContentHeight, overFullScreenHeight, dispatch]);
83
86
 
84
87
  const renderNativeComponent = () => {
85
88
  switch (props.nativeComponentData?.component.type) {
@@ -30,7 +30,7 @@ import {
30
30
  } from '../../../../slices/BottomSheetSlice';
31
31
  import { getAccountActionType } from '../../../UNAccountComponent/UNAccountComponent.utils';
32
32
  import { UNAccountAction } from '../../../UNAccountComponent/UNAccountComponent';
33
- import { BOTTOM_PADDING, LEFT_PADDING, overFullScreenHeight, RIGHT_PADDING, TOP_PADDING, VERTICAL_PADDING } from '../../UNBottomSheetComponent.constants';
33
+ import { BOTTOM_PADDING, BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE, LEFT_PADDING, RIGHT_PADDING, TOP_PADDING, VERTICAL_PADDING } from '../../UNBottomSheetComponent.constants';
34
34
  import { useSafeAreaDimensions } from '../../../../hooks/useSafeAreaDimensions';
35
35
  import { BottomSheetNativeMessage } from '../../../../messages/nativeMessages/bottomSheetMessage';
36
36
  import { OpenPlaidEvent, PlaidMessage } from '../../../../messages/webMessages/plaidMessages';
@@ -43,6 +43,7 @@ export interface UNBottomSheetSlotComponentProps {
43
43
  requestRenderingEvent: RequestRenderingEvent;
44
44
  componentName?: WebComponentType,
45
45
  componentResourceId?: string,
46
+ containerHeight: number,
46
47
  }
47
48
 
48
49
  const UNBottomSheetSlotComponent = (props: UNBottomSheetSlotComponentProps) => {
@@ -50,7 +51,9 @@ const UNBottomSheetSlotComponent = (props: UNBottomSheetSlotComponentProps) => {
50
51
  const webRef = useRef<WebView>(null);
51
52
  const scrollState = useSelector((state: RootState) => state.bottomSheet.scrollState);
52
53
  const nativePlace = props.requestRenderingEvent?.data?.nativePlace;
53
- const { fullScreenHeight, contentHeight, effectiveBottomInset } = useSafeAreaDimensions();
54
+ const { insets, effectiveBottomInset } = useSafeAreaDimensions();
55
+ const overFullScreenHeight = props.containerHeight * BOTTOM_SHEET_OVER_FULLSCREEN_PERCENTAGE_SIZE;
56
+ const modalContentHeight = props.containerHeight - insets.top;
54
57
 
55
58
  useEffect(() => {
56
59
  const scrollStateForSlot = () => {
@@ -113,8 +116,8 @@ const UNBottomSheetSlotComponent = (props: UNBottomSheetSlotComponentProps) => {
113
116
  }
114
117
  case BottomSheetNativePlaceType.modal: {
115
118
  const injectedHeight = !props.requestRenderingEvent.data.isPaddingIncluded
116
- ? contentHeight - VERTICAL_PADDING - effectiveBottomInset
117
- : contentHeight - effectiveBottomInset;
119
+ ? modalContentHeight - VERTICAL_PADDING - effectiveBottomInset
120
+ : modalContentHeight - effectiveBottomInset;
118
121
  injectHtmlFullScreenHeight(webRef.current, injectedHeight);
119
122
  break;
120
123
  }
@@ -219,7 +222,7 @@ const UNBottomSheetSlotComponent = (props: UNBottomSheetSlotComponentProps) => {
219
222
 
220
223
  return (
221
224
  <View style={{...paddingStyle, flex: 1}}>
222
- <UNKeyboardAvoidingView keyboardVerticalOffset={fullScreenHeight - overFullScreenHeight}>
225
+ <UNKeyboardAvoidingView keyboardVerticalOffset={props.containerHeight - overFullScreenHeight}>
223
226
  <WebComponent
224
227
  ref={webRef}
225
228
  type={WebComponentType.slot}
@@ -18,8 +18,10 @@ export const getStylesObject = (fadeAnim: any) => {
18
18
  opacity: fadeAnim,
19
19
  },
20
20
  container: {
21
- position: 'relative',
22
- flex: 1,
21
+ position: 'absolute',
22
+ bottom: 0,
23
+ left: 0,
24
+ right: 0,
23
25
  shadowColor: VARIABLES.COLORS.BLACK,
24
26
  shadowOffset: {
25
27
  width: 0,
@@ -6,7 +6,6 @@ import {
6
6
  Image,
7
7
  LayoutChangeEvent,
8
8
  PanResponder,
9
- Platform,
10
9
  TouchableOpacity,
11
10
  View,
12
11
  } from 'react-native';
@@ -37,11 +36,11 @@ const BottomSheet = (props: BottomSheetProps) => {
37
36
  const panelHeightValue = useRef(new Animated.Value(props.sliderMaxHeight)).current;
38
37
  const fadeAnim = useRef(new Animated.Value(0)).current;
39
38
  const styles = getStylesObject(fadeAnim);
40
- const [isPanelOpened, setIsPanelOpened] = useState(props.isOpen);
39
+ // Initialize to false: BottomSheet mounts fresh each time (conditionally rendered),
40
+ // so useEffect will trigger fadeIn() when isOpen=true on mount.
41
+ const [isPanelOpened, setIsPanelOpened] = useState(false);
41
42
  const [contentHeight, setContentHeight] = useState<number | undefined>(undefined);
42
- const { insets, fullScreenHeight, isAndroid10AndAbove, isEdgeToEdgeActive } = useSafeAreaDimensions();
43
- // Android 15+ (API 35) enforces edge-to-edge, so marginTop calculation differs
44
- const isAndroid15AndAbove = Platform.OS === 'android' && Platform.Version >= 35;
43
+ const { insets } = useSafeAreaDimensions();
45
44
 
46
45
  const [currentHeight, setCurrentHeight] = useState<number>(props.sliderMaxHeight);
47
46
 
@@ -161,10 +160,25 @@ const BottomSheet = (props: BottomSheetProps) => {
161
160
  return isPanelOpened;
162
161
  };
163
162
 
163
+ // Track the last height we animated to, so we skip duplicate animations
164
+ // (prevents visual jitter when _setSize fires multiple times with the same height)
165
+ // but still re-animate when the height actually changes.
166
+ const lastAnimatedHeight = useRef(0);
167
+
168
+ // Reset when new content starts loading, so the next opening can animate.
169
+ useEffect(() => {
170
+ if (props.isComponentLoading) {
171
+ lastAnimatedHeight.current = 0;
172
+ }
173
+ }, [props.isComponentLoading]);
174
+
164
175
  const _setSize = (e: LayoutChangeEvent) => {
165
176
  const newContentHeight = e.nativeEvent.layout.height;
166
177
  setContentHeight(newContentHeight);
167
- setToContentHeight(newContentHeight);
178
+ if (newContentHeight > 0 && newContentHeight !== lastAnimatedHeight.current) {
179
+ lastAnimatedHeight.current = newContentHeight;
180
+ setToContentHeight(newContentHeight);
181
+ }
168
182
  };
169
183
 
170
184
  const _dismiss = (withAnimation = true) => {
@@ -203,13 +217,10 @@ const BottomSheet = (props: BottomSheetProps) => {
203
217
  borderTopLeftRadius: isModal ? 0 : styles.container.borderTopLeftRadius,
204
218
  borderTopRightRadius: isModal ? 0 : styles.container.borderTopRightRadius,
205
219
  height: props.sliderMaxHeight,
206
- // Android 15+ (edge-to-edge): fullScreenHeight is already the full screen, no adjustment needed
207
- // Android 10-14: fullScreenHeight includes status bar, but view starts below it, so subtract insets.top
208
- marginTop: isModal ? 0 : fullScreenHeight - props.sliderMaxHeight - (isAndroid10AndAbove && !isAndroid15AndAbove ? insets.top : 0),
209
220
  transform: [
210
221
  { translateY: panelHeightValue },
211
222
  ],
212
- paddingTop: isModal && (Platform.OS === 'ios' || isEdgeToEdgeActive) ? insets.top : 0,
223
+ paddingTop: isModal ? insets.top : 0,
213
224
  }}
214
225
  >
215
226
  <View
@@ -20,7 +20,8 @@ const calculateFullScreenHeight = (): number => {
20
20
  if (isAndroid15AndAbove) {
21
21
  return isEdgeToEdgeActive ? screenHeight : windowHeight;
22
22
  } else if (isAndroid10To14) {
23
- return windowHeight + insets.top;
23
+ // screenHeight is stable even when translucent status bar alters windowHeight
24
+ return screenHeight;
24
25
  }
25
26
  return windowHeight;
26
27
  };
@@ -31,6 +32,9 @@ const calculateContentHeight = (): number => {
31
32
  if (isAndroid15AndAbove && !isEdgeToEdgeActive) {
32
33
  return windowHeight;
33
34
  }
35
+ if (isAndroid10To14) {
36
+ return fullScreenHeight - insets.top - insets.bottom;
37
+ }
34
38
  return fullScreenHeight - insets.top;
35
39
  };
36
40
 
@@ -26,7 +26,7 @@ export class UnitComponentsSDK {
26
26
  protected static fonts?: UNFonts;
27
27
  protected static signedNonce?: string;
28
28
  protected static pushProvisionModule?: typeof NativeModules;
29
- protected static sdkVersion = '3.1.0';
29
+ protected static sdkVersion = '3.1.2-beta.1';
30
30
  static iosFontBase64Map: Record<string, string> = {};
31
31
 
32
32
  public static init = async (