mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-30 01:42:29 +03:00
76c9f04013
Refs https://github.com/TryGhost/Product/issues/3725 --------- Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
20 lines
443 B
JavaScript
20 lines
443 B
JavaScript
import Component from '@glimmer/component';
|
|
import {htmlSafe} from '@ember/template';
|
|
|
|
const isMac = window.navigator.platform.startsWith('Mac');
|
|
|
|
export default class CtrlOrCmd extends Component {
|
|
get tooltip() {
|
|
return isMac ? 'Option' : '';
|
|
}
|
|
|
|
get character() {
|
|
const character = isMac ? '⌥' : 'Alt';
|
|
return htmlSafe(character);
|
|
}
|
|
|
|
get class() {
|
|
return isMac ? '' : 'mono';
|
|
}
|
|
}
|