You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* package – update css-compile script to use --math
--strict-math has been deprecated and replaced by --math. See less/less.js#3274
* maps – begin converting to DRs
* each – use each() for loops (WIP)
Still haven't updated for the grid breakpoints just yet, though some breakpoint loops have been written in anticipation of those updates.
* breakpoints – fix breakpoint JS after converting to DR maps
* each – replace all #each-* loop with each or #for-*
There are 4 loops in mixins/_grid-framework.less that loop 'til a static number. I'm not aware of any answer for that at the moment, but a plugin could be easily written that could just leverage `each()`.
* dev, meta – steal nice stuff from #12
Thanks @matthew-dean!
* plugins – fix lint warnings/errors
Except one in breakpoints.js:
```
91:6 warning Variable 'nextBreakpoint' should be initialized on declaration
```
* _tables – fix .table-responsive output order
See less/less.js#3340
* _navbar – fix .navbar-expand output order
See less/less.js#3340
* README – update to match true min version required
Co-Authored-By: calvinjuarez <[email protected]>
* plugins/theme-color-level – more readable code
Co-Authored-By: calvinjuarez <[email protected]>
* README – replace the other, less easy ways of installing
* _grid-framework – restore comment
See #14 (comment)
* README – wording edits
Co-Authored-By: calvinjuarez <[email protected]>
* _functions – restore commented Sass
* README – more wording edits
Co-Authored-By: calvinjuarez <[email protected]>
* README – remove clone note
per #14 (comment)
* plugins/breakpoints – remove parseUnit(); fix nextBreakpoint ESLint issue
See https://github.com/seanCodes/bootstrap-less-port/pull/14/files/94a03d156dde954caccf58130ebc8fa3adaf397e#r240023403
* rename plugin `keys` → `map-keys`
Reverting the name change for now, until @calvinjuarez is able to pull
in the plugin from NPM and alias it. (See [his
comment](#14 (comment)
sion_r241965904).)
This change addresses [this PR review
comment](#14 (comment)
sion_r239916331).
* _grid-framework – revert loop renaming
Reduce the number of changes in the PR to avoid potential bugs.
This change addresses [this PR review comment](#14 (comment)).
* _transition – revert var renaming
Match var names used in the Sass version of the mixin.
This change addresses [this PR review comment](#14 (comment)).
* breakpoints – put long comments on own line
(instead of including at the end of a line)
* restore color-function plugins
Revert deletion of plugin files that add the `color()`, `gray()` and
`theme-color()` functions. Even though Less’ new ruleset accessors could
be used, we’re going to keep them for parity with the Sass version and
for backwards compatibility.
This change addresses [this PR review comment](#14).
* restore usages of color functions
Revert the conversion the `color()`, `gray()` and `theme-color()`
functions to Less’ ruleset accessors. This change is primarily being
made to keep the syntax as similar to the Sass version as possible, for
easy reference/comparison.
Note that keeping things similar to Sass may prove unnecessary in the
future, so we may go back to accessors, but for now we’ll keep it like
this.
This change addresses [this PR review comment](#14).
* change color functions to handle rulesets vs lists
* fix bug in ruleset-to-map conversion
Instead of pulling the `value` directly from each item in the ruleset,
evaluate the item first to determine the true value of the item. This
fixes the issue where the `value` is actually a var name and what we
want is the the value of the var—not the var name itself.
This approach is recommended since it will result in a smaller CSS file by omitting the styles you don’t need. (Just be aware that some files are dependent on others.)
59
59
60
-
Alternatively, you can get the entire framework by importing the main `bootstrap.less` file:
60
+
Alternatively, you can get the entire framework by simply importing the package as a whole. (Or, if not using a package manager, importing `bootstrap-less-port/less/bootstrap` instead.)
If you’re using `lessc` on the command line, you can use [`less-plugin-npm-import`](https://github.com/less/less-plugin-npm-import) to import the files in a much cooler and more maintainable way. Just install the plugin via npm and then reference the Bootstrap Less files using the plugin’s default `npm://` prefix:
@@ -124,9 +110,7 @@ This port attempts to mirror the source Sass files as closely as possible in ord
124
110
125
111
Note: The plugins are included using the [`@plugin`](http://lesscss.org/features/#plugin-atrules-feature) at-rule instead of as arguments to the `lessc` CLI. This was intentionally done since most Less GUI compilers don’t allow you to customize the command-line arguments.
126
112
127
-
0.**Maps** Less has no _native_ concept of maps, which are used extensively in the Bootstrap Sass files. They can be emulated, however, by using a comma-separated list of space-separated lists, which is what is done in this port.
128
-
129
-
0.**Loops** Sass `@for` and `@each` loops have been replaced with Less’s method of looping which requires unique, named mixins for every loop. This is a bit clunky and means that the loops used in this port are verbose and difficult to read, but it’s the best we’ve got until I can figure out how to overcome this with a plugin.
113
+
0.**Loops** Where possible, Sass `@each` loops have been replaced with the Less `each()` function. Sass `@for` directives are trickier and have no direct Less analog (yet), so they are replaced with the old Less method of looping, which requires a unique, named mixin for every loop. This is a bit clunky, and means that in some places, loops are verbose and difficult to read, but it’s the best we’ve got until we figure out how to do this with a plugin (or Less adds a native equivalent).
130
114
131
115
In order to make catching bugs easier, the Sass versions of most for/each loops have been kept in the code, commented, above the Less versions.
0 commit comments