顯示下列標籤的問題: 顯示所有問題
  • 被鎖定

Differences between implementation of :has between FF and Chrome.

FF bug (?) (my own tests), Chrome works as expected, was also gemini ai discussed.: Why for the following css rule (new FF): header:has(~ noscript) ~ * div[class*="-s… (閱讀更多)

FF bug (?) (my own tests), Chrome works as expected, was also gemini ai discussed.:

 Why for the following css rule (new FF):
 header:has(~ noscript) ~ * div[class*="-slider"] {width: calc(var(--number-of-slides) * 100%);}
 the --number-of-slides is defined and visible:
 header:has(~ noscript) ~ * div[class*="-slider"] {--number-of-slides: 1}
 but this one isn't at all:
 header:has(~ noscript:has([value="1"])) ~ * div[class*="-slider"] {--number-of-slides: 1}
 And all remembering that in the noscript there is direct descendant having value="1"

As mentioned it works as expected (so average person naturally may think it sould) well for Chrome - noscript is visible, js disabled, controls are visible. Sophisticated use case of :has() but it sort of "has right" to happen.

Sławomir Cwojdziński 於 2 個月前 詢問

Denys 最近回覆於 1 個月前