react-datasheet-grid
Advanced tools
Comparing version 4.0.5 to 4.0.6
@@ -55,3 +55,2 @@ "use strict"; | ||
const typeCheck_1 = require("../utils/typeCheck"); | ||
const html_entities_1 = require("html-entities"); | ||
const tab_1 = require("../utils/tab"); | ||
@@ -434,3 +433,3 @@ const DEFAULT_DATA = []; | ||
.map((row) => `<tr>${row | ||
.map((cell) => `<td>${html_entities_1.encode(String(cell !== null && cell !== void 0 ? cell : '')).replace(/\n/g, '<br/>')}</td>`) | ||
.map((cell) => `<td>${copyPasting_1.encodeHtml(String(cell !== null && cell !== void 0 ? cell : '')).replace(/\n/g, '<br/>')}</td>`) | ||
.join('')}</tr>`) | ||
@@ -437,0 +436,0 @@ .join('')}</table>`); |
export declare const parseTextHtmlData: (data: string) => string[][]; | ||
export declare const parseTextPlainData: (data: string) => string[][]; | ||
export declare const encodeHtml: (str: string) => string; | ||
//# sourceMappingURL=copyPasting.d.ts.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.parseTextPlainData = exports.parseTextHtmlData = void 0; | ||
exports.encodeHtml = exports.parseTextPlainData = exports.parseTextHtmlData = void 0; | ||
const domParser_1 = require("./domParser"); | ||
@@ -81,2 +81,11 @@ const parseTextHtmlData = (data) => { | ||
exports.parseTextPlainData = parseTextPlainData; | ||
const encodeHtml = (str) => { | ||
return str | ||
.replace(/&/g, '&') | ||
.replace(/</g, '<') | ||
.replace(/>/g, '>') | ||
.replace(/"/g, '"') | ||
.replace(/'/g, '''); | ||
}; | ||
exports.encodeHtml = encodeHtml; | ||
//# sourceMappingURL=copyPasting.js.map |
{ | ||
"name": "react-datasheet-grid", | ||
"version": "4.0.5", | ||
"version": "4.0.6", | ||
"description": "An Excel-like React component to create beautiful spreadsheets.", | ||
@@ -66,3 +66,2 @@ "main": "dist/index.js", | ||
"fast-deep-equal": "^3.1.3", | ||
"html-entities": "^2.3.2", | ||
"react-resize-detector": "^6.7.2", | ||
@@ -69,0 +68,0 @@ "react-window": "^1.8.6", |
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
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
276814
6
3514
- Removedhtml-entities@^2.3.2
- Removedhtml-entities@2.5.2(transitive)