mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 18:00:18 +01:00
[MMI] Added code fencing in info tab component (#17910)
* Added code fencing in info tab component * Fixed storybook urls * Removed isBeta mmi code fencing
This commit is contained in:
parent
234fb4ac5d
commit
c2618176f6
@ -12,8 +12,8 @@ _supportRequestLink =
|
||||
|
||||
///: BEGIN:ONLY_INCLUDE_IN(mmi)
|
||||
_supportRequestLink = 'https://mmi-support.zendesk.com/hc/en-us/requests/new';
|
||||
const _mmiWebSite = 'https://metamask.io/institutions/';
|
||||
export const MMI_WEB_SITE = _mmiWebSite;
|
||||
export const SUPPORT_LINK = 'https://mmi-support.zendesk.com/hc/en-us';
|
||||
export const MMI_WEB_SITE = 'https://metamask.io/institutions/';
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
|
||||
export const SUPPORT_REQUEST_LINK = _supportRequestLink;
|
||||
|
@ -4,7 +4,12 @@ import PropTypes from 'prop-types';
|
||||
import Button from '../../../components/ui/button';
|
||||
import { Tag } from '../../../components/component-library';
|
||||
|
||||
import { SUPPORT_REQUEST_LINK } from '../../../helpers/constants/common';
|
||||
import {
|
||||
SUPPORT_REQUEST_LINK,
|
||||
///: BEGIN:ONLY_INCLUDE_IN(mmi)
|
||||
MMI_WEB_SITE,
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
} from '../../../helpers/constants/common';
|
||||
import { isBeta } from '../../../helpers/utils/build-types';
|
||||
import {
|
||||
getNumberOfSettingsInSection,
|
||||
@ -47,6 +52,17 @@ export default class InfoTab extends PureComponent {
|
||||
|
||||
renderInfoLinks() {
|
||||
const { t } = this.context;
|
||||
let privacyUrl, siteUrl;
|
||||
|
||||
///: BEGIN:ONLY_INCLUDE_IN(mmi)
|
||||
privacyUrl = 'https://consensys.net/codefi/about/privacy-policy/';
|
||||
siteUrl = MMI_WEB_SITE;
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
|
||||
///: BEGIN:ONLY_INCLUDE_IN(main,beta,flask)
|
||||
privacyUrl = 'https://metamask.io/privacy.html';
|
||||
siteUrl = 'https://metamask.io/';
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
|
||||
return (
|
||||
<div className="settings-page__content-item settings-page__content-item--without-height">
|
||||
@ -56,7 +72,7 @@ export default class InfoTab extends PureComponent {
|
||||
<div ref={this.settingsRefs[2]} className="info-tab__link-item">
|
||||
<Button
|
||||
type="link"
|
||||
href="https://metamask.io/privacy.html"
|
||||
href={privacyUrl}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="info-tab__link-text"
|
||||
@ -129,7 +145,7 @@ export default class InfoTab extends PureComponent {
|
||||
<div ref={this.settingsRefs[6]} className="info-tab__link-item">
|
||||
<Button
|
||||
type="link"
|
||||
href="https://metamask.io/"
|
||||
href={siteUrl}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="info-tab__link-text"
|
||||
@ -173,6 +189,17 @@ export default class InfoTab extends PureComponent {
|
||||
<div className="settings-page__body">
|
||||
<div className="settings-page__content-row">
|
||||
<div className="settings-page__content-item settings-page__content-item--without-height">
|
||||
{
|
||||
///: BEGIN:ONLY_INCLUDE_IN(mmi)
|
||||
<div className="info-tab__logo-wrapper">
|
||||
<img
|
||||
src="images/info-logo.png"
|
||||
className="info-tab__logo"
|
||||
alt=""
|
||||
/>
|
||||
</div>
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
}
|
||||
<div className="info-tab__item">
|
||||
<div
|
||||
ref={this.settingsRefs[0]}
|
||||
@ -185,11 +212,24 @@ export default class InfoTab extends PureComponent {
|
||||
</div>
|
||||
</div>
|
||||
<div className="info-tab__item">
|
||||
<div className="info-tab__about">{t('builtAroundTheWorld')}</div>
|
||||
<div className="info-tab__about">
|
||||
{
|
||||
///: BEGIN:ONLY_INCLUDE_IN(main,beta,flask)
|
||||
t('builtAroundTheWorld')
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
}
|
||||
{
|
||||
///: BEGIN:ONLY_INCLUDE_IN(mmi)
|
||||
t('mmiBuiltAroundTheWorld')
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{this.renderInfoLinks()}
|
||||
</div>
|
||||
{
|
||||
///: BEGIN:ONLY_INCLUDE_IN(main,beta,flask)
|
||||
<div className="info-tab__logo-wrapper">
|
||||
<img
|
||||
src="./images/logo/metamask-fox.svg"
|
||||
@ -197,6 +237,8 @@ export default class InfoTab extends PureComponent {
|
||||
alt="MetaMask Logo"
|
||||
/>
|
||||
</div>
|
||||
///: END:ONLY_INCLUDE_IN
|
||||
}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user