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

@rc-component/portal

Package Overview
Dependencies
Maintainers
2
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rc-component/portal - npm Package Compare versions

Comparing version 1.0.0-8 to 1.0.0-9

7

es/Portal.js

@@ -42,5 +42,4 @@ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";

mergedRender = _React$useState2[0],
setMergedRender = _React$useState2[1];
setMergedRender = _React$useState2[1]; // ====================== Should Render ======================
useScrollLocker(autoLock && open); // ====================== Should Render ======================

@@ -71,3 +70,5 @@ React.useEffect(function () {

var mergedContainer = innerContainer !== null && innerContainer !== void 0 ? innerContainer : defaultContainer; // ========================= Render ==========================
var mergedContainer = innerContainer !== null && innerContainer !== void 0 ? innerContainer : defaultContainer; // ========================= Locker ==========================
useScrollLocker(autoLock && open && canUseDom() && (mergedContainer === defaultContainer || mergedContainer === document.body)); // ========================= Render ==========================
// Do not render when nothing need render

@@ -74,0 +75,0 @@ // When innerContainer is `undefined`, it may not ready since user use ref in the same render

@@ -60,5 +60,4 @@ "use strict";

mergedRender = _React$useState2[0],
setMergedRender = _React$useState2[1];
setMergedRender = _React$useState2[1]; // ====================== Should Render ======================
(0, _useScrollLocker.default)(autoLock && open); // ====================== Should Render ======================

@@ -89,3 +88,5 @@ React.useEffect(function () {

var mergedContainer = innerContainer !== null && innerContainer !== void 0 ? innerContainer : defaultContainer; // ========================= Render ==========================
var mergedContainer = innerContainer !== null && innerContainer !== void 0 ? innerContainer : defaultContainer; // ========================= Locker ==========================
(0, _useScrollLocker.default)(autoLock && open && (0, _canUseDom.default)() && (mergedContainer === defaultContainer || mergedContainer === document.body)); // ========================= Render ==========================
// Do not render when nothing need render

@@ -92,0 +93,0 @@ // When innerContainer is `undefined`, it may not ready since user use ref in the same render

{
"name": "@rc-component/portal",
"version": "1.0.0-8",
"version": "1.0.0-9",
"description": "React Portal Component",

@@ -5,0 +5,0 @@ "keywords": [

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