15:03:46 RRSAgent has joined #css 15:03:50 logging to https://www.w3.org/2025/09/18-css-irc 15:03:53 Zakim has joined #css 15:03:59 present+ 15:04:01 RRSAgent, make logs Public 15:04:03 Meeting: Cascading Style Sheets (CSS) Working Group Teleconference 15:04:16 scribenick: jarhar 15:04:33 noamr: i put up an explainer and a couple of issues for this, and presented at csswg f2f a couple weeks ago 15:04:36 Topic: OpenUI 15:04:37 Agenda: https://github.com/whatwg/html/issues/11625 15:04:39 zcorpan has joined #css 15:04:49 noamr: its been on some sort of slow burning for the last 2 years since we started cross document view transitions 15:04:59 noamr: its not only a view transitions issue, but that was the driving force behind it 15:05:04 github: https://github.com/w3c/csswg-drafts/issues/12594 15:05:36 noamr: the main thing we wanted to do it allow some experiences that have to do with navigation be more declarative and rely on html and css rather than basically intercept all navigate events and have an if statement in there, which also does not always work for everything if you have cross document things 15:06:29 noamr: this started from looking at a lot of userland code that uses frameworks/js to style things based on navigation experience. frameworks call it pending ui, loading spinners and skeletons, that give you immediate response for a navigation 15:06:36 noamr: in order to do this in frameworks you need this kind of code 15:06:42 noamr: you need to wrap the a element in a "nav link" 15:06:48 noamr: you have to wrap all your links to get this pending ui 15:07:03 noamr: and then the whole idea of whats pending is in the framework, and the framework does the transition and content that has not loaded yet 15:07:29 noamr: this to me, i had to build code like that as a frontend dev and it wasn't guaranteed to be immediate, and its just ui. why cant it be immediate in the platform, change css based on navigating somewhere 15:08:03 noamr: *points out things in code examples* 15:08:27 What does ":remote-link" mean here? 15:08:47 noamr: you have to intercept all your navigations to do this, and you have to clean up after yourself. in cross document navigations, for example 15:09:12 noamr: you might not have a js handle after the navigation. when do you clean up your state? you probably dont, and then if you restore from bfcache, your new style shows some exiting ui 15:09:31 noamr: youre showing some exiting the ui and youre back with bfcache and didn't clean up the animation, and now youre showing this exit ui 15:09:51 noamr: a big use case were working on right now is something that was requested around cross document view transition, i call it two phase view transitions 15:10:04 noamr: people want view transitions to start immediately, but we dont have the end state because we didn't load the new document yet 15:10:27 noamr: we want to use routes so that we can say you can style something like the new document, like a skeleton, create a frame and start to present that 15:10:35 noamr: some people are doing that already 15:10:42 noamr: here is a demo that some css teachers were using 15:11:31 noamr: from the problem to the solution, why dont we put a bunch of url patterns in css and have transitions from that url pattern to this one should behave that way 15:11:43 noamr: that never felt right to me, that a stylesheet should know the navigation url patterns, those can often change 15:11:55 noamr: something so style aware, feels like html or the document should know about it than a stylesheet 15:12:09 noamr: having this can open opportunities in the future that are about ui, not specifically about styling 15:12:28 noamr: the same way we can invoke a dialog open from a button maybe we can invoke it from a link that changes your url, and that url is somehow bound to the dialog 15:12:43 noamr: maybe we can allow scrolling to an element based on path, so that the url change can also apply 15:13:04 noamr: we can have all kinds of interceptions, spa style processes done in the browser rather than in userland 15:13:15 noamr: if all it does is change style, then maybe you dont need code that intercepts the navigation event 15:13:45 noamr: not things we intend to pursue at this moment, but reasoning to have an html representation of roots and using css to style it 15:14:00 noamr: the way we thought to have a script type that is like json, call it routemap 15:14:20 noamr: the main basic thing it does is naming url patterns or combinations of url patterns, so they can be used in css 15:14:33 noamr: later on can be used to create those html ui navigation roles if we decide to do that 15:14:46 noamr: the naming and combination we try as much as possible to be consistent with service worker static routing 15:14:54 noamr: this cant be done in a service worker because navigation is done in the window 15:15:13 keithamus: is there a good reason to have the route map defined in html rather than using css as the language to describe this? 15:15:29 noamr: its one of the alternatives. you mean have it as an html thing but css as the definition language? 15:15:42 keithamus: idk why we have to specify the patterns and roles in html if you also need them in css 15:16:09 noamr: thats one of the options. i think what was strange about it is more of a stylesheet lifecycle. it probably needs to be a script in terms of what it can do if we later connect it to html things 15:16:24 noamr: the precedent for something defined in css but accessible from html is using fonts in canvas, for example 15:16:37 noamr: but it feels a bit different, routes seem more like an html native thing than a style native thing 15:16:44 noamr: using css as a DSL for it seems ok 15:17:06 dbaron: one of the things noam was saying is that it isn't in this proposal right now but using this for more html features in the future that are not as tied to css 15:17:32 keithamus: do the two need to live together? do we need an intrinsic coupling or can we have them as discrete features where one is focused on styling and the other is focused on html? 15:17:55 I think you could do both. Define a "routemap" script type, use CSS syntax so it's easier to use, and allow it to be put into