v11
This page lists the changes introduced in v11. It focuses on breaking changes, removals, and required migrations, grouped by area for clarity.
Migration
v11 of @dnb/eufemia contains breaking changes. As a migration process, you can simply search and replace:
Install
To upgrade to @dnb/eufemia v11 with NPM, use:
$ npm i @dnb/eufemia@11# or$ yarn add @dnb/eufemia@11# or$ pnpm add @dnb/eufemia@11
Summary of changes:
- All snake case (
on_click) events and properties has been converted to use camel case (onClick). The reason for previously using snake case was to support Web Components – but the support was discontinued in v10.
Components
Section
- Most
style_typevariants were removed. Use the newvariantorbackgroundColorproperty instead:mint-greensea-greenemerald-greenlavenderblack-3sand-yellowpistachiofire-redfire-red-8
- Remove
spacing. UseinnerSpaceinstead. - Replace
inner_refwithinnerRef.
HelpButton
Translations
- Replace
HelpButton.aria_rolewithHelpButton.ariaRole.
Autocomplete
- Replace
selected_keywithselectedKey. - Replace
default_valuewithdefaultValue. - Replace
prevent_selectionwithpreventSelection. - Replace
prevent_closewithpreventClose. - Replace
keep_openwithkeepOpen. - Replace
independent_widthwithindependentWidth. - Replace
fixed_postionwithfixedPosition. - Replace
enable_body_lockwithenableBodyLock. - Replace
align_drawerwithalignDrawer. - Replace
list_classwithlistClass. - Replace
portal_classwithportalClass. - Replace
no_scroll_animationwithnoScrollAnimation. - Replace
skip_portalwithskipPortal. - Replace
min_heightwithminHeight. - Replace
max_heightwithmaxHeight. - Replace
observer_elementwithobserverElement. - Replace
cache_hashwithcacheHash. - Replace
wrapper_elementwithwrapperElement. - Replace
options_renderwithoptionsRender. - Replace
triangle_positionwithtrianglePosition. - Replace
skip_keysearchwithskipKeysearch. - Replace
page_offsetwithpageOffset. - Replace
ignore_eventswithignoreEvents. - Replace
no_animationwithnoAnimation. - Replace
label_directionwithlabelDirection. - Replace
no_optionswithnoOptions. - Replace
show_allwithshowAll. - Replace
aria_live_optionswithariaLiveOptions. - Replace
indicator_labelwithindicatorLabel. - Replace
show_options_srwithshowOptionsSr. - Replace
selected_srwithselectedSr. - Replace
submit_button_titlewithsubmitButtonTitle. - Replace
submit_button_iconwithsubmitButtonIcon. - Replace
input_refwithinputRef. - Replace
icon_sizewithiconSize. - Replace
icon_positionwithiconPosition. - Replace
input_iconwithinputIcon. - Replace
label_sr_onlywithlabelSrOnly. - Replace
keep_valuewithkeepValue. - Replace
keep_selectionwithkeepSelection. - Replace
keep_value_and_selectionwithkeepValueAndSelection. - Replace
show_clear_buttonwithshowClearButton. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
disable_filterwithdisableFilter. - Replace
disable_reorderwithdisableReorder. - Replace
disable_highlightingwithdisableHighlighting. - Replace
show_submit_buttonwithshowSubmitButton. - Replace
submit_elementwithsubmitElement. - Replace
align_autocompletewithalignAutocomplete. - Replace
input_elementwithinputElement. - Replace
search_in_word_indexwithsearchInWordIndex. - Replace
search_numberswithsearchNumbers. - Replace
input_valuewithinputValue. - Replace
open_on_focuswithopenOnFocus. - Replace
drawer_classwithdrawerClass. - Replace
prevent_focuswithpreventFocus. - Replace
action_menuwithactionMenu. - Replace
is_popupwithisPopup.
Translations
- Replace
Autocomplete.no_optionswithAutocomplete.noOptions. - Replace
Autocomplete.show_allwithAutocomplete.showAll. - Replace
Autocomplete.aria_live_optionswithAutocomplete.ariaLiveOptions. - Replace
Autocomplete.indicator_labelwithAutocomplete.indicatorLabel. - Replace
Autocomplete.show_options_srwithAutocomplete.showOptionsSr. - Replace
Autocomplete.selected_srwithAutocomplete.selectedSr. - Replace
Autocomplete.submit_button_titlewithAutocomplete.submitButtonTitle.
DrawerListDataArrayObject
- Replace
selected_valuewithselectedValue. - Replace
suffix_valuewithsuffixValue. - Replace
search_contentwithsearchContent. - Replace
class_namewithclassName.
Dropdown
- Replace
selected_keywithselectedKey. - Replace
default_valuewithdefaultValue. - Replace
prevent_selectionwithpreventSelection. - Replace
prevent_closewithpreventClose. - Replace
keep_openwithkeepOpen. - Replace
independent_widthwithindependentWidth. - Replace
fixed_postionwithfixedPosition. - Replace
enable_body_lockwithenableBodyLock. - Replace
align_drawerwithalignDrawer. - Replace
list_classwithlistClass. - Replace
portal_classwithportalClass. - Replace
no_scroll_animationwithnoScrollAnimation. - Replace
skip_portalwithskipPortal. - Replace
min_heightwithminHeight. - Replace
max_heightwithmaxHeight. - Replace
observer_elementwithobserverElement. - Replace
cache_hashwithcacheHash. - Replace
wrapper_elementwithwrapperElement. - Replace
options_renderwithoptionsRender. - Replace
triangle_positionwithtrianglePosition. - Replace
skip_keysearchwithskipKeysearch. - Replace
page_offsetwithpageOffset. - Replace
ignore_eventswithignoreEvents. - Replace
no_animationwithnoAnimation. - Replace
label_directionwithlabelDirection. - Replace
icon_sizewithiconSize. - Replace
icon_positionwithiconPosition. - Replace
label_sr_onlywithlabelSrOnly. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
more_menuwithmoreMenu. - Replace
align_dropdownwithalignDropdown. - Replace
trigger_elementwithtriggerElement. - Replace
open_on_focuswithopenOnFocus. - Replace
action_menuwithactionMenu. - Replace
is_popupwithisPopup. - Replace
prevent_focuswithpreventFocus.
DrawerListDataArrayObject
- Replace
selected_valuewithselectedValue. - Replace
suffix_valuewithsuffixValue. - Replace
search_contentwithsearchContent. - Replace
class_namewithclassName.
DrawerList
- Replace type
DrawerListDataObjectUnionwithDrawerListDataArrayItem. - Replace type
DrawerListDataObjectwithDrawerListDataArrayObject. - Replace
import { ItemContent } from '@dnb/eufemia/fragments/drawer-list/DrawerList'withimport { ItemContent } from '@dnb/eufemia/fragments/drawer-list/DrawerListItem'. - Replace
selected_keywithselectedKey. - Replace
default_valuewithdefaultValue. - Replace
prevent_selectionwithpreventSelection. - Replace
prevent_closewithpreventClose. - Replace
keep_openwithkeepOpen. - Replace
independent_widthwithindependentWidth. - Replace
fixed_postionwithfixedPosition. - Replace
enable_body_lockwithenableBodyLock. - Replace
align_drawerwithalignDrawer. - Replace
list_classwithlistClass. - Replace
portal_classwithportalClass. - Replace
no_scroll_animationwithnoScrollAnimation. - Replace
skip_portalwithskipPortal. - Replace
min_heightwithminHeight. - Replace
max_heightwithmaxHeight. - Replace
observer_elementwithobserverElement. - Replace
cache_hashwithcacheHash. - Replace
wrapper_elementwithwrapperElement. - Replace
options_renderwithoptionsRender. - Replace
triangle_positionwithtrianglePosition. - Replace
skip_keysearchwithskipKeysearch. - Replace
page_offsetwithpageOffset. - Replace
ignore_eventswithignoreEvents. - Replace
no_animationwithnoAnimation. - Replace
label_directionwithlabelDirection. - Replace
action_menuwithactionMenu. - Replace
is_popupwithisPopup. - Replace
prevent_focuswithpreventFocus.
DrawerListDataArrayObject
- Replace
selected_valuewithselectedValue. - Replace
suffix_valuewithsuffixValue. - Replace
search_contentwithsearchContent. - Replace
class_namewithclassName.
Anchor
- When using icons in an Anchor (text link), use the
iconproperty instead of inlining it. - Find and remove
scrollToHashHandler. Smooth hash scrolling is now supported by all major browsers. - Replace
inner_refwithinnerRef.
Input
- Replace
label_directionwithlabelDirection. - Replace
label_sr_onlywithlabelSrOnly. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
input_statewithinputState. - Replace
submit_button_titlewithsubmitButtonTitle. - Replace
clear_button_titlewithclearButtonTitle. - Replace
keep_placeholderwithkeepPlaceholder. - Replace
input_classwithinputClass. - Replace
input_attributeswithinputAttributes. - Replace
input_elementwithinputElement. - Replace
icon_sizewithiconSize. - Replace
icon_positionwithiconPosition. - Replace
inner_refwithinnerRef. - Replace
inner_elementwithinnerElement. - Replace
submit_elementwithsubmitElement. - Replace
submit_button_variantwithsubmitButtonVariant. - Replace
submit_button_iconwithsubmitButtonIcon. - Replace
submit_button_statuswithsubmitButtonStatus.
SubmitButton (do we need to document this, I don't see any docs of this, but it's exposed/exported)
- Replace
icon_sizewithiconSize. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps.
InputMasked
- Replace
label_directionwithlabelDirection. - Replace
number_maskwithnumberMask. - Replace
currency_maskwithcurrencyMask. - Replace
mask_optionswithmaskOptions. - Replace
number_formatwithnumberFormat. - Replace
as_currencywithasCurrency. - Replace
as_numberwithasNumber. - Replace
as_percentwithasPercent. - Replace
show_maskwithshowMask. - Replace
show_guidewithshowGuide. - Replace
keep_char_positionswithkeepCharPositions. - Replace
placeholder_charwithplaceholderChar. - Replace
inner_refwithinnerRef. - Replace
label_sr_onlywithlabelSrOnly. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
input_statewithinputState. - Replace
submit_button_titlewithsubmitButtonTitle. - Replace
clear_button_titlewithclearButtonTitle. - Replace
keep_placeholderwithkeepPlaceholder. - Replace
input_classwithinputClass. - Replace
input_attributeswithinputAttributes. - Replace
input_elementwithinputElement. - Replace
icon_sizewithiconSize. - Replace
icon_positionwithiconPosition. - Replace
inner_elementwithinnerElement. - Replace
submit_elementwithsubmitElement. - Replace
submit_button_variantwithsubmitButtonVariant. - Replace
submit_button_iconwithsubmitButtonIcon. - Replace
submit_button_statuswithsubmitButtonStatus.
MultiInputMask
- Replace
label_directionwithlabelDirection.
FormLabel
- Replace
for_idwithforId. - Replace
sr_onlywithsrOnly.
Radio
- Replace
label_sr_onlywithlabelSrOnly. - Replace
label_positionwithlabelPosition. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
label_directionwithlabelDirection.
Radio.Group
- Replace
label_directionwithlabelDirection. - Replace
label_sr_onlywithlabelSrOnly. - Replace
label_positionwithlabelPosition. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
layout_directionwithlayoutDirection.
Textarea
- Replace
label_directionwithlabelDirection. - Replace
label_sr_onlywithlabelSrOnly. - Replace
textarea_statewithtextareaState. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
autoresize_max_rowswithautoresizeMaxRows. - Replace
textarea_classwithtextareaClass. - Replace
textarea_attributeswithtextareaAttributes. - Replace
inner_refwithinnerRef. - Replace
textarea_elementwithtextareaElement.
Accordion
- Replace
expandBehaviourwithexpandBehavior. - Replace
on_state_updatewithonStateUpdate. - Replace
expanded_ssrwithexpandedSsr. - Replace
heading_levelwithheadingLevel. - Replace
icon_sizewithiconSize. - Replace
single_containerwithsingleContainer. - Replace
left_componentwithleftComponent. - Replace
flush_remembered_statewithflushRememberedState. - Replace
on_changewithonChange. - Replace
icon_positionwithiconPosition. - Replace
prevent_rerender_conditionalwithpreventRerenderConditional. - Replace
remember_statewithrememberState. - Replace
prevent_rerenderwithpreventRerender. - Replace
no_animationwithnoAnimation.
Accordion.Group
- Replace
allow_close_allwithallowCloseAll. - Replace
expanded_idwithexpandedId.
Accordion.Provider
- Replace
expanded_idwithexpandedId.
Tag
- Replace
onDeletewithonClick, and addvariant="removable".
P
- Replace
medium={true}withweight='medium'. - Replace
bold={true}withweight='bold'. - Replace
modifierwith appropriateweightand/orsize. - Replace class
.dnb-p--mediumwith.dnb-t__weight--medium - Replace class
.dnb-p--boldwith.dnb-t__weight--bold - Replace class
.dnb-p__size--xx-largewith.dnb-t__size--xx-largeand.dnb-t__line-height--xx-large - Replace class
.dnb-p__size--x-largewith.dnb-t__size--x-largeand.dnb-t__line-height--x-large - Replace class
.dnb-p__size--largewith.dnb-t__size--largeand.dnb-t__line-height--large - Replace class
.dnb-p__size--basiswith.dnb-t__size--basisand.dnb-t__line-height--basis - Replace class
.dnb-p__size--mediumwith.dnb-t__size--mediumand.dnb-t__line-height--medium - Replace class
.dnb-p--smallor.dnb-p__size--smallwith.dnb-t__size--smalland.dnb-t__line-height--small - Replace class
.dnb-p--x-smallor.dnb-p__size--x-smallwith.dnb-t__size--x-smalland.dnb-t__line-height--x-small
Definition lists
- Replace
directionin<Dl>withlayout.
BreadcrumbItem
- Removed passing down properties to the internal
span.
We don't think this has been used for anything other than passing down data-testids for testing. We believe the potential side effects of passing down properties to this span are greater than the advantages it gives for those who want to test this span using data-testid as their way of selecting the span.
We recommend other testing methods to select and test the inner parts of Eufemia components. You could use, e.g., screen.queryByRole or document.querySelector.
For more context, see this PR.
ProgressIndicator
- Replace
no_animationwithnoAnimation. - Replace
indicator_labelwithindicatorLabel. - Replace translation
ProgressIndicator.indicator_labelwithProgressInidicator.indicatorLabel. - Replace
label_directionwithlabelDirection. - Replace
show_labelwithshowDefaultLabel. - Replace
on_completewithonComplete. - Replace
classwithclassName. - Replace
childrenwithlabel.
PaymentCard
- Remove translation
PaymentCard.text_card_numberas it's not supported anymore. - Replace
product_codewithproductCode. - Replace
card_numberwithcardNumber. - Replace
card_statuswithcardStatus. - Replace
raw_datawithrawData.
cardStatus property
- Replace value
not_activewithnotActive. - Replace value
order_in_processwithorderInProcess. - Replace value
new_orderwithnewOrder.
Translations
- Replace
PaymentCard.text_blockedwithPaymentCard.textBlocked. - Replace
PaymentCard.text_expiredwithPaymentCard.textExpired. - Replace
PaymentCard.text_not_activewithPaymentCard.textNotActive. - Replace
PaymentCard.text_new_orderwithPaymentCard.textNewOrder. - Replace
PaymentCard.text_order_in_processwithPaymentCard.textOrderInProcess. - Replace
PaymentCard.text_replacedwithPaymentCard.textReplaced. - Replace
PaymentCard.text_renewedwithPaymentCard.textRenewed. - Replace
PaymentCard.text_newwithPaymentCard.textNew. - Replace
PaymentCard.text_unknownwithPaymentCard.textUnknown.
Divider (Horizontal Rule)
- Remove
lightandmediumas they are not supported anymore. - Replace
fullscreenwithbreakout.
Card
- Remove
spacingproperty.
Checkbox
- Replace
label_positionwithlabelPosition. - Replace
label_sr_onlywithlabelSrOnly. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
on_changewithonChange. - Replace
childrenwithlabel.
Switch
- Replace
label_positionwithlabelPosition. - Replace
label_sr_onlywithlabelSrOnly. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
on_changewithonChange. - Replace
on_change_endwithonChangeEnd. - Replace
on_state_updatewithonStateUpdate. - Replace
status_no_animationwithstatusNoAnimation.
Logo
- Remove
brandprop. Import and use the desired SVG component directly (e.g.,DnbDefault,SbankenDefault,SbankenCompact,SbankenHorizontal,CarnegieDefault,EiendomDefault). - Remove
variantprop. Instead, import the specific variant directly (e.g.,SbankenCompactinstead ofbrand="sbanken" variant="compact"). - Remove
size. Replace it withheightif it contains a numeric value, and withinheritSizewheresize='inherit'. - Remove the following properties:
altandratio. - Replace
inherit_colorwithinheritColor. - Change
widthfrom number to string. - Change
heightfrom number to string.
Migration Example:
Before (v10):
import { Logo } from '@dnb/eufemia'render(<Logo brand="sbanken" variant="compact" />)
After (v11):
import { Logo, SbankenCompact } from '@dnb/eufemia/components/Logo'render(<Logo svg={SbankenCompact} />)
Icon
- Replace
inherit_colorwithinheritColor.
Button
- Replace
icon_positionwithiconPosition. - Replace
icon_sizewithiconSize. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
custom_contentwithcustomContent. - Replace
inner_refwithinnerRef.
Modal, Dialog and Drawer
- Replace
classwithclassName. - Replace
focus_selectorwithfocusSelector. - Replace
labelled_bywithlabelledBy. - Replace
open_delaywithopenDelay. - Replace
content_idwithcontentId. - Replace
dialog_titlewithdialogTitle. - Replace
close_titlewithcloseTitle. - Replace
hide_close_buttonwithhideCloseButton. - Replace
close_button_attributeswithcloseButtonAttributes. - Replace
prevent_closewithpreventClose. - Replace
prevent_core_stylewithpreventCoreStyle. - Replace
animation_durationwithanimationDuration. - Replace
no_animationwithnoAnimation. - Replace
no_animation_on_mobilewithnoAnimationOnMobile. - Replace
min_widthwithminWidth. - Replace
max_widthwithmaxWidth. - Replace
align_contentwithalignContent. - Replace
container_placementwithcontainerPlacement. - Replace
vertical_alignmentwithverticalAlignment. - Replace
open_statewithopenState. - Replace
direct_dom_returnwithdirectDomReturn. - Replace
root_idwithrootId. - Replace
omit_trigger_buttonwithomitTriggerButton. - Replace
on_openwithonOpen. - Replace
on_closewithonClose. - Replace
on_close_preventwithonClosePrevent. - Replace
open_modalwithopenModal. - Replace
close_modalwithcloseModal. - Replace
trigger_attributeswithtriggerAttributes. - Replace
overlay_classwithoverlayClass. - Replace
content_classwithcontentClass. - Replace
modal_contentwithmodalContent. - Replace
header_contentwithheaderContent. - Replace
bar_contentwithbarContent. - Replace
dialog_rolewithdialogRole. - Replace
bypass_invalidation_selectorswithbypassInvalidationSelectors. - Replace
content_refwithcontentRef. - Replace
scroll_refwithscrollRef. - Replace
prevent_overlay_closewithpreventOverlayClose.
Heading
- Replace
debug_counterwith debugCounter`. - Replace
skip_correctionwith skipCorrection`.
Table
- Replace
accordionwithmode="accordion".
FormStatus
- Replace
no_animationwithnoAnimation. - Replace
icon_sizewithiconSize. - Replace
text_idwithtextId. - Replace
width_selectorwithwidthSelector. - Replace
width_elementwithwidthElement.
Skeleton
- Replace
no_animationwithnoAnimation. - Replace
aria_busywithariaBusy. - Replace
aria_readywithariaReady. - Replace translation
Skeleton.aria_busywithSkeleton.ariaBusy. - Replace translation
Skeleton.aria_readywithSkeleton.ariaReady.
Tabs
- Replace
selected_keywithselectedKey. - Replace
content_stylewithcontentStyle. - Replace
content_spacingwithcontentSpacing. - Replace
tab_elementwithtabElement. - Replace
tabs_stylewithtabsStyle. - Replace
tabs_spacingwithtabsSpacing. - Replace
nav_button_edgewithnavButtonEdge. - Replace
preventRerenderwithpreventRerender. - Replace
on_changewithonChange. - Replace
on_clickwithonClick. - Replace
on_mouse_enterwithonMouseEnter. - Replace
on_focuswithonFocus. - Replace
focus_keywithfocusKey. - Replace
no_borderwithnoBorder.
Pagination
- Replace
place_maker_before_contentwithplaceMarkerBeforeContent. - Replace
startupPagewithstartupPage. - Replace
currentPagewithcurrentPage. - Replace
pageCountwithpageCount. - Replace
startupCountwithstartupCount. - Replace
parallelLoadCountwithparallelLoadCount. - Replace
minWaitTimewithminWaitTime. - Replace
useLoadButtonwithuseLoadButton. - Replace
hideProgressIndicatorwithhideProgressIndicator. - Replace
setContentHandlerwithsetContentHandler. - Replace
resetContentHandlerwithresetContentHandler. - Replace
resetPaginationHandlerwithresetPaginationHandler. - Replace
endInfinityHandlerwithendInfinityHandler. - Replace
pageElementwithpageElement. - Replace
fallbackElementwithfallbackElement. - Replace
markerElementwithmarkerElement. - Replace
indicatorElementwithindicatorElement. - Replace
buttonTitlewithbuttonTitle. - Replace
prevTitlewithprevTitle. - Replace
nextTitlewithnextTitle. - Replace
morePageswithmorePages. - Replace
isLoadingTextwithisLoadingText. - Replace
loadButtonTextwithloadButtonText.
Translations
- Replace
Pagination.buttonTitlewithPagination.buttonTitle. - Replace
Pagination.prevTitlewithPagination.prevTitle. - Replace
Pagination.nextTitlewithPagination.nextTitle. - Replace
Pagination.morePageswithPagination.morePages. - Replace
Pagination.isLoadingTextwithPagination.isLoadingText. - Replace
Pagination.loadButtonTextwithPagination.loadButtonText.
Timeline
Translations
- Replace
TimelineItem.alt_label_completedwithTimelineItem.altLabelCompleted. - Replace
TimelineItem.alt_label_currentwithTimelineItem.altLabelCurrent. - Replace
TimelineItem.alt_label_upomingwithTimelineItem.altLabelUpcoming.
DatePicker
- Find
correctInvalidDate/correct_invalid_dateand remove it. You may rather use Field.Date from Eufemia Forms when usingminDateandmaxDate, as this has built in validation. Reason for removing this is because we believe it's not good UX, or best practice to automatically change the user input. This often leads to confusion, as what they typed in, magically changes for seemingly no reason. We believe it's better to inform them about the error and let them correct it themselves. - Replace
start_datewithstartDate. - Replace
end_datewithendDate. - Replace
start_monthwithstartMonth. - Replace
end_monthwithendMonth. - Replace
min_datewithminDate. - Replace
max_datewithmaxDate. - Replace
mask_orderwithmaskOrder. - Replace
mask_placeholderwithmaskPlaceholder. - Replace
date_formatwithdateFormat. - Replace
return_formatwithreturnFormat. - Replace
hide_navigationwithhideNavigation. - Replace
hide_dayswithhideDays. - Replace
only_monthwithonlyMonth. - Replace
hide_last_weekwithhideLastWeek. - Replace
disable_autofocuswithdisableAutofocus. - Replace
enable_keyboard_navwithenableKeyboardNav. - Replace
show_inputwithshowInput. - Replace
show_submit_buttonwithshowSubmitButton. - Replace
show_cancel_buttonwithshowCancelButton. - Replace
show_reset_buttonwithshowResetButton. - Replace
submit_button_textwithsubmitButtonText. - Replace
cancel_button_textwithcancelButtonText. - Replace
reset_button_textwithresetButtonText. - Replace
reset_datewithresetDate. - Replace
first_daywithfirstDay. - Replace
label_directionwithlabelDirection. - Replace
label_sr_onlywithlabelSrOnly. - Replace
input_elementwithinputElement. - Replace
addon_elementwithaddonElement. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
prevent_closewithpreventClose. - Replace
no_animationwithnoAnimation. - Replace
align_pickerwithalignPicker. - Replace
on_days_renderwithonDaysRender. - Replace
on_changewithonChange. - Replace
on_typewithonType. - Replace
on_showwithonShow. - Replace
on_hidewithonHide. - Replace
on_submitwithonSubmit. - Replace
on_cancelwithonCancel. - Replace
on_resetwithonReset. - Replace
days_betweenwithdaysBetween. - Replace
is_validwithisValid. - Replace
is_valid_start_datewithisValidStartDate. - Replace
is_valid_end_datewithisValidEndDate. - Replace the
shortcutspropertyclose_on_selectwithcloseOnSelect.
NumberFormat
- Replace
omit_roundingwithrounding="omit". - Replace
currency_displaywithcurrencyDisplay. - Replace
currency_positionwithcurrencyPosition. - Replace
always_selectallwithalwaysSelectall. - Replace
copy_selectionwithcopySelection. - Replace
clean_copy_valuewithcleanCopyValue.
Translations
- Replace
NumberFormat.clipboard_copywithNumberFormat.clipboardCopy. - Replace
NumberFormat.not_availablewithNumberFormat.notAvailable.
StepIndicator
- Major redesign of component. There is now only one variant (instead of two).
- Remove
on_item_render. No longer has any other function than each step'stitleproperty. - Remove step item
on_render. No longer has any other function than thetitleproperty. - Remove
sidebarId. No longer has any sidebar. If an id is needed, use theidproperty. - Remove
step_title_extended. Onlystep_titleis needed. - Remove
StepIndicatorRenderCallbacktype. Not needed anymore. - Replace
is_currentwithisCurrent. - Replace
status_statewithstatusState. - Replace
current_stepwithcurrentStep. - Replace
overview_titlewithoverviewTitle. - Replace
step_titlewithstepTitle. - Replace
current_stepwithcurrentStep. - Replace
hide_numberswithhideNumbers. - Replace
status_statewithstatusState. - Replace
no_animationwithnoAnimation.
StepIndicator.Sidebar
- Component removed entirely after redesign. The variant that used this component no longer exists.
GlobalError
- Replace
statuswithstatusCode. - Replace
codewitherrorMessageCode. - Replace translation
GlobalError.codewithGlobalError.errorMessageCode.
ToggleButton
- Replace
icon_positionwithiconPosition. - Replace
icon_sizewithiconSize. - Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
left_componentwithleftComponent.
ToggleButton.Group
- Replace
status_statewithstatusState. - Replace
status_propswithstatusProps. - Replace
status_no_animationwithstatusNoAnimation. - Replace
label_directionwithlabelDirection. - Replace
label_sr_onlywithlabelSrOnly. - Replace
left_componentwithleftComponent. - Replace
layout_directionwithlayoutDirection.
GlobalStatus
Properties
- Replace
icon_sizewithiconSize. - Replace
no_animationwithnoAnimation. - Replace
hide_close_buttonwithhideCloseButton. - Replace
close_textwithcloseText. - Replace translation
GlobalStatus.close_textwithGlobalStatus.closeText. - Replace
default_titlewithdefaultTitle. - Replace translation
GlobalStatus.default_titlewithGlobalStatus.defaultTitle. - Replace
status_anchor_textwithstatusAnchorText. - Replace
omit_set_focuswithomitSetFocus. - Replace
omit_set_focus_on_updatewithomitSetFocusOnUpdate. - Replace
status_idwithstatusId. - Replace
status_anchor_urlwithstatusAnchorUrl. - Replace
status_anchor_textwithstatusAnchorText. - Replace
status_anchor_labelwithstatusAnchorLabel. - Replace
status_idwithstatusId. - Replace
buffer_delaywithbufferDelay. - Replace
on_close'sstatus_idwithstatusId.
GlobalStatusController
- Replace
remove_on_unmountwithremoveOnUnmount.
GlobalStatus.create
- Replace
status_idwithstatusId.
GlobalStatus.Remove
- Replace
status_idwithstatusId. - Replace
buffer_delaywithbufferDelay.
GlobalStatus.Add
- Replace
status_idwithstatusId.
GlobalStatus.Update
- Replace
status_idwithstatusId.
CopyOnClick
Translations
- Replace
CopyOnClick.clipboard_copywithCopyOnClick.clipboardCopy.
Layout
Space
- Replace
no_collapsewithnoCollapse.
Flex
- Replace
spacingwithgapon all Flex components. rowGapno longer accepts valuetrue. Replacetruewithundefinedor remove the property to get the same behavior.
Removal of FormRow and FormSet
For more information on how to replace these, see FormSet/FormRow deprecation.
- Replace
<FormRow>with<Flex.Horizontal align="baseline">. - Replace
<FormRow vertical>with<Flex.Vertical>. - Replace
<FormRow centered>with<Flex.Horizontal align="center">. - Replace
FormRow=withformElement=. - Replace
FormRow:withformElement:. - Replace
import { includeValidProps } from '@dnb/eufemia/components/form-row/FormRowHelpers'withimport { pickFormElementProps } from '@dnb/eufemia/shared/helpers/filterValidProps'. - Replace
import { prepareFormRowContext } from '@dnb/eufemia/components/form-row/FormRowHelpers'withimport { prepareFormElementContext } from '@dnb/eufemia/shared/helpers/filterValidProps'.
Helpers
Component helpers
- Remove
extendGracefully, it no longer exists.
Eufemia Forms
General
- Replace
Form.useErrorMessagewith your error messages as an object in theerrorMessagesproperty (e.g., with auseMemohook). - Replace
Form.useErrorwithForm.useValidation. - Replace
Form.useLocalewithForm.useLocation. - Replace
internal.errorwitherror. - Replace Form.Iterate label variable
{itemNr}with{itemNo}. - Replace
Form.FieldPropswithField.Provider. - Replace
<Card stack>...</Card>with<Form.Card>...</Form.Card>. - Replace
<Card>...</Card>with<Form.Card>...</Form.Card>. - Replace
StepsLayoutwithWizard.Container. - Replace
StepsLayout.StepwithWizard.Step. - Replace
StepsLayout.NextButtonwithWizard.Buttons. - Replace
StepsLayout.PreviousButtonwithWizard.Buttons. - Replace
StepsLayout.ButtonswithWizard.Buttons. - Replace
StepsLayout.useStepwithWizard.useStep. - Replace
Iterate.ArrayPushButtonwithIterate.PushButton. - Replace
Iterate.ArrayRemoveElementButtonwithIterate.RemoveButton.
Docs: Eufemia Forms
Ajv no longer shipped by default
Breaking Change: Ajv is no longer included as a dependency in Eufemia Forms v11. This reduces bundle size for applications that don't use JSON Schema validation.
Migration Required: If you use JSON Schema validation with Ajv, you must:
Update your imports and usage:
Before (v10):
import { Form, Field, JSONSchema } from '@dnb/eufemia/extensions/forms'const schema: JSONSchema = {type: 'object',properties: {myField: { type: 'string', minLength: 3 },},required: ['myField'],}function MyApp() {return (<Form.Handler schema={schema}><Field.String path="/myField" label="Label" /></Form.Handler>)}
After (v11):
import {Form,Field,JSONSchema,makeAjvInstance,} from '@dnb/eufemia/extensions/forms'const ajvInstance = makeAjvInstance()const schema: JSONSchema = {type: 'object',properties: {myField: { type: 'string', minLength: 3 },},required: ['myField'],}function MyApp() {return (<Form.Handler schema={schema} ajvInstance={ajvInstance}><Field.String path="/myField" label="Label" /></Form.Handler>)}
Alternative: Consider using Zod schemas instead, which provide better TypeScript integration and are included by default:
import { Form, Field, z } from '@dnb/eufemia/extensions/forms'const schema = z.object({myField: z.string().min(3),})function MyApp() {return (<Form.Handler schema={schema}><Field.String path="/myField" label="Label" /></Form.Handler>)}
InputPassword moved to Field.Password
The InputPassword component has been moved to Field.Password, and is now a part of Eufemia Forms. Change your import statement from import InputPassword from '@dnb/eufemia/components/input/InputPassword' to import { Field } from '@dnb/eufemia/extensions/forms'.
Docs: Input, All Fields
Error handling
FormError
validationRule
// Fromnew FormError('Invalid value', {validationRule: 'pattern',})// Tonew FormError('Field.errorPattern')
- Remove the
validationRuleparameter in favor of a translation key, like so:new FormError('Field.errorRequired').
errorMessages object
// Fromconst errorMessages = {pattern: 'Show this when "pattern" fails!',}// Toconst errorMessages = {'Field.errorPattern': 'Show this when "pattern" fails!',}
- Replace
requiredwithField.errorRequired. - Replace
patternwithField.errorPattern. - Replace
minLengthwithStringField.errorMinLength. - Replace
maxLengthwithStringField.errorMaxLength. - Replace
minimumwithNumberField.errorMinimum. - Replace
maximumwithNumberField.errorMaximum. - Replace
exclusiveMinimumwithNumberField.errorExclusiveMinimum. - Replace
exclusiveMaximumwithNumberField.errorExclusiveMaximum. - Replace
multipleOfwithNumberField.errorMultipleOf.
useErrorMessage
- Removed. Provide your error messages as an object in the
errorMessagesproperty (e.g., with auseMemohook).
See also: Form error messages, useValidation
Form.Visibility
- Replace
continuousValidationwithvalidateContinuously. - Replace
withValuewithhasValue. - Replace
pathValuewith usingvisibleWhen. - Replace
whenValuewith usingvisibleWhen.
Every Field.* component
- Replace
continuousValidationwithvalidateContinuously. - Replace
validatorwithonChangeValidator.
Docs: All Fields
Field.PostalCodeAndCity
- Replace
countrywithcountryCode.
Field.Selection
data property
- Replace
selected_valuewithselectedValue. - Replace
suffix_valuewithsuffixValue. - Replace
search_contentwithsearchContent. - Replace
class_namewithclassName.
Field.Password
- Replace
on_show_passwordwithonShowPassword. - Replace
on_hide_passwordwithonHidePassword. - Replace
show_passwordwith translationPassword.ariaLabelShow. - Replace
hide_passwordwith translationPassword.ariaLabelHide.
Iterate.PushContainer
- Replace
requireCommitwithpreventUncommittedChanges.
Wizard.Container
- Remove
variant. No longer has any variants. - Remove
scrollTopOnStepChange, as it's now enabled by default. You can disable it withomitScrollManagement. - Remove
sidebarId. No longer has any sidebar. If an id is needed, use theidproperty.
Wizard.Step
- Replace
activewithinclude. - Replace
activeWhenwithincludeWhen.
November 14, 2025