feat: show firefox-compatible command palette shortcut alias (#7825)

This commit is contained in:
David Luzar 2024-03-28 18:12:54 +01:00 committed by GitHub
parent 1d71f84515
commit 3e334a67ed
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 11 additions and 8 deletions

View file

@ -3755,8 +3755,7 @@ class App extends React.Component<AppProps, AppState> {
) {
this.setToast({
message: t("commandPalette.shortcutHint", {
shortcutOne: getShortcutFromShortcutName("commandPalette"),
shortcutTwo: getShortcutFromShortcutName("commandPalette", 1),
shortcut: getShortcutFromShortcutName("commandPalette"),
}),
});
event.preventDefault();

View file

@ -281,10 +281,14 @@ export const HelpDialog = ({ onClose }: { onClose?: () => void }) => {
/>
<Shortcut
label={t("commandPalette.title")}
shortcuts={[
getShortcutFromShortcutName("commandPalette"),
getShortcutFromShortcutName("commandPalette", 1),
]}
shortcuts={
isFirefox
? [getShortcutFromShortcutName("commandPalette")]
: [
getShortcutFromShortcutName("commandPalette"),
getShortcutFromShortcutName("commandPalette", 1),
]
}
/>
</ShortcutIsland>
<ShortcutIsland