I’m replacing an html table with css ‘display’ properties (table, table-row, etc). (If I need to change the title, will do).
Is there a way to select in CSS by the display property?
Can’t find any info on this.
How to make this valid?:
.myClass[display=table-cell]
This isn’t possible, you can select by attributes, and their values, but not by CSS properties. Nor do I think it would make sense to do so, since the selector could easily be invalidated by the style-rules applied to the selected element(s), if such existed, leading to incredibly complex CSS parsing rules and, potentially, infinite loops.
It is possible to achieve something similar, with JavaScript, but definitely not with just CSS.
References: