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

panel

Package Overview
Dependencies
Maintainers
9
Versions
131
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

panel - npm Package Compare versions

Comparing version 1.6.3 to 1.6.4

17

build/isorender/dom-shims.js

@@ -103,3 +103,3 @@ 'use strict';

var registeredElements = {};
var customElementsRegistry = global._customElementsRegistry = global._customElementsRegistry || {};

@@ -109,6 +109,6 @@ var originalCreateElement = Document.prototype.createElement;

tagName = tagName.toLowerCase();
var customElProto = registeredElements[tagName];
var customElClass = customElementsRegistry[tagName];
var el = void 0;
if (customElProto) {
el = new customElProto();
if (customElClass) {
el = new customElClass();
el.nodeName = el.tagName = tagName;

@@ -122,10 +122,13 @@ } else {

global.customElements = global.customElements || {
get: function get(tagName) {
return customElementsRegistry[tagName];
},
define: function define(tagName, proto) {
tagName = tagName.toLowerCase();
if (registeredElements[tagName]) {
throw DOMException('Registration failed for type \'' + tagName + '\'. A type with that name is already registered.');
if (customElementsRegistry[tagName]) {
throw new Error('Registration failed for type \'' + tagName + '\'. A type with that name is already registered.');
} else {
registeredElements[tagName] = proto;
customElementsRegistry[tagName] = proto;
}
}
};

@@ -71,3 +71,3 @@ /* eslint-env node */

const registeredElements = {};
const customElementsRegistry = global._customElementsRegistry = global._customElementsRegistry || {};

@@ -77,6 +77,6 @@ const originalCreateElement = Document.prototype.createElement;

tagName = tagName.toLowerCase();
const customElProto = registeredElements[tagName];
const customElClass = customElementsRegistry[tagName];
let el;
if (customElProto) {
el = new customElProto();
if (customElClass) {
el = new customElClass();
el.nodeName = el.tagName = tagName;

@@ -90,10 +90,14 @@ } else {

global.customElements = global.customElements || {
get(tagName) {
return customElementsRegistry[tagName];
},
define(tagName, proto) {
tagName = tagName.toLowerCase();
if (registeredElements[tagName]) {
throw DOMException(`Registration failed for type '${tagName}'. A type with that name is already registered.`);
if (customElementsRegistry[tagName]) {
throw new Error(`Registration failed for type '${tagName}'. A type with that name is already registered.`);
} else {
registeredElements[tagName] = proto;
customElementsRegistry[tagName] = proto;
}
},
};
{
"name": "panel",
"version": "1.6.3",
"version": "1.6.4",
"description": "Web Components with Virtual DOM: lightweight composable web apps",

@@ -5,0 +5,0 @@ "main": "build/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