New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@atlaskit/inline-dialog

Package Overview
Dependencies
Maintainers
1
Versions
202
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@atlaskit/inline-dialog - npm Package Compare versions

Comparing version 13.0.11 to 13.1.0

dist/cjs/InlineDialog/styled/container.js

11

CHANGELOG.md
# @atlaskit/inline-dialog
## 13.1.0
### Minor Changes
- [`5a049f800d3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5a049f800d3) - Integrates the new tokens package to add support for our new theming solution. This change is fully backwards compatible with our existing theming solution
- [`caec2cee6e0`](https://bitbucket.org/atlassian/atlassian-frontend/commits/caec2cee6e0) - Removes `styled-components` dependency from the package. Also uses ThemeV2 API now. There should be no visual or UX change.
### Patch Changes
- Updated dependencies
## 13.0.11

@@ -4,0 +15,0 @@

39

dist/cjs/InlineDialog/index.js

@@ -28,2 +28,4 @@ "use strict";

var _core = require("@emotion/core");
var _reactNodeResolver = _interopRequireDefault(require("react-node-resolver"));

@@ -35,3 +37,3 @@

var _styled = require("./styled");
var _container = require("./styled/container");

@@ -47,3 +49,3 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }

var packageName = "@atlaskit/inline-dialog";
var packageVersion = "13.0.11";
var packageVersion = "13.1.0";

@@ -98,4 +100,7 @@ var InlineDialog = /*#__PURE__*/function (_Component) {

return;
}
} // added here to clean up component unmounting, which is not done in ref
this.containerRef = null;
if (!prevProps.isOpen && this.props.isOpen) {

@@ -141,27 +146,29 @@ window.addEventListener('click', this.handleClickOutside, true);

testId = _this$props2.testId;
var popper = isOpen ? /*#__PURE__*/_react.default.createElement(_popper.Popper, {
var popper = isOpen ? (0, _core.jsx)(_popper.Popper, {
placement: placement
}, function (_ref) {
var ref = _ref.ref,
var _ref2 = _ref.ref,
style = _ref.style;
return /*#__PURE__*/_react.default.createElement(_styled.Container, {
return (0, _core.jsx)(_container.Container, {
onBlur: onContentBlur,
onFocus: onContentFocus,
onClick: onContentClick,
innerRef: function innerRef(node) {
_this2.containerRef = node;
ref: function ref(node) {
if (node) {
_this2.containerRef = node;
if (typeof ref === 'function') {
ref(node);
} else {
ref.current = node;
if (typeof _ref2 === 'function') {
_ref2(node);
} else {
_ref2.current = node;
}
}
},
style: style,
"data-testid": testId
testId: testId
}, content);
}) : null;
return /*#__PURE__*/_react.default.createElement(_popper.Manager, null, /*#__PURE__*/_react.default.createElement(_popper.Reference, null, function (_ref2) {
var ref = _ref2.ref;
return /*#__PURE__*/_react.default.createElement(_reactNodeResolver.default, {
return (0, _core.jsx)(_popper.Manager, null, (0, _core.jsx)(_popper.Reference, null, function (_ref3) {
var ref = _ref3.ref;
return (0, _core.jsx)(_reactNodeResolver.default, {
innerRef: function innerRef(node) {

@@ -168,0 +175,0 @@ _this2.triggerRef = node;

{
"name": "@atlaskit/inline-dialog",
"version": "13.0.11",
"version": "13.1.0",
"sideEffects": false
}
import _defineProperty from "@babel/runtime/helpers/defineProperty";
/** @jsx jsx */
import React, { Component } from 'react';
import { jsx } from '@emotion/core';
import NodeResolver from 'react-node-resolver';
import { createAndFireEvent, withAnalyticsContext, withAnalyticsEvents } from '@atlaskit/analytics-next';
import { Manager, Popper, Reference } from '@atlaskit/popper';
import { Container } from './styled';
import { Container } from './styled/container';
const packageName = "@atlaskit/inline-dialog";
const packageVersion = "13.0.11";
const packageVersion = "13.1.0";

@@ -47,4 +50,7 @@ class InlineDialog extends Component {

return;
}
} // added here to clean up component unmounting, which is not done in ref
this.containerRef = null;
if (!prevProps.isOpen && this.props.isOpen) {

@@ -86,3 +92,3 @@ window.addEventListener('click', this.handleClickOutside, true);

} = this.props;
const popper = isOpen ? /*#__PURE__*/React.createElement(Popper, {
const popper = isOpen ? jsx(Popper, {
placement: placement

@@ -92,21 +98,23 @@ }, ({

style
}) => /*#__PURE__*/React.createElement(Container, {
}) => jsx(Container, {
onBlur: onContentBlur,
onFocus: onContentFocus,
onClick: onContentClick,
innerRef: node => {
this.containerRef = node;
ref: node => {
if (node) {
this.containerRef = node;
if (typeof ref === 'function') {
ref(node);
} else {
ref.current = node;
if (typeof ref === 'function') {
ref(node);
} else {
ref.current = node;
}
}
},
style: style,
"data-testid": testId
testId: testId
}, content)) : null;
return /*#__PURE__*/React.createElement(Manager, null, /*#__PURE__*/React.createElement(Reference, null, ({
return jsx(Manager, null, jsx(Reference, null, ({
ref
}) => /*#__PURE__*/React.createElement(NodeResolver, {
}) => jsx(NodeResolver, {
innerRef: node => {

@@ -113,0 +121,0 @@ this.triggerRef = node;

{
"name": "@atlaskit/inline-dialog",
"version": "13.0.11",
"version": "13.1.0",
"sideEffects": false
}

@@ -13,9 +13,11 @@ import _classCallCheck from "@babel/runtime/helpers/classCallCheck";

/** @jsx jsx */
import React, { Component } from 'react';
import { jsx } from '@emotion/core';
import NodeResolver from 'react-node-resolver';
import { createAndFireEvent, withAnalyticsContext, withAnalyticsEvents } from '@atlaskit/analytics-next';
import { Manager, Popper, Reference } from '@atlaskit/popper';
import { Container } from './styled';
import { Container } from './styled/container';
var packageName = "@atlaskit/inline-dialog";
var packageVersion = "13.0.11";
var packageVersion = "13.1.0";

@@ -72,4 +74,7 @@ var InlineDialog = /*#__PURE__*/function (_Component) {

return;
}
} // added here to clean up component unmounting, which is not done in ref
this.containerRef = null;
if (!prevProps.isOpen && this.props.isOpen) {

@@ -115,27 +120,29 @@ window.addEventListener('click', this.handleClickOutside, true);

testId = _this$props2.testId;
var popper = isOpen ? /*#__PURE__*/React.createElement(Popper, {
var popper = isOpen ? jsx(Popper, {
placement: placement
}, function (_ref) {
var ref = _ref.ref,
var _ref2 = _ref.ref,
style = _ref.style;
return /*#__PURE__*/React.createElement(Container, {
return jsx(Container, {
onBlur: onContentBlur,
onFocus: onContentFocus,
onClick: onContentClick,
innerRef: function innerRef(node) {
_this2.containerRef = node;
ref: function ref(node) {
if (node) {
_this2.containerRef = node;
if (typeof ref === 'function') {
ref(node);
} else {
ref.current = node;
if (typeof _ref2 === 'function') {
_ref2(node);
} else {
_ref2.current = node;
}
}
},
style: style,
"data-testid": testId
testId: testId
}, content);
}) : null;
return /*#__PURE__*/React.createElement(Manager, null, /*#__PURE__*/React.createElement(Reference, null, function (_ref2) {
var ref = _ref2.ref;
return /*#__PURE__*/React.createElement(NodeResolver, {
return jsx(Manager, null, jsx(Reference, null, function (_ref3) {
var ref = _ref3.ref;
return jsx(NodeResolver, {
innerRef: function innerRef(node) {

@@ -142,0 +149,0 @@ _this2.triggerRef = node;

{
"name": "@atlaskit/inline-dialog",
"version": "13.0.11",
"version": "13.1.0",
"sideEffects": false
}

@@ -0,4 +1,5 @@

/** @jsx jsx */
import React, { Component } from 'react';
import { Placement, Props } from '../types';
declare class InlineDialog extends Component<Props, {}> {
import { InlineDialogProps, Placement } from '../types';
declare class InlineDialog extends Component<InlineDialogProps> {
static defaultProps: {

@@ -12,5 +13,5 @@ isOpen: boolean;

};
containerRef?: HTMLElement;
containerRef?: HTMLElement | null;
triggerRef?: HTMLElement;
componentDidUpdate(prevProps: Props): void;
componentDidUpdate(prevProps: InlineDialogProps): void;
componentDidMount(): void;

@@ -22,3 +23,3 @@ componentWillUnmount(): void;

export { InlineDialog as InlineDialogWithoutAnalytics };
declare const _default: React.ForwardRefExoticComponent<Pick<Pick<Pick<Props, "children" | "content" | "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement" | "testId">, "children" | "content" | "testId"> & Partial<Pick<Pick<Props, "children" | "content" | "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement" | "testId">, "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement">> & Partial<Pick<{
declare const _default: React.ForwardRefExoticComponent<Pick<Pick<Pick<InlineDialogProps, "content" | "children" | "testId" | "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement">, "content" | "children" | "testId"> & Partial<Pick<Pick<InlineDialogProps, "content" | "children" | "testId" | "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement">, "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement">> & Partial<Pick<{
isOpen: boolean;

@@ -30,3 +31,3 @@ onContentBlur: () => void;

placement: Placement;
}, never>> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "children" | "content" | "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement" | "testId" | "key" | "analyticsContext"> & React.RefAttributes<any>>;
}, never>> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "content" | "children" | "testId" | "isOpen" | "onContentBlur" | "onContentClick" | "onContentFocus" | "onClose" | "placement" | "key" | "analyticsContext"> & React.RefAttributes<any>>;
export default _default;
import { ReactNode } from 'react';
import { WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
export declare type Placement = 'auto-start' | 'auto' | 'auto-end' | 'top-start' | 'top' | 'top-end' | 'right-start' | 'right' | 'right-end' | 'bottom-end' | 'bottom' | 'bottom-start' | 'left-end' | 'left' | 'left-start';
export interface Props extends WithAnalyticsEventsProps {
/** The elements that the InlineDialog will be positioned relative to. */
export interface InlineDialogProps extends WithAnalyticsEventsProps {
/**
* The elements that the InlineDialog will be positioned relative to.
*/
children: ReactNode;
/** The elements to be displayed within the InlineDialog. */
/**
* The elements to be displayed within the InlineDialog.
*/
content: ReactNode;
/** Sets whether to show or hide the dialog. */
/**
* Sets whether to show or hide the dialog.
*/
isOpen?: boolean;
/** Function called when you lose focus on the object. */
/**
* Function called when you lose focus on the object.
*/
onContentBlur?: () => void;
/** Function called when you click on the open dialog. */
/**
* Function called when user clicks on the open dialog.
*/
onContentClick?: () => void;
/** Function called when you focus on the open dialog. */
/**
* Function called when user focuses on the open dialog.
*/
onContentFocus?: () => void;
/** Function called when the dialog is open and a click occurs anywhere outside
the dialog. */
/**
* Function called when the dialog is open and a click occurs anywhere outside
* the dialog.
*/
onClose?: (obj: {

@@ -23,6 +37,10 @@ isOpen: boolean;

}) => void;
/** Where the dialog should appear, relative to the contents of the children. */
/**
* Where the dialog should appear, relative to the contents of the children.
*/
placement?: Placement;
/** A `testId` prop is provided for specified elements, which is a unique string that appears as a data attribute `data-testid` in the rendered code, serving as a hook for automated tests */
/**
* A `testId` prop is provided for specified elements, which is a unique string that appears as a data attribute `data-testid` in the rendered code, serving as a hook for automated tests
*/
testId?: string;
}
{
"name": "@atlaskit/inline-dialog",
"version": "13.0.11",
"version": "13.1.0",
"description": "An inline dialog is a pop-up container for small amounts of information. It can also contain controls.",

@@ -16,3 +16,3 @@ "publishConfig": {

"sideEffects": false,
"atlaskit:src": "src/index.ts",
"atlaskit:src": "src/index.tsx",
"atlassian": {

@@ -30,16 +30,18 @@ "team": "Design System Team",

"@atlaskit/popper": "^5.0.0",
"@atlaskit/theme": "^11.3.0",
"@atlaskit/theme": "^11.4.0",
"@atlaskit/tokens": "^0.1.0",
"@babel/runtime": "^7.0.0",
"@emotion/core": "^10.0.9",
"react-node-resolver": "^1.0.1"
},
"peerDependencies": {
"react": "^16.8.0",
"styled-components": "^3.2.6"
"react": "^16.8.0"
},
"devDependencies": {
"@atlaskit/build-utils": "*",
"@atlaskit/button": "^15.1.0",
"@atlaskit/datetime-picker": "^10.4.0",
"@atlaskit/button": "^16.1.0",
"@atlaskit/datetime-picker": "^11.0.0",
"@atlaskit/docs": "*",
"@atlaskit/icon": "^21.7.0",
"@atlaskit/section-message": "^6.1.0",
"@atlaskit/select": "^15.0.0",

@@ -66,2 +68,12 @@ "@atlaskit/single-select": "^10.0.0",

"import-structure": "atlassian-conventions"
},
"@repo/internal": {
"analytics": "analytics-next",
"theming": [
"new-theming-api",
"tokens"
],
"styling": "emotion",
"design-system": "v1",
"deprecation": "no-deprecated-imports"
}

@@ -68,0 +80,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