From 6a1d11b9b5ab475c36b8a0c7e176e06e24088d7f Mon Sep 17 00:00:00 2001 From: n1474335 Date: Thu, 31 Oct 2019 13:39:06 +0000 Subject: [PATCH] Argument hints are not tooltips instead of bmd-help elements --- src/web/HTMLIngredient.mjs | 53 +++++++++++-------- src/web/stylesheets/components/_operation.css | 4 -- src/web/waiters/RecipeWaiter.mjs | 2 + 3 files changed, 33 insertions(+), 26 deletions(-) diff --git a/src/web/HTMLIngredient.mjs b/src/web/HTMLIngredient.mjs index 03f4e983..fd496f2a 100755 --- a/src/web/HTMLIngredient.mjs +++ b/src/web/HTMLIngredient.mjs @@ -54,7 +54,9 @@ class HTMLIngredient { case "binaryString": case "byteArray": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
`; break; case "shortString": case "binaryShortString": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
`; break; case "toggleString": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
@@ -105,7 +108,9 @@ class HTMLIngredient { break; case "number": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
`; break; case "boolean": html += `
-
`; break; case "option": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
`; eventFn = this.type === "populateMultiOption" ? @@ -191,7 +196,9 @@ class HTMLIngredient { break; case "editableOption": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
`; break; case "argSelector": html += `
- + - ${this.hint ? "" + this.hint + "" : ""}
`; this.manager.addDynamicListener(".arg-selector", "change", this.argSelectorChange, this); diff --git a/src/web/stylesheets/components/_operation.css b/src/web/stylesheets/components/_operation.css index a4255fc3..39f53a07 100755 --- a/src/web/stylesheets/components/_operation.css +++ b/src/web/stylesheets/components/_operation.css @@ -159,10 +159,6 @@ div.toggle-string { width: calc(100% - 13px); } -.operation .bmd-form-group .bmd-help { - margin-top: -17px; -} - .input-group .form-control { border-top-left-radius: 4px !important; } diff --git a/src/web/waiters/RecipeWaiter.mjs b/src/web/waiters/RecipeWaiter.mjs index d198098b..ba0e7b11 100755 --- a/src/web/waiters/RecipeWaiter.mjs +++ b/src/web/waiters/RecipeWaiter.mjs @@ -399,6 +399,8 @@ class RecipeWaiter { this.buildRecipeOperation(item); document.getElementById("rec-list").appendChild(item); + $(item).find("[data-toggle='tooltip']").tooltip(); + item.dispatchEvent(this.manager.operationadd); return item; }