Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Revert "fix: Negate privacy mode in Send screen" #28360

Merged
merged 1 commit into from
Nov 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion ui/components/app/currency-input/currency-input.js
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ export default function CurrencyInput({
suffix={suffix}
className="currency-input__conversion-component"
displayValue={displayValue}
privacyModeExempt
/>
);
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ export type UserPrefrencedCurrencyDisplayProps = OverridingUnion<
showCurrencySuffix?: boolean;
shouldCheckShowNativeToken?: boolean;
isAggregatedFiatOverviewBalance?: boolean;
privacyModeExempt?: boolean;
}
>;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ export default function UserPreferencedCurrencyDisplay({
showNative,
showCurrencySuffix,
shouldCheckShowNativeToken,
privacyModeExempt,
...restProps
}) {
// NOTE: When displaying currencies, we need the actual account to detect whether we're in a
Expand Down Expand Up @@ -84,7 +83,6 @@ export default function UserPreferencedCurrencyDisplay({
numberOfDecimals={numberOfDecimals}
prefixComponent={prefixComponent}
suffix={showCurrencySuffix && !showEthLogo && currency}
privacyModeExempt={privacyModeExempt}
/>
);
}
Expand Down Expand Up @@ -128,7 +126,6 @@ const UserPreferencedCurrencyDisplayPropTypes = {
textProps: PropTypes.object,
suffixProps: PropTypes.object,
shouldCheckShowNativeToken: PropTypes.bool,
privacyModeExempt: PropTypes.bool,
};

UserPreferencedCurrencyDisplay.propTypes =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@ export function AssetBalanceText({
currency={secondaryCurrency}
numberOfDecimals={2}
displayValue={`${formattedFiat}${errorText}`}
privacyModeExempt
/>
);
}
Expand All @@ -117,7 +116,6 @@ export function AssetBalanceText({
{...commonProps}
value={asset.balance}
type={PRIMARY}
privacyModeExempt
/>
{errorText ? (
<Text
Expand All @@ -138,7 +136,6 @@ export function AssetBalanceText({
<UserPreferencedCurrencyDisplay
{...commonProps}
displayValue={`${balanceString || ''}${errorText}`}
privacyModeExempt
/>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ export type CurrencyDisplayProps = OverridingUnion<
// TODO: Replace `any` with type
// eslint-disable-next-line @typescript-eslint/no-explicit-any
suffixProps?: Record<string, any>;
privacyModeExempt?: boolean;
}
>;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ export default function CurrencyDisplay({
textProps = {},
suffixProps = {},
isAggregatedFiatOverviewBalance = false,
privacyModeExempt,
...props
}) {
const { privacyMode } = useSelector(getPreferences);
Expand Down Expand Up @@ -77,7 +76,7 @@ export default function CurrencyDisplay({
className="currency-display-component__text"
ellipsis
variant={TextVariant.inherit}
isHidden={!privacyModeExempt && privacyMode}
isHidden={privacyMode}
data-testid="account-value-and-suffix"
{...textProps}
>
Expand Down Expand Up @@ -126,7 +125,6 @@ const CurrencyDisplayPropTypes = {
textProps: PropTypes.object,
suffixProps: PropTypes.object,
isAggregatedFiatOverviewBalance: PropTypes.bool,
privacyModeExempt: PropTypes.bool,
};

CurrencyDisplay.propTypes = CurrencyDisplayPropTypes;
3 changes: 0 additions & 3 deletions ui/pages/asset/components/asset-page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import {
getCurrentCurrency,
getIsBridgeChain,
getIsSwapsChain,
getPreferences,
getSelectedInternalAccount,
getSwapsDefaultToken,
getTokensMarketData,
Expand Down Expand Up @@ -103,7 +102,6 @@ const AssetPage = ({
const conversionRate = useSelector(getConversionRate);
const allMarketData = useSelector(getTokensMarketData);
const isBridgeChain = useSelector(getIsBridgeChain);
const { privacyMode } = useSelector(getPreferences);
const isBuyableChain = useSelector(getIsNativeTokenBuyable);
const defaultSwapsToken = useSelector(getSwapsDefaultToken, isEqual);
const account = useSelector(getSelectedInternalAccount, isEqual);
Expand Down Expand Up @@ -198,7 +196,6 @@ const AssetPage = ({
tokenImage={image}
isOriginalTokenSymbol={asset.isOriginalNativeSymbol}
isNativeCurrency={true}
privacyMode={privacyMode}
/>
) : (
<TokenCell
Expand Down
Loading