@hashicorp/design-system-components 2.3.1 → 2.3.3

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
@@ -1,5 +1,19 @@
1
1
  # @hashicorp/design-system-components
2
2
 
3
+ ## 2.3.3
4
+
5
+ ### Patch Changes
6
+
7
+ - [#1350](https://github.com/hashicorp/design-system/pull/1350) [`be5c5aad8`](https://github.com/hashicorp/design-system/commit/be5c5aad8fb9d59ecc57be5f78a45619bf18ce10) Thanks [@KristinLBradley](https://github.com/KristinLBradley)! - `RadioCard` - Update CSS to enable wrapping of long strings in label which were overflowing the container
8
+
9
+ - [#1353](https://github.com/hashicorp/design-system/pull/1353) [`0ed127294`](https://github.com/hashicorp/design-system/commit/0ed127294e66fa7d7412f40eb82ed4c3a89e3763) Thanks [@didoo](https://github.com/didoo)! - removed `z-index` value from `AppFrame::Footer`
10
+
11
+ ## 2.3.2
12
+
13
+ ### Patch Changes
14
+
15
+ - [#1344](https://github.com/hashicorp/design-system/pull/1344) [`6d6cf3ea8`](https://github.com/hashicorp/design-system/commit/6d6cf3ea81bf5bd1f631c99fc53cc88318d7d52f) Thanks [@cbfx](https://github.com/cbfx)! - `SideNav::Portal::Target` - Fixed a possible source of flickering when a panel has already been rendered
16
+
3
17
  ## 2.3.1
4
18
 
5
19
  ### Patch Changes
@@ -30,7 +30,7 @@ export default class HdsDisclosureComponent extends Component {
30
30
 
31
31
  @action
32
32
  onFocusOut(event) {
33
- // due to inconsitent implementation of relatedTarget across browsers we use the activeElement as a fallback
33
+ // due to inconsistent implementation of relatedTarget across browsers we use the activeElement as a fallback
34
34
  // if the related target is not part of the disclosed content we close the disclosed container
35
35
  if (!this.element.contains(event.relatedTarget || document.activeElement)) {
36
36
  this.close();
@@ -1,3 +1,8 @@
1
+ {{!
2
+ Copyright (c) HashiCorp, Inc.
3
+ SPDX-License-Identifier: MPL-2.0
4
+ }}
5
+
1
6
  <div class="hds-side-nav" ...attributes>
2
7
  <div class="hds-side-nav__wrapper">
3
8
  {{yield to="root"}}
@@ -9,12 +9,12 @@ import { tracked } from '@glimmer/tracking';
9
9
  import { action } from '@ember/object';
10
10
  import { DEBUG } from '@glimmer/env';
11
11
  import Ember from 'ember';
12
- import { debounce } from '@ember/runloop';
13
12
 
14
13
  export default class SidenavPortalTarget extends Component {
15
14
  @service router;
16
15
 
17
16
  @tracked numSubnavs = 0;
17
+ @tracked lastPanelEl = null;
18
18
 
19
19
  static get prefersReducedMotionOverride() {
20
20
  return Ember.testing;
@@ -38,7 +38,7 @@ export default class SidenavPortalTarget extends Component {
38
38
 
39
39
  @action
40
40
  didUpdateSubnav(element, [count]) {
41
- debounce(this, 'animateSubnav', element, [count], 100);
41
+ this.animateSubnav(element, [count]);
42
42
  }
43
43
 
44
44
  @action
@@ -135,14 +135,23 @@ export default class SidenavPortalTarget extends Component {
135
135
 
136
136
  // fade in next panel
137
137
  let nextPanelEl = targetElement.children[activeIndex];
138
+
139
+ // get reference to last child panel
140
+ let lastPanelEl = targetElement.children[targetElement.children.length - 1];
141
+
138
142
  if (nextPanelEl) {
139
143
  nextPanelEl.ariaHidden = 'false';
140
144
  nextPanelEl.style.setProperty('visibility', 'visible');
141
- // this eliminates a flicker if there's only 1 subnav rendering
142
- if (activeIndex === 0) {
145
+ // this eliminates a flicker if there's only one subnav rendering or if we
146
+ // already just rendered this panel.
147
+ if (activeIndex === 0 || nextPanelEl.isSameNode(this.lastPanelEl)) {
143
148
  fadeDelay = 0;
144
149
  fadeDuration = 0;
145
150
  }
151
+
152
+ // remember the last panel
153
+ this.lastPanelEl = lastPanelEl;
154
+
146
155
  nextPanelEl.animate([{ opacity: '0' }, { opacity: '1' }], {
147
156
  delay: fadeDelay,
148
157
  duration: fadeDuration,
@@ -36,7 +36,6 @@
36
36
  }
37
37
 
38
38
  .hds-app-frame__footer {
39
- z-index: 5;
40
39
  grid-area: footer;
41
40
  }
42
41
 
@@ -140,6 +140,7 @@
140
140
  display: block;
141
141
  margin: 8px 0;
142
142
  color: var(--token-form-label-color);
143
+ overflow-wrap: break-word;
143
144
 
144
145
  &:first-child {
145
146
  margin-top: 0;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hashicorp/design-system-components",
3
- "version": "2.3.1",
3
+ "version": "2.3.3",
4
4
  "description": "Helios Design System Components",
5
5
  "keywords": [
6
6
  "hashicorp",