[PLT-7069] Remove shortcut key on Switch Channels when viewing on mobile web (#7012)
* remove shortcut key on Switch Channels when viewing on mobile web * apply hidden-xs class for mobile view
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
4132a02319
Коммит
244b15ea5b
@@ -827,15 +827,22 @@ export default class Sidebar extends React.Component {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
const quickSwitchText = 'channel_switch_modal.title';
|
let quickSwitchTextShortcutId = 'quick_switch_modal.channelsShortcut.windows';
|
||||||
|
let quickSwitchTextShortcutDefault = '- CTRL+K';
|
||||||
let quickSwitchTextShortcut = 'quick_switch_modal.channelsShortcut.windows';
|
|
||||||
let quickSwitchDefault = '- CTRL+K';
|
|
||||||
if (Utils.isMac()) {
|
if (Utils.isMac()) {
|
||||||
quickSwitchTextShortcut = 'quick_switch_modal.channelsShortcut.mac';
|
quickSwitchTextShortcutId = 'quick_switch_modal.channelsShortcut.mac';
|
||||||
quickSwitchDefault = '- ⌘K';
|
quickSwitchTextShortcutDefault = '- ⌘K';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const quickSwitchTextShortcut = (
|
||||||
|
<span className='switch__shortcut hidden-xs'>
|
||||||
|
<FormattedMessage
|
||||||
|
id={quickSwitchTextShortcutId}
|
||||||
|
defaultMessage={quickSwitchTextShortcutDefault}
|
||||||
|
/>
|
||||||
|
</span>
|
||||||
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div
|
<div
|
||||||
className='sidebar--left'
|
className='sidebar--left'
|
||||||
@@ -946,15 +953,10 @@ export default class Sidebar extends React.Component {
|
|||||||
dangerouslySetInnerHTML={{__html: switchChannelIcon}}
|
dangerouslySetInnerHTML={{__html: switchChannelIcon}}
|
||||||
/>
|
/>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id={quickSwitchText}
|
id={'channel_switch_modal.title'}
|
||||||
defaultMessage='Switch Channels'
|
defaultMessage='Switch Channels'
|
||||||
/>
|
/>
|
||||||
<span className='switch__shortcut'>
|
{quickSwitchTextShortcut}
|
||||||
<FormattedMessage
|
|
||||||
id={quickSwitchTextShortcut}
|
|
||||||
defaultMessage={quickSwitchDefault}
|
|
||||||
/>
|
|
||||||
</span>
|
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user