@bpmn-io/properties-panel 3.24.0 → 3.25.0
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/LICENSE +20 -20
- package/README.md +35 -35
- package/assets/properties-panel.css +3 -3
- package/dist/assets/properties-panel.css +1509 -1505
- package/dist/index.esm.js +536 -538
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +536 -538
- package/dist/index.js.map +1 -1
- package/package.json +91 -91
package/dist/index.esm.js
CHANGED
|
@@ -24,6 +24,21 @@ ArrowIcon.defaultProps = {
|
|
|
24
24
|
width: "16",
|
|
25
25
|
height: "16"
|
|
26
26
|
};
|
|
27
|
+
var CloseIcon = function CloseIcon(props) {
|
|
28
|
+
return jsx("svg", {
|
|
29
|
+
...props,
|
|
30
|
+
children: jsx("path", {
|
|
31
|
+
fillRule: "evenodd",
|
|
32
|
+
d: "m12 4.7-.7-.7L8 7.3 4.7 4l-.7.7L7.3 8 4 11.3l.7.7L8 8.7l3.3 3.3.7-.7L8.7 8 12 4.7Z",
|
|
33
|
+
fill: "currentColor"
|
|
34
|
+
})
|
|
35
|
+
});
|
|
36
|
+
};
|
|
37
|
+
CloseIcon.defaultProps = {
|
|
38
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
39
|
+
width: "16",
|
|
40
|
+
height: "16"
|
|
41
|
+
};
|
|
27
42
|
var CreateIcon = function CreateIcon(props) {
|
|
28
43
|
return jsx("svg", {
|
|
29
44
|
...props,
|
|
@@ -111,26 +126,17 @@ FeelIcon$1.defaultProps = {
|
|
|
111
126
|
fill: "none",
|
|
112
127
|
xmlns: "http://www.w3.org/2000/svg"
|
|
113
128
|
};
|
|
114
|
-
var
|
|
129
|
+
var LaunchIcon = function LaunchIcon(props) {
|
|
115
130
|
return jsxs("svg", {
|
|
116
131
|
...props,
|
|
117
132
|
children: [jsx("path", {
|
|
118
|
-
d: "
|
|
119
|
-
}), jsx("circle", {
|
|
120
|
-
cx: "16",
|
|
121
|
-
cy: "23.5",
|
|
122
|
-
r: "1.5"
|
|
133
|
+
d: "M26 28H6a2.003 2.003 0 0 1-2-2V6a2.003 2.003 0 0 1 2-2h10v2H6v20h20V16h2v10a2.003 2.003 0 0 1-2 2Z"
|
|
123
134
|
}), jsx("path", {
|
|
124
|
-
d: "
|
|
125
|
-
}), jsx("path", {
|
|
126
|
-
style: {
|
|
127
|
-
fill: "none"
|
|
128
|
-
},
|
|
129
|
-
d: "M0 0h32v32H0z"
|
|
135
|
+
d: "M20 2v2h6.586L18 12.586 19.414 14 28 5.414V12h2V2H20z"
|
|
130
136
|
})]
|
|
131
137
|
});
|
|
132
138
|
};
|
|
133
|
-
|
|
139
|
+
LaunchIcon.defaultProps = {
|
|
134
140
|
xmlns: "http://www.w3.org/2000/svg",
|
|
135
141
|
viewBox: "0 0 32 32"
|
|
136
142
|
};
|
|
@@ -152,21 +158,6 @@ PopupIcon.defaultProps = {
|
|
|
152
158
|
height: "16",
|
|
153
159
|
viewBox: "0 0 32 32"
|
|
154
160
|
};
|
|
155
|
-
var CloseIcon = function CloseIcon(props) {
|
|
156
|
-
return jsx("svg", {
|
|
157
|
-
...props,
|
|
158
|
-
children: jsx("path", {
|
|
159
|
-
fillRule: "evenodd",
|
|
160
|
-
d: "m12 4.7-.7-.7L8 7.3 4.7 4l-.7.7L7.3 8 4 11.3l.7.7L8 8.7l3.3 3.3.7-.7L8.7 8 12 4.7Z",
|
|
161
|
-
fill: "currentColor"
|
|
162
|
-
})
|
|
163
|
-
});
|
|
164
|
-
};
|
|
165
|
-
CloseIcon.defaultProps = {
|
|
166
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
167
|
-
width: "16",
|
|
168
|
-
height: "16"
|
|
169
|
-
};
|
|
170
161
|
|
|
171
162
|
function Header(props) {
|
|
172
163
|
const {
|
|
@@ -206,7 +197,7 @@ function Header(props) {
|
|
|
206
197
|
}), jsx("div", {
|
|
207
198
|
class: "bio-properties-panel-header-actions",
|
|
208
199
|
children: documentationRef ? jsx("a", {
|
|
209
|
-
rel: "
|
|
200
|
+
rel: "noreferrer",
|
|
210
201
|
class: "bio-properties-panel-header-link",
|
|
211
202
|
href: documentationRef,
|
|
212
203
|
title: "Open documentation",
|
|
@@ -226,19 +217,19 @@ const ErrorsContext = createContext({
|
|
|
226
217
|
errors: {}
|
|
227
218
|
});
|
|
228
219
|
|
|
229
|
-
/**
|
|
230
|
-
* @typedef {Function} <propertiesPanel.showEntry> callback
|
|
231
|
-
*
|
|
232
|
-
* @example
|
|
233
|
-
*
|
|
234
|
-
* useEvent('propertiesPanel.showEntry', ({ focus = false, ...rest }) => {
|
|
235
|
-
* // ...
|
|
236
|
-
* });
|
|
237
|
-
*
|
|
238
|
-
* @param {Object} context
|
|
239
|
-
* @param {boolean} [context.focus]
|
|
240
|
-
*
|
|
241
|
-
* @returns void
|
|
220
|
+
/**
|
|
221
|
+
* @typedef {Function} <propertiesPanel.showEntry> callback
|
|
222
|
+
*
|
|
223
|
+
* @example
|
|
224
|
+
*
|
|
225
|
+
* useEvent('propertiesPanel.showEntry', ({ focus = false, ...rest }) => {
|
|
226
|
+
* // ...
|
|
227
|
+
* });
|
|
228
|
+
*
|
|
229
|
+
* @param {Object} context
|
|
230
|
+
* @param {boolean} [context.focus]
|
|
231
|
+
*
|
|
232
|
+
* @returns void
|
|
242
233
|
*/
|
|
243
234
|
|
|
244
235
|
const EventContext = createContext({
|
|
@@ -257,20 +248,20 @@ const TooltipContext = createContext({
|
|
|
257
248
|
getTooltipForId: () => {}
|
|
258
249
|
});
|
|
259
250
|
|
|
260
|
-
/**
|
|
261
|
-
* Accesses the global TooltipContext and returns a tooltip for a given id and element.
|
|
262
|
-
*
|
|
263
|
-
* @example
|
|
264
|
-
* ```jsx
|
|
265
|
-
* function TextField(props) {
|
|
266
|
-
* const tooltip = useTooltipContext('input1', element);
|
|
267
|
-
* }
|
|
268
|
-
* ```
|
|
269
|
-
*
|
|
270
|
-
* @param {string} id
|
|
271
|
-
* @param {object} element
|
|
272
|
-
*
|
|
273
|
-
* @returns {string}
|
|
251
|
+
/**
|
|
252
|
+
* Accesses the global TooltipContext and returns a tooltip for a given id and element.
|
|
253
|
+
*
|
|
254
|
+
* @example
|
|
255
|
+
* ```jsx
|
|
256
|
+
* function TextField(props) {
|
|
257
|
+
* const tooltip = useTooltipContext('input1', element);
|
|
258
|
+
* }
|
|
259
|
+
* ```
|
|
260
|
+
*
|
|
261
|
+
* @param {string} id
|
|
262
|
+
* @param {object} element
|
|
263
|
+
*
|
|
264
|
+
* @returns {string}
|
|
274
265
|
*/
|
|
275
266
|
function useTooltipContext(id, element) {
|
|
276
267
|
const {
|
|
@@ -423,20 +414,20 @@ function prefixId$9(id) {
|
|
|
423
414
|
return `bio-properties-panel-${id}`;
|
|
424
415
|
}
|
|
425
416
|
|
|
426
|
-
/**
|
|
427
|
-
* Accesses the global DescriptionContext and returns a description for a given id and element.
|
|
428
|
-
*
|
|
429
|
-
* @example
|
|
430
|
-
* ```jsx
|
|
431
|
-
* function TextField(props) {
|
|
432
|
-
* const description = useDescriptionContext('input1', element);
|
|
433
|
-
* }
|
|
434
|
-
* ```
|
|
435
|
-
*
|
|
436
|
-
* @param {string} id
|
|
437
|
-
* @param {object} element
|
|
438
|
-
*
|
|
439
|
-
* @returns {string}
|
|
417
|
+
/**
|
|
418
|
+
* Accesses the global DescriptionContext and returns a description for a given id and element.
|
|
419
|
+
*
|
|
420
|
+
* @example
|
|
421
|
+
* ```jsx
|
|
422
|
+
* function TextField(props) {
|
|
423
|
+
* const description = useDescriptionContext('input1', element);
|
|
424
|
+
* }
|
|
425
|
+
* ```
|
|
426
|
+
*
|
|
427
|
+
* @param {string} id
|
|
428
|
+
* @param {object} element
|
|
429
|
+
*
|
|
430
|
+
* @returns {string}
|
|
440
431
|
*/
|
|
441
432
|
function useDescriptionContext(id, element) {
|
|
442
433
|
const {
|
|
@@ -458,11 +449,11 @@ function useErrors() {
|
|
|
458
449
|
return errors;
|
|
459
450
|
}
|
|
460
451
|
|
|
461
|
-
/**
|
|
462
|
-
* Subscribe to an event immediately. Update subscription after inputs changed.
|
|
463
|
-
*
|
|
464
|
-
* @param {string} event
|
|
465
|
-
* @param {Function} callback
|
|
452
|
+
/**
|
|
453
|
+
* Subscribe to an event immediately. Update subscription after inputs changed.
|
|
454
|
+
*
|
|
455
|
+
* @param {string} event
|
|
456
|
+
* @param {Function} callback
|
|
466
457
|
*/
|
|
467
458
|
function useEvent(event, callback, eventBus) {
|
|
468
459
|
const eventContext = useContext(EventContext);
|
|
@@ -494,24 +485,24 @@ function useEvent(event, callback, eventBus) {
|
|
|
494
485
|
|
|
495
486
|
const KEY_LENGTH = 6;
|
|
496
487
|
|
|
497
|
-
/**
|
|
498
|
-
* Create a persistent key factory for plain objects without id.
|
|
499
|
-
*
|
|
500
|
-
* @example
|
|
501
|
-
* ```jsx
|
|
502
|
-
* function List({ objects }) {
|
|
503
|
-
* const getKey = useKeyFactory();
|
|
504
|
-
* return (<ol>{
|
|
505
|
-
* objects.map(obj => {
|
|
506
|
-
* const key = getKey(obj);
|
|
507
|
-
* return <li key={key}>obj.name</li>
|
|
508
|
-
* })
|
|
509
|
-
* }</ol>);
|
|
510
|
-
* }
|
|
511
|
-
* ```
|
|
512
|
-
*
|
|
513
|
-
* @param {any[]} dependencies
|
|
514
|
-
* @returns {(element: object) => string}
|
|
488
|
+
/**
|
|
489
|
+
* Create a persistent key factory for plain objects without id.
|
|
490
|
+
*
|
|
491
|
+
* @example
|
|
492
|
+
* ```jsx
|
|
493
|
+
* function List({ objects }) {
|
|
494
|
+
* const getKey = useKeyFactory();
|
|
495
|
+
* return (<ol>{
|
|
496
|
+
* objects.map(obj => {
|
|
497
|
+
* const key = getKey(obj);
|
|
498
|
+
* return <li key={key}>obj.name</li>
|
|
499
|
+
* })
|
|
500
|
+
* }</ol>);
|
|
501
|
+
* }
|
|
502
|
+
* ```
|
|
503
|
+
*
|
|
504
|
+
* @param {any[]} dependencies
|
|
505
|
+
* @returns {(element: object) => string}
|
|
515
506
|
*/
|
|
516
507
|
function useKeyFactory(dependencies = []) {
|
|
517
508
|
const map = useMemo(() => new Map(), dependencies);
|
|
@@ -526,20 +517,20 @@ function useKeyFactory(dependencies = []) {
|
|
|
526
517
|
return getKey;
|
|
527
518
|
}
|
|
528
519
|
|
|
529
|
-
/**
|
|
530
|
-
* Creates a state that persists in the global LayoutContext.
|
|
531
|
-
*
|
|
532
|
-
* @example
|
|
533
|
-
* ```jsx
|
|
534
|
-
* function Group(props) {
|
|
535
|
-
* const [ open, setOpen ] = useLayoutState([ 'groups', 'foo', 'open' ], false);
|
|
536
|
-
* }
|
|
537
|
-
* ```
|
|
538
|
-
*
|
|
539
|
-
* @param {(string|number)[]} path
|
|
540
|
-
* @param {any} [defaultValue]
|
|
541
|
-
*
|
|
542
|
-
* @returns {[ any, Function ]}
|
|
520
|
+
/**
|
|
521
|
+
* Creates a state that persists in the global LayoutContext.
|
|
522
|
+
*
|
|
523
|
+
* @example
|
|
524
|
+
* ```jsx
|
|
525
|
+
* function Group(props) {
|
|
526
|
+
* const [ open, setOpen ] = useLayoutState([ 'groups', 'foo', 'open' ], false);
|
|
527
|
+
* }
|
|
528
|
+
* ```
|
|
529
|
+
*
|
|
530
|
+
* @param {(string|number)[]} path
|
|
531
|
+
* @param {any} [defaultValue]
|
|
532
|
+
*
|
|
533
|
+
* @returns {[ any, Function ]}
|
|
543
534
|
*/
|
|
544
535
|
function useLayoutState(path, defaultValue) {
|
|
545
536
|
const {
|
|
@@ -553,11 +544,11 @@ function useLayoutState(path, defaultValue) {
|
|
|
553
544
|
return [layoutForKey, setState];
|
|
554
545
|
}
|
|
555
546
|
|
|
556
|
-
/**
|
|
557
|
-
* @pinussilvestrus: we need to introduce our own hook to persist the previous
|
|
558
|
-
* state on updates.
|
|
559
|
-
*
|
|
560
|
-
* cf. https://reactjs.org/docs/hooks-faq.html#how-to-get-the-previous-props-or-state
|
|
547
|
+
/**
|
|
548
|
+
* @pinussilvestrus: we need to introduce our own hook to persist the previous
|
|
549
|
+
* state on updates.
|
|
550
|
+
*
|
|
551
|
+
* cf. https://reactjs.org/docs/hooks-faq.html#how-to-get-the-previous-props-or-state
|
|
561
552
|
*/
|
|
562
553
|
|
|
563
554
|
function usePrevious(value) {
|
|
@@ -568,12 +559,12 @@ function usePrevious(value) {
|
|
|
568
559
|
return ref.current;
|
|
569
560
|
}
|
|
570
561
|
|
|
571
|
-
/**
|
|
572
|
-
* Subscribe to `propertiesPanel.showEntry`.
|
|
573
|
-
*
|
|
574
|
-
* @param {string} id
|
|
575
|
-
*
|
|
576
|
-
* @returns {import('preact').Ref}
|
|
562
|
+
/**
|
|
563
|
+
* Subscribe to `propertiesPanel.showEntry`.
|
|
564
|
+
*
|
|
565
|
+
* @param {string} id
|
|
566
|
+
*
|
|
567
|
+
* @returns {import('preact').Ref}
|
|
577
568
|
*/
|
|
578
569
|
function useShowEntryEvent(id) {
|
|
579
570
|
const {
|
|
@@ -604,20 +595,20 @@ function useShowEntryEvent(id) {
|
|
|
604
595
|
return ref;
|
|
605
596
|
}
|
|
606
597
|
|
|
607
|
-
/**
|
|
608
|
-
* @callback setSticky
|
|
609
|
-
* @param {boolean} value
|
|
598
|
+
/**
|
|
599
|
+
* @callback setSticky
|
|
600
|
+
* @param {boolean} value
|
|
610
601
|
*/
|
|
611
602
|
|
|
612
|
-
/**
|
|
613
|
-
* Use IntersectionObserver to identify when DOM element is in sticky mode.
|
|
614
|
-
* If sticky is observered setSticky(true) will be called.
|
|
615
|
-
* If sticky mode is left, setSticky(false) will be called.
|
|
616
|
-
*
|
|
617
|
-
*
|
|
618
|
-
* @param {Object} ref
|
|
619
|
-
* @param {string} scrollContainerSelector
|
|
620
|
-
* @param {setSticky} setSticky
|
|
603
|
+
/**
|
|
604
|
+
* Use IntersectionObserver to identify when DOM element is in sticky mode.
|
|
605
|
+
* If sticky is observered setSticky(true) will be called.
|
|
606
|
+
* If sticky mode is left, setSticky(false) will be called.
|
|
607
|
+
*
|
|
608
|
+
*
|
|
609
|
+
* @param {Object} ref
|
|
610
|
+
* @param {string} scrollContainerSelector
|
|
611
|
+
* @param {setSticky} setSticky
|
|
621
612
|
*/
|
|
622
613
|
function useStickyIntersectionObserver(ref, scrollContainerSelector, setSticky) {
|
|
623
614
|
const [scrollContainer, setScrollContainer] = useState(query(scrollContainerSelector));
|
|
@@ -671,19 +662,19 @@ function useStickyIntersectionObserver(ref, scrollContainerSelector, setSticky)
|
|
|
671
662
|
}, [ref.current, scrollContainer, setSticky]);
|
|
672
663
|
}
|
|
673
664
|
|
|
674
|
-
/**
|
|
675
|
-
* Creates a static function reference with changing body.
|
|
676
|
-
* This is necessary when external libraries require a callback function
|
|
677
|
-
* that has references to state variables.
|
|
678
|
-
*
|
|
679
|
-
* Usage:
|
|
680
|
-
* const callback = useStaticCallback((val) => {val === currentState});
|
|
681
|
-
*
|
|
682
|
-
* The `callback` reference is static and can be safely used in external
|
|
683
|
-
* libraries or as a prop that does not cause rerendering of children.
|
|
684
|
-
*
|
|
685
|
-
* @param {Function} callback function with changing reference
|
|
686
|
-
* @returns {Function} static function reference
|
|
665
|
+
/**
|
|
666
|
+
* Creates a static function reference with changing body.
|
|
667
|
+
* This is necessary when external libraries require a callback function
|
|
668
|
+
* that has references to state variables.
|
|
669
|
+
*
|
|
670
|
+
* Usage:
|
|
671
|
+
* const callback = useStaticCallback((val) => {val === currentState});
|
|
672
|
+
*
|
|
673
|
+
* The `callback` reference is static and can be safely used in external
|
|
674
|
+
* libraries or as a prop that does not cause rerendering of children.
|
|
675
|
+
*
|
|
676
|
+
* @param {Function} callback function with changing reference
|
|
677
|
+
* @returns {Function} static function reference
|
|
687
678
|
*/
|
|
688
679
|
function useStaticCallback(callback) {
|
|
689
680
|
const callbackRef = useRef(callback);
|
|
@@ -826,13 +817,13 @@ function DataMarker(props) {
|
|
|
826
817
|
return null;
|
|
827
818
|
}
|
|
828
819
|
|
|
829
|
-
/**
|
|
830
|
-
* @typedef { {
|
|
831
|
-
* text: (element: object) => string,
|
|
832
|
-
* icon?: (element: Object) => import('preact').Component
|
|
833
|
-
* } } PlaceholderDefinition
|
|
834
|
-
*
|
|
835
|
-
* @param { PlaceholderDefinition } props
|
|
820
|
+
/**
|
|
821
|
+
* @typedef { {
|
|
822
|
+
* text: (element: object) => string,
|
|
823
|
+
* icon?: (element: Object) => import('preact').Component
|
|
824
|
+
* } } PlaceholderDefinition
|
|
825
|
+
*
|
|
826
|
+
* @param { PlaceholderDefinition } props
|
|
836
827
|
*/
|
|
837
828
|
function Placeholder(props) {
|
|
838
829
|
const {
|
|
@@ -871,9 +862,9 @@ function Description(props) {
|
|
|
871
862
|
|
|
872
863
|
const noop$6 = () => {};
|
|
873
864
|
|
|
874
|
-
/**
|
|
875
|
-
* Buffer `.focus()` calls while the editor is not initialized.
|
|
876
|
-
* Set Focus inside when the editor is ready.
|
|
865
|
+
/**
|
|
866
|
+
* Buffer `.focus()` calls while the editor is not initialized.
|
|
867
|
+
* Set Focus inside when the editor is ready.
|
|
877
868
|
*/
|
|
878
869
|
const useBufferedFocus$1 = function (editor, ref) {
|
|
879
870
|
const [buffer, setBuffer] = useState(undefined);
|
|
@@ -974,9 +965,9 @@ const CodeEditor$1 = forwardRef((props, ref) => {
|
|
|
974
965
|
|
|
975
966
|
const noop$5 = () => {};
|
|
976
967
|
|
|
977
|
-
/**
|
|
978
|
-
* Buffer `.focus()` calls while the editor is not initialized.
|
|
979
|
-
* Set Focus inside when the editor is ready.
|
|
968
|
+
/**
|
|
969
|
+
* Buffer `.focus()` calls while the editor is not initialized.
|
|
970
|
+
* Set Focus inside when the editor is ready.
|
|
980
971
|
*/
|
|
981
972
|
const useBufferedFocus = function (editor, ref) {
|
|
982
973
|
const [buffer, setBuffer] = useState(undefined);
|
|
@@ -1025,10 +1016,10 @@ const CodeEditor = forwardRef((props, ref) => {
|
|
|
1025
1016
|
useEffect(() => {
|
|
1026
1017
|
let editor;
|
|
1027
1018
|
|
|
1028
|
-
/* Trigger FEEL toggle when
|
|
1029
|
-
*
|
|
1030
|
-
* - `backspace` is pressed
|
|
1031
|
-
* - AND the cursor is at the beginning of the input
|
|
1019
|
+
/* Trigger FEEL toggle when
|
|
1020
|
+
*
|
|
1021
|
+
* - `backspace` is pressed
|
|
1022
|
+
* - AND the cursor is at the beginning of the input
|
|
1032
1023
|
*/
|
|
1033
1024
|
const onKeyDown = e => {
|
|
1034
1025
|
if (e.key !== 'Backspace' || !editor) {
|
|
@@ -1119,10 +1110,10 @@ function FeelIndicator(props) {
|
|
|
1119
1110
|
|
|
1120
1111
|
const noop$4 = () => {};
|
|
1121
1112
|
|
|
1122
|
-
/**
|
|
1123
|
-
* @param {Object} props
|
|
1124
|
-
* @param {Object} props.label
|
|
1125
|
-
* @param {String} props.feel
|
|
1113
|
+
/**
|
|
1114
|
+
* @param {Object} props
|
|
1115
|
+
* @param {Object} props.label
|
|
1116
|
+
* @param {String} props.feel
|
|
1126
1117
|
*/
|
|
1127
1118
|
function FeelIcon(props) {
|
|
1128
1119
|
const {
|
|
@@ -1157,22 +1148,22 @@ const FeelPopupContext = createContext({
|
|
|
1157
1148
|
source: null
|
|
1158
1149
|
});
|
|
1159
1150
|
|
|
1160
|
-
/**
|
|
1161
|
-
* Add a dragger that calls back the passed function with
|
|
1162
|
-
* { event, delta } on drag.
|
|
1163
|
-
*
|
|
1164
|
-
* @example
|
|
1165
|
-
*
|
|
1166
|
-
* function dragMove(event, delta) {
|
|
1167
|
-
* // we are dragging (!!)
|
|
1168
|
-
* }
|
|
1169
|
-
*
|
|
1170
|
-
* domElement.addEventListener('dragstart', dragger(dragMove));
|
|
1171
|
-
*
|
|
1172
|
-
* @param {Function} fn
|
|
1173
|
-
* @param {Element} [dragPreview]
|
|
1174
|
-
*
|
|
1175
|
-
* @return {Function} drag start callback function
|
|
1151
|
+
/**
|
|
1152
|
+
* Add a dragger that calls back the passed function with
|
|
1153
|
+
* { event, delta } on drag.
|
|
1154
|
+
*
|
|
1155
|
+
* @example
|
|
1156
|
+
*
|
|
1157
|
+
* function dragMove(event, delta) {
|
|
1158
|
+
* // we are dragging (!!)
|
|
1159
|
+
* }
|
|
1160
|
+
*
|
|
1161
|
+
* domElement.addEventListener('dragstart', dragger(dragMove));
|
|
1162
|
+
*
|
|
1163
|
+
* @param {Function} fn
|
|
1164
|
+
* @param {Element} [dragPreview]
|
|
1165
|
+
*
|
|
1166
|
+
* @return {Function} drag start callback function
|
|
1176
1167
|
*/
|
|
1177
1168
|
function createDragger(fn, dragPreview) {
|
|
1178
1169
|
let self;
|
|
@@ -1227,23 +1218,23 @@ function emptyCanvas() {
|
|
|
1227
1218
|
|
|
1228
1219
|
const noop$3 = () => {};
|
|
1229
1220
|
|
|
1230
|
-
/**
|
|
1231
|
-
* A generic popup component.
|
|
1232
|
-
*
|
|
1233
|
-
* @param {Object} props
|
|
1234
|
-
* @param {HTMLElement} [props.container]
|
|
1235
|
-
* @param {string} [props.className]
|
|
1236
|
-
* @param {boolean} [props.delayInitialFocus]
|
|
1237
|
-
* @param {{x: number, y: number}} [props.position]
|
|
1238
|
-
* @param {number} [props.width]
|
|
1239
|
-
* @param {number} [props.height]
|
|
1240
|
-
* @param {Function} props.onClose
|
|
1241
|
-
* @param {Function} [props.onPostActivate]
|
|
1242
|
-
* @param {Function} [props.onPostDeactivate]
|
|
1243
|
-
* @param {boolean} [props.returnFocus]
|
|
1244
|
-
* @param {boolean} [props.closeOnEscape]
|
|
1245
|
-
* @param {string} props.title
|
|
1246
|
-
* @param {Ref} [ref]
|
|
1221
|
+
/**
|
|
1222
|
+
* A generic popup component.
|
|
1223
|
+
*
|
|
1224
|
+
* @param {Object} props
|
|
1225
|
+
* @param {HTMLElement} [props.container]
|
|
1226
|
+
* @param {string} [props.className]
|
|
1227
|
+
* @param {boolean} [props.delayInitialFocus]
|
|
1228
|
+
* @param {{x: number, y: number}} [props.position]
|
|
1229
|
+
* @param {number} [props.width]
|
|
1230
|
+
* @param {number} [props.height]
|
|
1231
|
+
* @param {Function} props.onClose
|
|
1232
|
+
* @param {Function} [props.onPostActivate]
|
|
1233
|
+
* @param {Function} [props.onPostDeactivate]
|
|
1234
|
+
* @param {boolean} [props.returnFocus]
|
|
1235
|
+
* @param {boolean} [props.closeOnEscape]
|
|
1236
|
+
* @param {string} props.title
|
|
1237
|
+
* @param {Ref} [ref]
|
|
1247
1238
|
*/
|
|
1248
1239
|
function PopupComponent(props, globalRef) {
|
|
1249
1240
|
const {
|
|
@@ -1462,12 +1453,12 @@ function getContainerNode(node) {
|
|
|
1462
1453
|
const FEEL_POPUP_WIDTH = 700;
|
|
1463
1454
|
const FEEL_POPUP_HEIGHT = 250;
|
|
1464
1455
|
|
|
1465
|
-
/**
|
|
1466
|
-
* FEEL popup component, built as a singleton. Emits lifecycle events as follows:
|
|
1467
|
-
* - `feelPopup.open` - fired before the popup is mounted
|
|
1468
|
-
* - `feelPopup.opened` - fired after the popup is mounted. Event context contains the DOM node of the popup
|
|
1469
|
-
* - `feelPopup.close` - fired before the popup is unmounted. Event context contains the DOM node of the popup
|
|
1470
|
-
* - `feelPopup.closed` - fired after the popup is unmounted
|
|
1456
|
+
/**
|
|
1457
|
+
* FEEL popup component, built as a singleton. Emits lifecycle events as follows:
|
|
1458
|
+
* - `feelPopup.open` - fired before the popup is mounted
|
|
1459
|
+
* - `feelPopup.opened` - fired after the popup is mounted. Event context contains the DOM node of the popup
|
|
1460
|
+
* - `feelPopup.close` - fired before the popup is unmounted. Event context contains the DOM node of the popup
|
|
1461
|
+
* - `feelPopup.closed` - fired after the popup is unmounted
|
|
1471
1462
|
*/
|
|
1472
1463
|
function FEELPopupRoot(props) {
|
|
1473
1464
|
const {
|
|
@@ -1477,7 +1468,8 @@ function FEELPopupRoot(props) {
|
|
|
1477
1468
|
on() {},
|
|
1478
1469
|
off() {}
|
|
1479
1470
|
},
|
|
1480
|
-
popupContainer
|
|
1471
|
+
popupContainer,
|
|
1472
|
+
getPopupLinks = () => []
|
|
1481
1473
|
} = props;
|
|
1482
1474
|
const prevElement = usePrevious(element);
|
|
1483
1475
|
const [popupConfig, setPopupConfig] = useState({});
|
|
@@ -1552,6 +1544,7 @@ function FEELPopupRoot(props) {
|
|
|
1552
1544
|
children: [open && jsx(FeelPopupComponent, {
|
|
1553
1545
|
onClose: handleClose,
|
|
1554
1546
|
container: popupContainer,
|
|
1547
|
+
getLinks: getPopupLinks,
|
|
1555
1548
|
sourceElement: sourceElement,
|
|
1556
1549
|
emit: emit,
|
|
1557
1550
|
...popupConfig
|
|
@@ -1561,6 +1554,7 @@ function FEELPopupRoot(props) {
|
|
|
1561
1554
|
function FeelPopupComponent(props) {
|
|
1562
1555
|
const {
|
|
1563
1556
|
container,
|
|
1557
|
+
getLinks,
|
|
1564
1558
|
id,
|
|
1565
1559
|
hostLanguage,
|
|
1566
1560
|
onInput,
|
|
@@ -1630,24 +1624,24 @@ function FeelPopupComponent(props) {
|
|
|
1630
1624
|
height: FEEL_POPUP_HEIGHT,
|
|
1631
1625
|
width: FEEL_POPUP_WIDTH,
|
|
1632
1626
|
ref: popupRef,
|
|
1633
|
-
children: [
|
|
1627
|
+
children: [jsx(Popup.Title, {
|
|
1634
1628
|
title: title,
|
|
1635
1629
|
emit: emit,
|
|
1636
1630
|
showCloseButton: true,
|
|
1637
1631
|
closeButtonTooltip: "Save and close",
|
|
1638
1632
|
onClose: onClose,
|
|
1639
1633
|
draggable: true,
|
|
1640
|
-
children:
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
})
|
|
1634
|
+
children: jsx(Fragment, {
|
|
1635
|
+
children: getLinks(type).map((link, index) => {
|
|
1636
|
+
return jsxs("a", {
|
|
1637
|
+
rel: "noreferrer",
|
|
1638
|
+
href: link.href,
|
|
1639
|
+
target: "_blank",
|
|
1640
|
+
class: "bio-properties-panel-feel-popup__title-link",
|
|
1641
|
+
children: [link.title, jsx(LaunchIcon, {})]
|
|
1642
|
+
}, index);
|
|
1643
|
+
})
|
|
1644
|
+
})
|
|
1651
1645
|
}), jsx(Popup.Body, {
|
|
1652
1646
|
children: jsxs("div", {
|
|
1653
1647
|
onKeyDownCapture: onKeyDownCapture,
|
|
@@ -1690,11 +1684,11 @@ function autoCompletionOpen(element) {
|
|
|
1690
1684
|
return element.closest('.cm-editor').querySelector('.cm-tooltip-autocomplete');
|
|
1691
1685
|
}
|
|
1692
1686
|
|
|
1693
|
-
/**
|
|
1694
|
-
* This hook behaves like useEffect, but does not trigger on the first render.
|
|
1695
|
-
*
|
|
1696
|
-
* @param {Function} effect
|
|
1697
|
-
* @param {Array} deps
|
|
1687
|
+
/**
|
|
1688
|
+
* This hook behaves like useEffect, but does not trigger on the first render.
|
|
1689
|
+
*
|
|
1690
|
+
* @param {Function} effect
|
|
1691
|
+
* @param {Array} deps
|
|
1698
1692
|
*/
|
|
1699
1693
|
function useUpdateEffect(effect, deps) {
|
|
1700
1694
|
const isMounted = useRef(false);
|
|
@@ -1772,19 +1766,19 @@ function ToggleSwitch(props) {
|
|
|
1772
1766
|
});
|
|
1773
1767
|
}
|
|
1774
1768
|
|
|
1775
|
-
/**
|
|
1776
|
-
* @param {Object} props
|
|
1777
|
-
* @param {Object} props.element
|
|
1778
|
-
* @param {String} props.id
|
|
1779
|
-
* @param {String} props.description
|
|
1780
|
-
* @param {String} props.label
|
|
1781
|
-
* @param {String} props.switcherLabel
|
|
1782
|
-
* @param {Boolean} props.inline
|
|
1783
|
-
* @param {Function} props.getValue
|
|
1784
|
-
* @param {Function} props.setValue
|
|
1785
|
-
* @param {Function} props.onFocus
|
|
1786
|
-
* @param {Function} props.onBlur
|
|
1787
|
-
* @param {string|import('preact').Component} props.tooltip
|
|
1769
|
+
/**
|
|
1770
|
+
* @param {Object} props
|
|
1771
|
+
* @param {Object} props.element
|
|
1772
|
+
* @param {String} props.id
|
|
1773
|
+
* @param {String} props.description
|
|
1774
|
+
* @param {String} props.label
|
|
1775
|
+
* @param {String} props.switcherLabel
|
|
1776
|
+
* @param {Boolean} props.inline
|
|
1777
|
+
* @param {Function} props.getValue
|
|
1778
|
+
* @param {Function} props.setValue
|
|
1779
|
+
* @param {Function} props.onFocus
|
|
1780
|
+
* @param {Function} props.onBlur
|
|
1781
|
+
* @param {string|import('preact').Component} props.tooltip
|
|
1788
1782
|
*/
|
|
1789
1783
|
function ToggleSwitchEntry(props) {
|
|
1790
1784
|
const {
|
|
@@ -1892,22 +1886,22 @@ function NumberField(props) {
|
|
|
1892
1886
|
});
|
|
1893
1887
|
}
|
|
1894
1888
|
|
|
1895
|
-
/**
|
|
1896
|
-
* @param {Object} props
|
|
1897
|
-
* @param {Boolean} props.debounce
|
|
1898
|
-
* @param {String} props.description
|
|
1899
|
-
* @param {Boolean} props.disabled
|
|
1900
|
-
* @param {Object} props.element
|
|
1901
|
-
* @param {Function} props.getValue
|
|
1902
|
-
* @param {String} props.id
|
|
1903
|
-
* @param {String} props.label
|
|
1904
|
-
* @param {String} props.max
|
|
1905
|
-
* @param {String} props.min
|
|
1906
|
-
* @param {Function} props.setValue
|
|
1907
|
-
* @param {Function} props.onFocus
|
|
1908
|
-
* @param {Function} props.onBlur
|
|
1909
|
-
* @param {String} props.step
|
|
1910
|
-
* @param {Function} props.validate
|
|
1889
|
+
/**
|
|
1890
|
+
* @param {Object} props
|
|
1891
|
+
* @param {Boolean} props.debounce
|
|
1892
|
+
* @param {String} props.description
|
|
1893
|
+
* @param {Boolean} props.disabled
|
|
1894
|
+
* @param {Object} props.element
|
|
1895
|
+
* @param {Function} props.getValue
|
|
1896
|
+
* @param {String} props.id
|
|
1897
|
+
* @param {String} props.label
|
|
1898
|
+
* @param {String} props.max
|
|
1899
|
+
* @param {String} props.min
|
|
1900
|
+
* @param {Function} props.setValue
|
|
1901
|
+
* @param {Function} props.onFocus
|
|
1902
|
+
* @param {Function} props.onBlur
|
|
1903
|
+
* @param {String} props.step
|
|
1904
|
+
* @param {Function} props.validate
|
|
1911
1905
|
*/
|
|
1912
1906
|
function NumberFieldEntry(props) {
|
|
1913
1907
|
const {
|
|
@@ -2053,12 +2047,13 @@ function FeelTextfieldComponent(props) {
|
|
|
2053
2047
|
setFocus(-1);
|
|
2054
2048
|
}
|
|
2055
2049
|
};
|
|
2056
|
-
const handleLint = useStaticCallback(lint => {
|
|
2057
|
-
|
|
2050
|
+
const handleLint = useStaticCallback((lint = []) => {
|
|
2051
|
+
const syntaxError = lint.some(report => report.type === 'Syntax Error');
|
|
2052
|
+
if (syntaxError) {
|
|
2053
|
+
onError('Unparsable FEEL expression.');
|
|
2054
|
+
} else {
|
|
2058
2055
|
onError(undefined);
|
|
2059
|
-
return;
|
|
2060
2056
|
}
|
|
2061
|
-
onError('Unparsable FEEL expression.');
|
|
2062
2057
|
});
|
|
2063
2058
|
const handlePopupOpen = (type = 'feel') => {
|
|
2064
2059
|
const popupOptions = {
|
|
@@ -2392,26 +2387,26 @@ const OptionalFeelCheckbox = forwardRef((props, ref) => {
|
|
|
2392
2387
|
});
|
|
2393
2388
|
});
|
|
2394
2389
|
|
|
2395
|
-
/**
|
|
2396
|
-
* @param {Object} props
|
|
2397
|
-
* @param {Object} props.element
|
|
2398
|
-
* @param {String} props.id
|
|
2399
|
-
* @param {String} props.description
|
|
2400
|
-
* @param {Boolean} props.debounce
|
|
2401
|
-
* @param {Boolean} props.disabled
|
|
2402
|
-
* @param {Boolean} props.feel
|
|
2403
|
-
* @param {String} props.label
|
|
2404
|
-
* @param {Function} props.getValue
|
|
2405
|
-
* @param {Function} props.setValue
|
|
2406
|
-
* @param {Function} props.tooltipContainer
|
|
2407
|
-
* @param {Function} props.validate
|
|
2408
|
-
* @param {Function} props.show
|
|
2409
|
-
* @param {Function} props.example
|
|
2410
|
-
* @param {Function} props.variables
|
|
2411
|
-
* @param {Function} props.onFocus
|
|
2412
|
-
* @param {Function} props.onBlur
|
|
2413
|
-
* @param {string} [props.placeholder]
|
|
2414
|
-
* @param {string|import('preact').Component} props.tooltip
|
|
2390
|
+
/**
|
|
2391
|
+
* @param {Object} props
|
|
2392
|
+
* @param {Object} props.element
|
|
2393
|
+
* @param {String} props.id
|
|
2394
|
+
* @param {String} props.description
|
|
2395
|
+
* @param {Boolean} props.debounce
|
|
2396
|
+
* @param {Boolean} props.disabled
|
|
2397
|
+
* @param {Boolean} props.feel
|
|
2398
|
+
* @param {String} props.label
|
|
2399
|
+
* @param {Function} props.getValue
|
|
2400
|
+
* @param {Function} props.setValue
|
|
2401
|
+
* @param {Function} props.tooltipContainer
|
|
2402
|
+
* @param {Function} props.validate
|
|
2403
|
+
* @param {Function} props.show
|
|
2404
|
+
* @param {Function} props.example
|
|
2405
|
+
* @param {Function} props.variables
|
|
2406
|
+
* @param {Function} props.onFocus
|
|
2407
|
+
* @param {Function} props.onBlur
|
|
2408
|
+
* @param {string} [props.placeholder]
|
|
2409
|
+
* @param {string|import('preact').Component} props.tooltip
|
|
2415
2410
|
*/
|
|
2416
2411
|
function FeelEntry(props) {
|
|
2417
2412
|
const {
|
|
@@ -2498,27 +2493,27 @@ function FeelEntry(props) {
|
|
|
2498
2493
|
});
|
|
2499
2494
|
}
|
|
2500
2495
|
|
|
2501
|
-
/**
|
|
2502
|
-
* @param {Object} props
|
|
2503
|
-
* @param {Object} props.element
|
|
2504
|
-
* @param {String} props.id
|
|
2505
|
-
* @param {String} props.description
|
|
2506
|
-
* @param {Boolean} props.debounce
|
|
2507
|
-
* @param {Boolean} props.disabled
|
|
2508
|
-
* @param {String} props.max
|
|
2509
|
-
* @param {String} props.min
|
|
2510
|
-
* @param {String} props.step
|
|
2511
|
-
* @param {Boolean} props.feel
|
|
2512
|
-
* @param {String} props.label
|
|
2513
|
-
* @param {Function} props.getValue
|
|
2514
|
-
* @param {Function} props.setValue
|
|
2515
|
-
* @param {Function} props.tooltipContainer
|
|
2516
|
-
* @param {Function} props.validate
|
|
2517
|
-
* @param {Function} props.show
|
|
2518
|
-
* @param {Function} props.example
|
|
2519
|
-
* @param {Function} props.variables
|
|
2520
|
-
* @param {Function} props.onFocus
|
|
2521
|
-
* @param {Function} props.onBlur
|
|
2496
|
+
/**
|
|
2497
|
+
* @param {Object} props
|
|
2498
|
+
* @param {Object} props.element
|
|
2499
|
+
* @param {String} props.id
|
|
2500
|
+
* @param {String} props.description
|
|
2501
|
+
* @param {Boolean} props.debounce
|
|
2502
|
+
* @param {Boolean} props.disabled
|
|
2503
|
+
* @param {String} props.max
|
|
2504
|
+
* @param {String} props.min
|
|
2505
|
+
* @param {String} props.step
|
|
2506
|
+
* @param {Boolean} props.feel
|
|
2507
|
+
* @param {String} props.label
|
|
2508
|
+
* @param {Function} props.getValue
|
|
2509
|
+
* @param {Function} props.setValue
|
|
2510
|
+
* @param {Function} props.tooltipContainer
|
|
2511
|
+
* @param {Function} props.validate
|
|
2512
|
+
* @param {Function} props.show
|
|
2513
|
+
* @param {Function} props.example
|
|
2514
|
+
* @param {Function} props.variables
|
|
2515
|
+
* @param {Function} props.onFocus
|
|
2516
|
+
* @param {Function} props.onBlur
|
|
2522
2517
|
*/
|
|
2523
2518
|
function FeelNumberEntry(props) {
|
|
2524
2519
|
return jsx(FeelEntry, {
|
|
@@ -2528,25 +2523,25 @@ function FeelNumberEntry(props) {
|
|
|
2528
2523
|
});
|
|
2529
2524
|
}
|
|
2530
2525
|
|
|
2531
|
-
/**
|
|
2532
|
-
* @param {Object} props
|
|
2533
|
-
* @param {Object} props.element
|
|
2534
|
-
* @param {String} props.id
|
|
2535
|
-
* @param {String} props.description
|
|
2536
|
-
* @param {Boolean} props.debounce
|
|
2537
|
-
* @param {Boolean} props.disabled
|
|
2538
|
-
* @param {Boolean} props.feel
|
|
2539
|
-
* @param {String} props.label
|
|
2540
|
-
* @param {Function} props.getValue
|
|
2541
|
-
* @param {Function} props.setValue
|
|
2542
|
-
* @param {Function} props.tooltipContainer
|
|
2543
|
-
* @param {Function} props.validate
|
|
2544
|
-
* @param {Function} props.show
|
|
2545
|
-
* @param {Function} props.example
|
|
2546
|
-
* @param {Function} props.variables
|
|
2547
|
-
* @param {Function} props.onFocus
|
|
2548
|
-
* @param {Function} props.onBlur
|
|
2549
|
-
* @param {string} [props.placeholder]
|
|
2526
|
+
/**
|
|
2527
|
+
* @param {Object} props
|
|
2528
|
+
* @param {Object} props.element
|
|
2529
|
+
* @param {String} props.id
|
|
2530
|
+
* @param {String} props.description
|
|
2531
|
+
* @param {Boolean} props.debounce
|
|
2532
|
+
* @param {Boolean} props.disabled
|
|
2533
|
+
* @param {Boolean} props.feel
|
|
2534
|
+
* @param {String} props.label
|
|
2535
|
+
* @param {Function} props.getValue
|
|
2536
|
+
* @param {Function} props.setValue
|
|
2537
|
+
* @param {Function} props.tooltipContainer
|
|
2538
|
+
* @param {Function} props.validate
|
|
2539
|
+
* @param {Function} props.show
|
|
2540
|
+
* @param {Function} props.example
|
|
2541
|
+
* @param {Function} props.variables
|
|
2542
|
+
* @param {Function} props.onFocus
|
|
2543
|
+
* @param {Function} props.onBlur
|
|
2544
|
+
* @param {string} [props.placeholder]
|
|
2550
2545
|
*/
|
|
2551
2546
|
function FeelTextAreaEntry(props) {
|
|
2552
2547
|
return jsx(FeelEntry, {
|
|
@@ -2556,24 +2551,24 @@ function FeelTextAreaEntry(props) {
|
|
|
2556
2551
|
});
|
|
2557
2552
|
}
|
|
2558
2553
|
|
|
2559
|
-
/**
|
|
2560
|
-
* @param {Object} props
|
|
2561
|
-
* @param {Object} props.element
|
|
2562
|
-
* @param {String} props.id
|
|
2563
|
-
* @param {String} props.description
|
|
2564
|
-
* @param {Boolean} props.debounce
|
|
2565
|
-
* @param {Boolean} props.disabled
|
|
2566
|
-
* @param {Boolean} props.feel
|
|
2567
|
-
* @param {String} props.label
|
|
2568
|
-
* @param {Function} props.getValue
|
|
2569
|
-
* @param {Function} props.setValue
|
|
2570
|
-
* @param {Function} props.tooltipContainer
|
|
2571
|
-
* @param {Function} props.validate
|
|
2572
|
-
* @param {Function} props.show
|
|
2573
|
-
* @param {Function} props.example
|
|
2574
|
-
* @param {Function} props.variables
|
|
2575
|
-
* @param {Function} props.onFocus
|
|
2576
|
-
* @param {Function} props.onBlur
|
|
2554
|
+
/**
|
|
2555
|
+
* @param {Object} props
|
|
2556
|
+
* @param {Object} props.element
|
|
2557
|
+
* @param {String} props.id
|
|
2558
|
+
* @param {String} props.description
|
|
2559
|
+
* @param {Boolean} props.debounce
|
|
2560
|
+
* @param {Boolean} props.disabled
|
|
2561
|
+
* @param {Boolean} props.feel
|
|
2562
|
+
* @param {String} props.label
|
|
2563
|
+
* @param {Function} props.getValue
|
|
2564
|
+
* @param {Function} props.setValue
|
|
2565
|
+
* @param {Function} props.tooltipContainer
|
|
2566
|
+
* @param {Function} props.validate
|
|
2567
|
+
* @param {Function} props.show
|
|
2568
|
+
* @param {Function} props.example
|
|
2569
|
+
* @param {Function} props.variables
|
|
2570
|
+
* @param {Function} props.onFocus
|
|
2571
|
+
* @param {Function} props.onBlur
|
|
2577
2572
|
*/
|
|
2578
2573
|
function FeelToggleSwitchEntry(props) {
|
|
2579
2574
|
return jsx(FeelEntry, {
|
|
@@ -2583,24 +2578,24 @@ function FeelToggleSwitchEntry(props) {
|
|
|
2583
2578
|
});
|
|
2584
2579
|
}
|
|
2585
2580
|
|
|
2586
|
-
/**
|
|
2587
|
-
* @param {Object} props
|
|
2588
|
-
* @param {Object} props.element
|
|
2589
|
-
* @param {String} props.id
|
|
2590
|
-
* @param {String} props.description
|
|
2591
|
-
* @param {Boolean} props.debounce
|
|
2592
|
-
* @param {Boolean} props.disabled
|
|
2593
|
-
* @param {Boolean} props.feel
|
|
2594
|
-
* @param {String} props.label
|
|
2595
|
-
* @param {Function} props.getValue
|
|
2596
|
-
* @param {Function} props.setValue
|
|
2597
|
-
* @param {Function} props.tooltipContainer
|
|
2598
|
-
* @param {Function} props.validate
|
|
2599
|
-
* @param {Function} props.show
|
|
2600
|
-
* @param {Function} props.example
|
|
2601
|
-
* @param {Function} props.variables
|
|
2602
|
-
* @param {Function} props.onFocus
|
|
2603
|
-
* @param {Function} props.onBlur
|
|
2581
|
+
/**
|
|
2582
|
+
* @param {Object} props
|
|
2583
|
+
* @param {Object} props.element
|
|
2584
|
+
* @param {String} props.id
|
|
2585
|
+
* @param {String} props.description
|
|
2586
|
+
* @param {Boolean} props.debounce
|
|
2587
|
+
* @param {Boolean} props.disabled
|
|
2588
|
+
* @param {Boolean} props.feel
|
|
2589
|
+
* @param {String} props.label
|
|
2590
|
+
* @param {Function} props.getValue
|
|
2591
|
+
* @param {Function} props.setValue
|
|
2592
|
+
* @param {Function} props.tooltipContainer
|
|
2593
|
+
* @param {Function} props.validate
|
|
2594
|
+
* @param {Function} props.show
|
|
2595
|
+
* @param {Function} props.example
|
|
2596
|
+
* @param {Function} props.variables
|
|
2597
|
+
* @param {Function} props.onFocus
|
|
2598
|
+
* @param {Function} props.onBlur
|
|
2604
2599
|
*/
|
|
2605
2600
|
function FeelCheckboxEntry(props) {
|
|
2606
2601
|
return jsx(FeelEntry, {
|
|
@@ -2610,26 +2605,26 @@ function FeelCheckboxEntry(props) {
|
|
|
2610
2605
|
});
|
|
2611
2606
|
}
|
|
2612
2607
|
|
|
2613
|
-
/**
|
|
2614
|
-
* @param {Object} props
|
|
2615
|
-
* @param {Object} props.element
|
|
2616
|
-
* @param {String} props.id
|
|
2617
|
-
* @param {String} props.description
|
|
2618
|
-
* @param {String} props.hostLanguage
|
|
2619
|
-
* @param {Boolean} props.singleLine
|
|
2620
|
-
* @param {Boolean} props.debounce
|
|
2621
|
-
* @param {Boolean} props.disabled
|
|
2622
|
-
* @param {Boolean} props.feel
|
|
2623
|
-
* @param {String} props.label
|
|
2624
|
-
* @param {Function} props.getValue
|
|
2625
|
-
* @param {Function} props.setValue
|
|
2626
|
-
* @param {Function} props.tooltipContainer
|
|
2627
|
-
* @param {Function} props.validate
|
|
2628
|
-
* @param {Function} props.show
|
|
2629
|
-
* @param {Function} props.example
|
|
2630
|
-
* @param {Function} props.variables
|
|
2631
|
-
* @param {Function} props.onFocus
|
|
2632
|
-
* @param {Function} props.onBlur
|
|
2608
|
+
/**
|
|
2609
|
+
* @param {Object} props
|
|
2610
|
+
* @param {Object} props.element
|
|
2611
|
+
* @param {String} props.id
|
|
2612
|
+
* @param {String} props.description
|
|
2613
|
+
* @param {String} props.hostLanguage
|
|
2614
|
+
* @param {Boolean} props.singleLine
|
|
2615
|
+
* @param {Boolean} props.debounce
|
|
2616
|
+
* @param {Boolean} props.disabled
|
|
2617
|
+
* @param {Boolean} props.feel
|
|
2618
|
+
* @param {String} props.label
|
|
2619
|
+
* @param {Function} props.getValue
|
|
2620
|
+
* @param {Function} props.setValue
|
|
2621
|
+
* @param {Function} props.tooltipContainer
|
|
2622
|
+
* @param {Function} props.validate
|
|
2623
|
+
* @param {Function} props.show
|
|
2624
|
+
* @param {Function} props.example
|
|
2625
|
+
* @param {Function} props.variables
|
|
2626
|
+
* @param {Function} props.onFocus
|
|
2627
|
+
* @param {Function} props.onBlur
|
|
2633
2628
|
*/
|
|
2634
2629
|
function FeelTemplatingEntry(props) {
|
|
2635
2630
|
return jsx(FeelEntry, {
|
|
@@ -2698,84 +2693,85 @@ const DEFAULT_LAYOUT = {};
|
|
|
2698
2693
|
const DEFAULT_DESCRIPTION = {};
|
|
2699
2694
|
const DEFAULT_TOOLTIP = {};
|
|
2700
2695
|
|
|
2701
|
-
/**
|
|
2702
|
-
* @typedef { {
|
|
2703
|
-
* component: import('preact').Component,
|
|
2704
|
-
* id: String,
|
|
2705
|
-
* isEdited?: Function
|
|
2706
|
-
* } } EntryDefinition
|
|
2707
|
-
*
|
|
2708
|
-
* @typedef { {
|
|
2709
|
-
* autoFocusEntry: String,
|
|
2710
|
-
* autoOpen?: Boolean,
|
|
2711
|
-
* entries: Array<EntryDefinition>,
|
|
2712
|
-
* id: String,
|
|
2713
|
-
* label: String,
|
|
2714
|
-
* remove: (event: MouseEvent) => void
|
|
2715
|
-
* } } ListItemDefinition
|
|
2716
|
-
*
|
|
2717
|
-
* @typedef { {
|
|
2718
|
-
* add: (event: MouseEvent) => void,
|
|
2719
|
-
* component: import('preact').Component,
|
|
2720
|
-
* element: Object,
|
|
2721
|
-
* id: String,
|
|
2722
|
-
* items: Array<ListItemDefinition>,
|
|
2723
|
-
* label: String,
|
|
2724
|
-
* shouldOpen?: Boolean
|
|
2725
|
-
* } } ListGroupDefinition
|
|
2726
|
-
*
|
|
2727
|
-
* @typedef { {
|
|
2728
|
-
* component?: import('preact').Component,
|
|
2729
|
-
* entries: Array<EntryDefinition>,
|
|
2730
|
-
* id: String,
|
|
2731
|
-
* label: String,
|
|
2732
|
-
* shouldOpen?: Boolean
|
|
2733
|
-
* } } GroupDefinition
|
|
2734
|
-
*
|
|
2735
|
-
* @typedef { {
|
|
2736
|
-
* [id: String]: GetDescriptionFunction
|
|
2737
|
-
* } } DescriptionConfig
|
|
2738
|
-
*
|
|
2739
|
-
* @typedef { {
|
|
2740
|
-
* [id: String]: GetTooltipFunction
|
|
2741
|
-
* } } TooltipConfig
|
|
2742
|
-
*
|
|
2743
|
-
* @callback { {
|
|
2744
|
-
* @param {string} id
|
|
2745
|
-
* @param {Object} element
|
|
2746
|
-
* @returns {string}
|
|
2747
|
-
* } } GetDescriptionFunction
|
|
2748
|
-
*
|
|
2749
|
-
* @callback { {
|
|
2750
|
-
* @param {string} id
|
|
2751
|
-
* @param {Object} element
|
|
2752
|
-
* @returns {string}
|
|
2753
|
-
* } } GetTooltipFunction
|
|
2754
|
-
*
|
|
2755
|
-
* @typedef { {
|
|
2756
|
-
* getEmpty: (element: object) => import('./components/Placeholder').PlaceholderDefinition,
|
|
2757
|
-
* getMultiple: (element: Object) => import('./components/Placeholder').PlaceholderDefinition
|
|
2758
|
-
* } } PlaceholderProvider
|
|
2759
|
-
*
|
|
2696
|
+
/**
|
|
2697
|
+
* @typedef { {
|
|
2698
|
+
* component: import('preact').Component,
|
|
2699
|
+
* id: String,
|
|
2700
|
+
* isEdited?: Function
|
|
2701
|
+
* } } EntryDefinition
|
|
2702
|
+
*
|
|
2703
|
+
* @typedef { {
|
|
2704
|
+
* autoFocusEntry: String,
|
|
2705
|
+
* autoOpen?: Boolean,
|
|
2706
|
+
* entries: Array<EntryDefinition>,
|
|
2707
|
+
* id: String,
|
|
2708
|
+
* label: String,
|
|
2709
|
+
* remove: (event: MouseEvent) => void
|
|
2710
|
+
* } } ListItemDefinition
|
|
2711
|
+
*
|
|
2712
|
+
* @typedef { {
|
|
2713
|
+
* add: (event: MouseEvent) => void,
|
|
2714
|
+
* component: import('preact').Component,
|
|
2715
|
+
* element: Object,
|
|
2716
|
+
* id: String,
|
|
2717
|
+
* items: Array<ListItemDefinition>,
|
|
2718
|
+
* label: String,
|
|
2719
|
+
* shouldOpen?: Boolean
|
|
2720
|
+
* } } ListGroupDefinition
|
|
2721
|
+
*
|
|
2722
|
+
* @typedef { {
|
|
2723
|
+
* component?: import('preact').Component,
|
|
2724
|
+
* entries: Array<EntryDefinition>,
|
|
2725
|
+
* id: String,
|
|
2726
|
+
* label: String,
|
|
2727
|
+
* shouldOpen?: Boolean
|
|
2728
|
+
* } } GroupDefinition
|
|
2729
|
+
*
|
|
2730
|
+
* @typedef { {
|
|
2731
|
+
* [id: String]: GetDescriptionFunction
|
|
2732
|
+
* } } DescriptionConfig
|
|
2733
|
+
*
|
|
2734
|
+
* @typedef { {
|
|
2735
|
+
* [id: String]: GetTooltipFunction
|
|
2736
|
+
* } } TooltipConfig
|
|
2737
|
+
*
|
|
2738
|
+
* @callback { {
|
|
2739
|
+
* @param {string} id
|
|
2740
|
+
* @param {Object} element
|
|
2741
|
+
* @returns {string}
|
|
2742
|
+
* } } GetDescriptionFunction
|
|
2743
|
+
*
|
|
2744
|
+
* @callback { {
|
|
2745
|
+
* @param {string} id
|
|
2746
|
+
* @param {Object} element
|
|
2747
|
+
* @returns {string}
|
|
2748
|
+
* } } GetTooltipFunction
|
|
2749
|
+
*
|
|
2750
|
+
* @typedef { {
|
|
2751
|
+
* getEmpty: (element: object) => import('./components/Placeholder').PlaceholderDefinition,
|
|
2752
|
+
* getMultiple: (element: Object) => import('./components/Placeholder').PlaceholderDefinition
|
|
2753
|
+
* } } PlaceholderProvider
|
|
2754
|
+
*
|
|
2760
2755
|
*/
|
|
2761
2756
|
|
|
2762
|
-
/**
|
|
2763
|
-
* A basic properties panel component. Describes *how* content will be rendered, accepts
|
|
2764
|
-
* data from implementor to describe *what* will be rendered.
|
|
2765
|
-
*
|
|
2766
|
-
* @param {Object} props
|
|
2767
|
-
* @param {Object|Array} props.element
|
|
2768
|
-
* @param {import('./components/Header').HeaderProvider} props.headerProvider
|
|
2769
|
-
* @param {PlaceholderProvider} [props.placeholderProvider]
|
|
2770
|
-
* @param {Array<GroupDefinition|ListGroupDefinition>} props.groups
|
|
2771
|
-
* @param {Object} [props.layoutConfig]
|
|
2772
|
-
* @param {Function} [props.layoutChanged]
|
|
2773
|
-
* @param {DescriptionConfig} [props.descriptionConfig]
|
|
2774
|
-
* @param {Function} [props.descriptionLoaded]
|
|
2775
|
-
* @param {TooltipConfig} [props.tooltipConfig]
|
|
2776
|
-
* @param {Function} [props.tooltipLoaded]
|
|
2777
|
-
* @param {HTMLElement} [props.feelPopupContainer]
|
|
2778
|
-
* @param {
|
|
2757
|
+
/**
|
|
2758
|
+
* A basic properties panel component. Describes *how* content will be rendered, accepts
|
|
2759
|
+
* data from implementor to describe *what* will be rendered.
|
|
2760
|
+
*
|
|
2761
|
+
* @param {Object} props
|
|
2762
|
+
* @param {Object|Array} props.element
|
|
2763
|
+
* @param {import('./components/Header').HeaderProvider} props.headerProvider
|
|
2764
|
+
* @param {PlaceholderProvider} [props.placeholderProvider]
|
|
2765
|
+
* @param {Array<GroupDefinition|ListGroupDefinition>} props.groups
|
|
2766
|
+
* @param {Object} [props.layoutConfig]
|
|
2767
|
+
* @param {Function} [props.layoutChanged]
|
|
2768
|
+
* @param {DescriptionConfig} [props.descriptionConfig]
|
|
2769
|
+
* @param {Function} [props.descriptionLoaded]
|
|
2770
|
+
* @param {TooltipConfig} [props.tooltipConfig]
|
|
2771
|
+
* @param {Function} [props.tooltipLoaded]
|
|
2772
|
+
* @param {HTMLElement} [props.feelPopupContainer]
|
|
2773
|
+
* @param {Function} [props.getFeelPopupLinks]
|
|
2774
|
+
* @param {Object} [props.eventBus]
|
|
2779
2775
|
*/
|
|
2780
2776
|
function PropertiesPanel(props) {
|
|
2781
2777
|
const {
|
|
@@ -2790,6 +2786,7 @@ function PropertiesPanel(props) {
|
|
|
2790
2786
|
tooltipConfig,
|
|
2791
2787
|
tooltipLoaded,
|
|
2792
2788
|
feelPopupContainer,
|
|
2789
|
+
getFeelPopupLinks,
|
|
2793
2790
|
eventBus
|
|
2794
2791
|
} = props;
|
|
2795
2792
|
|
|
@@ -2894,6 +2891,7 @@ function PropertiesPanel(props) {
|
|
|
2894
2891
|
element: element,
|
|
2895
2892
|
eventBus: eventBus,
|
|
2896
2893
|
popupContainer: feelPopupContainer,
|
|
2894
|
+
getPopupLinks: getFeelPopupLinks,
|
|
2897
2895
|
children: jsxs("div", {
|
|
2898
2896
|
class: "bio-properties-panel",
|
|
2899
2897
|
children: [jsx(Header, {
|
|
@@ -2946,11 +2944,11 @@ function createTooltipContext(overrides = {}) {
|
|
|
2946
2944
|
|
|
2947
2945
|
// hooks //////////////////
|
|
2948
2946
|
|
|
2949
|
-
/**
|
|
2950
|
-
* This hook behaves like useLayoutEffect, but does not trigger on the first render.
|
|
2951
|
-
*
|
|
2952
|
-
* @param {Function} effect
|
|
2953
|
-
* @param {Array} deps
|
|
2947
|
+
/**
|
|
2948
|
+
* This hook behaves like useLayoutEffect, but does not trigger on the first render.
|
|
2949
|
+
*
|
|
2950
|
+
* @param {Function} effect
|
|
2951
|
+
* @param {Array} deps
|
|
2954
2952
|
*/
|
|
2955
2953
|
function useUpdateLayoutEffect(effect, deps) {
|
|
2956
2954
|
const isMounted = useRef(false);
|
|
@@ -3025,15 +3023,15 @@ function MenuItem({
|
|
|
3025
3023
|
});
|
|
3026
3024
|
}
|
|
3027
3025
|
|
|
3028
|
-
/**
|
|
3029
|
-
*
|
|
3030
|
-
* @param {Array<null | Element>} ignoredElements
|
|
3031
|
-
* @param {Function} callback
|
|
3026
|
+
/**
|
|
3027
|
+
*
|
|
3028
|
+
* @param {Array<null | Element>} ignoredElements
|
|
3029
|
+
* @param {Function} callback
|
|
3032
3030
|
*/
|
|
3033
3031
|
function useGlobalClick(ignoredElements, callback) {
|
|
3034
3032
|
useEffect(() => {
|
|
3035
|
-
/**
|
|
3036
|
-
* @param {MouseEvent} event
|
|
3033
|
+
/**
|
|
3034
|
+
* @param {MouseEvent} event
|
|
3037
3035
|
*/
|
|
3038
3036
|
function listener(event) {
|
|
3039
3037
|
if (ignoredElements.some(element => element && element.contains(event.target))) {
|
|
@@ -3066,20 +3064,20 @@ function HeaderButton(props) {
|
|
|
3066
3064
|
});
|
|
3067
3065
|
}
|
|
3068
3066
|
|
|
3069
|
-
/**
|
|
3070
|
-
* @typedef { {
|
|
3071
|
-
* [key: string]: string;
|
|
3072
|
-
* } } TranslateReplacements
|
|
3067
|
+
/**
|
|
3068
|
+
* @typedef { {
|
|
3069
|
+
* [key: string]: string;
|
|
3070
|
+
* } } TranslateReplacements
|
|
3073
3071
|
*/
|
|
3074
3072
|
|
|
3075
|
-
/**
|
|
3076
|
-
* A simple translation stub to be used for multi-language support.
|
|
3077
|
-
* Can be easily replaced with a more sophisticated solution.
|
|
3078
|
-
*
|
|
3079
|
-
* @param {string} template to interpolate
|
|
3080
|
-
* @param {TranslateReplacements} [replacements] a map with substitutes
|
|
3081
|
-
*
|
|
3082
|
-
* @return {string} the translated string
|
|
3073
|
+
/**
|
|
3074
|
+
* A simple translation stub to be used for multi-language support.
|
|
3075
|
+
* Can be easily replaced with a more sophisticated solution.
|
|
3076
|
+
*
|
|
3077
|
+
* @param {string} template to interpolate
|
|
3078
|
+
* @param {TranslateReplacements} [replacements] a map with substitutes
|
|
3079
|
+
*
|
|
3080
|
+
* @return {string} the translated string
|
|
3083
3081
|
*/
|
|
3084
3082
|
function translateFallback(template, replacements) {
|
|
3085
3083
|
replacements = replacements || {};
|
|
@@ -3191,8 +3189,8 @@ function ListItem(props) {
|
|
|
3191
3189
|
|
|
3192
3190
|
const noop$1 = () => {};
|
|
3193
3191
|
|
|
3194
|
-
/**
|
|
3195
|
-
* @param {import('../PropertiesPanel').ListGroupDefinition} props
|
|
3192
|
+
/**
|
|
3193
|
+
* @param {import('../PropertiesPanel').ListGroupDefinition} props
|
|
3196
3194
|
*/
|
|
3197
3195
|
function ListGroup(props) {
|
|
3198
3196
|
const {
|
|
@@ -3384,18 +3382,18 @@ function Checkbox(props) {
|
|
|
3384
3382
|
});
|
|
3385
3383
|
}
|
|
3386
3384
|
|
|
3387
|
-
/**
|
|
3388
|
-
* @param {Object} props
|
|
3389
|
-
* @param {Object} props.element
|
|
3390
|
-
* @param {String} props.id
|
|
3391
|
-
* @param {String} props.description
|
|
3392
|
-
* @param {String} props.label
|
|
3393
|
-
* @param {Function} props.getValue
|
|
3394
|
-
* @param {Function} props.setValue
|
|
3395
|
-
* @param {Function} props.onFocus
|
|
3396
|
-
* @param {Function} props.onBlur
|
|
3397
|
-
* @param {string|import('preact').Component} props.tooltip
|
|
3398
|
-
* @param {boolean} [props.disabled]
|
|
3385
|
+
/**
|
|
3386
|
+
* @param {Object} props
|
|
3387
|
+
* @param {Object} props.element
|
|
3388
|
+
* @param {String} props.id
|
|
3389
|
+
* @param {String} props.description
|
|
3390
|
+
* @param {String} props.label
|
|
3391
|
+
* @param {Function} props.getValue
|
|
3392
|
+
* @param {Function} props.setValue
|
|
3393
|
+
* @param {Function} props.onFocus
|
|
3394
|
+
* @param {Function} props.onBlur
|
|
3395
|
+
* @param {string|import('preact').Component} props.tooltip
|
|
3396
|
+
* @param {boolean} [props.disabled]
|
|
3399
3397
|
*/
|
|
3400
3398
|
function CheckboxEntry(props) {
|
|
3401
3399
|
const {
|
|
@@ -3447,19 +3445,19 @@ function prefixId$4(id) {
|
|
|
3447
3445
|
|
|
3448
3446
|
const noop = () => {};
|
|
3449
3447
|
|
|
3450
|
-
/**
|
|
3451
|
-
* @param {Object} props
|
|
3452
|
-
* @param {Object} props.element
|
|
3453
|
-
* @param {String} props.id
|
|
3454
|
-
* @param {String} props.description
|
|
3455
|
-
* @param {Boolean} props.debounce
|
|
3456
|
-
* @param {Boolean} props.disabled
|
|
3457
|
-
* @param {String} props.label
|
|
3458
|
-
* @param {Function} props.getValue
|
|
3459
|
-
* @param {Function} props.setValue
|
|
3460
|
-
* @param {Function} props.tooltipContainer
|
|
3461
|
-
* @param {Function} props.validate
|
|
3462
|
-
* @param {Function} props.show
|
|
3448
|
+
/**
|
|
3449
|
+
* @param {Object} props
|
|
3450
|
+
* @param {Object} props.element
|
|
3451
|
+
* @param {String} props.id
|
|
3452
|
+
* @param {String} props.description
|
|
3453
|
+
* @param {Boolean} props.debounce
|
|
3454
|
+
* @param {Boolean} props.disabled
|
|
3455
|
+
* @param {String} props.label
|
|
3456
|
+
* @param {Function} props.getValue
|
|
3457
|
+
* @param {Function} props.setValue
|
|
3458
|
+
* @param {Function} props.tooltipContainer
|
|
3459
|
+
* @param {Function} props.validate
|
|
3460
|
+
* @param {Function} props.show
|
|
3463
3461
|
*/
|
|
3464
3462
|
function TemplatingEntry(props) {
|
|
3465
3463
|
const {
|
|
@@ -3634,8 +3632,8 @@ function List(props) {
|
|
|
3634
3632
|
}
|
|
3635
3633
|
}, [open, hasItems]);
|
|
3636
3634
|
|
|
3637
|
-
/**
|
|
3638
|
-
* @param {MouseEvent} event
|
|
3635
|
+
/**
|
|
3636
|
+
* @param {MouseEvent} event
|
|
3639
3637
|
*/
|
|
3640
3638
|
function addItem(event) {
|
|
3641
3639
|
event.stopPropagation();
|
|
@@ -3827,20 +3825,20 @@ function Select(props) {
|
|
|
3827
3825
|
});
|
|
3828
3826
|
}
|
|
3829
3827
|
|
|
3830
|
-
/**
|
|
3831
|
-
* @param {object} props
|
|
3832
|
-
* @param {object} props.element
|
|
3833
|
-
* @param {string} props.id
|
|
3834
|
-
* @param {string} [props.description]
|
|
3835
|
-
* @param {string} props.label
|
|
3836
|
-
* @param {Function} props.getValue
|
|
3837
|
-
* @param {Function} props.setValue
|
|
3838
|
-
* @param {Function} props.onFocus
|
|
3839
|
-
* @param {Function} props.onBlur
|
|
3840
|
-
* @param {Function} props.getOptions
|
|
3841
|
-
* @param {boolean} [props.disabled]
|
|
3842
|
-
* @param {Function} [props.validate]
|
|
3843
|
-
* @param {string|import('preact').Component} props.tooltip
|
|
3828
|
+
/**
|
|
3829
|
+
* @param {object} props
|
|
3830
|
+
* @param {object} props.element
|
|
3831
|
+
* @param {string} props.id
|
|
3832
|
+
* @param {string} [props.description]
|
|
3833
|
+
* @param {string} props.label
|
|
3834
|
+
* @param {Function} props.getValue
|
|
3835
|
+
* @param {Function} props.setValue
|
|
3836
|
+
* @param {Function} props.onFocus
|
|
3837
|
+
* @param {Function} props.onBlur
|
|
3838
|
+
* @param {Function} props.getOptions
|
|
3839
|
+
* @param {boolean} [props.disabled]
|
|
3840
|
+
* @param {Function} [props.validate]
|
|
3841
|
+
* @param {string|import('preact').Component} props.tooltip
|
|
3844
3842
|
*/
|
|
3845
3843
|
function SelectEntry(props) {
|
|
3846
3844
|
const {
|
|
@@ -4187,20 +4185,20 @@ function Textfield(props) {
|
|
|
4187
4185
|
});
|
|
4188
4186
|
}
|
|
4189
4187
|
|
|
4190
|
-
/**
|
|
4191
|
-
* @param {Object} props
|
|
4192
|
-
* @param {Object} props.element
|
|
4193
|
-
* @param {String} props.id
|
|
4194
|
-
* @param {String} props.description
|
|
4195
|
-
* @param {Boolean} props.debounce
|
|
4196
|
-
* @param {Boolean} props.disabled
|
|
4197
|
-
* @param {String} props.label
|
|
4198
|
-
* @param {Function} props.getValue
|
|
4199
|
-
* @param {Function} props.setValue
|
|
4200
|
-
* @param {Function} props.onFocus
|
|
4201
|
-
* @param {Function} props.onBlur
|
|
4202
|
-
* @param {string|import('preact').Component} props.tooltip
|
|
4203
|
-
* @param {Function} props.validate
|
|
4188
|
+
/**
|
|
4189
|
+
* @param {Object} props
|
|
4190
|
+
* @param {Object} props.element
|
|
4191
|
+
* @param {String} props.id
|
|
4192
|
+
* @param {String} props.description
|
|
4193
|
+
* @param {Boolean} props.debounce
|
|
4194
|
+
* @param {Boolean} props.disabled
|
|
4195
|
+
* @param {String} props.label
|
|
4196
|
+
* @param {Function} props.getValue
|
|
4197
|
+
* @param {Function} props.setValue
|
|
4198
|
+
* @param {Function} props.onFocus
|
|
4199
|
+
* @param {Function} props.onBlur
|
|
4200
|
+
* @param {string|import('preact').Component} props.tooltip
|
|
4201
|
+
* @param {Function} props.validate
|
|
4204
4202
|
*/
|
|
4205
4203
|
function TextfieldEntry(props) {
|
|
4206
4204
|
const {
|
|
@@ -4293,20 +4291,20 @@ class FeelPopupModule {
|
|
|
4293
4291
|
this._eventBus = eventBus;
|
|
4294
4292
|
}
|
|
4295
4293
|
|
|
4296
|
-
/**
|
|
4297
|
-
* Check if the FEEL popup is open.
|
|
4298
|
-
* @return {Boolean}
|
|
4294
|
+
/**
|
|
4295
|
+
* Check if the FEEL popup is open.
|
|
4296
|
+
* @return {Boolean}
|
|
4299
4297
|
*/
|
|
4300
4298
|
isOpen() {
|
|
4301
4299
|
return this._eventBus.fire('feelPopup._isOpen');
|
|
4302
4300
|
}
|
|
4303
4301
|
|
|
4304
|
-
/**
|
|
4305
|
-
* Open the FEEL popup.
|
|
4306
|
-
*
|
|
4307
|
-
* @param {String} entryId
|
|
4308
|
-
* @param {Object} popupConfig
|
|
4309
|
-
* @param {HTMLElement} sourceElement
|
|
4302
|
+
/**
|
|
4303
|
+
* Open the FEEL popup.
|
|
4304
|
+
*
|
|
4305
|
+
* @param {String} entryId
|
|
4306
|
+
* @param {Object} popupConfig
|
|
4307
|
+
* @param {HTMLElement} sourceElement
|
|
4310
4308
|
*/
|
|
4311
4309
|
open(entryId, popupConfig, sourceElement) {
|
|
4312
4310
|
return this._eventBus.fire('feelPopup._open', {
|
|
@@ -4316,8 +4314,8 @@ class FeelPopupModule {
|
|
|
4316
4314
|
});
|
|
4317
4315
|
}
|
|
4318
4316
|
|
|
4319
|
-
/**
|
|
4320
|
-
* Close the FEEL popup.
|
|
4317
|
+
/**
|
|
4318
|
+
* Close the FEEL popup.
|
|
4321
4319
|
*/
|
|
4322
4320
|
close() {
|
|
4323
4321
|
return this._eventBus.fire('feelPopup._close');
|
|
@@ -4329,5 +4327,5 @@ var index = {
|
|
|
4329
4327
|
feelPopup: ['type', FeelPopupModule]
|
|
4330
4328
|
};
|
|
4331
4329
|
|
|
4332
|
-
export { ArrowIcon, CheckboxEntry, CloseIcon, CollapsibleEntry, CreateIcon, index$1 as DebounceInputModule, DeleteIcon, DescriptionContext, Description as DescriptionEntry, DragIcon, DropdownButton, ErrorsContext, EventContext, ExternalLinkIcon, FeelCheckboxEntry, FeelEntry, FeelIcon$1 as FeelIcon, FeelNumberEntry, index as FeelPopupModule, FeelTemplatingEntry, FeelTextAreaEntry, FeelToggleSwitchEntry, Group, Header, HeaderButton,
|
|
4330
|
+
export { ArrowIcon, CheckboxEntry, CloseIcon, CollapsibleEntry, CreateIcon, index$1 as DebounceInputModule, DeleteIcon, DescriptionContext, Description as DescriptionEntry, DragIcon, DropdownButton, ErrorsContext, EventContext, ExternalLinkIcon, FeelCheckboxEntry, FeelEntry, FeelIcon$1 as FeelIcon, FeelNumberEntry, index as FeelPopupModule, FeelTemplatingEntry, FeelTextAreaEntry, FeelToggleSwitchEntry, Group, Header, HeaderButton, LaunchIcon, LayoutContext, List as ListEntry, ListGroup, ListItem, NumberFieldEntry, Placeholder, Popup, PopupIcon, PropertiesPanel, LayoutContext as PropertiesPanelContext, SelectEntry, Simple as SimpleEntry, TemplatingEntry, TextAreaEntry, TextfieldEntry as TextFieldEntry, ToggleSwitchEntry, TooltipContext, TooltipWrapper as TooltipEntry, isEdited$5 as isCheckboxEntryEdited, isEdited$6 as isFeelEntryEdited, isEdited$7 as isNumberFieldEntryEdited, isEdited$3 as isSelectEntryEdited, isEdited$2 as isSimpleEntryEdited, isEdited$4 as isTemplatingEntryEdited, isEdited$1 as isTextAreaEntryEdited, isEdited as isTextFieldEntryEdited, isEdited$8 as isToggleSwitchEntryEdited, useDescriptionContext, useElementVisible, useError, useErrors, useEvent, useKeyFactory, useLayoutState, usePrevious, useShowEntryEvent, useStaticCallback, useStickyIntersectionObserver, useTooltipContext };
|
|
4333
4331
|
//# sourceMappingURL=index.esm.js.map
|