Overview
Comment: | [fx] recheck paragraph after applying suggestion |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | fx | webext2 |
Files: | files | file ages | folders |
SHA3-256: |
5bfb5a6c67fa581c66491c74ffb91ca5 |
User & Date: | olr on 2017-08-22 09:34:26 |
Other Links: | branch diff | manifest | tags |
Context
2017-08-22
| ||
12:27 | [fx] modify textarea content while typing check-in: a2a19392b6 user: olr tags: fx, webext2 | |
09:34 | [fx] recheck paragraph after applying suggestion check-in: 5bfb5a6c67 user: olr tags: fx, webext2 | |
08:02 | [fx] textarea control + small code refactoring check-in: 40e9aa097d user: olr tags: fx, webext2 | |
Changes
Modified gc_lang/fr/webext/content_scripts/content_modifier.js from [4e0ba04476] to [c652fb3252].
︙ | |||
137 138 139 140 141 142 143 | 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 | - + | function createGCPanel () { console.log("Correction grammaticale"); if (oGCPanel !== null) { oGCPanelContent.clear(); oGCPanel.show(); } else { // create the panel |
︙ |
Modified gc_lang/fr/webext/content_scripts/gc_content.js from [da49634b64] to [12bc7392df].
︙ | |||
97 98 99 100 101 102 103 | 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 | - + + | } catch (e) { showError(e); } }, recheckParagraph: function (sParagraphNum) { |
︙ | |||
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 | 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 | + + + + + + + + + + + + | xNodeErr.dataset.rule_id = oErr['sRuleId']; } xNodeErr.dataset.suggestions = oErr["aSuggestions"].join("|"); } xNodeErr.className = (this.aIgnoredErrors.has(xNodeErr.dataset.ignored_key)) ? "ignored" : "error " + oErr['sType']; return xNodeErr; }, blockParagraph: function (xParagraph) { xParagraph.style = "background-color: hsl(30, 100%, 80%)"; xParagraph.disabled = true; xParagraph.contentEditable = "false"; }, freeParagraph: function (xParagraph) { xParagraph.style = ""; xParagraph.contentEditable = "true"; }, applySuggestion: function (sNodeSuggId) { // sugg try { console.log(sNodeSuggId); let sErrorId = document.getElementById(sNodeSuggId).dataset.error_id; //let sParaNum = sErrorId.slice(0, sErrorId.indexOf("-")); console.log("grammalecte_err"+sErrorId); let xNodeErr = document.getElementById("grammalecte_err" + sErrorId); xNodeErr.textContent = document.getElementById(sNodeSuggId).textContent; xNodeErr.className = "corrected"; xNodeErr.removeAttribute("style"); this.oTooltip.hide(); this.recheckParagraph(sErrorId.slice(0, sErrorId.indexOf("-"))); } catch (e) { showError(e); } }, ignoreError: function (sIgnoreButtonId) { // ignore |
︙ |