Skip to content

Releases: sass/libsass

DeVille

26 Jan 01:57
Compare
Choose a tag to compare
DeVille Pre-release
Pre-release

Most of the work in this release was internal housekeeping which should result in a minor performance improvement.

See #2299 and #2300 for more details.

Fixes

  • Remove image-url function signature
  • Fix bug with nested @import (#2295)

DeVille

12 Jan 11:10
Compare
Choose a tag to compare
DeVille Pre-release
Pre-release

After 3 years we completed Sass 3.4 compatibility in December 2016.

A few short weeks later we're excited to announce our first beta release of the upcoming LibSass 3.5. Our emphasis will be on implementing Sass 3.5 features. You can read more about what's coming in Sass 3.5 on their blog.

This release is production ready however we cannot guarantee C ABI stability until 3.5.0 stable.

CSS Grid Layout

Thanks to hard work of @delapuente with support from @xzyfer we now have support for the new CSS Grid Layout syntax.

The new CSS Grid Layout module added a new type of syntax: identifiers surrounded by square brackets. We're always striving to be totally compatible with CSS, which meant we needed to support these brackets as well. Here's what they look like in CSS:

.container {
 grid-template-columns: [first] 40px [line2] 50px [line3] auto [col4-start] 50px [five] 40px [end];
 grid-template-rows: [row1-start] 25% [row1-end] 100px [third-line] auto [last-line];
}

The solution was clear: Sass already has a list data type, so we'd just allow lists to have square brackets. So [first] is just a list containing the unquoted string first. Like all Sass lists, bracketed lists can either be space-separated or comma-separated: [foo bar baz] and [foo, bar, baz] are both lists containing three elements.

We've also added function support for bracketed lists. Theis-bracketed($list) function returns whether a list is bracketed or not, and join() has a new $bracketed parameter that allows the caller to choose whether or not the resulting list will have brackets (by default, the result is bracketed if the first list is).

C ABI break

This release marks the first breaking change to the C ABI and a resulting ABI bump to 1:0:0. The sass_make_list function signature was update to support bracket lists.

-union Sass_Value* sass_make_list (size_t len, enum Sass_Separator sep);
+union Sass_Value* sass_make_list (size_t len, enum Sass_Separator sep, bool is_bracketed);

The resulting Sass_List struct also got a bool is_bracketed property.

Invert

The invert() function got support for the new $weight parameter thanks to @mgreter (#2273).

This is a percentage between 0% and 100% that indicates how inverted the resulting color should be. It defaults to 100%.

Add Sass call stack to the C API

It's now possible to query the the current mixin and function call stack from the C API. Now implementors can expose much more detailed information about the current execution environment. It's super cool, and we're excited to see what people do with it. Thanks @mgreter (#2251)

Check out the API docs for more information.

Features

The Bluesmobile

07 Jan 14:01
Compare
Choose a tag to compare

Fixes

Automobile

28 Dec 06:02
Compare
Choose a tag to compare

Better memory management

After a massive effort by @mgreter our memory management has been completely overhauled (#2222). Expect to see significantly less memory usage from now!

Features

  • Sass 3.4.23: Support url() with quotes in unknown directives (@mgreter, #2243)

Fixes

  • Test bootstrap ignoring SASS_SPEC_PATH and SASS_SASSC_PATH environment variables (@xzyfer, #2265)
  • Incorrect equality of interpolated values (@mgreter, #2261)
  • Incorrect error when @content is inside @at-root (@mgreter, #2260)
  • C-API copy_options function losing some options (@mgreter, #2257)
  • Segfault with calling calc (@mgreter, @xzyfer)

Ecto-1

19 Dec 11:30
Compare
Choose a tag to compare

Fixes

KITT

10 Dec 00:31
Compare
Choose a tag to compare

LibSass started almost 4 years ago with the singular goal to be a drop in
replacment for Ruby Sass. Since then @hcatlin, @akhleung, @mgreter, and @xzyfer
have been chasing the lofty goal of Sass 3.4. compatibility.

This release marks the completion of that major milestone, and we couldn't be
more excited to release LibSass 3.4 today! πŸŽ‰

Sass 3.4

Over the last couple years we've worked very closely with the Ruby Sass team to
reach Sass 3.4 compatibility.

It's become clear that need to draw a line in sand with exactly how exactly
we can match Sass 3.4, especially in the face of changes in Sass 3.5.

With this release the LibSass team is marking the completion of active
development on Sass 3.4 compatibility. From today we'll focus our efforts on
Sass 3.5 compatibility, first prioritising CSS compatibility features like
support for CSS custom property and CSS grids.

Improves to @at-root

@at-root has mostly worked since it's introduction to LibSass but there have
always been issue when it was combined with conditions (like @if) or mixins.
These issues were due to a fundamental difference in the LibSass implementation.
The difference has been addressed, so @at-root is now fully supported.

You can read more about the specifics of this issue in #2089

Delayed Values

Knowing when to evaluate a string, function, do concatenation, or perform math
is a complicated problem with many edge cases. @mgreter has continued his work
on improving the accuracy of these decisions.

Continued improvements to @extend

@extend is hard. With every release we get better at it and this release is no
exception.

Memory improvments

@mgreter has done some great work on improving our memory usage when dealing
with large maps, and lists. He's not done yet, keep your eyes peeled for further
improvments in upcomming releases.

  • Improve memory footprint when evaluating in loops (@mgreter, #2171)

Support list functions on maps

Implementing Sass maps was my first major contribution to LibSass. A couple
year later I can finally all the job complete with support for maps in list
functions.

Sourcemaps

@mgreter and @nschonni have made some significant improvements to our
sourcemaps. You can read more about the specifics in the bug links below.

  • Bugfixes for source maps (@mgreter, #2216)
    • Fixes parent selector mappings
    • Fixes media block/query mappings
    • Fixes range over binary expressions
    • Don't include semicolon for statics
    • Fixes variable assignment mappings
  • Make paths in source comments relative to CWD (@mgreter, #2219)
  • Implement source_map_file_urls option (@mgreter, #2220)
  • Re-order the sourcemap writing to match spec (@nschonni, #2193)

Features

Fixes

Misc

KITT

23 Oct 12:51
Compare
Choose a tag to compare
KITT Pre-release
Pre-release

See the 3.4.0 release notes for a full recap.

Features

Fixes

Misc

Herbie

23 Apr 09:07
Compare
Choose a tag to compare

I woke up this morning to an inbox full of gifts from @mgreter 🎁 πŸ™Œ

Feature

Fixes

General Lee

18 Apr 15:15
Compare
Choose a tag to compare

This is a modest release focused continues to address some regressions as well general improvements to @extend πŸš‘ with sprinkling of improvements to the C API πŸŽ‰

Expose our memory allocator

This feature has taken many proposed forms over the last 4 months. After much patent and considered discussion by @am11 @mgreter @saper and @xoofx you can now access our memory allocator on the C-API.

void* sass_alloc_memory(size_t size)
char* sass_copy_c_string(const char* str)
void sass_free_memory(void* ptr)

Features

  • Re-add sass_option_push_include_path and sass_option_push_plugin_path (@xoofx, #1974)

Build

Fixes

  • Incorrectly erring on @extend and @media (@mgreter, #2009 #2007, #1927, #1923)
  • Incorrectly erring on @extend and interpolated selectors (@mgreter, #2000)
  • Builds not failing when Sass spec fails to load (@saper, #1997)
  • Incorrectly erring on Sass comments in selectors (@mgreter, #1996)
  • Incorrectly erring on @extend and interpolated selectors with the !optional flag (@mgreter, #1993)
  • Incorrectly treating 0 and false as the same value when used as map keys (@mgreter, #1991)
  • Incorrectly erring on escaped and unicode selectors (@mgreter, #1977)
  • Incorrectly rendering @extend and @supports (@mgreter, #1971)
  • Incorrectly erring on functions beginning with calc (@mgreter, #1969)
  • Incorrectly quoting interpolated strings in selectors (@mgreter, #1947)
  • Incorrectly escaped escaped strings in selectors (@mgreter, #1945)
  • Incorrectly duplicating executing of function in interpolated string (@mgreter, #1944)
  • Prevent parsing url() resulting in an endless loop (@mgreter, #1931)
  • Compilation error with using -DDEBUG flag (@tony, #1917)
  • Incorrectly removing @media blocks that contain only CSS comments (@mgreter, #1889)
  • Better handling of / in function arguments (@mgreter, #1417)

Special thanks to @am11, @tony, @xoofx for their contributions to this release! πŸ‘

Christine

19 Mar 04:42
Compare
Choose a tag to compare

This is a modest release focused on addressing some regressions that popped up in the previous 3.3.3 release. πŸš‘

Fixes

  • Inconsistent error message produced when nesting functions and mixins (@xzyfer, #1941)
  • Ensure custom importers are executed for all @imports (@xzyfer, #1935)
  • Ensure custom importers are executed in the correct order (@xzyfer, #1921)
  • Possible segfault when generating sourcemaps (@usta, #1920)
  • Memory leak (@usta, #1919)
  • Unused variable warning (@xzyfer, #1918)
  • Segfaulting when @extending an undefined selector (@mgreter, #1916)
  • Incorrectly erring when @extending inside a mixin (@xzyfer, #1915)
  • Handle signed char when considering @charset (@asottile, #1914)
  • New link to sassc-ruby in documentation (@itkrt2y, #1910)
  • Incorrectly quoting interpolated strings join with + (@mgreter, #1907)
  • Incorrectly erring when using & and interpolation together (@xzyfer, #1904)
  • Incorrectly duplicating nested pseudo selectors (@mgreter, #1901)
  • Unused function breaking breaking unity builds (@drewwells, #1896)
  • Segfaulting when url() is empty (@xzyfer, #1886)
  • Should error when & is used without a parent selector (@xzyfer, #1644)

Special thanks to @asottile, @drewwells, @itkrt2y, @usta for their contributions to this release! πŸ‘

Upcoming version 3.3.5

We weren't able to get around the planned breaking changes to the C-API. This work will continue in 3.3.5.