@atlaskit/onboarding 11.10.2 → 11.10.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/dist/cjs/components/modal.js +2 -1
- package/dist/cjs/components/spotlight-card.js +1 -1
- package/dist/cjs/components/spotlight-dialog.js +1 -1
- package/dist/cjs/styled/blanket.js +2 -1
- package/dist/cjs/styled/dialog.js +1 -1
- package/dist/cjs/styled/modal.js +1 -1
- package/dist/cjs/styled/target.js +1 -1
- package/dist/es2019/components/modal.js +1 -1
- package/dist/es2019/components/spotlight-card.js +1 -1
- package/dist/es2019/components/spotlight-dialog.js +1 -1
- package/dist/es2019/components/spotlight.js +1 -0
- package/dist/es2019/styled/blanket.js +1 -1
- package/dist/es2019/styled/dialog.js +1 -1
- package/dist/es2019/styled/modal.js +1 -1
- package/dist/es2019/styled/target.js +1 -1
- package/dist/esm/components/modal.js +1 -1
- package/dist/esm/components/spotlight-card.js +1 -1
- package/dist/esm/components/spotlight-dialog.js +1 -1
- package/dist/esm/components/spotlight.js +1 -0
- package/dist/esm/styled/blanket.js +1 -1
- package/dist/esm/styled/dialog.js +1 -1
- package/dist/esm/styled/modal.js +1 -1
- package/dist/esm/styled/target.js +1 -1
- package/dist/types/components/modal.d.ts +1 -1
- package/dist/types/components/spotlight-card.d.ts +1 -1
- package/dist/types/components/spotlight-inner.d.ts +1 -2
- package/dist/types/components/spotlight.d.ts +2 -89
- package/dist/types/styled/blanket.d.ts +1 -1
- package/dist/types/styled/dialog.d.ts +1 -1
- package/dist/types/styled/modal.d.ts +1 -1
- package/dist/types/styled/target.d.ts +1 -1
- package/dist/types/types.d.ts +88 -1
- package/dist/types-ts4.5/components/modal.d.ts +1 -1
- package/dist/types-ts4.5/components/spotlight-card.d.ts +1 -1
- package/dist/types-ts4.5/components/spotlight-inner.d.ts +1 -2
- package/dist/types-ts4.5/components/spotlight.d.ts +2 -89
- package/dist/types-ts4.5/styled/blanket.d.ts +1 -1
- package/dist/types-ts4.5/styled/dialog.d.ts +1 -1
- package/dist/types-ts4.5/styled/modal.d.ts +1 -1
- package/dist/types-ts4.5/styled/target.d.ts +1 -1
- package/dist/types-ts4.5/types.d.ts +88 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @atlaskit/onboarding
|
|
2
2
|
|
|
3
|
+
## 11.10.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#125754](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/125754)
|
|
8
|
+
[`aa57c66a5b798`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/aa57c66a5b798) -
|
|
9
|
+
Migrating ipm-choreographer out of post-office and into platform. Fixing tests and lint checks for
|
|
10
|
+
ipm-choreographer, and adding a bugfix for Engagekit. Also, a minor change to @atlaskit/onboarding
|
|
11
|
+
to export the SpotlightProps interface.
|
|
12
|
+
|
|
13
|
+
## 11.10.3
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- Updated dependencies
|
|
18
|
+
|
|
3
19
|
## 11.10.2
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
|
@@ -28,7 +28,8 @@ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e;
|
|
|
28
28
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
29
29
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
30
30
|
* @jsxRuntime classic
|
|
31
|
-
|
|
31
|
+
* @jsx jsx
|
|
32
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
32
33
|
// TODO: DSP-1250 - use a composable API consistent with normal modal dialog
|
|
33
34
|
/**
|
|
34
35
|
* __Benefits modal__
|
|
@@ -17,8 +17,8 @@ var _theme = require("./theme");
|
|
|
17
17
|
var _excluded = ["text", "key"];
|
|
18
18
|
/**
|
|
19
19
|
* @jsxRuntime classic
|
|
20
|
+
* @jsx jsx
|
|
20
21
|
*/
|
|
21
|
-
/** @jsx jsx */
|
|
22
22
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
23
23
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
24
24
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
@@ -27,7 +27,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
27
27
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
28
28
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
29
29
|
var packageName = "@atlaskit/onboarding";
|
|
30
|
-
var packageVersion = "11.10.
|
|
30
|
+
var packageVersion = "11.10.4";
|
|
31
31
|
var SpotlightDialogComponent = /*#__PURE__*/function (_Component) {
|
|
32
32
|
(0, _inherits2.default)(SpotlightDialogComponent, _Component);
|
|
33
33
|
var _super = _createSuper(SpotlightDialogComponent);
|
|
@@ -12,7 +12,8 @@ var _constants = require("@atlaskit/theme/constants");
|
|
|
12
12
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
13
13
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /**
|
|
14
14
|
* @jsxRuntime classic
|
|
15
|
-
|
|
15
|
+
* @jsx jsx
|
|
16
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
16
17
|
// IE11 and Edge: z-index needed because fixed position calculates z-index relative
|
|
17
18
|
// to body instead of nearest stacking context (Portal in our case).
|
|
18
19
|
var blanketStyles = (0, _react.css)({
|
|
@@ -11,8 +11,8 @@ var _react = require("@emotion/react");
|
|
|
11
11
|
var _excluded = ["alt"];
|
|
12
12
|
/**
|
|
13
13
|
* @jsxRuntime classic
|
|
14
|
+
* @jsx jsx
|
|
14
15
|
*/
|
|
15
|
-
/** @jsx jsx */
|
|
16
16
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
17
17
|
var imageStyles = (0, _react.css)({
|
|
18
18
|
maxWidth: '100%',
|
package/dist/cjs/styled/modal.js
CHANGED
|
@@ -9,8 +9,8 @@ var _typography = require("@atlaskit/theme/typography");
|
|
|
9
9
|
/* eslint-disable @atlaskit/design-system/no-nested-styles */
|
|
10
10
|
/**
|
|
11
11
|
* @jsxRuntime classic
|
|
12
|
+
* @jsx jsx
|
|
12
13
|
*/
|
|
13
|
-
/** @jsx jsx */
|
|
14
14
|
|
|
15
15
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
16
16
|
|
|
@@ -16,8 +16,8 @@ var _excluded = ["children", "bgColor", "radius", "style", "testId"],
|
|
|
16
16
|
_excluded3 = ["children", "pulse", "testId"];
|
|
17
17
|
/**
|
|
18
18
|
* @jsxRuntime classic
|
|
19
|
+
* @jsx jsx
|
|
19
20
|
*/
|
|
20
|
-
/** @jsx jsx */
|
|
21
21
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
22
22
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
23
23
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -2,8 +2,8 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
/**
|
|
4
4
|
* @jsxRuntime classic
|
|
5
|
+
* @jsx jsx
|
|
5
6
|
*/
|
|
6
|
-
/** @jsx jsx */
|
|
7
7
|
import { Component } from 'react';
|
|
8
8
|
|
|
9
9
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
@@ -7,7 +7,7 @@ import { DialogImage } from '../styled/dialog';
|
|
|
7
7
|
import SpotlightCard from './spotlight-card';
|
|
8
8
|
import ValueChanged from './value-changed';
|
|
9
9
|
const packageName = "@atlaskit/onboarding";
|
|
10
|
-
const packageVersion = "11.10.
|
|
10
|
+
const packageVersion = "11.10.4";
|
|
11
11
|
class SpotlightDialogComponent extends Component {
|
|
12
12
|
constructor(...args) {
|
|
13
13
|
super(...args);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/**
|
|
3
3
|
* @jsxRuntime classic
|
|
4
|
+
* @jsx jsx
|
|
4
5
|
*/
|
|
5
|
-
/** @jsx jsx */
|
|
6
6
|
|
|
7
7
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/design-system/no-nested-styles */
|
|
2
2
|
/**
|
|
3
3
|
* @jsxRuntime classic
|
|
4
|
+
* @jsx jsx
|
|
4
5
|
*/
|
|
5
|
-
/** @jsx jsx */
|
|
6
6
|
|
|
7
7
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
/**
|
|
3
3
|
* @jsxRuntime classic
|
|
4
|
+
* @jsx jsx
|
|
4
5
|
*/
|
|
5
|
-
/** @jsx jsx */
|
|
6
6
|
|
|
7
7
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
8
|
import { css, jsx, keyframes } from '@emotion/react';
|
|
@@ -13,8 +13,8 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
13
13
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
14
14
|
/**
|
|
15
15
|
* @jsxRuntime classic
|
|
16
|
+
* @jsx jsx
|
|
16
17
|
*/
|
|
17
|
-
/** @jsx jsx */
|
|
18
18
|
import { Component } from 'react';
|
|
19
19
|
|
|
20
20
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
@@ -2,8 +2,8 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
2
2
|
var _excluded = ["text", "key"];
|
|
3
3
|
/**
|
|
4
4
|
* @jsxRuntime classic
|
|
5
|
+
* @jsx jsx
|
|
5
6
|
*/
|
|
6
|
-
/** @jsx jsx */
|
|
7
7
|
import { forwardRef } from 'react';
|
|
8
8
|
|
|
9
9
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
@@ -17,7 +17,7 @@ import { DialogImage } from '../styled/dialog';
|
|
|
17
17
|
import SpotlightCard from './spotlight-card';
|
|
18
18
|
import ValueChanged from './value-changed';
|
|
19
19
|
var packageName = "@atlaskit/onboarding";
|
|
20
|
-
var packageVersion = "11.10.
|
|
20
|
+
var packageVersion = "11.10.4";
|
|
21
21
|
var SpotlightDialogComponent = /*#__PURE__*/function (_Component) {
|
|
22
22
|
_inherits(SpotlightDialogComponent, _Component);
|
|
23
23
|
var _super = _createSuper(SpotlightDialogComponent);
|
|
@@ -3,8 +3,8 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
4
|
/**
|
|
5
5
|
* @jsxRuntime classic
|
|
6
|
+
* @jsx jsx
|
|
6
7
|
*/
|
|
7
|
-
/** @jsx jsx */
|
|
8
8
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
9
9
|
import { css, jsx } from '@emotion/react';
|
|
10
10
|
import { N100A } from '@atlaskit/theme/colors';
|
|
@@ -3,8 +3,8 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
3
3
|
var _excluded = ["alt"];
|
|
4
4
|
/**
|
|
5
5
|
* @jsxRuntime classic
|
|
6
|
+
* @jsx jsx
|
|
6
7
|
*/
|
|
7
|
-
/** @jsx jsx */
|
|
8
8
|
|
|
9
9
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
10
10
|
import { css, jsx } from '@emotion/react';
|
package/dist/esm/styled/modal.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/* eslint-disable @atlaskit/design-system/no-nested-styles */
|
|
2
2
|
/**
|
|
3
3
|
* @jsxRuntime classic
|
|
4
|
+
* @jsx jsx
|
|
4
5
|
*/
|
|
5
|
-
/** @jsx jsx */
|
|
6
6
|
|
|
7
7
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
@@ -8,8 +8,8 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
8
8
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
9
9
|
/**
|
|
10
10
|
* @jsxRuntime classic
|
|
11
|
+
* @jsx jsx
|
|
11
12
|
*/
|
|
12
|
-
/** @jsx jsx */
|
|
13
13
|
|
|
14
14
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
15
15
|
import { css, jsx, keyframes } from '@emotion/react';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
3
4
|
*/
|
|
4
|
-
/** @jsx jsx */
|
|
5
5
|
import { Component, type ElementType, type ReactNode } from 'react';
|
|
6
6
|
import { jsx } from '@emotion/react';
|
|
7
7
|
import { type ModalFooterProps as FooterComponentProps, type ModalHeaderProps as HeaderComponentProps } from '@atlaskit/modal-dialog';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { type ScrollLogicalPosition } from '../types';
|
|
2
|
+
import { type ScrollLogicalPosition, type SpotlightProps } from '../types';
|
|
3
3
|
import { type ElementBoundingBox } from '../utils/use-element-box';
|
|
4
|
-
import { type SpotlightProps } from './spotlight';
|
|
5
4
|
export interface SpotlightInnerProps extends SpotlightProps {
|
|
6
5
|
/**
|
|
7
6
|
* The spotlight target DOM element.
|
|
@@ -1,92 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import { type
|
|
3
|
-
export interface SpotlightProps {
|
|
4
|
-
/**
|
|
5
|
-
* Buttons to render in the footer.
|
|
6
|
-
*/
|
|
7
|
-
actions?: Actions;
|
|
8
|
-
/**
|
|
9
|
-
* An optional node to be rendered beside the footer actions.
|
|
10
|
-
*/
|
|
11
|
-
actionsBeforeElement?: ReactNode;
|
|
12
|
-
/**
|
|
13
|
-
* The elements rendered in the modal.
|
|
14
|
-
*/
|
|
15
|
-
children?: ReactNode;
|
|
16
|
-
/**
|
|
17
|
-
* Where the dialog should appear, relative to the contents of the children.
|
|
18
|
-
*/
|
|
19
|
-
dialogPlacement?: 'top left' | 'top center' | 'top right' | 'right top' | 'right middle' | 'right bottom' | 'bottom left' | 'bottom center' | 'bottom right' | 'left top' | 'left middle' | 'left bottom';
|
|
20
|
-
/**
|
|
21
|
-
* The width of the dialog in pixels. The minimum possible width is 160px and the maximum width is 600px.
|
|
22
|
-
*/
|
|
23
|
-
dialogWidth?: number;
|
|
24
|
-
/**
|
|
25
|
-
* Optional element rendered below the body.
|
|
26
|
-
*/
|
|
27
|
-
footer?: ComponentType<any>;
|
|
28
|
-
/**
|
|
29
|
-
* Optional element rendered above the body.
|
|
30
|
-
*/
|
|
31
|
-
header?: ComponentType<any>;
|
|
32
|
-
/**
|
|
33
|
-
* Heading text rendered above the body.
|
|
34
|
-
*/
|
|
35
|
-
heading?: string;
|
|
36
|
-
/**
|
|
37
|
-
* An optional element rendered to the right of the heading.
|
|
38
|
-
*/
|
|
39
|
-
headingAfterElement?: ReactNode;
|
|
40
|
-
/**
|
|
41
|
-
* Path to the image.
|
|
42
|
-
*/
|
|
43
|
-
image?: string;
|
|
44
|
-
/**
|
|
45
|
-
* Whether or not to display a pulse animation around the spotlighted element.
|
|
46
|
-
*/
|
|
47
|
-
pulse?: boolean;
|
|
48
|
-
/**
|
|
49
|
-
* The name of the SpotlightTarget.
|
|
50
|
-
*/
|
|
51
|
-
target?: string;
|
|
52
|
-
/**
|
|
53
|
-
* The spotlight target node.
|
|
54
|
-
*/
|
|
55
|
-
targetNode?: HTMLElement;
|
|
56
|
-
/**
|
|
57
|
-
* The background color of the element being highlighted.
|
|
58
|
-
*/
|
|
59
|
-
targetBgColor?: string;
|
|
60
|
-
/**
|
|
61
|
-
* Function to fire when a person clicks on the cloned target.
|
|
62
|
-
*/
|
|
63
|
-
targetOnClick?: (eventData: {
|
|
64
|
-
event: MouseEvent<HTMLElement>;
|
|
65
|
-
target?: string;
|
|
66
|
-
}) => void;
|
|
67
|
-
/**
|
|
68
|
-
* The border radius of the element being highlighted.
|
|
69
|
-
*/
|
|
70
|
-
targetRadius?: number;
|
|
71
|
-
/**
|
|
72
|
-
* Alternative element to render than the wrapped target.
|
|
73
|
-
*/
|
|
74
|
-
targetReplacement?: ComponentType<any>;
|
|
75
|
-
/**
|
|
76
|
-
This prop is a unique string that appears as an attribute `data-testid` in the rendered HTML output serving as a hook for automated tests.
|
|
77
|
-
As this component is composed of multiple components we use this `testId` as a prefix:
|
|
78
|
-
|
|
79
|
-
- `"${testId}--dialog"` to identify the spotlight dialog
|
|
80
|
-
- `"${testId}--target"` to identify the spotlight target clone
|
|
81
|
-
|
|
82
|
-
Defaults to `"spotlight"`.
|
|
83
|
-
*/
|
|
84
|
-
testId?: string;
|
|
85
|
-
/**
|
|
86
|
-
* Used set the 'block' attribute on scrollIntoView, which determines the vertical alignment of the target node to the nearest scrollable ancestor.
|
|
87
|
-
*/
|
|
88
|
-
scrollPositionBlock?: ScrollLogicalPosition;
|
|
89
|
-
}
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type SpotlightProps } from '../types';
|
|
90
3
|
/**
|
|
91
4
|
* __Spotlight__
|
|
92
5
|
*
|
package/dist/types/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ReactNode } from 'react';
|
|
1
|
+
import { type ComponentType, type MouseEvent, type ReactNode } from 'react';
|
|
2
2
|
import { type CustomThemeButtonProps } from '@atlaskit/button/types';
|
|
3
3
|
interface Action extends Omit<CustomThemeButtonProps, 'children'> {
|
|
4
4
|
key?: string;
|
|
@@ -6,3 +6,90 @@ interface Action extends Omit<CustomThemeButtonProps, 'children'> {
|
|
|
6
6
|
}
|
|
7
7
|
export type Actions = Action[];
|
|
8
8
|
export type { ScrollLogicalPosition } from 'scroll-into-view-if-needed/typings/types';
|
|
9
|
+
export interface SpotlightProps {
|
|
10
|
+
/**
|
|
11
|
+
* Buttons to render in the footer.
|
|
12
|
+
*/
|
|
13
|
+
actions?: Actions;
|
|
14
|
+
/**
|
|
15
|
+
* An optional node to be rendered beside the footer actions.
|
|
16
|
+
*/
|
|
17
|
+
actionsBeforeElement?: ReactNode;
|
|
18
|
+
/**
|
|
19
|
+
* The elements rendered in the modal.
|
|
20
|
+
*/
|
|
21
|
+
children?: ReactNode;
|
|
22
|
+
/**
|
|
23
|
+
* Where the dialog should appear, relative to the contents of the children.
|
|
24
|
+
*/
|
|
25
|
+
dialogPlacement?: 'top left' | 'top center' | 'top right' | 'right top' | 'right middle' | 'right bottom' | 'bottom left' | 'bottom center' | 'bottom right' | 'left top' | 'left middle' | 'left bottom';
|
|
26
|
+
/**
|
|
27
|
+
* The width of the dialog in pixels. The minimum possible width is 160px and the maximum width is 600px.
|
|
28
|
+
*/
|
|
29
|
+
dialogWidth?: number;
|
|
30
|
+
/**
|
|
31
|
+
* Optional element rendered below the body.
|
|
32
|
+
*/
|
|
33
|
+
footer?: ComponentType<any>;
|
|
34
|
+
/**
|
|
35
|
+
* Optional element rendered above the body.
|
|
36
|
+
*/
|
|
37
|
+
header?: ComponentType<any>;
|
|
38
|
+
/**
|
|
39
|
+
* Heading text rendered above the body.
|
|
40
|
+
*/
|
|
41
|
+
heading?: string;
|
|
42
|
+
/**
|
|
43
|
+
* An optional element rendered to the right of the heading.
|
|
44
|
+
*/
|
|
45
|
+
headingAfterElement?: ReactNode;
|
|
46
|
+
/**
|
|
47
|
+
* Path to the image.
|
|
48
|
+
*/
|
|
49
|
+
image?: string;
|
|
50
|
+
/**
|
|
51
|
+
* Whether or not to display a pulse animation around the spotlighted element.
|
|
52
|
+
*/
|
|
53
|
+
pulse?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* The name of the SpotlightTarget.
|
|
56
|
+
*/
|
|
57
|
+
target?: string;
|
|
58
|
+
/**
|
|
59
|
+
* The spotlight target node.
|
|
60
|
+
*/
|
|
61
|
+
targetNode?: HTMLElement;
|
|
62
|
+
/**
|
|
63
|
+
* The background color of the element being highlighted.
|
|
64
|
+
*/
|
|
65
|
+
targetBgColor?: string;
|
|
66
|
+
/**
|
|
67
|
+
* Function to fire when a person clicks on the cloned target.
|
|
68
|
+
*/
|
|
69
|
+
targetOnClick?: (eventData: {
|
|
70
|
+
event: MouseEvent<HTMLElement>;
|
|
71
|
+
target?: string;
|
|
72
|
+
}) => void;
|
|
73
|
+
/**
|
|
74
|
+
* The border radius of the element being highlighted.
|
|
75
|
+
*/
|
|
76
|
+
targetRadius?: number;
|
|
77
|
+
/**
|
|
78
|
+
* Alternative element to render than the wrapped target.
|
|
79
|
+
*/
|
|
80
|
+
targetReplacement?: ComponentType<any>;
|
|
81
|
+
/**
|
|
82
|
+
This prop is a unique string that appears as an attribute `data-testid` in the rendered HTML output serving as a hook for automated tests.
|
|
83
|
+
As this component is composed of multiple components we use this `testId` as a prefix:
|
|
84
|
+
|
|
85
|
+
- `"${testId}--dialog"` to identify the spotlight dialog
|
|
86
|
+
- `"${testId}--target"` to identify the spotlight target clone
|
|
87
|
+
|
|
88
|
+
Defaults to `"spotlight"`.
|
|
89
|
+
*/
|
|
90
|
+
testId?: string;
|
|
91
|
+
/**
|
|
92
|
+
* Used set the 'block' attribute on scrollIntoView, which determines the vertical alignment of the target node to the nearest scrollable ancestor.
|
|
93
|
+
*/
|
|
94
|
+
scrollPositionBlock?: ScrollLogicalPosition;
|
|
95
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
3
4
|
*/
|
|
4
|
-
/** @jsx jsx */
|
|
5
5
|
import { Component, type ElementType, type ReactNode } from 'react';
|
|
6
6
|
import { jsx } from '@emotion/react';
|
|
7
7
|
import { type ModalFooterProps as FooterComponentProps, type ModalHeaderProps as HeaderComponentProps } from '@atlaskit/modal-dialog';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { type ScrollLogicalPosition } from '../types';
|
|
2
|
+
import { type ScrollLogicalPosition, type SpotlightProps } from '../types';
|
|
3
3
|
import { type ElementBoundingBox } from '../utils/use-element-box';
|
|
4
|
-
import { type SpotlightProps } from './spotlight';
|
|
5
4
|
export interface SpotlightInnerProps extends SpotlightProps {
|
|
6
5
|
/**
|
|
7
6
|
* The spotlight target DOM element.
|
|
@@ -1,92 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import { type
|
|
3
|
-
export interface SpotlightProps {
|
|
4
|
-
/**
|
|
5
|
-
* Buttons to render in the footer.
|
|
6
|
-
*/
|
|
7
|
-
actions?: Actions;
|
|
8
|
-
/**
|
|
9
|
-
* An optional node to be rendered beside the footer actions.
|
|
10
|
-
*/
|
|
11
|
-
actionsBeforeElement?: ReactNode;
|
|
12
|
-
/**
|
|
13
|
-
* The elements rendered in the modal.
|
|
14
|
-
*/
|
|
15
|
-
children?: ReactNode;
|
|
16
|
-
/**
|
|
17
|
-
* Where the dialog should appear, relative to the contents of the children.
|
|
18
|
-
*/
|
|
19
|
-
dialogPlacement?: 'top left' | 'top center' | 'top right' | 'right top' | 'right middle' | 'right bottom' | 'bottom left' | 'bottom center' | 'bottom right' | 'left top' | 'left middle' | 'left bottom';
|
|
20
|
-
/**
|
|
21
|
-
* The width of the dialog in pixels. The minimum possible width is 160px and the maximum width is 600px.
|
|
22
|
-
*/
|
|
23
|
-
dialogWidth?: number;
|
|
24
|
-
/**
|
|
25
|
-
* Optional element rendered below the body.
|
|
26
|
-
*/
|
|
27
|
-
footer?: ComponentType<any>;
|
|
28
|
-
/**
|
|
29
|
-
* Optional element rendered above the body.
|
|
30
|
-
*/
|
|
31
|
-
header?: ComponentType<any>;
|
|
32
|
-
/**
|
|
33
|
-
* Heading text rendered above the body.
|
|
34
|
-
*/
|
|
35
|
-
heading?: string;
|
|
36
|
-
/**
|
|
37
|
-
* An optional element rendered to the right of the heading.
|
|
38
|
-
*/
|
|
39
|
-
headingAfterElement?: ReactNode;
|
|
40
|
-
/**
|
|
41
|
-
* Path to the image.
|
|
42
|
-
*/
|
|
43
|
-
image?: string;
|
|
44
|
-
/**
|
|
45
|
-
* Whether or not to display a pulse animation around the spotlighted element.
|
|
46
|
-
*/
|
|
47
|
-
pulse?: boolean;
|
|
48
|
-
/**
|
|
49
|
-
* The name of the SpotlightTarget.
|
|
50
|
-
*/
|
|
51
|
-
target?: string;
|
|
52
|
-
/**
|
|
53
|
-
* The spotlight target node.
|
|
54
|
-
*/
|
|
55
|
-
targetNode?: HTMLElement;
|
|
56
|
-
/**
|
|
57
|
-
* The background color of the element being highlighted.
|
|
58
|
-
*/
|
|
59
|
-
targetBgColor?: string;
|
|
60
|
-
/**
|
|
61
|
-
* Function to fire when a person clicks on the cloned target.
|
|
62
|
-
*/
|
|
63
|
-
targetOnClick?: (eventData: {
|
|
64
|
-
event: MouseEvent<HTMLElement>;
|
|
65
|
-
target?: string;
|
|
66
|
-
}) => void;
|
|
67
|
-
/**
|
|
68
|
-
* The border radius of the element being highlighted.
|
|
69
|
-
*/
|
|
70
|
-
targetRadius?: number;
|
|
71
|
-
/**
|
|
72
|
-
* Alternative element to render than the wrapped target.
|
|
73
|
-
*/
|
|
74
|
-
targetReplacement?: ComponentType<any>;
|
|
75
|
-
/**
|
|
76
|
-
This prop is a unique string that appears as an attribute `data-testid` in the rendered HTML output serving as a hook for automated tests.
|
|
77
|
-
As this component is composed of multiple components we use this `testId` as a prefix:
|
|
78
|
-
|
|
79
|
-
- `"${testId}--dialog"` to identify the spotlight dialog
|
|
80
|
-
- `"${testId}--target"` to identify the spotlight target clone
|
|
81
|
-
|
|
82
|
-
Defaults to `"spotlight"`.
|
|
83
|
-
*/
|
|
84
|
-
testId?: string;
|
|
85
|
-
/**
|
|
86
|
-
* Used set the 'block' attribute on scrollIntoView, which determines the vertical alignment of the target node to the nearest scrollable ancestor.
|
|
87
|
-
*/
|
|
88
|
-
scrollPositionBlock?: ScrollLogicalPosition;
|
|
89
|
-
}
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { type SpotlightProps } from '../types';
|
|
90
3
|
/**
|
|
91
4
|
* __Spotlight__
|
|
92
5
|
*
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type ReactNode } from 'react';
|
|
1
|
+
import { type ComponentType, type MouseEvent, type ReactNode } from 'react';
|
|
2
2
|
import { type CustomThemeButtonProps } from '@atlaskit/button/types';
|
|
3
3
|
interface Action extends Omit<CustomThemeButtonProps, 'children'> {
|
|
4
4
|
key?: string;
|
|
@@ -6,3 +6,90 @@ interface Action extends Omit<CustomThemeButtonProps, 'children'> {
|
|
|
6
6
|
}
|
|
7
7
|
export type Actions = Action[];
|
|
8
8
|
export type { ScrollLogicalPosition } from 'scroll-into-view-if-needed/typings/types';
|
|
9
|
+
export interface SpotlightProps {
|
|
10
|
+
/**
|
|
11
|
+
* Buttons to render in the footer.
|
|
12
|
+
*/
|
|
13
|
+
actions?: Actions;
|
|
14
|
+
/**
|
|
15
|
+
* An optional node to be rendered beside the footer actions.
|
|
16
|
+
*/
|
|
17
|
+
actionsBeforeElement?: ReactNode;
|
|
18
|
+
/**
|
|
19
|
+
* The elements rendered in the modal.
|
|
20
|
+
*/
|
|
21
|
+
children?: ReactNode;
|
|
22
|
+
/**
|
|
23
|
+
* Where the dialog should appear, relative to the contents of the children.
|
|
24
|
+
*/
|
|
25
|
+
dialogPlacement?: 'top left' | 'top center' | 'top right' | 'right top' | 'right middle' | 'right bottom' | 'bottom left' | 'bottom center' | 'bottom right' | 'left top' | 'left middle' | 'left bottom';
|
|
26
|
+
/**
|
|
27
|
+
* The width of the dialog in pixels. The minimum possible width is 160px and the maximum width is 600px.
|
|
28
|
+
*/
|
|
29
|
+
dialogWidth?: number;
|
|
30
|
+
/**
|
|
31
|
+
* Optional element rendered below the body.
|
|
32
|
+
*/
|
|
33
|
+
footer?: ComponentType<any>;
|
|
34
|
+
/**
|
|
35
|
+
* Optional element rendered above the body.
|
|
36
|
+
*/
|
|
37
|
+
header?: ComponentType<any>;
|
|
38
|
+
/**
|
|
39
|
+
* Heading text rendered above the body.
|
|
40
|
+
*/
|
|
41
|
+
heading?: string;
|
|
42
|
+
/**
|
|
43
|
+
* An optional element rendered to the right of the heading.
|
|
44
|
+
*/
|
|
45
|
+
headingAfterElement?: ReactNode;
|
|
46
|
+
/**
|
|
47
|
+
* Path to the image.
|
|
48
|
+
*/
|
|
49
|
+
image?: string;
|
|
50
|
+
/**
|
|
51
|
+
* Whether or not to display a pulse animation around the spotlighted element.
|
|
52
|
+
*/
|
|
53
|
+
pulse?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* The name of the SpotlightTarget.
|
|
56
|
+
*/
|
|
57
|
+
target?: string;
|
|
58
|
+
/**
|
|
59
|
+
* The spotlight target node.
|
|
60
|
+
*/
|
|
61
|
+
targetNode?: HTMLElement;
|
|
62
|
+
/**
|
|
63
|
+
* The background color of the element being highlighted.
|
|
64
|
+
*/
|
|
65
|
+
targetBgColor?: string;
|
|
66
|
+
/**
|
|
67
|
+
* Function to fire when a person clicks on the cloned target.
|
|
68
|
+
*/
|
|
69
|
+
targetOnClick?: (eventData: {
|
|
70
|
+
event: MouseEvent<HTMLElement>;
|
|
71
|
+
target?: string;
|
|
72
|
+
}) => void;
|
|
73
|
+
/**
|
|
74
|
+
* The border radius of the element being highlighted.
|
|
75
|
+
*/
|
|
76
|
+
targetRadius?: number;
|
|
77
|
+
/**
|
|
78
|
+
* Alternative element to render than the wrapped target.
|
|
79
|
+
*/
|
|
80
|
+
targetReplacement?: ComponentType<any>;
|
|
81
|
+
/**
|
|
82
|
+
This prop is a unique string that appears as an attribute `data-testid` in the rendered HTML output serving as a hook for automated tests.
|
|
83
|
+
As this component is composed of multiple components we use this `testId` as a prefix:
|
|
84
|
+
|
|
85
|
+
- `"${testId}--dialog"` to identify the spotlight dialog
|
|
86
|
+
- `"${testId}--target"` to identify the spotlight target clone
|
|
87
|
+
|
|
88
|
+
Defaults to `"spotlight"`.
|
|
89
|
+
*/
|
|
90
|
+
testId?: string;
|
|
91
|
+
/**
|
|
92
|
+
* Used set the 'block' attribute on scrollIntoView, which determines the vertical alignment of the target node to the nearest scrollable ancestor.
|
|
93
|
+
*/
|
|
94
|
+
scrollPositionBlock?: ScrollLogicalPosition;
|
|
95
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/onboarding",
|
|
3
|
-
"version": "11.10.
|
|
3
|
+
"version": "11.10.4",
|
|
4
4
|
"description": "An onboarding spotlight introduces new features to users through focused messages or multi-step tours.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
43
|
"@atlaskit/analytics-next": "^9.3.0",
|
|
44
|
-
"@atlaskit/button": "^
|
|
44
|
+
"@atlaskit/button": "^19.1.0",
|
|
45
45
|
"@atlaskit/ds-lib": "^2.3.0",
|
|
46
46
|
"@atlaskit/heading": "^2.4.0",
|
|
47
47
|
"@atlaskit/modal-dialog": "^12.14.0",
|
|
@@ -49,9 +49,9 @@
|
|
|
49
49
|
"@atlaskit/platform-feature-flags": "^0.3.0",
|
|
50
50
|
"@atlaskit/popper": "^6.1.0",
|
|
51
51
|
"@atlaskit/portal": "^4.6.0",
|
|
52
|
-
"@atlaskit/primitives": "^11.
|
|
52
|
+
"@atlaskit/primitives": "^11.1.0",
|
|
53
53
|
"@atlaskit/theme": "^12.11.0",
|
|
54
|
-
"@atlaskit/tokens": "^1.
|
|
54
|
+
"@atlaskit/tokens": "^1.56.0",
|
|
55
55
|
"@babel/runtime": "^7.0.0",
|
|
56
56
|
"@emotion/react": "^11.7.1",
|
|
57
57
|
"bind-event-listener": "^3.0.0",
|