One comment about this feature and legacy layout. It seems ::highlight customization is only supported in LayoutNG for most properties (only background-color works in legacy).
I'm wondering if we should add some kind of console warning message, like for Container Queries [*], so if people see some differences in some cases they can know the reason why. Another thing that I noticed is that highlight pseudos are not being printed, I guess that was on purpose for things like ::selection or ::target-text, but should we allow printing ::highlight? Should we open a spec issue about that so it's properly defined (I didn't find anything on the specs regarding printing)? I don't mean this is a blocker for shipping, but if this is not properly defined, maybe it's time to clarify things regarding printing. Cheers, Rego [*] https://chromium-review.googlesource.com/c/chromium/src/+/3706582 On 08/06/2022 19:42, 'Daniel Clark' via blink-dev wrote: > > Contact emails > > dan...@microsoft.com <mailto:dan...@microsoft.com>, sa...@microsoft.com > <mailto:sa...@microsoft.com>, ffi...@microsoft.com > <mailto:ffi...@microsoft.com>, lusan...@microsoft.com > <mailto:lusan...@microsoft.com>, pc...@microsoft.com > <mailto:pc...@microsoft.com>, > > > Explainer > > https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/highlight/explainer.md > <https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/highlight/explainer.md> > > > Specification > > https://drafts.csswg.org/css-highlight-api-1/ > <https://drafts.csswg.org/css-highlight-api-1/> > > > Design docs > > > https://docs.google.com/document/d/1vaWiPLA9opz0AObbObuRj3P5zqzoM2ldy0pHkZkJyxo > <https://docs.google.com/document/d/1vaWiPLA9opz0AObbObuRj3P5zqzoM2ldy0pHkZkJyxo> > > > Summary > > The custom highlight API provides a way for web developers to style the > text of arbitrary ranges. This is useful in a variety of scenarios, > including editing frameworks that wish to implement their own selection, > find-on-page over virtualized documents, multiple selections to > represent online collaboration, or spellchecking frameworks. > > > Blink component > > Blink>Editing > <https://bugs.chromium.org/p/chromium/issues/list?q=component:Blink%3EEditing> > > > Search tags > > Custom Highlight API > <https://chromestatus.com/features#tags:Custom%20Highlight%20API>, Highlight > API <https://chromestatus.com/features#tags:Highlight%20API> > > > TAG review > > https://github.com/w3ctag/design-reviews/issues/584 > <https://github.com/w3ctag/design-reviews/issues/584> > > > TAG review status > > Issues addressed > > > Risks > > > Interoperability and Compatibility > > Low risk: This feature received positive support from Safari and Firefox > at TPAC 2019. Safari is implementing it, Firefox has not yet made any > clear indication on implementation. > > > > /Gecko/: No clear signal > (https://github.com/mozilla/standards-positions/issues/482 > <https://github.com/mozilla/standards-positions/issues/482>) > > /WebKit/: Positive. WebKit implemented the feature behind an > experimental flag in 99: > https://developer.apple.com/safari/technology-preview/release-notes/#:~:text=Added%20support%20for%20rendering%20highlights%20specified%20in%20CSS%20Highlight%20API > <https://developer.apple.com/safari/technology-preview/release-notes/#:~:text=Added%20support%20for%20rendering%20highlights%20specified%20in%20CSS%20Highlight%20API>. > > /Web developers/: Strongly positive > (https://github.com/w3c/csswg-drafts/issues/4307 > <https://github.com/w3c/csswg-drafts/issues/4307>). Multiple use cases > have been pointed out in this issue. CKEditor has also shown support > from the first highlight API explainer. > > /Other signals/: > > > Ergonomics > > Highlight API will be the first use case for constructible StaticRanges, > which the API permits as an alternative to Iive Ranges because they do > not incur cost during DOM mutations. > > > > > Activation > > No. Web developers should be able to use the feature as-is. It is also > easy to feature detect (checking for the existence of CSS.highlights). > > > > > WebView application risks > > None. > > > Debuggability > > DevTools shows ::highlight pseudo elements in the style pane. This > includes inherited pseudos per the highlight inheritance model > <https://drafts.csswg.org/css-pseudo-4/#highlight-cascade> used by > custom highlights. > > > > > Will this feature be supported on all six Blink platforms > (Windows, Mac, Linux, Chrome OS, Android, and Android WebView)? > > Yes > > > Is this feature fully tested by web-platform-tests > > <https://chromium.googlesource.com/chromium/src/+/main/docs/testing/web_platform_tests.md>? > > Yes > https://github.com/web-platform-tests/wpt/tree/master/css/css-highlight-api > <https://github.com/web-platform-tests/wpt/tree/master/css/css-highlight-api> > > > Flag name > > HighlightAPI > > > Requires code in //chrome? > > False > > > Tracking bug > > https://crbug.com/1164461 <https://crbug.com/1164461> > > > Estimated milestones > > No milestones specified > > > > Anticipated spec changes > > Future work will likely add support for setting pointer event listeners > on highlights so that highlights can react to user input. For some early > thoughts on this see > https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/highlight/events-explainer.md > <https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/main/highlight/events-explainer.md>. > That work will not be a compat risk; it would be only additive. > > > > Link to entry on the Chrome Platform Status > > https://chromestatus.com/feature/5436441440026624 > <https://chromestatus.com/feature/5436441440026624> > > > Links to previous Intent discussions > > Intent to > prototype: > https://groups.google.com/a/chromium.org/g/blink-dev/c/Ix2u8NHG5Po/m/jjMjWIHXAQAJ > <https://groups.google.com/a/chromium.org/g/blink-dev/c/Ix2u8NHG5Po/m/jjMjWIHXAQAJ> > > Earlier Intent to ship: > https://groups.google.com/a/chromium.org/g/blink-dev/c/Q21B > Qb-zV0w/m/2ik0_aKyCAAJ > <https://groups.google.com/a/chromium.org/g/blink-dev/c/Q21B%09Qb-zV0w/m/2ik0_aKyCAAJ> > > > > *Additional Comments:* > > We sent an earlier Intent to Ship > <https://groups.google.com/a/chromium.org/g/blink-dev/c/Q21BQb-zV0w/m/2ik0_aKyCAAJ> > for this feature last year where we received feedback about several spec > and implementation issues that needed to be resolved prior to shipping. > We have now addressed these issues. Things that have changed since the > initial I2S include: > > - Custom highlights have been switched to use highlight pseudo > inheritance <https://drafts.csswg.org/css-pseudo-4/#highlight-cascade>, > resolving longstanding disagreements between how highlight pseudos work > in Chromium versus what is said in the spec. > > - Many highlight painting bugs have been fixed by Igalia’s work in this > space. *Note:* Some of these fixes came from the > HighlightOverlayPainting work that was landed in > https://chromium-review.googlesource.com/c/chromium/src/+/3640642 > <https://chromium-review.googlesource.com/c/chromium/src/+/3640642>. > That change was reverted due to a perf issue, so we’ll wait for it to > reland prior to landing the shipping CL for Custom Highlight API. > > - Custom highlights are now exposed to a11y tech though an approach > developed in discussions with CSSWG and APAWG: > https://github.com/w3c/csswg-drafts/issues/6498 > <https://github.com/w3c/csswg-drafts/issues/6498> > > - Miscellaneous other CSSWG resolutions and bugfixes. > > -- > You received this message because you are subscribed to the Google > Groups "blink-dev" group. > To unsubscribe from this group and stop receiving emails from it, send > an email to blink-dev+unsubscr...@chromium.org > <mailto:blink-dev+unsubscr...@chromium.org>. > To view this discussion on the web visit > https://groups.google.com/a/chromium.org/d/msgid/blink-dev/DM5PR00MB0437B1B4E35C4373FF37E4C4C5A49%40DM5PR00MB0437.namprd00.prod.outlook.com > <https://groups.google.com/a/chromium.org/d/msgid/blink-dev/DM5PR00MB0437B1B4E35C4373FF37E4C4C5A49%40DM5PR00MB0437.namprd00.prod.outlook.com?utm_medium=email&utm_source=footer>. -- You received this message because you are subscribed to the Google Groups "blink-dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscr...@chromium.org. To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/450cd2bf-56f3-79c6-4910-0062ef6558ec%40igalia.com.