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

@radix-ui/react-focus-guards

Package Overview
Dependencies
Maintainers
5
Versions
80
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@radix-ui/react-focus-guards - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

2

dist/index.js

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

function e(e,t,n){Object.defineProperty(e,t,{get:n,enumerable:!0})}var t,n=require("react").useEffect,r=(t=require("@babel/runtime-corejs3/core-js-stable/instance/for-each"))&&t.__esModule?t.default:t,u={},o=0;function c(e){return a(),e.children}function a(){n((function(){var e,t,n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(e=n[0])&&void 0!==e?e:d()),document.body.insertAdjacentElement("beforeend",null!==(t=n[1])&&void 0!==t?t:d()),o++,function(){var e;1===o&&r(e=document.querySelectorAll("[data-radix-focus-guard]")).call(e,(function(e){return e.remove()}));o--}}),[])}function d(){var e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}exports.FocusGuards=c,exports.useFocusGuards=a;var i=c;exports.Root=i,e(u,"useFocusGuards",(function(){return a})),e(u,"Root",(function(){return i})),e(u,"FocusGuards",(function(){return c}));
function e(e,t,n){Object.defineProperty(e,t,{get:n,enumerable:!0})}var t=require("react").useEffect,n={};let r=0;function o(e){return u(),e.children}function u(){t((()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(e=n[0])&&void 0!==e?e:c()),document.body.insertAdjacentElement("beforeend",null!==(t=n[1])&&void 0!==t?t:c()),r++,()=>{1===r&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),r--}}),[])}function c(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}exports.FocusGuards=o,exports.useFocusGuards=u;const d=o;exports.Root=d,e(n,"useFocusGuards",(function(){return u})),e(n,"Root",(function(){return d})),e(n,"FocusGuards",(function(){return o}));
//# sourceMappingURL=index.js.map

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

function e(e,t,n){Object.defineProperty(e,t,{get:n,enumerable:!0})}import{useEffect as t}from"react";import n from"@babel/runtime-corejs3/core-js-stable/instance/for-each";var r={},o=0;function u(e){return useFocusGuards(),e.children}export{u as FocusGuards};export function useFocusGuards(){t((function(){var e,t,r=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(e=r[0])&&void 0!==e?e:c()),document.body.insertAdjacentElement("beforeend",null!==(t=r[1])&&void 0!==t?t:c()),o++,function(){var e;1===o&&n(e=document.querySelectorAll("[data-radix-focus-guard]")).call(e,(function(e){return e.remove()}));o--}}),[])}function c(){var e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}export var Root=u;e(r,"useFocusGuards",(function(){return useFocusGuards})),e(r,"Root",(function(){return Root})),e(r,"FocusGuards",(function(){return u}));
function e(e,t,n){Object.defineProperty(e,t,{get:n,enumerable:!0})}import{useEffect as t}from"react";var n={};let o=0;function r(e){return useFocusGuards(),e.children}export{r as FocusGuards};export function useFocusGuards(){t((()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(e=n[0])&&void 0!==e?e:u()),document.body.insertAdjacentElement("beforeend",null!==(t=n[1])&&void 0!==t?t:u()),o++,()=>{1===o&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),o--}}),[])}function u(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}export const Root=r;e(n,"useFocusGuards",(function(){return useFocusGuards})),e(n,"Root",(function(){return Root})),e(n,"FocusGuards",(function(){return r}));
//# sourceMappingURL=index.module.js.map
{
"name": "@radix-ui/react-focus-guards",
"version": "0.0.4",
"version": "0.0.5",
"license": "MIT",

@@ -31,4 +31,4 @@ "source": "src/index.ts",

"dependencies": {
"@babel/runtime-corejs3": "^7.13.10"
"@babel/runtime": "^7.13.10"
}
}

Sorry, the diff of this file is not supported yet

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