@arc-ui/components 11.18.0 → 11.20.0

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 (136) hide show
  1. package/dist/Alert/Alert.cjs.js +1 -1
  2. package/dist/Alert/Alert.esm.js +1 -1
  3. package/dist/Avatar/Avatar.cjs.js +18 -0
  4. package/dist/Avatar/Avatar.esm.js +10 -0
  5. package/dist/Avatar/package.json +7 -0
  6. package/dist/AvatarGroup/AvatarGroup.cjs.js +37 -0
  7. package/dist/AvatarGroup/AvatarGroup.esm.js +29 -0
  8. package/dist/AvatarGroup/package.json +7 -0
  9. package/dist/Breadcrumbs/Breadcrumbs.cjs.js +2 -2
  10. package/dist/Breadcrumbs/Breadcrumbs.esm.js +2 -2
  11. package/dist/Button/Button.cjs.js +2 -2
  12. package/dist/Button/Button.esm.js +2 -2
  13. package/dist/Calendar/Calendar.cjs.js +2 -2
  14. package/dist/Calendar/Calendar.esm.js +2 -2
  15. package/dist/Card/Card.cjs.js +2 -2
  16. package/dist/Card/Card.esm.js +2 -2
  17. package/dist/Checkbox/Checkbox.cjs.js +2 -2
  18. package/dist/Checkbox/Checkbox.esm.js +2 -2
  19. package/dist/DatePicker/DatePicker.cjs.js +5 -5
  20. package/dist/DatePicker/DatePicker.esm.js +5 -5
  21. package/dist/Disclosure/Disclosure.cjs.js +5 -1
  22. package/dist/Disclosure/Disclosure.esm.js +6 -2
  23. package/dist/FormControl/FormControl.cjs.js +1 -1
  24. package/dist/FormControl/FormControl.esm.js +1 -1
  25. package/dist/Icon/Icon.cjs.js +1 -1
  26. package/dist/Icon/Icon.esm.js +1 -1
  27. package/dist/InformationCard/InformationCard.cjs.js +8 -8
  28. package/dist/InformationCard/InformationCard.esm.js +5 -5
  29. package/dist/MediaCard/MediaCard.cjs.js +7 -11
  30. package/dist/MediaCard/MediaCard.esm.js +4 -8
  31. package/dist/Modal/Modal.cjs.js +2 -2
  32. package/dist/Modal/Modal.esm.js +2 -2
  33. package/dist/Pagination/Pagination.cjs.js +1 -1
  34. package/dist/Pagination/Pagination.esm.js +1 -1
  35. package/dist/PaginationSimple/PaginationSimple.cjs.js +1 -1
  36. package/dist/PaginationSimple/PaginationSimple.esm.js +1 -1
  37. package/dist/ProgressBar/ProgressBar.cjs.js +1 -1
  38. package/dist/ProgressBar/ProgressBar.esm.js +1 -1
  39. package/dist/ProgressStepper/ProgressStepper.cjs.js +2 -2
  40. package/dist/ProgressStepper/ProgressStepper.esm.js +2 -2
  41. package/dist/RadioGroup/RadioGroup.cjs.js +2 -2
  42. package/dist/RadioGroup/RadioGroup.esm.js +2 -2
  43. package/dist/Rule/Rule.cjs.js +11 -7
  44. package/dist/Rule/Rule.esm.js +11 -7
  45. package/dist/ScrollToTop/ScrollToTop.cjs.js +2 -2
  46. package/dist/ScrollToTop/ScrollToTop.esm.js +2 -2
  47. package/dist/Select/Select.cjs.js +9 -7
  48. package/dist/Select/Select.esm.js +9 -7
  49. package/dist/SiteHeader/SiteHeader.cjs.js +3 -3
  50. package/dist/SiteHeader/SiteHeader.esm.js +3 -3
  51. package/dist/SiteHeaderV2/SiteHeaderV2.cjs.js +3 -3
  52. package/dist/SiteHeaderV2/SiteHeaderV2.esm.js +3 -3
  53. package/dist/SkipLink/SkipLink.cjs.js +23 -0
  54. package/dist/SkipLink/SkipLink.esm.js +15 -0
  55. package/dist/SkipLink/package.json +7 -0
  56. package/dist/Switch/Switch.cjs.js +2 -2
  57. package/dist/Switch/Switch.esm.js +2 -2
  58. package/dist/Tabs/Tabs.cjs.js +2 -2
  59. package/dist/Tabs/Tabs.esm.js +2 -2
  60. package/dist/Tag/Tag.cjs.js +2 -2
  61. package/dist/Tag/Tag.esm.js +2 -2
  62. package/dist/TextArea/TextArea.cjs.js +14 -14
  63. package/dist/TextArea/TextArea.esm.js +14 -14
  64. package/dist/TextInput/TextInput.cjs.js +3 -3
  65. package/dist/TextInput/TextInput.esm.js +3 -3
  66. package/dist/Toast/Toast.cjs.js +2 -2
  67. package/dist/Toast/Toast.esm.js +2 -2
  68. package/dist/TypographyCard/TypographyCard.cjs.js +5 -5
  69. package/dist/TypographyCard/TypographyCard.esm.js +3 -3
  70. package/dist/_shared/cjs/Avatar-12ece0dd.js +65 -0
  71. package/dist/_shared/cjs/{Breadcrumbs-ef659d2b.js → Breadcrumbs-c6eaf5c4.js} +1 -1
  72. package/dist/_shared/cjs/{Button-4fed080a.js → Button-84533dc8.js} +1 -1
  73. package/dist/_shared/cjs/{Calendar-18e255f8.js → Calendar-c6ed5f2c.js} +1 -1
  74. package/dist/_shared/cjs/{Card-17dcc171.js → Card-5b19cabc.js} +1 -1
  75. package/dist/_shared/cjs/{CardFooter-43c32239.js → CardFooter-4a68a862.js} +3 -3
  76. package/dist/_shared/cjs/{Checkbox-4d4b432f.js → Checkbox-8915fcd9.js} +1 -1
  77. package/dist/_shared/cjs/ConditionalWrapper-be3b2625.js +14 -0
  78. package/dist/_shared/cjs/{FormControl-b26ad353.js → FormControl-5f3b6ce4.js} +9 -4
  79. package/dist/_shared/cjs/{Icon-a9801f05.js → Icon-b46897a3.js} +6 -2
  80. package/dist/_shared/cjs/{ProgressStepper-9cdc0afe.js → ProgressStepper-3af8a210.js} +1 -1
  81. package/dist/_shared/cjs/{RadioGroup-23c964ae.js → RadioGroup-07bb155e.js} +11 -6
  82. package/dist/_shared/cjs/{SiteHeader.rehydrator-df053a52.js → SiteHeader.rehydrator-ea49f8d5.js} +2 -2
  83. package/dist/_shared/cjs/{SiteHeaderV2-79930632.js → SiteHeaderV2-301c765c.js} +11 -27
  84. package/dist/_shared/cjs/{Tabs-34db6bc1.js → Tabs-24e6f45b.js} +1 -1
  85. package/dist/_shared/cjs/{Tag-42ddca45.js → Tag-8723b324.js} +1 -1
  86. package/dist/_shared/cjs/{TextInput-d0370fa8.js → TextInput-5da70ec2.js} +6 -3
  87. package/dist/_shared/cjs/{Toast-392b1d60.js → Toast-7a20d1b9.js} +1 -1
  88. package/dist/_shared/esm/Avatar-d01e2b7b.js +59 -0
  89. package/dist/_shared/esm/{Breadcrumbs-36edfb3d.js → Breadcrumbs-7d55e1a6.js} +1 -1
  90. package/dist/_shared/esm/{Button-a453e8e4.js → Button-3f294e64.js} +1 -1
  91. package/dist/_shared/esm/{Calendar-4033fa48.js → Calendar-753ef6f1.js} +1 -1
  92. package/dist/_shared/esm/{Card-201e9f28.js → Card-7fc6c9b4.js} +1 -1
  93. package/dist/_shared/esm/{CardFooter-dd8d4000.js → CardFooter-a08b70ee.js} +2 -2
  94. package/dist/_shared/esm/{Checkbox-720b074d.js → Checkbox-0e051546.js} +1 -1
  95. package/dist/_shared/esm/ConditionalWrapper-59be8f35.js +8 -0
  96. package/dist/_shared/esm/{FormControl-f0b8fe91.js → FormControl-cc99cde0.js} +9 -4
  97. package/dist/_shared/esm/{Icon-abd0d990.js → Icon-15799695.js} +6 -2
  98. package/dist/_shared/esm/{ProgressStepper-f51f86c3.js → ProgressStepper-d4c5b6d9.js} +1 -1
  99. package/dist/_shared/esm/{RadioGroup-37fdb06b.js → RadioGroup-362be63f.js} +11 -6
  100. package/dist/_shared/esm/{SiteHeader.rehydrator-32bdcd88.js → SiteHeader.rehydrator-65c8cf71.js} +2 -2
  101. package/dist/_shared/esm/{SiteHeaderV2-9e7e7d3b.js → SiteHeaderV2-0096e25b.js} +11 -27
  102. package/dist/_shared/esm/{Tabs-df9965dd.js → Tabs-a85af483.js} +1 -1
  103. package/dist/_shared/esm/{Tag-92c088a9.js → Tag-664b85c8.js} +1 -1
  104. package/dist/_shared/esm/{TextInput-abbab56b.js → TextInput-1d1c5fd6.js} +6 -4
  105. package/dist/_shared/esm/{Toast-5d66e13f.js → Toast-7a232e15.js} +1 -1
  106. package/dist/index.es.js +291 -215
  107. package/dist/index.es.js.map +1 -1
  108. package/dist/index.js +291 -213
  109. package/dist/index.js.map +1 -1
  110. package/dist/styles.css +4 -4
  111. package/dist/types/components/Avatar/Avatar.d.ts +13 -0
  112. package/dist/types/components/Avatar/components/AvatarContent/AvatarContent.d.ts +9 -0
  113. package/dist/types/components/Avatar/index.d.ts +1 -0
  114. package/dist/types/components/Avatar/types/avatar-icon-size.d.ts +1 -0
  115. package/dist/types/components/Avatar/types/avatar-image.d.ts +2 -0
  116. package/dist/types/components/Avatar/types/avatar-size.d.ts +1 -0
  117. package/dist/types/components/Avatar/types/avatar-text-size.d.ts +2 -0
  118. package/dist/types/components/AvatarGroup/AvatarGroup.d.ts +13 -0
  119. package/dist/types/components/AvatarGroup/index.d.ts +1 -0
  120. package/dist/types/components/AvatarGroup/types/group-avatar.d.ts +2 -0
  121. package/dist/types/components/AvatarGroup/utils/get-avatars.d.ts +2 -0
  122. package/dist/types/components/DatePicker/DatePicker.d.ts +2 -2
  123. package/dist/types/components/Icon/Icon.d.ts +4 -0
  124. package/dist/types/components/RadioGroup/RadioButton/RadioButton.d.ts +5 -0
  125. package/dist/types/components/Rule/Rule.d.ts +2 -1
  126. package/dist/types/components/Select/Select.d.ts +4 -0
  127. package/dist/types/components/SkipLink/SkipLink.d.ts +11 -0
  128. package/dist/types/components/SkipLink/SkipLinkItem/SkipLinkItem.d.ts +16 -0
  129. package/dist/types/components/SkipLink/index.d.ts +1 -0
  130. package/dist/types/components/TextInput/TextInput.d.ts +4 -4
  131. package/dist/types/components/index.d.ts +2 -0
  132. package/dist/types/private-components/ConditionalWrapper/ConditionalWrapper.d.ts +1 -0
  133. package/dist/types/styles.d.ts +3 -0
  134. package/package.json +2 -2
  135. package/dist/_shared/cjs/{CardLabel-768abf20.js → BtIconArrowRight.esm-50d96943.js} +20 -20
  136. package/dist/_shared/esm/{CardLabel-d6d71407.js → BtIconArrowRight.esm-9b181878.js} +20 -20
@@ -3,10 +3,10 @@
3
3
  var filterDataAttrs = require('./filter-data-attrs-1c9a530c.js');
4
4
  var index = require('./index-9947ac13.js');
5
5
  var React = require('react');
6
- var FormControl = require('./FormControl-b26ad353.js');
6
+ var FormControl = require('./FormControl-5f3b6ce4.js');
7
7
  var Surface = require('./Surface-038db6e1.js');
8
8
  var VisuallyHidden = require('./VisuallyHidden-e2c8b291.js');
9
- var Icon = require('./Icon-a9801f05.js');
9
+ var Icon = require('./Icon-b46897a3.js');
10
10
 
11
11
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
12
12
 
@@ -42,7 +42,7 @@ var useNumericInput = function (props) {
42
42
  /**
43
43
  * Use `TextInput` to allow custom user text entry with a keyboard.
44
44
  */
45
- var TextInput = React.forwardRef(function (_a, ref) {
45
+ var TextInputComponent = React.forwardRef(function (_a, ref) {
46
46
  var _b;
47
47
  var _c = _a.defaultValue, defaultValue = _c === void 0 ? "" : _c, errorMessage = _a.errorMessage, helper = _a.helper, hideLabel = _a.hideLabel, id = _a.id, inputMode = _a.inputMode, _d = _a.isDisabled, isDisabled = _d === void 0 ? false : _d, _e = _a.isReadOnly, isReadOnly = _e === void 0 ? false : _e, _f = _a.isRequired, isRequired = _f === void 0 ? false : _f, label = _a.label, _g = _a.labelSize, labelSize = _g === void 0 ? "l" : _g, maxLength = _a.maxLength, minLength = _a.minLength, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, placeholder = _a.placeholder, onClickDisclosure = _a.onClickDisclosure, pattern = _a.pattern, _h = _a.type, type = _h === void 0 ? "text" : _h, _j = _a.showPassword, showPassword = _j === void 0 ? false : _j, value = _a.value, disclosureTitle = _a.disclosureTitle, disclosureText = _a.disclosureText, _k = _a.inputSize, inputSize = _k === void 0 ? "m" : _k, iconButton = _a.iconButton, prefix = _a.prefix, suffix = _a.suffix, _l = _a.inputAlignment, inputAlignment = _l === void 0 ? "left" : _l, width = _a.width, props = filterDataAttrs.__rest(_a, ["defaultValue", "errorMessage", "helper", "hideLabel", "id", "inputMode", "isDisabled", "isReadOnly", "isRequired", "label", "labelSize", "maxLength", "minLength", "name", "onBlur", "onChange", "placeholder", "onClickDisclosure", "pattern", "type", "showPassword", "value", "disclosureTitle", "disclosureText", "inputSize", "iconButton", "prefix", "suffix", "inputAlignment", "width"]);
48
48
  var surface = React.useContext(Surface.Context).surface;
@@ -96,5 +96,8 @@ var TextInput = React.forwardRef(function (_a, ref) {
96
96
  ? "Your password is shown"
97
97
  : "Your password is hidden")))))))));
98
98
  });
99
+ var TextInput = React.forwardRef(function (props, ref) { return React__default["default"].createElement(TextInputComponent, filterDataAttrs.__assign({ ref: ref }, props)); });
100
+ var TextInputWithPlaceHolder = React.forwardRef(function (props, ref) { return React__default["default"].createElement(TextInputComponent, filterDataAttrs.__assign({ ref: ref }, props)); });
99
101
 
100
102
  exports.TextInput = TextInput;
103
+ exports.TextInputWithPlaceHolder = TextInputWithPlaceHolder;
@@ -13,7 +13,7 @@ var index$5 = require('./index-9947ac13.js');
13
13
  var BtIconCrossAlt2Px_esm = require('./BtIconCrossAlt2Px.esm-1452b14b.js');
14
14
  var BtIconTick_esm = require('./BtIconTick.esm-844eac6c.js');
15
15
  var BtIconAlert_esm = require('./BtIconAlert.esm-1a0ff9f0.js');
16
- var Icon = require('./Icon-a9801f05.js');
16
+ var Icon = require('./Icon-b46897a3.js');
17
17
 
18
18
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
19
19
 
@@ -0,0 +1,59 @@
1
+ import { a as __assign, _ as __rest, f as filterDataAttrs } from './filter-data-attrs-ea8f4ed4.js';
2
+ import React__default from 'react';
3
+ import { c as classNames } from './index-2e73c2e9.js';
4
+ import './Surface-0ca6817d.js';
5
+ import { C as ConditionalWrapper } from './ConditionalWrapper-59be8f35.js';
6
+ import { I as Icon } from './Icon-15799695.js';
7
+ import { I as Image } from './Image-12fbd327.js';
8
+ import { H as Heading } from './Heading-d16e0e53.js';
9
+
10
+ const BtIconUser = (props) =>
11
+ /*#__PURE__*/ React__default.createElement(
12
+ "svg",
13
+ Object.assign(
14
+ {
15
+ xmlns: "http://www.w3.org/2000/svg",
16
+ viewBox: "0 0 32 32",
17
+ },
18
+ props,
19
+ ),
20
+ /*#__PURE__*/ React__default.createElement("defs", null),
21
+ /*#__PURE__*/ React__default.createElement("path", {
22
+ d: "M20.87579,16.014a6.99843,6.99843,0,1,0-9.75378.00091C6.725,17.77887,4,21.452,4,25.66113V27a1.001,1.001,0,0,0,1,1H27a1.001,1.001,0,0,0,1-1V25.66113C28,21.45129,25.27423,17.77765,20.87579,16.014ZM10,11a5.998,5.998,0,1,1,6,6A6.0068,6.0068,0,0,1,10,11ZM27,27H5V25.66113c0-4.61181,3.46484-7.57324,6.707-8.80761l.29492-.11206a6.97581,6.97581,0,0,0,7.99457-.00062l.29645.11268C23.53516,18.08789,27,21.04932,27,25.66113Z",
23
+ fill: "currentColor",
24
+ }),
25
+ );
26
+
27
+ var AvatarContent = function (_a) {
28
+ var img = _a.img, initials = _a.initials, _b = _a.size, size = _b === void 0 ? "xl" : _b;
29
+ var textSize = {
30
+ s: "xxxs",
31
+ m: "xxs",
32
+ l: "xs",
33
+ xl: "s"
34
+ };
35
+ var iconSize = {
36
+ s: 16,
37
+ m: 24,
38
+ l: 32,
39
+ xl: 40
40
+ };
41
+ if (img) {
42
+ return React__default.createElement(Image, __assign({ fit: "cover" }, img));
43
+ }
44
+ if (initials) {
45
+ return (React__default.createElement(Heading, { size: textSize[size] }, initials.substring(0, 3).toUpperCase()));
46
+ }
47
+ return React__default.createElement(Icon, { size: iconSize[size], icon: BtIconUser });
48
+ };
49
+
50
+ var Avatar = function (_a) {
51
+ var img = _a.img, initials = _a.initials, href = _a.href, title = _a.title, ariaLabel = _a.ariaLabel, onClick = _a.onClick, _b = _a.size, size = _b === void 0 ? "xl" : _b, props = __rest(_a, ["img", "initials", "href", "title", "ariaLabel", "onClick", "size"]);
52
+ var wrapperAttrs = __assign({ className: classNames("arc-Avatar", "arc-Avatar--".concat(size), {
53
+ "arc-Avatar--img": Boolean(img)
54
+ }) }, filterDataAttrs(props));
55
+ return (React__default.createElement(ConditionalWrapper, { condition: Boolean(href), wrapper: function (children) { return (React__default.createElement("a", __assign({ href: href, "aria-label": ariaLabel, onClick: onClick, title: title }, wrapperAttrs), children)); }, fallback: function (children) { return React__default.createElement("div", __assign({}, wrapperAttrs), children); } },
56
+ React__default.createElement(AvatarContent, { size: size, img: img, initials: initials })));
57
+ };
58
+
59
+ export { Avatar as A };
@@ -2,7 +2,7 @@ import { _ as __rest, a as __assign, f as filterDataAttrs } from './filter-data-
2
2
  import React__default, { useRef, useState, useEffect } from 'react';
3
3
  import { d as debounce_1 } from './debounce-6fed6b84.js';
4
4
  import { B as BtIconChevronLeft2Px, a as BtIconChevronRight2Px } from './BtIconChevronRight2Px.esm-75e92636.js';
5
- import { I as Icon } from './Icon-abd0d990.js';
5
+ import { I as Icon } from './Icon-15799695.js';
6
6
  import { c as classNames } from './index-2e73c2e9.js';
7
7
  import { h as handleLinkClick } from './handle-link-click-f64f55a2.js';
8
8
 
@@ -4,7 +4,7 @@ import { B as BtIconChevronRightMid } from './BtIconChevronRightMid.esm-32268f1a
4
4
  import { c as classNames } from './index-2e73c2e9.js';
5
5
  import React__default, { forwardRef, useContext } from 'react';
6
6
  import { s as suffixModifier } from './suffix-modifier-3d548e45.js';
7
- import { I as Icon } from './Icon-abd0d990.js';
7
+ import { I as Icon } from './Icon-15799695.js';
8
8
  import { C as Context } from './Surface-0ca6817d.js';
9
9
 
10
10
  /**
@@ -8,7 +8,7 @@ import { S as Surface } from './Surface-0ca6817d.js';
8
8
  import { H as Heading } from './Heading-d16e0e53.js';
9
9
  import { B as BtIconChevronLeftMid } from './BtIconChevronLeftMid.esm-1ed8330b.js';
10
10
  import { B as BtIconChevronRightMid } from './BtIconChevronRightMid.esm-32268f1a.js';
11
- import { I as Icon } from './Icon-abd0d990.js';
11
+ import { I as Icon } from './Icon-15799695.js';
12
12
 
13
13
  function toInteger(dirtyNumber) {
14
14
  if (dirtyNumber === null || dirtyNumber === true || dirtyNumber === false) {
@@ -2,7 +2,7 @@ import { _ as __rest, a as __assign, f as filterDataAttrs } from './filter-data-
2
2
  import { c as classNames } from './index-2e73c2e9.js';
3
3
  import React__default, { useState, useEffect, useContext } from 'react';
4
4
  import { B as BtIconChevronRightMid } from './BtIconChevronRightMid.esm-32268f1a.js';
5
- import { I as Icon } from './Icon-abd0d990.js';
5
+ import { I as Icon } from './Icon-15799695.js';
6
6
  import { I as Image } from './Image-12fbd327.js';
7
7
  import { H as Heading } from './Heading-d16e0e53.js';
8
8
  import { s as suffixModifier } from './suffix-modifier-3d548e45.js';
@@ -1,8 +1,8 @@
1
1
  import React__default from 'react';
2
2
  import { c as classNames } from './index-2e73c2e9.js';
3
- import { B as BtIconArrowRight } from './CardLabel-d6d71407.js';
3
+ import { B as BtIconArrowRight } from './BtIconArrowRight.esm-9b181878.js';
4
4
  import { B as BtIconArrowRightFill } from './BtIconArrowRightFill.esm-99019d1a.js';
5
- import { I as Icon } from './Icon-abd0d990.js';
5
+ import { I as Icon } from './Icon-15799695.js';
6
6
 
7
7
  const BtIconPlay = (props) =>
8
8
  /*#__PURE__*/ React__default.createElement(
@@ -3,7 +3,7 @@ import React__default, { forwardRef, useContext } from 'react';
3
3
  import { B as BtIconTickAlt2Px } from './BtIconTickAlt2Px.esm-0bc2ded0.js';
4
4
  import { B as BtIconAlert } from './BtIconAlert.esm-a4608d47.js';
5
5
  import { c as classNames } from './index-2e73c2e9.js';
6
- import { C as Context, u as useAriaDescribedby } from './FormControl-f0b8fe91.js';
6
+ import { C as Context, u as useAriaDescribedby } from './FormControl-cc99cde0.js';
7
7
  import { C as Context$1 } from './Surface-0ca6817d.js';
8
8
 
9
9
  /**
@@ -0,0 +1,8 @@
1
+ import React__default from 'react';
2
+
3
+ var ConditionalWrapper = function (_a) {
4
+ var condition = _a.condition, wrapper = _a.wrapper, fallback = _a.fallback, children = _a.children;
5
+ return (React__default.createElement(React__default.Fragment, null, condition ? wrapper(children) : fallback ? fallback(children) : children));
6
+ };
7
+
8
+ export { ConditionalWrapper as C };
@@ -74,11 +74,16 @@ var FormControl = function (_a) {
74
74
  "arc-FormControl--smallLabel": labelSize === "s",
75
75
  "arc-FormControl--onDarkSurface": surface === "dark"
76
76
  }), id: id }, elementProps, filterDataAttrs(props)),
77
- React__default.createElement(LabelType, __assign({ className: "arc-FormControl-label" }, labelProps), hideLabel === true ? (React__default.createElement(VisuallyHidden, null,
77
+ hideLabel === true ? (React__default.createElement(VisuallyHidden, null,
78
+ React__default.createElement(LabelType, __assign({ className: classNames("arc-FormControl-label", {
79
+ "arc-FormControl-label--withHelperUnderLabel": helperUnderLabel && helper
80
+ }) }, labelProps),
81
+ label,
82
+ requirementStatus === "optional" && (React__default.createElement("span", { className: "arc-FormControl-labelOptional" }, "(optional)"))))) : (React__default.createElement(LabelType, __assign({ className: classNames("arc-FormControl-label", {
83
+ "arc-FormControl-label--withHelperUnderLabel": helperUnderLabel && helper
84
+ }) }, labelProps),
78
85
  label,
79
- requirementStatus === "optional" && (React__default.createElement("span", { className: "arc-FormControl-labelOptional" }, "(optional)")))) : (React__default.createElement(React__default.Fragment, null,
80
- label,
81
- requirementStatus === "optional" && (React__default.createElement("span", { className: "arc-FormControl-labelOptional" }, "(optional)"))))),
86
+ requirementStatus === "optional" && (React__default.createElement("span", { className: "arc-FormControl-labelOptional" }, "(optional)")))),
82
87
  helperUnderLabel && (React__default.createElement(React__default.Fragment, null, helper && (React__default.createElement("div", { className: "arc-FormControl-helper arc-FormControl-helper--underLabel", id: idHelper }, helper)))),
83
88
  children,
84
89
  React__default.createElement("div", { className: classNames("arc-FormControl-info", {
@@ -26,9 +26,13 @@ const ArcIconArc = (props) =>
26
26
  */
27
27
  var Icon = function (_a) {
28
28
  var _b;
29
- var testId = _a.testId, _c = _a.color, color = _c === void 0 ? "auto" : _c, _d = _a.icon, icon = _d === void 0 ? ArcIconArc : _d, _e = _a.isInline, isInline = _e === void 0 ? false : _e, label = _a.label, size = _a.size, props = __rest(_a, ["testId", "color", "icon", "isInline", "label", "size"]);
29
+ var testId = _a.testId, _c = _a.color, color = _c === void 0 ? "auto" : _c, _d = _a.icon, icon = _d === void 0 ? ArcIconArc : _d, _e = _a.isInline, isInline = _e === void 0 ? false : _e, _f = _a.isPresentationIcon, isPresentationIcon = _f === void 0 ? false : _f, label = _a.label, size = _a.size, props = __rest(_a, ["testId", "color", "icon", "isInline", "isPresentationIcon", "label", "size"]);
30
30
  var surface = useContext(Context).surface;
31
31
  var Icon = icon;
32
+ var presentationIconProps = {
33
+ role: "presentation",
34
+ "aria-hidden": true
35
+ };
32
36
  return (React__default.createElement("span", __assign({ "data-testid": testId, "aria-label": label, className: classNames((_b = {},
33
37
  _b["arc-Icon"] = true,
34
38
  _b[suffixModifier("arc-Icon--color", color)] = color !== "auto",
@@ -38,7 +42,7 @@ var Icon = function (_a) {
38
42
  height: size,
39
43
  width: size
40
44
  } }, filterDataAttrs(props)),
41
- React__default.createElement(Icon, null)));
45
+ React__default.createElement(Icon, __assign({}, (isPresentationIcon ? presentationIconProps : {})))));
42
46
  };
43
47
 
44
48
  export { Icon as I };
@@ -2,7 +2,7 @@ import { _ as __rest, a as __assign, f as filterDataAttrs } from './filter-data-
2
2
  import React__default, { useContext } from 'react';
3
3
  import { c as classNames } from './index-2e73c2e9.js';
4
4
  import { B as BtIconAlert } from './BtIconAlert.esm-a4608d47.js';
5
- import { I as Icon } from './Icon-abd0d990.js';
5
+ import { I as Icon } from './Icon-15799695.js';
6
6
  import { C as Context } from './Surface-0ca6817d.js';
7
7
  import { V as VerticalSpace } from './VerticalSpace-43cd9138.js';
8
8
  import { V as VisuallyHidden } from './VisuallyHidden-b9eebf71.js';
@@ -1,6 +1,6 @@
1
1
  import { _ as __rest, a as __assign, f as filterDataAttrs } from './filter-data-attrs-ea8f4ed4.js';
2
2
  import React__default, { createContext, useContext, forwardRef, useEffect } from 'react';
3
- import { F as FormControl } from './FormControl-f0b8fe91.js';
3
+ import { F as FormControl } from './FormControl-cc99cde0.js';
4
4
  import { c as classNames } from './index-2e73c2e9.js';
5
5
  import { C as Context } from './Surface-0ca6817d.js';
6
6
 
@@ -15,8 +15,8 @@ var useRadioContext = function () {
15
15
  * Radio Button component.
16
16
  */
17
17
  var RadioButton = forwardRef(function (_a, ref) {
18
- var helper = _a.helper, id = _a.id, isDisabled = _a.isDisabled, label = _a.label, value = _a.value, props = __rest(_a, ["helper", "id", "isDisabled", "label", "value"]);
19
- var _b = useRadioContext(), blurEvent = _b.blurEvent, changeEvent = _b.changeEvent, groupDisabled = _b.groupDisabled, checkedValue = _b.checkedValue, labelSize = _b.labelSize, name = _b.name, size = _b.size;
18
+ var helper = _a.helper, id = _a.id, isDisabled = _a.isDisabled, label = _a.label, _b = _a.radioButtonAlignment, radioButtonAlignment = _b === void 0 ? "center" : _b, value = _a.value, props = __rest(_a, ["helper", "id", "isDisabled", "label", "radioButtonAlignment", "value"]);
19
+ var _c = useRadioContext(), blurEvent = _c.blurEvent, changeEvent = _c.changeEvent, groupDisabled = _c.groupDisabled, checkedValue = _c.checkedValue, labelSize = _c.labelSize, name = _c.name, size = _c.size;
20
20
  var surface = useContext(Context).surface;
21
21
  var idLabel = "".concat(id, "-label");
22
22
  var checked = checkedValue === value ? true : false;
@@ -27,9 +27,13 @@ var RadioButton = forwardRef(function (_a, ref) {
27
27
  "arc-RadioButton--smallLabel": labelSize === "s",
28
28
  "arc-RadioButton--onDarkSurface": surface === "dark"
29
29
  }) }, filterDataAttrs(props)),
30
- React__default.createElement("label", { className: "arc-RadioButton-label", htmlFor: id, id: idLabel },
30
+ React__default.createElement("label", { className: classNames("arc-RadioButton-label", {
31
+ "arc-RadioButton-label--alignTop": radioButtonAlignment === "top"
32
+ }), htmlFor: id, id: idLabel },
31
33
  React__default.createElement("input", { className: "arc-RadioButton-input", checked: typeof changeEvent !== "function" ? undefined : checked, defaultChecked: typeof changeEvent !== "function" ? checked : undefined, disabled: isDisabled || groupDisabled, id: id, name: name, onBlur: blurEvent, onChange: changeEvent, ref: ref, type: "radio", value: value }),
32
- React__default.createElement("span", null,
34
+ React__default.createElement("span", { className: classNames({
35
+ "arc-RadioButton-label--marginTop": radioButtonAlignment === "top"
36
+ }) },
33
37
  label,
34
38
  helper && React__default.createElement("span", { className: "arc-RadioButton-helper" }, helper)))));
35
39
  });
@@ -56,7 +60,8 @@ var RadioGroup = function (_a) {
56
60
  size: size
57
61
  } },
58
62
  React__default.createElement("div", __assign({ className: "arc-RadioGroup" }, filterDataAttrs(props)),
59
- React__default.createElement(FormControl, { elementType: "fieldset", label: label, labelSize: labelSize, helper: helper, id: id, requirementStatus: "not-applicable", helperUnderLabel: true }, children))));
63
+ React__default.createElement(FormControl, { elementType: "fieldset", label: label, labelSize: labelSize, helper: helper, id: id, requirementStatus: "not-applicable", helperUnderLabel: true },
64
+ React__default.createElement("span", { className: "arc-RadioGroup-radioButtonContainer" }, children)))));
60
65
  };
61
66
  RadioGroup.RadioButton = RadioButton;
62
67
 
@@ -7,7 +7,7 @@ import { h as handleLinkClick } from './handle-link-click-f64f55a2.js';
7
7
  import { a as BtIconChevronRight2Px, B as BtIconChevronLeft2Px } from './BtIconChevronRight2Px.esm-75e92636.js';
8
8
  import { S as Surface } from './Surface-0ca6817d.js';
9
9
  import { B as BrandLogo } from './BrandLogo-1af78f76.js';
10
- import { B as Button } from './Button-a453e8e4.js';
10
+ import { B as Button } from './Button-3f294e64.js';
11
11
  import { s as suffixModifier } from './suffix-modifier-3d548e45.js';
12
12
  import { T as Text } from './Text-14f586ac.js';
13
13
 
@@ -580,7 +580,7 @@ var SiteHeader = function (_a) {
580
580
  React__default.createElement("a", { className: "arc-SiteHeader-brand", onClick: handleLinkClick({
581
581
  handler: logoOnClick
582
582
  }), href: logoHref },
583
- React__default.createElement(BrandLogo, { label: logoLabel, subBrand: subBrand, size: 40 })),
583
+ React__default.createElement(BrandLogo, { label: logoLabel, subBrand: subBrand })),
584
584
  children && (React__default.createElement("nav", { className: "arc-SiteHeader-nav" },
585
585
  React__default.createElement("div", { className: "arc-SiteHeader-menuButton" },
586
586
  React__default.createElement(MenuButton, { menuOpen: menuOpen, setMenuOpen: setMenuOpen })),
@@ -7,10 +7,10 @@ import { S as Surface } from './Surface-0ca6817d.js';
7
7
  import { h as handleLinkClick } from './handle-link-click-f64f55a2.js';
8
8
  import { B as BtIconChevronRightMid } from './BtIconChevronRightMid.esm-32268f1a.js';
9
9
  import { B as BtIconChevronLeft2Px, a as BtIconChevronRight2Px } from './BtIconChevronRight2Px.esm-75e92636.js';
10
- import { B as Button } from './Button-a453e8e4.js';
10
+ import { B as Button } from './Button-3f294e64.js';
11
11
  import { s as suffixModifier } from './suffix-modifier-3d548e45.js';
12
12
  import { T as Text } from './Text-14f586ac.js';
13
- import { I as Icon } from './Icon-abd0d990.js';
13
+ import { I as Icon } from './Icon-15799695.js';
14
14
 
15
15
  var Item = function (_a) {
16
16
  var _b;
@@ -20,9 +20,9 @@ var Item = function (_a) {
20
20
  _b["arc-SiteHeaderV2Item--emphasised"] = true,
21
21
  _b)) }, filterDataAttrs(props)),
22
22
  React__default.createElement("a", { onClick: handleLinkClick({ handler: onClick }), className: "arc-SiteHeaderV2Item-link", href: href },
23
+ children,
23
24
  React__default.createElement("span", { className: "arc-SiteHeaderV2Item-linkIcon" },
24
- React__default.createElement(BtIconChevronRightMid, null)),
25
- children)));
25
+ React__default.createElement(BtIconChevronRightMid, null)))));
26
26
  };
27
27
 
28
28
  var ItemGroup = function (_a) {
@@ -124,6 +124,7 @@ var Panel = function (_a) {
124
124
  }
125
125
  // Close the panel.
126
126
  setOpen(false);
127
+ setOpenPanelOnFirstClick(false);
127
128
  };
128
129
  document.addEventListener("click", handleClick);
129
130
  return function () {
@@ -301,32 +302,15 @@ var HorizontalPanel = function (_a) {
301
302
  // Where appropriate, close the Panel when clicking outside of it,
302
303
  // by listening to clicks on the entire document and acting accordingly.
303
304
  var handleClick = function (e) {
304
- var _a, _b;
305
- // Don't close the Panel…
305
+ var _a;
306
+ // Close the Horizontal Panel…
306
307
  if (
307
- // The click is inside the current SubNavItem.
308
- ((_a = subNavItemRef === null || subNavItemRef === void 0 ? void 0 : subNavItemRef.current) === null || _a === void 0 ? void 0 : _a.contains(e.target)) ||
309
- // The click is inside the current NavItem
310
- // and the Panel is not inside a SubNavItem.
311
- // and the target is not a link
312
- (((_b = navItemRef === null || navItemRef === void 0 ? void 0 : navItemRef.current) === null || _b === void 0 ? void 0 : _b.contains(e.target)) &&
313
- !subNavItemRef &&
314
- !e.target.getAttribute("href")) ||
315
- // The Panel is inside a SubNavItem
316
- // and the click is not on a SubNavItem-link.
317
- // This ensures that one SubNavItem Panel per NavItem always remains open.
318
- (subNavItemRef &&
319
- !e.target.classList.contains(subNavLink) &&
320
- !e.target.classList.contains("".concat(subNavLink, "Title")) &&
321
- !e.target.classList.contains("".concat(subNavLink, "SubTitle"))) ||
322
- // Panel is inside a SubNavItem
323
- // and the click is not inside the Panel's NavItem parent.
324
- // This prevents SubNavItem Panels in sibling NavItems from being closed.
325
- (subNavItemRef && !(navItemRef === null || navItemRef === void 0 ? void 0 : navItemRef.current.contains(e.target)))) {
308
+ // The click is not inside the current NavItem
309
+ !((_a = navItemRef === null || navItemRef === void 0 ? void 0 : navItemRef.current) === null || _a === void 0 ? void 0 : _a.contains(e.target)) ||
310
+ e.target.classList.contains("arc-SiteHeaderV2HorizontalPanel--open")) {
311
+ setOpen(false);
326
312
  return;
327
313
  }
328
- // Close the panel.
329
- setOpen(false);
330
314
  };
331
315
  document.addEventListener("click", handleClick);
332
316
  return function () {
@@ -6,7 +6,7 @@ import { $ as $e02a7d9cb1dc128c$export$c74125a8e3af6bb2 } from './index-044da8d0
6
6
  import { $ as $1746a345f3d73bb7$export$f680877a34711e37 } from './index-efa9be1a.js';
7
7
  import { $ as $f631663db3294ace$export$b39126d51d94e6f3 } from './index-a624de47.js';
8
8
  import { $ as $921a889cee6df7e8$export$99c2b779aa4e8b8b } from './index-ca72c9d5.js';
9
- import { I as Icon } from './Icon-abd0d990.js';
9
+ import { I as Icon } from './Icon-15799695.js';
10
10
  import { C as Context } from './Surface-0ca6817d.js';
11
11
  import { c as classNames } from './index-2e73c2e9.js';
12
12
  import { B as BtIconArrowRightFill } from './BtIconArrowRightFill.esm-99019d1a.js';
@@ -2,7 +2,7 @@ import { _ as __rest, a as __assign, f as filterDataAttrs } from './filter-data-
2
2
  import React__default, { useContext, useState } from 'react';
3
3
  import { c as classNames } from './index-2e73c2e9.js';
4
4
  import { C as Context } from './Surface-0ca6817d.js';
5
- import { I as Icon } from './Icon-abd0d990.js';
5
+ import { I as Icon } from './Icon-15799695.js';
6
6
 
7
7
  const BtIconCross = (props) =>
8
8
  /*#__PURE__*/ React__default.createElement(
@@ -1,10 +1,10 @@
1
1
  import { _ as __rest, a as __assign, f as filterDataAttrs } from './filter-data-attrs-ea8f4ed4.js';
2
2
  import { c as classNames } from './index-2e73c2e9.js';
3
3
  import React__default, { forwardRef, useContext, useState } from 'react';
4
- import { u as useAriaDescribedby, F as FormControl } from './FormControl-f0b8fe91.js';
4
+ import { u as useAriaDescribedby, F as FormControl } from './FormControl-cc99cde0.js';
5
5
  import { C as Context } from './Surface-0ca6817d.js';
6
6
  import { V as VisuallyHidden } from './VisuallyHidden-b9eebf71.js';
7
- import { I as Icon } from './Icon-abd0d990.js';
7
+ import { I as Icon } from './Icon-15799695.js';
8
8
 
9
9
  /**
10
10
  * Infer the correct inputMode, pattern and type if specifying a `number` type.
@@ -36,7 +36,7 @@ var useNumericInput = function (props) {
36
36
  /**
37
37
  * Use `TextInput` to allow custom user text entry with a keyboard.
38
38
  */
39
- var TextInput = forwardRef(function (_a, ref) {
39
+ var TextInputComponent = forwardRef(function (_a, ref) {
40
40
  var _b;
41
41
  var _c = _a.defaultValue, defaultValue = _c === void 0 ? "" : _c, errorMessage = _a.errorMessage, helper = _a.helper, hideLabel = _a.hideLabel, id = _a.id, inputMode = _a.inputMode, _d = _a.isDisabled, isDisabled = _d === void 0 ? false : _d, _e = _a.isReadOnly, isReadOnly = _e === void 0 ? false : _e, _f = _a.isRequired, isRequired = _f === void 0 ? false : _f, label = _a.label, _g = _a.labelSize, labelSize = _g === void 0 ? "l" : _g, maxLength = _a.maxLength, minLength = _a.minLength, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, placeholder = _a.placeholder, onClickDisclosure = _a.onClickDisclosure, pattern = _a.pattern, _h = _a.type, type = _h === void 0 ? "text" : _h, _j = _a.showPassword, showPassword = _j === void 0 ? false : _j, value = _a.value, disclosureTitle = _a.disclosureTitle, disclosureText = _a.disclosureText, _k = _a.inputSize, inputSize = _k === void 0 ? "m" : _k, iconButton = _a.iconButton, prefix = _a.prefix, suffix = _a.suffix, _l = _a.inputAlignment, inputAlignment = _l === void 0 ? "left" : _l, width = _a.width, props = __rest(_a, ["defaultValue", "errorMessage", "helper", "hideLabel", "id", "inputMode", "isDisabled", "isReadOnly", "isRequired", "label", "labelSize", "maxLength", "minLength", "name", "onBlur", "onChange", "placeholder", "onClickDisclosure", "pattern", "type", "showPassword", "value", "disclosureTitle", "disclosureText", "inputSize", "iconButton", "prefix", "suffix", "inputAlignment", "width"]);
42
42
  var surface = useContext(Context).surface;
@@ -90,5 +90,7 @@ var TextInput = forwardRef(function (_a, ref) {
90
90
  ? "Your password is shown"
91
91
  : "Your password is hidden")))))))));
92
92
  });
93
+ var TextInput = forwardRef(function (props, ref) { return React__default.createElement(TextInputComponent, __assign({ ref: ref }, props)); });
94
+ var TextInputWithPlaceHolder = forwardRef(function (props, ref) { return React__default.createElement(TextInputComponent, __assign({ ref: ref }, props)); });
93
95
 
94
- export { TextInput as T };
96
+ export { TextInputWithPlaceHolder as T, TextInput as a };
@@ -11,7 +11,7 @@ import { c as classNames } from './index-2e73c2e9.js';
11
11
  import { B as BtIconCrossAlt2Px } from './BtIconCrossAlt2Px.esm-7165ab1a.js';
12
12
  import { B as BtIconNotification, a as BtIconAlertTriangle, b as BtIconTick } from './BtIconTick.esm-e265098f.js';
13
13
  import { B as BtIconAlert } from './BtIconAlert.esm-a4608d47.js';
14
- import { I as Icon } from './Icon-abd0d990.js';
14
+ import { I as Icon } from './Icon-15799695.js';
15
15
 
16
16
  const $5cb92bef7577960e$var$CONTEXT_UPDATE = 'dismissableLayer.update';
17
17
  const $5cb92bef7577960e$var$POINTER_DOWN_OUTSIDE = 'dismissableLayer.pointerDownOutside';