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

blessed-contrib

Package Overview
Dependencies
Maintainers
1
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

blessed-contrib - npm Package Compare versions

Comparing version 4.8.14 to 4.8.15

6

index.d.ts

@@ -355,2 +355,8 @@ import * as Blessed from 'blessed'

export interface MarkdownOptions extends CanvasOptions {
/**
* Markdown text to render.
*/
markdown?: string;
markdownStyle?: any;
}

@@ -357,0 +363,0 @@

30

lib/widget/markdown.js

@@ -16,6 +16,10 @@ "use strict";

this.evalStyles(options);
const markdownOptions = {
style: options.markdownStyle
};
this.setOptions(options.style);
this.evalStyles(markdownOptions);
this.setOptions(markdownOptions.style);
this.options = options;

@@ -29,2 +33,6 @@ Box.call(this, options);

Markdown.prototype.setMarkdown = function(str) {
this.setContent(marked(str));
};
Markdown.prototype.setOptions = function(style) {

@@ -34,13 +42,6 @@ marked.setOptions({

});
};
}
Markdown.prototype.setMarkdown = function(str) {
this.setContent(marked(str));
}
Markdown.prototype.evalStyles = function(options) {
if (!options.style) return;
for (var st in options.style) {

@@ -54,12 +55,11 @@ if (typeof(options.style[st])!="string") continue;

}
}
};
}
Markdown.prototype.getOptionsPrototype = function() {
return {
markdown: 'string'
markdown: 'string',
markdownStyle: 'object'
}
}
};

@@ -66,0 +66,0 @@ Markdown.prototype.type = 'markdown';

{
"name": "blessed-contrib",
"version": "4.8.14",
"version": "4.8.15",
"description": "",

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

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