1
0
mirror of https://github.com/trezor/trezor-wallet synced 2025-07-03 05:12:40 +00:00
trezor-wallet/src/components/notifications/App/components/UpdateBridge/index.js
2019-05-02 14:00:24 +02:00

30 lines
1014 B
JavaScript

/* @flow */
import * as React from 'react';
import { Notification } from 'trezor-ui-components';
import l10nCommonMessages from 'views/common.messages';
import type { Props } from '../../index';
import l10nMessages from './index.messages';
export default (props: Props) => {
if (props.connect.transport && props.connect.transport.outdated) {
return (
<Notification
key="update-bridge"
variant="warning"
title={props.intl.formatMessage(l10nMessages.TR_NEW_TREZOR_BRIDGE_IS_AVAILABLE)}
message={props.intl.formatMessage(
l10nCommonMessages.TR_UPGRADE_FOR_THE_NEWEST_FEATURES_DOT
)}
actions={[
{
label: props.intl.formatMessage(l10nCommonMessages.TR_SHOW_DETAILS),
callback: props.routerActions.gotoBridgeUpdate,
},
]}
/>
);
}
return null;
};