Просмотр исходного кода

Merge pull request #2314 from overleaf/cmg-remove-rt-toggle

Remove Rich Text test control in left menu

GitOrigin-RevId: 9f6c554b955b75d28dd0f376d7fa5e3d6b3dc8a9
Timothée Alby 7 лет назад
Родитель
Сommit
5112bd3696

+ 0 - 2
services/web/app/src/Features/Project/ProjectController.js

@@ -811,8 +811,6 @@ const ProjectController = {
                 project.overleaf &&
                 project.overleaf.history &&
                 Boolean(project.overleaf.history.display),
-              showTestControls:
-                (req.query && req.query.tc === 'true') || user.isAdmin,
               brandVariation,
               allowedImageNames: Settings.allowedImageNames || [],
               gitBridgePublicBaseUrl: Settings.gitBridgePublicBaseUrl

+ 3 - 13
services/web/app/views/project/editor/left-menu.pug

@@ -49,28 +49,18 @@ aside#left-menu.full-size(
 					span    #{translate("word_count")}
 				a.link-disabled(href, ng-if="!pdf.url" , tooltip=translate('please_compile_pdf_before_word_count'))
 					i.fa.fa-fw.fa-eye
-					span.link-disabled    #{translate("word_count")}	
+					span.link-disabled    #{translate("word_count")}
 
 	if (moduleIncludesAvailable("editorLeftMenu:sync"))
 		div(ng-show="!anonymous")
 			h4() #{translate("sync")}
 			!= moduleIncludes("editorLeftMenu:sync", locals)
-	
+
 	if (moduleIncludesAvailable("editorLeftMenu:editing_services"))
 		span(ng-show="!anonymous")
 			h4 #{translate("services")}
 			!= moduleIncludes("editorLeftMenu:editing_services", locals)
 
-
-	if showTestControls
-		h4 Test Controls
-		ul.list-unstyled.nav(ng-controller="TestControlsController")
-			li
-				a(href="#" ng-click="richText()")
-					i.fa.fa-exclamation.fa-fw
-					| Rich Text
-
-
 	h4(ng-show="!anonymous") #{translate("settings")}
 	form.settings(ng-controller="SettingsController", ng-show="!anonymous")
 		.containter-fluid
@@ -84,7 +74,7 @@ aside#left-menu.full-size(
 					option(value='latex') LaTeX
 					option(value='xelatex') XeLaTeX
 					option(value='lualatex') LuaLaTeX
-					
+
 			.form-controls(ng-show="permissions.write")
 				label(for="rootDoc_id") #{translate("main_document")}
 				select(

+ 0 - 1
services/web/public/src/ide.js

@@ -38,7 +38,6 @@ define([
   'ide/chat/index',
   'ide/clone/index',
   'ide/hotkeys/index',
-  'ide/test-controls/index',
   'ide/wordcount/index',
   'ide/directives/layout',
   'ide/directives/validFile',

+ 0 - 22
services/web/public/src/ide/test-controls/controllers/TestControlsController.js

@@ -1,22 +0,0 @@
-/* eslint-disable
-    max-len,
-    no-return-assign,
-    no-undef,
-*/
-// TODO: This file was created by bulk-decaffeinate.
-// Fix any style issues and re-enable lint.
-/*
- * decaffeinate suggestions:
- * DS102: Remove unnecessary code created because of implicit returns
- * Full docs: https://github.com/decaffeinate/decaffeinate/blob/master/docs/suggestions.md
- */
-define(['base', 'ace/ace'], App =>
-  App.controller(
-    'TestControlsController',
-    $scope =>
-      ($scope.richText = function() {
-        const current = window.location.toString()
-        const target = `${current}${window.location.search ? '&' : '?'}rt=true`
-        return (window.location.href = target)
-      })
-  ))

+ 0 - 6
services/web/public/src/ide/test-controls/index.js

@@ -1,6 +0,0 @@
-/* eslint-disable
-    no-undef,
-*/
-// TODO: This file was created by bulk-decaffeinate.
-// Fix any style issues and re-enable lint.
-define(['ide/test-controls/controllers/TestControlsController'], function() {})