Skip to content

Commit 74bdbba

Browse files
authored
1.0.1 (#50)
* rollup-plugin-buble -> @rollup/plugin-buble `rollup-plugin-buble` has been deprecated. * 1.0.1
1 parent 5ca02ac commit 74bdbba

File tree

8 files changed

+79
-55
lines changed

8 files changed

+79
-55
lines changed

dist/jsonpanel-next.cjs.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*!
2-
* jsonpanel-next v1.0.0
3-
* (c) 2019 Tan Zhen Yong
2+
* jsonpanel-next v1.0.1
3+
* (c) 2020 Tan Zhen Yong
44
* Released under the MIT License.
55
*/
66

@@ -142,14 +142,15 @@ var ExpandablePair = /*@__PURE__*/(function (Pair) {
142142

143143
ExpandablePair.prototype.expand = function expand () {
144144
// Open new panel
145-
Panel.renderToEl(this.el, {data: this.val});
145+
Panel.renderToEl(this.el, {
146+
data: this.val,
147+
valTransformer: this.valTransformer
148+
});
146149
this.el.classList.add('expanded');
147150
};
148151

149152
ExpandablePair.prototype.collapse = function collapse () {
150-
this.el
151-
.querySelectorAll('.panel')
152-
.forEach(function (e) { return e.parentNode.removeChild(e); });
153+
this.el.querySelectorAll('.panel').forEach(function (e) { return e.remove(); });
153154
this.el.classList.remove('expanded');
154155
};
155156

dist/jsonpanel-next.esm.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*!
2-
* jsonpanel-next v1.0.0
3-
* (c) 2019 Tan Zhen Yong
2+
* jsonpanel-next v1.0.1
3+
* (c) 2020 Tan Zhen Yong
44
* Released under the MIT License.
55
*/
66

@@ -140,14 +140,15 @@ var ExpandablePair = /*@__PURE__*/(function (Pair) {
140140

141141
ExpandablePair.prototype.expand = function expand () {
142142
// Open new panel
143-
Panel.renderToEl(this.el, {data: this.val});
143+
Panel.renderToEl(this.el, {
144+
data: this.val,
145+
valTransformer: this.valTransformer
146+
});
144147
this.el.classList.add('expanded');
145148
};
146149

147150
ExpandablePair.prototype.collapse = function collapse () {
148-
this.el
149-
.querySelectorAll('.panel')
150-
.forEach(function (e) { return e.parentNode.removeChild(e); });
151+
this.el.querySelectorAll('.panel').forEach(function (e) { return e.remove(); });
151152
this.el.classList.remove('expanded');
152153
};
153154

dist/jsonpanel-next.umd.js

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
/*!
2-
* jsonpanel-next v1.0.0
3-
* (c) 2019 Tan Zhen Yong
2+
* jsonpanel-next v1.0.1
3+
* (c) 2020 Tan Zhen Yong
44
* Released under the MIT License.
55
*/
66

77
(function (global, factory) {
88
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
99
typeof define === 'function' && define.amd ? define(factory) :
1010
(global = global || self, global.jsonpanelNext = factory());
11-
}(this, function () { 'use strict';
11+
}(this, (function () { 'use strict';
1212

1313
function isPlainObject(obj) {
1414
return Object.prototype.toString.call(obj) === '[object Object]';
@@ -146,14 +146,15 @@
146146

147147
ExpandablePair.prototype.expand = function expand () {
148148
// Open new panel
149-
Panel.renderToEl(this.el, {data: this.val});
149+
Panel.renderToEl(this.el, {
150+
data: this.val,
151+
valTransformer: this.valTransformer
152+
});
150153
this.el.classList.add('expanded');
151154
};
152155

153156
ExpandablePair.prototype.collapse = function collapse () {
154-
this.el
155-
.querySelectorAll('.panel')
156-
.forEach(function (e) { return e.parentNode.removeChild(e); });
157+
this.el.querySelectorAll('.panel').forEach(function (e) { return e.remove(); });
157158
this.el.classList.remove('expanded');
158159
};
159160

@@ -289,4 +290,4 @@
289290

290291
return jsonpanelNext;
291292

292-
}));
293+
})));

dist/jsonpanel-next.umd.min.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/jsonpanel-next.umd.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package-lock.json

Lines changed: 49 additions & 28 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "jsonpanel-next",
3-
"version": "1.0.0",
3+
"version": "1.0.1",
44
"description": "Pretty JSON viewer for the web, zero dependencies.",
55
"keywords": [
66
"JSON",
@@ -64,13 +64,13 @@
6464
"space": 2
6565
},
6666
"devDependencies": {
67+
"@rollup/plugin-buble": "0.21.0",
6768
"eslint-plugin-jest": "23.6.0",
6869
"jest": "24.9.0",
6970
"node-sass": "4.13.0",
7071
"postcss-preset-env": "6.7.0",
7172
"prettier": "1.19.1",
7273
"rollup": "1.29.0",
73-
"rollup-plugin-buble": "0.19.8",
7474
"rollup-plugin-postcss": "2.0.3",
7575
"rollup-plugin-uglify": "6.0.4",
7676
"xo": "0.25.3"

rollup.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import buble from 'rollup-plugin-buble';
1+
import buble from '@rollup/plugin-buble';
22
import {uglify} from 'rollup-plugin-uglify';
33
import postcss from 'rollup-plugin-postcss';
44
import postcssPresetEnv from 'postcss-preset-env';

0 commit comments

Comments
 (0)