-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Normalize selector function input/output format specs (#1521)
Also add a missing named parameter spec for selector-extend()
- Loading branch information
Showing
4 changed files
with
136 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
<===> input/non_string/README.md | ||
These specs verify that all the arguments to `selector-extend()` can take the | ||
parsed selector format, and that the function returns a selector in that format. | ||
The full set of possible input formats is tested with `selector-parse()`; this | ||
spec just verifies one example for each parameter. | ||
|
||
<===> | ||
================================================================================ | ||
<===> input/non_string/selector/input.scss | ||
a {b: selector-extend((c, d c), "c", "e")} | ||
|
||
<===> input/non_string/selector/output.css | ||
a { | ||
b: c, e, d c; | ||
} | ||
|
||
<===> | ||
================================================================================ | ||
<===> input/non_string/extendee/options.yml | ||
--- | ||
:todo: | ||
- sass/libsass#3068 | ||
|
||
<===> input/non_string/extendee/input.scss | ||
a {b: selector-extend("c.d", (c, ".d"), ".e")} | ||
|
||
<===> input/non_string/extendee/output.css | ||
a { | ||
b: c.d, .e; | ||
} | ||
|
||
<===> | ||
================================================================================ | ||
<===> input/non_string/extender/input.scss | ||
a {b: selector-extend("c", "c", (d, e f))} | ||
|
||
<===> input/non_string/extender/output.css | ||
a { | ||
b: c, d, e f; | ||
} | ||
|
||
<===> | ||
================================================================================ | ||
<===> input/multiple_extendees/compound/input.scss | ||
a {b: selector-extend("c.d", "c.d", ".e")} | ||
|
||
<===> input/multiple_extendees/compound/output.css | ||
a { | ||
b: c.d, .e; | ||
} | ||
|
||
<===> | ||
================================================================================ | ||
<===> input/multiple_extendees/list/options.yml | ||
--- | ||
:todo: | ||
- sass/libsass#3067 | ||
|
||
<===> input/multiple_extendees/list/input.scss | ||
a {b: selector-extend("c.d", "c, .d", ".e")} | ||
|
||
<===> input/multiple_extendees/list/output.css | ||
a { | ||
b: c.d, .e; | ||
} | ||
|
||
<===> | ||
================================================================================ | ||
<===> input/multiple_extendees/list_of_compound/options.yml | ||
--- | ||
:todo: | ||
- sass/libsass#3067 | ||
|
||
<===> input/multiple_extendees/list_of_compound/input.scss | ||
a {b: selector-extend("c.d.e.f", "c.d, .e.f", ".g")} | ||
|
||
<===> input/multiple_extendees/list_of_compound/output.css | ||
a { | ||
b: c.d.e.f, .g; | ||
} | ||
|
||
<===> | ||
================================================================================ | ||
<===> output/input.scss | ||
$result: selector-extend("c d, e f", "g", "g"); | ||
a { | ||
result: $result; | ||
structure: $result == ("c" "d", "e" "f"); | ||
} | ||
|
||
<===> output/output.css | ||
a { | ||
result: c d, e f; | ||
structure: true; | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<===> input.scss | ||
a {b: selector-extend($selector: "c.d", $extendee: "c", $extender: "e")} | ||
|
||
<===> output.css | ||
a { | ||
b: c.d, e.d; | ||
} |