@atlaskit/avatar 25.11.2 → 25.11.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.
Files changed (37) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/cjs/avatar-content.compiled.css +4 -4
  3. package/dist/cjs/avatar-content.js +3 -3
  4. package/dist/cjs/avatar-context.js +17 -0
  5. package/dist/cjs/avatar-item.compiled.css +4 -4
  6. package/dist/cjs/avatar-item.js +2 -2
  7. package/dist/cjs/avatar.js +3 -3
  8. package/dist/cjs/index.js +4 -3
  9. package/dist/cjs/use-avatar-context.js +11 -0
  10. package/dist/es2019/avatar-content.compiled.css +4 -4
  11. package/dist/es2019/avatar-content.js +3 -3
  12. package/dist/es2019/avatar-context.js +11 -0
  13. package/dist/es2019/avatar-item.compiled.css +4 -4
  14. package/dist/es2019/avatar-item.js +2 -2
  15. package/dist/es2019/avatar.js +2 -2
  16. package/dist/es2019/index.js +2 -1
  17. package/dist/es2019/use-avatar-context.js +3 -0
  18. package/dist/esm/avatar-content.compiled.css +4 -4
  19. package/dist/esm/avatar-content.js +3 -3
  20. package/dist/esm/avatar-context.js +11 -0
  21. package/dist/esm/avatar-item.compiled.css +4 -4
  22. package/dist/esm/avatar-item.js +2 -2
  23. package/dist/esm/avatar.js +2 -2
  24. package/dist/esm/index.js +2 -1
  25. package/dist/esm/use-avatar-context.js +5 -0
  26. package/dist/types/avatar-context.d.ts +14 -0
  27. package/dist/types/index.d.ts +3 -1
  28. package/dist/types/use-avatar-context.d.ts +2 -0
  29. package/dist/types-ts4.5/avatar-context.d.ts +14 -0
  30. package/dist/types-ts4.5/index.d.ts +3 -1
  31. package/dist/types-ts4.5/use-avatar-context.d.ts +2 -0
  32. package/package.json +9 -1
  33. package/dist/cjs/context.js +0 -24
  34. package/dist/es2019/context.js +0 -16
  35. package/dist/esm/context.js +0 -18
  36. package/dist/types/context.d.ts +0 -19
  37. package/dist/types-ts4.5/context.d.ts +0 -19
package/CHANGELOG.md CHANGED
@@ -1,5 +1,22 @@
1
1
  # @atlaskit/avatar
2
2
 
3
+ ## 25.11.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [`02483200273ec`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/02483200273ec) -
8
+ Enrol all Design System UI packages into the React Compiler with platform gating via
9
+ isReactCompilerActivePlatform.
10
+ - Updated dependencies
11
+
12
+ ## 25.11.3
13
+
14
+ ### Patch Changes
15
+
16
+ - [`22bf79dbdcdca`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/22bf79dbdcdca) -
17
+ Internal changes to remove unnecessary token fallbacks and imports from `@atlaskit/theme`
18
+ - Updated dependencies
19
+
3
20
  ## 25.11.2
4
21
 
5
22
  ### Patch Changes
@@ -41,8 +41,8 @@
41
41
  ._1hfkvuon:after{background-color:var(--ds-surface,#fff)}
42
42
  ._1o9o1v1w:has(:focus-visible){background-color:var(--ds-border-focused,#4688ec)}
43
43
  ._1o9ovuon:has(:focus-visible){background-color:var(--ds-surface,#fff)}
44
+ ._1peq2wxo:after{opacity:var(--ds-opacity-disabled,.4)}
44
45
  ._1peqidpf:after{opacity:0}
45
- ._1peqs237:after{opacity:var(--ds-opacity-disabled,.7)}
46
46
  ._1pfhv77o{margin-block-start:var(--ds-space-025,2px)}
47
47
  ._1q51ze3t{padding-block-start:var(--ds-space-0,0)}
48
48
  ._1qu2glyw{outline-style:none}
@@ -55,7 +55,7 @@
55
55
  ._4t3i1ylp{height:40px}
56
56
  ._4t3i7vkz{height:1pc}
57
57
  ._4t3izwfg{height:2pc}
58
- ._4tpu1g4v:hover:after{background-color:var(--ds-interaction-hovered,rgba(9,30,66,.36))}
58
+ ._4tpu1f0r:hover:after{background-color:var(--ds-interaction-hovered,#00000029)}
59
59
  ._6rthv77o{margin-block-end:var(--ds-space-025,2px)}
60
60
  ._80om13gf{cursor:not-allowed}
61
61
  ._80om1kw7{cursor:inherit}
@@ -68,7 +68,7 @@
68
68
  ._bozgze3t{padding-inline-start:var(--ds-space-0,0)}
69
69
  ._eeh8kb7n:active:after{opacity:1}
70
70
  ._ez1ykb7n:hover:after{opacity:1}
71
- ._gcm1182g:active:after{background-color:var(--ds-interaction-pressed,rgba(9,30,66,.36))}
71
+ ._gcm1jer9:active:after{background-color:var(--ds-interaction-pressed,#00000052)}
72
72
  ._kqswh2mm{position:relative}
73
73
  ._kqswpfqs{position:static}
74
74
  ._mkrz1k6g{clip-path:polygon(45% 1.33975%,46.5798% .60307%,48.26352% .15192%,50% 0,51.73648% .15192%,53.4202% .60307%,55% 1.33975%,89.64102% 21.33975%,91.06889% 22.33956%,92.30146% 23.57212%,93.30127% 25%,94.03794% 26.5798%,94.48909% 28.26352%,94.64102% 30%,94.64102% 70%,94.48909% 71.73648%,94.03794% 73.4202%,93.30127% 75%,92.30146% 76.42788%,91.06889% 77.66044%,89.64102% 78.66025%,55% 98.66025%,53.4202% 99.39693%,51.73648% 99.84808%,50% 100%,48.26352% 99.84808%,46.5798% 99.39693%,45% 98.66025%,10.35898% 78.66025%,8.93111% 77.66044%,7.69854% 76.42788%,6.69873% 75%,5.96206% 73.4202%,5.51091% 71.73648%,5.35898% 70%,5.35898% 30%,5.51091% 28.26352%,5.96206% 26.5798%,6.69873% 25%,7.69854% 23.57212%,8.93111% 22.33956%,10.35898% 21.33975%)}
@@ -82,7 +82,7 @@
82
82
  ._1ah3v77o:focus-visible{outline-offset:var(--ds-space-025,2px)}
83
83
  ._1ejjglyw:focus-visible{box-shadow:none}
84
84
  ._1ejjn7od:focus-visible{box-shadow:unset}
85
- ._mizu194a:focus-visible{outline-color:var(--ds-border-focused,#2684ff)}
85
+ ._mizu1v1w:focus-visible{outline-color:var(--ds-border-focused,#4688ec)}
86
86
  ._ra3xnqa1:focus-visible{outline-style:solid}
87
87
  ._1llweo6y:hover{transform:scale(1.12)}
88
88
  @media screen and (-ms-high-contrast:active),screen and (forced-colors:active){._4dave4h9:focus-visible{outline-width:var(--ds-border-width,1px)}._4davidpf:focus-visible{outline-width:0}}
@@ -20,11 +20,11 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
20
20
  var boxShadowCssVar = '--avatar-box-shadow';
21
21
  var bgColorCssVar = '--avatar-bg-color';
22
22
  var styles = {
23
- root: "_19itglyw _12ji1r31 _1qu2glyw _12y31o36 _1reo15vq _18m915vq _v564ieh6 _1e0c1txw _kqswpfqs _4cvr1fhb _1bah1h6o _2lx21bp4 _80om1kw7 _6rthv77o _1pfhv77o _12l2v77o _ahbqv77o _85i5ze3t _1q51ze3t _y4tize3t _bozgze3t _t9ec1aqe _9v7aze3t _qc5o1p41 _z0ai1osq _18postnw _1hfk1j28 _aetrf705 _1peqidpf _11fnglyw _1ejjglyw _mizu194a _1ah3v77o _ra3xnqa1 _128mdkaa _4dave4h9",
23
+ root: "_19itglyw _12ji1r31 _1qu2glyw _12y31o36 _1reo15vq _18m915vq _v564ieh6 _1e0c1txw _kqswpfqs _4cvr1fhb _1bah1h6o _2lx21bp4 _80om1kw7 _6rthv77o _1pfhv77o _12l2v77o _ahbqv77o _85i5ze3t _1q51ze3t _y4tize3t _bozgze3t _t9ec1aqe _9v7aze3t _qc5o1p41 _z0ai1osq _18postnw _1hfk1j28 _aetrf705 _1peqidpf _11fnglyw _1ejjglyw _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _4dave4h9",
24
24
  circle: "_2rko1qll _14mj1qll",
25
25
  square: "_2rkol0p1",
26
26
  positionRelative: "_kqswh2mm",
27
- disabled: "_80om13gf _1hfkvuon _1peqs237"
27
+ disabled: "_80om13gf _1hfkvuon _1peq2wxo"
28
28
  };
29
29
  var unboundStyles = {
30
30
  rootCustomBorder: "_11q7cxp3",
@@ -35,7 +35,7 @@ var unboundStyles = {
35
35
  hexagonBorderContainer: "_1rjcf6hp _18zruxly _bfhkcxp3 _mkrz1kw7 _1o9ovuon",
36
36
  hexagonBorderContainerMarginFg: "_1mou18m8 _195gzwb8",
37
37
  hexagon: "_2rkoidpf _mkrz1kw7 _16qsn7od _14mjidpf _1ejjn7od _128midpf _4davidpf",
38
- interactive: "_80omtlke _4tpu1g4v _ez1ykb7n _gcm1182g _eeh8kb7n _jlxit94y",
38
+ interactive: "_80omtlke _4tpu1f0r _ez1ykb7n _gcm1jer9 _eeh8kb7n _jlxit94y",
39
39
  interactiveMotion: "_v564155l _1llweo6y"
40
40
  };
41
41
  var widthHeightMap = {
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.AvatarContext = void 0;
7
+ var _react = require("react");
8
+ /**
9
+ * __Avatar context__
10
+ *
11
+ * An avatar context that provides the size of the avatar to children. Used by AvatarGroup
12
+ *
13
+ * - [Examples](https://atlassian.design/components/avatar/examples)
14
+ * - [Code](https://atlassian.design/components/avatar/code)
15
+ * - [Usage](https://atlassian.design/components/avatar/usage)
16
+ */
17
+ var AvatarContext = exports.AvatarContext = /*#__PURE__*/(0, _react.createContext)(undefined);
@@ -37,20 +37,20 @@
37
37
  ._syaz1kw7{color:inherit}
38
38
  ._syaz1rpy{color:var(--ds-text-subtlest,#6b6e76)}
39
39
  ._syazi7uo{color:var(--ds-text,#292a2e)}
40
- ._tzy41e4z{opacity:var(--ds-opacity-disabled,.5)}
40
+ ._tzy42wxo{opacity:var(--ds-opacity-disabled,.4)}
41
41
  ._vchhusvi{box-sizing:border-box}
42
42
  ._vwz419ii{line-height:1.4}
43
43
  ._vwz4kb7n{line-height:1}
44
44
  ._y3gn1e5h{text-align:left}
45
45
  ._y4ti1b66{padding-inline-end:var(--ds-space-050,4px)}
46
46
  ._zg8l4jg8{font-style:normal}
47
- ._858u194a:focus{border-color:var(--ds-border-focused,#2684ff)}
47
+ ._858u1v1w:focus{border-color:var(--ds-border-focused,#4688ec)}
48
48
  ._1hvw1o36:focus{outline-width:medium}
49
49
  ._49pcglyw:focus{outline-style:none}
50
50
  ._nt751r31:focus{outline-color:currentColor}
51
51
  ._1bnxglyw:hover{text-decoration-line:none}
52
52
  ._9oik1r31:hover{text-decoration-color:currentColor}
53
53
  ._d0altlke:hover{cursor:pointer}
54
- ._irr314ae:hover{background-color:var(--ds-background-neutral-subtle-hovered,#ebecf0)}
54
+ ._irr31dpa:hover{background-color:var(--ds-background-neutral-subtle-hovered,#0515240f)}
55
55
  ._jf4cnqa1:hover{text-decoration-style:solid}
56
- ._1di61l7b:active{background-color:var(--ds-background-neutral-subtle-pressed,#deebff)}
56
+ ._1di6fcek:active{background-color:var(--ds-background-neutral-subtle-pressed,#0b120e24)}
@@ -20,8 +20,8 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
20
20
  var bgColorCssVar = '--avatar-item-bg-color';
21
21
  var styles = {
22
22
  root: "_2rkofajl _12ji1r31 _1qu2glyw _12y31o36 _4bfu1r31 _1hmsglyw _ajmmnqa1 _1h6d1j28 _1dqonqa1 _189e1dm9 _1e0c1txw _vchhusvi _1bsb1osq _4cvr1h6o _bfhk1g13 _syaz1kw7 _1wyb1kw7 _zg8l4jg8 _k48pi7a9 _vwz4kb7n _6rthze3t _1pfhze3t _12l2ze3t _ahbqze3t _85i51b66 _1q511b66 _y4ti1b66 _bozg1b66 _y3gn1e5h",
23
- rootDisabled: "_80om13gf _tzy41e4z _lcxvglyw",
24
- rootInteractive: "_nt751r31 _49pcglyw _1hvw1o36 _858u194a _9oik1r31 _1bnxglyw _jf4cnqa1 _irr314ae _d0altlke _1di61l7b",
23
+ rootDisabled: "_80om13gf _tzy42wxo _lcxvglyw",
24
+ rootInteractive: "_nt751r31 _49pcglyw _1hvw1o36 _858u1v1w _9oik1r31 _1bnxglyw _jf4cnqa1 _irr31dpa _d0altlke _1di6fcek",
25
25
  avatarItem: "_16jlkb7n _1o9zkb7n _i0dl1osq _1ul9idpf _p12f1osq _vwz419ii _bozgu2gc",
26
26
  baseText: "_1e0c1ule _syazi7uo",
27
27
  truncation: "_1reo15vq _1bto1l2s _o5721q9c",
@@ -15,18 +15,18 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
15
15
  var _analyticsNext = require("@atlaskit/analytics-next");
16
16
  var _useId = require("@atlaskit/ds-lib/use-id");
17
17
  var _avatarContent = require("./avatar-content");
18
- var _context = require("./context");
19
18
  var _avatarImage = _interopRequireDefault(require("./internal/avatar-image"));
20
19
  var _contentContext = require("./internal/content-context");
21
20
  var _ensureIsInsideAvatarContext = require("./internal/ensure-is-inside-avatar-context");
22
21
  var _getCustomElement = _interopRequireDefault(require("./internal/get-custom-element"));
23
22
  var _presenceWrapper = _interopRequireDefault(require("./internal/presence-wrapper"));
24
23
  var _statusWrapper = _interopRequireDefault(require("./internal/status-wrapper"));
24
+ var _useAvatarContext = require("./use-avatar-context");
25
25
  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); }
26
26
  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; }
27
27
  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; }
28
28
  var packageName = "@atlaskit/avatar";
29
- var packageVersion = "25.11.1";
29
+ var packageVersion = "25.11.3";
30
30
  var containerStyles = null;
31
31
 
32
32
  // eslint-disable-next-line @repo/internal/react/consistent-types-definitions
@@ -68,7 +68,7 @@ var Avatar = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
68
68
  ariaHasPopup = _ref['aria-haspopup'];
69
69
  var _useAnalyticsEvents = (0, _analyticsNext.useAnalyticsEvents)(),
70
70
  createAnalyticsEvent = _useAnalyticsEvents.createAnalyticsEvent;
71
- var context = (0, _context.useAvatarContext)();
71
+ var context = (0, _useAvatarContext.useAvatarContext)();
72
72
  var size = sizeProp || (context === null || context === void 0 ? void 0 : context.size) || 'medium';
73
73
  var customPresenceNode = /*#__PURE__*/(0, _react.isValidElement)(presence) ? presence : null;
74
74
  var customStatusNode = /*#__PURE__*/(0, _react.isValidElement)(status) ? status : null;
package/dist/cjs/index.js CHANGED
@@ -31,7 +31,7 @@ Object.defineProperty(exports, "AvatarContent", {
31
31
  Object.defineProperty(exports, "AvatarContext", {
32
32
  enumerable: true,
33
33
  get: function get() {
34
- return _context.AvatarContext;
34
+ return _avatarContext.AvatarContext;
35
35
  }
36
36
  });
37
37
  Object.defineProperty(exports, "AvatarItem", {
@@ -79,7 +79,7 @@ Object.defineProperty(exports, "getAppearanceForAppType", {
79
79
  Object.defineProperty(exports, "useAvatarContext", {
80
80
  enumerable: true,
81
81
  get: function get() {
82
- return _context.useAvatarContext;
82
+ return _useAvatarContext.useAvatarContext;
83
83
  }
84
84
  });
85
85
  var _avatar = _interopRequireDefault(require("./avatar"));
@@ -89,5 +89,6 @@ var _presence = _interopRequireDefault(require("./presence"));
89
89
  var _status = _interopRequireDefault(require("./status"));
90
90
  var _skeleton = _interopRequireDefault(require("./skeleton"));
91
91
  var _getAppearance = _interopRequireDefault(require("./get-appearance"));
92
- var _context = require("./context");
92
+ var _avatarContext = require("./avatar-context");
93
+ var _useAvatarContext = require("./use-avatar-context");
93
94
  var _constants = require("./constants");
@@ -0,0 +1,11 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useAvatarContext = void 0;
7
+ var _react = require("react");
8
+ var _avatarContext = require("./avatar-context");
9
+ var useAvatarContext = exports.useAvatarContext = function useAvatarContext() {
10
+ return (0, _react.useContext)(_avatarContext.AvatarContext);
11
+ };
@@ -41,8 +41,8 @@
41
41
  ._1hfkvuon:after{background-color:var(--ds-surface,#fff)}
42
42
  ._1o9o1v1w:has(:focus-visible){background-color:var(--ds-border-focused,#4688ec)}
43
43
  ._1o9ovuon:has(:focus-visible){background-color:var(--ds-surface,#fff)}
44
+ ._1peq2wxo:after{opacity:var(--ds-opacity-disabled,.4)}
44
45
  ._1peqidpf:after{opacity:0}
45
- ._1peqs237:after{opacity:var(--ds-opacity-disabled,.7)}
46
46
  ._1pfhv77o{margin-block-start:var(--ds-space-025,2px)}
47
47
  ._1q51ze3t{padding-block-start:var(--ds-space-0,0)}
48
48
  ._1qu2glyw{outline-style:none}
@@ -55,7 +55,7 @@
55
55
  ._4t3i1ylp{height:40px}
56
56
  ._4t3i7vkz{height:1pc}
57
57
  ._4t3izwfg{height:2pc}
58
- ._4tpu1g4v:hover:after{background-color:var(--ds-interaction-hovered,rgba(9,30,66,.36))}
58
+ ._4tpu1f0r:hover:after{background-color:var(--ds-interaction-hovered,#00000029)}
59
59
  ._6rthv77o{margin-block-end:var(--ds-space-025,2px)}
60
60
  ._80om13gf{cursor:not-allowed}
61
61
  ._80om1kw7{cursor:inherit}
@@ -68,7 +68,7 @@
68
68
  ._bozgze3t{padding-inline-start:var(--ds-space-0,0)}
69
69
  ._eeh8kb7n:active:after{opacity:1}
70
70
  ._ez1ykb7n:hover:after{opacity:1}
71
- ._gcm1182g:active:after{background-color:var(--ds-interaction-pressed,rgba(9,30,66,.36))}
71
+ ._gcm1jer9:active:after{background-color:var(--ds-interaction-pressed,#00000052)}
72
72
  ._kqswh2mm{position:relative}
73
73
  ._kqswpfqs{position:static}
74
74
  ._mkrz1k6g{clip-path:polygon(45% 1.33975%,46.5798% .60307%,48.26352% .15192%,50% 0,51.73648% .15192%,53.4202% .60307%,55% 1.33975%,89.64102% 21.33975%,91.06889% 22.33956%,92.30146% 23.57212%,93.30127% 25%,94.03794% 26.5798%,94.48909% 28.26352%,94.64102% 30%,94.64102% 70%,94.48909% 71.73648%,94.03794% 73.4202%,93.30127% 75%,92.30146% 76.42788%,91.06889% 77.66044%,89.64102% 78.66025%,55% 98.66025%,53.4202% 99.39693%,51.73648% 99.84808%,50% 100%,48.26352% 99.84808%,46.5798% 99.39693%,45% 98.66025%,10.35898% 78.66025%,8.93111% 77.66044%,7.69854% 76.42788%,6.69873% 75%,5.96206% 73.4202%,5.51091% 71.73648%,5.35898% 70%,5.35898% 30%,5.51091% 28.26352%,5.96206% 26.5798%,6.69873% 25%,7.69854% 23.57212%,8.93111% 22.33956%,10.35898% 21.33975%)}
@@ -82,7 +82,7 @@
82
82
  ._1ah3v77o:focus-visible{outline-offset:var(--ds-space-025,2px)}
83
83
  ._1ejjglyw:focus-visible{box-shadow:none}
84
84
  ._1ejjn7od:focus-visible{box-shadow:unset}
85
- ._mizu194a:focus-visible{outline-color:var(--ds-border-focused,#2684ff)}
85
+ ._mizu1v1w:focus-visible{outline-color:var(--ds-border-focused,#4688ec)}
86
86
  ._ra3xnqa1:focus-visible{outline-style:solid}
87
87
  ._1llweo6y:hover{transform:scale(1.12)}
88
88
  @media screen and (-ms-high-contrast:active),screen and (forced-colors:active){._4dave4h9:focus-visible{outline-width:var(--ds-border-width,1px)}._4davidpf:focus-visible{outline-width:0}}
@@ -10,11 +10,11 @@ import { useEnsureIsInsideAvatar } from './internal/ensure-is-inside-avatar-cont
10
10
  const boxShadowCssVar = '--avatar-box-shadow';
11
11
  const bgColorCssVar = '--avatar-bg-color';
12
12
  const styles = {
13
- root: "_19itglyw _12ji1r31 _1qu2glyw _12y31o36 _1reo15vq _18m915vq _v564ieh6 _1e0c1txw _kqswpfqs _4cvr1fhb _1bah1h6o _2lx21bp4 _80om1kw7 _6rthv77o _1pfhv77o _12l2v77o _ahbqv77o _85i5ze3t _1q51ze3t _y4tize3t _bozgze3t _t9ec1aqe _9v7aze3t _qc5o1p41 _z0ai1osq _18postnw _1hfk1j28 _aetrf705 _1peqidpf _11fnglyw _1ejjglyw _mizu194a _1ah3v77o _ra3xnqa1 _128mdkaa _4dave4h9",
13
+ root: "_19itglyw _12ji1r31 _1qu2glyw _12y31o36 _1reo15vq _18m915vq _v564ieh6 _1e0c1txw _kqswpfqs _4cvr1fhb _1bah1h6o _2lx21bp4 _80om1kw7 _6rthv77o _1pfhv77o _12l2v77o _ahbqv77o _85i5ze3t _1q51ze3t _y4tize3t _bozgze3t _t9ec1aqe _9v7aze3t _qc5o1p41 _z0ai1osq _18postnw _1hfk1j28 _aetrf705 _1peqidpf _11fnglyw _1ejjglyw _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _4dave4h9",
14
14
  circle: "_2rko1qll _14mj1qll",
15
15
  square: "_2rkol0p1",
16
16
  positionRelative: "_kqswh2mm",
17
- disabled: "_80om13gf _1hfkvuon _1peqs237"
17
+ disabled: "_80om13gf _1hfkvuon _1peq2wxo"
18
18
  };
19
19
  const unboundStyles = {
20
20
  rootCustomBorder: "_11q7cxp3",
@@ -25,7 +25,7 @@ const unboundStyles = {
25
25
  hexagonBorderContainer: "_1rjcf6hp _18zruxly _bfhkcxp3 _mkrz1kw7 _1o9ovuon",
26
26
  hexagonBorderContainerMarginFg: "_1mou18m8 _195gzwb8",
27
27
  hexagon: "_2rkoidpf _mkrz1kw7 _16qsn7od _14mjidpf _1ejjn7od _128midpf _4davidpf",
28
- interactive: "_80omtlke _4tpu1g4v _ez1ykb7n _gcm1182g _eeh8kb7n _jlxit94y",
28
+ interactive: "_80omtlke _4tpu1f0r _ez1ykb7n _gcm1jer9 _eeh8kb7n _jlxit94y",
29
29
  interactiveMotion: "_v564155l _1llweo6y"
30
30
  };
31
31
  const widthHeightMap = {
@@ -0,0 +1,11 @@
1
+ import { createContext } from 'react';
2
+ /**
3
+ * __Avatar context__
4
+ *
5
+ * An avatar context that provides the size of the avatar to children. Used by AvatarGroup
6
+ *
7
+ * - [Examples](https://atlassian.design/components/avatar/examples)
8
+ * - [Code](https://atlassian.design/components/avatar/code)
9
+ * - [Usage](https://atlassian.design/components/avatar/usage)
10
+ */
11
+ export const AvatarContext = /*#__PURE__*/createContext(undefined);
@@ -37,20 +37,20 @@
37
37
  ._syaz1kw7{color:inherit}
38
38
  ._syaz1rpy{color:var(--ds-text-subtlest,#6b6e76)}
39
39
  ._syazi7uo{color:var(--ds-text,#292a2e)}
40
- ._tzy41e4z{opacity:var(--ds-opacity-disabled,.5)}
40
+ ._tzy42wxo{opacity:var(--ds-opacity-disabled,.4)}
41
41
  ._vchhusvi{box-sizing:border-box}
42
42
  ._vwz419ii{line-height:1.4}
43
43
  ._vwz4kb7n{line-height:1}
44
44
  ._y3gn1e5h{text-align:left}
45
45
  ._y4ti1b66{padding-inline-end:var(--ds-space-050,4px)}
46
46
  ._zg8l4jg8{font-style:normal}
47
- ._858u194a:focus{border-color:var(--ds-border-focused,#2684ff)}
47
+ ._858u1v1w:focus{border-color:var(--ds-border-focused,#4688ec)}
48
48
  ._1hvw1o36:focus{outline-width:medium}
49
49
  ._49pcglyw:focus{outline-style:none}
50
50
  ._nt751r31:focus{outline-color:currentColor}
51
51
  ._1bnxglyw:hover{text-decoration-line:none}
52
52
  ._9oik1r31:hover{text-decoration-color:currentColor}
53
53
  ._d0altlke:hover{cursor:pointer}
54
- ._irr314ae:hover{background-color:var(--ds-background-neutral-subtle-hovered,#ebecf0)}
54
+ ._irr31dpa:hover{background-color:var(--ds-background-neutral-subtle-hovered,#0515240f)}
55
55
  ._jf4cnqa1:hover{text-decoration-style:solid}
56
- ._1di61l7b:active{background-color:var(--ds-background-neutral-subtle-pressed,#deebff)}
56
+ ._1di6fcek:active{background-color:var(--ds-background-neutral-subtle-pressed,#0b120e24)}
@@ -10,8 +10,8 @@ import getCustomElement from './internal/get-custom-element';
10
10
  const bgColorCssVar = '--avatar-item-bg-color';
11
11
  const styles = {
12
12
  root: "_2rkofajl _12ji1r31 _1qu2glyw _12y31o36 _4bfu1r31 _1hmsglyw _ajmmnqa1 _1h6d1j28 _1dqonqa1 _189e1dm9 _1e0c1txw _vchhusvi _1bsb1osq _4cvr1h6o _bfhk1g13 _syaz1kw7 _1wyb1kw7 _zg8l4jg8 _k48pi7a9 _vwz4kb7n _6rthze3t _1pfhze3t _12l2ze3t _ahbqze3t _85i51b66 _1q511b66 _y4ti1b66 _bozg1b66 _y3gn1e5h",
13
- rootDisabled: "_80om13gf _tzy41e4z _lcxvglyw",
14
- rootInteractive: "_nt751r31 _49pcglyw _1hvw1o36 _858u194a _9oik1r31 _1bnxglyw _jf4cnqa1 _irr314ae _d0altlke _1di61l7b",
13
+ rootDisabled: "_80om13gf _tzy42wxo _lcxvglyw",
14
+ rootInteractive: "_nt751r31 _49pcglyw _1hvw1o36 _858u1v1w _9oik1r31 _1bnxglyw _jf4cnqa1 _irr31dpa _d0altlke _1di6fcek",
15
15
  avatarItem: "_16jlkb7n _1o9zkb7n _i0dl1osq _1ul9idpf _p12f1osq _vwz419ii _bozgu2gc",
16
16
  baseText: "_1e0c1ule _syazi7uo",
17
17
  truncation: "_1reo15vq _1bto1l2s _o5721q9c",
@@ -6,15 +6,15 @@ import { forwardRef, isValidElement, useCallback, useEffect, useRef } from 'reac
6
6
  import { useAnalyticsEvents } from '@atlaskit/analytics-next';
7
7
  import { useId } from '@atlaskit/ds-lib/use-id';
8
8
  import { AvatarContent } from './avatar-content';
9
- import { useAvatarContext } from './context';
10
9
  import AvatarImage from './internal/avatar-image';
11
10
  import { AvatarContentContext } from './internal/content-context';
12
11
  import { EnsureIsInsideAvatarContext } from './internal/ensure-is-inside-avatar-context';
13
12
  import getCustomElement from './internal/get-custom-element';
14
13
  import PresenceWrapper from './internal/presence-wrapper';
15
14
  import StatusWrapper from './internal/status-wrapper';
15
+ import { useAvatarContext } from './use-avatar-context';
16
16
  const packageName = "@atlaskit/avatar";
17
- const packageVersion = "25.11.1";
17
+ const packageVersion = "25.11.3";
18
18
  const containerStyles = null;
19
19
 
20
20
  // eslint-disable-next-line @repo/internal/react/consistent-types-definitions
@@ -5,5 +5,6 @@ export { default as Presence } from './presence';
5
5
  export { default as Status } from './status';
6
6
  export { default as Skeleton } from './skeleton';
7
7
  export { default as getAppearanceForAppType } from './get-appearance';
8
- export { AvatarContext, useAvatarContext } from './context';
8
+ export { AvatarContext } from './avatar-context';
9
+ export { useAvatarContext } from './use-avatar-context';
9
10
  export { AVATAR_SIZES, BORDER_WIDTH, AVATAR_RADIUS, ACTIVE_SCALE_FACTOR } from './constants';
@@ -0,0 +1,3 @@
1
+ import { useContext } from 'react';
2
+ import { AvatarContext } from './avatar-context';
3
+ export const useAvatarContext = () => useContext(AvatarContext);
@@ -41,8 +41,8 @@
41
41
  ._1hfkvuon:after{background-color:var(--ds-surface,#fff)}
42
42
  ._1o9o1v1w:has(:focus-visible){background-color:var(--ds-border-focused,#4688ec)}
43
43
  ._1o9ovuon:has(:focus-visible){background-color:var(--ds-surface,#fff)}
44
+ ._1peq2wxo:after{opacity:var(--ds-opacity-disabled,.4)}
44
45
  ._1peqidpf:after{opacity:0}
45
- ._1peqs237:after{opacity:var(--ds-opacity-disabled,.7)}
46
46
  ._1pfhv77o{margin-block-start:var(--ds-space-025,2px)}
47
47
  ._1q51ze3t{padding-block-start:var(--ds-space-0,0)}
48
48
  ._1qu2glyw{outline-style:none}
@@ -55,7 +55,7 @@
55
55
  ._4t3i1ylp{height:40px}
56
56
  ._4t3i7vkz{height:1pc}
57
57
  ._4t3izwfg{height:2pc}
58
- ._4tpu1g4v:hover:after{background-color:var(--ds-interaction-hovered,rgba(9,30,66,.36))}
58
+ ._4tpu1f0r:hover:after{background-color:var(--ds-interaction-hovered,#00000029)}
59
59
  ._6rthv77o{margin-block-end:var(--ds-space-025,2px)}
60
60
  ._80om13gf{cursor:not-allowed}
61
61
  ._80om1kw7{cursor:inherit}
@@ -68,7 +68,7 @@
68
68
  ._bozgze3t{padding-inline-start:var(--ds-space-0,0)}
69
69
  ._eeh8kb7n:active:after{opacity:1}
70
70
  ._ez1ykb7n:hover:after{opacity:1}
71
- ._gcm1182g:active:after{background-color:var(--ds-interaction-pressed,rgba(9,30,66,.36))}
71
+ ._gcm1jer9:active:after{background-color:var(--ds-interaction-pressed,#00000052)}
72
72
  ._kqswh2mm{position:relative}
73
73
  ._kqswpfqs{position:static}
74
74
  ._mkrz1k6g{clip-path:polygon(45% 1.33975%,46.5798% .60307%,48.26352% .15192%,50% 0,51.73648% .15192%,53.4202% .60307%,55% 1.33975%,89.64102% 21.33975%,91.06889% 22.33956%,92.30146% 23.57212%,93.30127% 25%,94.03794% 26.5798%,94.48909% 28.26352%,94.64102% 30%,94.64102% 70%,94.48909% 71.73648%,94.03794% 73.4202%,93.30127% 75%,92.30146% 76.42788%,91.06889% 77.66044%,89.64102% 78.66025%,55% 98.66025%,53.4202% 99.39693%,51.73648% 99.84808%,50% 100%,48.26352% 99.84808%,46.5798% 99.39693%,45% 98.66025%,10.35898% 78.66025%,8.93111% 77.66044%,7.69854% 76.42788%,6.69873% 75%,5.96206% 73.4202%,5.51091% 71.73648%,5.35898% 70%,5.35898% 30%,5.51091% 28.26352%,5.96206% 26.5798%,6.69873% 25%,7.69854% 23.57212%,8.93111% 22.33956%,10.35898% 21.33975%)}
@@ -82,7 +82,7 @@
82
82
  ._1ah3v77o:focus-visible{outline-offset:var(--ds-space-025,2px)}
83
83
  ._1ejjglyw:focus-visible{box-shadow:none}
84
84
  ._1ejjn7od:focus-visible{box-shadow:unset}
85
- ._mizu194a:focus-visible{outline-color:var(--ds-border-focused,#2684ff)}
85
+ ._mizu1v1w:focus-visible{outline-color:var(--ds-border-focused,#4688ec)}
86
86
  ._ra3xnqa1:focus-visible{outline-style:solid}
87
87
  ._1llweo6y:hover{transform:scale(1.12)}
88
88
  @media screen and (-ms-high-contrast:active),screen and (forced-colors:active){._4dave4h9:focus-visible{outline-width:var(--ds-border-width,1px)}._4davidpf:focus-visible{outline-width:0}}
@@ -11,11 +11,11 @@ import { useEnsureIsInsideAvatar } from './internal/ensure-is-inside-avatar-cont
11
11
  var boxShadowCssVar = '--avatar-box-shadow';
12
12
  var bgColorCssVar = '--avatar-bg-color';
13
13
  var styles = {
14
- root: "_19itglyw _12ji1r31 _1qu2glyw _12y31o36 _1reo15vq _18m915vq _v564ieh6 _1e0c1txw _kqswpfqs _4cvr1fhb _1bah1h6o _2lx21bp4 _80om1kw7 _6rthv77o _1pfhv77o _12l2v77o _ahbqv77o _85i5ze3t _1q51ze3t _y4tize3t _bozgze3t _t9ec1aqe _9v7aze3t _qc5o1p41 _z0ai1osq _18postnw _1hfk1j28 _aetrf705 _1peqidpf _11fnglyw _1ejjglyw _mizu194a _1ah3v77o _ra3xnqa1 _128mdkaa _4dave4h9",
14
+ root: "_19itglyw _12ji1r31 _1qu2glyw _12y31o36 _1reo15vq _18m915vq _v564ieh6 _1e0c1txw _kqswpfqs _4cvr1fhb _1bah1h6o _2lx21bp4 _80om1kw7 _6rthv77o _1pfhv77o _12l2v77o _ahbqv77o _85i5ze3t _1q51ze3t _y4tize3t _bozgze3t _t9ec1aqe _9v7aze3t _qc5o1p41 _z0ai1osq _18postnw _1hfk1j28 _aetrf705 _1peqidpf _11fnglyw _1ejjglyw _mizu1v1w _1ah3v77o _ra3xnqa1 _128mdkaa _4dave4h9",
15
15
  circle: "_2rko1qll _14mj1qll",
16
16
  square: "_2rkol0p1",
17
17
  positionRelative: "_kqswh2mm",
18
- disabled: "_80om13gf _1hfkvuon _1peqs237"
18
+ disabled: "_80om13gf _1hfkvuon _1peq2wxo"
19
19
  };
20
20
  var unboundStyles = {
21
21
  rootCustomBorder: "_11q7cxp3",
@@ -26,7 +26,7 @@ var unboundStyles = {
26
26
  hexagonBorderContainer: "_1rjcf6hp _18zruxly _bfhkcxp3 _mkrz1kw7 _1o9ovuon",
27
27
  hexagonBorderContainerMarginFg: "_1mou18m8 _195gzwb8",
28
28
  hexagon: "_2rkoidpf _mkrz1kw7 _16qsn7od _14mjidpf _1ejjn7od _128midpf _4davidpf",
29
- interactive: "_80omtlke _4tpu1g4v _ez1ykb7n _gcm1182g _eeh8kb7n _jlxit94y",
29
+ interactive: "_80omtlke _4tpu1f0r _ez1ykb7n _gcm1jer9 _eeh8kb7n _jlxit94y",
30
30
  interactiveMotion: "_v564155l _1llweo6y"
31
31
  };
32
32
  var widthHeightMap = {
@@ -0,0 +1,11 @@
1
+ import { createContext } from 'react';
2
+ /**
3
+ * __Avatar context__
4
+ *
5
+ * An avatar context that provides the size of the avatar to children. Used by AvatarGroup
6
+ *
7
+ * - [Examples](https://atlassian.design/components/avatar/examples)
8
+ * - [Code](https://atlassian.design/components/avatar/code)
9
+ * - [Usage](https://atlassian.design/components/avatar/usage)
10
+ */
11
+ export var AvatarContext = /*#__PURE__*/createContext(undefined);
@@ -37,20 +37,20 @@
37
37
  ._syaz1kw7{color:inherit}
38
38
  ._syaz1rpy{color:var(--ds-text-subtlest,#6b6e76)}
39
39
  ._syazi7uo{color:var(--ds-text,#292a2e)}
40
- ._tzy41e4z{opacity:var(--ds-opacity-disabled,.5)}
40
+ ._tzy42wxo{opacity:var(--ds-opacity-disabled,.4)}
41
41
  ._vchhusvi{box-sizing:border-box}
42
42
  ._vwz419ii{line-height:1.4}
43
43
  ._vwz4kb7n{line-height:1}
44
44
  ._y3gn1e5h{text-align:left}
45
45
  ._y4ti1b66{padding-inline-end:var(--ds-space-050,4px)}
46
46
  ._zg8l4jg8{font-style:normal}
47
- ._858u194a:focus{border-color:var(--ds-border-focused,#2684ff)}
47
+ ._858u1v1w:focus{border-color:var(--ds-border-focused,#4688ec)}
48
48
  ._1hvw1o36:focus{outline-width:medium}
49
49
  ._49pcglyw:focus{outline-style:none}
50
50
  ._nt751r31:focus{outline-color:currentColor}
51
51
  ._1bnxglyw:hover{text-decoration-line:none}
52
52
  ._9oik1r31:hover{text-decoration-color:currentColor}
53
53
  ._d0altlke:hover{cursor:pointer}
54
- ._irr314ae:hover{background-color:var(--ds-background-neutral-subtle-hovered,#ebecf0)}
54
+ ._irr31dpa:hover{background-color:var(--ds-background-neutral-subtle-hovered,#0515240f)}
55
55
  ._jf4cnqa1:hover{text-decoration-style:solid}
56
- ._1di61l7b:active{background-color:var(--ds-background-neutral-subtle-pressed,#deebff)}
56
+ ._1di6fcek:active{background-color:var(--ds-background-neutral-subtle-pressed,#0b120e24)}
@@ -11,8 +11,8 @@ import getCustomElement from './internal/get-custom-element';
11
11
  var bgColorCssVar = '--avatar-item-bg-color';
12
12
  var styles = {
13
13
  root: "_2rkofajl _12ji1r31 _1qu2glyw _12y31o36 _4bfu1r31 _1hmsglyw _ajmmnqa1 _1h6d1j28 _1dqonqa1 _189e1dm9 _1e0c1txw _vchhusvi _1bsb1osq _4cvr1h6o _bfhk1g13 _syaz1kw7 _1wyb1kw7 _zg8l4jg8 _k48pi7a9 _vwz4kb7n _6rthze3t _1pfhze3t _12l2ze3t _ahbqze3t _85i51b66 _1q511b66 _y4ti1b66 _bozg1b66 _y3gn1e5h",
14
- rootDisabled: "_80om13gf _tzy41e4z _lcxvglyw",
15
- rootInteractive: "_nt751r31 _49pcglyw _1hvw1o36 _858u194a _9oik1r31 _1bnxglyw _jf4cnqa1 _irr314ae _d0altlke _1di61l7b",
14
+ rootDisabled: "_80om13gf _tzy42wxo _lcxvglyw",
15
+ rootInteractive: "_nt751r31 _49pcglyw _1hvw1o36 _858u1v1w _9oik1r31 _1bnxglyw _jf4cnqa1 _irr31dpa _d0altlke _1di6fcek",
16
16
  avatarItem: "_16jlkb7n _1o9zkb7n _i0dl1osq _1ul9idpf _p12f1osq _vwz419ii _bozgu2gc",
17
17
  baseText: "_1e0c1ule _syazi7uo",
18
18
  truncation: "_1reo15vq _1bto1l2s _o5721q9c",
@@ -9,15 +9,15 @@ import { forwardRef, isValidElement, useCallback, useEffect, useRef } from 'reac
9
9
  import { useAnalyticsEvents } from '@atlaskit/analytics-next';
10
10
  import { useId } from '@atlaskit/ds-lib/use-id';
11
11
  import { AvatarContent } from './avatar-content';
12
- import { useAvatarContext } from './context';
13
12
  import AvatarImage from './internal/avatar-image';
14
13
  import { AvatarContentContext } from './internal/content-context';
15
14
  import { EnsureIsInsideAvatarContext } from './internal/ensure-is-inside-avatar-context';
16
15
  import getCustomElement from './internal/get-custom-element';
17
16
  import PresenceWrapper from './internal/presence-wrapper';
18
17
  import StatusWrapper from './internal/status-wrapper';
18
+ import { useAvatarContext } from './use-avatar-context';
19
19
  var packageName = "@atlaskit/avatar";
20
- var packageVersion = "25.11.1";
20
+ var packageVersion = "25.11.3";
21
21
  var containerStyles = null;
22
22
 
23
23
  // eslint-disable-next-line @repo/internal/react/consistent-types-definitions
package/dist/esm/index.js CHANGED
@@ -5,5 +5,6 @@ export { default as Presence } from './presence';
5
5
  export { default as Status } from './status';
6
6
  export { default as Skeleton } from './skeleton';
7
7
  export { default as getAppearanceForAppType } from './get-appearance';
8
- export { AvatarContext, useAvatarContext } from './context';
8
+ export { AvatarContext } from './avatar-context';
9
+ export { useAvatarContext } from './use-avatar-context';
9
10
  export { AVATAR_SIZES, BORDER_WIDTH, AVATAR_RADIUS, ACTIVE_SCALE_FACTOR } from './constants';
@@ -0,0 +1,5 @@
1
+ import { useContext } from 'react';
2
+ import { AvatarContext } from './avatar-context';
3
+ export var useAvatarContext = function useAvatarContext() {
4
+ return useContext(AvatarContext);
5
+ };
@@ -0,0 +1,14 @@
1
+ import { type SizeType } from './types';
2
+ export type AvatarContextProps = {
3
+ size: SizeType;
4
+ };
5
+ /**
6
+ * __Avatar context__
7
+ *
8
+ * An avatar context that provides the size of the avatar to children. Used by AvatarGroup
9
+ *
10
+ * - [Examples](https://atlassian.design/components/avatar/examples)
11
+ * - [Code](https://atlassian.design/components/avatar/code)
12
+ * - [Usage](https://atlassian.design/components/avatar/usage)
13
+ */
14
+ export declare const AvatarContext: import('react').Context<AvatarContextProps | undefined>;
@@ -10,6 +10,8 @@ export type { StatusProps } from './status';
10
10
  export { default as Skeleton } from './skeleton';
11
11
  export type { SkeletonProps } from './skeleton';
12
12
  export { default as getAppearanceForAppType } from './get-appearance';
13
- export { AvatarContext, type AvatarContextProps, useAvatarContext } from './context';
13
+ export { AvatarContext } from './avatar-context';
14
+ export type { AvatarContextProps } from './avatar-context';
15
+ export { useAvatarContext } from './use-avatar-context';
14
16
  export { AVATAR_SIZES, BORDER_WIDTH, AVATAR_RADIUS, ACTIVE_SCALE_FACTOR } from './constants';
15
17
  export type { AvatarClickEventHandler, AppearanceType, SizeType, Presence as PresenceType, Status as StatusType, IndicatorSizeType, } from './types';
@@ -0,0 +1,2 @@
1
+ import { type AvatarContextProps } from './avatar-context';
2
+ export declare const useAvatarContext: () => AvatarContextProps | undefined;
@@ -0,0 +1,14 @@
1
+ import { type SizeType } from './types';
2
+ export type AvatarContextProps = {
3
+ size: SizeType;
4
+ };
5
+ /**
6
+ * __Avatar context__
7
+ *
8
+ * An avatar context that provides the size of the avatar to children. Used by AvatarGroup
9
+ *
10
+ * - [Examples](https://atlassian.design/components/avatar/examples)
11
+ * - [Code](https://atlassian.design/components/avatar/code)
12
+ * - [Usage](https://atlassian.design/components/avatar/usage)
13
+ */
14
+ export declare const AvatarContext: import('react').Context<AvatarContextProps | undefined>;
@@ -10,6 +10,8 @@ export type { StatusProps } from './status';
10
10
  export { default as Skeleton } from './skeleton';
11
11
  export type { SkeletonProps } from './skeleton';
12
12
  export { default as getAppearanceForAppType } from './get-appearance';
13
- export { AvatarContext, type AvatarContextProps, useAvatarContext } from './context';
13
+ export { AvatarContext } from './avatar-context';
14
+ export type { AvatarContextProps } from './avatar-context';
15
+ export { useAvatarContext } from './use-avatar-context';
14
16
  export { AVATAR_SIZES, BORDER_WIDTH, AVATAR_RADIUS, ACTIVE_SCALE_FACTOR } from './constants';
15
17
  export type { AvatarClickEventHandler, AppearanceType, SizeType, Presence as PresenceType, Status as StatusType, IndicatorSizeType, } from './types';
@@ -0,0 +1,2 @@
1
+ import { type AvatarContextProps } from './avatar-context';
2
+ export declare const useAvatarContext: () => AvatarContextProps | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/avatar",
3
- "version": "25.11.2",
3
+ "version": "25.11.4",
4
4
  "description": "An avatar is a visual representation of a user or entity.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -25,6 +25,13 @@
25
25
  ],
26
26
  "atlaskit:src": "src/index.tsx",
27
27
  "atlassian": {
28
+ "react-compiler": {
29
+ "enabled": true,
30
+ "gating": {
31
+ "source": "@atlassian/react-compiler-gating",
32
+ "importSpecifierName": "isReactCompilerActivePlatform"
33
+ }
34
+ },
28
35
  "team": "Design System Team",
29
36
  "website": {
30
37
  "name": "Avatar",
@@ -60,6 +67,7 @@
60
67
  "@atlaskit/textfield": "^8.2.0",
61
68
  "@atlaskit/tooltip": "^21.1.0",
62
69
  "@atlassian/feature-flags-test-utils": "^1.0.0",
70
+ "@atlassian/react-compiler-gating": "workspace:^",
63
71
  "@atlassian/ssr-tests": "workspace:^",
64
72
  "@atlassian/structured-docs-types": "workspace:^",
65
73
  "@atlassian/testing-library": "^0.5.0",
@@ -1,24 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.useAvatarContext = exports.AvatarContext = void 0;
7
- var _react = require("react");
8
- /**
9
- * __Avatar context__
10
- *
11
- * This allows setting the size of all avatars under a context provider.
12
- *
13
- * ```tsx
14
- * <AvatarContext.Provider value={{ size: 'small' }}>
15
- * <Avatar
16
- * // ...props
17
- * />
18
- * </AvatarContext.Provider>
19
- * ```
20
- */
21
- var AvatarContext = exports.AvatarContext = /*#__PURE__*/(0, _react.createContext)(undefined);
22
- var useAvatarContext = exports.useAvatarContext = function useAvatarContext() {
23
- return (0, _react.useContext)(AvatarContext);
24
- };
@@ -1,16 +0,0 @@
1
- import { createContext, useContext } from 'react';
2
- /**
3
- * __Avatar context__
4
- *
5
- * This allows setting the size of all avatars under a context provider.
6
- *
7
- * ```tsx
8
- * <AvatarContext.Provider value={{ size: 'small' }}>
9
- * <Avatar
10
- * // ...props
11
- * />
12
- * </AvatarContext.Provider>
13
- * ```
14
- */
15
- export const AvatarContext = /*#__PURE__*/createContext(undefined);
16
- export const useAvatarContext = () => useContext(AvatarContext);
@@ -1,18 +0,0 @@
1
- import { createContext, useContext } from 'react';
2
- /**
3
- * __Avatar context__
4
- *
5
- * This allows setting the size of all avatars under a context provider.
6
- *
7
- * ```tsx
8
- * <AvatarContext.Provider value={{ size: 'small' }}>
9
- * <Avatar
10
- * // ...props
11
- * />
12
- * </AvatarContext.Provider>
13
- * ```
14
- */
15
- export var AvatarContext = /*#__PURE__*/createContext(undefined);
16
- export var useAvatarContext = function useAvatarContext() {
17
- return useContext(AvatarContext);
18
- };
@@ -1,19 +0,0 @@
1
- import { type SizeType } from './types';
2
- export type AvatarContextProps = {
3
- size: SizeType;
4
- };
5
- /**
6
- * __Avatar context__
7
- *
8
- * This allows setting the size of all avatars under a context provider.
9
- *
10
- * ```tsx
11
- * <AvatarContext.Provider value={{ size: 'small' }}>
12
- * <Avatar
13
- * // ...props
14
- * />
15
- * </AvatarContext.Provider>
16
- * ```
17
- */
18
- export declare const AvatarContext: import('react').Context<AvatarContextProps | undefined>;
19
- export declare const useAvatarContext: () => AvatarContextProps | undefined;
@@ -1,19 +0,0 @@
1
- import { type SizeType } from './types';
2
- export type AvatarContextProps = {
3
- size: SizeType;
4
- };
5
- /**
6
- * __Avatar context__
7
- *
8
- * This allows setting the size of all avatars under a context provider.
9
- *
10
- * ```tsx
11
- * <AvatarContext.Provider value={{ size: 'small' }}>
12
- * <Avatar
13
- * // ...props
14
- * />
15
- * </AvatarContext.Provider>
16
- * ```
17
- */
18
- export declare const AvatarContext: import('react').Context<AvatarContextProps | undefined>;
19
- export declare const useAvatarContext: () => AvatarContextProps | undefined;