mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-25 18:20:09 +02:00
Merge pull request #2046 from overleaf/hb-detect-changes-pre-export
Do one compile on toggle to autocompile GitOrigin-RevId: 21776835c691bec9a1f80a7c0d4e651cc8c59dac
This commit is contained in:
committed by
sharelatex
parent
83495f4559
commit
523b5b2114
@@ -131,7 +131,11 @@ define([
|
||||
|
||||
let autoCompileInterval = null
|
||||
const autoCompileIfReady = function() {
|
||||
if ($scope.pdf.compiling || !$scope.autocompile_enabled) {
|
||||
if (
|
||||
$scope.pdf.compiling ||
|
||||
!$scope.autocompile_enabled ||
|
||||
!$scope.pdf.uncompiled
|
||||
) {
|
||||
return
|
||||
}
|
||||
|
||||
@@ -250,7 +254,7 @@ define([
|
||||
$scope.$watch('autocompile_enabled', function(newValue, oldValue) {
|
||||
if (newValue != null && oldValue !== newValue) {
|
||||
if (newValue === true) {
|
||||
startTryingAutoCompile()
|
||||
autoCompileIfReady()
|
||||
}
|
||||
localStorage(`autocompile_enabled:${$scope.project_id}`, newValue)
|
||||
return event_tracking.sendMB('autocompile-setting-changed', {
|
||||
|
||||
Reference in New Issue
Block a user