Skip to content

Commit ffa32fe

Browse files
committed
feat(mobile): remove llmRebornABtest feature flag
1 parent 2f093c8 commit ffa32fe

9 files changed

Lines changed: 26 additions & 182 deletions

File tree

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"live-mobile": patch
3+
"@ledgerhq/types-live": patch
4+
---
5+
6+
Remove llmRebornABtest feature flag and legacy NoLedgerYetModal onboarding path

apps/ledger-live-mobile/e2e/page/onboarding/onboardingSteps.page.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ export default class OnboardingStepsPage {
1010
acceptAnalyticsButton = () => getElementById(this.acceptAnalyticsButtonId);
1111
accessWalletButton = () => getElementById("onboarding-accessWallet");
1212
noLedgerYetButton = () => getElementById("onboarding-noLedgerYet");
13-
exploreAppButton = () => getElementById("onboarding-noLedgerYetModal-explore");
1413
connectLedgerButton = () => getElementById("Existing Wallet | Connect");
1514

1615
setupLedger = "onboarding-setupLedger";
@@ -65,11 +64,7 @@ export default class OnboardingStepsPage {
6564
}
6665

6766
async chooseToExploreApp() {
68-
await tapByElement(this.exploreAppButton());
69-
// In test mode, the carousel is skipped and only the last slide
70-
// is shown. This avoids all carousel animation/clipping issues
71-
// with the new React Native New Architecture. Just wait for the
72-
// final slide and tap the explore button.
67+
// DETOX: chooseNoLedgerYet navigates straight to discover live (no upsell modal).
7368
await waitForElementById(this.discoverLiveTitle(3));
7469
await waitForElementById(this.exploreWithoutDeviceButtonId);
7570
await tapById(this.exploreWithoutDeviceButtonId);

apps/ledger-live-mobile/src/locales/en/common.json

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1867,31 +1867,13 @@
18671867
"postWelcomeStep": {
18681868
"title": "Let’s get started",
18691869
"noLedgerYet": "I don’t have a Ledger yet",
1870-
"noLedgerYetModal": {
1871-
"title": "Millions of users. 0 hacks.",
1872-
"desc": "Experience peace of mind with a Ledger securing your digital assets.",
1873-
"buy": "Buy a Ledger",
1874-
"explore": "Explore this app"
1875-
},
18761870
"setupLedger": {
18771871
"title": "Set up your Ledger",
18781872
"subtitle": "Select if your Ledger is new or was reset."
18791873
},
18801874
"accessWallet": {
18811875
"title": "Access your wallet",
18821876
"subtitle": "Select if your Ledger is already set up."
1883-
},
1884-
"buyNano": {
1885-
"title": "Buy a Ledger Nano X",
1886-
"subtitle": "A Ledger device is the only way to ensure your assets are secure "
1887-
},
1888-
"discoverLedger": {
1889-
"title": "Explore Ledger Wallet",
1890-
"subtitle": "Explore the app and learn about its benefits "
1891-
},
1892-
"desktopSync": {
1893-
"title": "Sync with desktop app",
1894-
"subtitle": "Sync your assets from Ledger Wallet desktop with your mobile."
18951877
}
18961878
},
18971879
"welcomeBackStep": {

apps/ledger-live-mobile/src/screens/Onboarding/steps/NoLedgerYetModal.tsx

Lines changed: 0 additions & 120 deletions
This file was deleted.

apps/ledger-live-mobile/src/screens/Onboarding/steps/postWelcomeSelection.tsx

Lines changed: 18 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Button, Icons } from "@ledgerhq/native-ui";
22
import { useFocusEffect, useNavigation, useRoute } from "@react-navigation/native";
3-
import React, { useCallback, useState } from "react";
3+
import React, { useCallback } from "react";
44
import { Linking } from "react-native";
55
import { useTranslation } from "~/context/Locale";
66
import { useDispatch } from "~/context/hooks";
@@ -11,11 +11,11 @@ import { OnboardingNavigatorParamList } from "~/components/RootNavigator/types/O
1111
import { StackNavigatorProps } from "~/components/RootNavigator/types/helpers";
1212
import { NavigatorName, ScreenName } from "~/const";
1313
import { SelectionCards } from "./Cards/SelectionCard";
14-
import { NoLedgerYetModal } from "./NoLedgerYetModal";
1514
import OnboardingView from "./OnboardingView";
16-
import { useFeature, useWalletFeaturesConfig } from "@features/platform-feature-flags";
15+
import { useWalletFeaturesConfig } from "@features/platform-feature-flags";
1716
import { urls } from "~/utils/urls";
1817
import { useLocalizedUrl } from "LLM/hooks/useLocalizedUrls";
18+
import { DETOX_ENABLED } from "~/utils/constants";
1919

2020
type NavigationProps = StackNavigatorProps<
2121
OnboardingNavigatorParamList,
@@ -31,28 +31,9 @@ function PostWelcomeSelection() {
3131
const userHasDevice = route.params?.userHasDevice ?? false;
3232
const currentNavigation = navigation.getParent()?.getParent()?.getState().routes[0].name;
3333
const isInOnboarding = currentNavigation === NavigatorName.BaseOnboarding;
34-
const llmRebornABtest = useFeature("llmRebornABtest");
3534
const localizedRebornUrl = useLocalizedUrl(urls.reborn);
3635
const { isEnabled: isWallet40Enabled } = useWalletFeaturesConfig("mobile");
3736

38-
const [modalOpen, setModalOpen] = useState(false);
39-
40-
const openModal = () => {
41-
identifyUser(null);
42-
track("button_clicked", {
43-
button: "I don’t have a Ledger yet",
44-
});
45-
if (llmRebornABtest?.enabled) {
46-
Linking.openURL(localizedRebornUrl);
47-
} else {
48-
setModalOpen(true);
49-
}
50-
};
51-
52-
const closeModal = () => {
53-
setModalOpen(false);
54-
};
55-
5637
const identifyUser = useCallback(
5738
(hasDevice: boolean | null) => {
5839
if (isInOnboarding) dispatch(setOnboardingHasDevice(hasDevice));
@@ -61,10 +42,21 @@ function PostWelcomeSelection() {
6142
[dispatch, isInOnboarding],
6243
);
6344

64-
useFocusEffect(() => {
65-
if (!modalOpen) {
66-
identifyUser(null);
45+
const openNoLedgerYet = useCallback(() => {
46+
identifyUser(null);
47+
track("button_clicked", {
48+
button: "I don’t have a Ledger yet",
49+
});
50+
// Detox: keep the discover-live read-only e2e path; production opens the Reborn URL
51+
if (DETOX_ENABLED) {
52+
navigation.navigate(ScreenName.OnboardingModalDiscoverLive);
53+
return;
6754
}
55+
Linking.openURL(localizedRebornUrl);
56+
}, [identifyUser, localizedRebornUrl, navigation]);
57+
58+
useFocusEffect(() => {
59+
identifyUser(null);
6860
});
6961

7062
const setupLedger = () => {
@@ -88,7 +80,7 @@ function PostWelcomeSelection() {
8880
}}
8981
footer={
9082
isWallet40Enabled && userHasDevice ? undefined : (
91-
<Button type="default" mb={10} onPress={openModal} testID="onboarding-noLedgerYet">
83+
<Button type="default" mb={10} onPress={openNoLedgerYet} testID="onboarding-noLedgerYet">
9284
{t("onboarding.postWelcomeStep.noLedgerYet")}
9385
</Button>
9486
)
@@ -120,8 +112,6 @@ function PostWelcomeSelection() {
120112
},
121113
]}
122114
/>
123-
124-
<NoLedgerYetModal isOpen={modalOpen} onClose={closeModal} />
125115
</OnboardingView>
126116
);
127117
}

e2e/mobile/page/onboarding/onboardingSteps.page.ts

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ export default class OnboardingStepsPage {
2323
onboardingGetStartedButton = () => getElementById(this.getStartedButtonId);
2424
acceptAnalyticsButton = () => getElementById(this.acceptAnalyticsButtonId);
2525
noLedgerYetButton = () => getElementById("onboarding-noLedgerYet");
26-
exploreAppButton = () => getElementById("onboarding-noLedgerYetModal-explore");
2726
setupLedgerButton = () => getElementById(this.setupLedger);
2827
accessWalletButton = () => getElementById(this.accessWallet);
2928
deviceCardHeader = (title: string) => getElementById(`${this.deviceCardId(title)}-header`);
@@ -137,11 +136,7 @@ export default class OnboardingStepsPage {
137136

138137
@Step("Choose to explore app")
139138
async chooseToExploreApp(): Promise<void> {
140-
await tapByElement(this.exploreAppButton());
141-
// In test mode, the carousel is skipped and only the last slide
142-
// is shown. This avoids all carousel animation/clipping issues
143-
// with the new React Native New Architecture. Just wait for the
144-
// final slide and tap the explore button.
139+
// DETOX: chooseNoLedgerYet navigates straight to discover live (no upsell modal).
145140
await waitForElementById(this.discoverLiveTitle(3));
146141
await waitForElementById(this.exploreWithoutDeviceButtonId);
147142
await tapById(this.exploreWithoutDeviceButtonId);

libs/ledgerjs/packages/types-live/src/feature.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,6 @@ export type Features = CurrencyFeatures & {
325325
zcashShielded: DefaultFeature;
326326
llmNanoOnboardingFundWallet: DefaultFeature;
327327
lldRebornABtest: DefaultFeature;
328-
llmRebornABtest: DefaultFeature;
329328
lifiSolana: DefaultFeature;
330329
llmOnboardingEnableSync: Feature_OnboardingEnableSync;
331330
lldOnboardingEnableSync: Feature_OnboardingEnableSync;

shared/feature-flags/src/flags/team-engagement/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ export { analyticsOptIn } from "./analyticsOptIn";
1818
export * from "./llmNanoOnboardingFundWallet";
1919
export * from "./llmNanoSUpsellBanners";
2020
export * from "./llmOnboardingEnableSync";
21-
export * from "./llmRebornABtest";
2221
export * from "./llmSyncOnboardingIncr1";
2322
export * from "./lwmNotificationsOptIn";
2423
export * from "./lwmNewWordingOptInNotificationsDrawer";

shared/feature-flags/src/flags/team-engagement/llmRebornABtest.ts

Lines changed: 0 additions & 2 deletions
This file was deleted.

0 commit comments

Comments
 (0)