⬆️ (deps) @mantine/hooks@7.15.0 [skip ci] #3077
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
7.14.3
->7.15.0
Release Notes
mantinedev/mantine (@mantine/hooks)
v7.15.0
: 💋Compare Source
View changelog with demos on mantine.dev website
Support Mantine development
You can now sponsor Mantine development with OpenCollective.
All funds will be used to improve Mantine and create new features and components.
use-radial-move hook
New use-radial-move hook can be used to create custom radial sliders:
BarChart color based on value
BarChart component now supports
getBarColor
prop to assign color based on value.getBarColor
function is called with two arguments: value and series object. It should return a colorstring (theme color reference or any valid CSS color value).
Button.GroupSection and ActionIcon.GroupSection
ActionIcon.GroupSection
andButton.GroupSection
are new components thatcan be used in
ActionIcon.Group
/Button.Group
to create sections that arenot
ActionIcon
/Button
components:Table vertical variant
Table component now support
variant="vertical"
:Table tabular numbers
Table component now supports
tabularNums
prop to render numbers in tabular style. It setsfont-variant-numeric: tabular-nums
which makes numbers to have equal width.This is useful when you have columns with numbers and you want them to be aligned:
Update function in modals manager
Modals manager now supports
modals.updateModal
andmodals.updateContextModal
function to update modal after it was opened:
useForm submitting state
use-form hook now supports
form.submitting
fieldand
form.setSubmitting
function to track form submission state.form.submitting
field will be set totrue
if function passed toform.onSubmit
returns a promise. After the promise is resolved or rejected,form.submitting
will be set tofalse
:You can also manually set
form.submitting
totrue
orfalse
:useForm onSubmitPreventDefault option
use-form hook now supports
onSubmitPreventDefault
option.This option is useful if you want to integrate
useForm
hook with server actions.By default,
event.preventDefault()
is called on the formonSubmit
handler.If you want to change this behavior, you can pass
onSubmitPreventDefault
optionto
useForm
hook. It can have the following values:always
(default) - always callevent.preventDefault()
never
- never callevent.preventDefault()
validation-failed
- callevent.preventDefault()
only if validation failedSubtle RichTextEditor variant
RichTextEditor component now supports
subtle
variant:onExitTransitionEnd and onEnterTransitionEnd
Modal and Drawer components now support
onExitTransitionEnd
andonEnterTransitionEnd
props,which can be used to run code after exit/enter transition is finished. For example, this is useful when you want to clear
data after modal is closed:
Week numbers in DatePicker
DatePicker and other components based on Calendar component now support
withWeekNumbers
prop to display week numbers:New demo: BarChart with overlay
Variants types augmentation
Custom variants types augmentation guide was added to the documentation.
Example of adding custom variant type to Button component:
Help Center updates
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about these updates again.