breakpoint-sass
Advanced tools
Comparing version 2.7.1 to 3.0.0
# Changelog | ||
## 3.0.0 | ||
* **Deprecation** - Dropped Ruby, Eyeglass, Bower, and Sache support | ||
* **Fix** - Fix `math.div` warnings | ||
* **Change** - Sass 1.25+ is now a peer dependency | ||
## 2.6.0 | ||
@@ -4,0 +9,0 @@ * **Change** Moved variable settings to new Breakpoint settings. Future versions will deprecate variable settings. Use `@include breakpoint-set()` or `@include bkpt-set()` to change settings, `@include breakpoint-reset()` or `@include bkpt-reset()` to reset settings to their default state. Please update your settings as followins: |
{ | ||
"name": "breakpoint-sass", | ||
"version": "2.7.1", | ||
"version": "3.0.0", | ||
"description": "Really Simple Media Queries with Sass", | ||
"main": "stylesheets/_breakpoint.scss", | ||
"eyeglass": { | ||
"needs": "^1.0.0", | ||
"exports": "eyeglass-exports.js", | ||
"name": "breakpoint" | ||
}, | ||
"directories": { | ||
"test": "tests" | ||
"stylesheets": "stylesheets" | ||
}, | ||
@@ -18,15 +13,10 @@ "keywords": [ | ||
"rwd", | ||
"eyeglass-module", | ||
"breakpoint" | ||
], | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1", | ||
"bump:major": "node .bump.js --major", | ||
"bump:minor": "node .bump.js --minor", | ||
"bump:patch": "node .bump.js --patch", | ||
"publish": "node .gembuild.js && git push && git push origin --tags" | ||
"test": "ava tests/index.js" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/Team-Sass/breakpoint.git" | ||
"url": "https://github.com/at-import/breakpoint.git" | ||
}, | ||
@@ -36,14 +26,15 @@ "author": "", | ||
"bugs": { | ||
"url": "https://github.com/Team-Sass/breakpoint/issues" | ||
"url": "https://github.com/at-import/breakpoint/issues" | ||
}, | ||
"homepage": "https://github.com/Team-Sass/breakpoint", | ||
"homepage": "https://github.com/at-import/breakpoint", | ||
"devDependencies": { | ||
"diff": "^1.2.1", | ||
"fs-extra": "^0.14.0", | ||
"glob": "^4.3.2", | ||
"node-sass": "^3.0.0", | ||
"nodegit": "^0.11.2", | ||
"semver": "^5.1.0", | ||
"yargs": "^4.1.0" | ||
"ava": "^4.3.1", | ||
"diff": "^5.1", | ||
"fs-extra": "^10.1", | ||
"glob": "^8.0", | ||
"sassy-maps": "github:at-import/Sassy-Maps" | ||
}, | ||
"peerDependencies": { | ||
"sass": "^1.25" | ||
} | ||
} |
@@ -1,3 +0,5 @@ | ||
# Breakpoint [![Gem Version](https://badge.fury.io/rb/breakpoint.png)](http://badge.fury.io/rb/breakpoint) [![Build Status](https://travis-ci.org/Team-Sass/breakpoint.png)](https://travis-ci.org/Team-Sass/breakpoint) | ||
# Breakpoint ![npm version](https://badge.fury.io/js/breakpoint-sass.svg) ![downloads per week](https://img.shields.io/npm/dw/breakpoint-sass) ![test status](https://github.com/at-import/breakpoint/actions/workflows/test.yml/badge.svg) | ||
**Really Simple Media Queries with Sass** | ||
@@ -7,5 +9,5 @@ | ||
Breakpoint also allows you to get the [context of your media queries](https://github.com/Team-Sass/breakpoint/wiki/Breakpoint-Context) from your code, allowing you to write dynamic mixins based on their media query context. | ||
Breakpoint also allows you to get the [context of your media queries](https://github.com/at-import/breakpoint/wiki/Breakpoint-Context) from your code, allowing you to write dynamic mixins based on their media query context. | ||
If you'd prefer the semantic awesomeness of string names to identify your queries as opposed to variables, or want to dynamically generate media queries, the [Respond-To](https://github.com/Team-Sass/breakpoint/wiki/Respond-To) syntax is now included in Breakpoint core! | ||
If you'd prefer the semantic awesomeness of string names to identify your queries as opposed to variables, or want to dynamically generate media queries, the [Respond-To](https://github.com/at-import/breakpoint/wiki/Respond-To) syntax is now included in Breakpoint core! | ||
@@ -15,3 +17,3 @@ **It is important to note** that due to limitations within the Sass language itself, which themselves stem from some potentially unexpected cascading from doing so, Breakpoint is unable to concat like media queries into a single media query. This means they will be spread out throughout your CSS. This is unfortunate, yes, but currently unavoidable. That being said, once [Sass Issue #241: Seperate Media/Browser Specific Markup to Separate Style Sheet](https://github.com/nex3/sass/issues/241) hits, be sure we're going to take full advantage of it. | ||
## Full documentation is available on the [Breakpoint Wiki](https://github.com/Team-Sass/breakpoint/wiki) | ||
## Full documentation is available on the [Breakpoint Wiki](https://github.com/at-import/breakpoint/wiki) | ||
@@ -21,3 +23,3 @@ ## Getting Help with Breakpoint | ||
* For help with Breakpoint, please ask a question on [Stack Overflow](http://stackoverflow.com/questions/ask) tagged with "breakpoint-sass". | ||
* To file an issue with Breakpoint, be it a feature request or a bug report, please use our [Issue Queue](https://github.com/Team-Sass/breakpoint/issues). | ||
* To file an issue with Breakpoint, be it a feature request or a bug report, please use our [Issue Queue](https://github.com/at-import/breakpoint/issues). | ||
* **Each Separate Bug Report or Feature Request Must Have Its Own Issue** | ||
@@ -29,19 +31,9 @@ * Search in both active issues and closed issues before filing your own. If one already exists, please respond there. | ||
We love contributors! Yes we do! If you would like to contribute to Breakpoint, please follow the [Contributing Guidelines](https://github.com/Team-Sass/breakpoint/blob/2.x.x/CONTRIBUTING.md) | ||
We love contributors! Yes we do! If you would like to contribute to Breakpoint, please follow the [Contributing Guidelines](https://github.com/at-import/breakpoint/blob/main/CONTRIBUTING.md) | ||
## Awesome Things Built With Breakpoint | ||
Breakpoint is designed to be a Media Query engine to power everything from design tweaks to media query contexts to full media query fallbacks. But we also know that our users will build awesome thing with these tools. Build a Breakpoint powered mixin for new media query semantics? We want to hear about it! Build something cool with Context? Let us know! If you would like to add your Awesome Thing to the list, please issue a Pull Request to add it! | ||
* [Singularity](https://github.com/Team-Sass/Singularity) - Semantic Grid System | ||
* [Breakpoint Slicer](https://github.com/lolmaus/breakpoint-slicer) - Quick and efficient syntax for Min/Max Width media queries | ||
## License | ||
Licensed under MIT/GPL. | ||
Licensed under MIT | ||
GPL2 license: | ||
http://www.gnu.org/licenses/gpl-2.0.html | ||
MIT license: | ||
http://www.opensource.org/licenses/mit-license.php |
@@ -1,60 +0,33 @@ | ||
var sass = require('node-sass'), | ||
jsdiff = require('diff'), | ||
fs = require('fs-extra'), | ||
i = 0, | ||
glob = require('glob'); | ||
const test = require('ava'); | ||
const sass = require('sass'); | ||
const {readFileSync} = require('fs'); | ||
const path = require('path'); | ||
const glob = require('glob'); | ||
const {pathToFileURL} = require('url'); | ||
glob('./tests/**/*.scss', function (err, files) { | ||
if (err) throw err; | ||
const tests = glob.sync(path.join(__dirname, './tests/**.scss')).filter(file => !path.basename(file).startsWith('_')); | ||
files.forEach(function (file) { | ||
if (file.charAt(0) !== '_') { | ||
sass.render({ | ||
file: file, | ||
outputStyle: 'expanded', | ||
includePaths: [ | ||
'../stylesheets/', | ||
'../vendor/ruby/2.0.0/gems/sassy-maps-0.4.0/sass/', | ||
'../vendor/ruby/2.0.0/gems/breakpoint-2.5.0/stylesheets/' | ||
] | ||
}, function(err, result) { | ||
if (err) throw err; | ||
async function testMacro(t, file) { | ||
const css = sass.compile(file, { | ||
importers: [{ | ||
findFileUrl(url) { | ||
if (url.startsWith('breakpoint')) { | ||
return new URL(url, pathToFileURL(path.join(process.cwd(), 'stylesheets/')));; | ||
} else if (url === 'memo' || url.startsWith('sassy-maps')) { | ||
return new URL(url, pathToFileURL(path.join(process.cwd(), 'node_modules/sassy-maps/sass/'))); | ||
} | ||
// console.log(result); | ||
var file = result.stats.entry.split('/'); | ||
return null; | ||
} | ||
}] | ||
}); | ||
file = file[file.length - 1]; | ||
file = file.replace('.scss', '.css'); | ||
const cssFile = file.replace('.scss', '.css').replace('/tests/tests/', '/tests/controls/'); | ||
const expected = readFileSync(cssFile, 'utf8'); | ||
t.is(css.css + '\n', expected); | ||
} | ||
if (file.charAt(0) !== '_') { | ||
fs.readFile('./controls/' + file, function (ctrlErr, ctrlFile) { | ||
var diff = jsdiff.diffCss(ctrlFile.toString(), result.css.toString()), | ||
diffCount = 0; | ||
diff.forEach(function(part){ | ||
// green for additions, red for deletions | ||
// grey for common parts | ||
var color = part.added ? 'green' : | ||
part.removed ? 'red' : 'grey'; | ||
if (color !== 'grey') { | ||
diffCount++; | ||
} | ||
}); | ||
if (diffCount) { | ||
console.log(file); | ||
diff = jsdiff.createPatch(file, ctrlFile.toString(), result.css.toString()); | ||
fs.outputFile('./diff/' + file + '.diff', diff, function (writeErr, writePatch) { | ||
if (writeErr) throw writeErr; | ||
// throw 'Diff in output for ' + file; | ||
}); | ||
} | ||
}); | ||
} | ||
}); | ||
} | ||
}); | ||
}); | ||
for (const testFile of tests) { | ||
test(path.basename(testFile).replace(/(\n*)_/, ' ').replace('.scss', '').replace(/_/g, ' ').replace('-', ' - '), testMacro, testFile); | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
5
0
1
0
142356
1
97
2300
36