@aarhus-university/au-lib-react-components 11.5.1 → 11.6.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 (100) hide show
  1. package/.eslintrc.js +34 -34
  2. package/.storybook/main.js +20 -20
  3. package/.storybook/preview.js +17 -17
  4. package/README.md +19 -19
  5. package/__tests__/jest/AUButtonComponent.test.tsx +165 -165
  6. package/__tests__/jest/AUErrorComponent.test.tsx +142 -142
  7. package/__tests__/jest/AUModalComponent.test.tsx +186 -186
  8. package/__tests__/jest/AUNotificationComponent.test.tsx +115 -115
  9. package/__tests__/jest/AUSpinnerComponent.test.tsx +57 -57
  10. package/__tests__/jest/AUToolbarComponent.test.tsx +46 -46
  11. package/__tests__/jest/context.test.ts +25 -25
  12. package/__tests__/jest/helpers.test.ts +15 -15
  13. package/__tests__/jest/setupTests.ts +2 -2
  14. package/babel.config.js +8 -8
  15. package/build/umd/all.css +2 -2
  16. package/build/umd/all.js +1 -1
  17. package/build/umd/alphabox.js +1 -1
  18. package/build/umd/databox.js +1 -1
  19. package/build/umd/diagramme.js +1 -1
  20. package/build/umd/flowbox.js +1 -1
  21. package/build/umd/universe.js +1 -1
  22. package/build-storybook.log +367 -367
  23. package/package.json +114 -114
  24. package/src/components/AUAlertComponent.tsx +113 -113
  25. package/src/components/AUAutoSuggestComponent.js +158 -158
  26. package/src/components/AUButtonComponent.tsx +87 -87
  27. package/src/components/AUCalendarComponent.tsx +493 -493
  28. package/src/components/AUContentToggleComponent.tsx +47 -47
  29. package/src/components/AUDatepickerComponent.tsx +121 -121
  30. package/src/components/AUEditFilterComponent.tsx +24 -67
  31. package/src/components/AUErrorComponent.tsx +78 -78
  32. package/src/components/AUMobilePrefixComponent.tsx +15 -15
  33. package/src/components/AUModalComponent.tsx +68 -68
  34. package/src/components/AUNotificationComponent.tsx +43 -43
  35. package/src/components/AUReceiptComponent.tsx +33 -33
  36. package/src/components/AUSpinnerComponent.tsx +36 -36
  37. package/src/components/AUStepComponent.tsx +47 -47
  38. package/src/components/AUSubNavComponent.tsx +48 -48
  39. package/src/components/AUSubmitButtonContainerComponent.tsx +29 -29
  40. package/src/components/AUTabbedContentComponent.tsx +145 -145
  41. package/src/components/AUTableComponent.tsx +24 -24
  42. package/src/components/AUToastComponent.tsx +104 -104
  43. package/src/components/AUToolbarComponent.tsx +101 -106
  44. package/src/components/AUTruncatorComponent.tsx +124 -124
  45. package/src/components/wrapping/AUEmbedComponent.js +47 -47
  46. package/src/layout-2016/components/alphabox/AlphaBoxComponent.js +143 -143
  47. package/src/layout-2016/components/alphabox/AlphaBoxContentComponent.js +136 -136
  48. package/src/layout-2016/components/common/AUCollapsibleComponent.js +152 -152
  49. package/src/layout-2016/components/common/AUSpinnerComponent.js +103 -103
  50. package/src/layout-2016/components/databox/DataBoxAlphabetComponent.js +144 -144
  51. package/src/layout-2016/components/databox/DataBoxAssociationComponent.js +122 -122
  52. package/src/layout-2016/components/databox/DataBoxButtonComponent.js +157 -157
  53. package/src/layout-2016/components/databox/DataBoxComponent.js +297 -297
  54. package/src/layout-2016/components/databox/DataBoxGroupingComponent.js +64 -64
  55. package/src/layout-2016/components/databox/DataBoxSearchResultComponent.js +36 -36
  56. package/src/layout-2016/components/databox/DataBoxStackedAssociationComponent.js +54 -54
  57. package/src/layout-2016/components/databox/DataBoxSuggestionComponent.js +39 -39
  58. package/src/layout-2016/components/diagramme/AUDiagrammeComponent.js +309 -309
  59. package/src/layout-2016/components/flowbox/FlowBoxComponent.js +126 -126
  60. package/src/layout-2016/components/flowbox/FlowBoxPhoneComponent.js +104 -104
  61. package/src/layout-2016/components/profile/AUProfileAvatar2016Component.js +103 -103
  62. package/src/layout-2016/components/universe/StaffTopComponent.js +363 -363
  63. package/src/layout-2016/components/universe/StudentTopComponent.js +137 -137
  64. package/src/layout-2016/components/universe/UniverseContainerComponent.js +65 -65
  65. package/src/layout-2016/lib/all.js +3 -3
  66. package/src/layout-2016/lib/au-alphabox.js +100 -100
  67. package/src/layout-2016/lib/au-databox.js +400 -400
  68. package/src/layout-2016/lib/au-diagramme.js +85 -85
  69. package/src/layout-2016/lib/au-flowbox.js +93 -93
  70. package/src/layout-2016/lib/universe.js +9 -9
  71. package/src/lib/context.tsx +51 -51
  72. package/src/lib/dates.ts +50 -50
  73. package/src/lib/helpers.ts +208 -208
  74. package/src/lib/hooks.ts +75 -75
  75. package/src/lib/i18n.ts +600 -600
  76. package/src/lib/portals.tsx +145 -119
  77. package/src/lib/tracking.ts +69 -69
  78. package/src/lib/wrapping.ts +21 -21
  79. package/src/styles/_settings.scss +10 -10
  80. package/src/styles/alphabox.scss +222 -222
  81. package/src/styles/app.scss +7 -7
  82. package/src/styles/autosuggest.scss +57 -57
  83. package/src/styles/databox.scss +563 -563
  84. package/src/styles/diagramme.scss +119 -119
  85. package/src/styles/flowbox.scss +72 -72
  86. package/src/styles/maps.scss +395 -395
  87. package/stories/AUAlertComponent.stories.tsx +120 -120
  88. package/stories/AUButtonComponent.stories.tsx +127 -127
  89. package/stories/AUContentToggleComponent.stories.tsx +63 -63
  90. package/stories/AUEditFilterComponent.stories.tsx +29 -29
  91. package/stories/AUErrorComponent.stories.tsx +98 -98
  92. package/stories/AUModalComponent.stories.tsx +84 -84
  93. package/stories/AUNotificationComponent.stories.tsx +116 -116
  94. package/stories/AUSpinnerComponent.stories.tsx +41 -41
  95. package/stories/AUStepComponent.stories.tsx +40 -40
  96. package/stories/AUToolbarComponent.stories.tsx +326 -327
  97. package/stories/AUTruncatorComponent.stories.tsx +101 -101
  98. package/stories/lib/helpers.tsx +128 -128
  99. package/tsconfig.json +46 -46
  100. package/webpack.config.js +89 -89
package/package.json CHANGED
@@ -1,114 +1,114 @@
1
- {
2
- "sideEffects": false,
3
- "name": "@aarhus-university/au-lib-react-components",
4
- "version": "11.5.1",
5
- "description": "Library for shared React components for various applications on au.dk",
6
- "scripts": {
7
- "test": "jest",
8
- "build": "jest && webpack --config ./webpack.config.js",
9
- "storybook": "start-storybook -p 6006 -h 127.0.0.1",
10
- "build-storybook": "build-storybook",
11
- "chromatic": "npx chromatic --project-token=6e78be9148c0"
12
- },
13
- "repository": {
14
- "type": "git",
15
- "url": "https://gitlab.au.dk/au-web-og-digital/au-lib-react-components"
16
- },
17
- "author": {
18
- "name": "Thomas Riis Hansen",
19
- "email": "trh@au.dk"
20
- },
21
- "devDependencies": {
22
- "@babel/core": "^7.17.0",
23
- "@babel/plugin-proposal-class-properties": "^7.16.7",
24
- "@babel/plugin-proposal-object-rest-spread": "^7.16.7",
25
- "@babel/plugin-proposal-optional-chaining": "^7.16.7",
26
- "@babel/preset-env": "^7.16.11",
27
- "@babel/preset-react": "^7.16.7",
28
- "@babel/preset-typescript": "^7.16.7",
29
- "@mdx-js/react": "^2.1.2",
30
- "@storybook/addon-a11y": "^6.5.9",
31
- "@storybook/addon-actions": "^6.5.4",
32
- "@storybook/addon-essentials": "^6.5.4",
33
- "@storybook/addon-interactions": "^6.5.4",
34
- "@storybook/addon-links": "^6.5.4",
35
- "@storybook/builder-webpack4": "^6.5.4",
36
- "@storybook/builder-webpack5": "^6.5.4",
37
- "@storybook/jest": "^0.0.10",
38
- "@storybook/manager-webpack4": "^6.5.4",
39
- "@storybook/manager-webpack5": "^6.5.4",
40
- "@storybook/react": "^6.5.4",
41
- "@storybook/testing-library": "^0.0.11",
42
- "@testing-library/jest-dom": "5.0.0",
43
- "@testing-library/react": "13.0.0",
44
- "@testing-library/user-event": "14.0.0",
45
- "@types/jest": "^27.4.0",
46
- "@types/testing-library__jest-dom": "5.0.0",
47
- "@typescript-eslint/eslint-plugin": "^5.10.2",
48
- "@typescript-eslint/parser": "^5.10.2",
49
- "babel-eslint": "^10.1.0",
50
- "babel-jest": "^27.5.1",
51
- "babel-loader": "^8.2.3",
52
- "chromatic": "^6.7.2",
53
- "css-loader": "^6.6.0",
54
- "eslint": "^8.8.0",
55
- "eslint-config-airbnb": "^19.0.4",
56
- "eslint-import-resolver-typescript": "^2.5.0",
57
- "eslint-plugin-import": "^2.25.4",
58
- "eslint-plugin-jsx-a11y": "^6.5.1",
59
- "eslint-plugin-react": "^7.28.0",
60
- "eslint-plugin-react-hooks": "^4.3.0",
61
- "eslint-plugin-storybook": "^0.5.12",
62
- "eslint-webpack-plugin": "^3.1.1",
63
- "fork-ts-checker-webpack-plugin": "^7.0.0",
64
- "jest": "^27.5.1",
65
- "mini-css-extract-plugin": "^2.5.3",
66
- "react-test-renderer": "18.1.0",
67
- "sass": "^1.49.7",
68
- "sass-loader": "^12.4.0",
69
- "style-loader": "^3.3.1",
70
- "ts-loader": "^9.2.6",
71
- "typescript": "^4.5.5",
72
- "webpack-cli": "^4.9.2"
73
- },
74
- "dependencies": {
75
- "@aarhus-university/au-designsystem-delphinus": "0.39.3",
76
- "@aarhus-university/au-designsystem-delphinus-dev": "0.2.0",
77
- "@aarhus-university/types": "0.20.0",
78
- "@reduxjs/toolkit": "^1.8.3",
79
- "@types/google.analytics": "^0.0.42",
80
- "@types/history": "^5.0.0",
81
- "@types/react": "^18.0.14",
82
- "@types/react-dom": "^18.0.5",
83
- "@types/react-router-dom": "^5.3.3",
84
- "dayjs": "^1.11.3",
85
- "lodash.debounce": "^4.0.8",
86
- "prop-types": "^15.8.1",
87
- "query-string": "^7.1.0",
88
- "react": "18.2.0",
89
- "react-autosuggest": "^10.1.0",
90
- "react-router-dom": "^6.2.1",
91
- "regenerator-runtime": "^0.13.9",
92
- "webpack": "^5.68.0",
93
- "whatwg-fetch": "^3.6.2"
94
- },
95
- "peerDependencies": {
96
- "react": "18.2.0",
97
- "react-dom": "18.2.0"
98
- },
99
- "jest": {
100
- "rootDir": "__tests__/jest",
101
- "setupFilesAfterEnv": [
102
- "./setupTests.ts"
103
- ],
104
- "testEnvironment": "jsdom",
105
- "transformIgnorePatterns": [
106
- "node_modules/(?!(@aarhus-university/au-lib-react-components|@aarhus-university/au-designsystem-delphinus|node-fetch|data-uri-to-buffer|fetch-blob|formdata-polyfill)/)"
107
- ],
108
- "testPathIgnorePatterns": [
109
- "factory.ts",
110
- "setupTests.ts"
111
- ]
112
- },
113
- "readme": "ERROR: No README data found!"
114
- }
1
+ {
2
+ "sideEffects": false,
3
+ "name": "@aarhus-university/au-lib-react-components",
4
+ "version": "11.6.0",
5
+ "description": "Library for shared React components for various applications on au.dk",
6
+ "scripts": {
7
+ "test": "jest",
8
+ "build": "jest && webpack --config ./webpack.config.js",
9
+ "storybook": "start-storybook -p 6006 -h 127.0.0.1",
10
+ "build-storybook": "build-storybook",
11
+ "chromatic": "npx chromatic --project-token=6e78be9148c0"
12
+ },
13
+ "repository": {
14
+ "type": "git",
15
+ "url": "https://gitlab.au.dk/au-web-og-digital/au-lib-react-components"
16
+ },
17
+ "author": {
18
+ "name": "Thomas Riis Hansen",
19
+ "email": "trh@au.dk"
20
+ },
21
+ "devDependencies": {
22
+ "@babel/core": "^7.17.0",
23
+ "@babel/plugin-proposal-class-properties": "^7.16.7",
24
+ "@babel/plugin-proposal-object-rest-spread": "^7.16.7",
25
+ "@babel/plugin-proposal-optional-chaining": "^7.16.7",
26
+ "@babel/preset-env": "^7.16.11",
27
+ "@babel/preset-react": "^7.16.7",
28
+ "@babel/preset-typescript": "^7.16.7",
29
+ "@mdx-js/react": "^2.1.2",
30
+ "@storybook/addon-a11y": "^6.5.9",
31
+ "@storybook/addon-actions": "^6.5.4",
32
+ "@storybook/addon-essentials": "^6.5.4",
33
+ "@storybook/addon-interactions": "^6.5.4",
34
+ "@storybook/addon-links": "^6.5.4",
35
+ "@storybook/builder-webpack4": "^6.5.4",
36
+ "@storybook/builder-webpack5": "^6.5.4",
37
+ "@storybook/jest": "^0.0.10",
38
+ "@storybook/manager-webpack4": "^6.5.4",
39
+ "@storybook/manager-webpack5": "^6.5.4",
40
+ "@storybook/react": "^6.5.4",
41
+ "@storybook/testing-library": "^0.0.11",
42
+ "@testing-library/jest-dom": "5.0.0",
43
+ "@testing-library/react": "13.0.0",
44
+ "@testing-library/user-event": "14.0.0",
45
+ "@types/jest": "^27.4.0",
46
+ "@types/testing-library__jest-dom": "5.0.0",
47
+ "@typescript-eslint/eslint-plugin": "^5.10.2",
48
+ "@typescript-eslint/parser": "^5.10.2",
49
+ "babel-eslint": "^10.1.0",
50
+ "babel-jest": "^27.5.1",
51
+ "babel-loader": "^8.2.3",
52
+ "chromatic": "^6.7.2",
53
+ "css-loader": "^6.6.0",
54
+ "eslint": "^8.8.0",
55
+ "eslint-config-airbnb": "^19.0.4",
56
+ "eslint-import-resolver-typescript": "^2.5.0",
57
+ "eslint-plugin-import": "^2.25.4",
58
+ "eslint-plugin-jsx-a11y": "^6.5.1",
59
+ "eslint-plugin-react": "^7.28.0",
60
+ "eslint-plugin-react-hooks": "^4.3.0",
61
+ "eslint-plugin-storybook": "^0.5.12",
62
+ "eslint-webpack-plugin": "^3.1.1",
63
+ "fork-ts-checker-webpack-plugin": "^7.0.0",
64
+ "jest": "^27.5.1",
65
+ "mini-css-extract-plugin": "^2.5.3",
66
+ "react-test-renderer": "18.1.0",
67
+ "sass": "^1.49.7",
68
+ "sass-loader": "^12.4.0",
69
+ "style-loader": "^3.3.1",
70
+ "ts-loader": "^9.2.6",
71
+ "typescript": "^4.5.5",
72
+ "webpack-cli": "^4.9.2"
73
+ },
74
+ "dependencies": {
75
+ "@aarhus-university/au-designsystem-delphinus": "0.35.2",
76
+ "@aarhus-university/au-designsystem-delphinus-dev": "0.2.0",
77
+ "@aarhus-university/types": "0.18.0",
78
+ "@reduxjs/toolkit": "^1.8.3",
79
+ "@types/google.analytics": "^0.0.42",
80
+ "@types/history": "^5.0.0",
81
+ "@types/react": "^18.0.14",
82
+ "@types/react-dom": "^18.0.5",
83
+ "@types/react-router-dom": "^5.3.3",
84
+ "dayjs": "^1.11.3",
85
+ "lodash.debounce": "^4.0.8",
86
+ "prop-types": "^15.8.1",
87
+ "query-string": "^7.1.0",
88
+ "react": "18.2.0",
89
+ "react-autosuggest": "^10.1.0",
90
+ "react-router-dom": "^6.2.1",
91
+ "regenerator-runtime": "^0.13.9",
92
+ "webpack": "^5.68.0",
93
+ "whatwg-fetch": "^3.6.2"
94
+ },
95
+ "peerDependencies": {
96
+ "react": "18.2.0",
97
+ "react-dom": "18.2.0"
98
+ },
99
+ "jest": {
100
+ "rootDir": "__tests__/jest",
101
+ "setupFilesAfterEnv": [
102
+ "./setupTests.ts"
103
+ ],
104
+ "testEnvironment": "jsdom",
105
+ "transformIgnorePatterns": [
106
+ "node_modules/(?!(@aarhus-university/au-lib-react-components|@aarhus-university/au-designsystem-delphinus|node-fetch|data-uri-to-buffer|fetch-blob|formdata-polyfill)/)"
107
+ ],
108
+ "testPathIgnorePatterns": [
109
+ "factory.ts",
110
+ "setupTests.ts"
111
+ ]
112
+ },
113
+ "readme": "ERROR: No README data found!"
114
+ }
@@ -1,113 +1,113 @@
1
- /* eslint-disable max-len */
2
- /* eslint-disable @typescript-eslint/no-non-null-assertion */
3
- /* eslint-env browser */
4
- import React, {
5
- FC, useState, useRef, useEffect,
6
- } from 'react';
7
- import { hideModal } from '@aarhus-university/au-designsystem-delphinus/source/js/components/modal-view';
8
- import AUButtonComponent from './AUButtonComponent';
9
- import AUModalComponent from './AUModalComponent';
10
-
11
- const AUAlertComponent: FC<AUAlertComponentProps> = ({
12
- modalId,
13
- confirm,
14
- processing,
15
- done,
16
- header,
17
- message,
18
- okButtonText,
19
- cancelButtonText,
20
- label,
21
- size,
22
- type,
23
- icon,
24
- iconPosition,
25
- hideLabel,
26
- mode,
27
- classNames,
28
- dataGtm,
29
- asSubmit,
30
- onClick,
31
- }: AUAlertComponentProps) => {
32
- const [alert, setAlert] = useState<boolean>(false);
33
- const btnRef = useRef<HTMLButtonElement>(null);
34
- useEffect(() => {
35
- if (done) {
36
- hideModal(modalId, btnRef.current as HTMLButtonElement, () => setAlert(false));
37
- }
38
- }, [done]);
39
-
40
- let okBtnMode = mode;
41
- if (processing) {
42
- if (mode === 'confirmable-action') {
43
- okBtnMode = 'confirmable-action processing';
44
- } else if (mode === 'ireversable-action') {
45
- okBtnMode = 'ireversable-action processing';
46
- }
47
- }
48
-
49
- return (
50
- <>
51
- <AUModalComponent
52
- domId={modalId}
53
- show={alert}
54
- sender={btnRef.current}
55
- onClose={() => setAlert(false)}
56
- closeButtonDisabled={processing}
57
- >
58
- <>
59
- <h2 className="modal-view__header">{header}</h2>
60
- <div className="modal-view__content">
61
- <div className="content-container" dangerouslySetInnerHTML={{ __html: message }} />
62
- <div className="button-container vertical-spacing-top">
63
- <AUButtonComponent
64
- label={okButtonText}
65
- disabled={processing}
66
- mode={okBtnMode}
67
- onClick={(event) => {
68
- if (typeof onClick === 'function') {
69
- onClick(event, btnRef);
70
- }
71
- }}
72
- />
73
- {
74
- confirm && (
75
- <AUButtonComponent
76
- label={cancelButtonText}
77
- disabled={processing}
78
- type="text"
79
- onClick={() => {
80
- hideModal(modalId, btnRef.current as HTMLButtonElement, () => setAlert(false));
81
- }}
82
- />
83
- )
84
- }
85
- </div>
86
- </div>
87
- </>
88
- </AUModalComponent>
89
- <AUButtonComponent
90
- label={label}
91
- disabled={alert}
92
- size={size}
93
- type={type}
94
- icon={icon}
95
- iconPosition={iconPosition}
96
- hideLabel={hideLabel}
97
- mode={mode}
98
- btnRef={btnRef}
99
- classNames={classNames}
100
- ariaExpanded={alert}
101
- ariaHasPopup
102
- dataGtm={dataGtm}
103
- asSubmit={asSubmit}
104
- onClick={() => {
105
- setAlert(true);
106
- }}
107
- />
108
- </>
109
- );
110
- };
111
-
112
- AUAlertComponent.displayName = 'AUAlertComponent';
113
- export default AUAlertComponent;
1
+ /* eslint-disable max-len */
2
+ /* eslint-disable @typescript-eslint/no-non-null-assertion */
3
+ /* eslint-env browser */
4
+ import React, {
5
+ FC, useState, useRef, useEffect,
6
+ } from 'react';
7
+ import { hideModal } from '@aarhus-university/au-designsystem-delphinus/source/js/components/modal-view';
8
+ import AUButtonComponent from './AUButtonComponent';
9
+ import AUModalComponent from './AUModalComponent';
10
+
11
+ const AUAlertComponent: FC<AUAlertComponentProps> = ({
12
+ modalId,
13
+ confirm,
14
+ processing,
15
+ done,
16
+ header,
17
+ message,
18
+ okButtonText,
19
+ cancelButtonText,
20
+ label,
21
+ size,
22
+ type,
23
+ icon,
24
+ iconPosition,
25
+ hideLabel,
26
+ mode,
27
+ classNames,
28
+ dataGtm,
29
+ asSubmit,
30
+ onClick,
31
+ }: AUAlertComponentProps) => {
32
+ const [alert, setAlert] = useState<boolean>(false);
33
+ const btnRef = useRef<HTMLButtonElement>(null);
34
+ useEffect(() => {
35
+ if (done) {
36
+ hideModal(modalId, btnRef.current as HTMLButtonElement, () => setAlert(false));
37
+ }
38
+ }, [done]);
39
+
40
+ let okBtnMode = mode;
41
+ if (processing) {
42
+ if (mode === 'confirmable-action') {
43
+ okBtnMode = 'confirmable-action processing';
44
+ } else if (mode === 'ireversable-action') {
45
+ okBtnMode = 'ireversable-action processing';
46
+ }
47
+ }
48
+
49
+ return (
50
+ <>
51
+ <AUModalComponent
52
+ domId={modalId}
53
+ show={alert}
54
+ sender={btnRef.current}
55
+ onClose={() => setAlert(false)}
56
+ closeButtonDisabled={processing}
57
+ >
58
+ <>
59
+ <h2 className="modal-view__header">{header}</h2>
60
+ <div className="modal-view__content">
61
+ <div className="content-container" dangerouslySetInnerHTML={{ __html: message }} />
62
+ <div className="button-container vertical-spacing-top">
63
+ <AUButtonComponent
64
+ label={okButtonText}
65
+ disabled={processing}
66
+ mode={okBtnMode}
67
+ onClick={(event) => {
68
+ if (typeof onClick === 'function') {
69
+ onClick(event, btnRef);
70
+ }
71
+ }}
72
+ />
73
+ {
74
+ confirm && (
75
+ <AUButtonComponent
76
+ label={cancelButtonText}
77
+ disabled={processing}
78
+ type="text"
79
+ onClick={() => {
80
+ hideModal(modalId, btnRef.current as HTMLButtonElement, () => setAlert(false));
81
+ }}
82
+ />
83
+ )
84
+ }
85
+ </div>
86
+ </div>
87
+ </>
88
+ </AUModalComponent>
89
+ <AUButtonComponent
90
+ label={label}
91
+ disabled={alert}
92
+ size={size}
93
+ type={type}
94
+ icon={icon}
95
+ iconPosition={iconPosition}
96
+ hideLabel={hideLabel}
97
+ mode={mode}
98
+ btnRef={btnRef}
99
+ classNames={classNames}
100
+ ariaExpanded={alert}
101
+ ariaHasPopup
102
+ dataGtm={dataGtm}
103
+ asSubmit={asSubmit}
104
+ onClick={() => {
105
+ setAlert(true);
106
+ }}
107
+ />
108
+ </>
109
+ );
110
+ };
111
+
112
+ AUAlertComponent.displayName = 'AUAlertComponent';
113
+ export default AUAlertComponent;