For information about upgrading from Enact 2.x, refer to the Enact 3.0.0 migration guide at docs/migration/enact/migrating-to-enact-3.md
NOTE: Support for 2019 TV platform (Blink <68) has been dropped from this version of Enact
Removed
core/kindconfig propertycontextTypesi18n/ilibembedded copy of iLib in favour of the NPM packageilibi18n/UppercaseHOC, replaced byi18n/utilcasing functionsmoonstone/Buttonandmoonstone/Panels.Headerpropcasingwhich is no longer supportedmoonstone/Divider, replaced bymoonstone/Headingmoonstone/Divider,moonstone/Dialog, andmoonstone/Headingpropcasingmoonstone/Input.InputBasepropfocusedwhich was used to indicate when the internal input field had focused but was replaced by the:focus-withinpseudo-selectormoonstone/VirtualListandmoonstone/VirtualList.VirtualGridListpropertyisItemDisabledsmallprop inmoonstone/Input,moonstone/ToggleButton,moonstone/Button,moonstone/Icon,moonstone/IconButton, andmoonstone/LabeledIcon, replaced bysizeprop, which accepts"small"or"large"
Added
core/util.clampto safely clamp a value between min and max boundsilib@^14.2.0package as a peer dependency for@enact/i18nand@enact/moonstone, which apps will need to includemoonstone/BodyTextpropsizeto offer a new "small" sizemoonstone/ButtonpropiconPositionmoonstone/ContextualPopupconfignoArrowmoonstone/Dropdowncomponentmoonstone/Dropdownpropertywidthto support'small','medium', and'large'sizesmoonstone/Dropdownwidthstiny, andhugemoonstone/Panels.Headerpropcenteredto support immersive apps with a completely centered designmoonstone/Panels.HeaderprophideLineto hide the bottom separator linemoonstone/Panels.Headersamplemoonstone/Panels.Headertype "dense" for "AlwaysViewing" Panels typesmoonstone/Headingcomponent, an improved version ofmoonstone/Dividerwith additional featuresmoonstone/Headingpropspacingwith default value'small'moonstone/Icon.iconsentries for new iconsmoonstone/LabeledIconButtonpropflipto flip the icon horizontally, vertically, or bothmoonstone/Panelsslot<controls>to easily add custom controls next to the Panels' "close" buttonmoonstone/Panelssupport for managing share state of contained componentsmoonstone/Popuppublic class namesbodyandcloseContainermoonstone/Scrollerandmoonstone/VirtualListsupport for restoring scroll position when within amoonstone/Panels.Panelmoonstone/Spinnerpropsizeto support a new "small" size for use insideSlotItemcomponentsmoonstone/TooltipDecoratorproptooltipRelativeandmoonstone/TooltipDecorator.Tooltipproprelativeto support relative positioning. This is an advanced feature and requires a container with specific rules. See documentation for details.ui/Buttonpublic class.hasIconwhich is present on the root node only when an icon has been providedui/Headingcomponentui/Icon,ui/IconButton, andui/LabeledIconpropflipto flip the icon horizontally, vertically, or bothui/MeasurableHOC and Hook for quick and convenient measuring of simple componentsui/Scroller,ui/VirtualList.VirtualGridList, andui/VirtualList.VirtualListpropnoScrollByWheelfor preventing scroll by wheelui/ToggleableHOC config propeventPropsto allow wrapped components to specify additional event informationui/VirtualList.VirtualGridListandui/VirtualList.VirtualListsupport for resizing a window
Changed
moonstone/Button.ButtonDecoratorto removei18n/UppercaseHOCmoonstone/Button,moonstone/Checkbox,moonstone/CheckboxItem,moonstone/ContextualPopupDecorator,moonstone/FormCheckbox,moonstone/FormCheckboxItem,moonstone/Panels.Header,moonstone/Notification,moonstone/RadioItem, andmoonstone/Tooltipappearance to match the latest designsmoonstone/Button,moonstone/Dropdown,moonstone/Icon,moonstone/IconButton,moonstone/Input, andmoonstone/ToggleButtondefault size to "small", which unifies their initial heightsmoonstone/DaySelectorto have squared check boxes to match the rest of the checkmark componentsmoonstone/Dialogappearance to match the latest designsmoonstone/Dropdownto prevent spotlight moving out of the popupmoonstone/Dropdownto use radio selection which allows only changing the selection but not deselectionmoonstone/LabeledIconandmoonstone/LabeledIconButtontext size to be smallermoonstone/Panelandmoonstone/Panelsnow allocate slightly more screen edge space for a cleaner lookmoonstone/Scrollerand other scrolling components to scroll via remote page up/down buttons when the scrollbar is hiddenmoonstone/Scrollerto scroll when no spottable child exists in the pressed 5-way key direction and, whenfocusableScrollbaris set, focus the scrollbar buttonmoonstone/Scroller.Scroller,moonstone/VirtualList.VirtualGridList, andmoonstone/VirtualList.VirtualListscrollbar button to gain focus when pressing a page up or down key iffocusableScrollbaris truesamplerlook and feel by updating to Storybook 5 and applying an Enact themespotlightcontainers to include nodes identified on thearia-ownsattribute of the container node as candidates within that containerspotlight/Spottableto allow disabled items to be focusedui/ViewManagerto use Web Animations instead of animation callbacks to improve performance resulting in API changes toArrangerand the pre-configured arrangersSlideArranger,SlideBottomArranger,SlideLeftArranger,SlideRightArranger, andSlideTopArranger- global styling rules affecting standard font-weight, disabled opacity, and LESS color variable definitions
Fixed
Fontsfor non-Latin to not intermix font weights for bold when using a combination of Latin and non-Latin glyphs- Fonts to correctly use the new font files and updated the international font name from "Moonstone LG Display" to "Moonstone Global"
- Language-specific fonts so they always use the correct typeface for their locale
- Moonstone Fonts to use the updated names of global fonts available in the system
- Non-Latin locale font assignments to match the new font family support in
LG Smart UI core/platformlogic for webOS detectioni18n/Textto generate a proper TypeScript definition and to properly detect if translations were available when asyncmoonstonedisabled focus appearance to match the latest designsmoonstonefonts be consolidated under "Moonstone" font-family to properly display all localized fonts when representing glyphs from any localemoonstoneto support custom font for simplified Chinesemoonstone/Buttonbackground colors for translucent and lightTranslucentmoonstone/Checkboxby updating colors for both dark and light skinsmoonstone/Checkbox,moonstone/FormCheckbox,moonstone/Panels.Header,moonstone/RadioItem,moonstone/Slider, andmoonstone/Switchto render correctly in high contrastmoonstone/ContextualPopupDecoratorarrow rendering issue in Chromiummoonstone/ContextualPopupDecoratorlayout in large text mode in RTL localesmoonstone/DatePicker,moonstone/DayPicker,moonstone/ExpandableList, andmoonstone/TimePickerdisabled opacity in high contrast modemoonstone/DaySelectoritem text size in large-text modemoonstone/Dropdownbutton to not animatemoonstone/DropdownchildrenpropType so it supports the same format asui/Group(an array of strings or an array of objects with props)moonstone/Dropdownperformance when using many optionsmoonstone/Dropdownpopup scroller arrows showing in non-latin locales and added large-text mode supportmoonstone/Dropdownremaining open after it becomesdisabledmoonstone/Dropdownto scroll to and focus the selected item when openedmoonstone/Dropdownto support voice readoutmoonstone/EditableIntegerPickerto properly rerender when the edited value is invalidmoonstone/ExpandableItem.ExpandableItemBaseto not error ifonCloseoronOpenwas not suppliedmoonstone/FormCheckbox,moonstone/Input,moonstone/ProgressBar,moonstone/RadioItem,moonstone/SwitchItem, andmoonstone/Tooltiplight skin colors.moonstone/FormCheckboxItemso it doesn't change size between normal and large text modemoonstone/FormCheckboxItemto marquee its contentsmoonstone/FormCheckboxItemto match the designsmoonstone/GridListImageItemto support overriding theimageCSS class namemoonstone/Headerinput highlight positioningmoonstone/Headingto have a bit more space between the text and the line, when the line is presentmoonstone/IncrementSliderto support aria-label when disabledmoonstone/Inputcaret color to match the designs (black bar on white background, white bar on black background, standard inversion)moonstone/Inputtext color when focused and disabledmoonstone/Itemheight in non-latin localesmoonstone/LabeledItemto not clip the bottom of descender glyphs in large text modemoonstone/LabeledItemto passmarqueeOnprop to its contentsmoonstone/MediaOverlayto not mute media playbackmoonstone/Panelsanimation performance issues on low powered hardwaremoonstone/Panelsto allow 5-way navigation to components withincontrolswhen used with aHeaderwithheaderInputmoonstone/Panelsto treat all components withincontrolsas part of the active panel for the purposes of accessibilitymoonstone/Panels.Headerto use the latest designs with better spacing between the titles belowmoonstone/Panels.HeaderwithInputto not have a distracting white background colormoonstone/Pickeraccessibility read out when a button becomes disabledmoonstone/Pickerto avoid overlapping items on rendermoonstone/Popupto properly handle closing in mid-transitionmoonstone/ProgressBarfill color whenhighlightedis setmoonstone/ProgressBar,moonstone/Slider, andmoonstone/IncrementSliderto use the latest set of design colorsmoonstone/RadioItemandmoonstone/SelectableItemicon size in large-text modemoonstone/RadioItemto have a much prettier dot in dark and light skinsmoonstone/Scrollerand other scrolling components to properly scroll via remote page up/down buttons when nested within another scrolling componentmoonstone/Scrollerto correctly handle horizontally scrolling focused elements into view when using adirectionvalue of'both'moonstone/Scrollerto not jump to the top when right key is pressed in the right most item of a vertical scrollermoonstone/Scrollerto not scroll horizontally via 5-way down in horizontal scrollermoonstone/Scrollerto properly move focus out of the containermoonstone/Scrollerto scroll and to move focus to the paging control properly if the current item sticking to the top is only spottablemoonstone/Scroller,moonstone/VirtualList.VirtualGridList, andmoonstone/VirtualList.VirtualListto scroll via a page up or down key when focus is on any vertical paging control while in pointer modemoonstone/Scroller,moonstone/VirtualList.VirtualGridList, andmoonstone/VirtualList.VirtualListto correctly set focus after scrolling by page up/down keysmoonstone/Scroller,moonstone/VirtualList.VirtualGridList, andmoonstone/VirtualList.VirtualListnot to scroll too far by page up/down keysmoonstone/Scroller,moonstone/VirtualList.VirtualGridList, andmoonstone/VirtualList.VirtualListnot to scroll via a page up or down key when focus is on any horizontal paging controlmoonstone/SkinnableTypeScript signaturemoonstone/Sliderprogress bar fill color when focused withnoFillsetmoonstone/Spinnerto use the latest designsmoonstone/Tooltiparrow gapmoonstone/Tooltiplayer order so it doesn't interfere with other positioned elements, likeContextualPopupmoonstone/VideoPlayerfeedback tooltip to overlap in non-latin localemoonstone/VideoPlayermore button tooltip to not clip or reverse text in RTL localesmoonstone/VideoPlayerto have correct jump forward/backward iconmoonstone/VideoPlayerto have correct sized control buttonsmoonstone/VideoPlayerto hide scrim for high contrast if bottom controls are hiddenmoonstone/VirtualListto allow keydown events to bubble up when not handled by the componentmoonstone/VirtualListto restore focus to an item when scrollbars are visiblemoonstone/VirtualListto scroll to the focused item when navigating out of the viewport via 5-waymoonstone/VirtualList.VirtualGridListandmoonstone/VirtualList.VirtualListto correctly scroll to a selected component when focused via 5waymoonstone/VirtualList.VirtualGridListandmoonstone/VirtualList.VirtualListto focus an item properly after an updatemoonstone/VirtualList.VirtualGridListandmoonstone/VirtualList.VirtualListto navigate items properly in RTL languagesmoonstone/VirtualList.VirtualGridListandmoonstone/VirtualList.VirtualListto properly navigate from paging controls to controls out of the listmoonstone/VirtualList.VirtualGridListandmoonstone/VirtualList.VirtualListto properly respond to 5way directional key pressesmoonstone/VirtualList.VirtualGridListandmoonstone/VirtualList.VirtualListto render the first item properly when thedataSizeprop is updated and the function as a parameter of thecbScrollToprop is calledsamplerto limit the fields included in the Actions tab to improve serialization performance on low-powered hardwarespotlightto attempt to restore focus through ancestor containers when the pointer hidesspotlightto attempt to restore focus to an element nearest the pointer position when the pointer hides within an overflow containerspotlightTypeScript signaturesspotlight/SpotlightContainerDecoratorto correctly forwardonFocusCaptureandonBlurCaptureeventsui/Iconto support arbitrary icon name strings, like in material iconsui/Measurableto remeasure after a re-layout so the measurement value is always correctui/ProgressBarpublic class namebarto support customizing the background of the barui/ScrollerTypeScript signaturesui/Scroller,ui/VirtualList.VirtualGridList, andui/VirtualList.VirtualListnot to scroll by wheel at the same time when multiple lists/scrollers are nestedui/Scroller,ui/VirtualList.VirtualGridList, andui/VirtualList.VirtualListto handle mouse down events on scrollbarsui/styles/mixins.lessmixins:.buildLocaleFont,.buildLocaleFonts,.buildFontFaceto properly support font-weight ranges, font-weight default values, and font-stretch valuesui/ToggleItemto send itsvalueprop when toggledui/ViewManagerto correctly arrange views when initially rendering a non-zero indexui/VirtualList.VirtualGridListandui/VirtualList.VirtualListto applywill-changeCSS property to the proper nodeui/VirtualList.VirtualGridListandui/VirtualList.VirtualListto retain the proper scroll position when updating theitemSizeorspacingpropswebos/LS2Requestto automatically prefixluna://service protocol when absentwebos/LS2Requestto return an error for a null response from a service