Skip to content

Commit

Permalink
Merge pull request #1812 from LedgerHQ/bugfix/change-push-notifs-feat…
Browse files Browse the repository at this point in the history
…ure-flag-key

The push notifications feature flag's key has been modified
  • Loading branch information
cgrellard-ledger authored and valpinkman committed Nov 15, 2022
1 parent 70efc42 commit 1dc29a7
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 7 deletions.
6 changes: 6 additions & 0 deletions .changeset/weak-days-end.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"live-mobile": patch
"@ledgerhq/types-live": patch
---

The push notifications feature flag's key has been modified
2 changes: 1 addition & 1 deletion apps/ledger-live-mobile/src/logic/notifications.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ const getIsNotifEnabled = async () => {
};

const useNotifications = () => {
const pushNotificationsFeature = useFeature("pushNotifications");
const pushNotificationsFeature = useFeature("brazePushNotifications");

const isPushNotificationsModalOpen = useSelector(
notificationsModalOpenSelector,
Expand Down
4 changes: 2 additions & 2 deletions apps/ledger-live-mobile/src/screens/Modals/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const getCurrentRouteName = (
const Modals = () => {
const navigation = useNavigation();

const pushNotificationsFeature = useFeature("pushNotifications");
const pushNotificationsFeature = useFeature("brazePushNotifications");
const { onPushNotificationsRouteChange } = useNotifications();

const ratingsFeature = useFeature("ratings");
Expand Down Expand Up @@ -73,7 +73,7 @@ const Modals = () => {

return (
<>
<FeatureToggle feature="pushNotifications">
<FeatureToggle feature="brazePushNotifications">
<PushNotificationsModal />
</FeatureToggle>
<FeatureToggle feature="ratings">
Expand Down
2 changes: 1 addition & 1 deletion apps/ledger-live-mobile/src/screens/Settings/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ export default function Settings({
onClick={() => navigation.navigate(ScreenName.AboutSettings)}
arrowRight
/>
<FeatureToggle feature="pushNotifications">
<FeatureToggle feature="brazePushNotifications">
<SettingsCard
title={t("settings.notifications.title")}
desc={t("settings.notifications.desc")}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export const defaultFeatures: DefaultFeatures = {
learn: {
enabled: false,
},
pushNotifications: {
brazePushNotifications: {
enabled: false,
},
deviceLocalization: {
Expand Down
2 changes: 1 addition & 1 deletion libs/ledgerjs/packages/types-live/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ Type: [string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Globa

Add others with union (e.g. "learn" | "market" | "foo")

Type: (`"learn"` | `"pushNotifications"` | `"llmNewDeviceSelection"` | `"llmUsbFirmwareUpdate"` | `"ratings"` | `"counterValue"` | `"deviceLocalization"` | `"deviceInitialApps"` | `"buyDeviceFromLive"` | `"ptxSmartRouting"` | `"currencyOsmosis"` | `"currencyOsmosisMobile"` | `"currencyFantom"` | `"currencyMoonbeam"` | `"currencyCronos"` | `"currencySongbird"` | `"currencyFlare"` | `"currencyFantomMobile"` | `"currencyMoonbeamMobile"` | `"currencyCronosMobile"` | `"currencySongbirdMobile"` | `"currencyFlareMobile"` | `"ptxSmartRoutingMobile"` | `"mockFeature"` | `"syncOnboarding"` | `"walletConnectLiveApp"` | `"customImage"` | `"referralProgramDiscoverCard"` | `"referralProgramDesktopBanner"` | `"disableNftSend"` | `"disableNftLedgerMarket"` | `"disableNftRaribleOpensea"` | `"receiveStakingFlowConfigDesktop"` | `"ethStakingProviders"`)
Type: (`"learn"` | `"brazePushNotifications"` | `"llmNewDeviceSelection"` | `"llmUsbFirmwareUpdate"` | `"ratings"` | `"counterValue"` | `"deviceLocalization"` | `"deviceInitialApps"` | `"buyDeviceFromLive"` | `"ptxSmartRouting"` | `"currencyOsmosis"` | `"currencyOsmosisMobile"` | `"currencyFantom"` | `"currencyMoonbeam"` | `"currencyCronos"` | `"currencySongbird"` | `"currencyFlare"` | `"currencyFantomMobile"` | `"currencyMoonbeamMobile"` | `"currencyCronosMobile"` | `"currencySongbirdMobile"` | `"currencyFlareMobile"` | `"ptxSmartRoutingMobile"` | `"mockFeature"` | `"syncOnboarding"` | `"walletConnectLiveApp"` | `"customImage"` | `"referralProgramDiscoverCard"` | `"referralProgramDesktopBanner"` | `"disableNftSend"` | `"disableNftLedgerMarket"` | `"disableNftRaribleOpensea"` | `"receiveStakingFlowConfigDesktop"` | `"ethStakingProviders"`)

### Feature

Expand Down
2 changes: 1 addition & 1 deletion libs/ledgerjs/packages/types-live/src/feature.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** Add others with union (e.g. "learn" | "market" | "foo") */
export type FeatureId =
| "learn"
| "pushNotifications"
| "brazePushNotifications"
| "llmNewDeviceSelection"
| "llmUsbFirmwareUpdate"
| "ratings"
Expand Down

0 comments on commit 1dc29a7

Please sign in to comment.