288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
|
this.sErrorId = null;
this.xTooltip = oGrammalecte.createNode("div", {id: "grammalecte_tooltip"});
this.xTooltipArrow = oGrammalecte.createNode("img", {
id: "grammalecte_tooltip_arrow",
src: " data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwAAADsABataJCQAAABl0RVh0U29mdHdhcmUAcGFpbnQubmV0IDQuMC4xNzNun2MAAAAnSURBVChTY/j//z8cq/kW/wdhZDEMSXRFWCVhGKwAmwQyHngFxf8B5fOGYfeFpYoAAAAASUVORK5CYII=",
alt: "^",
});
this.xTooltipSuggBlock = oGrammalecte.createNode("div", {id: "grammalecte_tooltip_sugg_block"});
let xMessageBlock = oGrammalecte.createNode("div", {id: "grammalecte_tooltip_message_block"});
xMessageBlock.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_rule_id"}));
xMessageBlock.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_message", textContent: "Erreur."}));
let xActions = xMessageBlock.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_actions"}));
xActions.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_ignore", textContent: "Ignorer"}));
xActions.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_url", textContent: "Voulez-vous en savoir plus ?…"}, {url: ""}));
xMessageBlock.appendChild(xActions);
this.xTooltip.appendChild(xMessageBlock);
this.xTooltip.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_sugg_title", textContent: "SUGGESTIONS :"}));
this.xTooltip.appendChild(this.xTooltipSuggBlock);
xContentNode.appendChild(this.xTooltip);
xContentNode.appendChild(this.xTooltipArrow);
}
show (sNodeErrorId) { // err
try {
let xNodeErr = document.getElementById(sNodeErrorId);
|
|
>
>
>
>
>
>
|
<
|
<
|
|
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
|
this.sErrorId = null;
this.xTooltip = oGrammalecte.createNode("div", {id: "grammalecte_tooltip"});
this.xTooltipArrow = oGrammalecte.createNode("img", {
id: "grammalecte_tooltip_arrow",
src: " data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAOwAAADsABataJCQAAABl0RVh0U29mdHdhcmUAcGFpbnQubmV0IDQuMC4xNzNun2MAAAAnSURBVChTY/j//z8cq/kW/wdhZDEMSXRFWCVhGKwAmwQyHngFxf8B5fOGYfeFpYoAAAAASUVORK5CYII=",
alt: "^",
});
// message
let xMessageBlock = oGrammalecte.createNode("div", {id: "grammalecte_tooltip_message_block"});
xMessageBlock.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_rule_id"}));
xMessageBlock.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_message", textContent: "Erreur."}));
this.xTooltip.appendChild(xMessageBlock);
// suggestions
this.xTooltip.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_sugg_title", textContent: "SUGGESTIONS :"}));
this.xTooltipSuggBlock = oGrammalecte.createNode("div", {id: "grammalecte_tooltip_sugg_block"});
this.xTooltip.appendChild(this.xTooltipSuggBlock);
// actions
let xActions = oGrammalecte.createNode("div", {id: "grammalecte_tooltip_actions"});
xActions.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_ignore", textContent: "Ignorer"}));
xActions.appendChild(oGrammalecte.createNode("div", {id: "grammalecte_tooltip_url", textContent: "Voulez-vous en savoir plus ?…"}, {url: ""}));
this.xTooltip.appendChild(xActions);
// add tooltip to the page
xContentNode.appendChild(this.xTooltip);
xContentNode.appendChild(this.xTooltipArrow);
}
show (sNodeErrorId) { // err
try {
let xNodeErr = document.getElementById(sNodeErrorId);
|