Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
mederly committed Jul 13, 2019
2 parents 01cd396 + 5b02920 commit d8aa4f7
Showing 1 changed file with 11 additions and 4 deletions.
Expand Up @@ -52,10 +52,17 @@ protected String newValue(String currentValue, String replacementValue) {
public void renderHead(Component component, IHeaderResponse response) {
super.renderHead(component, response);

StringBuilder componentSb = new StringBuilder();
componentSb.append("$('#");
componentSb.append(component.getMarkupId());
componentSb.append("')");

StringBuilder sb = new StringBuilder();
sb.append("$('#");
sb.append(component.getMarkupId());
sb.append("').tooltip({html:true");
sb.append("if (typeof ");
sb.append(componentSb.toString());
sb.append(".tooltip === \"function\"){");
sb.append(componentSb.toString());
sb.append(".tooltip({html:true");

if(!isInsideModal()){
sb.append(", 'container':'body'");
Expand All @@ -66,7 +73,7 @@ public void renderHead(Component component, IHeaderResponse response) {
}

sb.append("});");

sb.append("}");
response.render(OnDomReadyHeaderItem.forScript(sb.toString()));
}

Expand Down

0 comments on commit d8aa4f7

Please sign in to comment.