mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
771a39f267
Migrate hotkeys modal to React GitOrigin-RevId: 78399d3d62771cd296bdc2f4f8b1083263d31551
25 lines
600 B
JavaScript
25 lines
600 B
JavaScript
import App from '../../../base'
|
|
import { react2angular } from 'react2angular'
|
|
|
|
import HotkeysModal from '../components/hotkeys-modal'
|
|
|
|
App.component('hotkeysModal', react2angular(HotkeysModal))
|
|
|
|
export default App.controller('HotkeysModalController', function($scope) {
|
|
$scope.show = false
|
|
|
|
$scope.handleHide = () => {
|
|
$scope.$applyAsync(() => {
|
|
$scope.show = false
|
|
})
|
|
}
|
|
|
|
$scope.openHotkeysModal = () => {
|
|
$scope.trackChangesVisible =
|
|
$scope.project && $scope.project.features.trackChangesVisible
|
|
|
|
$scope.$applyAsync(() => {
|
|
$scope.show = true
|
|
})
|
|
}
|
|
})
|