@rolster/react-components 18.26.3 → 18.26.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/assets/{index-D9onGyQ8.css → index-BWk6HbJL.css} +41 -38
- package/dist/cjs/index.js +24 -16
- package/dist/cjs/index.js.map +1 -1
- package/dist/es/assets/{index-D9onGyQ8.css → index-BWk6HbJL.css} +41 -38
- package/dist/es/index.js +24 -16
- package/dist/es/index.js.map +1 -1
- package/dist/esm/components/atoms/Amount/Amount.css +1 -0
- package/dist/esm/components/atoms/Amount/Amount.css.map +1 -1
- package/dist/esm/components/atoms/Breadcrumb/Breadcrumb.css +2 -2
- package/dist/esm/components/atoms/Breadcrumb/Breadcrumb.css.map +1 -1
- package/dist/esm/components/atoms/RadioButton/RadioButton.css +2 -2
- package/dist/esm/components/atoms/RadioButton/RadioButton.css.map +1 -1
- package/dist/esm/components/molecules/Ballot/Ballot.css +14 -17
- package/dist/esm/components/molecules/Ballot/Ballot.css.map +1 -1
- package/dist/esm/components/molecules/ButtonToggle/ButtonToggle.css +4 -2
- package/dist/esm/components/molecules/ButtonToggle/ButtonToggle.css.map +1 -1
- package/dist/esm/components/molecules/MessageFormError/MessageFormError.js +1 -1
- package/dist/esm/components/molecules/PickerDay/PickerDay.css +4 -4
- package/dist/esm/components/molecules/PickerDay/PickerDay.css.map +1 -1
- package/dist/esm/components/molecules/PickerDayRange/PickerDayRange.css +4 -4
- package/dist/esm/components/molecules/PickerDayRange/PickerDayRange.css.map +1 -1
- package/dist/esm/components/molecules/Slider/Slider.css +1 -1
- package/dist/esm/components/molecules/Slider/Slider.css.map +1 -1
- package/dist/esm/components/molecules/Toolbar/Toolbar.css +1 -1
- package/dist/esm/components/molecules/Toolbar/Toolbar.css.map +1 -1
- package/dist/esm/components/organisms/Confirmation/Confirmation.css +4 -4
- package/dist/esm/components/organisms/Confirmation/Confirmation.css.map +1 -1
- package/dist/esm/components/organisms/ModalSheet/ModalSheet.css +4 -1
- package/dist/esm/components/organisms/ModalSheet/ModalSheet.css.map +1 -1
- package/dist/esm/helpers/language.js +23 -15
- package/dist/esm/helpers/language.js.map +1 -1
- package/package.json +4 -4
|
@@ -33,6 +33,7 @@
|
|
|
33
33
|
--pvt-decimal-size: var(--rlc-amount-decimal-size, 0.6);
|
|
34
34
|
--rlc-tabular-text-font-size: var(--pvt-font-size);
|
|
35
35
|
--rlc-tabular-text-font-weight: var(--pvt-font-weight);
|
|
36
|
+
--rlc-tabular-text-char-width: calc(var(--pvt-font-size) / 1.25);
|
|
36
37
|
display: flex;
|
|
37
38
|
width: var(--rlc-amount-width, auto);
|
|
38
39
|
justify-content: var(--rlc-amount-text-align, flex-start);
|
|
@@ -154,8 +155,8 @@
|
|
|
154
155
|
color: inherit;
|
|
155
156
|
line-height: inherit;
|
|
156
157
|
font-weight: var(--pvt-label-font-weight);
|
|
157
|
-
font-size: var(--pvt-label
|
|
158
|
-
letter-spacing: var(--pvt-label
|
|
158
|
+
font-size: var(--pvt-label-font-size);
|
|
159
|
+
letter-spacing: var(--pvt-label-letter-spacing);
|
|
159
160
|
}
|
|
160
161
|
.rls-breadcrumb__label:first-child::before {
|
|
161
162
|
display: none;
|
|
@@ -965,8 +966,8 @@
|
|
|
965
966
|
cursor: var(--rlc-radiobutton-cursor, initial);
|
|
966
967
|
}
|
|
967
968
|
.rls-radiobutton--checked {
|
|
968
|
-
--pvt-component-background: var(--rls-app-
|
|
969
|
-
background: var(--rls-theme-
|
|
969
|
+
--pvt-component-background: var(--rls-app-color-050);
|
|
970
|
+
background: var(--rls-theme-gradient-500);
|
|
970
971
|
border: var(--rls-theme-border-1-500);
|
|
971
972
|
}
|
|
972
973
|
.rls-radiobutton--disabled {
|
|
@@ -1112,18 +1113,22 @@
|
|
|
1112
1113
|
.rls-ballot {
|
|
1113
1114
|
--rlc-avatar-width: var(--rls-sizing-x20);
|
|
1114
1115
|
--rlc-avatar-height: var(--rls-sizing-x20);
|
|
1115
|
-
--pvt-title-letter-spacing: var(
|
|
1116
|
-
--rlc-ballot-title-letter-spacing,
|
|
1117
|
-
var(--rls-label-letter-spacing)
|
|
1118
|
-
);
|
|
1119
1116
|
--pvt-title-font-size: var(
|
|
1120
1117
|
--rlc-ballot-title-font-size,
|
|
1121
1118
|
var(--rls-label-font-size)
|
|
1122
1119
|
);
|
|
1120
|
+
--pvt-title-letter-spacing: var(
|
|
1121
|
+
--rlc-ballot-title-letter-spacing,
|
|
1122
|
+
var(--rls-label-letter-spacing)
|
|
1123
|
+
);
|
|
1123
1124
|
--pvt-title-height: var(
|
|
1124
1125
|
--rlc-ballot-title-height,
|
|
1125
1126
|
var(--rls-label-line-height)
|
|
1126
1127
|
);
|
|
1128
|
+
--pvt-subtitle-font-size: var(
|
|
1129
|
+
--rlc-ballot-subtitle-font-size,
|
|
1130
|
+
var(--rls-smalltext-font-size)
|
|
1131
|
+
);
|
|
1127
1132
|
--pvt-subtitle-letter-spacing: var(
|
|
1128
1133
|
--rlc-ballot-subtitle-letter-spacing,
|
|
1129
1134
|
var(--rls-smalltext-letter-spacing)
|
|
@@ -1134,7 +1139,7 @@
|
|
|
1134
1139
|
);
|
|
1135
1140
|
position: relative;
|
|
1136
1141
|
display: flex;
|
|
1137
|
-
width: 100
|
|
1142
|
+
width: var(--rlc-ballot-width, 100%);
|
|
1138
1143
|
align-items: center;
|
|
1139
1144
|
column-gap: var(--rls-sizing-x4);
|
|
1140
1145
|
padding: var(--rlc-ballot-padding, var(--rls-sizing-x4));
|
|
@@ -1158,9 +1163,9 @@
|
|
|
1158
1163
|
width: calc(100% - var(--rlc-avatar-width) - var(--rls-sizing-x4));
|
|
1159
1164
|
}
|
|
1160
1165
|
.rls-ballot__title {
|
|
1161
|
-
--rlc-skeleton-text-height: var(--pvt-title-height);
|
|
1162
|
-
--rlc-skeleton-text-letter-spacing: var(--pvt-title-letter-spacing);
|
|
1163
1166
|
--rlc-skeleton-text-font-size: var(--pvt-title-font-size);
|
|
1167
|
+
--rlc-skeleton-text-height: auto;
|
|
1168
|
+
--rlc-skeleton-text-letter-spacing: var(--pvt-title-letter-spacing);
|
|
1164
1169
|
position: relative;
|
|
1165
1170
|
width: 100%;
|
|
1166
1171
|
color: var(--rls-app-color-900);
|
|
@@ -1173,16 +1178,11 @@
|
|
|
1173
1178
|
);
|
|
1174
1179
|
font-size: var(--pvt-title-font-size);
|
|
1175
1180
|
letter-spacing: var(--pvt-title-letter-spacing);
|
|
1176
|
-
min-height: var(--pvt-title-height);
|
|
1177
|
-
line-height: var(--pvt-title-height);
|
|
1178
1181
|
}
|
|
1179
1182
|
.rls-ballot__subtitle {
|
|
1180
|
-
--rlc-skeleton-text-
|
|
1183
|
+
--rlc-skeleton-text-font-size: var(--pvt-subtitle-font-size);
|
|
1184
|
+
--rlc-skeleton-text-height: auto;
|
|
1181
1185
|
--rlc-skeleton-text-letter-spacing: var(--pvt-subtitle-letter-spacing);
|
|
1182
|
-
--rlc-skeleton-text-font-size: var(
|
|
1183
|
-
--rlc-ballot-subtitle-font-size,
|
|
1184
|
-
var(--rls-smalltext-font-size)
|
|
1185
|
-
);
|
|
1186
1186
|
position: relative;
|
|
1187
1187
|
width: var(--rlc-ballot-subtitle-width, 100%);
|
|
1188
1188
|
color: var(--rls-app-color-500);
|
|
@@ -1190,10 +1190,8 @@
|
|
|
1190
1190
|
--rlc-ballot-subtitle-font-weight,
|
|
1191
1191
|
var(--rls-font-weight-medium)
|
|
1192
1192
|
);
|
|
1193
|
-
font-size: var(--
|
|
1193
|
+
font-size: var(--pvt-subtitle-font-size);
|
|
1194
1194
|
letter-spacing: var(--pvt-subtitle-letter-spacing);
|
|
1195
|
-
min-height: var(--pvt-subtitle-height);
|
|
1196
|
-
line-height: var(--pvt-subtitle-height);
|
|
1197
1195
|
overflow: var(--rlc-ballot-subtitle-overflow, initial);
|
|
1198
1196
|
text-overflow: var(--rlc-ballot-subtitle-text-overflow, initial);
|
|
1199
1197
|
white-space: var(--rlc-ballot-subtitle-white-space, initial);
|
|
@@ -1268,6 +1266,8 @@
|
|
|
1268
1266
|
transform: var(--rlc-button-toggle-ul-transform);
|
|
1269
1267
|
transform-origin: 0% 0%;
|
|
1270
1268
|
box-shadow: 0px 0px 0px 3px var(--rls-theme-shadow-500);
|
|
1269
|
+
transition: transform 240ms 0ms var(--rls-standard-curve),
|
|
1270
|
+
opacity 240ms 0ms var(--rls-standard-curve);
|
|
1271
1271
|
}
|
|
1272
1272
|
.rls-button-toggle__list ul li {
|
|
1273
1273
|
padding: 0rem var(--rls-sizing-x6);
|
|
@@ -1276,8 +1276,8 @@
|
|
|
1276
1276
|
line-height: var(--rls-sizing-x20);
|
|
1277
1277
|
cursor: default;
|
|
1278
1278
|
font-weight: var(--rls-font-weight-semibold);
|
|
1279
|
-
font-size:
|
|
1280
|
-
letter-spacing:
|
|
1279
|
+
font-size: var(--rls-smalltext-font-size);
|
|
1280
|
+
letter-spacing: var(--rls-smalltext-letter-spacing);
|
|
1281
1281
|
text-transform: uppercase;
|
|
1282
1282
|
color: var(--rls-app-color-600);
|
|
1283
1283
|
}
|
|
@@ -1599,10 +1599,10 @@
|
|
|
1599
1599
|
height: var(--rls-sizing-x20);
|
|
1600
1600
|
line-height: var(--rls-sizing-x20);
|
|
1601
1601
|
text-align: center;
|
|
1602
|
-
font-size:
|
|
1602
|
+
font-size: var(--rls-caption-font-size);
|
|
1603
1603
|
color: var(--rls-app-color-600);
|
|
1604
1604
|
font-weight: var(--rls-font-weight-regular);
|
|
1605
|
-
letter-spacing:
|
|
1605
|
+
letter-spacing: var(--rls-caption-letter-spacing);
|
|
1606
1606
|
}
|
|
1607
1607
|
.rls-picker-day__component {
|
|
1608
1608
|
display: flex;
|
|
@@ -1652,13 +1652,13 @@
|
|
|
1652
1652
|
.rls-picker-day__element__span {
|
|
1653
1653
|
position: relative;
|
|
1654
1654
|
display: block;
|
|
1655
|
-
font-size:
|
|
1655
|
+
font-size: var(--rls-paragraph-font-size);
|
|
1656
1656
|
font-weight: var(--rls-font-weight-semibold);
|
|
1657
1657
|
border-radius: var(--rls-sizing-x4);
|
|
1658
1658
|
height: var(--rls-sizing-x18);
|
|
1659
1659
|
line-height: var(--rls-sizing-x18);
|
|
1660
1660
|
box-sizing: border-box;
|
|
1661
|
-
letter-spacing:
|
|
1661
|
+
letter-spacing: var(--rls-paragraph-letter-spacing);
|
|
1662
1662
|
box-shadow: var(--pvt-span-box-shadow);
|
|
1663
1663
|
}
|
|
1664
1664
|
.rls-picker-day__element__span:not(:hover) {
|
|
@@ -1701,10 +1701,10 @@
|
|
|
1701
1701
|
height: var(--rls-sizing-x20);
|
|
1702
1702
|
line-height: var(--rls-sizing-x20);
|
|
1703
1703
|
text-align: center;
|
|
1704
|
-
font-size:
|
|
1704
|
+
font-size: var(--rls-caption-font-size);
|
|
1705
1705
|
color: var(--rls-app-color-600);
|
|
1706
1706
|
font-weight: var(--rls-font-weight-regular);
|
|
1707
|
-
letter-spacing:
|
|
1707
|
+
letter-spacing: var(--rls-caption-letter-spacing);
|
|
1708
1708
|
}
|
|
1709
1709
|
.rls-picker-day-range__component {
|
|
1710
1710
|
display: flex;
|
|
@@ -1742,13 +1742,13 @@
|
|
|
1742
1742
|
.rls-picker-day-range__element__span {
|
|
1743
1743
|
position: relative;
|
|
1744
1744
|
display: block;
|
|
1745
|
-
font-size:
|
|
1745
|
+
font-size: var(--rls-paragraph-font-size);
|
|
1746
1746
|
font-weight: var(--rls-font-weight-semibold);
|
|
1747
1747
|
border-radius: var(--rls-sizing-x4);
|
|
1748
1748
|
height: var(--rls-sizing-x18);
|
|
1749
1749
|
line-height: var(--rls-sizing-x18);
|
|
1750
1750
|
box-sizing: border-box;
|
|
1751
|
-
letter-spacing:
|
|
1751
|
+
letter-spacing: var(--rls-paragraph-letter-spacing);
|
|
1752
1752
|
}
|
|
1753
1753
|
.rls-picker-day-range__element__span:not(:hover) {
|
|
1754
1754
|
background: var(--pvt-span-nothover-background);
|
|
@@ -1994,7 +1994,7 @@
|
|
|
1994
1994
|
height: var(--rls-sizing-x10);
|
|
1995
1995
|
line-height: var(--rls-sizing-x10);
|
|
1996
1996
|
text-align: center;
|
|
1997
|
-
font-size:
|
|
1997
|
+
font-size: var(--rls-micro-font-size);
|
|
1998
1998
|
font-weight: var(--rls-font-weight-medium);
|
|
1999
1999
|
color: var(--pvt-thumb-color);
|
|
2000
2000
|
z-index: var(--rls-z-index-4);
|
|
@@ -2071,7 +2071,7 @@
|
|
|
2071
2071
|
color: var(--rls-app-color-900);
|
|
2072
2072
|
height: var(--rls-sizing-x12);
|
|
2073
2073
|
line-height: var(--rls-sizing-x12);
|
|
2074
|
-
font-size:
|
|
2074
|
+
font-size: var(--rls-body-font-size);
|
|
2075
2075
|
letter-spacing: var(--rls-label-letter-spacing);
|
|
2076
2076
|
font-weight: var(--rls-font-weight-bold);
|
|
2077
2077
|
}
|
|
@@ -2211,9 +2211,9 @@
|
|
|
2211
2211
|
--pvt-subtitle-letter-spacing: var(--rls-body-letter-spacing);
|
|
2212
2212
|
--pvt-subtitle-line-height: var(--rls-body-line-height);
|
|
2213
2213
|
--pvt-subtitle-text-transform: initial;
|
|
2214
|
-
--pvt-content-font-size:
|
|
2215
|
-
--pvt-content-letter-spacing:
|
|
2216
|
-
--pvt-content-line-height:
|
|
2214
|
+
--pvt-content-font-size: var(--rls-input-font-size);
|
|
2215
|
+
--pvt-content-letter-spacing: var(--rls-input-letter-spacing);
|
|
2216
|
+
--pvt-content-line-height: var(--rls-input-line-height);
|
|
2217
2217
|
--pvt-backdrop-opacity: 0;
|
|
2218
2218
|
--pvt-backdrop-bottom: initial;
|
|
2219
2219
|
position: fixed;
|
|
@@ -2340,7 +2340,7 @@
|
|
|
2340
2340
|
--pvt-subtitle-font-size: var(--rls-smalltext-font-size);
|
|
2341
2341
|
--pvt-subtitle-letter-spacing: var(--rls-smalltext-letter-spacing);
|
|
2342
2342
|
--pvt-subtitle-line-height: var(--rls-smalltext-line-height);
|
|
2343
|
-
--pvt-content-font-size:
|
|
2343
|
+
--pvt-content-font-size: var(--rls-paragraph-font-size);
|
|
2344
2344
|
}
|
|
2345
2345
|
.rls-confirmation__header {
|
|
2346
2346
|
row-gap: var(--rls-sizing-x2);
|
|
@@ -2943,7 +2943,10 @@
|
|
|
2943
2943
|
);
|
|
2944
2944
|
--pvt-component-height: 0rem;
|
|
2945
2945
|
--pvt-component-max-height: calc(100% - var(--rls-sizing-x12));
|
|
2946
|
-
--pvt-component-border-radius: var(
|
|
2946
|
+
--pvt-component-border-radius: var(
|
|
2947
|
+
--rlc-modal-sheet-border-radius,
|
|
2948
|
+
var(--rls-sizing-x4)
|
|
2949
|
+
);
|
|
2947
2950
|
--pvt-component-opacity: 0;
|
|
2948
2951
|
--pvt-component-visibility: hidden;
|
|
2949
2952
|
--pvt-component-transition: 160ms;
|
package/dist/cjs/index.js
CHANGED
|
@@ -1723,10 +1723,11 @@ function RlsContent({ children, identifier, rlsTheme }) {
|
|
|
1723
1723
|
return (jsxRuntimeExports.jsx("div", { id: identifier, className: "rls-app__page__content", "rls-theme": rlsTheme, children: children }));
|
|
1724
1724
|
}
|
|
1725
1725
|
|
|
1726
|
-
const
|
|
1726
|
+
const errors = {
|
|
1727
1727
|
es: {
|
|
1728
1728
|
alphabetic: 'Campo solo permite caracteres',
|
|
1729
1729
|
alphanumber: 'Campo solo permite caracteres y número',
|
|
1730
|
+
checked: 'Campo debe ser seleccionado',
|
|
1730
1731
|
decimal: 'Campo debe ser número decimal',
|
|
1731
1732
|
defined: 'Campo debe estar definido',
|
|
1732
1733
|
email: 'Campo debe ser correo electrónico',
|
|
@@ -1737,18 +1738,19 @@ const errorsDictionary = {
|
|
|
1737
1738
|
maxValue: 'Campo debe tener un valor máximo de {thanValue}',
|
|
1738
1739
|
minValue: 'Campo debe tener un valor mínimo de {thanValue}',
|
|
1739
1740
|
nickname: 'Campo inválido para nombre de usuario',
|
|
1740
|
-
|
|
1741
|
+
onlyNumber: 'Campo debe ser númerico',
|
|
1741
1742
|
password: 'Campo no permitido para password',
|
|
1742
|
-
reqlength: 'Campo debe tener {length} caracter(es)',
|
|
1743
1743
|
required: 'Campo es requerido',
|
|
1744
1744
|
strMinlength: 'Campo debe tener mínimo {length} caracter(es)',
|
|
1745
1745
|
strMaxlength: 'Campo debe tener máximo {length} caracter(es)',
|
|
1746
|
+
strReqLength: 'Campo debe tener {length} caracter(es)',
|
|
1746
1747
|
textonly: 'Campo solo permite caracteres (sin espacio)',
|
|
1747
1748
|
_unknown: 'Campo inválido {error}'
|
|
1748
1749
|
},
|
|
1749
1750
|
en: {
|
|
1750
1751
|
alphabetic: 'Field only allows characters',
|
|
1751
1752
|
alphanumber: 'Field only allows characters and number',
|
|
1753
|
+
checked: 'Field must be selected',
|
|
1752
1754
|
decimal: 'Field must be decimal number',
|
|
1753
1755
|
defined: 'Field must be defined',
|
|
1754
1756
|
email: 'Field must be email',
|
|
@@ -1759,9 +1761,9 @@ const errorsDictionary = {
|
|
|
1759
1761
|
minValue: 'Field must have a minimum value of {thanValue}',
|
|
1760
1762
|
maxValue: 'Field must have a maximum value of {thanValue}',
|
|
1761
1763
|
nickname: 'Invalid field for username',
|
|
1762
|
-
|
|
1764
|
+
onlyNumber: 'Field must be numeric',
|
|
1763
1765
|
password: 'Field not allowed for password',
|
|
1764
|
-
|
|
1766
|
+
strReqLength: 'Field must be {length} characters',
|
|
1765
1767
|
required: 'Field is required',
|
|
1766
1768
|
strMinlength: 'Field must have minimum {length} characters',
|
|
1767
1769
|
strMaxlength: 'Field must have maximum {length} characters',
|
|
@@ -1771,6 +1773,7 @@ const errorsDictionary = {
|
|
|
1771
1773
|
fr: {
|
|
1772
1774
|
alphabetic: 'Field only allows characters',
|
|
1773
1775
|
alphanumber: 'Field only allows characters and number',
|
|
1776
|
+
checked: 'Field must be selected',
|
|
1774
1777
|
decimal: 'Field must be decimal number',
|
|
1775
1778
|
defined: 'Field must be defined',
|
|
1776
1779
|
email: 'Field must be email',
|
|
@@ -1781,9 +1784,9 @@ const errorsDictionary = {
|
|
|
1781
1784
|
minValue: 'Field must have a minimum value of {thanValue}',
|
|
1782
1785
|
maxValue: 'Field must have a maximum value of {thanValue}',
|
|
1783
1786
|
nickname: 'Invalid field for username',
|
|
1784
|
-
|
|
1787
|
+
onlyNumber: 'Field must be numeric',
|
|
1785
1788
|
password: 'Field not allowed for password',
|
|
1786
|
-
|
|
1789
|
+
strReqLength: 'Field must be {length} characters',
|
|
1787
1790
|
required: 'Field is required',
|
|
1788
1791
|
strMinlength: 'Field must have minimum {length} characters',
|
|
1789
1792
|
strMaxlength: 'Field must have maximum {length} characters',
|
|
@@ -1793,6 +1796,7 @@ const errorsDictionary = {
|
|
|
1793
1796
|
pt: {
|
|
1794
1797
|
alphabetic: 'Field only allows characters',
|
|
1795
1798
|
alphanumber: 'Field only allows characters and number',
|
|
1799
|
+
checked: 'Field must be selected',
|
|
1796
1800
|
decimal: 'Field must be decimal number',
|
|
1797
1801
|
defined: 'Field must be defined',
|
|
1798
1802
|
email: 'Field must be email',
|
|
@@ -1803,21 +1807,25 @@ const errorsDictionary = {
|
|
|
1803
1807
|
minValue: 'Field must have a minimum value of {thanValue}',
|
|
1804
1808
|
maxValue: 'Field must have a maximum value of {thanValue}',
|
|
1805
1809
|
nickname: 'Invalid field for username',
|
|
1806
|
-
|
|
1810
|
+
onlyNumber: 'Field must be numeric',
|
|
1807
1811
|
password: 'Field not allowed for password',
|
|
1808
|
-
|
|
1812
|
+
strReqLength: 'Field must be {length} characters',
|
|
1809
1813
|
required: 'Field is required',
|
|
1810
|
-
strMinlength: 'Field must have minimum {
|
|
1811
|
-
strMaxlength: 'Field must have maximum {
|
|
1814
|
+
strMinlength: 'Field must have minimum {length} characters',
|
|
1815
|
+
strMaxlength: 'Field must have maximum {length} characters',
|
|
1812
1816
|
textonly: 'Field only allows characters (no space)',
|
|
1813
1817
|
_unknown: 'Invalid field {error}'
|
|
1814
1818
|
}
|
|
1815
1819
|
};
|
|
1816
|
-
let _msgErrorsI18n = i18n.i18n(
|
|
1820
|
+
let _msgErrorsI18n = i18n.i18n(errors);
|
|
1817
1821
|
function setErrorsI18n(dictionary) {
|
|
1818
|
-
_msgErrorsI18n = i18n.i18n(Object.entries(
|
|
1819
|
-
|
|
1820
|
-
|
|
1822
|
+
_msgErrorsI18n = i18n.i18n(Object.entries(errors).reduce((errors, [key, value]) => {
|
|
1823
|
+
// Merge keys from dictionary in errors i18n
|
|
1824
|
+
errors[key] = {
|
|
1825
|
+
...value,
|
|
1826
|
+
...dictionary[key]
|
|
1827
|
+
};
|
|
1828
|
+
return errors;
|
|
1821
1829
|
}, {}));
|
|
1822
1830
|
}
|
|
1823
1831
|
function msgErrorsI18n(key, language, interpolators) {
|
|
@@ -1833,7 +1841,7 @@ function RlsMessageFormError({ className, formControl }) {
|
|
|
1833
1841
|
}, []);
|
|
1834
1842
|
const msgError = require$$0.useMemo(() => {
|
|
1835
1843
|
return (formControl?.error &&
|
|
1836
|
-
(msgErrorsI18n(formControl.error.id, language, formControl.error.data)
|
|
1844
|
+
(msgErrorsI18n(formControl.error.id, language, formControl.error.data) ||
|
|
1837
1845
|
msgErrorsI18n('_unknown', language, { error: formControl.error.id })));
|
|
1838
1846
|
}, [formControl?.error, language]);
|
|
1839
1847
|
return (jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: formControl?.wrong && (jsxRuntimeExports.jsx("div", { className: className, children: jsxRuntimeExports.jsx(RlsMessageIcon, { icon: "alert-triangle", rlsTheme: "danger", children: msgError }) })) }));
|