(v0.15.0) The "major" minor one
Contributors
This long-overdue release was made possible by the following contributors.
- @100stacks
- @cathysiller
- @CITguy
- @EHackettTriCore (bug reports, early adoption)
- @jonkruse00 (bug reports)
- @kamalgill
- @mcortez1497 (bug reports, early adoption)
- @nicko-winner (bug reports, early adoption)
- @nloadholtes
Thank you for your support!
Known Issues
- Smart repositioning logic for positionable elements breaks down for variable-width elements at really small screen widths (e.g., Popovers at XS breakpoint).
- Keyboard interaction of tooltip control elements aren't automatic in Edge 12-17 or IE due to a bug that exists in those browsers.
- For maximum accessibility, please ensure that the control element is keyboard navigable by setting
tabindex="0", if the element isn't already navigable.
- For maximum accessibility, please ensure that the control element is keyboard navigable by setting
Summary
Improved Compatibility with Pre-existing Application CSS
Several Helix styles have been updated, in order to reduce the likelihood that generic element style resets interfere with pre-existing CSS in consuming applications. There are some CSS resets that could not be updated, due to the nature of their existence, but those that were updated are appropriately scoped to .hx* prefixed CSS classes.
Standardization of Positioned Elements
All positionable elements (presently <hx-menu>, <hx-popover>, <hx-search-assistance>, and <hx-tooltip>) have been updated to use the same core logic in order to apply consistent positioning behavior. Additionally, the logic that repositions these elements in the event that they collide with edges of the viewport has been updated to be smarter about when and when not to reposition.
Improved React Life Cycle Compatibility
In December 2018, we did extensive research around lifecycle timings between React and custom elements. We discovered that custom elements had the potential to execute behavior before they've fully initialized. The primary cause of these errors is because external elements hadn't yet connected to the DOM. This was especially true for parent/child relationships (<hx-accordion> and <hx-tabset>) and co-dependent elements (<hx-disclosure> + revealable element, <hx-tooltip> + control element).
To correct this problem, relevant custom elements were updated to defer their initialization logic until the next JavaScript event loop using setTimeout(callback, 0). This maximized the chances that external elements have had a chance to connect and initialize. Additionally, their internal workings have been updated to avoid errors associated with incomplete initialization.
Modified custom elements include:
- hx-accordion (parent/child)
- hx-disclosure (co-dependency on external element)
- hx-tabset (parent/child)
- hx-tooltip (co-dependency on external element)
⚠️ NOTE
This change shouldn't break existing code. However, it does have the potential to introduce subtle behavior changes if consuming applications are expecting these elements to be fully initialized on render.
Symptoms may include:
- calling methods that require full initialization seem to do nothing
- side-effects resulting from setting configuration values do not occur
Detailed Changes
API
- Deprecated
Positionable: Deprecate non-hyphenated position values with replacements (#429)bottomis nowbottom-centerleftis nowleft-middlerightis nowright-middletopis nowtop-center
- Fixed
Accordions
- Breaking Changes
- Fixed
<hx-accordion>: Defer initialization in order to wait for children to initialize. (#428)
- Added
<hx-accordion-panel>: Add support for thedisabledattribute. (#401)
Alerts
Given the change to Pills, Alerts were updated in a similar fashion. Even though backward compatibility could have been preserved, we're already introducing breaking changes in this release, so we followed suit.
| Alert | Before | After |
|---|---|---|
| Persistent | <hx-alert static> |
<hx-alert persist> |
| Dismissible | <hx-alert> |
<hx-alert> |
- Breaking Changes
- 🚨
<hx-alert>: Replace thestaticattribute withpersistto align with persistent Pill configuration. (#397)
- 🚨
- Updated
<hx-alert>: Simplify ShadowDOM styles (#398)
Box
- Fixed
<hx-div>: Correct CSS bug associated with scrollable elements (#393)- Even though the bug only appears in non-webkit browsers, it's actually an old bug with the CSS specification itself.
- Webkit browsers apply styles as developers would expect, but other browsers apply styles according to the broken specification.
Buttons
- Updated
- Update "Basic Button" demo and documentation to clarify CSS change made in
v0.14.0(#438)- To reiterate, text nodes within buttons must be wrapped in a
<span>if there are any non-text siblings.
- To reiterate, text nodes within buttons must be wrapped in a
- Update "Basic Button" demo and documentation to clarify CSS change made in
Choice Tiles
- Fixed
CSS
- Breaking Changes
- 🚨Alignment classes (
.hxLeft,.hxCenter,.hxRight) now use!important(#394)
- 🚨Alignment classes (
- Fixed
- Isolate CSS resets for the
<legend>and<fieldset>elements to the experimental.beta-hxFormclass (#342) <hr>: Isolate styles to.hxDividerclass (#342)- Correct ShadowDOM CSS specificity in response to a bug in older versions of Chrome. (#366)
- Set default values for
leftandtopCSS properties of positionable elements, in order to maximize accuracy of calculated position coordinates (#429)
- Isolate CSS resets for the
- Added
- Add
hr.hxDividerCSS styles (#342)
- Add
Documentation
- Fixed
- Updated
- Update "Polyfills" guide to reflect capabilities of Firefox 63+ (#365)
- Update README to display some useful info on NPM (#361)
- Remove hidden stability docs and associated styles (#399)
- Update component and element documentation to reflect modifications to positioned element functionality. (#349)
- Normalize property descriptions across positionable elements (#429)
- Added
Icons
Lists
- Fixed
- Isolate CSS resets for the
<ol>and<ul>elements to the.hxListclass (#342)
- Isolate CSS resets for the
Menus
- Breaking Changes
- 🚨
HXMenuElement: Thepositionproperty may not return the same value it was given. (#429)- the value is normalized on set (e.g., setting
topnormalizes totop-centeron get)
- the value is normalized on set (e.g., setting
- 🚨
- Fixed
- Added
Modals
- Deprecated
- Fixed
- Added
- Updated
- Increase max width of default (a.k.a. "medium") Modals from
40rem (640px)to50rem (800px)(#400)
- Increase max width of default (a.k.a. "medium") Modals from
Panels
- Deprecated
Pills
Consumer feedback revealed that Pills were expected to be dismissible by default, but Pills used to be persistent by default. This meant that consumers had to apply additional configuration to achieve default behavior. As such, Pills were updated to be dismissible without additional configuration (opposite of before).
Unfortunately, this change makes it impossible to remain backward compatible with old behavior, because <hx-pill> would have to be both persistent and dismissible (a "Schrödinger's Pill", if you will).
| Pill | Before | After |
|---|---|---|
| Persistent | <hx-pill> |
<hx-pill persist> |
| Dismissible | <hx-pill dismissable> |
<hx-pill> |
- Breaking Changes
- Fixed
<hx-pill>: Correct appearance when used within.hxTable. (#383)
Popovers
- Breaking Changes
- 🚨Remove support for positions ending in
*-startor*-end. (#349) - 🚨Remove support for
data-popover="popoverID"on the control element. (#349)- Use
<hx-disclosure aria-controls="popoverID">instead.
- Use
- 🚨
HXPopoverElement: Thepositionproperty may not return the same value it was given. (#429)- the value is normalized on set (e.g., setting
topnormalizes totop-centeron get)
- the value is normalized on set (e.g., setting
- 🚨Remove support for positions ending in
- Deprecated
- Fixed
<hx-popover>: Calculatefixedcoordinates, relative to the viewport. (#349)<hx-popover>: Correct configuration/state overlap onpositionattribute. (#349)- The attribute value will not change, once configured.
HXPopoverElement: Correct logic to default attribute values on connect, not during construction (#408)
- Added
Reveals
- Fixed
Search
- Breaking Changes
- 🚨
<hx-search-assistance>: Thepositionproperty may not return the same value it was given. (#429)- the value is normalized on set (e.g., setting
topnormalizes totop-centeron get)
- the value is normalized on set (e.g., setting
- 🚨
- Fixed
- Added
Tables
- Fixed
Tabs
- Fixed
- Updated
Tooltips
In addition to positioning corrections, Tooltips received updates to improve accessibility.
Unfortunately these changes could not be made in a non-breaking fashion, so please read the details below.
Tooltips Before
<hx-disclosure aria-controls="my-tooltip">
<hx-icon type="help-circle"></hx-icon>
</hx-disclosure>
<hx-tooltip id="my-tooltip">
This is an old tooltip. (T_T)
</hx-tooltip>Tooltips After
<hx-icon id="help-icon" type="help-circle"></hx-icon>
<hx-tooltip for="help-icon" position="top-center">
This is a new tooltip! (^_^)
</hx-tooltip>- Breaking Changes
- 🚨Remove click-to-toggle behavior to align with WAI-ARIA accessibility guidelines. (#349)
- Use
<hx-popover>if you require interactive contents.
- Use
- 🚨
<hx-tooltip>: Remove support forpositionvalues ending in*-startor*-end. (#349) - 🚨Remove support for
data-tooltip="tooltipID"on the control element. (#349)- Use
<hx-tooltip for="controlID">instead.
- Use
- 🚨
HXTooltipElement: Thepositionproperty may not return the same value it was given. (#429)- the value is normalized on set (e.g., setting
topnormalizes totop-centeron get)
- the value is normalized on set (e.g., setting
- 🚨Remove click-to-toggle behavior to align with WAI-ARIA accessibility guidelines. (#349)
- Fixed
<hx-tooltip>: Calculatefixedcoordinates, relative to the viewport. (#349)HXTooltipElement: Detach unnecessary event handlers when closed. (#349)<hx-tooltip>: Correct configuration/state overlap onpositionattribute. (#349)- The attribute value will not change, once configured.
<hx-tooltip>: Update appearance to align with current design specs. (#349)HXTooltipElement: Defer initialization in order to wait for control element to initialize. (#435)
- Added
- Add support for tooltip headers via
hx-tooltip > header. (#349) - Add read-only
controlElementproperty (#349) - Add read-only
optimumPositionproperty (#429) - Add read-only
relativeElementproperty (#349) - Add
forattribute which reflects thehtmlForproperty (#349) - Add
relative-toattribute which reflects therelativeToproperty (#349) - Add
reposition()method which emits arepositionevent (#349)
- Add support for tooltip headers via
- Updated
- Show and Hide delay are now the same duration (
500ms). (#349) <hx-tooltip>automatically attempts to make its control element accessible (#349)- Logic is based on DOM API standards, but it's broken in Edge 12-17 and IE due to a bug. (see #384)
<hx-tooltip>: Change default position fromtoptotop-center(#429)
- Show and Hide delay are now the same duration (
Typography
- Breaking Changes
- 🚨 Remove "disabled" link styles (#342)
Utilities
- Breaking Changes
- Added
- Add
Positionableclass mixin (#349) - Add
Revealableclass mixin (#349) - HelixUI.Utils
- HelixUI.Utils.Alignment
- Add
getAlignment(position)(#429) - Add
getCrossAxis(position)(#429) - Add
getHorizontalAlignment(position)(#429) - Add
getMainAxis(position)(#429) - Add
getVerticalAlignment(position)(#429) - Add
invertPositionHorizontally(position)(#429) - Add
invertPositionVertically(position)(#429) - Add
normalizePosition(position)(#429) - Add
optimizePositionForCollisions(position, collisions)(#429)
- Add
- HelixUI.Utils.Offset
- Add aliases of deprecated positions to
offsetFunctionMap(#429)
- Add aliases of deprecated positions to
- Add
Merged
v0.15.0
- #438 - docs(Buttons): clarify need for span around text node children
- resolves #426 - Review .hxBtn display: inline-flex;
- #436 - fix(*): papercuts
- #435 - fix(Positionable): correct support for HTML5 IDs
- #434 - fix(#394): correct specificity of helper classes
- fixes #394 - Table CSS resets too specific
- #431 - chore(panels): deprecate custom elements within component
v0.15.0-rc.3
- #417 - Various updates
- #412 - fix(*): Compatibility Updates
- #432 - fix(docs): fix invalid HTML ID in nav
- #429 - feat(Positionable): implement "smart" repositioning
- #428 - update(HXAccordionElement): compatibility updates
- #427 - refactor(HXTabsetElement): compatibility updates
- #425 - docs(Polyfills): correct source of 'isConnected' polyfill
- #424 - refactor(Positionable): debug compatibility updates
- #423 - revert(polyfills): remove unnecessary 'isConnected' polyfill
- #422 - refactor(*): clean up source code
- #421 - update(HXTabsetElement): modify default ID value
- #420 - docs(polyfills): add location for Node.isConnected
- #419 - refactor(HXTooltipElement): compatibility updates
- #418 - refactor(HXDivElement): compatibility updates
- #416 - refactor(HXElement): refactor behavior of multiple custom elements
- #413 - refactor(Positionable): compatibility audit updates
v0.15.0-rc.2
- #408 - fix(#406): Fix React Compatibility
- #407 - refactor(HXSearchAssistanceElement): use Positionable mixin
- #402 - refactor(HXMenuElement): use Positionable mixin
v0.15.0-rc.1
- #403 - docs(pills): update pills with recent persist update
- #401 - feat(disabled): add disabled attr support to HXAccordionPanelElement
- #400 - feat(Modals): add width options to hx-modal
- #399 - docs(stability): remove stability docs and associated styles
- #398 - refactor(hx-alert): simplify Shadow CSS
- #397 - update(hx-alert): replace "static" attr with "persist"
- #396 - docs(Files): correct broken "see also" link
- #393 - fix(#379): fix padding-block-end bug
- #392 - fix(CSS): correct spacing around tables
- #391 - update(hx-pill): invert and replace "dismissable" attr with "persist" attr
- #387 - fix(#334): IE11 and Edge Tabs bug
- #385 - docs(elements): normalize custom elements docs
- #383 - fix(pills): fix styles for pills inside tables
v0.15.0-rc.0
- #366 - fix(CSS): correct :host selector specificity
- #365 - docs(polyfills): Update to reflect Firefox 63 functionality
- #361 - docs(README): updating content
- #357 - fix(choice-tiles): fix icon color when selected
- #351 - fix(CSS): fix hover cursor for various components
- #349 - update(positioning): fix deep-rooted positioning logic
- #342 - fix(CSS): Audit CSS classes for conflicts with pre-existing styles
