tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

animation-name-in-shadow-part.html (817B)


      1 <!DOCTYPE html>
      2 <html>
      3 <head>
      4 <title>Matching animation-name from within a shadow root with a single @keyframes rule in the outer scope</title>
      5 <link rel="author" title="Antoine Quint" href="mailto:graouts@webkit.org">
      6 <link rel="help" href="https://bugs.webkit.org/show_bug.cgi?id=296048">
      7 <link rel="help" href="https://drafts.csswg.org/css-scoping-1/#shadow-names">
      8 <link rel="match" href="animation-name-in-shadow-part-ref.html">
      9 </head>
     10 <body>
     11 
     12 <style>
     13 
     14 #shadow {
     15  width: 100px;
     16  height: 100px;
     17 }
     18 
     19 @keyframes animation {
     20  from, to { background-color: green }
     21 }
     22 
     23 #shadow::part(target) {
     24  height: 100px;
     25  width: 100px;
     26  animation: animation 1s both;
     27  background-color: red;
     28 }
     29 
     30 </style>
     31 
     32 <div id="shadow">
     33  <template shadowrootmode="open">
     34    <div part="target"></div>
     35  </template>
     36 </div>
     37 
     38 </body>
     39 </html>