@bpmn-io/form-js-editor 0.12.1 → 0.12.2
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/index.cjs
CHANGED
|
@@ -887,7 +887,7 @@ function Palette(props) {
|
|
|
887
887
|
return jsxRuntime.jsxs("div", {
|
|
888
888
|
class: "fjs-palette-field fjs-drag-copy fjs-no-drop",
|
|
889
889
|
"data-field-type": type,
|
|
890
|
-
title: `Create
|
|
890
|
+
title: `Create ${getIndefiniteArticle(type)} ${label} element`,
|
|
891
891
|
children: [Icon ? jsxRuntime.jsx(Icon, {
|
|
892
892
|
class: "fjs-palette-field-icon",
|
|
893
893
|
width: "36",
|
|
@@ -926,6 +926,12 @@ function groupEntries(entries) {
|
|
|
926
926
|
});
|
|
927
927
|
return groups.filter(g => g.entries.length);
|
|
928
928
|
}
|
|
929
|
+
function getIndefiniteArticle(type) {
|
|
930
|
+
if (['image'].includes(type)) {
|
|
931
|
+
return 'an';
|
|
932
|
+
}
|
|
933
|
+
return 'a';
|
|
934
|
+
}
|
|
929
935
|
|
|
930
936
|
const CURSOR_CLS_PATTERN = /^fjs-cursor-.*$/;
|
|
931
937
|
function set(mode) {
|
|
@@ -5734,6 +5740,7 @@ function Description(props) {
|
|
|
5734
5740
|
});
|
|
5735
5741
|
}
|
|
5736
5742
|
|
|
5743
|
+
const EMPTY_OPTION = null;
|
|
5737
5744
|
function DefaultOptionEntry(props) {
|
|
5738
5745
|
const {
|
|
5739
5746
|
editField,
|
|
@@ -5879,13 +5886,14 @@ function DefaultValueSingleSelect(props) {
|
|
|
5879
5886
|
label
|
|
5880
5887
|
} = props;
|
|
5881
5888
|
const {
|
|
5882
|
-
defaultValue,
|
|
5889
|
+
defaultValue = EMPTY_OPTION,
|
|
5883
5890
|
values = []
|
|
5884
5891
|
} = field;
|
|
5885
5892
|
const path = ['defaultValue'];
|
|
5886
5893
|
const getOptions = () => {
|
|
5887
5894
|
return [{
|
|
5888
|
-
label: '<none>'
|
|
5895
|
+
label: '<none>',
|
|
5896
|
+
value: EMPTY_OPTION
|
|
5889
5897
|
}, ...values];
|
|
5890
5898
|
};
|
|
5891
5899
|
const setValue = value => {
|