Eyeglass import, `$do`, and `font()`
Pre-release
Pre-release
- NEW: Add
_index.scssto simplify default "tools" import (core + plugins) in Eyeglass:@import 'accoutrement'; - Core:
- NEW:
get-token()andratio()functions accept$doargument, for on-the-fly adjustments - NEW:
trim($string)utility now available in map-syntax, to trim white-space from the start and end of a string - NEW:
str-replace()utility now forces arguments tostring-type when appropriate, allowing e.g.calc(16px + 1vw) ('str-replace': 1vw 2vw)
- NEW:
- Plugin: Animate
- NEW:
change(),time(), andease()functions all accept$doarg for on-the-fly adjustments
- NEW:
- Plugin: Color
- BREAKING:
color()functions accept$doarg for on-the-fly adjustments – before existing$paletteargument
- BREAKING:
- Plugin: Layout
- NEW:
break()function accept$doarg for on-the-fly adjustments
- NEW:
- Plugin: Scale
- BREAKING:
size()function$units…variable argument has been replaced with$domap argument, for flexible on-the-fly adjustments. Non-map$dovalues are converted to('convert-units': $do)before processing, to provide a shortcut for unit-conversions.size('root', 'cm')will continue to work, butsize('root', 'em', 10px)should be changed tosize('root', 'em' 10px)(with all unit args in a single list)
- BREAKING:
- Plugin: Type
- BREAKING:
import-webfonts()mixin no longer accepts any arguments - NEW:
font()function provides access to parsed font-data - NEW:
'trim'string helper strips whitespace from the start and end of a string - NEW: Improved font-normalization handles more font-map edge-cases
- NEW: Font-stacks can be written as comma-delimited strings, e.g.
'Helvetica Neue, Helvetica, Arial'or'Helvetica Neue, Helvetica, Arial'
- BREAKING: