@patternfly/react-core 4.251.1 → 4.251.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 CHANGED
@@ -3,6 +3,17 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [4.251.2](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@4.251.1...@patternfly/react-core@4.251.2) (2022-10-14)
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **JumpLinks:** clean up demo in a drawer ([#8182](https://github.com/patternfly/patternfly-react/issues/8182)) ([d8e5b91](https://github.com/patternfly/patternfly-react/commit/d8e5b91c74957bc0dc4825e519721191f9f0427e))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [4.251.1](https://github.com/patternfly/patternfly-react/compare/@patternfly/react-core@4.251.0...@patternfly/react-core@4.251.1) (2022-10-13)
7
18
 
8
19
  **Note:** Version bump only for package @patternfly/react-core
@@ -3628,6 +3628,44 @@ label.pf-c-check, .pf-c-check__label,
3628
3628
  border: 0;
3629
3629
  }
3630
3630
 
3631
+ .pf-c-code-block {
3632
+ --pf-c-code-block--BackgroundColor: var(--pf-global--BackgroundColor--200);
3633
+ --pf-c-code-block__header--BorderBottomWidth: var(--pf-global--BorderWidth--sm);
3634
+ --pf-c-code-block__header--BorderBottomColor: var(--pf-global--BorderColor--100);
3635
+ --pf-c-code-block__content--PaddingTop: var(--pf-global--spacer--md);
3636
+ --pf-c-code-block__content--PaddingRight: var(--pf-global--spacer--md);
3637
+ --pf-c-code-block__content--PaddingBottom: var(--pf-global--spacer--md);
3638
+ --pf-c-code-block__content--PaddingLeft: var(--pf-global--spacer--md);
3639
+ --pf-c-code-block__pre--FontFamily: var(--pf-global--FontFamily--monospace);
3640
+ --pf-c-code-block__pre--FontSize: var(--pf-global--FontSize--sm);
3641
+ background-color: var(--pf-c-code-block--BackgroundColor);
3642
+ }
3643
+
3644
+ .pf-c-code-block__header {
3645
+ display: flex;
3646
+ border-bottom: var(--pf-c-code-block__header--BorderBottomWidth) solid var(--pf-c-code-block__header--BorderBottomColor);
3647
+ }
3648
+
3649
+ .pf-c-code-block__actions {
3650
+ display: flex;
3651
+ margin-left: auto;
3652
+ }
3653
+
3654
+ .pf-c-code-block__content {
3655
+ padding: var(--pf-c-code-block__content--PaddingTop) var(--pf-c-code-block__content--PaddingRight) var(--pf-c-code-block__content--PaddingBottom) var(--pf-c-code-block__content--PaddingLeft);
3656
+ }
3657
+
3658
+ .pf-c-code-block__pre {
3659
+ font-family: var(--pf-c-code-block__pre--FontFamily);
3660
+ font-size: var(--pf-c-code-block__pre--FontSize);
3661
+ overflow-wrap: break-word;
3662
+ white-space: pre-wrap;
3663
+ }
3664
+
3665
+ .pf-c-code-block__code {
3666
+ font-family: var(--pf-c-code-block__code--FontFamily, inherit);
3667
+ }
3668
+
3631
3669
  .pf-c-context-selector__menu {
3632
3670
  --pf-global--Color--100: var(--pf-global--Color--dark-100);
3633
3671
  --pf-global--Color--200: var(--pf-global--Color--dark-200);
@@ -3962,44 +4000,6 @@ label.pf-c-check, .pf-c-check__label,
3962
4000
  border-top: 1px solid var(--pf-global--BorderColor--300);
3963
4001
  }
3964
4002
 
3965
- .pf-c-code-block {
3966
- --pf-c-code-block--BackgroundColor: var(--pf-global--BackgroundColor--200);
3967
- --pf-c-code-block__header--BorderBottomWidth: var(--pf-global--BorderWidth--sm);
3968
- --pf-c-code-block__header--BorderBottomColor: var(--pf-global--BorderColor--100);
3969
- --pf-c-code-block__content--PaddingTop: var(--pf-global--spacer--md);
3970
- --pf-c-code-block__content--PaddingRight: var(--pf-global--spacer--md);
3971
- --pf-c-code-block__content--PaddingBottom: var(--pf-global--spacer--md);
3972
- --pf-c-code-block__content--PaddingLeft: var(--pf-global--spacer--md);
3973
- --pf-c-code-block__pre--FontFamily: var(--pf-global--FontFamily--monospace);
3974
- --pf-c-code-block__pre--FontSize: var(--pf-global--FontSize--sm);
3975
- background-color: var(--pf-c-code-block--BackgroundColor);
3976
- }
3977
-
3978
- .pf-c-code-block__header {
3979
- display: flex;
3980
- border-bottom: var(--pf-c-code-block__header--BorderBottomWidth) solid var(--pf-c-code-block__header--BorderBottomColor);
3981
- }
3982
-
3983
- .pf-c-code-block__actions {
3984
- display: flex;
3985
- margin-left: auto;
3986
- }
3987
-
3988
- .pf-c-code-block__content {
3989
- padding: var(--pf-c-code-block__content--PaddingTop) var(--pf-c-code-block__content--PaddingRight) var(--pf-c-code-block__content--PaddingBottom) var(--pf-c-code-block__content--PaddingLeft);
3990
- }
3991
-
3992
- .pf-c-code-block__pre {
3993
- font-family: var(--pf-c-code-block__pre--FontFamily);
3994
- font-size: var(--pf-c-code-block__pre--FontSize);
3995
- overflow-wrap: break-word;
3996
- white-space: pre-wrap;
3997
- }
3998
-
3999
- .pf-c-code-block__code {
4000
- font-family: var(--pf-c-code-block__code--FontFamily, inherit);
4001
- }
4002
-
4003
4003
  .pf-c-data-list {
4004
4004
  --pf-global--Color--100: var(--pf-global--Color--dark-100);
4005
4005
  --pf-global--Color--200: var(--pf-global--Color--dark-200);
@@ -24160,6 +24160,40 @@ label.pf-c-tree-view__node-text {
24160
24160
  display: flex;
24161
24161
  }
24162
24162
 
24163
+ .pf-c-truncate {
24164
+ --pf-c-truncate--MinWidth: 12ch;
24165
+ --pf-c-truncate__start--MinWidth: 6ch;
24166
+ display: inline-grid;
24167
+ grid-auto-flow: column;
24168
+ align-items: baseline;
24169
+ min-width: var(--pf-c-truncate--MinWidth);
24170
+ }
24171
+
24172
+ .pf-c-truncate__start,
24173
+ .pf-c-truncate__end {
24174
+ overflow: hidden;
24175
+ text-overflow: ellipsis;
24176
+ white-space: nowrap;
24177
+ }
24178
+
24179
+ .pf-c-truncate__start {
24180
+ min-width: var(--pf-c-truncate__start--MinWidth);
24181
+ }
24182
+
24183
+ .pf-c-truncate__end {
24184
+ direction: rtl;
24185
+ }
24186
+
24187
+ .pf-c-truncate__start + .pf-c-truncate__end {
24188
+ overflow: visible;
24189
+ direction: ltr;
24190
+ }
24191
+
24192
+ @supports (-webkit-hyphens: none) {
24193
+ .pf-c-truncate__end {
24194
+ direction: ltr;
24195
+ }
24196
+ }
24163
24197
  .pf-c-panel {
24164
24198
  --pf-c-panel--Width: auto;
24165
24199
  --pf-c-panel--MinWidth: auto;
@@ -24243,40 +24277,6 @@ label.pf-c-tree-view__node-text {
24243
24277
  box-shadow: var(--pf-c-panel__footer--BoxShadow);
24244
24278
  }
24245
24279
 
24246
- .pf-c-truncate {
24247
- --pf-c-truncate--MinWidth: 12ch;
24248
- --pf-c-truncate__start--MinWidth: 6ch;
24249
- display: inline-grid;
24250
- grid-auto-flow: column;
24251
- align-items: baseline;
24252
- min-width: var(--pf-c-truncate--MinWidth);
24253
- }
24254
-
24255
- .pf-c-truncate__start,
24256
- .pf-c-truncate__end {
24257
- overflow: hidden;
24258
- text-overflow: ellipsis;
24259
- white-space: nowrap;
24260
- }
24261
-
24262
- .pf-c-truncate__start {
24263
- min-width: var(--pf-c-truncate__start--MinWidth);
24264
- }
24265
-
24266
- .pf-c-truncate__end {
24267
- direction: rtl;
24268
- }
24269
-
24270
- .pf-c-truncate__start + .pf-c-truncate__end {
24271
- overflow: visible;
24272
- direction: ltr;
24273
- }
24274
-
24275
- @supports (-webkit-hyphens: none) {
24276
- .pf-c-truncate__end {
24277
- direction: ltr;
24278
- }
24279
- }
24280
24280
  .pf-l-flex {
24281
24281
  --pf-l-flex--Display: flex;
24282
24282
  --pf-l-flex--FlexWrap: wrap;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@patternfly/react-core",
3
- "version": "4.251.1",
3
+ "version": "4.251.2",
4
4
  "description": "This library provides a set of common React components for use with the PatternFly reference implementation.",
5
5
  "main": "dist/js/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -70,5 +70,5 @@
70
70
  "react": "^16.8 || ^17 || ^18",
71
71
  "react-dom": "^16.8 || ^17 || ^18"
72
72
  },
73
- "gitHead": "9eacaae1c7ae678cc139c0ee937c158483826c18"
73
+ "gitHead": "5a7fd835da70f91dd7e40b97feb2ec4dc2e4ec0d"
74
74
  }
@@ -12,6 +12,7 @@ import {
12
12
  JumpLinksItem,
13
13
  JumpLinksList,
14
14
  PageSection,
15
+ PageSectionVariants,
15
16
  Sidebar,
16
17
  SidebarContent,
17
18
  SidebarPanel,
@@ -29,7 +30,7 @@ export const JumpLinksWithDrawer = () => {
29
30
 
30
31
  React.useEffect(() => {
31
32
  const masthead = document.getElementsByClassName('pf-c-masthead')[0];
32
- const drawerToggleSection = document.getElementsByClassName('pf-c-page__main-section')[0];
33
+ const drawerToggleSection = document.getElementById('drawer-toggle');
33
34
 
34
35
  getResizeObserver(masthead, () => {
35
36
  setOffsetHeight(masthead.offsetHeight + drawerToggleSection.offsetHeight);
@@ -61,60 +62,65 @@ export const JumpLinksWithDrawer = () => {
61
62
  <DashboardWrapper breadcrumb={null} mainContainerId="scrollable-element">
62
63
  <Drawer isExpanded={isExpanded}>
63
64
  <DrawerContent panelContent={panelContent} id="jump-links-drawer-drawer-scrollable-container">
64
- <DrawerContentBody hasPadding>
65
+ <DrawerContentBody>
65
66
  <Sidebar>
66
67
  <SidebarPanel variant="sticky">
67
- <JumpLinks
68
- isVertical={true}
69
- label="Jump to section"
70
- scrollableSelector="#jump-links-drawer-drawer-scrollable-container"
71
- offset={offsetHeight}
72
- expandable={{ default: 'expandable', md: 'nonExpandable' }}
73
- >
74
- {headings.map(heading => (
75
- <JumpLinksItem key={heading} href={`#jump-links-drawer-jump-links-${heading.toLowerCase()}`}>
76
- {`${heading} section`}
77
- <JumpLinksList></JumpLinksList>
78
- </JumpLinksItem>
79
- ))}
80
- </JumpLinks>
68
+ <PageSection variant={PageSectionVariants.light}>
69
+ <JumpLinks
70
+ isVertical={true}
71
+ label="Jump to section"
72
+ scrollableSelector="#jump-links-drawer-drawer-scrollable-container"
73
+ offset={offsetHeight}
74
+ expandable={{ default: 'expandable', md: 'nonExpandable' }}
75
+ >
76
+ {headings.map(heading => (
77
+ <JumpLinksItem key={heading} href={`#jump-links-drawer-jump-links-${heading.toLowerCase()}`}>
78
+ {`${heading} section`}
79
+ <JumpLinksList></JumpLinksList>
80
+ </JumpLinksItem>
81
+ ))}
82
+ </JumpLinks>
83
+ </PageSection>
81
84
  </SidebarPanel>
82
85
  <SidebarContent>
83
- <PageSection sticky="top" variant="light">
86
+ <PageSection id="drawer-toggle" stickyOnBreakpoint={{ default: 'top' }} variant="light">
84
87
  <Button onClick={onToggleClick}>Toggle drawer</Button>
85
88
  </PageSection>
86
- <TextContent>
87
- {headings.map(heading => (
88
- <div key={heading} style={{ maxWidth: '800px', marginBottom: '32px' }}>
89
- <h2 id={`jump-links-drawer-jump-links-${heading.toLowerCase()}`} tabIndex={-1}>
90
- {`${heading} section`}
91
- </h2>
92
- <p>
93
- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas sed dui ullamcorper, dignissim
94
- purus eu, mattis leo. Curabitur eleifend turpis ipsum, aliquam pretium risus efficitur vel.
95
- Etiam eget enim vitae quam facilisis pharetra at eget diam. Suspendisse ut vulputate magna. Nunc
96
- viverra posuere orci sit amet pulvinar. Quisque dui justo, egestas ac accumsan suscipit,
97
- tristique eu risus. In aliquet libero ante, ac pulvinar lectus pretium in. Ut enim tellus,
98
- vulputate et lorem et, hendrerit rutrum diam. Cras pharetra dapibus elit vitae ullamcorper.
99
- Nulla facilisis euismod diam, at sodales sem laoreet hendrerit. Curabitur porttitor ex nulla.
100
- Proin ligula leo, egestas ac nibh a, pellentesque mollis augue. Donec nec augue vehicula eros
101
- pulvinar vehicula eget rutrum neque. Duis sit amet interdum lorem. Vivamus porttitor nec quam a
102
- accumsan. Nam pretium vitae leo vitae rhoncus.
103
- </p>
104
- <p>
105
- At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum
106
- deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non
107
- provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et
108
- dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum
109
- soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere
110
- possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus autem quibusdam et
111
- aut officiis debitis aut rerum necessitatibus saepe eveniet ut et voluptates repudiandae sint et
112
- molestiae non recusandae. Itaque earum rerum hic tenetur a sapiente delectus, ut aut reiciendis
113
- voluptatibus maiores alias consequatur aut perferendis doloribus asperiores repellat.
114
- </p>
115
- </div>
116
- ))}
117
- </TextContent>
89
+ <PageSection variant={PageSectionVariants.light}>
90
+ <TextContent>
91
+ {headings.map(heading => (
92
+ <div key={heading} style={{ maxWidth: '800px', marginBottom: '32px' }}>
93
+ <h2 id={`jump-links-drawer-jump-links-${heading.toLowerCase()}`} tabIndex={-1}>
94
+ {`${heading} section`}
95
+ </h2>
96
+ <p>
97
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Maecenas sed dui ullamcorper,
98
+ dignissim purus eu, mattis leo. Curabitur eleifend turpis ipsum, aliquam pretium risus
99
+ efficitur vel. Etiam eget enim vitae quam facilisis pharetra at eget diam. Suspendisse ut
100
+ vulputate magna. Nunc viverra posuere orci sit amet pulvinar. Quisque dui justo, egestas ac
101
+ accumsan suscipit, tristique eu risus. In aliquet libero ante, ac pulvinar lectus pretium in.
102
+ Ut enim tellus, vulputate et lorem et, hendrerit rutrum diam. Cras pharetra dapibus elit vitae
103
+ ullamcorper. Nulla facilisis euismod diam, at sodales sem laoreet hendrerit. Curabitur
104
+ porttitor ex nulla. Proin ligula leo, egestas ac nibh a, pellentesque mollis augue. Donec nec
105
+ augue vehicula eros pulvinar vehicula eget rutrum neque. Duis sit amet interdum lorem. Vivamus
106
+ porttitor nec quam a accumsan. Nam pretium vitae leo vitae rhoncus.
107
+ </p>
108
+ <p>
109
+ At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium
110
+ voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati
111
+ cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est
112
+ laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero
113
+ tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime
114
+ placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus. Temporibus
115
+ autem quibusdam et aut officiis debitis aut rerum necessitatibus saepe eveniet ut et
116
+ voluptates repudiandae sint et molestiae non recusandae. Itaque earum rerum hic tenetur a
117
+ sapiente delectus, ut aut reiciendis voluptatibus maiores alias consequatur aut perferendis
118
+ doloribus asperiores repellat.
119
+ </p>
120
+ </div>
121
+ ))}
122
+ </TextContent>
123
+ </PageSection>
118
124
  </SidebarContent>
119
125
  </Sidebar>
120
126
  </DrawerContentBody>