Socket
Socket
Sign inDemoInstall

@ag-grid-community/csv-export

Package Overview
Dependencies
Maintainers
3
Versions
69
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ag-grid-community/csv-export - npm Package Compare versions

Comparing version 25.2.0 to 25.3.0

tsconfig.typings.json

27

dist/cjs/csvExport/downloader.js

@@ -7,13 +7,19 @@ "use strict";

Downloader.download = function (fileName, content) {
var win = document.defaultView || window;
if (!win) {
console.warn('AG Grid: There is no `window` associated with the current `document`');
return;
}
// Internet Explorer
if (window.navigator.msSaveOrOpenBlob) {
window.navigator.msSaveOrOpenBlob(content, fileName);
if (win.navigator.msSaveOrOpenBlob) {
win.navigator.msSaveOrOpenBlob(content, fileName);
}
else {
// Other Browsers
var element = document.createElement("a");
var url_1 = window.URL.createObjectURL(content);
element.setAttribute("href", url_1);
element.setAttribute("download", fileName);
element.style.display = "none";
var element = document.createElement('a');
// @ts-ignore
var url_1 = win.URL.createObjectURL(content);
element.setAttribute('href', url_1);
element.setAttribute('download', fileName);
element.style.display = 'none';
document.body.appendChild(element);

@@ -23,7 +29,8 @@ element.dispatchEvent(new MouseEvent('click', {

cancelable: true,
view: window
view: win
}));
document.body.removeChild(element);
window.setTimeout(function () {
window.URL.revokeObjectURL(url_1);
win.setTimeout(function () {
// @ts-ignore
win.URL.revokeObjectURL(url_1);
}, 0);

@@ -30,0 +37,0 @@ }

@@ -51,2 +51,3 @@ "use strict";

var skipLowestSingleChildrenGroup = gridOptionsWrapper.isGroupRemoveLowestSingleChildren();
var isLeafNode = this.columnController.isPivotMode() ? node.leafGroup : !node.group;
var skipRowGroups = params.skipGroups || params.skipRowGroups;

@@ -56,5 +57,5 @@ var shouldSkipLowestGroup = skipLowestSingleChildrenGroup && node.leafGroup;

if (skipRowGroups && params.skipGroups) {
console.warn('AG Grid: Since v25.2 `skipGroups` has been renamed to `skipRowGroups`.');
core_1._.doOnce(function () { return console.warn('AG Grid: Since v25.2 `skipGroups` has been renamed to `skipRowGroups`.'); }, 'gridSerializer-skipGroups');
}
if ((node.group && (params.skipRowGroups || shouldSkipCurrentGroup || hideOpenParents)) ||
if ((!isLeafNode && (params.skipRowGroups || shouldSkipCurrentGroup || hideOpenParents)) ||
(params.onlySelected && !node.isSelected()) ||

@@ -91,3 +92,3 @@ (params.skipPinnedTop && node.rowPinned === 'top') ||

if (params.customFooter) {
console.warn('AG Grid: Since version 25.2.0 the `customFooter` param has been deprecated. Use `appendContent` instead.');
core_1._.doOnce(function () { return console.warn('AG Grid: Since version 25.2.0 the `customFooter` param has been deprecated. Use `appendContent` instead.'); }, 'gridSerializer-customFooter');
}

@@ -104,3 +105,3 @@ gridSerializingSession.addCustomContent(appendContent);

if (params.customHeader) {
console.warn('AG Grid: Since version 25.2.0 the `customHeader` param has been deprecated. Use `prependContent` instead.');
core_1._.doOnce(function () { return console.warn('AG Grid: Since version 25.2.0 the `customHeader` param has been deprecated. Use `prependContent` instead.'); }, 'gridSerializer-customHeader');
}

@@ -127,3 +128,3 @@ gridSerializingSession.addCustomContent(prependContent);

else if (params.columnGroups) {
console.warn('AG Grid: Since v25.2 the `columnGroups` param has deprecated, and groups are exported by default.');
core_1._.doOnce(function () { return console.warn('AG Grid: Since v25.2 the `columnGroups` param has deprecated, and groups are exported by default.'); }, 'gridSerializer-columnGroups');
}

@@ -142,3 +143,3 @@ return gridSerializingSession;

else if (params.skipHeader) {
console.warn('AG Grid: Since v25.2 the `skipHeader` param has been renamed to `skipColumnHeaders`.');
core_1._.doOnce(function () { return console.warn('AG Grid: Since v25.2 the `skipHeader` param has been renamed to `skipColumnHeaders`.'); }, 'gridSerializer-skipHeader');
}

@@ -161,7 +162,9 @@ return gridSerializingSession;

var rowModel = _this.rowModel;
var rowModelNormal = rowModel.getType() === core_1.Constants.ROW_MODEL_TYPE_CLIENT_SIDE;
var onlySelectedNonStandardModel = !rowModelNormal && params.onlySelected;
var rowModelType = rowModel.getType();
var usingCsrm = rowModelType === core_1.Constants.ROW_MODEL_TYPE_CLIENT_SIDE;
var usingSsrm = rowModelType === core_1.Constants.ROW_MODEL_TYPE_SERVER_SIDE;
var onlySelectedNonStandardModel = !usingCsrm && params.onlySelected;
var processRow = _this.processRow.bind(_this, gridSerializingSession, params, columnsToExport);
if (_this.columnController.isPivotMode()) {
if (rowModelNormal) {
if (usingCsrm) {
rowModel.forEachPivotNode(processRow);

@@ -188,5 +191,8 @@ }

// of the rows appearing on the screen.
if (rowModelNormal) {
if (usingCsrm) {
rowModel.forEachNodeAfterFilterAndSort(processRow);
}
else if (usingSsrm) {
rowModel.forEachNodeAfterFilterAndSort(processRow);
}
else {

@@ -193,0 +199,0 @@ rowModel.forEachNode(processRow);

@@ -5,13 +5,19 @@ var Downloader = /** @class */ (function () {

Downloader.download = function (fileName, content) {
var win = document.defaultView || window;
if (!win) {
console.warn('AG Grid: There is no `window` associated with the current `document`');
return;
}
// Internet Explorer
if (window.navigator.msSaveOrOpenBlob) {
window.navigator.msSaveOrOpenBlob(content, fileName);
if (win.navigator.msSaveOrOpenBlob) {
win.navigator.msSaveOrOpenBlob(content, fileName);
}
else {
// Other Browsers
var element = document.createElement("a");
var url_1 = window.URL.createObjectURL(content);
element.setAttribute("href", url_1);
element.setAttribute("download", fileName);
element.style.display = "none";
var element = document.createElement('a');
// @ts-ignore
var url_1 = win.URL.createObjectURL(content);
element.setAttribute('href', url_1);
element.setAttribute('download', fileName);
element.style.display = 'none';
document.body.appendChild(element);

@@ -21,7 +27,8 @@ element.dispatchEvent(new MouseEvent('click', {

cancelable: true,
view: window
view: win
}));
document.body.removeChild(element);
window.setTimeout(function () {
window.URL.revokeObjectURL(url_1);
win.setTimeout(function () {
// @ts-ignore
win.URL.revokeObjectURL(url_1);
}, 0);

@@ -28,0 +35,0 @@ }

@@ -20,3 +20,3 @@ var __extends = (this && this.__extends) || (function () {

};
import { Autowired, Bean, BeanStub, ColumnGroup, Constants, GroupInstanceIdCreator, _ } from "@ag-grid-community/core";
import { _, Autowired, Bean, BeanStub, ColumnGroup, Constants, GroupInstanceIdCreator } from "@ag-grid-community/core";
export var RowType;

@@ -50,2 +50,3 @@ (function (RowType) {

var skipLowestSingleChildrenGroup = gridOptionsWrapper.isGroupRemoveLowestSingleChildren();
var isLeafNode = this.columnController.isPivotMode() ? node.leafGroup : !node.group;
var skipRowGroups = params.skipGroups || params.skipRowGroups;

@@ -55,5 +56,5 @@ var shouldSkipLowestGroup = skipLowestSingleChildrenGroup && node.leafGroup;

if (skipRowGroups && params.skipGroups) {
console.warn('AG Grid: Since v25.2 `skipGroups` has been renamed to `skipRowGroups`.');
_.doOnce(function () { return console.warn('AG Grid: Since v25.2 `skipGroups` has been renamed to `skipRowGroups`.'); }, 'gridSerializer-skipGroups');
}
if ((node.group && (params.skipRowGroups || shouldSkipCurrentGroup || hideOpenParents)) ||
if ((!isLeafNode && (params.skipRowGroups || shouldSkipCurrentGroup || hideOpenParents)) ||
(params.onlySelected && !node.isSelected()) ||

@@ -90,3 +91,3 @@ (params.skipPinnedTop && node.rowPinned === 'top') ||

if (params.customFooter) {
console.warn('AG Grid: Since version 25.2.0 the `customFooter` param has been deprecated. Use `appendContent` instead.');
_.doOnce(function () { return console.warn('AG Grid: Since version 25.2.0 the `customFooter` param has been deprecated. Use `appendContent` instead.'); }, 'gridSerializer-customFooter');
}

@@ -103,3 +104,3 @@ gridSerializingSession.addCustomContent(appendContent);

if (params.customHeader) {
console.warn('AG Grid: Since version 25.2.0 the `customHeader` param has been deprecated. Use `prependContent` instead.');
_.doOnce(function () { return console.warn('AG Grid: Since version 25.2.0 the `customHeader` param has been deprecated. Use `prependContent` instead.'); }, 'gridSerializer-customHeader');
}

@@ -126,3 +127,3 @@ gridSerializingSession.addCustomContent(prependContent);

else if (params.columnGroups) {
console.warn('AG Grid: Since v25.2 the `columnGroups` param has deprecated, and groups are exported by default.');
_.doOnce(function () { return console.warn('AG Grid: Since v25.2 the `columnGroups` param has deprecated, and groups are exported by default.'); }, 'gridSerializer-columnGroups');
}

@@ -141,3 +142,3 @@ return gridSerializingSession;

else if (params.skipHeader) {
console.warn('AG Grid: Since v25.2 the `skipHeader` param has been renamed to `skipColumnHeaders`.');
_.doOnce(function () { return console.warn('AG Grid: Since v25.2 the `skipHeader` param has been renamed to `skipColumnHeaders`.'); }, 'gridSerializer-skipHeader');
}

@@ -160,7 +161,9 @@ return gridSerializingSession;

var rowModel = _this.rowModel;
var rowModelNormal = rowModel.getType() === Constants.ROW_MODEL_TYPE_CLIENT_SIDE;
var onlySelectedNonStandardModel = !rowModelNormal && params.onlySelected;
var rowModelType = rowModel.getType();
var usingCsrm = rowModelType === Constants.ROW_MODEL_TYPE_CLIENT_SIDE;
var usingSsrm = rowModelType === Constants.ROW_MODEL_TYPE_SERVER_SIDE;
var onlySelectedNonStandardModel = !usingCsrm && params.onlySelected;
var processRow = _this.processRow.bind(_this, gridSerializingSession, params, columnsToExport);
if (_this.columnController.isPivotMode()) {
if (rowModelNormal) {
if (usingCsrm) {
rowModel.forEachPivotNode(processRow);

@@ -187,5 +190,8 @@ }

// of the rows appearing on the screen.
if (rowModelNormal) {
if (usingCsrm) {
rowModel.forEachNodeAfterFilterAndSort(processRow);
}
else if (usingSsrm) {
rowModel.forEachNodeAfterFilterAndSort(processRow);
}
else {

@@ -192,0 +198,0 @@ rowModel.forEachNode(processRow);

{
"name": "@ag-grid-community/csv-export",
"version": "25.2.0",
"version": "25.3.0",
"description": "Advanced Data Grid / Data Table supporting Javascript / React / AngularJS / Web Components",

@@ -12,3 +12,3 @@ "main": "./dist/cjs/main.js",

"package": "node ../../module-build/rollup/build.js",
"build": "npm run build-cjs && npm run build-es6 && npm run hash",
"build": "npm run build-cjs && npm run build-es6 && tsc -p tsconfig.typings.json && npm run hash",
"hash": "sh ../../scripts/hashDirectory.sh > .hash"

@@ -46,3 +46,3 @@ },

"dependencies": {
"@ag-grid-community/core": "~25.2.0"
"@ag-grid-community/core": "~25.3.0"
},

@@ -49,0 +49,0 @@ "devDependencies": {

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 too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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