@shiftbrainstd/harmonic-modular-scale
Advanced tools
Comparing version 1.0.1 to 1.1.0
{ | ||
"name": "@shiftbrainstd/harmonic-modular-scale", | ||
"description": "Polyrhythm Modular Scale", | ||
"author": "Shiftbrain Inc. (https://www.shiftbrain.com/)", | ||
"version": "1.0.1", | ||
"main": "_index.scss", | ||
"description": "Harmonic Modular Scale Typography", | ||
"author": "Shiftbrain Standard Design Unit (https://standard.shiftbrain.com/)", | ||
"version": "1.1.0", | ||
"main": "dist/index.js", | ||
"module": "dist/harmomic-modular-scale.esm.js", | ||
"unpkg": "dist/harmomic-modular-scale.umd.production.min.js", | ||
"typings": "dist/index.d.ts", | ||
"files": [ | ||
"_index.scss", | ||
"dist", | ||
"types", | ||
"scss/**/*" | ||
@@ -21,22 +26,60 @@ ], | ||
"scripts": { | ||
"prepublishOnly": "run-s lint test build", | ||
"sass:watch": "chokidar '**/*.scss' -c 'npm run sass:build' --initial", | ||
"sass:build": "sass demo/main.scss demo/main.css", | ||
"sass:build": "sass demo/main.scss:demo/main.css", | ||
"sass:lint": "stylelint \"**/*.scss\"", | ||
"ts:lint": "eslint \"src/**/*.ts\"", | ||
"ts:watch": "tsdx watch --entry demo/index.ts --format umd", | ||
"ts:build": "tsdx build --format cjs,esm,umd --entry src/index.ts", | ||
"serve": "browser-sync start -c ./.config/browser-sync.js", | ||
"start": "npm-run-all -p sass:watch serve", | ||
"build": "npm run sass:build", | ||
"lint": "stylelint **/*.scss", | ||
"start": "run-p sass:watch ts:watch serve", | ||
"build": "run-s sass:build ts:build", | ||
"lint": "run-s sass:lint ts:lint", | ||
"test": "jest" | ||
}, | ||
"dependencies": { | ||
"tiny-invariant": "^1.0.6", | ||
"csstype": "^2.6.7" | ||
}, | ||
"devDependencies": { | ||
"@types/jest": "^24.0.23", | ||
"@typescript-eslint/eslint-plugin": "^2.6.0", | ||
"@typescript-eslint/parser": "^2.6.0", | ||
"browser-sync": "^2.26.7", | ||
"chokidar-cli": "^2.1.0", | ||
"fast-glob": "^3.1.0", | ||
"emotion": "^10.0.23", | ||
"eslint": "^6.7.2", | ||
"eslint-config-prettier": "^6.5.0", | ||
"eslint-plugin-prettier": "^3.0.1", | ||
"fast-glob": "^3.1.1", | ||
"husky": "^3.1.0", | ||
"jest": "^24.9.0", | ||
"lint-staged": "^9.5.0", | ||
"npm-run-all": "^4.1.5", | ||
"sass": "^1.23.2", | ||
"prettier": "^1.19.0", | ||
"sass": "^1.23.7", | ||
"sass-true": "^5.0.0", | ||
"stylelint": "^11.1.1", | ||
"stylelint-config-recommended-scss": "^4.0.0", | ||
"stylelint-scss": "^3.12.0" | ||
"stylelint": "^12.0.0", | ||
"stylelint-config-recommended-scss": "^4.1.0", | ||
"stylelint-scss": "^3.13.0", | ||
"ts-jest": "^24.2.0", | ||
"tsdx": "^0.11.0", | ||
"tslib": "^1.10.0", | ||
"typescript": "^3.6.4" | ||
}, | ||
"husky": { | ||
"hooks": { | ||
"pre-commit": "lint-staged" | ||
} | ||
}, | ||
"lint-staged": { | ||
"*.js": [ | ||
"eslint --fix", | ||
"git add" | ||
], | ||
"*.{css,scss}": [ | ||
"stylelint --fix", | ||
"git add" | ||
] | ||
}, | ||
"publishConfig": { | ||
@@ -48,7 +91,14 @@ "access": "public" | ||
"rules": { | ||
"string-quotes": "double" | ||
"string-quotes": "double", | ||
"property-no-unknown": [ | ||
true, | ||
{ | ||
"ignoreProperties": "/scale./" | ||
} | ||
] | ||
} | ||
}, | ||
"jest": { | ||
"testEnvironment": "node" | ||
"testEnvironment": "node", | ||
"preset": "ts-jest" | ||
}, | ||
@@ -62,3 +112,7 @@ "prettier": { | ||
{ | ||
"files": "*.js", | ||
"files": [ | ||
"*.js", | ||
"*.ts", | ||
"*.md" | ||
], | ||
"options": { | ||
@@ -65,0 +119,0 @@ "singleQuote": true |
@@ -15,6 +15,8 @@ # Harmonic Modular Scale | ||
A Sass module to manage your project’s typographic scale using a [harmonic progression](https://en.wikipedia.org/wiki/Harmonic_progression_(mathematics)). | ||
A Sass module to manage your project’s typographic scale using a [harmonic progression](<https://en.wikipedia.org/wiki/Harmonic_progression_(mathematics)>). | ||
See the [explanatory article](https://standard.shiftbrain.com/blog/harmonious-proportions-in-type-sizes) for details (Japanese). | ||
**This documentation refers to the Sass APIs. To use the library with JavaScript read the [documentation here](docs/javascript-api.md).** | ||
<!-- TOC --> | ||
@@ -48,3 +50,3 @@ | ||
```scss | ||
@use "harmonic-modular-scale" as hms; | ||
@use "@shiftbrainstd/harmonic-modular-scale" as hms; | ||
``` | ||
@@ -90,8 +92,8 @@ | ||
| argument | type | default | description | | ||
| --------------------- | ------ | ------- | --------------------------------------------------------------------------------------------------------------------------- | | ||
| `$font-size-degree` | number | 0 | An integer indicating the font size in the harmonic scale. The returned value will be relative to the base font size. | | ||
| `$line-height-degree` | number | null | The increments of line height relative to the minimum height that can contain the current font size. It must be an integer. | | ||
| `$lines` | number | 1 | The number to multiply the line height for. | | ||
| `$as-line-height` | boolean | false | If true, returns the value relative to the current font-size. If false, returns the value relative to the root font size. | | ||
| argument | type | default | description | | ||
| --------------------- | ------- | ------- | --------------------------------------------------------------------------------------------------------------------------- | | ||
| `$font-size-degree` | number | 0 | An integer indicating the font size in the harmonic scale. The returned value will be relative to the base font size. | | ||
| `$line-height-degree` | number | null | The increments of line height relative to the minimum height that can contain the current font size. It must be an integer. | | ||
| `$lines` | number | 1 | The number to multiply the line height for. | | ||
| `$as-line-height` | boolean | false | If true, returns the value relative to the current font-size. If false, returns the value relative to the root font size. | | ||
@@ -168,5 +170,5 @@ It will returns `line-hieght` value related to the `$base-font-size`. It is helpful when you need to set sizes based on typographic scale. | ||
@use "sass:meta"; | ||
@use "harmonic-modular-scale"; | ||
@use "@shiftbrainstd/harmonic-modular-scale"; | ||
@use "polyrhythm-typography" as pt with ( | ||
@use "@shiftbrainstd/polyrhythm-typography" as pt with ( | ||
$type-scaler: meta.get-function("get-sizes", $module: "harmonic-modular-scale") | ||
@@ -199,3 +201,3 @@ ); | ||
Contributions, issues and feature requests are welcome!<br />Feel free to check [issues page](https://github.com/devjam/harmonic-modular-scale/issues). | ||
Contributions, issues and feature requests are welcome!<br />Feel free to check [issues page](https://github.com/ShiftbrainStd/harmonic-modular-scale/issues). | ||
@@ -202,0 +204,0 @@ ## 📝 License |
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
Empty package
Supply chain riskPackage does not contain any code. It may be removed, is name squatting, or the result of a faulty package publish.
Found 1 instance in 1 package
70401
21
443
206
2
24
1
3
+ Addedcsstype@^2.6.7
+ Addedtiny-invariant@^1.0.6
+ Addedcsstype@2.6.21(transitive)
+ Addedtiny-invariant@1.3.3(transitive)