2020-12-10 11:13:59 +00:00
|
|
|
import App from '../../../base'
|
|
|
|
import { react2angular } from 'react2angular'
|
|
|
|
|
|
|
|
import HotkeysModal from '../components/hotkeys-modal'
|
|
|
|
|
2021-03-05 13:00:28 +00:00
|
|
|
App.component('hotkeysModal', react2angular(HotkeysModal, undefined))
|
2020-12-10 11:13:59 +00:00
|
|
|
|
2021-04-14 13:17:21 +00:00
|
|
|
export default App.controller('HotkeysModalController', function ($scope) {
|
2020-12-10 11:13:59 +00:00
|
|
|
$scope.show = false
|
2021-03-05 13:00:28 +00:00
|
|
|
$scope.isMac = /Mac/i.test(navigator.platform)
|
2020-12-10 11:13:59 +00:00
|
|
|
|
|
|
|
$scope.handleHide = () => {
|
|
|
|
$scope.$applyAsync(() => {
|
|
|
|
$scope.show = false
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
$scope.openHotkeysModal = () => {
|
|
|
|
$scope.$applyAsync(() => {
|
2021-03-05 13:00:28 +00:00
|
|
|
$scope.trackChangesVisible =
|
|
|
|
$scope.project && $scope.project.features.trackChangesVisible
|
|
|
|
|
2020-12-10 11:13:59 +00:00
|
|
|
$scope.show = true
|
|
|
|
})
|
|
|
|
}
|
|
|
|
})
|