Skip to content

Releases: ghivert/sketch

v3.1.0

17 Sep 16:43
83d90a6
Compare
Choose a tag to compare

What's Changed

  • Add Redraw Sketch by @ghivert in #25
  • Add initial transform API by @joseemds in #23
  • Fix correct signature for cache on Erlang target by @ghivert in #26
  • Remove fold_right functions to avoid stack overflows on JS by @ghivert in #27

New Contributors

Full Changelog: v3.0.2...v3.1.0

v3.0.2

10 Aug 14:12
676ae30
Compare
Choose a tag to compare

What's Changed

  • Hide the Erlang target on JS. Fix bug where the JS target was not able to compile.

Full Changelog: v3.0.1...v3.0.2

v3.0.1

10 Aug 14:12
c95b621
Compare
Choose a tag to compare

What's Changed

  • fix: size.percent_ return Pct instead of Px by @kwshi in #22
  • Add ephemeral caches on BEAM by @ghivert in #24. Sketch is now usable in the exact same way on the Erlang target as well as on the JS target.

New Contributors

  • @kwshi made their first contribution in #22

Full Changelog: v3.0.0...v3.0.1

v3.0.0

05 Aug 12:46
1bde2ce
Compare
Choose a tag to compare

3.0.0 — New Major Version 🎉

Sketch undergo a major rewrite, switching from being a Lustre-focused package, to a generic CSS-in-Gleam package. Sketch is now split across multiple packages: sketch, sketch_css & sketch_lustre.
Inspired by Gleam, Sketch has now an agnostic core, able to target any project and any compile target, and has few packages specialised for frameworks and libraries to integrate it in a transparent way! This step starts first with the split of Lustre features from the core to its own package, sketch_lustre. This change should help building on top of Sketch, and allow everyone to use the package, in the way they like. Sketch favours diversity!

Changes

  • Deprecations are removed.
  • Remove the mechanism of "virtual stylesheet", because browsers optimise for static CSS. Every class pushed in Cache is now memoised.
  • Add every possible non-experimental CSS properties.
  • Split Lustre bits to sketch_lustre.
  • sketch_css allows to generate a CSS stylesheet from Sketch styles.
  • Class ID change from guess (with magic) to string.inspect (without magic, in a deterministic way). Overhead is really low (few milliseconds at most).
  • sketch.Class now contains its string representation, allowing for quicker lookup in cache.
  • Lustre mechanism switch from injecting styles in globalised Cache to an additional tree walk before render (like elm-css). This is transparent for the user, and should not be felt as a change anyway (time to render differs from a bunch of milliseconds).

Full Changelog: v2.3.0...v3.0.0

v2.3.0

10 Jul 10:12
7b0a02f
Compare
Choose a tag to compare

What's Changed

  • Add the utility functions in sketch/lustre/element to create easily view functions in Lustre, Sketch-enhanced!

Full Changelog: v2.2.2...v2.3.0

v2.2.2

10 Jul 10:11
f8b1915
Compare
Choose a tag to compare

What's Changed

  • Fix another bug with the class name generation.

Full Changelog: v2.2.1...v2.2.2

v2.2.1

10 Jul 10:10
f2543de
Compare
Choose a tag to compare

What's Changed

  • Small bugfix on class name generation to push in the virtual stylesheet.

Full Changelog: v2.2.0...v2.2.1

v2.2.0

01 May 20:55
9d95fdf
Compare
Choose a tag to compare

What's Changed

  • A tiny release, including the missing property float!

Full Changelog: v2.1.0...v2.2.0

v2.1.0

19 Apr 16:04
771d414
Compare
Choose a tag to compare

Improvements

Sketch now targets BEAM as well as JS! This is a major milestone, and unlocks new possibilities. Some bugs can still be hidden in the BEAM codebase, so open an issue for anything! But sketch can now become the ultimate CSS-in-Gleam tool, to help building UI better than ever!

What's Changed

  • class does not memo by default anymore. memo should be used on selected class, to have a more lightweight stylesheet transmitted in server components. This can reduce the output bandwidth.
  • sketch can be used on BEAM target, with both SSR, pure gleam or lustre!
  • More documentation added
  • Most of the transform code has been rewrote in gleam, reducing the JS part
  • Cache algorithm has been ported to gleam

Full Changelog: v2.0.0...v2.1.0

v2.0.0

15 Apr 16:14
8ee467d
Compare
Choose a tag to compare

What's Changed

  • Add support for Shadow DOM
  • Add size support for border-radiuses
  • Improve setup with lustre

Breaking Changes

  • border_top_right_radius -> border_top_right_radius_
  • border_top_left_radius -> border_top_left_radius_
  • border_bottom_right_radius -> border_bottom_right_radius_
  • border_bottom_left_radius -> border_bottom_left_radius_