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

@xiee/utils

Package Overview
Dependencies
Maintainers
1
Versions
173
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@xiee/utils - npm Package Compare versions

Comparing version 1.4.1 to 1.4.2

2

js/fold-details.js

@@ -23,3 +23,3 @@ // fold elements with <details>: https://yihui.org/en/2023/09/code-folding/

btn.id = 'toggle-all';
btn.innerText = cfg.label || 'Toggle Details';
btn.innerText = cfg.buttonLabel || 'Toggle Details';
p.insertAdjacentElement(cfg.position || 'afterbegin', btn);

@@ -26,0 +26,0 @@ }

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

(e=>{const t=e.currentScript?.dataset,a="folder";if(e.querySelectorAll(t?.selector||"pre>code[class],pre[class]").forEach((r=>{const l=e.createElement("details"),n=e.createElement("summary");l.className=a,l.open=t?.open,n.innerText=(t?.label||"Details")+(t?.tagName?` <${r.tagName}>`:""),"CODE"===r.tagName&&"PRE"===r.parentNode.tagName&&(r=r.parentNode),l.append(n),r.before(l),l.append(r)})),!t?.hasOwnProperty("button"))return;const r=e.querySelector(t.parent);let l=e.querySelector(t.button);(l||r)&&(l||(l=e.createElement("button"),l.id="toggle-all",l.innerText=t.label||"Toggle Details",r.insertAdjacentElement(t.position||"afterbegin",l)),l.onclick=t=>{e.querySelectorAll(`details.${a}`).forEach((e=>{e.toggleAttribute("open")}))})})(document);
(e=>{const t=e.currentScript?.dataset,a="folder";if(e.querySelectorAll(t?.selector||"pre>code[class],pre[class]").forEach((r=>{const n=e.createElement("details"),l=e.createElement("summary");n.className=a,n.open=t?.open,l.innerText=(t?.label||"Details")+(t?.tagName?` <${r.tagName}>`:""),"CODE"===r.tagName&&"PRE"===r.parentNode.tagName&&(r=r.parentNode),n.append(l),r.before(n),n.append(r)})),!t?.hasOwnProperty("button"))return;const r=e.querySelector(t.parent);let n=e.querySelector(t.button);(n||r)&&(n||(n=e.createElement("button"),n.id="toggle-all",n.innerText=t.buttonLabel||"Toggle Details",r.insertAdjacentElement(t.position||"afterbegin",n)),n.onclick=t=>{e.querySelectorAll(`details.${a}`).forEach((e=>{e.toggleAttribute("open")}))})})(document);
{
"name": "@xiee/utils",
"version": "1.4.1",
"version": "1.4.2",
"description": "Miscellaneous tools and utilities to manipulate HTML pages",

@@ -5,0 +5,0 @@ "scripts": {

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