Closed Skyfold closed 1 month ago
I've added four simple tests in PseudoSpec.hs
There is one disadvantage to the current type class approach: if you write not ".test"
it is ambiguous if the ".test"
is a Selector
or a Refinement
.
Yes, that's a disadvantage. Recently, a similar issue was raised: https://github.com/sebastiaanvisser/clay/issues/241
This issue has not seen any activity in a long time. If no further activity occurs, it will be closed after ten weeks.
FYI, this can break existing code when the type for the selector is not explicit. For example,
img # (not ".keep-colors" <> "src" $= ".svg")
will now result in an ambiguous type.
This is not a big deal for me (I plan to simply add an explicit type annotation), but it should at least be mentioned in any release notes.
The
not
pseudo selector can only be applied to one argument at a time in most browsers, Safari seems to be the exception. The instance forNot Refinement
allows you to applyNot
to multiple arguments, however, there is no contaminator to combine twoRefinement
directly.