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

xterm

Package Overview
Dependencies
Maintainers
2
Versions
1092
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xterm - npm Package Compare versions

Comparing version 5.3.0-beta.12 to 5.3.0-beta.13

2

package.json
{
"name": "xterm",
"description": "Full xterm terminal, in your browser",
"version": "5.3.0-beta.12",
"version": "5.3.0-beta.13",
"main": "lib/xterm.js",

@@ -6,0 +6,0 @@ "style": "css/xterm.css",

@@ -0,1 +1,6 @@

/**
* Copyright (c) 2023 The xterm.js authors. All rights reserved.
* @license MIT
*/
export interface IStyleSheet {

@@ -6,9 +11,9 @@ dispose: () => void;

const createCssStyleSheet = (): IStyleSheet => {
const createCssStyleSheet = (doc: Document): IStyleSheet => {
const sheet = new CSSStyleSheet();
document.adoptedStyleSheets.push(sheet);
doc.adoptedStyleSheets.push(sheet);
return {
dispose() {
const index = document.adoptedStyleSheets.indexOf(sheet);
document.adoptedStyleSheets.splice(index, 1);
const index = doc.adoptedStyleSheets.indexOf(sheet);
doc.adoptedStyleSheets.splice(index, 1);
},

@@ -22,3 +27,4 @@ setCss(css) {

const createStyleElement = (parent: HTMLElement): IStyleSheet => {
const element = document.createElement('style');
const doc = parent.ownerDocument;
const element = doc.createElement('style');
parent.append(element);

@@ -37,3 +43,3 @@ return {

try {
return createCssStyleSheet();
return createCssStyleSheet(parent.ownerDocument);
} catch {

@@ -40,0 +46,0 @@ return createStyleElement(parent);

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

Sorry, the diff of this file is not supported yet

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