mirror of
https://github.com/sass/sass.git
synced 2024-09-21 02:27:30 +00:00
[Forward With] Only !default variables defer to outer configuration (#2785)
This commit is contained in:
parent
338532b487
commit
57792117aa
3
accepted/forward-with.changes.md
Normal file
3
accepted/forward-with.changes.md
Normal file
@ -0,0 +1,3 @@
|
||||
## Draft 1.1
|
||||
|
||||
* Only `!default` variables defer to the pre-existing configuration.
|
@ -1,6 +1,7 @@
|
||||
# Reconfigurable Modules: Draft 1
|
||||
# Reconfigurable Modules: Draft 1.1
|
||||
|
||||
*([Issues](https://github.com/sass/sass/issues/2744))*
|
||||
*([Issues](https://github.com/sass/sass/issues/2744),
|
||||
[Changelog](forward-with.changes.md))*
|
||||
|
||||
## Table of Contents
|
||||
|
||||
@ -190,15 +191,14 @@ Given a source file `file`, a configuration `config`, and an import context
|
||||
|
||||
* For each `ForwardWithArgument` `argument` in this clause:
|
||||
|
||||
* If a variable exists in `rule-config` with the same name as `argument`'s
|
||||
identifier, do nothing.
|
||||
* If `argument` has a `!default` flag and a variable exists in
|
||||
`rule-config` with the same name as `argument`'s identifier, do nothing.
|
||||
|
||||
* Otherwise:
|
||||
* Otherwise, let `value` be the result of evaluating `argument`'s
|
||||
expression.
|
||||
|
||||
* Let `value` be the result of evaluating `argument`'s expression.
|
||||
|
||||
* Add a variable to `rule-config` with the same name as `argument`'s
|
||||
identifier, and with `value` as its value.
|
||||
* Add a variable to `rule-config` with the same name as `argument`'s
|
||||
identifier, and with `value` as its value.
|
||||
|
||||
* Let `forwarded` be the result of [loading][] the module with `rule`'s URL
|
||||
and `rule-config`.
|
||||
|
Loading…
Reference in New Issue
Block a user