- Added support for any number of arguments to the
classes!
macro. It was previously limited to a maximum of 16 and didn't work for 0 or 1 arguments.
- Fix nightly
import_style
macro panic when it is run by rust analyzer (PR #4).
- Added support sass interpolation syntax in at rules and many other places.
- Added support for @container at rules
- Generated class name constants will now properly warn if they are unused.
- Added attributes syntax to
import_style!
andimport_crate_style!
macros.
- Add support for @layer at-rules
- Made the order in which the modified css modules are output be well defined; Sorted by (filename, relativepath). This is important for rules with equal specificity or for cascade layers defined in the css modules.
- Fixed the parser rejecting syntax of scss variable declarations (eg
$my-var: 10px;
).
- Added
hash_len
configuration option that controls the length of the hash in generated class names. - Added
class_name_pattern
configuration option to control the generated class name pattern. - Added detection of hash collisions to stylance cli, it will error when detected. This allows reducing the hash_len without fear of it silently colliding.
- Fixes cli watched folders not being relative to the manifest dir.
- Fixes cli watch mode not printing errors.
- Removes unused features from tokio dependency to improve compilation times.
- Added scss_prelude configuration option that lets you prefix text to the generated scss files.
- Added debouncing to the stylance cli --watch mode.
- Fixes an issue where stylance would read files while they were being modified by the text editor resulting in wrong output.
- Added classes! utility macro for joining class names
- Added JoinClasses trait
- Renamed
output
config option tooutput-file
- Added
output-dir
config option which generates one file per css module and an_index.scss
file that imports all of them. - Improved
import_style!
andimport_crate_style!
proc macros error reporting. - Added support for style declarations inside of media queries (useful for SASS nested media queries)
- Unknown fields in Cargo.toml
[package.metadata.stylance]
will now produce an error.