Repository navigation
mtrl 0.10.6
The release that announces 1.0.0. Everything decided for 1.0.0 as of this release that 0.10.x
had not yet marked is now told in the code, as @deprecated or as an "In 1.0 …" note in the
TSDoc, so your editor shows each one before you move to 1.0.0. Later decisions will be
announced in a further 0.10.x release before 1.0.0: upgrade to the latest 0.10.x first. None
of those notes changes anything at run time. Also three fixes: reduced motion inside the
elements (an accessibility fix), the button group's press, and the tooltip's placement.
Deprecated
Comments only: nothing changes at run time. Each is removed or changed in 1.0.0.
select.textfield: 1.0 renames ittextFieldand keeps no alias. This corrects 0.10.5's
note, which saidtextfield"remains as an alias through 1.x": in 1.0select.textfieldis
undefined. 0.10.x has notextField, so rename it when you upgrade, as with
SELECT_CLASSES.TEXTFIELD(FLO-383).- The icon button's DOM
toggleevent is removed in 1.0: listen tochange, which the
factory's button and<m-icon-button>have emitted since 0.10.0 (FLO-295). The deprecation,
until now only in 0.10.0's notes, is on thetoggleoption and on the element's event. RADIO_DEFAULTS.VARIANT,.LABEL_POSITIONand.SIZE(mtrl/components/radios/constants):
the radios have no such options, and nothing reads the keys.DIRECTIONstays.- Told in the TSDoc, for 1.0:
emiton the card and the tabs accepts only the component's
own events; the radio factory'schangereportsnull, not"", when nothing is selected;
withInput'schangereports the checked boolean asvalue, with the input's string value
asvalueAttribute. select.menuandsplitButton.menu(the inner menu component) are removed in 1.0. Use
the component's own methods and events: on the selectopen(),close(),isOpen(),
getOptions(),setOptions()andopen,close,change; on the split buttonexpand(),
collapse(),isExpanded()andexpand,collapse,select(FLO-543).- Told in the TSDoc, for 1.0, values and payloads:
- the radio factory's
getValue()returnsnullwhen nothing is selected, andsetValue
acceptsnullto clear; withInput'sgetValue()andsetValue()work on the checked boolean, the string is
getValueAttribute()/setValueAttribute(), andsetValueemits novalueevent;- the carousel's
changecarries the index asvalue, andindexis gone.
- the radio factory's
- Told in the TSDoc, for 1.0, the
on*options that become their event's listener: each
receives what a listener passed toon(event)receives.- Time picker
onConfirm:{ value }, not the time string. - Search
onSubmitandonInput: theSearchEvent(the query isevent.value), not the
string.onClear: theSearchEvent.onSuggestionSelect: theSearchEvent(the
suggestion isevent.suggestion).onExpandandonCollapse: the event's object. - Navigation rail
onExpandandonCollapse:{ expanded: true }and{ expanded: false }. - A chip's
onChange: one object,{ selected, chip, value }, not(selected, chip). A
chip'sonClick:{ event, originalEvent, element }, not the chip. The chip set's
onChange: one object,{ value, selected, changed }, and it also hears
selectByValue(values, true).
- Time picker
- Told in the TSDoc, for 1.0, the button group's
onmap (click,focus,blur,
change): on 0.10.x it is accepted and never called, so subscribe with
on(event, handler)on the group. In 1.0 those handlers run, with the listener's argument.
Fixed
- Accessibility: reduced motion is honoured inside the elements (FLO-549). With the system's
reduced-motion preference on, mtrl limits transitions to fades and ends animations at once,
from a rule in the page's stylesheet. That rule did not reach an element's shadow root, so
inside<m-button>,<m-button-group>,<m-icon-button>,<m-fab>,<m-extended-fab>,
<m-card>,<m-chips>,<m-tabs>,<m-slider>,<m-radios>,<m-tooltip>and<m-badge>
movement ran as if the preference were off (the button's corner morph, the button group's
width and corner springs), and in the other elements only the parts their own stylesheet
names were reduced. Every element's shadow root now carries the same rule. The ripple and
the motion driven from script (progress, loading indicator, carousel, date picker, FAB menu)
already honoured the preference, and so did the factories outside a shadow root. - Button group (FLO-537): Pressing a button in a standard group briefly showed an ellipsis
on a neighbour's label. The neighbour's width and padding now ease together, and the width
returns to the label's own size when the press ends. In a right-to-left page the
neighbour's padding now gives way on the side facing the pressed button; it was the
opposite side. - Tooltip placement (FLO-535): With motion enabled, a tooltip could settle 5% of its width off
centre while animating in and be squeezed at the viewport edge. Placement now uses its full
layout size; the first placement under reduced motion is unchanged.
npm: mtrl@0.10.6 · Docs: md3.io · Full history: CHANGELOG.md