@patternfly/react-core 4.183.8 → 4.184.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.
- package/CHANGELOG.md +38 -0
- package/dist/esm/components/Dropdown/Dropdown.d.ts +2 -0
- package/dist/esm/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/esm/components/Dropdown/DropdownToggle.d.ts +2 -0
- package/dist/esm/components/Dropdown/DropdownToggle.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/DropdownToggle.js +3 -3
- package/dist/esm/components/Dropdown/DropdownToggle.js.map +1 -1
- package/dist/esm/components/Dropdown/DropdownWithContext.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/DropdownWithContext.js +4 -2
- package/dist/esm/components/Dropdown/DropdownWithContext.js.map +1 -1
- package/dist/esm/components/Dropdown/Toggle.d.ts +2 -0
- package/dist/esm/components/Dropdown/Toggle.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/Toggle.js +4 -3
- package/dist/esm/components/Dropdown/Toggle.js.map +1 -1
- package/dist/esm/components/Tabs/Tabs.d.ts.map +1 -1
- package/dist/esm/components/Tabs/Tabs.js +0 -2
- package/dist/esm/components/Tabs/Tabs.js.map +1 -1
- package/dist/js/components/Dropdown/Dropdown.d.ts +2 -0
- package/dist/js/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/js/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/js/components/Dropdown/DropdownToggle.d.ts +2 -0
- package/dist/js/components/Dropdown/DropdownToggle.d.ts.map +1 -1
- package/dist/js/components/Dropdown/DropdownToggle.js +3 -3
- package/dist/js/components/Dropdown/DropdownToggle.js.map +1 -1
- package/dist/js/components/Dropdown/DropdownWithContext.d.ts.map +1 -1
- package/dist/js/components/Dropdown/DropdownWithContext.js +4 -2
- package/dist/js/components/Dropdown/DropdownWithContext.js.map +1 -1
- package/dist/js/components/Dropdown/Toggle.d.ts +2 -0
- package/dist/js/components/Dropdown/Toggle.d.ts.map +1 -1
- package/dist/js/components/Dropdown/Toggle.js +4 -3
- package/dist/js/components/Dropdown/Toggle.js.map +1 -1
- package/dist/js/components/Tabs/Tabs.d.ts.map +1 -1
- package/dist/js/components/Tabs/Tabs.js +0 -2
- package/dist/js/components/Tabs/Tabs.js.map +1 -1
- package/dist/umd/react-core.css +1 -0
- package/dist/umd/react-core.js +11 -10
- package/dist/umd/react-core.min.css +180 -179
- package/dist/umd/react-core.min.js +2 -2
- package/package.json +6 -6
- package/src/components/ApplicationLauncher/__tests__/Generated/__snapshots__/ApplicationLauncher.test.tsx.snap +1 -0
- package/src/components/ApplicationLauncher/__tests__/__snapshots__/ApplicationLauncher.test.tsx.snap +18 -0
- package/src/components/Dropdown/Dropdown.tsx +2 -0
- package/src/components/Dropdown/DropdownToggle.tsx +4 -0
- package/src/components/Dropdown/DropdownWithContext.tsx +3 -0
- package/src/components/Dropdown/Toggle.tsx +5 -0
- package/src/components/Dropdown/__tests__/DropdownToggle.test.tsx +11 -0
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/Dropdown.test.tsx.snap +1 -0
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/KebabToggle.test.tsx.snap +1 -0
- package/src/components/Dropdown/__tests__/__snapshots__/Dropdown.test.tsx.snap +45 -0
- package/src/components/Dropdown/__tests__/__snapshots__/DropdownToggle.test.tsx.snap +94 -8
- package/src/components/Dropdown/__tests__/__snapshots__/Toggle.test.tsx.snap +2 -0
- package/src/components/Dropdown/examples/Dropdown.md +57 -0
- package/src/components/OptionsMenu/__tests__/Generated/__snapshots__/OptionsMenu.test.tsx.snap +1 -0
- package/src/components/OptionsMenu/__tests__/__snapshots__/OptionsMenu.test.tsx.snap +31 -0
- package/src/components/Pagination/__tests__/Generated/__snapshots__/PaginationOptionsMenu.test.tsx.snap +1 -0
- package/src/components/Pagination/__tests__/__snapshots__/Pagination.test.tsx.snap +47 -0
- package/src/components/Tabs/Tabs.tsx +0 -2
- package/src/components/Tabs/examples/Tabs.md +6 -6
- package/src/components/TextInputGroup/examples/TextInputGroup.md +4 -123
- package/src/components/TextInputGroup/examples/TextInputGroupBasic.tsx +8 -0
- package/src/components/TextInputGroup/examples/TextInputGroupDisabled.tsx +8 -0
- package/src/components/TextInputGroup/examples/TextInputGroupFilters.tsx +69 -0
- package/src/components/TextInputGroup/examples/TextInputGroupUtilitiesAndIcon.tsx +34 -0
- package/src/demos/TextInputGroupDemo.md +2 -2
- package/src/demos/examples/TextInputGroup/{AttributeValueFiltering.js → AttributeValueFiltering.tsx} +22 -18
- package/src/demos/examples/TextInputGroup/{AutoCompleteSearch.js → AutoCompleteSearch.tsx} +18 -18
|
@@ -171,6 +171,7 @@ exports[`component render custom pagination toggle 1`] = `
|
|
|
171
171
|
isGrouped={false}
|
|
172
172
|
isOpen={false}
|
|
173
173
|
isPlain={true}
|
|
174
|
+
isText={false}
|
|
174
175
|
menuAppendTo="inline"
|
|
175
176
|
onSelect={[Function]}
|
|
176
177
|
position="left"
|
|
@@ -206,6 +207,7 @@ exports[`component render custom pagination toggle 1`] = `
|
|
|
206
207
|
isDisabled={false}
|
|
207
208
|
isOpen={false}
|
|
208
209
|
isPlain={true}
|
|
210
|
+
isText={false}
|
|
209
211
|
itemCount={40}
|
|
210
212
|
itemsPerPageTitle="Items per page"
|
|
211
213
|
itemsTitle=""
|
|
@@ -345,6 +347,7 @@ exports[`component render custom pagination toggle 1`] = `
|
|
|
345
347
|
isPlain={false}
|
|
346
348
|
isPrimary={false}
|
|
347
349
|
isSplitButton={false}
|
|
350
|
+
isText={false}
|
|
348
351
|
onEnter={[Function]}
|
|
349
352
|
onToggle={[Function]}
|
|
350
353
|
parentRef={
|
|
@@ -869,6 +872,7 @@ exports[`component render custom perPageOptions 1`] = `
|
|
|
869
872
|
isGrouped={false}
|
|
870
873
|
isOpen={false}
|
|
871
874
|
isPlain={true}
|
|
875
|
+
isText={false}
|
|
872
876
|
menuAppendTo="inline"
|
|
873
877
|
onSelect={[Function]}
|
|
874
878
|
position="left"
|
|
@@ -904,6 +908,7 @@ exports[`component render custom perPageOptions 1`] = `
|
|
|
904
908
|
isDisabled={false}
|
|
905
909
|
isOpen={false}
|
|
906
910
|
isPlain={true}
|
|
911
|
+
isText={false}
|
|
907
912
|
itemCount={40}
|
|
908
913
|
itemsPerPageTitle="Items per page"
|
|
909
914
|
itemsTitle=""
|
|
@@ -1086,6 +1091,7 @@ exports[`component render custom perPageOptions 1`] = `
|
|
|
1086
1091
|
isPlain={false}
|
|
1087
1092
|
isPrimary={false}
|
|
1088
1093
|
isSplitButton={false}
|
|
1094
|
+
isText={false}
|
|
1089
1095
|
onEnter={[Function]}
|
|
1090
1096
|
onToggle={[Function]}
|
|
1091
1097
|
parentRef={
|
|
@@ -1682,6 +1688,7 @@ exports[`component render custom start end 1`] = `
|
|
|
1682
1688
|
isGrouped={false}
|
|
1683
1689
|
isOpen={false}
|
|
1684
1690
|
isPlain={true}
|
|
1691
|
+
isText={false}
|
|
1685
1692
|
menuAppendTo="inline"
|
|
1686
1693
|
onSelect={[Function]}
|
|
1687
1694
|
position="left"
|
|
@@ -1717,6 +1724,7 @@ exports[`component render custom start end 1`] = `
|
|
|
1717
1724
|
isDisabled={false}
|
|
1718
1725
|
isOpen={false}
|
|
1719
1726
|
isPlain={true}
|
|
1727
|
+
isText={false}
|
|
1720
1728
|
itemCount={40}
|
|
1721
1729
|
itemsPerPageTitle="Items per page"
|
|
1722
1730
|
itemsTitle=""
|
|
@@ -1899,6 +1907,7 @@ exports[`component render custom start end 1`] = `
|
|
|
1899
1907
|
isPlain={false}
|
|
1900
1908
|
isPrimary={false}
|
|
1901
1909
|
isSplitButton={false}
|
|
1910
|
+
isText={false}
|
|
1902
1911
|
onEnter={[Function]}
|
|
1903
1912
|
onToggle={[Function]}
|
|
1904
1913
|
parentRef={
|
|
@@ -2407,6 +2416,7 @@ exports[`component render empty per page options 1`] = `
|
|
|
2407
2416
|
isGrouped={false}
|
|
2408
2417
|
isOpen={false}
|
|
2409
2418
|
isPlain={true}
|
|
2419
|
+
isText={false}
|
|
2410
2420
|
menuAppendTo="inline"
|
|
2411
2421
|
onSelect={[Function]}
|
|
2412
2422
|
position="left"
|
|
@@ -2442,6 +2452,7 @@ exports[`component render empty per page options 1`] = `
|
|
|
2442
2452
|
isDisabled={false}
|
|
2443
2453
|
isOpen={false}
|
|
2444
2454
|
isPlain={true}
|
|
2455
|
+
isText={false}
|
|
2445
2456
|
itemCount={40}
|
|
2446
2457
|
itemsPerPageTitle="Items per page"
|
|
2447
2458
|
itemsTitle=""
|
|
@@ -2985,6 +2996,7 @@ exports[`component render last page 1`] = `
|
|
|
2985
2996
|
isGrouped={false}
|
|
2986
2997
|
isOpen={false}
|
|
2987
2998
|
isPlain={true}
|
|
2999
|
+
isText={false}
|
|
2988
3000
|
menuAppendTo="inline"
|
|
2989
3001
|
onSelect={[Function]}
|
|
2990
3002
|
position="left"
|
|
@@ -3020,6 +3032,7 @@ exports[`component render last page 1`] = `
|
|
|
3020
3032
|
isDisabled={false}
|
|
3021
3033
|
isOpen={false}
|
|
3022
3034
|
isPlain={true}
|
|
3035
|
+
isText={false}
|
|
3023
3036
|
itemCount={20}
|
|
3024
3037
|
itemsPerPageTitle="Items per page"
|
|
3025
3038
|
itemsTitle=""
|
|
@@ -3202,6 +3215,7 @@ exports[`component render last page 1`] = `
|
|
|
3202
3215
|
isPlain={false}
|
|
3203
3216
|
isPrimary={false}
|
|
3204
3217
|
isSplitButton={false}
|
|
3218
|
+
isText={false}
|
|
3205
3219
|
onEnter={[Function]}
|
|
3206
3220
|
onToggle={[Function]}
|
|
3207
3221
|
parentRef={
|
|
@@ -3798,6 +3812,7 @@ exports[`component render limited number of pages 1`] = `
|
|
|
3798
3812
|
isGrouped={false}
|
|
3799
3813
|
isOpen={false}
|
|
3800
3814
|
isPlain={true}
|
|
3815
|
+
isText={false}
|
|
3801
3816
|
menuAppendTo="inline"
|
|
3802
3817
|
onSelect={[Function]}
|
|
3803
3818
|
position="left"
|
|
@@ -3833,6 +3848,7 @@ exports[`component render limited number of pages 1`] = `
|
|
|
3833
3848
|
isDisabled={false}
|
|
3834
3849
|
isOpen={false}
|
|
3835
3850
|
isPlain={true}
|
|
3851
|
+
isText={false}
|
|
3836
3852
|
itemCount={20}
|
|
3837
3853
|
itemsPerPageTitle="Items per page"
|
|
3838
3854
|
itemsTitle=""
|
|
@@ -4015,6 +4031,7 @@ exports[`component render limited number of pages 1`] = `
|
|
|
4015
4031
|
isPlain={false}
|
|
4016
4032
|
isPrimary={false}
|
|
4017
4033
|
isSplitButton={false}
|
|
4034
|
+
isText={false}
|
|
4018
4035
|
onEnter={[Function]}
|
|
4019
4036
|
onToggle={[Function]}
|
|
4020
4037
|
parentRef={
|
|
@@ -4613,6 +4630,7 @@ exports[`component render no items 1`] = `
|
|
|
4613
4630
|
isGrouped={false}
|
|
4614
4631
|
isOpen={false}
|
|
4615
4632
|
isPlain={true}
|
|
4633
|
+
isText={false}
|
|
4616
4634
|
menuAppendTo="inline"
|
|
4617
4635
|
onSelect={[Function]}
|
|
4618
4636
|
position="left"
|
|
@@ -4648,6 +4666,7 @@ exports[`component render no items 1`] = `
|
|
|
4648
4666
|
isDisabled={false}
|
|
4649
4667
|
isOpen={false}
|
|
4650
4668
|
isPlain={true}
|
|
4669
|
+
isText={false}
|
|
4651
4670
|
itemCount={0}
|
|
4652
4671
|
itemsPerPageTitle="Items per page"
|
|
4653
4672
|
itemsTitle=""
|
|
@@ -4830,6 +4849,7 @@ exports[`component render no items 1`] = `
|
|
|
4830
4849
|
isPlain={false}
|
|
4831
4850
|
isPrimary={false}
|
|
4832
4851
|
isSplitButton={false}
|
|
4852
|
+
isText={false}
|
|
4833
4853
|
onEnter={[Function]}
|
|
4834
4854
|
onToggle={[Function]}
|
|
4835
4855
|
parentRef={
|
|
@@ -5404,6 +5424,7 @@ exports[`component render should render correctly bottom 1`] = `
|
|
|
5404
5424
|
isGrouped={false}
|
|
5405
5425
|
isOpen={false}
|
|
5406
5426
|
isPlain={true}
|
|
5427
|
+
isText={false}
|
|
5407
5428
|
menuAppendTo="inline"
|
|
5408
5429
|
onSelect={[Function]}
|
|
5409
5430
|
position="left"
|
|
@@ -5439,6 +5460,7 @@ exports[`component render should render correctly bottom 1`] = `
|
|
|
5439
5460
|
isDisabled={false}
|
|
5440
5461
|
isOpen={false}
|
|
5441
5462
|
isPlain={true}
|
|
5463
|
+
isText={false}
|
|
5442
5464
|
itemCount={20}
|
|
5443
5465
|
itemsPerPageTitle="Items per page"
|
|
5444
5466
|
itemsTitle=""
|
|
@@ -5621,6 +5643,7 @@ exports[`component render should render correctly bottom 1`] = `
|
|
|
5621
5643
|
isPlain={false}
|
|
5622
5644
|
isPrimary={false}
|
|
5623
5645
|
isSplitButton={false}
|
|
5646
|
+
isText={false}
|
|
5624
5647
|
onEnter={[Function]}
|
|
5625
5648
|
onToggle={[Function]}
|
|
5626
5649
|
parentRef={
|
|
@@ -6193,6 +6216,7 @@ exports[`component render should render correctly bottom sticky 1`] = `
|
|
|
6193
6216
|
isGrouped={false}
|
|
6194
6217
|
isOpen={false}
|
|
6195
6218
|
isPlain={true}
|
|
6219
|
+
isText={false}
|
|
6196
6220
|
menuAppendTo="inline"
|
|
6197
6221
|
onSelect={[Function]}
|
|
6198
6222
|
position="left"
|
|
@@ -6228,6 +6252,7 @@ exports[`component render should render correctly bottom sticky 1`] = `
|
|
|
6228
6252
|
isDisabled={false}
|
|
6229
6253
|
isOpen={false}
|
|
6230
6254
|
isPlain={true}
|
|
6255
|
+
isText={false}
|
|
6231
6256
|
itemCount={20}
|
|
6232
6257
|
itemsPerPageTitle="Items per page"
|
|
6233
6258
|
itemsTitle=""
|
|
@@ -6410,6 +6435,7 @@ exports[`component render should render correctly bottom sticky 1`] = `
|
|
|
6410
6435
|
isPlain={false}
|
|
6411
6436
|
isPrimary={false}
|
|
6412
6437
|
isSplitButton={false}
|
|
6438
|
+
isText={false}
|
|
6413
6439
|
onEnter={[Function]}
|
|
6414
6440
|
onToggle={[Function]}
|
|
6415
6441
|
parentRef={
|
|
@@ -7006,6 +7032,7 @@ exports[`component render should render correctly compact 1`] = `
|
|
|
7006
7032
|
isGrouped={false}
|
|
7007
7033
|
isOpen={false}
|
|
7008
7034
|
isPlain={true}
|
|
7035
|
+
isText={false}
|
|
7009
7036
|
menuAppendTo="inline"
|
|
7010
7037
|
onSelect={[Function]}
|
|
7011
7038
|
position="left"
|
|
@@ -7041,6 +7068,7 @@ exports[`component render should render correctly compact 1`] = `
|
|
|
7041
7068
|
isDisabled={false}
|
|
7042
7069
|
isOpen={false}
|
|
7043
7070
|
isPlain={true}
|
|
7071
|
+
isText={false}
|
|
7044
7072
|
itemCount={20}
|
|
7045
7073
|
itemsPerPageTitle="Items per page"
|
|
7046
7074
|
itemsTitle=""
|
|
@@ -7223,6 +7251,7 @@ exports[`component render should render correctly compact 1`] = `
|
|
|
7223
7251
|
isPlain={false}
|
|
7224
7252
|
isPrimary={false}
|
|
7225
7253
|
isSplitButton={false}
|
|
7254
|
+
isText={false}
|
|
7226
7255
|
onEnter={[Function]}
|
|
7227
7256
|
onToggle={[Function]}
|
|
7228
7257
|
parentRef={
|
|
@@ -7678,6 +7707,7 @@ exports[`component render should render correctly disabled 1`] = `
|
|
|
7678
7707
|
isGrouped={false}
|
|
7679
7708
|
isOpen={false}
|
|
7680
7709
|
isPlain={true}
|
|
7710
|
+
isText={false}
|
|
7681
7711
|
menuAppendTo="inline"
|
|
7682
7712
|
onSelect={[Function]}
|
|
7683
7713
|
position="left"
|
|
@@ -7713,6 +7743,7 @@ exports[`component render should render correctly disabled 1`] = `
|
|
|
7713
7743
|
isDisabled={true}
|
|
7714
7744
|
isOpen={false}
|
|
7715
7745
|
isPlain={true}
|
|
7746
|
+
isText={false}
|
|
7716
7747
|
itemCount={20}
|
|
7717
7748
|
itemsPerPageTitle="Items per page"
|
|
7718
7749
|
itemsTitle=""
|
|
@@ -7897,6 +7928,7 @@ exports[`component render should render correctly disabled 1`] = `
|
|
|
7897
7928
|
isPlain={false}
|
|
7898
7929
|
isPrimary={false}
|
|
7899
7930
|
isSplitButton={false}
|
|
7931
|
+
isText={false}
|
|
7900
7932
|
onEnter={[Function]}
|
|
7901
7933
|
onToggle={[Function]}
|
|
7902
7934
|
parentRef={
|
|
@@ -8496,6 +8528,7 @@ exports[`component render should render correctly sticky 1`] = `
|
|
|
8496
8528
|
isGrouped={false}
|
|
8497
8529
|
isOpen={false}
|
|
8498
8530
|
isPlain={true}
|
|
8531
|
+
isText={false}
|
|
8499
8532
|
menuAppendTo="inline"
|
|
8500
8533
|
onSelect={[Function]}
|
|
8501
8534
|
position="left"
|
|
@@ -8531,6 +8564,7 @@ exports[`component render should render correctly sticky 1`] = `
|
|
|
8531
8564
|
isDisabled={false}
|
|
8532
8565
|
isOpen={false}
|
|
8533
8566
|
isPlain={true}
|
|
8567
|
+
isText={false}
|
|
8534
8568
|
itemCount={20}
|
|
8535
8569
|
itemsPerPageTitle="Items per page"
|
|
8536
8570
|
itemsTitle=""
|
|
@@ -8713,6 +8747,7 @@ exports[`component render should render correctly sticky 1`] = `
|
|
|
8713
8747
|
isPlain={false}
|
|
8714
8748
|
isPrimary={false}
|
|
8715
8749
|
isSplitButton={false}
|
|
8750
|
+
isText={false}
|
|
8716
8751
|
onEnter={[Function]}
|
|
8717
8752
|
onToggle={[Function]}
|
|
8718
8753
|
parentRef={
|
|
@@ -9309,6 +9344,7 @@ exports[`component render should render correctly top 1`] = `
|
|
|
9309
9344
|
isGrouped={false}
|
|
9310
9345
|
isOpen={false}
|
|
9311
9346
|
isPlain={true}
|
|
9347
|
+
isText={false}
|
|
9312
9348
|
menuAppendTo="inline"
|
|
9313
9349
|
onSelect={[Function]}
|
|
9314
9350
|
position="left"
|
|
@@ -9344,6 +9380,7 @@ exports[`component render should render correctly top 1`] = `
|
|
|
9344
9380
|
isDisabled={false}
|
|
9345
9381
|
isOpen={false}
|
|
9346
9382
|
isPlain={true}
|
|
9383
|
+
isText={false}
|
|
9347
9384
|
itemCount={20}
|
|
9348
9385
|
itemsPerPageTitle="Items per page"
|
|
9349
9386
|
itemsTitle=""
|
|
@@ -9526,6 +9563,7 @@ exports[`component render should render correctly top 1`] = `
|
|
|
9526
9563
|
isPlain={false}
|
|
9527
9564
|
isPrimary={false}
|
|
9528
9565
|
isSplitButton={false}
|
|
9566
|
+
isText={false}
|
|
9529
9567
|
onEnter={[Function]}
|
|
9530
9568
|
onToggle={[Function]}
|
|
9531
9569
|
parentRef={
|
|
@@ -10111,6 +10149,7 @@ exports[`component render titles 1`] = `
|
|
|
10111
10149
|
isGrouped={false}
|
|
10112
10150
|
isOpen={false}
|
|
10113
10151
|
isPlain={true}
|
|
10152
|
+
isText={false}
|
|
10114
10153
|
menuAppendTo="inline"
|
|
10115
10154
|
onSelect={[Function]}
|
|
10116
10155
|
position="left"
|
|
@@ -10146,6 +10185,7 @@ exports[`component render titles 1`] = `
|
|
|
10146
10185
|
isDisabled={false}
|
|
10147
10186
|
isOpen={false}
|
|
10148
10187
|
isPlain={true}
|
|
10188
|
+
isText={false}
|
|
10149
10189
|
itemCount={40}
|
|
10150
10190
|
itemsPerPageTitle="Items per page"
|
|
10151
10191
|
itemsTitle="values"
|
|
@@ -10329,6 +10369,7 @@ exports[`component render titles 1`] = `
|
|
|
10329
10369
|
isPlain={false}
|
|
10330
10370
|
isPrimary={false}
|
|
10331
10371
|
isSplitButton={false}
|
|
10372
|
+
isText={false}
|
|
10332
10373
|
onEnter={[Function]}
|
|
10333
10374
|
onToggle={[Function]}
|
|
10334
10375
|
parentRef={
|
|
@@ -10954,6 +10995,7 @@ exports[`component render up drop direction 1`] = `
|
|
|
10954
10995
|
isGrouped={false}
|
|
10955
10996
|
isOpen={false}
|
|
10956
10997
|
isPlain={true}
|
|
10998
|
+
isText={false}
|
|
10957
10999
|
menuAppendTo="inline"
|
|
10958
11000
|
onSelect={[Function]}
|
|
10959
11001
|
position="left"
|
|
@@ -10989,6 +11031,7 @@ exports[`component render up drop direction 1`] = `
|
|
|
10989
11031
|
isDisabled={false}
|
|
10990
11032
|
isOpen={false}
|
|
10991
11033
|
isPlain={true}
|
|
11034
|
+
isText={false}
|
|
10992
11035
|
itemCount={40}
|
|
10993
11036
|
itemsPerPageTitle="Items per page"
|
|
10994
11037
|
itemsTitle=""
|
|
@@ -11171,6 +11214,7 @@ exports[`component render up drop direction 1`] = `
|
|
|
11171
11214
|
isPlain={false}
|
|
11172
11215
|
isPrimary={false}
|
|
11173
11216
|
isSplitButton={false}
|
|
11217
|
+
isText={false}
|
|
11174
11218
|
onEnter={[Function]}
|
|
11175
11219
|
onToggle={[Function]}
|
|
11176
11220
|
parentRef={
|
|
@@ -11767,6 +11811,7 @@ exports[`component render zero results 1`] = `
|
|
|
11767
11811
|
isGrouped={false}
|
|
11768
11812
|
isOpen={false}
|
|
11769
11813
|
isPlain={true}
|
|
11814
|
+
isText={false}
|
|
11770
11815
|
menuAppendTo="inline"
|
|
11771
11816
|
onSelect={[Function]}
|
|
11772
11817
|
position="left"
|
|
@@ -11802,6 +11847,7 @@ exports[`component render zero results 1`] = `
|
|
|
11802
11847
|
isDisabled={false}
|
|
11803
11848
|
isOpen={false}
|
|
11804
11849
|
isPlain={true}
|
|
11850
|
+
isText={false}
|
|
11805
11851
|
itemCount={0}
|
|
11806
11852
|
itemsPerPageTitle="Items per page"
|
|
11807
11853
|
itemsTitle=""
|
|
@@ -11984,6 +12030,7 @@ exports[`component render zero results 1`] = `
|
|
|
11984
12030
|
isPlain={false}
|
|
11985
12031
|
isPrimary={false}
|
|
11986
12032
|
isSplitButton={false}
|
|
12033
|
+
isText={false}
|
|
11987
12034
|
onEnter={[Function]}
|
|
11988
12035
|
onToggle={[Function]}
|
|
11989
12036
|
parentRef={
|
|
@@ -149,8 +149,6 @@ export class Tabs extends React.Component<TabsProps, TabsState> {
|
|
|
149
149
|
eventKey: number | string,
|
|
150
150
|
tabContentRef: React.RefObject<any>
|
|
151
151
|
) {
|
|
152
|
-
// When tab is an achor tag with href, cancel navigation event
|
|
153
|
-
event.preventDefault();
|
|
154
152
|
const { shownKeys } = this.state;
|
|
155
153
|
const { onSelect, defaultActiveKey } = this.props;
|
|
156
154
|
// if defaultActiveKey Tabs are uncontrolled, set new active key internally
|
|
@@ -890,22 +890,22 @@ class TabsNav extends React.Component {
|
|
|
890
890
|
aria-label="Local"
|
|
891
891
|
component={TabsComponent.nav}
|
|
892
892
|
>
|
|
893
|
-
<Tab eventKey={0} title={<TabTitleText>Users</TabTitleText>} href="#">
|
|
893
|
+
<Tab eventKey={0} title={<TabTitleText>Users</TabTitleText>} href="#users">
|
|
894
894
|
Users
|
|
895
895
|
</Tab>
|
|
896
|
-
<Tab eventKey={1} title={<TabTitleText>Containers</TabTitleText>} href="#">
|
|
896
|
+
<Tab eventKey={1} title={<TabTitleText>Containers</TabTitleText>} href="#containers">
|
|
897
897
|
Containers
|
|
898
898
|
</Tab>
|
|
899
|
-
<Tab eventKey={2} title={<TabTitleText>Database</TabTitleText>} href="#">
|
|
899
|
+
<Tab eventKey={2} title={<TabTitleText>Database</TabTitleText>} href="#database">
|
|
900
900
|
Database
|
|
901
901
|
</Tab>
|
|
902
|
-
<Tab eventKey={3} title={<TabTitleText>Disabled</TabTitleText>} isDisabled href="#">
|
|
902
|
+
<Tab eventKey={3} title={<TabTitleText>Disabled</TabTitleText>} isDisabled href="#disabled">
|
|
903
903
|
Disabled
|
|
904
904
|
</Tab>
|
|
905
|
-
<Tab eventKey={4} title={<TabTitleText>ARIA Disabled</TabTitleText>} isAriaDisabled href="#">
|
|
905
|
+
<Tab eventKey={4} title={<TabTitleText>ARIA Disabled</TabTitleText>} isAriaDisabled href="#aria-disabled">
|
|
906
906
|
ARIA Disabled
|
|
907
907
|
</Tab>
|
|
908
|
-
<Tab eventKey={6} title={<TabTitleText>Network</TabTitleText>} href="#">
|
|
908
|
+
<Tab eventKey={6} title={<TabTitleText>Network</TabTitleText>} href="#network">
|
|
909
909
|
Network
|
|
910
910
|
</Tab>
|
|
911
911
|
</Tabs>
|
|
@@ -13,139 +13,20 @@ import TimesIcon from '@patternfly/react-icons/dist/esm/icons/times-icon';
|
|
|
13
13
|
|
|
14
14
|
### Basic
|
|
15
15
|
|
|
16
|
-
```
|
|
17
|
-
import React from 'react';
|
|
18
|
-
import { TextInputGroup, TextInputGroupMain } from '@patternfly/react-core';
|
|
19
|
-
|
|
20
|
-
const BasicTextInputGroup = () => (
|
|
21
|
-
<TextInputGroup>
|
|
22
|
-
<TextInputGroupMain />
|
|
23
|
-
</TextInputGroup>
|
|
24
|
-
);
|
|
16
|
+
```ts file="./TextInputGroupBasic.tsx"
|
|
25
17
|
```
|
|
26
18
|
|
|
27
19
|
### Disabled
|
|
28
20
|
|
|
29
|
-
```
|
|
30
|
-
import React from 'react';
|
|
31
|
-
import { TextInputGroup, TextInputGroupMain } from '@patternfly/react-core';
|
|
32
|
-
|
|
33
|
-
const DisabledTextInputGroup = () => (
|
|
34
|
-
<TextInputGroup isDisabled>
|
|
35
|
-
<TextInputGroupMain value="Disabled" type="text" aria-label="Disabled text input group example input" />
|
|
36
|
-
</TextInputGroup>
|
|
37
|
-
);
|
|
21
|
+
```ts file="./TextInputGroupDisabled.tsx"
|
|
38
22
|
```
|
|
39
23
|
|
|
40
24
|
### Utilities and icon
|
|
41
25
|
|
|
42
|
-
```
|
|
43
|
-
import React from 'react';
|
|
44
|
-
import { TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, Button } from '@patternfly/react-core';
|
|
45
|
-
import SearchIcon from '@patternfly/react-icons/dist/esm/icons/search-icon';
|
|
46
|
-
import TimesIcon from '@patternfly/react-icons/dist/esm/icons/times-icon';
|
|
47
|
-
|
|
48
|
-
const TextInputGroupWithIcons = () => {
|
|
49
|
-
const [inputValue, setInputValue] = React.useState('');
|
|
50
|
-
|
|
51
|
-
/** callback for updating the inputValue state in this component so that the input can be controlled */
|
|
52
|
-
const handleInputChange = (value, _event) => {
|
|
53
|
-
setInputValue(value);
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
/** show the input clearing button only when the input is not empty */
|
|
57
|
-
const showClearButton = inputValue;
|
|
58
|
-
|
|
59
|
-
/** callback for clearing the text input */
|
|
60
|
-
const clearInput = () => {
|
|
61
|
-
setInputValue('');
|
|
62
|
-
};
|
|
63
|
-
|
|
64
|
-
return (
|
|
65
|
-
<TextInputGroup>
|
|
66
|
-
<TextInputGroupMain icon={<SearchIcon />} value={inputValue} onChange={handleInputChange} />
|
|
67
|
-
<TextInputGroupUtilities>
|
|
68
|
-
{showClearButton && (
|
|
69
|
-
<Button variant="plain" onClick={clearInput} aria-label="Clear button and input">
|
|
70
|
-
<TimesIcon />
|
|
71
|
-
</Button>
|
|
72
|
-
)}
|
|
73
|
-
</TextInputGroupUtilities>
|
|
74
|
-
</TextInputGroup>
|
|
75
|
-
);
|
|
76
|
-
};
|
|
26
|
+
```ts file="./TextInputGroupUtilitiesAndIcon.tsx"
|
|
77
27
|
```
|
|
78
28
|
|
|
79
29
|
### Filters
|
|
80
30
|
|
|
81
|
-
```
|
|
82
|
-
import React from 'react';
|
|
83
|
-
import { TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, Button } from '@patternfly/react-core';
|
|
84
|
-
import { Chip, ChipGroup } from '@patternfly/react-core';
|
|
85
|
-
import SearchIcon from '@patternfly/react-icons/dist/esm/icons/search-icon';
|
|
86
|
-
import TimesIcon from '@patternfly/react-icons/dist/esm/icons/times-icon';
|
|
87
|
-
|
|
88
|
-
const TextInputGroupWithChips = () => {
|
|
89
|
-
const [inputValue, setInputValue] = React.useState('');
|
|
90
|
-
const [currentChips, setCurrentChips] = React.useState([
|
|
91
|
-
'chip one',
|
|
92
|
-
'chip two',
|
|
93
|
-
'chip three',
|
|
94
|
-
'chip four',
|
|
95
|
-
'chip five',
|
|
96
|
-
'chip six',
|
|
97
|
-
'chip seven',
|
|
98
|
-
'chip eight',
|
|
99
|
-
'chip nine',
|
|
100
|
-
'chip ten',
|
|
101
|
-
'chip eleven',
|
|
102
|
-
'chip twelve',
|
|
103
|
-
'chip thirteen',
|
|
104
|
-
'chip fourteen'
|
|
105
|
-
]);
|
|
106
|
-
|
|
107
|
-
/** show the search icon only when there are no chips to prevent the chips from being displayed behind the icon */
|
|
108
|
-
const showSearchIcon = !currentChips.length;
|
|
109
|
-
|
|
110
|
-
/** callback for updating the inputValue state in this component so that the input can be controlled */
|
|
111
|
-
const handleInputChange = (value, _event) => {
|
|
112
|
-
setInputValue(value);
|
|
113
|
-
};
|
|
114
|
-
|
|
115
|
-
/** callback for removing a chip from the chip selections */
|
|
116
|
-
const deleteChip = chipToDelete => {
|
|
117
|
-
const newChips = currentChips.filter(chip => !Object.is(chip, chipToDelete));
|
|
118
|
-
setCurrentChips(newChips);
|
|
119
|
-
};
|
|
120
|
-
|
|
121
|
-
/** show the input/chip clearing button only when either the text input or chip group are not empty */
|
|
122
|
-
const showClearButton = inputValue || !!currentChips.length;
|
|
123
|
-
|
|
124
|
-
/** callback for clearing all selected chips and the text input */
|
|
125
|
-
const clearChipsAndInput = () => {
|
|
126
|
-
setCurrentChips([]);
|
|
127
|
-
setInputValue('');
|
|
128
|
-
};
|
|
129
|
-
|
|
130
|
-
return (
|
|
131
|
-
<TextInputGroup>
|
|
132
|
-
<TextInputGroupMain icon={showSearchIcon && <SearchIcon />} value={inputValue} onChange={handleInputChange}>
|
|
133
|
-
<ChipGroup>
|
|
134
|
-
{currentChips.map(currentChip => (
|
|
135
|
-
<Chip key={currentChip} onClick={() => deleteChip(currentChip)}>
|
|
136
|
-
{currentChip}
|
|
137
|
-
</Chip>
|
|
138
|
-
))}
|
|
139
|
-
</ChipGroup>
|
|
140
|
-
</TextInputGroupMain>
|
|
141
|
-
<TextInputGroupUtilities>
|
|
142
|
-
{showClearButton && (
|
|
143
|
-
<Button variant="plain" onClick={clearChipsAndInput} aria-label="Clear button and input">
|
|
144
|
-
<TimesIcon />
|
|
145
|
-
</Button>
|
|
146
|
-
)}
|
|
147
|
-
</TextInputGroupUtilities>
|
|
148
|
-
</TextInputGroup>
|
|
149
|
-
);
|
|
150
|
-
};
|
|
31
|
+
```ts file="./TextInputGroupFilters.tsx"
|
|
151
32
|
```
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { TextInputGroup, TextInputGroupMain } from '@patternfly/react-core';
|
|
3
|
+
|
|
4
|
+
export const TextInputGroupDisabled: React.FunctionComponent = () => (
|
|
5
|
+
<TextInputGroup isDisabled>
|
|
6
|
+
<TextInputGroupMain value="Disabled" type="text" aria-label="Disabled text input group example input" />
|
|
7
|
+
</TextInputGroup>
|
|
8
|
+
);
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, Button } from '@patternfly/react-core';
|
|
3
|
+
import { Chip, ChipGroup } from '@patternfly/react-core';
|
|
4
|
+
import SearchIcon from '@patternfly/react-icons/dist/esm/icons/search-icon';
|
|
5
|
+
import TimesIcon from '@patternfly/react-icons/dist/esm/icons/times-icon';
|
|
6
|
+
|
|
7
|
+
export const TextInputGroupFilters: React.FunctionComponent = () => {
|
|
8
|
+
const [inputValue, setInputValue] = React.useState('');
|
|
9
|
+
const [currentChips, setCurrentChips] = React.useState([
|
|
10
|
+
'chip one',
|
|
11
|
+
'chip two',
|
|
12
|
+
'chip three',
|
|
13
|
+
'chip four',
|
|
14
|
+
'chip five',
|
|
15
|
+
'chip six',
|
|
16
|
+
'chip seven',
|
|
17
|
+
'chip eight',
|
|
18
|
+
'chip nine',
|
|
19
|
+
'chip ten',
|
|
20
|
+
'chip eleven',
|
|
21
|
+
'chip twelve',
|
|
22
|
+
'chip thirteen',
|
|
23
|
+
'chip fourteen'
|
|
24
|
+
]);
|
|
25
|
+
|
|
26
|
+
/** show the search icon only when there are no chips to prevent the chips from being displayed behind the icon */
|
|
27
|
+
const showSearchIcon = !currentChips.length;
|
|
28
|
+
|
|
29
|
+
/** callback for updating the inputValue state in this component so that the input can be controlled */
|
|
30
|
+
const handleInputChange = (value: string, _event: React.FormEvent<HTMLInputElement>) => {
|
|
31
|
+
setInputValue(value);
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
/** callback for removing a chip from the chip selections */
|
|
35
|
+
const deleteChip = (chipToDelete: string) => {
|
|
36
|
+
const newChips = currentChips.filter(chip => !Object.is(chip, chipToDelete));
|
|
37
|
+
setCurrentChips(newChips);
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
/** show the input/chip clearing button only when either the text input or chip group are not empty */
|
|
41
|
+
const showClearButton = !!inputValue || !!currentChips.length;
|
|
42
|
+
|
|
43
|
+
/** callback for clearing all selected chips and the text input */
|
|
44
|
+
const clearChipsAndInput = () => {
|
|
45
|
+
setCurrentChips([]);
|
|
46
|
+
setInputValue('');
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
return (
|
|
50
|
+
<TextInputGroup>
|
|
51
|
+
<TextInputGroupMain icon={showSearchIcon && <SearchIcon />} value={inputValue} onChange={handleInputChange}>
|
|
52
|
+
<ChipGroup>
|
|
53
|
+
{currentChips.map(currentChip => (
|
|
54
|
+
<Chip key={currentChip} onClick={() => deleteChip(currentChip)}>
|
|
55
|
+
{currentChip}
|
|
56
|
+
</Chip>
|
|
57
|
+
))}
|
|
58
|
+
</ChipGroup>
|
|
59
|
+
</TextInputGroupMain>
|
|
60
|
+
<TextInputGroupUtilities>
|
|
61
|
+
{showClearButton && (
|
|
62
|
+
<Button variant="plain" onClick={clearChipsAndInput} aria-label="Clear button and input">
|
|
63
|
+
<TimesIcon />
|
|
64
|
+
</Button>
|
|
65
|
+
)}
|
|
66
|
+
</TextInputGroupUtilities>
|
|
67
|
+
</TextInputGroup>
|
|
68
|
+
);
|
|
69
|
+
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { TextInputGroup, TextInputGroupMain, TextInputGroupUtilities, Button } from '@patternfly/react-core';
|
|
3
|
+
import SearchIcon from '@patternfly/react-icons/dist/esm/icons/search-icon';
|
|
4
|
+
import TimesIcon from '@patternfly/react-icons/dist/esm/icons/times-icon';
|
|
5
|
+
|
|
6
|
+
export const TextInputGroupUtilitiesAndIcon: React.FunctionComponent = () => {
|
|
7
|
+
const [inputValue, setInputValue] = React.useState('');
|
|
8
|
+
|
|
9
|
+
/** callback for updating the inputValue state in this component so that the input can be controlled */
|
|
10
|
+
const handleInputChange = (value: string, _event: React.FormEvent<HTMLInputElement>) => {
|
|
11
|
+
setInputValue(value);
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
/** show the input clearing button only when the input is not empty */
|
|
15
|
+
const showClearButton = !!inputValue;
|
|
16
|
+
|
|
17
|
+
/** callback for clearing the text input */
|
|
18
|
+
const clearInput = () => {
|
|
19
|
+
setInputValue('');
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
return (
|
|
23
|
+
<TextInputGroup>
|
|
24
|
+
<TextInputGroupMain icon={<SearchIcon />} value={inputValue} onChange={handleInputChange} />
|
|
25
|
+
<TextInputGroupUtilities>
|
|
26
|
+
{showClearButton && (
|
|
27
|
+
<Button variant="plain" onClick={clearInput} aria-label="Clear button and input">
|
|
28
|
+
<TimesIcon />
|
|
29
|
+
</Button>
|
|
30
|
+
)}
|
|
31
|
+
</TextInputGroupUtilities>
|
|
32
|
+
</TextInputGroup>
|
|
33
|
+
);
|
|
34
|
+
};
|
|
@@ -24,7 +24,7 @@ Additionally, attributes can be selected by typing the full (case sensitive) nam
|
|
|
24
24
|
|
|
25
25
|
Attributes can be deselected (returning you to attribute selection mode) by hitting `escape`, or by hitting `backspace` when the only text in the text input is the attribute.
|
|
26
26
|
|
|
27
|
-
```
|
|
27
|
+
```ts file="./examples/TextInputGroup/AttributeValueFiltering.tsx"
|
|
28
28
|
```
|
|
29
29
|
### Auto-complete search
|
|
30
30
|
|
|
@@ -36,5 +36,5 @@ Hitting `escape` while focused on the input or menu will close the menu, and the
|
|
|
36
36
|
|
|
37
37
|
When only one item remains in the suggestion list, tab can be used to auto-complete the typing of that item.
|
|
38
38
|
|
|
39
|
-
```
|
|
39
|
+
```ts file="./examples/TextInputGroup/AutoCompleteSearch.tsx"
|
|
40
40
|
```
|