⚠️ Breaking Changes
- Every exported type is now prefixed with
Magicfor a consistent public API, e.g.TraySnapPoint→MagicTraySnapPoint,DrawerWillSnapToPayload→MagicDrawerWillSnapToPayloadandToastDragPayload→MagicToastDragPayload. - MagicTray's
staticClickevent has been removed; slotted handle content now receives native clicks instead. - MagicTray's
snap.instantoption has been replaced bydrag.mode, either'free'or'snap'. - MagicToast's per-toast
add()overrides now go through a singleoptionsargument instead of top-leveldurationanddraggable. - MagicToast's
draggableoption has been replaced bydrag.disabled. - MagicToast's
hiddenCounthas been renamed tohidden. - MagicToast no longer fades toasts while dragging; drive the fade through the
dragevent instead.
🍿 Features
- MagicDrawer now emits a
willSnapToevent during a drag whenever the committed snap target changes. - MagicTray handles now pass clicks through to slotted content, suppressing only the click a drag synthesises on release.
- MagicTray's
drag.modecan commit straight to the closest snap point while dragging. - MagicToast's
add()accepts a per-toastoptionsargument forduration,drag,thresholdandanimation. - MagicToast's
beforeDrag,dragandafterDragevents are now typed asMagicToastDragPayload.
❗️ Bug fixes
- Fixed the
optionsprop type shown in the MagicToast, MagicMarquee and MagicCommand documentation.
Full Changelog: v1.0.0-beta.73...v1.0.0-beta.78