@annevk@hachyderm.io
@annevk@hachyderm.io avatar

annevk

@annevk@hachyderm.io

Web Standards Engineer

This profile is from a federated server and may be incomplete. Browse more on the original instance.

annevk, to random
@annevk@hachyderm.io avatar

Wrote a short blog post about how URL parser inputs that start with a scheme can still be relative due to a weird quirk: https://annevankesteren.nl/2024/05/undue-base-url-influence

tomayac, to random
@tomayac@toot.cafe avatar

The nuances of base64-encoding: https://web.dev/articles/base64-encoding. One for the bookmarks! And maybe there should just be non-ASCII-friendly variants of btoa() and atob() in the JavaScript language!? The closest seems this ECMAScript proposal: https://github.com/tc39/proposal-arraybuffer-base64.

annevk,
@annevk@hachyderm.io avatar
pepelsbey, to random
@pepelsbey@mastodon.social avatar

You can scope styles inside of the parent with a <style> and a @​scope rule 😳

<div>
<style>
@​scope {
p { color: red }
}
</style>
<p>this is red</p>
</div>
<p>not red</p>

See the CSS Cascading and Inheritance L6 draft
https://drafts.csswg.org/css-cascade-6/#example-52419898

It’s not just a fantasy, it already works in Chrome Canary. Thanks to @kizu for the tip!

annevk,
@annevk@hachyderm.io avatar

@pepelsbey @mia @keithjgrant Well, conformance requirements are not the same as implementation requirements. And also, it seems like allowing it without some constraints might lead to folks using it in the wrong way. So this could probably be changed, but it would need some care. (We could also try to bring the scoped attribute back...)

annevk,
@annevk@hachyderm.io avatar

@tomayac @pepelsbey @mia @keithjgrant Just an observation that it might be easier to revive now.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • provamag3
  • thenastyranch
  • magazineikmin
  • InstantRegret
  • GTA5RPClips
  • ethstaker
  • Youngstown
  • everett
  • slotface
  • osvaldo12
  • rosin
  • mdbf
  • kavyap
  • DreamBathrooms
  • megavids
  • ngwrru68w68
  • Durango
  • modclub
  • cubers
  • khanakhh
  • Leos
  • tacticalgear
  • cisconetworking
  • vwfavf
  • tester
  • anitta
  • normalnudes
  • JUstTest
  • All magazines