🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@contentstack/utils

Package Overview
Dependencies
Maintainers
13
Versions
32
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@contentstack/utils - npm Package Compare versions

Comparing version

to
1.3.0

13

dist/index.es.js

@@ -362,2 +362,3 @@ 'use strict';

MarkType["SUPERSCRIPT"] = "superscript";
MarkType["BREAK"] = "break";
})(MarkType || (MarkType = {}));

@@ -401,2 +402,5 @@ var MarkType$1 = MarkType;

_a[NodeType$1.LINK] = function (node, next) {
if (node.attrs.target) {
return "<a href=\"".concat(node.attrs.href || node.attrs.url, "\" target=\"").concat(node.attrs.target, "\">").concat(next(node.children), "</a>");
}
return "<a href=\"".concat(node.attrs.href || node.attrs.url, "\">").concat(next(node.children), "</a>");

@@ -468,2 +472,5 @@ },

_a['reference'] = function (node, next) {
if (node.attrs.type === 'asset') {
return "<img src=\"".concat(node.attrs['asset-link'], "\" />");
}
return "";

@@ -495,2 +502,5 @@ },

},
_a[MarkType$1.BREAK] = function (text) {
return "<br />".concat(text);
},
_a);

@@ -520,2 +530,5 @@

var text = node.text;
if (node.break) {
text = renderOption[MarkType$1.BREAK](text);
}
if (node.superscript) {

@@ -522,0 +535,0 @@ text = renderOption[MarkType$1.SUPERSCRIPT](text);

3

dist/lib/helper/enumerate-entries.js

@@ -38,2 +38,5 @@ var __assign = (this && this.__assign) || function () {

var text = node.text;
if (node.break) {
text = renderOption[MarkType.BREAK](text);
}
if (node.superscript) {

@@ -40,0 +43,0 @@ text = renderOption[MarkType.SUPERSCRIPT](text);

@@ -10,4 +10,5 @@ var MarkType;

MarkType["SUPERSCRIPT"] = "superscript";
MarkType["BREAK"] = "break";
})(MarkType || (MarkType = {}));
export default MarkType;
//# sourceMappingURL=mark-type.js.map

@@ -12,2 +12,5 @@ var _a;

_a[NodeType.LINK] = function (node, next) {
if (node.attrs.target) {
return "<a href=\"".concat(node.attrs.href || node.attrs.url, "\" target=\"").concat(node.attrs.target, "\">").concat(next(node.children), "</a>");
}
return "<a href=\"".concat(node.attrs.href || node.attrs.url, "\">").concat(next(node.children), "</a>");

@@ -79,2 +82,5 @@ },

_a['reference'] = function (node, next) {
if (node.attrs.type === 'asset') {
return "<img src=\"".concat(node.attrs['asset-link'], "\" />");
}
return "";

@@ -106,3 +112,6 @@ },

},
_a[MarkType.BREAK] = function (text) {
return "<br />".concat(text);
},
_a);
//# sourceMappingURL=default-node-options.js.map

3

dist/types/nodes/mark-type.d.ts

@@ -8,4 +8,5 @@ declare enum MarkType {

SUBSCRIPT = "subscript",
SUPERSCRIPT = "superscript"
SUPERSCRIPT = "superscript",
BREAK = "break"
}
export default MarkType;

@@ -10,4 +10,5 @@ import Node from "./node";

subscript?: boolean;
break?: boolean;
text: string;
constructor(text: string);
}
{
"name": "@contentstack/utils",
"version": "1.2.0",
"version": "1.3.0",
"description": "Contentstack utilities for Javascript",

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet