@atlaskit/smart-card 43.15.0 → 43.15.1

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 CHANGED
@@ -1,5 +1,13 @@
1
1
  # @atlaskit/smart-card
2
2
 
3
+ ## 43.15.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`7fd73a7df2e12`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/7fd73a7df2e12) -
8
+ fix a11y violation detected for rule "nested-interactive" for "@atlaskit/smart-card" ->
9
+ StopPropagation component
10
+
3
11
  ## 43.15.0
4
12
 
5
13
  ### Minor Changes
@@ -11,7 +11,7 @@ var ANALYTICS_CHANNEL = exports.ANALYTICS_CHANNEL = 'media';
11
11
  var context = exports.context = {
12
12
  componentName: 'smart-cards',
13
13
  packageName: "@atlaskit/smart-card",
14
- packageVersion: "43.14.5"
14
+ packageVersion: "43.15.0"
15
15
  };
16
16
  var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
17
17
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -22,7 +22,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId", "isLink
22
22
  _excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
23
23
  var PACKAGE_DATA = {
24
24
  packageName: "@atlaskit/smart-card",
25
- packageVersion: "43.14.5",
25
+ packageVersion: "43.15.0",
26
26
  componentName: 'linkUrl'
27
27
  };
28
28
  var Anchor = (0, _click.withLinkClickedEvent)('a');
@@ -12,16 +12,25 @@ var _react = _interopRequireWildcard(require("react"));
12
12
  var _compiled = require("@atlaskit/primitives/compiled");
13
13
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
14
14
  var styles = {
15
- pressable: "_c71lidpf _p12fidpf _kqswstnw"
15
+ wrapper: "_c71lidpf _p12fidpf _kqswstnw"
16
16
  };
17
+ /**
18
+ * A wrapper component that prevents click events from propagating to parent elements.
19
+ *
20
+ * This component is commonly used within modals or overlays to prevent unintended
21
+ * interactions with parent handlers when users interact with nested content.
22
+ *
23
+ */
17
24
  var StopPropagation = exports.StopPropagation = function StopPropagation(_ref) {
18
25
  var children = _ref.children;
19
26
  var onClick = (0, _react.useCallback)(function (e) {
20
- // Prevent click event inside modal from bubble up
27
+ // Prevent click events from bubbling up
21
28
  e.stopPropagation();
22
29
  }, []);
23
- return /*#__PURE__*/_react.default.createElement(_compiled.Pressable, {
24
- xcss: styles.pressable,
30
+ return /*#__PURE__*/_react.default.createElement(_compiled.Box, {
31
+ as: "span",
32
+ role: "none",
33
+ xcss: styles.wrapper,
25
34
  onClick: onClick
26
35
  }, children);
27
36
  };
@@ -2,7 +2,7 @@ export const ANALYTICS_CHANNEL = 'media';
2
2
  export const context = {
3
3
  componentName: 'smart-cards',
4
4
  packageName: "@atlaskit/smart-card",
5
- packageVersion: "43.14.5"
5
+ packageVersion: "43.15.0"
6
6
  };
7
7
  export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
8
8
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -12,7 +12,7 @@ import LinkWarningModal from './LinkWarningModal';
12
12
  import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
13
13
  const PACKAGE_DATA = {
14
14
  packageName: "@atlaskit/smart-card",
15
- packageVersion: "43.14.5",
15
+ packageVersion: "43.15.0",
16
16
  componentName: 'linkUrl'
17
17
  };
18
18
  const Anchor = withLinkClickedEvent('a');
@@ -2,19 +2,28 @@
2
2
  import "./index.compiled.css";
3
3
  import { ax, ix } from "@compiled/react/runtime";
4
4
  import React, { useCallback } from 'react';
5
- import { Pressable } from '@atlaskit/primitives/compiled';
5
+ import { Box } from '@atlaskit/primitives/compiled';
6
6
  const styles = {
7
- pressable: "_c71lidpf _p12fidpf _kqswstnw"
7
+ wrapper: "_c71lidpf _p12fidpf _kqswstnw"
8
8
  };
9
+ /**
10
+ * A wrapper component that prevents click events from propagating to parent elements.
11
+ *
12
+ * This component is commonly used within modals or overlays to prevent unintended
13
+ * interactions with parent handlers when users interact with nested content.
14
+ *
15
+ */
9
16
  export const StopPropagation = ({
10
17
  children
11
18
  }) => {
12
19
  const onClick = useCallback(e => {
13
- // Prevent click event inside modal from bubble up
20
+ // Prevent click events from bubbling up
14
21
  e.stopPropagation();
15
22
  }, []);
16
- return /*#__PURE__*/React.createElement(Pressable, {
17
- xcss: styles.pressable,
23
+ return /*#__PURE__*/React.createElement(Box, {
24
+ as: "span",
25
+ role: "none",
26
+ xcss: styles.wrapper,
18
27
  onClick: onClick
19
28
  }, children);
20
29
  };
@@ -4,7 +4,7 @@ export var ANALYTICS_CHANNEL = 'media';
4
4
  export var context = {
5
5
  componentName: 'smart-cards',
6
6
  packageName: "@atlaskit/smart-card",
7
- packageVersion: "43.14.5"
7
+ packageVersion: "43.15.0"
8
8
  };
9
9
  export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
10
10
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -15,7 +15,7 @@ import LinkWarningModal from './LinkWarningModal';
15
15
  import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
16
16
  var PACKAGE_DATA = {
17
17
  packageName: "@atlaskit/smart-card",
18
- packageVersion: "43.14.5",
18
+ packageVersion: "43.15.0",
19
19
  componentName: 'linkUrl'
20
20
  };
21
21
  var Anchor = withLinkClickedEvent('a');
@@ -2,18 +2,27 @@
2
2
  import "./index.compiled.css";
3
3
  import { ax, ix } from "@compiled/react/runtime";
4
4
  import React, { useCallback } from 'react';
5
- import { Pressable } from '@atlaskit/primitives/compiled';
5
+ import { Box } from '@atlaskit/primitives/compiled';
6
6
  var styles = {
7
- pressable: "_c71lidpf _p12fidpf _kqswstnw"
7
+ wrapper: "_c71lidpf _p12fidpf _kqswstnw"
8
8
  };
9
+ /**
10
+ * A wrapper component that prevents click events from propagating to parent elements.
11
+ *
12
+ * This component is commonly used within modals or overlays to prevent unintended
13
+ * interactions with parent handlers when users interact with nested content.
14
+ *
15
+ */
9
16
  export var StopPropagation = function StopPropagation(_ref) {
10
17
  var children = _ref.children;
11
18
  var onClick = useCallback(function (e) {
12
- // Prevent click event inside modal from bubble up
19
+ // Prevent click events from bubbling up
13
20
  e.stopPropagation();
14
21
  }, []);
15
- return /*#__PURE__*/React.createElement(Pressable, {
16
- xcss: styles.pressable,
22
+ return /*#__PURE__*/React.createElement(Box, {
23
+ as: "span",
24
+ role: "none",
25
+ xcss: styles.wrapper,
17
26
  onClick: onClick
18
27
  }, children);
19
28
  };
@@ -6,5 +6,12 @@ import { type ReactNode } from 'react';
6
6
  type StopPropagationProps = {
7
7
  children: ReactNode;
8
8
  };
9
+ /**
10
+ * A wrapper component that prevents click events from propagating to parent elements.
11
+ *
12
+ * This component is commonly used within modals or overlays to prevent unintended
13
+ * interactions with parent handlers when users interact with nested content.
14
+ *
15
+ */
9
16
  export declare const StopPropagation: ({ children }: StopPropagationProps) => JSX.Element;
10
17
  export {};
@@ -6,5 +6,12 @@ import { type ReactNode } from 'react';
6
6
  type StopPropagationProps = {
7
7
  children: ReactNode;
8
8
  };
9
+ /**
10
+ * A wrapper component that prevents click events from propagating to parent elements.
11
+ *
12
+ * This component is commonly used within modals or overlays to prevent unintended
13
+ * interactions with parent handlers when users interact with nested content.
14
+ *
15
+ */
9
16
  export declare const StopPropagation: ({ children }: StopPropagationProps) => JSX.Element;
10
17
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-card",
3
- "version": "43.15.0",
3
+ "version": "43.15.1",
4
4
  "description": "Smart card component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -30,9 +30,9 @@
30
30
  "@atlaskit/afm-i18n-platform-linking-platform-smart-card": "2.6.0",
31
31
  "@atlaskit/analytics-gas-types": "^5.1.0",
32
32
  "@atlaskit/analytics-next": "^11.1.0",
33
- "@atlaskit/avatar": "^25.5.0",
33
+ "@atlaskit/avatar": "^25.6.0",
34
34
  "@atlaskit/avatar-group": "^12.4.0",
35
- "@atlaskit/badge": "^18.2.0",
35
+ "@atlaskit/badge": "^18.3.0",
36
36
  "@atlaskit/button": "^23.7.0",
37
37
  "@atlaskit/checkbox": "^17.2.0",
38
38
  "@atlaskit/css": "^0.17.0",
@@ -42,9 +42,9 @@
42
42
  "@atlaskit/form": "^15.0.0",
43
43
  "@atlaskit/frontend-utilities": "^3.2.0",
44
44
  "@atlaskit/heading": "^5.2.0",
45
- "@atlaskit/icon": "^29.0.0",
45
+ "@atlaskit/icon": "^29.1.0",
46
46
  "@atlaskit/icon-file-type": "^7.0.0",
47
- "@atlaskit/icon-object": "^7.3.0",
47
+ "@atlaskit/icon-object": "^7.4.0",
48
48
  "@atlaskit/icon-priority": "^6.3.0",
49
49
  "@atlaskit/image": "^3.0.0",
50
50
  "@atlaskit/json-ld-types": "^1.4.0",
@@ -59,7 +59,7 @@
59
59
  "@atlaskit/logo": "^19.9.0",
60
60
  "@atlaskit/lozenge": "^13.1.0",
61
61
  "@atlaskit/menu": "^8.4.0",
62
- "@atlaskit/modal-dialog": "^14.8.0",
62
+ "@atlaskit/modal-dialog": "^14.9.0",
63
63
  "@atlaskit/outbound-auth-flow-client": "^3.4.0",
64
64
  "@atlaskit/platform-feature-flags": "^1.1.0",
65
65
  "@atlaskit/platform-feature-flags-react": "^0.4.0",
@@ -72,8 +72,8 @@
72
72
  "@atlaskit/textfield": "^8.2.0",
73
73
  "@atlaskit/theme": "^21.0.0",
74
74
  "@atlaskit/tile": "^1.0.0",
75
- "@atlaskit/tmp-editor-statsig": "^15.9.0",
76
- "@atlaskit/tokens": "^8.4.0",
75
+ "@atlaskit/tmp-editor-statsig": "^15.11.0",
76
+ "@atlaskit/tokens": "^8.5.0",
77
77
  "@atlaskit/tooltip": "^20.11.0",
78
78
  "@atlaskit/ufo": "^0.4.0",
79
79
  "@babel/runtime": "^7.0.0",
@@ -102,11 +102,11 @@
102
102
  "@atlaskit/analytics-listeners": "^9.1.0",
103
103
  "@atlaskit/css-reset": "^7.3.0",
104
104
  "@atlaskit/media-test-helpers": "^39.0.0",
105
- "@atlaskit/react-ufo": "^4.15.0",
105
+ "@atlaskit/react-ufo": "^4.16.0",
106
106
  "@atlaskit/ssr": "workspace:^",
107
107
  "@atlassian/analytics-tooling": "workspace:^",
108
108
  "@atlassian/feature-flags-test-utils": "^1.0.0",
109
- "@atlassian/gemini": "^1.23.0",
109
+ "@atlassian/gemini": "^1.24.0",
110
110
  "@atlassian/testing-library": "^0.4.0",
111
111
  "@testing-library/dom": "^10.1.0",
112
112
  "@testing-library/jest-dom": "^6.4.5",