Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@bootstrap-styled/utils

Package Overview
Dependencies
Maintainers
2
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@bootstrap-styled/utils - npm Package Compare versions

Comparing version 1.6.3 to 1.6.4

7

CHANGELOG.md

@@ -0,1 +1,8 @@

## [1.6.4](https://github.com/bootstrap-styled/utils/compare/v1.6.3...v1.6.4) (2018-12-05)
### Bug Fixes
* **documentation:** corrected wrong exmaples and ribbon. ([6043b71](https://github.com/bootstrap-styled/utils/commit/6043b71))
## [1.6.3](https://github.com/bootstrap-styled/utils/compare/v1.6.2...v1.6.3) (2018-12-05)

@@ -2,0 +9,0 @@

5

lib/parseTransition.js

@@ -13,5 +13,6 @@ 'use strict';

*
* parseTransition(['height .35s ease', 'fade .5 ease-out']);
* const parsedTransition = parseTransition(['height .35s ease', 'fade .5 ease-out']);
*
* // OUTPUT ['height', '.35s', 'ease', 'fade', '.5', 'ease-out']
* // OUTPUT [{ timingFunction: 'height', duration: '.35s', property: 'height'}, { timingFunction: 'ease-out', duration: '.5s', property: 'fade'}]
*
* @returns {Array} will return an array of transition.

@@ -18,0 +19,0 @@ */

21

lib/unitUtils/index.js

@@ -106,6 +106,6 @@ 'use strict';

* import unitUtils from '@bootstrap-styled/utils/lib/unitUtils';
* const { detectUnit, rmUnit, toPercent } = unitUtils;
* const { detectUnit } = unitUtils;
*
* $spacer = '1rem';
* const detectedUnit = detectUnit($spacer);
* const spacer = '1rem';
* const detectedUnit = detectUnit(spacer);
*

@@ -123,3 +123,8 @@ * // OUTPUT 'rem'

* @example
* '$spacer-halved' = rmUnit($spacer, detectedUnit) / 2 + detectedUnit);
* import unitUtils from '@bootstrap-styled/utils/lib/unitUtils';
* const { detectUnit, rmUnit } = unitUtils;
*
* const spacer = '1rem';
* const spacerHalved' = rmUnit(spacer, detectedUnit) / 2 + detectedUnit);
*
* // OUTPUT '.5rem'

@@ -137,4 +142,8 @@ */

* @example
* '$spacer-halved-percentage' = toPercent(rmUnit(toPercent));
* // OUTPUT '50%'
* import unitUtils from '@bootstrap-styled/utils/lib/unitUtils';
* const { toPercent } = unitUtils;
*
* const percentage = toPercent(20, 100, 10);
*
* // OUTPUT '20%'
*/

@@ -141,0 +150,0 @@ ;

{
"name": "@bootstrap-styled/utils",
"version": "1.6.3",
"version": "1.6.4",
"description": "UMD module for helper functions used as utilities for bootstrap-styled and other related modules",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -8,5 +8,6 @@ /**

*
* parseTransition(['height .35s ease', 'fade .5 ease-out']);
* const parsedTransition = parseTransition(['height .35s ease', 'fade .5 ease-out']);
*
* // OUTPUT ['height', '.35s', 'ease', 'fade', '.5', 'ease-out']
* // OUTPUT [{ timingFunction: 'height', duration: '.35s', property: 'height'}, { timingFunction: 'ease-out', duration: '.5s', property: 'fade'}]
*
* @returns {Array} will return an array of transition.

@@ -13,0 +14,0 @@ */

@@ -57,6 +57,6 @@ class UnitUtils {

* import unitUtils from '@bootstrap-styled/utils/lib/unitUtils';
* const { detectUnit, rmUnit, toPercent } = unitUtils;
* const { detectUnit } = unitUtils;
*
* $spacer = '1rem';
* const detectedUnit = detectUnit($spacer);
* const spacer = '1rem';
* const detectedUnit = detectUnit(spacer);
*

@@ -91,3 +91,8 @@ * // OUTPUT 'rem'

* @example
* '$spacer-halved' = rmUnit($spacer, detectedUnit) / 2 + detectedUnit);
* import unitUtils from '@bootstrap-styled/utils/lib/unitUtils';
* const { detectUnit, rmUnit } = unitUtils;
*
* const spacer = '1rem';
* const spacerHalved' = rmUnit(spacer, detectedUnit) / 2 + detectedUnit);
*
* // OUTPUT '.5rem'

@@ -110,4 +115,8 @@ */

* @example
* '$spacer-halved-percentage' = toPercent(rmUnit(toPercent));
* // OUTPUT '50%'
* import unitUtils from '@bootstrap-styled/utils/lib/unitUtils';
* const { toPercent } = unitUtils;
*
* const percentage = toPercent(20, 100, 10);
*
* // OUTPUT '20%'
*/

@@ -114,0 +123,0 @@ toPercent = (value, total = 100, decimal = 2) => { // eslint-disable-line arrow-body-style

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc