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

@blinkk/degu

Package Overview
Dependencies
Maintainers
3
Versions
150
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@blinkk/degu - npm Package Compare versions

Comparing version 0.0.335 to 0.0.336

2

lib/dom/dom.d.ts

@@ -15,3 +15,3 @@ export declare class dom {

static event(element: HTMLElement, name: string, data: any): void;
static createElementFromString(htmlString: string): HTMLElement;
static createElementFromString(htmlString: string, fragMethod?: boolean): HTMLElement;
static removeElement(element: HTMLElement): void;

@@ -18,0 +18,0 @@ static runAfterWindowLoad(callback: Function): void;

@@ -101,6 +101,14 @@ "use strict";

}
static createElementFromString(htmlString) {
var div = document.createElement('div');
div.innerHTML = htmlString.trim();
return div.firstChild;
static createElementFromString(htmlString, fragMethod = false) {
if (fragMethod) {
var holder = document.createElement('div');
let frag = document.createRange().createContextualFragment(htmlString);
holder.appendChild(frag);
return holder.firstElementChild;
}
else {
var div = document.createElement('div');
div.innerHTML = htmlString.trim();
return div.firstChild;
}
}

@@ -107,0 +115,0 @@ static removeElement(element) {

@@ -24,10 +24,10 @@ "use strict";

</div>
`);
`, true);
this.mainPanelElement = __1.dom.createElementFromString(`
<div class="${this.nameSpace}__panel"></div>
`);
`, true);
this.mainPanelRefreshButton = __1.dom.createElementFromString(`
<div class="${this.nameSpace}__button">Refresh</div>
`);
this.mainPanelCloseButton = __1.dom.createElementFromString(`<div class="${this.nameSpace}__close">✖️</div>`);
`, true);
this.mainPanelCloseButton = __1.dom.createElementFromString(`<div class="${this.nameSpace}__close">✖️</div>`, true);
this.mainPanelRootElement.append(this.mainPanelCloseButton);

@@ -95,7 +95,7 @@ this.mainPanelRootElement.append(this.mainPanelElement);

<label class="${this.nameSpace}__option"></label>
`);
`, true);
field.element = el;
const title = __1.dom.createElementFromString(`
<div class="${this.nameSpace}__option__title">${field.displayName}</div>
`);
`, true);
const checkbox = __1.dom.createElementFromString(`

@@ -105,3 +105,3 @@ <input type="checkbox"

id="${this.nameSpace}-${field.paramName}">
`);
`, true);
checkbox.setAttribute('checked', url_params_1.urlParams.isTrue(field.paramName) ? 'true' : 'false');

@@ -108,0 +108,0 @@ checkbox.checked = url_params_1.urlParams.isTrue(field.paramName);

{
"name": "@blinkk/degu",
"version": "0.0.335",
"version": "0.0.336",
"description": "A general utility library for interactive websites, with a focus on performance.",

@@ -5,0 +5,0 @@ "author": "Blinkk <hello@blinkk.com>",

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