emojify-text
Advanced tools
Comparing version 1.0.2 to 1.0.3
@@ -9,2 +9,6 @@ 'use strict'; | ||
var _neatContract = require('neat-contract'); | ||
var _neatContract2 = _interopRequireDefault(_neatContract); | ||
var _characters = require('./characters'); | ||
@@ -38,5 +42,3 @@ | ||
return (0, _ramda.pipe)((0, _ramda.unless)((0, _ramda.is)(String), function () { | ||
throw new TypeError('`input` should be an `String`'); | ||
}), (0, _ramda.toUpper)(), (0, _ramda.split)(''), (0, _ramda.map)((0, _ramda.ifElse)((0, _ramda.has)(_ramda.__, dictionary), (0, _ramda.prop)(_ramda.__, dictionary), (0, _ramda.always)((0, _ramda.defaultTo)([], dictionary.nochar)))), (0, _ramda.map)((0, _ramda.map)((0, _ramda.join)(''))), (0, _ramda.ifElse)((0, _ramda.always)(row), (0, _ramda.pipe)((0, _ramda.transpose)(), (0, _ramda.map)((0, _ramda.join)(''))), (0, _ramda.map)((0, _ramda.join)('\n'))), (0, _ramda.join)('\n'), (0, _ramda.replace)(/0/g, (0, _ramda.defaultTo)((0, _ramda.defaultTo)('0', bg), background)), (0, _ramda.replace)(/1/g, (0, _ramda.defaultTo)((0, _ramda.defaultTo)('1', fg), foreground)))(input); | ||
return (0, _ramda.pipe)((0, _neatContract2.default)('input', String), _ramda.toUpper, (0, _ramda.split)(''), (0, _ramda.map)((0, _ramda.ifElse)((0, _ramda.has)(_ramda.__, dictionary), (0, _ramda.prop)(_ramda.__, dictionary), (0, _ramda.always)((0, _ramda.defaultTo)([], dictionary.nochar)))), (0, _ramda.map)((0, _ramda.map)((0, _ramda.join)(''))), (0, _ramda.ifElse)((0, _ramda.always)(row), (0, _ramda.pipe)((0, _ramda.transpose)(), (0, _ramda.map)((0, _ramda.join)(''))), (0, _ramda.map)((0, _ramda.join)('\n'))), (0, _ramda.join)('\n'), (0, _ramda.replace)(/0/g, (0, _ramda.defaultTo)((0, _ramda.defaultTo)('0', bg), background)), (0, _ramda.replace)(/1/g, (0, _ramda.defaultTo)((0, _ramda.defaultTo)('1', fg), foreground)))(input); | ||
} | ||
@@ -43,0 +45,0 @@ |
13
index.js
@@ -19,2 +19,3 @@ import { | ||
} from 'ramda' | ||
import contract from 'neat-contract' | ||
@@ -44,7 +45,4 @@ import characters from './characters' | ||
return pipe( | ||
unless( | ||
is(String), | ||
() => { throw new TypeError(`\`input\` should be an \`String\``) } | ||
), | ||
toUpper(), | ||
contract('input', String), | ||
toUpper, | ||
split(''), | ||
@@ -63,3 +61,6 @@ map( | ||
always(row), | ||
pipe(transpose(), map(join(''))), | ||
pipe( | ||
transpose(), | ||
map(join('')) | ||
), | ||
map(join('\n')) | ||
@@ -66,0 +67,0 @@ ), |
{ | ||
"name": "emojify-text", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "Convert boring text to wonderful emojis", | ||
@@ -57,4 +57,5 @@ "main": "index.es5.js", | ||
"dependencies": { | ||
"neat-contract": "^1.1.0", | ||
"ramda": "^0.22.1" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
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
32276
1034
0
2
+ Addedneat-contract@^1.1.0
+ Addedneat-contract@1.1.1(transitive)