1919// **Jumpable**
2020// Any terminal element may "jump" over combinators when moving to the end of the selector
2121//
22- // This is a backwards-compat quirk of :before and :after variants.
22+ // This is a backwards-compat quirk of pseudo element variants from earlier versions of Tailwind CSS .
2323
2424/** @typedef {'terminal' | 'actionable' | 'jumpable' } PseudoProperty */
2525
2626/** @type {Record<string, PseudoProperty[]> } */
2727let elementProperties = {
28+ // Pseudo elements from the spec
2829 '::after' : [ 'terminal' , 'jumpable' ] ,
2930 '::backdrop' : [ 'terminal' , 'jumpable' ] ,
3031 '::before' : [ 'terminal' , 'jumpable' ] ,
@@ -41,18 +42,14 @@ let elementProperties = {
4142 '::spelling-error' : [ 'terminal' ] ,
4243 '::target-text' : [ 'terminal' ] ,
4344
44- // other
45+ // Pseudo elements from the spec with special rules
4546 '::file-selector-button' : [ 'terminal' , 'actionable' ] ,
46- '::-webkit-progress-bar' : [ 'terminal' , 'actionable' ] ,
4747
48- // Webkit scroll bar pseudo elements can be combined with user-action pseudo classes
49- '::-webkit-scrollbar' : [ 'terminal' , 'actionable' ] ,
50- '::-webkit-scrollbar-button' : [ 'terminal' , 'actionable' ] ,
51- '::-webkit-scrollbar-thumb' : [ 'terminal' , 'actionable' ] ,
52- '::-webkit-scrollbar-track' : [ 'terminal' , 'actionable' ] ,
53- '::-webkit-scrollbar-track-piece' : [ 'terminal' , 'actionable' ] ,
54- '::-webkit-scrollbar-corner' : [ 'terminal' , 'actionable' ] ,
55- '::-webkit-resizer' : [ 'terminal' , 'actionable' ] ,
48+ // Library-specific pseudo elements used by component libraries
49+ // These are Shadow DOM-like
50+ '::deep' : [ 'actionable' ] ,
51+ '::v-deep' : [ 'actionable' ] ,
52+ '::ng-deep' : [ 'actionable' ] ,
5653
5754 // Note: As a rule, double colons (::) should be used instead of a single colon
5855 // (:). This distinguishes pseudo-classes from pseudo-elements. However, since
@@ -65,8 +62,8 @@ let elementProperties = {
6562
6663 // The default value is used when the pseudo-element is not recognized
6764 // Because it's not recognized, we don't know if it's terminal or not
68- // So we assume it can't be moved AND can have user-action pseudo classes attached to it
69- __default__ : [ 'actionable' ] ,
65+ // So we assume it can be moved AND can have user-action pseudo classes attached to it
66+ __default__ : [ 'terminal' , ' actionable'] ,
7067}
7168
7269/**
0 commit comments