That selector is invalid. :last-child
is a pseudo-class there should only be one colon. ::after
denotes a pseudo-element but pseudo-elements cannot have any pseudo-classes - or any other attributes for that matter on their own. The way you have wrote the selector sort of implies "an ::after pseudo-element which also has :last-child
pseudo-class".
To make it valid you would write it like this .tabbrowser-tab:last-child::after
. However, a .tabbrowser-tab
will never be a last-child of its parent, because there will always be an after it. Luckily for you the node type of tabs is
so then you can use :last-of-type
instead of :last-child
. Technically it's not the same thing, but probably what you want.