From 497eb631d17fd798f6ec10d147f8765151a8dbf3 Mon Sep 17 00:00:00 2001 From: Noam Rosenthal Date: Tue, 1 Dec 2020 10:47:11 +0200 Subject: [PATCH] Parse template HTML only once, as HTML parsing is expensive When creating a popup, clone the previously created DOM element and populate the attributes and content. Ideally this would be done with a template element, but since IE11 is still supported this is not possible. Change-Id: I347615cf1f613d97d767d60627b13b6b3ff9c762 Bug: T269338 --- package.json | 2 +- resources/dist/index.js | Bin 42233 -> 42803 bytes resources/dist/index.js.map.json | Bin 201842 -> 204314 bytes src/ui/templates/pagePreview/pagePreview.js | 36 +++++++------ src/ui/templates/popup/popup.js | 25 +++++---- src/ui/templates/preview/preview.js | 51 +++++++++++------- .../referencePreview/referencePreview.js | 42 +++++++++------ src/ui/templates/templateUtil.js | 16 ++++++ webpack.config.js | 4 +- 9 files changed, 116 insertions(+), 60 deletions(-) diff --git a/package.json b/package.json index 50ae8f1da..4f4af47cb 100644 --- a/package.json +++ b/package.json @@ -67,7 +67,7 @@ "bundlesize": [ { "path": "resources/dist/index.js", - "maxSize": "13.61kB" + "maxSize": "13.8kB" } ] } diff --git a/resources/dist/index.js b/resources/dist/index.js index 8f5e5f904cbeb2b8d1c1bc626288b756f00291a4..accc27bd6dada15b5e797116e225064bd6b56f0d 100644 GIT binary patch delta 4762 zcmai2Yj7LY6`m`T5Fjl~9&#L#SY9XgE?&uY;((E}aTH0h9XqnIgdd3=N0zRvwWXE3 zT3JpM#W*2gl9(huA!$lu0#jy63k)66A7wg){^&62gLWv>2hf3Oew3Lu)55@ywo|5O zceRonnc^So-Fx2WeD~aQ^{*SI>^r8{US(jqdNsVkRFElnk741z__eC~e&DvQhWhHw zWE2im*TG}>^>}q98G-LsTS*7JTU|%I@FhN{;eoAnqzC%8K0qd57T=xOSGN9kC5gg` zy8R@ay-}A~MZzF79WD#AQCMv1Akpk6O_$41bf(#iqL-W7YN!0N#VMpSEuo|oP{f#I z@vxLjiy^kkd58{kX_Y|{pmD$1%Q8W6is4!mn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3*yPt2nkExb@{`ia;`>)NEeJKqa z*3TH1=8@i?X)McxqeP@cG}IfBMjcfRQ&yxWd$oUl7A{|%d@O`2u$1VbVlCFf?U_VuYxj6@_s!KA{2ZD~aWKumhv^DyXKNo{C4t%fTJA6xeZBqJqRv~rJL|w# z=!&mY65<2fwR@xk4A&d*E!uSbI=)4Jas8jjDuv1!^1)o;#E0?OXLT0{8w-wh_SFPu8)gyVQz>U=3-og^Mm=d-{Z60@H$J#cHnMy X5N|4e^E-riVco43{Mmo&eZ&6&ShKZn diff --git a/resources/dist/index.js.map.json b/resources/dist/index.js.map.json index 23314f50b374747fed855507acb8b33091166f92..1731b5f4078ce2c7dadd339612df3f1b2ca3d01e 100644 GIT binary patch delta 24190 zcmb7sd30k}ndec_EEPhk(jirqq!!hZRHdvcS>6qmz`gf9%aTf#Wm%SGibFk1vKDJ! zEZZR{Yz;J|o94~nApr)uhwh$cO9+q&A%t|(3?V=>XU^=0(=fx#^h}@A9Oe%=b7s!; z{J!r#$&$+z()CBl@2=mz-TU7E`qNt<`{u1r{OD+^nJHC^Rx{H$<2jS6XYkitC7qe6 zS4xXc4?5EMjb67|%#~7>tsAtOQOntsmZB=P#rQEdgSPp+@dK*~PDn{{g_D}DbICQS+46kQOm5q#j$MM+R z^$fsIWfJ*j4s)AUJ)0re>Y1Yb$nkSeed+jbA9(5qCqMqGr`FFre#=uwF5NTQ5&li- z2?!B3J*E&zk6(nAJux9-ik{nY87*o<@sKz*C6>@4Vjd;TZ9Owd&EfJaPpiy&QbJ@r z5uvKepq_x~iDTt7{#H5JzXm3D(C_!GOX0_25g{U1clU^7r6++6J$}`a({dN8hAc_~ ztFFN+NtzR1rvH-*^nVylF`){Ikw~ue^;Bq0H7&WvTJ7(uNl#KJukK0^yxrv*5-6xi z-4kEy>uK>u9!5h=+kbssOqIe!EkWc9)aPkpu*N_1gr0zpfnOMkQeV^? z^@IR^cEMh@hFu%>hpZtZy8y6+C1^kjh!a@rgueiNh&hJxWJD&az!H%e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6yp+qQ)0xVn=>P9+*IoO+e9m>liAT>rL90IbuqU1G zpzCsr|J#4I<9cv^`-*FM|H{`~_wWDbAGyT-|G4Ye@%{II#r52Et$eG5-S_{)^R7FO zyJ^pA@sYbse*u2C?y#O@vKfse7`RL;lZVtAZ49-aq3WthH1XrzrCbYhp0Wj$l-KED6thh3-l zcfaQ9UU~J`U1wjl|FOStUAWFc_WplqgKr3n&~pm|r1K3DhpRw^aG>q3>}V&Q9_=GC zbKA_AJn + + + + + `; /** * @param {ext.popups.PagePreviewModel} model @@ -15,24 +26,19 @@ const defaultExtractWidth = 215; export function renderPagePreview( model, thumbnail ) { - const url = escapeHTML( model.url ), - languageCode = escapeHTML( model.languageCode ), - languageDirection = escapeHTML( model.languageDirection ); + const $el = renderPopup( model.type, createNodeFromTemplate( templateHTML ) ); - const $el = renderPopup( model.type, - ` - ${thumbnail ? `` : ''} - - - ` - ); + $el.find( '.mwe-popups-discreet, .mwe-popups-extract' ) + .attr( 'href', model.url ); + + $el.find( '.mwe-popups-extract' ) + .attr( 'dir', model.languageDirection ) + .attr( 'lang', model.languageCode ); if ( thumbnail ) { $el.find( '.mwe-popups-discreet' ).append( thumbnail.el ); + } else { + $el.find( '.mwe-popups-discreet' ).remove(); } if ( model.extract ) { diff --git a/src/ui/templates/popup/popup.js b/src/ui/templates/popup/popup.js index 6d5a56e90..1ccdfd4ea 100644 --- a/src/ui/templates/popup/popup.js +++ b/src/ui/templates/popup/popup.js @@ -2,19 +2,26 @@ * @module popup */ -import { escapeHTML } from '../templateUtil'; +import { createNodeFromTemplate } from '../templateUtil'; +const templateHTML = ` +
+`; /** * @param {ext.popups.previewTypes} type - * @param {string} html HTML string. + * @param {Element} element The contents of the popup. * @return {JQuery} */ -export function renderPopup( type, html ) { - type = escapeHTML( type ); - return $( $.parseHTML( ` -
-
${html}
-
- `.trim() ) ); +export function renderPopup( type, container ) { + const element = createNodeFromTemplate( templateHTML ); + // The following classes are used here: + // * mwe-popups-type-reference + // * mwe-popups-type-unknown + // * mwe-popups-type-generic + // * mwe-popups-type-disambiguation + element.className = `mwe-popups mwe-popups-type-${type}`; + container.className = 'mwe-popups-container'; + element.appendChild( container ); + return $( element ); } diff --git a/src/ui/templates/preview/preview.js b/src/ui/templates/preview/preview.js index 7cbad8a26..dec3c6d43 100644 --- a/src/ui/templates/preview/preview.js +++ b/src/ui/templates/preview/preview.js @@ -3,7 +3,20 @@ */ import { renderPopup } from '../popup/popup'; -import { escapeHTML } from '../templateUtil'; +import { createNodeFromTemplate, escapeHTML } from '../templateUtil'; + +const templateHTML = ` +
+
+ + + + +
+ +
+
+`; /** * @param {ext.popups.PagePreviewModel} model @@ -15,22 +28,24 @@ import { escapeHTML } from '../templateUtil'; export function renderPreview( model, showTitle, extractMsg, linkMsg ) { - const title = escapeHTML( model.title ), - url = escapeHTML( model.url ), - type = escapeHTML( model.type ); - extractMsg = escapeHTML( extractMsg ); - linkMsg = escapeHTML( linkMsg ); + const $popup = renderPopup( model.type, createNodeFromTemplate( templateHTML ) ); - return renderPopup( model.type, - ` -
- ${showTitle ? `${title}` : ''} - - ${extractMsg} - - - ` - ); + // The following classes are used here: + // * mw-icon-preview-reference + // * mw-icon-preview-unknown + // * mw-icon-preview-generic + // * mw-icon-preview-disambiguation + $popup.find( '.mw-ui-icon ' ).addClass( `mw-ui-icon-preview-${model.type}` ); + $popup.find( '.mwe-popups-extract' ).attr( 'href', model.url ); + $popup.find( '.mwe-popups-message' ).html( escapeHTML( extractMsg ) ); + $popup.find( '.mwe-popups-read-link' ) + .html( escapeHTML( linkMsg ) ) + .attr( 'href', model.url ); + if ( showTitle ) { + $popup.find( '.mwe-popups-title' ).html( escapeHTML( model.title ) ); + } else { + $popup.find( '.mwe-popups-title' ).remove(); + } + + return $popup; } diff --git a/src/ui/templates/referencePreview/referencePreview.js b/src/ui/templates/referencePreview/referencePreview.js index 43e9b10b8..82d0db2b0 100644 --- a/src/ui/templates/referencePreview/referencePreview.js +++ b/src/ui/templates/referencePreview/referencePreview.js @@ -4,6 +4,21 @@ import { renderPopup } from '../popup/popup'; import { escapeHTML } from '../templateUtil'; +import { createNodeFromTemplate } from '../templateUtil'; + +const templateHTML = ` +
+
+
+ + + + +
+
+
+
+
`; // Known citation type strings currently supported with icons and messages. const KNOWN_TYPES = [ 'book', 'journal', 'news', 'web' ]; @@ -37,21 +52,18 @@ export function renderReferencePreview( // * popups-refpreview-reference // * popups-refpreview-web title = escapeHTML( mw.msg( titleMsg ) ); - - const $el = renderPopup( model.type, - ` -
-
- - - ${title} - -
${model.extract}
-
-
-
- ` - ); + const $el = renderPopup( model.type, createNodeFromTemplate( templateHTML ) ); + $el.find( '.mwe-popups-title-placeholder' ) + .replaceWith( title ); + // The following classes are used here: + // * mw-icon-reference-reference + // * mw-icon-reference-unknown + // * mw-icon-reference-generic + // * mw-icon-reference-disambiguation + $el.find( '.mw-ui-icon' ) + .addClass( `mw-ui-icon-reference-${type}` ); + $el.find( '.mw-parser-output' ) + .html( model.extract ); // Make sure to not destroy existing targets, if any $el.find( '.mwe-popups-extract a[href][class~="external"]:not([target])' ).each( ( i, a ) => { diff --git a/src/ui/templates/templateUtil.js b/src/ui/templates/templateUtil.js index 803b2b1d2..05d1c5bf4 100644 --- a/src/ui/templates/templateUtil.js +++ b/src/ui/templates/templateUtil.js @@ -9,3 +9,19 @@ export function escapeHTML( str ) { return mw.html.escape( str ); } + +const templates = {}; +/** + * @param {string} html markup of the template + * @return {Element} a cloned root element of the template + */ +export function createNodeFromTemplate( html ) { + if ( !templates[ html ] ) { + // TODO: use