@hestia-earth/ui-components 0.43.2 → 0.43.4
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/fesm2022/hestia-earth-ui-components-file-errors.mjs +10 -6
- package/fesm2022/hestia-earth-ui-components-file-errors.mjs.map +1 -1
- package/fesm2022/hestia-earth-ui-components-svg-icons.mjs +1 -0
- package/fesm2022/hestia-earth-ui-components-svg-icons.mjs.map +1 -1
- package/fesm2022/hestia-earth-ui-components.mjs +6 -4
- package/fesm2022/hestia-earth-ui-components.mjs.map +1 -1
- package/package.json +1 -1
- package/svg-icons/icons-sprite.svg +1 -1
- package/types/hestia-earth-ui-components-svg-icons.d.ts +1 -1
|
@@ -627,12 +627,16 @@ const createErrorFormatter = ({ renderer: r, urls }) => {
|
|
|
627
627
|
? `This field can only be added to the ${schemaLink('Transformation#inputs', 'inputs of a Transformation')}.`
|
|
628
628
|
: schema?.required?.includes('otherSites')
|
|
629
629
|
? `Please only specify a single ${schemaLink('Cycle#site', 'site')} when the functional unit is ${code(CycleFunctionalUnit['1 ha'])}.`
|
|
630
|
-
:
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
630
|
+
: schema?.required?.includes('functionalArea')
|
|
631
|
+
? `The ${code('functionalArea')} field should only be used when ${code('site.area')} is missing. The
|
|
632
|
+
${code('mass')}/${code('area')}/${code('inputs')} should be expressed per the ${code('site.area')},
|
|
633
|
+
and the ${code('functionalArea')} field should be removed.`
|
|
634
|
+
: // termType restriction on the item
|
|
635
|
+
schema?.properties?.term?.properties?.termType?.enum?.length
|
|
636
|
+
? `This ${code('termType')} is not allowed here.`
|
|
637
|
+
: schema?.required
|
|
638
|
+
? `The following ${pluralize('field', schema.required.length)} should not be used: ${listAsCode(schema.required)}`
|
|
639
|
+
: 'Should not be used in this case.',
|
|
636
640
|
[patternErrorKey('^[0-9]{4}(-01)?(-01)?$')]: () => 'should be the first month/day of the year',
|
|
637
641
|
[patternErrorKey('^\\d{13}$')]: () => 'should be composed of 13 numbers',
|
|
638
642
|
'not a valid date': () => dateFormatMessage,
|