mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-18 04:01:45 +00:00
Merge branch 'master' of https://github.com/BoostIO/Boostnote into fix-2903
This commit is contained in:
@@ -4,15 +4,22 @@ import CSSModules from 'browser/lib/CSSModules'
|
||||
import styles from './ToggleStackDirectionButton.styl'
|
||||
import i18n from 'browser/lib/i18n'
|
||||
|
||||
const ToggleStackDirectionButton = ({
|
||||
onClick, isStacking
|
||||
}) => {
|
||||
const imgSrc = isStacking ? '../resources/icon/icon-panel-split-vertical.svg' : '../resources/icon/icon-panel-split-horizontal.svg'
|
||||
const text = isStacking ? i18n.__('Split Panels Horizontally') : i18n.__('Split Panels Vertically')
|
||||
const ToggleStackDirectionButton = ({ onClick, isStacking }) => {
|
||||
const imgSrc = isStacking
|
||||
? '../resources/icon/icon-panel-split-vertical.svg'
|
||||
: '../resources/icon/icon-panel-split-horizontal.svg'
|
||||
const text = isStacking
|
||||
? i18n.__('Split Panels Horizontally')
|
||||
: i18n.__('Split Panels Vertically')
|
||||
return (
|
||||
<button styleName='control-splitPanelDirection' onClick={() => onClick(!isStacking)}>
|
||||
<button
|
||||
styleName='control-splitPanelDirection'
|
||||
onClick={() => onClick(!isStacking)}
|
||||
>
|
||||
<img styleName='iconInfo' src={imgSrc} />
|
||||
<span lang={i18n.locale} styleName='tooltip'>{text}</span>
|
||||
<span lang={i18n.locale} styleName='tooltip'>
|
||||
{text}
|
||||
</span>
|
||||
</button>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user