Repository navigation
@lynx-js/web-elements@0.12.21
Patch Changes
-
Send a plain JSON object as the
detailof thex-textlayoutevent. (#4453)The
detailused to be aProxymeasuring the text on demand, which cannot be posted to the background thread. Now all the displayed lines are measured before the event is dispatched, anddetailis{ lineCount, lines: { start, end, ellipsisCount }[] }. The lines exceedingtext-maxlineor hidden by the truncation are not included. The measurement only happens when thelayoutevent is bound.Also fix the wrong line count for texts starting with a multi-line text node and for texts with padding.