rampkit-expo-dev 0.0.79 → 0.0.80

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.
@@ -1918,10 +1918,22 @@ function Overlay(props) {
1918
1918
  }
1919
1919
  if ((data === null || data === void 0 ? void 0 : data.type) === "rampkit:continue" ||
1920
1920
  (data === null || data === void 0 ? void 0 : data.type) === "continue") {
1921
+ // Only process continue from the active screen
1922
+ if (!isScreenActive(i)) {
1923
+ if (__DEV__)
1924
+ console.log(`[RampKit] Ignoring continue from inactive screen ${i}`);
1925
+ return;
1926
+ }
1921
1927
  handleAdvance(i, (data === null || data === void 0 ? void 0 : data.animation) || "fade");
1922
1928
  return;
1923
1929
  }
1924
1930
  if ((data === null || data === void 0 ? void 0 : data.type) === "rampkit:navigate") {
1931
+ // Only process navigate from the active screen
1932
+ if (!isScreenActive(i)) {
1933
+ if (__DEV__)
1934
+ console.log(`[RampKit] Ignoring navigate from inactive screen ${i}`);
1935
+ return;
1936
+ }
1925
1937
  const target = data === null || data === void 0 ? void 0 : data.targetScreenId;
1926
1938
  if (target === "__goBack__") {
1927
1939
  handleGoBack(i, (data === null || data === void 0 ? void 0 : data.animation) || "fade");
@@ -1941,6 +1953,12 @@ function Overlay(props) {
1941
1953
  return;
1942
1954
  }
1943
1955
  if ((data === null || data === void 0 ? void 0 : data.type) === "rampkit:goBack") {
1956
+ // Only process goBack from the active screen
1957
+ if (!isScreenActive(i)) {
1958
+ if (__DEV__)
1959
+ console.log(`[RampKit] Ignoring goBack from inactive screen ${i}`);
1960
+ return;
1961
+ }
1944
1962
  handleGoBack(i, (data === null || data === void 0 ? void 0 : data.animation) || "fade");
1945
1963
  return;
1946
1964
  }
@@ -1963,6 +1981,12 @@ function Overlay(props) {
1963
1981
  if (raw === "rampkit:tap" ||
1964
1982
  raw === "next" ||
1965
1983
  raw === "continue") {
1984
+ // Only process from the active screen
1985
+ if (!isScreenActive(i)) {
1986
+ if (__DEV__)
1987
+ console.log(`[RampKit] Ignoring ${raw} from inactive screen ${i}`);
1988
+ return;
1989
+ }
1966
1990
  handleAdvance(i);
1967
1991
  return;
1968
1992
  }
@@ -2017,10 +2041,22 @@ function Overlay(props) {
2017
2041
  return;
2018
2042
  }
2019
2043
  if (raw === "rampkit:goBack") {
2044
+ // Only process from the active screen
2045
+ if (!isScreenActive(i)) {
2046
+ if (__DEV__)
2047
+ console.log(`[RampKit] Ignoring goBack (raw) from inactive screen ${i}`);
2048
+ return;
2049
+ }
2020
2050
  handleGoBack(i);
2021
2051
  return;
2022
2052
  }
2023
2053
  if (raw.startsWith("rampkit:navigate:")) {
2054
+ // Only process from the active screen
2055
+ if (!isScreenActive(i)) {
2056
+ if (__DEV__)
2057
+ console.log(`[RampKit] Ignoring navigate (raw) from inactive screen ${i}`);
2058
+ return;
2059
+ }
2024
2060
  const target = raw.slice("rampkit:navigate:".length);
2025
2061
  if (target === "__goBack__") {
2026
2062
  handleGoBack(i);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rampkit-expo-dev",
3
- "version": "0.0.79",
3
+ "version": "0.0.80",
4
4
  "description": "The Expo SDK for RampKit. Build, test, and personalize app onboardings with instant updates.",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",