From 2b4de301890a52a8053fa2bc4ad959a2f23e1e79 Mon Sep 17 00:00:00 2001 From: Sebastian Serth Date: Tue, 28 Feb 2023 00:51:33 +0100 Subject: [PATCH] Manually hide tooltip in editor after pressing some buttons --- app/assets/javascripts/editor/editor.js.erb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/editor/editor.js.erb b/app/assets/javascripts/editor/editor.js.erb index 66d5a5d1..49d8ddf8 100644 --- a/app/assets/javascripts/editor/editor.js.erb +++ b/app/assets/javascripts/editor/editor.js.erb @@ -434,6 +434,7 @@ var CodeOceanEditor = { var button = $('#requestComments'); button.prop('disabled', true); button.on('click', function () { + button.tooltip('hide'); $('#rfc_intervention_text').hide() new bootstrap.Modal($('#comment-modal')).show(); }); @@ -614,7 +615,7 @@ var CodeOceanEditor = { $('#start-over-active-file').prop('disabled', this.active_frame.data('role') === 'user_defined_file' || this.active_frame.data('read-only') !== undefined); $('#dummy').toggle(!this.fileActionsAvailable()); $('#render').toggle(this.isActiveFileRenderable()); - $('#run').toggle(this.isActiveFileRunnable() && !this.running); + $('#run').tooltip('hide').toggle(this.isActiveFileRunnable() && !this.running); $('#stop').toggle(this.isActiveFileStoppable()); $('#test').toggle(this.isActiveFileTestable()); }, @@ -689,6 +690,7 @@ var CodeOceanEditor = { }, showSpinner: function (initiator) { + $(initiator).tooltip('hide'); $(initiator).find('i.fa-solid, i.fa-regular').hide(); $(initiator).find('i.fa-spin').addClass('d-inline-block').removeClass('d-none'); },