-
Notifications
You must be signed in to change notification settings - Fork 892
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Private New Tab Page now shows only applicable Mac / non-Mac keys to …
…open Tor Also corrects the actual keys in the string Fix brave/brave-browser#1688
- Loading branch information
Showing
4 changed files
with
34 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
components/brave_new_tab_ui/components/privateTab/torContent.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
import * as React from 'react' | ||
// Feature-specific components | ||
import { | ||
Content, | ||
Title, | ||
SubTitle, | ||
Text, | ||
TorLockImage | ||
} from 'brave-ui/features/newTab' | ||
// Helpers | ||
import { getLocale } from '../../../common/locale' | ||
|
||
const isMac = window.navigator.userAgent.includes('Macintosh') | ||
const torKeyboardShortcutText = isMac ? '⌥⌘N' : 'Alt+Shift+N' | ||
|
||
export default function TorContent () { | ||
return ( | ||
<Content> | ||
<TorLockImage /> | ||
<SubTitle>{getLocale('boxTorLabel')}</SubTitle> | ||
<Title>{getLocale('boxTorTitle')}</Title> | ||
<Text>{getLocale('boxTorText2', { key: torKeyboardShortcutText })}</Text> | ||
</Content> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters