@patternfly/react-core 6.6.1-prerelease.0 → 6.6.1-prerelease.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/components/package.json +1 -1
- package/deprecated/package.json +1 -1
- package/dist/dynamic/components/AboutModal/package.json +1 -1
- package/dist/dynamic/components/Accordion/package.json +1 -1
- package/dist/dynamic/components/ActionList/package.json +1 -1
- package/dist/dynamic/components/Alert/package.json +1 -1
- package/dist/dynamic/components/Avatar/package.json +1 -1
- package/dist/dynamic/components/BackToTop/package.json +1 -1
- package/dist/dynamic/components/Backdrop/package.json +1 -1
- package/dist/dynamic/components/BackgroundImage/package.json +1 -1
- package/dist/dynamic/components/Badge/package.json +1 -1
- package/dist/dynamic/components/Banner/package.json +1 -1
- package/dist/dynamic/components/Brand/package.json +1 -1
- package/dist/dynamic/components/Breadcrumb/package.json +1 -1
- package/dist/dynamic/components/Button/package.json +1 -1
- package/dist/dynamic/components/CalendarMonth/package.json +1 -1
- package/dist/dynamic/components/Card/package.json +1 -1
- package/dist/dynamic/components/Checkbox/package.json +1 -1
- package/dist/dynamic/components/ClipboardCopy/package.json +1 -1
- package/dist/dynamic/components/CodeBlock/package.json +1 -1
- package/dist/dynamic/components/Compass/package.json +1 -1
- package/dist/dynamic/components/Content/package.json +1 -1
- package/dist/dynamic/components/DataList/package.json +1 -1
- package/dist/dynamic/components/DatePicker/package.json +1 -1
- package/dist/dynamic/components/DescriptionList/package.json +1 -1
- package/dist/dynamic/components/Divider/package.json +1 -1
- package/dist/dynamic/components/Drawer/package.json +1 -1
- package/dist/dynamic/components/Dropdown/package.json +1 -1
- package/dist/dynamic/components/DualListSelector/package.json +1 -1
- package/dist/dynamic/components/EmptyState/package.json +1 -1
- package/dist/dynamic/components/ExpandableSection/package.json +1 -1
- package/dist/dynamic/components/FileUpload/package.json +1 -1
- package/dist/dynamic/components/Form/package.json +1 -1
- package/dist/dynamic/components/FormSelect/package.json +1 -1
- package/dist/dynamic/components/HelperText/package.json +1 -1
- package/dist/dynamic/components/Hero/package.json +1 -1
- package/dist/dynamic/components/Hint/package.json +1 -1
- package/dist/dynamic/components/Icon/package.json +1 -1
- package/dist/dynamic/components/InputGroup/package.json +1 -1
- package/dist/dynamic/components/JumpLinks/package.json +1 -1
- package/dist/dynamic/components/Label/package.json +1 -1
- package/dist/dynamic/components/List/package.json +1 -1
- package/dist/dynamic/components/LoginPage/package.json +1 -1
- package/dist/dynamic/components/Masthead/package.json +1 -1
- package/dist/dynamic/components/Menu/package.json +1 -1
- package/dist/dynamic/components/MenuToggle/package.json +1 -1
- package/dist/dynamic/components/Modal/package.json +1 -1
- package/dist/dynamic/components/MultipleFileUpload/package.json +1 -1
- package/dist/dynamic/components/Nav/package.json +1 -1
- package/dist/dynamic/components/NotificationBadge/package.json +1 -1
- package/dist/dynamic/components/NotificationDrawer/package.json +1 -1
- package/dist/dynamic/components/NumberInput/package.json +1 -1
- package/dist/dynamic/components/OverflowMenu/package.json +1 -1
- package/dist/dynamic/components/Page/package.json +1 -1
- package/dist/dynamic/components/Pagination/package.json +1 -1
- package/dist/dynamic/components/Panel/package.json +1 -1
- package/dist/dynamic/components/Popover/package.json +1 -1
- package/dist/dynamic/components/Progress/package.json +1 -1
- package/dist/dynamic/components/ProgressStepper/package.json +1 -1
- package/dist/dynamic/components/Radio/package.json +1 -1
- package/dist/dynamic/components/SearchInput/package.json +1 -1
- package/dist/dynamic/components/Select/package.json +1 -1
- package/dist/dynamic/components/Sidebar/package.json +1 -1
- package/dist/dynamic/components/SimpleList/package.json +1 -1
- package/dist/dynamic/components/Skeleton/package.json +1 -1
- package/dist/dynamic/components/SkipToContent/package.json +1 -1
- package/dist/dynamic/components/Slider/package.json +1 -1
- package/dist/dynamic/components/Spinner/package.json +1 -1
- package/dist/dynamic/components/Switch/package.json +1 -1
- package/dist/dynamic/components/Tabs/package.json +1 -1
- package/dist/dynamic/components/TextArea/package.json +1 -1
- package/dist/dynamic/components/TextInput/package.json +1 -1
- package/dist/dynamic/components/TextInputGroup/package.json +1 -1
- package/dist/dynamic/components/TimePicker/package.json +1 -1
- package/dist/dynamic/components/Timestamp/package.json +1 -1
- package/dist/dynamic/components/Title/package.json +1 -1
- package/dist/dynamic/components/ToggleGroup/package.json +1 -1
- package/dist/dynamic/components/Toolbar/package.json +1 -1
- package/dist/dynamic/components/Tooltip/package.json +1 -1
- package/dist/dynamic/components/TreeView/package.json +1 -1
- package/dist/dynamic/components/Truncate/package.json +1 -1
- package/dist/dynamic/components/Wizard/hooks/package.json +1 -1
- package/dist/dynamic/components/Wizard/package.json +1 -1
- package/dist/dynamic/deprecated/components/Chip/package.json +1 -1
- package/dist/dynamic/deprecated/components/DragDrop/package.json +1 -1
- package/dist/dynamic/deprecated/components/DualListSelector/package.json +1 -1
- package/dist/dynamic/deprecated/components/Modal/package.json +1 -1
- package/dist/dynamic/deprecated/components/Tile/package.json +1 -1
- package/dist/dynamic/deprecated/components/Wizard/package.json +1 -1
- package/dist/dynamic/deprecated/components/package.json +1 -1
- package/dist/dynamic/helpers/AnimationsProvider/AnimationsProvider/package.json +1 -1
- package/dist/dynamic/helpers/AnimationsProvider/package.json +1 -1
- package/dist/dynamic/helpers/FocusTrap/FocusTrap/package.json +1 -1
- package/dist/dynamic/helpers/GenerateId/GenerateId/package.json +1 -1
- package/dist/dynamic/helpers/KeyboardHandler/package.json +1 -1
- package/dist/dynamic/helpers/OUIA/ouia/package.json +1 -1
- package/dist/dynamic/helpers/Popper/Popper/package.json +1 -1
- package/dist/dynamic/helpers/SSRSafeIds/SSRSafeIds/package.json +1 -1
- package/dist/dynamic/helpers/constants/package.json +1 -1
- package/dist/dynamic/helpers/datetimeUtils/package.json +1 -1
- package/dist/dynamic/helpers/fileUtils/package.json +1 -1
- package/dist/dynamic/helpers/htmlConstants/package.json +1 -1
- package/dist/dynamic/helpers/inert/package.json +1 -1
- package/dist/dynamic/helpers/package.json +1 -1
- package/dist/dynamic/helpers/resizeObserver/package.json +1 -1
- package/dist/dynamic/helpers/typeUtils/package.json +1 -1
- package/dist/dynamic/helpers/useInterval/package.json +1 -1
- package/dist/dynamic/helpers/useIsomorphicLayout/package.json +1 -1
- package/dist/dynamic/helpers/useSSRSafeId/package.json +1 -1
- package/dist/dynamic/helpers/useUnmountEffect/package.json +1 -1
- package/dist/dynamic/helpers/util/package.json +1 -1
- package/dist/dynamic/layouts/Bullseye/package.json +1 -1
- package/dist/dynamic/layouts/Flex/package.json +1 -1
- package/dist/dynamic/layouts/Gallery/package.json +1 -1
- package/dist/dynamic/layouts/Grid/package.json +1 -1
- package/dist/dynamic/layouts/Level/package.json +1 -1
- package/dist/dynamic/layouts/Split/package.json +1 -1
- package/dist/dynamic/layouts/Stack/package.json +1 -1
- package/dist/dynamic/styles/package.json +1 -1
- package/dist/esm/components/CalendarMonth/CalendarMonth.d.ts +7 -2
- package/dist/esm/components/CalendarMonth/CalendarMonth.d.ts.map +1 -1
- package/dist/esm/components/CalendarMonth/CalendarMonth.js +4 -3
- package/dist/esm/components/CalendarMonth/CalendarMonth.js.map +1 -1
- package/dist/esm/components/Drawer/Drawer.d.ts +6 -1
- package/dist/esm/components/Drawer/Drawer.d.ts.map +1 -1
- package/dist/esm/components/Drawer/Drawer.js +4 -2
- package/dist/esm/components/Drawer/Drawer.js.map +1 -1
- package/dist/esm/components/DualListSelector/DualListSelector.d.ts +6 -1
- package/dist/esm/components/DualListSelector/DualListSelector.d.ts.map +1 -1
- package/dist/esm/components/DualListSelector/DualListSelector.js +4 -4
- package/dist/esm/components/DualListSelector/DualListSelector.js.map +1 -1
- package/dist/esm/components/Popover/Popover.d.ts +6 -1
- package/dist/esm/components/Popover/Popover.d.ts.map +1 -1
- package/dist/esm/components/Popover/Popover.js +4 -4
- package/dist/esm/components/Popover/Popover.js.map +1 -1
- package/dist/esm/components/Progress/Progress.d.ts +6 -1
- package/dist/esm/components/Progress/Progress.d.ts.map +1 -1
- package/dist/esm/components/Progress/Progress.js +5 -4
- package/dist/esm/components/Progress/Progress.js.map +1 -1
- package/dist/esm/components/Slider/Slider.d.ts +6 -1
- package/dist/esm/components/Slider/Slider.d.ts.map +1 -1
- package/dist/esm/components/Slider/Slider.js +4 -2
- package/dist/esm/components/Slider/Slider.js.map +1 -1
- package/dist/esm/demos/DashboardHeader.js +1 -1
- package/dist/esm/demos/DashboardHeader.js.map +1 -1
- package/dist/js/components/CalendarMonth/CalendarMonth.d.ts +7 -2
- package/dist/js/components/CalendarMonth/CalendarMonth.d.ts.map +1 -1
- package/dist/js/components/CalendarMonth/CalendarMonth.js +3 -2
- package/dist/js/components/CalendarMonth/CalendarMonth.js.map +1 -1
- package/dist/js/components/Drawer/Drawer.d.ts +6 -1
- package/dist/js/components/Drawer/Drawer.d.ts.map +1 -1
- package/dist/js/components/Drawer/Drawer.js +4 -2
- package/dist/js/components/Drawer/Drawer.js.map +1 -1
- package/dist/js/components/DualListSelector/DualListSelector.d.ts +6 -1
- package/dist/js/components/DualListSelector/DualListSelector.d.ts.map +1 -1
- package/dist/js/components/DualListSelector/DualListSelector.js +4 -4
- package/dist/js/components/DualListSelector/DualListSelector.js.map +1 -1
- package/dist/js/components/Popover/Popover.d.ts +6 -1
- package/dist/js/components/Popover/Popover.d.ts.map +1 -1
- package/dist/js/components/Popover/Popover.js +4 -4
- package/dist/js/components/Popover/Popover.js.map +1 -1
- package/dist/js/components/Progress/Progress.d.ts +6 -1
- package/dist/js/components/Progress/Progress.d.ts.map +1 -1
- package/dist/js/components/Progress/Progress.js +4 -3
- package/dist/js/components/Progress/Progress.js.map +1 -1
- package/dist/js/components/Slider/Slider.d.ts +6 -1
- package/dist/js/components/Slider/Slider.d.ts.map +1 -1
- package/dist/js/components/Slider/Slider.js +4 -2
- package/dist/js/components/Slider/Slider.js.map +1 -1
- package/dist/js/demos/DashboardHeader.js +1 -1
- package/dist/js/demos/DashboardHeader.js.map +1 -1
- package/dist/umd/assets/{output-BkknbY5f.css → output-Bon0Nycr.css} +20403 -20403
- package/dist/umd/react-core.min.js +1 -1
- package/helpers/package.json +1 -1
- package/layouts/package.json +1 -1
- package/next/package.json +1 -1
- package/package.json +2 -2
- package/src/components/CalendarMonth/CalendarMonth.tsx +10 -3
- package/src/components/CalendarMonth/__tests__/CalendarMonth.test.tsx +20 -0
- package/src/components/Compass/__tests__/__snapshots__/Compass.test.tsx.snap +3 -0
- package/src/components/Compass/__tests__/__snapshots__/CompassContent.test.tsx.snap +3 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePicker.test.tsx.snap +17 -11
- package/src/components/Drawer/Drawer.tsx +10 -1
- package/src/components/Drawer/__tests__/Drawer.test.tsx +45 -1
- package/src/components/Drawer/__tests__/__snapshots__/Drawer.test.tsx.snap +38 -14
- package/src/components/DualListSelector/DualListSelector.tsx +10 -3
- package/src/components/DualListSelector/__tests__/DualListSelector.test.tsx +25 -0
- package/src/components/DualListSelector/__tests__/__snapshots__/DualListSelector.test.tsx.snap +13 -0
- package/src/components/MultipleFileUpload/__tests__/__snapshots__/MultipleFileUploadStatusItem.test.tsx.snap +16 -0
- package/src/components/Popover/Popover.tsx +10 -3
- package/src/components/Popover/__tests__/Popover.test.tsx +44 -1
- package/src/components/Progress/Progress.tsx +11 -3
- package/src/components/Progress/__tests__/Progress.test.tsx +21 -1
- package/src/components/Progress/__tests__/__snapshots__/Progress.test.tsx.snap +41 -0
- package/src/components/Slider/Slider.tsx +10 -1
- package/src/components/Slider/__tests__/Slider.test.tsx +21 -1
- package/src/components/Slider/__tests__/__snapshots__/Slider.test.tsx.snap +33 -6
- package/src/demos/DashboardHeader.tsx +1 -1
- package/src/demos/examples/AlertGroup/AlertGroupToastWithNotificationDrawer.tsx +1 -1
- package/src/demos/examples/Masthead/MastheadWithHorizontalNav.tsx +1 -1
- package/src/demos/examples/Masthead/MastheadWithUtilitiesAndUserDropdownMenu.tsx +1 -1
- package/src/demos/examples/Nav/NavFlyout.tsx +1 -1
- package/src/demos/examples/Nav/NavHorizontal.tsx +1 -1
- package/src/demos/examples/Nav/NavHorizontalWithSubnav.tsx +1 -1
- package/src/demos/examples/Nav/NavManual.tsx +1 -1
- package/src/demos/examples/Page/PageContextSelector.tsx +1 -1
- package/src/demos/examples/Page/PageStickySectionBreadcrumb.tsx +1 -1
- package/src/demos/examples/Page/PageStickySectionGroup.tsx +1 -1
- package/src/demos/examples/Page/PageStickySectionGroupAlternate.tsx +1 -1
- package/src/helpers/OUIA/OUIA.md +6 -0
|
@@ -33,6 +33,8 @@ exports[`MultipleFileUploadStatusItem renders custom aria labels 1`] = `
|
|
|
33
33
|
</div>
|
|
34
34
|
<div
|
|
35
35
|
class="pf-v6-c-progress"
|
|
36
|
+
data-ouia-component-type="PF6/Progress"
|
|
37
|
+
data-ouia-safe="true"
|
|
36
38
|
id="test-progress-id"
|
|
37
39
|
>
|
|
38
40
|
<div
|
|
@@ -152,6 +154,8 @@ exports[`MultipleFileUploadStatusItem renders custom class names 1`] = `
|
|
|
152
154
|
</div>
|
|
153
155
|
<div
|
|
154
156
|
class="pf-v6-c-progress"
|
|
157
|
+
data-ouia-component-type="PF6/Progress"
|
|
158
|
+
data-ouia-safe="true"
|
|
155
159
|
id="test-progress-id"
|
|
156
160
|
>
|
|
157
161
|
<div
|
|
@@ -268,6 +272,8 @@ exports[`MultipleFileUploadStatusItem renders custom file name/size/icon/progres
|
|
|
268
272
|
</div>
|
|
269
273
|
<div
|
|
270
274
|
class="pf-v6-c-progress"
|
|
275
|
+
data-ouia-component-type="PF6/Progress"
|
|
276
|
+
data-ouia-safe="true"
|
|
271
277
|
id="test-progress-id"
|
|
272
278
|
>
|
|
273
279
|
<div
|
|
@@ -386,6 +392,8 @@ exports[`MultipleFileUploadStatusItem renders custom function progressAriaLiveMe
|
|
|
386
392
|
</div>
|
|
387
393
|
<div
|
|
388
394
|
class="pf-v6-c-progress"
|
|
395
|
+
data-ouia-component-type="PF6/Progress"
|
|
396
|
+
data-ouia-safe="true"
|
|
389
397
|
id="test-progress-id"
|
|
390
398
|
>
|
|
391
399
|
<div
|
|
@@ -504,6 +512,8 @@ exports[`MultipleFileUploadStatusItem renders custom progress value/variant when
|
|
|
504
512
|
</div>
|
|
505
513
|
<div
|
|
506
514
|
class="pf-v6-c-progress pf-m-warning"
|
|
515
|
+
data-ouia-component-type="PF6/Progress"
|
|
516
|
+
data-ouia-safe="true"
|
|
507
517
|
id="test-progress-id"
|
|
508
518
|
>
|
|
509
519
|
<div
|
|
@@ -639,6 +649,8 @@ exports[`MultipleFileUploadStatusItem renders expected values from a passed file
|
|
|
639
649
|
</div>
|
|
640
650
|
<div
|
|
641
651
|
class="pf-v6-c-progress"
|
|
652
|
+
data-ouia-component-type="PF6/Progress"
|
|
653
|
+
data-ouia-safe="true"
|
|
642
654
|
id="test-progress-id"
|
|
643
655
|
>
|
|
644
656
|
<div
|
|
@@ -757,6 +769,8 @@ exports[`MultipleFileUploadStatusItem renders with expected class names 1`] = `
|
|
|
757
769
|
</div>
|
|
758
770
|
<div
|
|
759
771
|
class="pf-v6-c-progress"
|
|
772
|
+
data-ouia-component-type="PF6/Progress"
|
|
773
|
+
data-ouia-safe="true"
|
|
760
774
|
id="test-progress-id"
|
|
761
775
|
>
|
|
762
776
|
<div
|
|
@@ -873,6 +887,8 @@ exports[`MultipleFileUploadStatusItem rendersdefault progressAriaLiveMessage whe
|
|
|
873
887
|
</div>
|
|
874
888
|
<div
|
|
875
889
|
class="pf-v6-c-progress"
|
|
890
|
+
data-ouia-component-type="PF6/Progress"
|
|
891
|
+
data-ouia-safe="true"
|
|
876
892
|
id="test-progress-id"
|
|
877
893
|
>
|
|
878
894
|
<div
|
|
@@ -11,9 +11,8 @@ import { PopoverCloseButton } from './PopoverCloseButton';
|
|
|
11
11
|
import { PopoverArrow } from './PopoverArrow';
|
|
12
12
|
import popoverMaxWidth from '@patternfly/react-tokens/dist/esm/c_popover_MaxWidth';
|
|
13
13
|
import popoverMinWidth from '@patternfly/react-tokens/dist/esm/c_popover_MinWidth';
|
|
14
|
-
import { FocusTrap } from '../../helpers';
|
|
14
|
+
import { FocusTrap, useSSRSafeId, useOUIAProps, OUIAProps } from '../../helpers';
|
|
15
15
|
import { Popper } from '../../helpers/Popper/Popper';
|
|
16
|
-
import { useSSRSafeId } from '../../helpers';
|
|
17
16
|
|
|
18
17
|
export enum PopoverPosition {
|
|
19
18
|
auto = 'auto',
|
|
@@ -35,7 +34,7 @@ export enum PopoverPosition {
|
|
|
35
34
|
* that has a property specifically for passing in popover properties.
|
|
36
35
|
*/
|
|
37
36
|
|
|
38
|
-
export interface PopoverProps {
|
|
37
|
+
export interface PopoverProps extends OUIAProps {
|
|
39
38
|
/** Text announced by screen reader when alert severity variant is set to indicate
|
|
40
39
|
* severity level.
|
|
41
40
|
*/
|
|
@@ -213,6 +212,10 @@ export interface PopoverProps {
|
|
|
213
212
|
withFocusTrap?: boolean;
|
|
214
213
|
/** The z-index of the popover. */
|
|
215
214
|
zIndex?: number;
|
|
215
|
+
/** Value to overwrite the randomly generated data-ouia-component-id.*/
|
|
216
|
+
ouiaId?: number | string;
|
|
217
|
+
/** Set the value of data-ouia-safe. Only set to true when the component is in a static state, i.e. no animations are occurring. At all other times, this value must be false. */
|
|
218
|
+
ouiaSafe?: boolean;
|
|
216
219
|
}
|
|
217
220
|
|
|
218
221
|
const alertStyle = {
|
|
@@ -274,12 +277,15 @@ export const Popover: React.FunctionComponent<PopoverProps> = ({
|
|
|
274
277
|
hasNoPadding = false,
|
|
275
278
|
hasAutoWidth = false,
|
|
276
279
|
elementToFocus,
|
|
280
|
+
ouiaId,
|
|
281
|
+
ouiaSafe = true,
|
|
277
282
|
...rest
|
|
278
283
|
}: PopoverProps) => {
|
|
279
284
|
// could make this a prop in the future (true | false | 'toggle')
|
|
280
285
|
// const hideOnClick = true;
|
|
281
286
|
const generatedId = useSSRSafeId();
|
|
282
287
|
const uniqueId = id || generatedId;
|
|
288
|
+
const ouiaProps = useOUIAProps(Popover.displayName, ouiaId, ouiaSafe);
|
|
283
289
|
const triggerManually = isVisible !== null;
|
|
284
290
|
const [visible, setVisible] = useState(false);
|
|
285
291
|
const [focusTrapActive, setFocusTrapActive] = useState(Boolean(propWithFocusTrap));
|
|
@@ -475,6 +481,7 @@ export const Popover: React.FunctionComponent<PopoverProps> = ({
|
|
|
475
481
|
maxWidth: hasCustomMaxWidth ? maxWidth : null
|
|
476
482
|
}}
|
|
477
483
|
{...rest}
|
|
484
|
+
{...ouiaProps}
|
|
478
485
|
>
|
|
479
486
|
<PopoverArrow />
|
|
480
487
|
<PopoverContent>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { StrictMode } from 'react';
|
|
2
|
-
import { render } from '@testing-library/react';
|
|
2
|
+
import { render, screen } from '@testing-library/react';
|
|
3
3
|
import { Popover, PopoverPosition } from '../Popover';
|
|
4
4
|
|
|
5
5
|
test('popover renders close-button, header and body', () => {
|
|
@@ -9,6 +9,7 @@ test('popover renders close-button, header and body', () => {
|
|
|
9
9
|
position="top"
|
|
10
10
|
isVisible
|
|
11
11
|
hideOnOutsideClick
|
|
12
|
+
ouiaId="ouia-id"
|
|
12
13
|
headerContent={<div>Popover Header</div>}
|
|
13
14
|
bodyContent={
|
|
14
15
|
<div>
|
|
@@ -114,3 +115,45 @@ test('popover renders in strict mode', () => {
|
|
|
114
115
|
expect(consoleError).not.toHaveBeenCalled();
|
|
115
116
|
expect(asFragment()).toMatchSnapshot();
|
|
116
117
|
});
|
|
118
|
+
|
|
119
|
+
test('Renders with custom ouiaId', () => {
|
|
120
|
+
render(
|
|
121
|
+
<Popover isVisible ouiaId="test-id" headerContent={<div>Popover Header</div>} bodyContent={<div>Popover body</div>}>
|
|
122
|
+
<div>Toggle Popover</div>
|
|
123
|
+
</Popover>
|
|
124
|
+
);
|
|
125
|
+
expect(screen.getByRole('dialog')).toHaveAttribute('data-ouia-component-id', 'test-id');
|
|
126
|
+
});
|
|
127
|
+
|
|
128
|
+
test('Renders with expected ouia component type', () => {
|
|
129
|
+
render(
|
|
130
|
+
<Popover isVisible ouiaId="test-id" headerContent={<div>Popover Header</div>} bodyContent={<div>Popover body</div>}>
|
|
131
|
+
<div>Toggle Popover</div>
|
|
132
|
+
</Popover>
|
|
133
|
+
);
|
|
134
|
+
expect(screen.getByRole('dialog')).toHaveAttribute('data-ouia-component-type', 'PF6/Popover');
|
|
135
|
+
});
|
|
136
|
+
|
|
137
|
+
test('Renders with ouiaSafe defaulting to true', () => {
|
|
138
|
+
render(
|
|
139
|
+
<Popover isVisible ouiaId="test-id" headerContent={<div>Popover Header</div>} bodyContent={<div>Popover body</div>}>
|
|
140
|
+
<div>Toggle Popover</div>
|
|
141
|
+
</Popover>
|
|
142
|
+
);
|
|
143
|
+
expect(screen.getByRole('dialog')).toHaveAttribute('data-ouia-safe', 'true');
|
|
144
|
+
});
|
|
145
|
+
|
|
146
|
+
test('Renders with ouiaSafe=false when specified', () => {
|
|
147
|
+
render(
|
|
148
|
+
<Popover
|
|
149
|
+
isVisible
|
|
150
|
+
ouiaId="test-id"
|
|
151
|
+
ouiaSafe={false}
|
|
152
|
+
headerContent={<div>Popover Header</div>}
|
|
153
|
+
bodyContent={<div>Popover body</div>}
|
|
154
|
+
>
|
|
155
|
+
<div>Toggle Popover</div>
|
|
156
|
+
</Popover>
|
|
157
|
+
);
|
|
158
|
+
expect(screen.getByRole('dialog')).toHaveAttribute('data-ouia-safe', 'false');
|
|
159
|
+
});
|
|
@@ -3,7 +3,7 @@ import styles from '@patternfly/react-styles/css/components/Progress/progress';
|
|
|
3
3
|
import { css } from '@patternfly/react-styles';
|
|
4
4
|
import { ProgressContainer, ProgressMeasureLocation } from './ProgressContainer';
|
|
5
5
|
import { AriaProps } from './ProgressBar';
|
|
6
|
-
import { GenerateId } from '../../helpers';
|
|
6
|
+
import { GenerateId, getOUIAProps, OUIAProps } from '../../helpers';
|
|
7
7
|
|
|
8
8
|
export enum ProgressSize {
|
|
9
9
|
sm = 'sm',
|
|
@@ -11,7 +11,7 @@ export enum ProgressSize {
|
|
|
11
11
|
lg = 'lg'
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
export interface ProgressProps extends Omit<React.HTMLProps<HTMLDivElement>, 'size' | 'label' | 'title'
|
|
14
|
+
export interface ProgressProps extends Omit<React.HTMLProps<HTMLDivElement>, 'size' | 'label' | 'title'>, OUIAProps {
|
|
15
15
|
/** Classname for progress component. */
|
|
16
16
|
className?: string;
|
|
17
17
|
/** Size variant of progress. */
|
|
@@ -50,6 +50,10 @@ export interface ProgressProps extends Omit<React.HTMLProps<HTMLDivElement>, 'si
|
|
|
50
50
|
helperText?: React.ReactNode;
|
|
51
51
|
/** Flag indicating whether the status icon should be hidden, helpful when space is limited (such as within table cells). When set to true, you must ensure the context of the status is provided in another way, such as via the progress measure. */
|
|
52
52
|
hideStatusIcon?: boolean;
|
|
53
|
+
/** Value to overwrite the randomly generated data-ouia-component-id.*/
|
|
54
|
+
ouiaId?: number | string;
|
|
55
|
+
/** Set the value of data-ouia-safe. Only set to true when the component is in a static state, i.e. no animations are occurring. At all other times, this value must be false. */
|
|
56
|
+
ouiaSafe?: boolean;
|
|
53
57
|
}
|
|
54
58
|
|
|
55
59
|
class Progress extends Component<ProgressProps> {
|
|
@@ -70,7 +74,8 @@ class Progress extends Component<ProgressProps> {
|
|
|
70
74
|
tooltipPosition: 'top' as 'auto' | 'top' | 'bottom' | 'left' | 'right',
|
|
71
75
|
'aria-label': null as string,
|
|
72
76
|
'aria-labelledby': null as string,
|
|
73
|
-
'aria-describedby': null as string
|
|
77
|
+
'aria-describedby': null as string,
|
|
78
|
+
ouiaSafe: true
|
|
74
79
|
};
|
|
75
80
|
|
|
76
81
|
render() {
|
|
@@ -94,6 +99,8 @@ class Progress extends Component<ProgressProps> {
|
|
|
94
99
|
'aria-describedby': ariaDescribedBy,
|
|
95
100
|
helperText,
|
|
96
101
|
hideStatusIcon,
|
|
102
|
+
ouiaId,
|
|
103
|
+
ouiaSafe,
|
|
97
104
|
...props
|
|
98
105
|
} = this.props;
|
|
99
106
|
|
|
@@ -147,6 +154,7 @@ class Progress extends Component<ProgressProps> {
|
|
|
147
154
|
className
|
|
148
155
|
)}
|
|
149
156
|
id={id}
|
|
157
|
+
{...getOUIAProps(Progress.displayName, ouiaId, ouiaSafe)}
|
|
150
158
|
>
|
|
151
159
|
<ProgressContainer
|
|
152
160
|
parentId={id}
|
|
@@ -3,7 +3,7 @@ import { Progress, ProgressSize } from '../Progress';
|
|
|
3
3
|
import { ProgressVariant, ProgressMeasureLocation } from '../ProgressContainer';
|
|
4
4
|
|
|
5
5
|
test('Simple progress', () => {
|
|
6
|
-
const { asFragment } = render(<Progress value={33} id="progress-simple-example" />);
|
|
6
|
+
const { asFragment } = render(<Progress value={33} id="progress-simple-example" ouiaId="ouia-id" />);
|
|
7
7
|
expect(asFragment()).toMatchSnapshot();
|
|
8
8
|
});
|
|
9
9
|
|
|
@@ -109,6 +109,26 @@ test('Renders passed helper text', () => {
|
|
|
109
109
|
expect(screen.getByText('Test helper text')).toBeVisible();
|
|
110
110
|
});
|
|
111
111
|
|
|
112
|
+
test('Renders with custom ouiaId', () => {
|
|
113
|
+
render(<Progress value={33} id="progress-ouia-id" ouiaId="test-id" title="Test" />);
|
|
114
|
+
expect(document.getElementById('progress-ouia-id')).toHaveAttribute('data-ouia-component-id', 'test-id');
|
|
115
|
+
});
|
|
116
|
+
|
|
117
|
+
test('Renders with expected ouia component type', () => {
|
|
118
|
+
render(<Progress value={33} id="progress-ouia-type" ouiaId="test-id" title="Test" />);
|
|
119
|
+
expect(document.getElementById('progress-ouia-type')).toHaveAttribute('data-ouia-component-type', 'PF6/Progress');
|
|
120
|
+
});
|
|
121
|
+
|
|
122
|
+
test('Renders with ouiaSafe defaulting to true', () => {
|
|
123
|
+
render(<Progress value={33} id="progress-ouia-safe" ouiaId="test-id" title="Test" />);
|
|
124
|
+
expect(document.getElementById('progress-ouia-safe')).toHaveAttribute('data-ouia-safe', 'true');
|
|
125
|
+
});
|
|
126
|
+
|
|
127
|
+
test('Renders with ouiaSafe=false when specified', () => {
|
|
128
|
+
render(<Progress value={33} id="progress-ouia-unsafe" ouiaId="test-id" ouiaSafe={false} title="Test" />);
|
|
129
|
+
expect(document.getElementById('progress-ouia-unsafe')).toHaveAttribute('data-ouia-safe', 'false');
|
|
130
|
+
});
|
|
131
|
+
|
|
112
132
|
describe('hideStatusIcon prop behavior', () => {
|
|
113
133
|
test('shows status icon by default when hideStatusIcon is not set', () => {
|
|
114
134
|
render(<Progress id="default-status-icon-test" value={100} variant="success" />);
|
|
@@ -4,6 +4,8 @@ exports[`Progress measure location inside 1`] = `
|
|
|
4
4
|
<DocumentFragment>
|
|
5
5
|
<div
|
|
6
6
|
class="pf-v6-c-progress pf-m-inside pf-m-lg pf-m-singleline"
|
|
7
|
+
data-ouia-component-type="PF6/Progress"
|
|
8
|
+
data-ouia-safe="true"
|
|
7
9
|
id="inside-progress"
|
|
8
10
|
>
|
|
9
11
|
<div
|
|
@@ -36,6 +38,8 @@ exports[`Progress measure location inside and small should render large 1`] = `
|
|
|
36
38
|
<DocumentFragment>
|
|
37
39
|
<div
|
|
38
40
|
class="pf-v6-c-progress pf-m-inside pf-m-lg pf-m-singleline"
|
|
41
|
+
data-ouia-component-type="PF6/Progress"
|
|
42
|
+
data-ouia-safe="true"
|
|
39
43
|
id="large-progress"
|
|
40
44
|
>
|
|
41
45
|
<div
|
|
@@ -68,6 +72,8 @@ exports[`Progress measure location none 1`] = `
|
|
|
68
72
|
<DocumentFragment>
|
|
69
73
|
<div
|
|
70
74
|
class="pf-v6-c-progress pf-m-singleline"
|
|
75
|
+
data-ouia-component-type="PF6/Progress"
|
|
76
|
+
data-ouia-safe="true"
|
|
71
77
|
id="none-progress"
|
|
72
78
|
>
|
|
73
79
|
<div
|
|
@@ -94,6 +100,8 @@ exports[`Progress measure location outside 1`] = `
|
|
|
94
100
|
<DocumentFragment>
|
|
95
101
|
<div
|
|
96
102
|
class="pf-v6-c-progress pf-m-outside pf-m-singleline"
|
|
103
|
+
data-ouia-component-type="PF6/Progress"
|
|
104
|
+
data-ouia-safe="true"
|
|
97
105
|
id="outside-progress"
|
|
98
106
|
>
|
|
99
107
|
<div
|
|
@@ -130,6 +138,8 @@ exports[`Progress measure location top 1`] = `
|
|
|
130
138
|
<DocumentFragment>
|
|
131
139
|
<div
|
|
132
140
|
class="pf-v6-c-progress pf-m-singleline"
|
|
141
|
+
data-ouia-component-type="PF6/Progress"
|
|
142
|
+
data-ouia-safe="true"
|
|
133
143
|
id="top-progress"
|
|
134
144
|
>
|
|
135
145
|
<div
|
|
@@ -166,6 +176,8 @@ exports[`Progress size lg 1`] = `
|
|
|
166
176
|
<DocumentFragment>
|
|
167
177
|
<div
|
|
168
178
|
class="pf-v6-c-progress pf-m-lg pf-m-singleline"
|
|
179
|
+
data-ouia-component-type="PF6/Progress"
|
|
180
|
+
data-ouia-safe="true"
|
|
169
181
|
id="lg-progress"
|
|
170
182
|
>
|
|
171
183
|
<div
|
|
@@ -202,6 +214,8 @@ exports[`Progress size md 1`] = `
|
|
|
202
214
|
<DocumentFragment>
|
|
203
215
|
<div
|
|
204
216
|
class="pf-v6-c-progress pf-m-singleline"
|
|
217
|
+
data-ouia-component-type="PF6/Progress"
|
|
218
|
+
data-ouia-safe="true"
|
|
205
219
|
id="md-progress"
|
|
206
220
|
>
|
|
207
221
|
<div
|
|
@@ -238,6 +252,8 @@ exports[`Progress size sm 1`] = `
|
|
|
238
252
|
<DocumentFragment>
|
|
239
253
|
<div
|
|
240
254
|
class="pf-v6-c-progress pf-m-sm pf-m-singleline"
|
|
255
|
+
data-ouia-component-type="PF6/Progress"
|
|
256
|
+
data-ouia-safe="true"
|
|
241
257
|
id="sm-progress"
|
|
242
258
|
>
|
|
243
259
|
<div
|
|
@@ -274,6 +290,8 @@ exports[`Progress variant danger 1`] = `
|
|
|
274
290
|
<DocumentFragment>
|
|
275
291
|
<div
|
|
276
292
|
class="pf-v6-c-progress pf-m-danger pf-m-singleline"
|
|
293
|
+
data-ouia-component-type="PF6/Progress"
|
|
294
|
+
data-ouia-safe="true"
|
|
277
295
|
id="danger-progress"
|
|
278
296
|
>
|
|
279
297
|
<div
|
|
@@ -327,6 +345,8 @@ exports[`Progress variant success 1`] = `
|
|
|
327
345
|
<DocumentFragment>
|
|
328
346
|
<div
|
|
329
347
|
class="pf-v6-c-progress pf-m-success pf-m-singleline"
|
|
348
|
+
data-ouia-component-type="PF6/Progress"
|
|
349
|
+
data-ouia-safe="true"
|
|
330
350
|
id="success-progress"
|
|
331
351
|
>
|
|
332
352
|
<div
|
|
@@ -380,6 +400,8 @@ exports[`Progress variant warning 1`] = `
|
|
|
380
400
|
<DocumentFragment>
|
|
381
401
|
<div
|
|
382
402
|
class="pf-v6-c-progress pf-m-warning pf-m-singleline"
|
|
403
|
+
data-ouia-component-type="PF6/Progress"
|
|
404
|
+
data-ouia-safe="true"
|
|
383
405
|
id="warning-progress"
|
|
384
406
|
>
|
|
385
407
|
<div
|
|
@@ -433,6 +455,8 @@ exports[`Progress with aria-valuetext 1`] = `
|
|
|
433
455
|
<DocumentFragment>
|
|
434
456
|
<div
|
|
435
457
|
class="pf-v6-c-progress pf-m-singleline"
|
|
458
|
+
data-ouia-component-type="PF6/Progress"
|
|
459
|
+
data-ouia-safe="true"
|
|
436
460
|
id="progress-aria-valuetext"
|
|
437
461
|
>
|
|
438
462
|
<div
|
|
@@ -470,6 +494,9 @@ exports[`Simple progress 1`] = `
|
|
|
470
494
|
<DocumentFragment>
|
|
471
495
|
<div
|
|
472
496
|
class="pf-v6-c-progress pf-m-singleline"
|
|
497
|
+
data-ouia-component-id="ouia-id"
|
|
498
|
+
data-ouia-component-type="PF6/Progress"
|
|
499
|
+
data-ouia-safe="true"
|
|
473
500
|
id="progress-simple-example"
|
|
474
501
|
>
|
|
475
502
|
<div
|
|
@@ -506,6 +533,8 @@ exports[`additional label 1`] = `
|
|
|
506
533
|
<DocumentFragment>
|
|
507
534
|
<div
|
|
508
535
|
class="pf-v6-c-progress pf-m-singleline"
|
|
536
|
+
data-ouia-component-type="PF6/Progress"
|
|
537
|
+
data-ouia-safe="true"
|
|
509
538
|
id="additional-label"
|
|
510
539
|
>
|
|
511
540
|
<div
|
|
@@ -542,6 +571,8 @@ exports[`no value specified 1`] = `
|
|
|
542
571
|
<DocumentFragment>
|
|
543
572
|
<div
|
|
544
573
|
class="pf-v6-c-progress pf-m-singleline"
|
|
574
|
+
data-ouia-component-type="PF6/Progress"
|
|
575
|
+
data-ouia-safe="true"
|
|
545
576
|
id="no-value"
|
|
546
577
|
>
|
|
547
578
|
<div
|
|
@@ -578,6 +609,8 @@ exports[`value higher than maxValue 1`] = `
|
|
|
578
609
|
<DocumentFragment>
|
|
579
610
|
<div
|
|
580
611
|
class="pf-v6-c-progress pf-m-singleline"
|
|
612
|
+
data-ouia-component-type="PF6/Progress"
|
|
613
|
+
data-ouia-safe="true"
|
|
581
614
|
id="higher-max-value"
|
|
582
615
|
>
|
|
583
616
|
<div
|
|
@@ -614,6 +647,8 @@ exports[`value lower than minValue 1`] = `
|
|
|
614
647
|
<DocumentFragment>
|
|
615
648
|
<div
|
|
616
649
|
class="pf-v6-c-progress pf-m-singleline"
|
|
650
|
+
data-ouia-component-type="PF6/Progress"
|
|
651
|
+
data-ouia-safe="true"
|
|
617
652
|
id="lower-min-value"
|
|
618
653
|
>
|
|
619
654
|
<div
|
|
@@ -650,6 +685,8 @@ exports[`value scaled between minValue and maxValue 1`] = `
|
|
|
650
685
|
<DocumentFragment>
|
|
651
686
|
<div
|
|
652
687
|
class="pf-v6-c-progress pf-m-singleline"
|
|
688
|
+
data-ouia-component-type="PF6/Progress"
|
|
689
|
+
data-ouia-safe="true"
|
|
653
690
|
id="scaled-range-value"
|
|
654
691
|
>
|
|
655
692
|
<div
|
|
@@ -686,6 +723,8 @@ exports[`value scaled with maxValue 1`] = `
|
|
|
686
723
|
<DocumentFragment>
|
|
687
724
|
<div
|
|
688
725
|
class="pf-v6-c-progress pf-m-singleline"
|
|
726
|
+
data-ouia-component-type="PF6/Progress"
|
|
727
|
+
data-ouia-safe="true"
|
|
689
728
|
id="scaled-max-value"
|
|
690
729
|
>
|
|
691
730
|
<div
|
|
@@ -722,6 +761,8 @@ exports[`value scaled with minValue 1`] = `
|
|
|
722
761
|
<DocumentFragment>
|
|
723
762
|
<div
|
|
724
763
|
class="pf-v6-c-progress pf-m-singleline"
|
|
764
|
+
data-ouia-component-type="PF6/Progress"
|
|
765
|
+
data-ouia-safe="true"
|
|
725
766
|
id="scaled-min-value"
|
|
726
767
|
>
|
|
727
768
|
<div
|
|
@@ -8,6 +8,7 @@ import { Tooltip, TooltipProps } from '../Tooltip';
|
|
|
8
8
|
import cssSliderValue from '@patternfly/react-tokens/dist/esm/c_slider_value';
|
|
9
9
|
import cssFormControlWidthChars from '@patternfly/react-tokens/dist/esm/c_slider__value_c_form_control_width_chars';
|
|
10
10
|
import { getLanguageDirection } from '../../helpers/util';
|
|
11
|
+
import { useOUIAProps, OUIAProps } from '../../helpers';
|
|
11
12
|
|
|
12
13
|
/** Properties for creating custom steps in a slider. These properties should be passed in as
|
|
13
14
|
* an object within an array to the slider component's customSteps property.
|
|
@@ -29,7 +30,7 @@ export type SliderOnChangeEvent =
|
|
|
29
30
|
| React.FocusEvent<HTMLInputElement>;
|
|
30
31
|
|
|
31
32
|
/** The main slider component. */
|
|
32
|
-
export interface SliderProps extends Omit<React.HTMLProps<HTMLDivElement>, 'onChange'
|
|
33
|
+
export interface SliderProps extends Omit<React.HTMLProps<HTMLDivElement>, 'onChange'>, OUIAProps {
|
|
33
34
|
/** Flag indicating if the slider is discrete for custom steps. This will cause the slider
|
|
34
35
|
* to snap to the closest value.
|
|
35
36
|
*/
|
|
@@ -93,6 +94,10 @@ export interface SliderProps extends Omit<React.HTMLProps<HTMLDivElement>, 'onCh
|
|
|
93
94
|
thumbAriaValueText?: string;
|
|
94
95
|
/** Current value of the slider. */
|
|
95
96
|
value?: number;
|
|
97
|
+
/** Value to overwrite the randomly generated data-ouia-component-id.*/
|
|
98
|
+
ouiaId?: number | string;
|
|
99
|
+
/** Set the value of data-ouia-safe. Only set to true when the component is in a static state, i.e. no animations are occurring. At all other times, this value must be false. */
|
|
100
|
+
ouiaSafe?: boolean;
|
|
96
101
|
}
|
|
97
102
|
|
|
98
103
|
const getPercentage = (current: number, max: number) => (100 * current) / max;
|
|
@@ -126,8 +131,11 @@ export const Slider: React.FunctionComponent<SliderProps> = ({
|
|
|
126
131
|
showBoundaries = true,
|
|
127
132
|
'aria-describedby': ariaDescribedby,
|
|
128
133
|
'aria-labelledby': ariaLabelledby,
|
|
134
|
+
ouiaId,
|
|
135
|
+
ouiaSafe = true,
|
|
129
136
|
...props
|
|
130
137
|
}: SliderProps) => {
|
|
138
|
+
const ouiaProps = useOUIAProps(Slider.displayName, ouiaId, ouiaSafe);
|
|
131
139
|
const sliderRailRef = useRef<HTMLDivElement>(undefined);
|
|
132
140
|
const thumbRef = useRef<HTMLDivElement>(undefined);
|
|
133
141
|
|
|
@@ -457,6 +465,7 @@ export const Slider: React.FunctionComponent<SliderProps> = ({
|
|
|
457
465
|
className={css(styles.slider, className, isDisabled && styles.modifiers.disabled)}
|
|
458
466
|
style={{ ...style, ...inputStyle }}
|
|
459
467
|
{...props}
|
|
468
|
+
{...ouiaProps}
|
|
460
469
|
>
|
|
461
470
|
{(leftActions || startActions) && <div className={css(styles.sliderActions)}>{leftActions || startActions}</div>}
|
|
462
471
|
<div className={css(styles.sliderMain)}>
|
|
@@ -5,7 +5,7 @@ import { Button } from '../../Button';
|
|
|
5
5
|
|
|
6
6
|
describe('slider', () => {
|
|
7
7
|
test('renders continuous slider', () => {
|
|
8
|
-
const { asFragment } = render(<Slider value={50} isInputVisible inputValue={50} />);
|
|
8
|
+
const { asFragment } = render(<Slider value={50} isInputVisible inputValue={50} ouiaId="ouia-id" />);
|
|
9
9
|
expect(asFragment()).toMatchSnapshot();
|
|
10
10
|
});
|
|
11
11
|
|
|
@@ -91,6 +91,26 @@ describe('slider', () => {
|
|
|
91
91
|
});
|
|
92
92
|
});
|
|
93
93
|
|
|
94
|
+
test('Renders with custom ouiaId', () => {
|
|
95
|
+
const { container } = render(<Slider value={50} ouiaId="test-id" />);
|
|
96
|
+
expect(container.firstChild).toHaveAttribute('data-ouia-component-id', 'test-id');
|
|
97
|
+
});
|
|
98
|
+
|
|
99
|
+
test('Renders with expected ouia component type', () => {
|
|
100
|
+
const { container } = render(<Slider value={50} ouiaId="test-id" />);
|
|
101
|
+
expect(container.firstChild).toHaveAttribute('data-ouia-component-type', 'PF6/Slider');
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
test('Renders with ouiaSafe defaulting to true', () => {
|
|
105
|
+
const { container } = render(<Slider value={50} ouiaId="test-id" />);
|
|
106
|
+
expect(container.firstChild).toHaveAttribute('data-ouia-safe', 'true');
|
|
107
|
+
});
|
|
108
|
+
|
|
109
|
+
test('Renders with ouiaSafe=false when specified', () => {
|
|
110
|
+
const { container } = render(<Slider value={50} ouiaId="test-id" ouiaSafe={false} />);
|
|
111
|
+
expect(container.firstChild).toHaveAttribute('data-ouia-safe', 'false');
|
|
112
|
+
});
|
|
113
|
+
|
|
94
114
|
test('renders slider with aria-labelledby', () => {
|
|
95
115
|
render(
|
|
96
116
|
<>
|
|
@@ -4,6 +4,9 @@ exports[`slider renders continuous slider 1`] = `
|
|
|
4
4
|
<DocumentFragment>
|
|
5
5
|
<div
|
|
6
6
|
class="pf-v6-c-slider"
|
|
7
|
+
data-ouia-component-id="ouia-id"
|
|
8
|
+
data-ouia-component-type="PF6/Slider"
|
|
9
|
+
data-ouia-safe="true"
|
|
7
10
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 2;"
|
|
8
11
|
>
|
|
9
12
|
<div
|
|
@@ -62,7 +65,7 @@ exports[`slider renders continuous slider 1`] = `
|
|
|
62
65
|
<input
|
|
63
66
|
aria-invalid="false"
|
|
64
67
|
aria-label="Slider value input"
|
|
65
|
-
data-ouia-component-id="OUIA-Generated-TextInputBase-:
|
|
68
|
+
data-ouia-component-id="OUIA-Generated-TextInputBase-:r2:"
|
|
66
69
|
data-ouia-component-type="PF6/TextInput"
|
|
67
70
|
data-ouia-safe="true"
|
|
68
71
|
type="number"
|
|
@@ -78,6 +81,9 @@ exports[`slider renders continuous slider with custom steps 1`] = `
|
|
|
78
81
|
<DocumentFragment>
|
|
79
82
|
<div
|
|
80
83
|
class="pf-v6-c-slider"
|
|
84
|
+
data-ouia-component-id="OUIA-Generated-Slider-:r7:"
|
|
85
|
+
data-ouia-component-type="PF6/Slider"
|
|
86
|
+
data-ouia-safe="true"
|
|
81
87
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 1;"
|
|
82
88
|
>
|
|
83
89
|
<div
|
|
@@ -141,6 +147,9 @@ exports[`slider renders disabled slider 1`] = `
|
|
|
141
147
|
<DocumentFragment>
|
|
142
148
|
<div
|
|
143
149
|
class="pf-v6-c-slider pf-m-disabled"
|
|
150
|
+
data-ouia-component-id="OUIA-Generated-Slider-:rh:"
|
|
151
|
+
data-ouia-component-type="PF6/Slider"
|
|
152
|
+
data-ouia-safe="true"
|
|
144
153
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 1;"
|
|
145
154
|
>
|
|
146
155
|
<div
|
|
@@ -198,6 +207,9 @@ exports[`slider renders discrete slider 1`] = `
|
|
|
198
207
|
<DocumentFragment>
|
|
199
208
|
<div
|
|
200
209
|
class="pf-v6-c-slider"
|
|
210
|
+
data-ouia-component-id="OUIA-Generated-Slider-:r3:"
|
|
211
|
+
data-ouia-component-type="PF6/Slider"
|
|
212
|
+
data-ouia-safe="true"
|
|
201
213
|
style="--pf-v6-c-slider--value: 40%; --pf-v6-c-slider__value--c-form-control--width-chars: 2;"
|
|
202
214
|
>
|
|
203
215
|
<div
|
|
@@ -256,7 +268,7 @@ exports[`slider renders discrete slider 1`] = `
|
|
|
256
268
|
<input
|
|
257
269
|
aria-invalid="false"
|
|
258
270
|
aria-label="Slider value input"
|
|
259
|
-
data-ouia-component-id="OUIA-Generated-TextInputBase-:
|
|
271
|
+
data-ouia-component-id="OUIA-Generated-TextInputBase-:r5:"
|
|
260
272
|
data-ouia-component-type="PF6/TextInput"
|
|
261
273
|
data-ouia-safe="true"
|
|
262
274
|
type="number"
|
|
@@ -272,6 +284,9 @@ exports[`slider renders discrete slider with custom steps 1`] = `
|
|
|
272
284
|
<DocumentFragment>
|
|
273
285
|
<div
|
|
274
286
|
class="pf-v6-c-slider"
|
|
287
|
+
data-ouia-component-id="OUIA-Generated-Slider-:r6:"
|
|
288
|
+
data-ouia-component-type="PF6/Slider"
|
|
289
|
+
data-ouia-safe="true"
|
|
275
290
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 1;"
|
|
276
291
|
>
|
|
277
292
|
<div
|
|
@@ -364,6 +379,9 @@ exports[`slider renders slider with input 1`] = `
|
|
|
364
379
|
<DocumentFragment>
|
|
365
380
|
<div
|
|
366
381
|
class="pf-v6-c-slider"
|
|
382
|
+
data-ouia-component-id="OUIA-Generated-Slider-:r8:"
|
|
383
|
+
data-ouia-component-type="PF6/Slider"
|
|
384
|
+
data-ouia-safe="true"
|
|
367
385
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 2;"
|
|
368
386
|
>
|
|
369
387
|
<div
|
|
@@ -428,7 +446,7 @@ exports[`slider renders slider with input 1`] = `
|
|
|
428
446
|
<input
|
|
429
447
|
aria-invalid="false"
|
|
430
448
|
aria-label="Slider value input"
|
|
431
|
-
data-ouia-component-id="OUIA-Generated-TextInputBase-:
|
|
449
|
+
data-ouia-component-id="OUIA-Generated-TextInputBase-:ra:"
|
|
432
450
|
data-ouia-component-type="PF6/TextInput"
|
|
433
451
|
data-ouia-safe="true"
|
|
434
452
|
type="number"
|
|
@@ -455,6 +473,9 @@ exports[`slider renders slider with input above thumb 1`] = `
|
|
|
455
473
|
<DocumentFragment>
|
|
456
474
|
<div
|
|
457
475
|
class="pf-v6-c-slider"
|
|
476
|
+
data-ouia-component-id="OUIA-Generated-Slider-:rb:"
|
|
477
|
+
data-ouia-component-type="PF6/Slider"
|
|
478
|
+
data-ouia-safe="true"
|
|
458
479
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 2;"
|
|
459
480
|
>
|
|
460
481
|
<div
|
|
@@ -518,7 +539,7 @@ exports[`slider renders slider with input above thumb 1`] = `
|
|
|
518
539
|
<input
|
|
519
540
|
aria-invalid="false"
|
|
520
541
|
aria-label="Slider value input"
|
|
521
|
-
data-ouia-component-id="OUIA-Generated-TextInputBase-:
|
|
542
|
+
data-ouia-component-id="OUIA-Generated-TextInputBase-:rd:"
|
|
522
543
|
data-ouia-component-type="PF6/TextInput"
|
|
523
544
|
data-ouia-safe="true"
|
|
524
545
|
type="number"
|
|
@@ -546,6 +567,9 @@ exports[`slider renders slider with input actions 1`] = `
|
|
|
546
567
|
<DocumentFragment>
|
|
547
568
|
<div
|
|
548
569
|
class="pf-v6-c-slider"
|
|
570
|
+
data-ouia-component-id="OUIA-Generated-Slider-:re:"
|
|
571
|
+
data-ouia-component-type="PF6/Slider"
|
|
572
|
+
data-ouia-safe="true"
|
|
549
573
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 1;"
|
|
550
574
|
>
|
|
551
575
|
<div
|
|
@@ -554,7 +578,7 @@ exports[`slider renders slider with input actions 1`] = `
|
|
|
554
578
|
<button
|
|
555
579
|
aria-label="Minus"
|
|
556
580
|
class="pf-v6-c-button pf-m-plain"
|
|
557
|
-
data-ouia-component-id="OUIA-Generated-Button-plain-:
|
|
581
|
+
data-ouia-component-id="OUIA-Generated-Button-plain-:rf:"
|
|
558
582
|
data-ouia-component-type="PF6/Button"
|
|
559
583
|
data-ouia-safe="true"
|
|
560
584
|
type="button"
|
|
@@ -613,7 +637,7 @@ exports[`slider renders slider with input actions 1`] = `
|
|
|
613
637
|
<button
|
|
614
638
|
aria-label="Plus"
|
|
615
639
|
class="pf-v6-c-button pf-m-plain"
|
|
616
|
-
data-ouia-component-id="OUIA-Generated-Button-plain-:
|
|
640
|
+
data-ouia-component-id="OUIA-Generated-Button-plain-:rg:"
|
|
617
641
|
data-ouia-component-type="PF6/Button"
|
|
618
642
|
data-ouia-safe="true"
|
|
619
643
|
type="button"
|
|
@@ -627,6 +651,9 @@ exports[`slider renders slider with tooltip on thumb 1`] = `
|
|
|
627
651
|
<DocumentFragment>
|
|
628
652
|
<div
|
|
629
653
|
class="pf-v6-c-slider"
|
|
654
|
+
data-ouia-component-id="OUIA-Generated-Slider-:ri:"
|
|
655
|
+
data-ouia-component-type="PF6/Slider"
|
|
656
|
+
data-ouia-safe="true"
|
|
630
657
|
style="--pf-v6-c-slider--value: 50%; --pf-v6-c-slider__value--c-form-control--width-chars: 1;"
|
|
631
658
|
>
|
|
632
659
|
<div
|
|
@@ -149,7 +149,7 @@ export const DashboardHeader: React.FC<DashboardHeaderProps> = ({ notificationBa
|
|
|
149
149
|
<ToolbarItem>
|
|
150
150
|
<NotificationBadge
|
|
151
151
|
aria-label="Notifications"
|
|
152
|
-
variant={NotificationBadgeVariant.
|
|
152
|
+
variant={NotificationBadgeVariant.plain}
|
|
153
153
|
onClick={() => {}}
|
|
154
154
|
/>
|
|
155
155
|
</ToolbarItem>
|