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

react-aria-modal

Package Overview
Dependencies
Maintainers
2
Versions
44
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-aria-modal - npm Package Compare versions

Comparing version 2.11.1 to 2.12.0

4

CHANGELOG.md
# Changelog
## 2.12.0
- Add `focusTrapOptions` prop to pass options to the focus trap.
## 2.11.1

@@ -4,0 +8,0 @@

9

dist/react-aria-modal.js

@@ -209,6 +209,9 @@ 'use strict';

var focusTrapOptions = props.focusTrapOptions || {};
if (props.focusDialog || props.initialFocus) {
focusTrapOptions.initialFocus = props.focusDialog ? '#' + this.props.dialogId : props.initialFocus;
}
return React.createElement(FocusTrap, {
focusTrapOptions: {
initialFocus: props.focusDialog ? '#' + this.props.dialogId : props.initialFocus
},
focusTrapOptions: focusTrapOptions,
paused: props.focusTrapPaused

@@ -215,0 +218,0 @@ }, React.createElement('div', underlayProps, childrenArray));

{
"name": "react-aria-modal",
"version": "2.11.1",
"version": "2.12.0",
"description": "A fully accessible and flexible React modal built according WAI-ARIA Authoring Practices",

@@ -5,0 +5,0 @@ "main": "dist/react-aria-modal.js",

@@ -349,2 +349,9 @@ # react-aria-modal

### focusTrapOptions
Type: `object`
Customize properties of the `focusTrapOptions` prop that is passed to the modal dialog's [focus trap](https://github.com/davidtheclark/focus-trap).
For example, you can use this prop if you need better control of where focus is returned.
### scrollDisabled

@@ -351,0 +358,0 @@

@@ -201,9 +201,12 @@ const React = require('react');

const focusTrapOptions = props.focusTrapOptions || {};
if (props.focusDialog || props.initialFocus) {
focusTrapOptions.initialFocus = props.focusDialog
? `#${this.props.dialogId}`
: props.initialFocus
}
return React.createElement(FocusTrap,
{
focusTrapOptions: {
initialFocus: props.focusDialog
? `#${this.props.dialogId}`
: props.initialFocus
},
focusTrapOptions,
paused: props.focusTrapPaused

@@ -210,0 +213,0 @@ },

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