New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ansi-art

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ansi-art - npm Package Compare versions

Comparing version 0.0.1 to 1.0.0

2

dist/index.js

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

module.exports=function(r){function o(t){if(n[t])return n[t].exports;var e=n[t]={i:t,l:!1,exports:{}};return r[t].call(e.exports,e,e.exports,o),e.l=!0,e.exports}var n={};return o.m=r,o.c=n,o.i=function(r){return r},o.d=function(r,n,t){o.o(r,n)||Object.defineProperty(r,n,{configurable:!1,enumerable:!0,get:t})},o.n=function(r){var n=r&&r.__esModule?function(){return r.default}:function(){return r};return o.d(n,"a",n),n},o.o=function(r,o){return Object.prototype.hasOwnProperty.call(r,o)},o.p="",o(o.s=1)}([function(r,o,n){"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.default="\n.....rrrrr..yyy.\n....rrrrrrrrryy.\n....oooyyxy.rrr.\n...oyoyyyxyyyrr.\n...oyooyyyoyyyr.\n...ooyyyyoooor..\n.....yyyyyyyrr..\n..rrrrbrrrbrr..o\nyyrrrrrbrrrb..oo\nyyyrrrrbbbbYbboo\n.y..brbbYbbbbboo\n..ooobbbbbbbbboo\n.ooobbbbbb......\n.oo.............\n"},function(r,o,n){"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.MarioArt=void 0;var t=n(0),e=function(r){return r&&r.__esModule?r:{default:r}}(t),y={r:"[48;5;9m",b:"[48;5;12m",g:"[48;5;10m",x:"[48;5;0m",w:"[48;5;15m",o:"[48;5;95m",y:"[48;5;224m",Y:"[48;5;11m",".":"[m"},u=function(r,o){var n=r&&r.trim()&&r.trim().split("\n");if(n&&n.length)return n.map(function(r){return r.split("").map(function(r){return""+y[r]+" "}).join("")}).join("\n")};o.default={get:u},o.MarioArt=e.default}]);
module.exports=function(r){function n(e){if(o[e])return o[e].exports;var t=o[e]={i:e,l:!1,exports:{}};return r[e].call(t.exports,t,t.exports,n),t.l=!0,t.exports}var o={};return n.m=r,n.c=o,n.i=function(r){return r},n.d=function(r,o,e){n.o(r,o)||Object.defineProperty(r,o,{configurable:!1,enumerable:!0,get:e})},n.n=function(r){var o=r&&r.__esModule?function(){return r.default}:function(){return r};return n.d(o,"a",o),o},n.o=function(r,n){return Object.prototype.hasOwnProperty.call(r,n)},n.p="",n(n.s=1)}([function(r,n,o){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.default="\n.....rrrrr..yyy.\n....rrrrrrrrryy.\n....oooyyxy.rrr.\n...oyoyyyxyyyrr.\n...oyooyyyoyyyr.\n...ooyyyyoooor..\n.....yyyyyyyrr..\n..rrrrbrrrbrr..o\nyyrrrrrbrrrb..oo\nyyyrrrrbbbbYbboo\n.y..brbbYbbbbboo\n..ooobbbbbbbbboo\n.ooobbbbbb......\n.oo.............\n"},function(r,n,o){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.MarioArt=void 0;var e=o(0),t=function(r){return r&&r.__esModule?r:{default:r}}(e),y={r:"[48;5;9m",b:"[48;5;12m",g:"[48;5;10m",x:"[48;5;0m",w:"[48;5;15m",o:"[48;5;95m",y:"[48;5;224m",Y:"[48;5;11m",".":"[m"},u=function(r){var n="+"+"-".repeat(r.length+2)+"+ \n| "+r+" |\n+"+"-".repeat(r.length+2)+"+\n";return n+=" \\\n \\\n"},b=function(r,n){var o=r&&r.trim()&&r.trim().split("\n");if(o&&o.length){var e=n.speak,t=o.map(function(r){return r.split("").map(function(r){return""+y[r]+" "}).join("")}).join("\n");return e&&(t=u(e)+t),t}};n.default={get:b},n.MarioArt=t.default}]);
{
"name": "ansi-art",
"version": "0.0.1",
"version": "1.0.0",
"description": "create ansi art using simple texts",

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

@@ -36,8 +36,15 @@ #### ANSI ART

Characters inside text represents the color. r for red, b for blue, '.' for transparent.
**ANSI.get(text, options):**
You can also import existing Arts available inside '/src/arts/'
Parameter | Type | Description
------|------ | -------------
text | string | Text to be converted into ANSI, Characters inside text represents the color. r for red, b for blue, '.' for transparent., [See available colors](https://github.com/gauravchl/ansi-art/blob/master/src/index.js#L5):
options | object | More options for ansi art
options.speak | string | If provided, render the text inside 'speech bubble' above the ANSI art
Example:
You can also import existing arts available inside '/src/arts/'
**Example with existing art:**
```

@@ -49,5 +56,10 @@ import ANSI, { MarioArt } from 'ansi-art';

**Example with speech bubble:**
TODO:
```
import ANSI, { MarioArt } from 'ansi-art';
- Add option to display text inside speech bubble.
console.log(ANSI.get(MarioArt, {speak: 'Hello World'}));
```
<img width="375" alt="screen shot 2017-04-25 at 12 45 50 pm" src="https://cloud.githubusercontent.com/assets/3471415/25372927/2b153fa4-29b5-11e7-97ab-dbcfecbc5e28.png">
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