@bpmn-io/form-js-viewer 1.7.3 → 1.8.1
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 +22 -22
- package/README.md +189 -189
- package/dist/index.cjs +345 -214
- package/dist/index.cjs.map +1 -1
- package/dist/index.es.js +344 -216
- package/dist/index.es.js.map +1 -1
- package/dist/types/Form.d.ts +1 -0
- package/dist/types/features/markdown/MarkdownRenderer.d.ts +0 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/render/components/form-fields/ExpressionField.d.ts +15 -0
- package/dist/types/render/components/index.d.ts +4 -2
- package/dist/types/render/components/util/domUtil.d.ts +1 -0
- package/dist/types/render/hooks/index.d.ts +1 -0
- package/dist/types/render/hooks/useEffectOnChange.d.ts +1 -0
- package/dist/types/render/hooks/useScrollIntoView.d.ts +4 -4
- package/dist/types/types.d.ts +35 -35
- package/dist/types/util/injector.d.ts +1 -1
- package/package.json +7 -7
package/dist/index.es.js
CHANGED
|
@@ -8,12 +8,12 @@ import { createContext, createElement, Fragment as Fragment$1, render } from 'pr
|
|
|
8
8
|
import isEqual from 'lodash/isEqual';
|
|
9
9
|
import flatpickr from 'flatpickr';
|
|
10
10
|
import * as React from 'preact/compat';
|
|
11
|
-
import { createPortal } from 'preact/compat';
|
|
11
|
+
import { useEffect as useEffect$1, createPortal } from 'preact/compat';
|
|
12
12
|
import DOMPurify from 'dompurify';
|
|
13
13
|
import { Injector } from 'didi';
|
|
14
14
|
import { parseExpression, parseUnaryTests, evaluate, unaryTest } from 'feelin';
|
|
15
15
|
import { evaluate as evaluate$1, parser, buildSimpleTree } from 'feelers';
|
|
16
|
-
import
|
|
16
|
+
import { marked } from 'marked';
|
|
17
17
|
|
|
18
18
|
const getFlavouredFeelVariableNames = (feelString, feelFlavour = 'expression', options = {}) => {
|
|
19
19
|
const {
|
|
@@ -581,7 +581,7 @@ function prefixId(id, formId, indexes) {
|
|
|
581
581
|
return result;
|
|
582
582
|
}
|
|
583
583
|
|
|
584
|
-
const type$
|
|
584
|
+
const type$h = 'button';
|
|
585
585
|
function Button(props) {
|
|
586
586
|
const {
|
|
587
587
|
disabled,
|
|
@@ -593,7 +593,7 @@ function Button(props) {
|
|
|
593
593
|
action = 'submit'
|
|
594
594
|
} = field;
|
|
595
595
|
return jsx("div", {
|
|
596
|
-
class: formFieldClasses(type$
|
|
596
|
+
class: formFieldClasses(type$h),
|
|
597
597
|
children: jsx("button", {
|
|
598
598
|
class: "fjs-button",
|
|
599
599
|
type: action,
|
|
@@ -605,7 +605,7 @@ function Button(props) {
|
|
|
605
605
|
});
|
|
606
606
|
}
|
|
607
607
|
Button.config = {
|
|
608
|
-
type: type$
|
|
608
|
+
type: type$h,
|
|
609
609
|
keyed: false,
|
|
610
610
|
label: 'Button',
|
|
611
611
|
group: 'action',
|
|
@@ -1050,44 +1050,124 @@ const _getValueHash = value => {
|
|
|
1050
1050
|
};
|
|
1051
1051
|
|
|
1052
1052
|
/**
|
|
1053
|
-
*
|
|
1053
|
+
* Wrap CSS styles with a given prefix.
|
|
1054
|
+
*
|
|
1055
|
+
* @param {HTMLElement} rootNode
|
|
1056
|
+
* @param {string} prefix
|
|
1057
|
+
*
|
|
1058
|
+
* @returns {HTMLElement}
|
|
1059
|
+
*/
|
|
1060
|
+
function wrapCSSStyles(rootNode, prefix) {
|
|
1061
|
+
const styleTags = rootNode.querySelectorAll('style');
|
|
1062
|
+
styleTags.forEach(styleTag => {
|
|
1063
|
+
const topLevelRules = extractTopLevelRules(styleTag.textContent);
|
|
1064
|
+
const scopedCss = topLevelRules.map(rule => {
|
|
1065
|
+
const {
|
|
1066
|
+
selector,
|
|
1067
|
+
styles
|
|
1068
|
+
} = splitRule(rule);
|
|
1069
|
+
const scopedSelector = scopeSelector(selector, prefix);
|
|
1070
|
+
return `${scopedSelector} ${styles}`;
|
|
1071
|
+
}).join(' ');
|
|
1072
|
+
styleTag.textContent = scopedCss;
|
|
1073
|
+
});
|
|
1074
|
+
return rootNode;
|
|
1075
|
+
}
|
|
1076
|
+
function extractTopLevelRules(cssString) {
|
|
1077
|
+
let cursor = 0;
|
|
1078
|
+
let start = 0;
|
|
1079
|
+
let level = 0;
|
|
1080
|
+
const topLevelRules = [];
|
|
1081
|
+
while (cursor < cssString.length) {
|
|
1082
|
+
if (cssString[cursor] === '{') {
|
|
1083
|
+
level++;
|
|
1084
|
+
}
|
|
1085
|
+
if (cssString[cursor] === '}') {
|
|
1086
|
+
level--;
|
|
1087
|
+
if (level === 0) {
|
|
1088
|
+
topLevelRules.push(cssString.substring(start, cursor + 1));
|
|
1089
|
+
start = cursor + 1;
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1092
|
+
cursor++;
|
|
1093
|
+
}
|
|
1094
|
+
return topLevelRules.map(rule => rule.trim());
|
|
1095
|
+
}
|
|
1096
|
+
function splitRule(rule) {
|
|
1097
|
+
const firstBracket = rule.indexOf('{');
|
|
1098
|
+
const selector = rule.substring(0, firstBracket);
|
|
1099
|
+
const styles = rule.substring(firstBracket);
|
|
1100
|
+
return {
|
|
1101
|
+
selector,
|
|
1102
|
+
styles
|
|
1103
|
+
};
|
|
1104
|
+
}
|
|
1105
|
+
function scopeSelector(selector, prefix) {
|
|
1106
|
+
return selector.split(',').map(sel => `${prefix} ${sel.trim()}`).join(', ');
|
|
1107
|
+
}
|
|
1108
|
+
function getScrollContainer(el) {
|
|
1109
|
+
while (el && el !== document.body && el !== document.documentElement) {
|
|
1110
|
+
if (_isElementScrollable(el)) {
|
|
1111
|
+
return el;
|
|
1112
|
+
}
|
|
1113
|
+
el = el.parentElement;
|
|
1114
|
+
}
|
|
1115
|
+
if (_isElementScrollable(document.body)) {
|
|
1116
|
+
return document.body;
|
|
1117
|
+
} else if (_isElementScrollable(document.documentElement)) {
|
|
1118
|
+
return document.documentElement;
|
|
1119
|
+
}
|
|
1120
|
+
return null;
|
|
1121
|
+
}
|
|
1122
|
+
function _isElementScrollable(el) {
|
|
1123
|
+
const style = window.getComputedStyle(el);
|
|
1124
|
+
const overflowY = style.overflowY || style.overflow;
|
|
1125
|
+
return (overflowY === 'auto' || overflowY === 'scroll') && el.scrollHeight > el.clientHeight;
|
|
1126
|
+
}
|
|
1127
|
+
|
|
1128
|
+
const EMPTY_OBJECT = {};
|
|
1129
|
+
const EMPTY_ARRAY = [];
|
|
1130
|
+
|
|
1131
|
+
/**
|
|
1132
|
+
* Custom hook to scroll an element within a scrollable container.
|
|
1054
1133
|
*
|
|
1055
|
-
* @param {Object}
|
|
1134
|
+
* @param {Object} scrolledElementRef - A ref pointing to the DOM element to scroll into view.
|
|
1056
1135
|
* @param {Array} deps - An array of dependencies that trigger the effect.
|
|
1057
|
-
* @param {Array} flagRefs - An array of refs that are used as flags to control when to scroll.
|
|
1058
1136
|
* @param {Object} [scrollOptions={}] - Options defining the behavior of the scrolling.
|
|
1059
1137
|
* @param {String} [scrollOptions.align='center'] - The alignment of the element within the viewport.
|
|
1060
1138
|
* @param {String} [scrollOptions.behavior='auto'] - The scrolling behavior.
|
|
1061
1139
|
* @param {Number} [scrollOptions.offset=0] - An offset that is added to the scroll position.
|
|
1062
1140
|
* @param {Boolean} [scrollOptions.scrollIfVisible=false] - Whether to scroll even if the element is visible.
|
|
1141
|
+
* @param {Array} [flagRefs] - An array of refs that are used as flags to control when to scroll.
|
|
1063
1142
|
*/
|
|
1064
|
-
function useScrollIntoView(
|
|
1143
|
+
function useScrollIntoView(scrolledElementRef, deps, scrollOptions, flagRefs) {
|
|
1144
|
+
const _scrollOptions = scrollOptions || EMPTY_OBJECT;
|
|
1145
|
+
const _flagRefs = flagRefs || EMPTY_ARRAY;
|
|
1065
1146
|
useEffect(() => {
|
|
1066
1147
|
// return early if flags are not raised, or component is not mounted
|
|
1067
|
-
if (some(
|
|
1148
|
+
if (some(_flagRefs, ref => !ref.current) || !scrolledElementRef.current) {
|
|
1068
1149
|
return;
|
|
1069
1150
|
}
|
|
1070
|
-
for (let i = 0; i <
|
|
1071
|
-
|
|
1151
|
+
for (let i = 0; i < _flagRefs.length; i++) {
|
|
1152
|
+
_flagRefs[i].current = false;
|
|
1072
1153
|
}
|
|
1073
|
-
const itemToBeScrolled =
|
|
1074
|
-
const scrollContainer =
|
|
1154
|
+
const itemToBeScrolled = scrolledElementRef.current;
|
|
1155
|
+
const scrollContainer = getScrollContainer(itemToBeScrolled);
|
|
1075
1156
|
if (!scrollContainer) {
|
|
1076
1157
|
return;
|
|
1077
1158
|
}
|
|
1078
1159
|
const itemRect = itemToBeScrolled.getBoundingClientRect();
|
|
1079
1160
|
const containerRect = scrollContainer.getBoundingClientRect();
|
|
1080
|
-
|
|
1081
|
-
// should scroll if visible or scrollIfVisible option is set
|
|
1082
|
-
const shouldScroll = scrollOptions.scrollIfVisible || !(itemRect.top >= containerRect.top && itemRect.bottom <= containerRect.bottom);
|
|
1083
|
-
if (!shouldScroll) {
|
|
1084
|
-
return;
|
|
1085
|
-
}
|
|
1086
1161
|
const {
|
|
1087
1162
|
align = 'center',
|
|
1088
1163
|
offset = 0,
|
|
1089
|
-
behavior = 'auto'
|
|
1090
|
-
|
|
1164
|
+
behavior = 'auto',
|
|
1165
|
+
scrollIfVisible = false
|
|
1166
|
+
} = _scrollOptions;
|
|
1167
|
+
const shouldScroll = scrollIfVisible || !(itemRect.top >= containerRect.top && itemRect.bottom <= containerRect.bottom);
|
|
1168
|
+
if (!shouldScroll) {
|
|
1169
|
+
return;
|
|
1170
|
+
}
|
|
1091
1171
|
const topOffset = _getTopOffset(itemToBeScrolled, scrollContainer, {
|
|
1092
1172
|
align,
|
|
1093
1173
|
offset
|
|
@@ -1103,14 +1183,6 @@ function useScrollIntoView(targetRef, deps, scrollOptions = null, flagRefs = [])
|
|
|
1103
1183
|
|
|
1104
1184
|
// helper //////////////////////
|
|
1105
1185
|
|
|
1106
|
-
function _getNearestScrollableAncestor(el) {
|
|
1107
|
-
while (el) {
|
|
1108
|
-
if (el.scrollHeight > el.clientHeight) {
|
|
1109
|
-
return el;
|
|
1110
|
-
}
|
|
1111
|
-
el = el.parentElement;
|
|
1112
|
-
}
|
|
1113
|
-
}
|
|
1114
1186
|
function _getTopOffset(item, scrollContainer, options) {
|
|
1115
1187
|
const itemRect = item.getBoundingClientRect();
|
|
1116
1188
|
const containerRect = scrollContainer.getBoundingClientRect();
|
|
@@ -1228,6 +1300,17 @@ function useFlushDebounce(func) {
|
|
|
1228
1300
|
return [debounceFunc, flushFunc];
|
|
1229
1301
|
}
|
|
1230
1302
|
|
|
1303
|
+
function useEffectOnChange(value, callback, dependencies = []) {
|
|
1304
|
+
const previousValue = usePrevious(value);
|
|
1305
|
+
useEffect$1(() => {
|
|
1306
|
+
if (value !== previousValue) {
|
|
1307
|
+
callback();
|
|
1308
|
+
}
|
|
1309
|
+
|
|
1310
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
1311
|
+
}, [value, ...dependencies]);
|
|
1312
|
+
}
|
|
1313
|
+
|
|
1231
1314
|
/**
|
|
1232
1315
|
* Template a string reactively based on form data. If the string is not a template, it is returned as is.
|
|
1233
1316
|
* Memoised to minimize re-renders
|
|
@@ -1661,7 +1744,7 @@ function Label(props) {
|
|
|
1661
1744
|
});
|
|
1662
1745
|
}
|
|
1663
1746
|
|
|
1664
|
-
const type$
|
|
1747
|
+
const type$g = 'checkbox';
|
|
1665
1748
|
function Checkbox(props) {
|
|
1666
1749
|
const {
|
|
1667
1750
|
disabled,
|
|
@@ -1692,7 +1775,7 @@ function Checkbox(props) {
|
|
|
1692
1775
|
const descriptionId = `${domId}-description`;
|
|
1693
1776
|
const errorMessageId = `${domId}-error-message`;
|
|
1694
1777
|
return jsxs("div", {
|
|
1695
|
-
class: classNames(formFieldClasses(type$
|
|
1778
|
+
class: classNames(formFieldClasses(type$g, {
|
|
1696
1779
|
errors,
|
|
1697
1780
|
disabled,
|
|
1698
1781
|
readonly
|
|
@@ -1727,7 +1810,7 @@ function Checkbox(props) {
|
|
|
1727
1810
|
});
|
|
1728
1811
|
}
|
|
1729
1812
|
Checkbox.config = {
|
|
1730
|
-
type: type$
|
|
1813
|
+
type: type$g,
|
|
1731
1814
|
keyed: true,
|
|
1732
1815
|
label: 'Checkbox',
|
|
1733
1816
|
group: 'selection',
|
|
@@ -1740,7 +1823,7 @@ Checkbox.config = {
|
|
|
1740
1823
|
})
|
|
1741
1824
|
};
|
|
1742
1825
|
|
|
1743
|
-
const type$
|
|
1826
|
+
const type$f = 'checklist';
|
|
1744
1827
|
function Checklist(props) {
|
|
1745
1828
|
const {
|
|
1746
1829
|
disabled,
|
|
@@ -1794,7 +1877,7 @@ function Checklist(props) {
|
|
|
1794
1877
|
const descriptionId = `${domId}-description`;
|
|
1795
1878
|
const errorMessageId = `${domId}-error-message`;
|
|
1796
1879
|
return jsxs("div", {
|
|
1797
|
-
class: classNames(formFieldClasses(type$
|
|
1880
|
+
class: classNames(formFieldClasses(type$f, {
|
|
1798
1881
|
errors,
|
|
1799
1882
|
disabled,
|
|
1800
1883
|
readonly
|
|
@@ -1838,7 +1921,7 @@ function Checklist(props) {
|
|
|
1838
1921
|
});
|
|
1839
1922
|
}
|
|
1840
1923
|
Checklist.config = {
|
|
1841
|
-
type: type$
|
|
1924
|
+
type: type$f,
|
|
1842
1925
|
keyed: true,
|
|
1843
1926
|
label: 'Checkbox group',
|
|
1844
1927
|
group: 'selection',
|
|
@@ -1881,6 +1964,7 @@ function FormField(props) {
|
|
|
1881
1964
|
if (!FormFieldComponent) {
|
|
1882
1965
|
throw new Error(`cannot render field <${field.type}>`);
|
|
1883
1966
|
}
|
|
1967
|
+
const fieldConfig = FormFieldComponent.config;
|
|
1884
1968
|
const valuePath = useMemo(() => pathRegistry.getValuePath(field, {
|
|
1885
1969
|
indexes
|
|
1886
1970
|
}), [field, indexes, pathRegistry]);
|
|
@@ -1933,11 +2017,11 @@ function FormField(props) {
|
|
|
1933
2017
|
setInitialValidationTrigger(false);
|
|
1934
2018
|
|
|
1935
2019
|
// add indexes of the keyed field to the update, if any
|
|
1936
|
-
onChange(
|
|
2020
|
+
onChange(fieldConfig.keyed ? {
|
|
1937
2021
|
...update,
|
|
1938
2022
|
indexes
|
|
1939
2023
|
} : update);
|
|
1940
|
-
}, [onChange,
|
|
2024
|
+
}, [onChange, fieldConfig.keyed, indexes]);
|
|
1941
2025
|
if (hidden) {
|
|
1942
2026
|
return jsx(Hidden, {
|
|
1943
2027
|
field: field
|
|
@@ -1945,23 +2029,27 @@ function FormField(props) {
|
|
|
1945
2029
|
}
|
|
1946
2030
|
const domId = `${prefixId(field.id, formId, indexes)}`;
|
|
1947
2031
|
const fieldErrors = get(errors, [field.id, ...Object.values(indexes || {})]) || [];
|
|
2032
|
+
const formFieldElement = jsx(FormFieldComponent, {
|
|
2033
|
+
...props,
|
|
2034
|
+
disabled: disabled,
|
|
2035
|
+
errors: fieldErrors,
|
|
2036
|
+
domId: domId,
|
|
2037
|
+
onChange: disabled || readonly ? noop$1 : onChangeIndexed,
|
|
2038
|
+
onBlur: disabled || readonly ? noop$1 : onBlur,
|
|
2039
|
+
onFocus: disabled || readonly ? noop$1 : onFocus,
|
|
2040
|
+
readonly: readonly,
|
|
2041
|
+
value: value
|
|
2042
|
+
});
|
|
2043
|
+
if (fieldConfig.escapeGridRender) {
|
|
2044
|
+
return formFieldElement;
|
|
2045
|
+
}
|
|
1948
2046
|
return jsx(Column, {
|
|
1949
2047
|
field: field,
|
|
1950
2048
|
class: gridColumnClasses(field),
|
|
1951
2049
|
children: jsx(Element, {
|
|
1952
2050
|
class: "fjs-element",
|
|
1953
2051
|
field: field,
|
|
1954
|
-
children:
|
|
1955
|
-
...props,
|
|
1956
|
-
disabled: disabled,
|
|
1957
|
-
errors: fieldErrors,
|
|
1958
|
-
domId: domId,
|
|
1959
|
-
onChange: disabled || readonly ? noop$1 : onChangeIndexed,
|
|
1960
|
-
onBlur: disabled || readonly ? noop$1 : onBlur,
|
|
1961
|
-
onFocus: disabled || readonly ? noop$1 : onFocus,
|
|
1962
|
-
readonly: readonly,
|
|
1963
|
-
value: value
|
|
1964
|
-
})
|
|
2052
|
+
children: formFieldElement
|
|
1965
2053
|
})
|
|
1966
2054
|
});
|
|
1967
2055
|
}
|
|
@@ -2121,16 +2209,16 @@ Default.config = {
|
|
|
2121
2209
|
})
|
|
2122
2210
|
};
|
|
2123
2211
|
|
|
2124
|
-
var _path$
|
|
2125
|
-
function _extends$
|
|
2212
|
+
var _path$w;
|
|
2213
|
+
function _extends$x() { _extends$x = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$x.apply(this, arguments); }
|
|
2126
2214
|
var SvgCalendar = function SvgCalendar(props) {
|
|
2127
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
2215
|
+
return /*#__PURE__*/React.createElement("svg", _extends$x({
|
|
2128
2216
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2129
2217
|
width: 14,
|
|
2130
2218
|
height: 15,
|
|
2131
2219
|
fill: "none",
|
|
2132
2220
|
viewBox: "0 0 28 30"
|
|
2133
|
-
}, props), _path$
|
|
2221
|
+
}, props), _path$w || (_path$w = /*#__PURE__*/React.createElement("path", {
|
|
2134
2222
|
fill: "currentColor",
|
|
2135
2223
|
fillRule: "evenodd",
|
|
2136
2224
|
d: "M19 2H9V0H7v2H2a2 2 0 0 0-2 2v24a2 2 0 0 0 2 2h24a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-5V0h-2v2ZM7 7V4H2v5h24V4h-5v3h-2V4H9v3H7Zm-5 4v17h24V11H2Z",
|
|
@@ -2394,16 +2482,16 @@ function Datepicker(props) {
|
|
|
2394
2482
|
});
|
|
2395
2483
|
}
|
|
2396
2484
|
|
|
2397
|
-
var _path$
|
|
2398
|
-
function _extends$
|
|
2485
|
+
var _path$v, _path2$5;
|
|
2486
|
+
function _extends$w() { _extends$w = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$w.apply(this, arguments); }
|
|
2399
2487
|
var SvgClock = function SvgClock(props) {
|
|
2400
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
2488
|
+
return /*#__PURE__*/React.createElement("svg", _extends$w({
|
|
2401
2489
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2402
2490
|
width: 16,
|
|
2403
2491
|
height: 16,
|
|
2404
2492
|
fill: "none",
|
|
2405
2493
|
viewBox: "0 0 28 29"
|
|
2406
|
-
}, props), _path$
|
|
2494
|
+
}, props), _path$v || (_path$v = /*#__PURE__*/React.createElement("path", {
|
|
2407
2495
|
fill: "currentColor",
|
|
2408
2496
|
d: "M13 14.41 18.59 20 20 18.59l-5-5.01V5h-2v9.41Z"
|
|
2409
2497
|
})), _path2$5 || (_path2$5 = /*#__PURE__*/React.createElement("path", {
|
|
@@ -2675,7 +2763,7 @@ function Timepicker(props) {
|
|
|
2675
2763
|
});
|
|
2676
2764
|
}
|
|
2677
2765
|
|
|
2678
|
-
const type$
|
|
2766
|
+
const type$e = 'datetime';
|
|
2679
2767
|
function Datetime(props) {
|
|
2680
2768
|
const {
|
|
2681
2769
|
disabled,
|
|
@@ -2847,7 +2935,7 @@ function Datetime(props) {
|
|
|
2847
2935
|
'aria-describedby': [descriptionId, errorMessageId].join(' ')
|
|
2848
2936
|
};
|
|
2849
2937
|
return jsxs("div", {
|
|
2850
|
-
class: formFieldClasses(type$
|
|
2938
|
+
class: formFieldClasses(type$e, {
|
|
2851
2939
|
errors: allErrors,
|
|
2852
2940
|
disabled,
|
|
2853
2941
|
readonly
|
|
@@ -2872,7 +2960,7 @@ function Datetime(props) {
|
|
|
2872
2960
|
});
|
|
2873
2961
|
}
|
|
2874
2962
|
Datetime.config = {
|
|
2875
|
-
type: type$
|
|
2963
|
+
type: type$e,
|
|
2876
2964
|
keyed: true,
|
|
2877
2965
|
label: 'Date time',
|
|
2878
2966
|
group: 'basic-input',
|
|
@@ -2932,7 +3020,7 @@ Group.config = {
|
|
|
2932
3020
|
})
|
|
2933
3021
|
};
|
|
2934
3022
|
|
|
2935
|
-
const type$
|
|
3023
|
+
const type$d = 'iframe';
|
|
2936
3024
|
const DEFAULT_HEIGHT = 300;
|
|
2937
3025
|
function IFrame(props) {
|
|
2938
3026
|
const {
|
|
@@ -2962,7 +3050,7 @@ function IFrame(props) {
|
|
|
2962
3050
|
setIframeRefresh(count => count + 1);
|
|
2963
3051
|
}, [sandbox, allow]);
|
|
2964
3052
|
return jsxs("div", {
|
|
2965
|
-
class: formFieldClasses(type$
|
|
3053
|
+
class: formFieldClasses(type$d, {
|
|
2966
3054
|
disabled,
|
|
2967
3055
|
readonly
|
|
2968
3056
|
}),
|
|
@@ -2997,7 +3085,7 @@ function IFramePlaceholder(props) {
|
|
|
2997
3085
|
});
|
|
2998
3086
|
}
|
|
2999
3087
|
IFrame.config = {
|
|
3000
|
-
type: type$
|
|
3088
|
+
type: type$d,
|
|
3001
3089
|
keyed: false,
|
|
3002
3090
|
label: 'iFrame',
|
|
3003
3091
|
group: 'container',
|
|
@@ -3009,44 +3097,44 @@ IFrame.config = {
|
|
|
3009
3097
|
})
|
|
3010
3098
|
};
|
|
3011
3099
|
|
|
3012
|
-
var _path$
|
|
3013
|
-
function _extends$
|
|
3100
|
+
var _path$u;
|
|
3101
|
+
function _extends$v() { _extends$v = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$v.apply(this, arguments); }
|
|
3014
3102
|
var SvgButton = function SvgButton(props) {
|
|
3015
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3103
|
+
return /*#__PURE__*/React.createElement("svg", _extends$v({
|
|
3016
3104
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3017
3105
|
width: 54,
|
|
3018
3106
|
height: 54,
|
|
3019
3107
|
fill: "currentcolor"
|
|
3020
|
-
}, props), _path$
|
|
3108
|
+
}, props), _path$u || (_path$u = /*#__PURE__*/React.createElement("path", {
|
|
3021
3109
|
fillRule: "evenodd",
|
|
3022
3110
|
d: "M45 17a3 3 0 0 1 3 3v14a3 3 0 0 1-3 3H9a3 3 0 0 1-3-3V20a3 3 0 0 1 3-3h36zm-9 8.889H18v2.222h18v-2.222z"
|
|
3023
3111
|
})));
|
|
3024
3112
|
};
|
|
3025
3113
|
var ButtonIcon = SvgButton;
|
|
3026
3114
|
|
|
3027
|
-
var _path$
|
|
3028
|
-
function _extends$
|
|
3115
|
+
var _path$t;
|
|
3116
|
+
function _extends$u() { _extends$u = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$u.apply(this, arguments); }
|
|
3029
3117
|
var SvgCheckbox = function SvgCheckbox(props) {
|
|
3030
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3118
|
+
return /*#__PURE__*/React.createElement("svg", _extends$u({
|
|
3031
3119
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3032
3120
|
width: 54,
|
|
3033
3121
|
height: 54,
|
|
3034
3122
|
fill: "currentcolor"
|
|
3035
|
-
}, props), _path$
|
|
3123
|
+
}, props), _path$t || (_path$t = /*#__PURE__*/React.createElement("path", {
|
|
3036
3124
|
d: "M34 18H20a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V20a2 2 0 0 0-2-2zm-9 14-5-5 1.41-1.41L25 29.17l7.59-7.59L34 23l-9 9z"
|
|
3037
3125
|
})));
|
|
3038
3126
|
};
|
|
3039
3127
|
var CheckboxIcon = SvgCheckbox;
|
|
3040
3128
|
|
|
3041
|
-
var _path$
|
|
3042
|
-
function _extends$
|
|
3129
|
+
var _path$s;
|
|
3130
|
+
function _extends$t() { _extends$t = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$t.apply(this, arguments); }
|
|
3043
3131
|
var SvgChecklist = function SvgChecklist(props) {
|
|
3044
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3132
|
+
return /*#__PURE__*/React.createElement("svg", _extends$t({
|
|
3045
3133
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3046
3134
|
width: 54,
|
|
3047
3135
|
height: 54,
|
|
3048
3136
|
fill: "none"
|
|
3049
|
-
}, props), _path$
|
|
3137
|
+
}, props), _path$s || (_path$s = /*#__PURE__*/React.createElement("path", {
|
|
3050
3138
|
fill: "currentColor",
|
|
3051
3139
|
fillRule: "evenodd",
|
|
3052
3140
|
d: "M14.35 24.75H19v4.65h-4.65v-4.65Zm-1.414-1.414a2 2 0 0 1 1.414-.586H19a2 2 0 0 1 2 2v4.65a2 2 0 0 1-2 2h-4.65a2 2 0 0 1-2-2v-4.65a2 2 0 0 1 .586-1.414ZM14.35 37.05H19v4.65h-4.65v-4.65Zm-1.414-1.414a2 2 0 0 1 1.414-.586H19a2 2 0 0 1 2 2v4.65a2 2 0 0 1-2 2h-4.65a2 2 0 0 1-2-2v-4.65a2 2 0 0 1 .586-1.414ZM14.35 12.45H19v4.65h-4.65v-4.65Zm-1.414-1.414a2 2 0 0 1 1.414-.586H19a2 2 0 0 1 2 2v4.65a2 2 0 0 1-2 2h-4.65a2 2 0 0 1-2-2v-4.65a2 2 0 0 1 .586-1.414Zm12.007 14.977a1 1 0 0 0-.293.707v.65a1 1 0 0 0 1 1h15a1 1 0 0 0 1-1v-.65a1 1 0 0 0-1-1h-15a1 1 0 0 0-.707.293Zm0 12.3a1 1 0 0 0-.293.707v.65a1 1 0 0 0 1 1h15a1 1 0 0 0 1-1v-.65a1 1 0 0 0-1-1h-15a1 1 0 0 0-.707.293Zm0-24.6a1 1 0 0 0-.293.707v.65a1 1 0 0 0 1 1h15a1 1 0 0 0 1-1v-.65a1 1 0 0 0-1-1h-15a1 1 0 0 0-.707.293Z",
|
|
@@ -3055,15 +3143,15 @@ var SvgChecklist = function SvgChecklist(props) {
|
|
|
3055
3143
|
};
|
|
3056
3144
|
var ChecklistIcon = SvgChecklist;
|
|
3057
3145
|
|
|
3058
|
-
var _path$
|
|
3059
|
-
function _extends$
|
|
3146
|
+
var _path$r, _path2$4, _path3;
|
|
3147
|
+
function _extends$s() { _extends$s = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$s.apply(this, arguments); }
|
|
3060
3148
|
var SvgDatetime = function SvgDatetime(props) {
|
|
3061
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3149
|
+
return /*#__PURE__*/React.createElement("svg", _extends$s({
|
|
3062
3150
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3063
3151
|
width: 54,
|
|
3064
3152
|
height: 54,
|
|
3065
3153
|
fill: "currentcolor"
|
|
3066
|
-
}, props), _path$
|
|
3154
|
+
}, props), _path$r || (_path$r = /*#__PURE__*/React.createElement("path", {
|
|
3067
3155
|
fillRule: "evenodd",
|
|
3068
3156
|
d: "M37.908 13.418h-5.004v-2.354h-1.766v2.354H21.13v-2.354h-1.766v2.354H14.36a2.07 2.07 0 0 0-2.06 2.06v23.549a2.07 2.07 0 0 0 2.06 2.06h6.77v-1.766h-6.358a.707.707 0 0 1-.706-.706V15.89c0-.39.316-.707.706-.707h4.592v2.355h1.766v-2.355h10.008v2.355h1.766v-2.355h4.592a.71.71 0 0 1 .707.707v6.358h1.765v-6.77c0-1.133-.927-2.06-2.06-2.06z"
|
|
3069
3157
|
})), _path2$4 || (_path2$4 = /*#__PURE__*/React.createElement("path", {
|
|
@@ -3075,15 +3163,15 @@ var SvgDatetime = function SvgDatetime(props) {
|
|
|
3075
3163
|
};
|
|
3076
3164
|
var DatetimeIcon = SvgDatetime;
|
|
3077
3165
|
|
|
3078
|
-
var _path$
|
|
3079
|
-
function _extends$
|
|
3166
|
+
var _path$q, _path2$3;
|
|
3167
|
+
function _extends$r() { _extends$r = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$r.apply(this, arguments); }
|
|
3080
3168
|
var SvgTaglist = function SvgTaglist(props) {
|
|
3081
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3169
|
+
return /*#__PURE__*/React.createElement("svg", _extends$r({
|
|
3082
3170
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3083
3171
|
width: 54,
|
|
3084
3172
|
height: 54,
|
|
3085
3173
|
fill: "currentcolor"
|
|
3086
|
-
}, props), _path$
|
|
3174
|
+
}, props), _path$q || (_path$q = /*#__PURE__*/React.createElement("path", {
|
|
3087
3175
|
fillRule: "evenodd",
|
|
3088
3176
|
d: "M45 16a3 3 0 0 1 3 3v16a3 3 0 0 1-3 3H9a3 3 0 0 1-3-3V19a3 3 0 0 1 3-3h36Zm0 2H9a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h36a1 1 0 0 0 1-1V19a1 1 0 0 0-1-1Z"
|
|
3089
3177
|
})), _path2$3 || (_path2$3 = /*#__PURE__*/React.createElement("path", {
|
|
@@ -3093,9 +3181,9 @@ var SvgTaglist = function SvgTaglist(props) {
|
|
|
3093
3181
|
var TaglistIcon = SvgTaglist;
|
|
3094
3182
|
|
|
3095
3183
|
var _rect, _rect2, _rect3;
|
|
3096
|
-
function _extends$
|
|
3184
|
+
function _extends$q() { _extends$q = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$q.apply(this, arguments); }
|
|
3097
3185
|
var SvgForm = function SvgForm(props) {
|
|
3098
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3186
|
+
return /*#__PURE__*/React.createElement("svg", _extends$q({
|
|
3099
3187
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3100
3188
|
width: 54,
|
|
3101
3189
|
height: 54
|
|
@@ -3121,104 +3209,104 @@ var SvgForm = function SvgForm(props) {
|
|
|
3121
3209
|
};
|
|
3122
3210
|
var FormIcon = SvgForm;
|
|
3123
3211
|
|
|
3124
|
-
var _path$
|
|
3125
|
-
function _extends$
|
|
3212
|
+
var _path$p;
|
|
3213
|
+
function _extends$p() { _extends$p = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$p.apply(this, arguments); }
|
|
3126
3214
|
var SvgGroup = function SvgGroup(props) {
|
|
3127
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3215
|
+
return /*#__PURE__*/React.createElement("svg", _extends$p({
|
|
3128
3216
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3129
3217
|
width: 54,
|
|
3130
3218
|
height: 54,
|
|
3131
3219
|
fill: "currentcolor"
|
|
3132
|
-
}, props), _path$
|
|
3220
|
+
}, props), _path$p || (_path$p = /*#__PURE__*/React.createElement("path", {
|
|
3133
3221
|
fillRule: "evenodd",
|
|
3134
3222
|
d: "M8 33v5a1 1 0 0 0 1 1h4v2H9a3 3 0 0 1-3-3v-5h2Zm18 6v2H15v-2h11Zm13 0v2H28v-2h11Zm9-6v5a3 3 0 0 1-3 3h-4v-2h4a1 1 0 0 0 .993-.883L46 38v-5h2ZM8 22v9H6v-9h2Zm40 0v9h-2v-9h2Zm-35-9v2H9a1 1 0 0 0-.993.883L8 16v4H6v-4a3 3 0 0 1 3-3h4Zm32 0a3 3 0 0 1 3 3v4h-2v-4a1 1 0 0 0-.883-.993L45 15h-4v-2h4Zm-6 0v2H28v-2h11Zm-13 0v2H15v-2h11Z"
|
|
3135
3223
|
})));
|
|
3136
3224
|
};
|
|
3137
3225
|
var GroupIcon = SvgGroup;
|
|
3138
3226
|
|
|
3139
|
-
var _path$
|
|
3140
|
-
function _extends$
|
|
3227
|
+
var _path$o;
|
|
3228
|
+
function _extends$o() { _extends$o = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$o.apply(this, arguments); }
|
|
3141
3229
|
var SvgNumber = function SvgNumber(props) {
|
|
3142
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3230
|
+
return /*#__PURE__*/React.createElement("svg", _extends$o({
|
|
3143
3231
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3144
3232
|
width: 54,
|
|
3145
3233
|
height: 54,
|
|
3146
3234
|
fill: "currentcolor"
|
|
3147
|
-
}, props), _path$
|
|
3235
|
+
}, props), _path$o || (_path$o = /*#__PURE__*/React.createElement("path", {
|
|
3148
3236
|
fillRule: "evenodd",
|
|
3149
3237
|
d: "M45 16a3 3 0 0 1 3 3v16a3 3 0 0 1-3 3H9a3 3 0 0 1-3-3V19a3 3 0 0 1 3-3h36zm0 2H9a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h36a1 1 0 0 0 1-1V19a1 1 0 0 0-1-1zM35 28.444h7l-3.5 4-3.5-4zM35 26h7l-3.5-4-3.5 4z"
|
|
3150
3238
|
})));
|
|
3151
3239
|
};
|
|
3152
3240
|
var NumberIcon = SvgNumber;
|
|
3153
3241
|
|
|
3154
|
-
var _path$
|
|
3155
|
-
function _extends$
|
|
3242
|
+
var _path$n;
|
|
3243
|
+
function _extends$n() { _extends$n = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$n.apply(this, arguments); }
|
|
3156
3244
|
var SvgRadio = function SvgRadio(props) {
|
|
3157
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3245
|
+
return /*#__PURE__*/React.createElement("svg", _extends$n({
|
|
3158
3246
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3159
3247
|
width: 54,
|
|
3160
3248
|
height: 54,
|
|
3161
3249
|
fill: "currentcolor"
|
|
3162
|
-
}, props), _path$
|
|
3250
|
+
}, props), _path$n || (_path$n = /*#__PURE__*/React.createElement("path", {
|
|
3163
3251
|
d: "M27 22c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5zm0-5c-5.52 0-10 4.48-10 10s4.48 10 10 10 10-4.48 10-10-4.48-10-10-10zm0 18a8 8 0 1 1 0-16 8 8 0 1 1 0 16z"
|
|
3164
3252
|
})));
|
|
3165
3253
|
};
|
|
3166
3254
|
var RadioIcon = SvgRadio;
|
|
3167
3255
|
|
|
3168
|
-
var _path$
|
|
3169
|
-
function _extends$
|
|
3256
|
+
var _path$m;
|
|
3257
|
+
function _extends$m() { _extends$m = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$m.apply(this, arguments); }
|
|
3170
3258
|
var SvgSelect = function SvgSelect(props) {
|
|
3171
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3259
|
+
return /*#__PURE__*/React.createElement("svg", _extends$m({
|
|
3172
3260
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3173
3261
|
width: 54,
|
|
3174
3262
|
height: 54,
|
|
3175
3263
|
fill: "currentcolor"
|
|
3176
|
-
}, props), _path$
|
|
3264
|
+
}, props), _path$m || (_path$m = /*#__PURE__*/React.createElement("path", {
|
|
3177
3265
|
fillRule: "evenodd",
|
|
3178
3266
|
d: "M45 16a3 3 0 0 1 3 3v16a3 3 0 0 1-3 3H9a3 3 0 0 1-3-3V19a3 3 0 0 1 3-3h36zm0 2H9a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h36a1 1 0 0 0 1-1V19a1 1 0 0 0-1-1zm-12 7h9l-4.5 6-4.5-6z"
|
|
3179
3267
|
})));
|
|
3180
3268
|
};
|
|
3181
3269
|
var SelectIcon = SvgSelect;
|
|
3182
3270
|
|
|
3183
|
-
var _path$
|
|
3184
|
-
function _extends$
|
|
3271
|
+
var _path$l;
|
|
3272
|
+
function _extends$l() { _extends$l = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$l.apply(this, arguments); }
|
|
3185
3273
|
var SvgSeparator = function SvgSeparator(props) {
|
|
3186
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3274
|
+
return /*#__PURE__*/React.createElement("svg", _extends$l({
|
|
3187
3275
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3188
3276
|
width: 54,
|
|
3189
3277
|
height: 54,
|
|
3190
3278
|
fill: "none"
|
|
3191
|
-
}, props), _path$
|
|
3279
|
+
}, props), _path$l || (_path$l = /*#__PURE__*/React.createElement("path", {
|
|
3192
3280
|
fill: "currentColor",
|
|
3193
3281
|
d: "M26.293 16.293a1 1 0 0 1 1.414 0l4 4a1 1 0 0 1-1.414 1.414L27 18.414l-3.293 3.293a1 1 0 0 1-1.414-1.414l4-4ZM9 26h36v2H9v-2Zm13.293 7.707 4 4a1 1 0 0 0 1.414 0l4-4a1 1 0 0 0-1.414-1.414L27 35.586l-3.293-3.293a1 1 0 0 0-1.414 1.414Z"
|
|
3194
3282
|
})));
|
|
3195
3283
|
};
|
|
3196
3284
|
var SeparatorIcon = SvgSeparator;
|
|
3197
3285
|
|
|
3198
|
-
var _path$
|
|
3199
|
-
function _extends$
|
|
3286
|
+
var _path$k;
|
|
3287
|
+
function _extends$k() { _extends$k = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$k.apply(this, arguments); }
|
|
3200
3288
|
var SvgSpacer = function SvgSpacer(props) {
|
|
3201
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3289
|
+
return /*#__PURE__*/React.createElement("svg", _extends$k({
|
|
3202
3290
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3203
3291
|
width: 54,
|
|
3204
3292
|
height: 54,
|
|
3205
3293
|
fill: "none"
|
|
3206
|
-
}, props), _path$
|
|
3294
|
+
}, props), _path$k || (_path$k = /*#__PURE__*/React.createElement("path", {
|
|
3207
3295
|
fill: "currentColor",
|
|
3208
3296
|
d: "M9 15v2h36v-2H9Zm0 22v2h36v-2H9Zm17.293-17.707a1 1 0 0 1 1.414 0l4 4a1 1 0 0 1-1.414 1.414L27 21.414l-3.293 3.293a1 1 0 0 1-1.414-1.414l4-4Zm-4 11.414 4 4a1 1 0 0 0 1.414 0l4-4a1 1 0 0 0-1.414-1.414L27 32.586l-3.293-3.293a1 1 0 0 0-1.414 1.414Z"
|
|
3209
3297
|
})));
|
|
3210
3298
|
};
|
|
3211
3299
|
var SpacerIcon = SvgSpacer;
|
|
3212
3300
|
|
|
3213
|
-
var _path$
|
|
3214
|
-
function _extends$
|
|
3301
|
+
var _path$j;
|
|
3302
|
+
function _extends$j() { _extends$j = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$j.apply(this, arguments); }
|
|
3215
3303
|
var SvgDynamicList = function SvgDynamicList(props) {
|
|
3216
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3304
|
+
return /*#__PURE__*/React.createElement("svg", _extends$j({
|
|
3217
3305
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3218
3306
|
width: 54,
|
|
3219
3307
|
height: 54,
|
|
3220
3308
|
fill: "none"
|
|
3221
|
-
}, props), _path$
|
|
3309
|
+
}, props), _path$j || (_path$j = /*#__PURE__*/React.createElement("path", {
|
|
3222
3310
|
fill: "currentColor",
|
|
3223
3311
|
fillRule: "evenodd",
|
|
3224
3312
|
d: "M2.7 43.296v1.254c0 .746.604 1.35 1.35 1.35h1.275v-1.795c.049.14.075.29.075.445v-1.254h-.075V43.2H4.05c.177 0 .347.034.502.096H2.7Zm2.7-2.507v-2.507H2.7v2.507h2.7Zm0-5.014v-2.507H2.7v2.507h2.7Zm0-5.014v-2.507H2.7v2.507h2.7Zm0-5.015V23.24H2.7v2.507h2.7Zm0-5.014v-2.507H2.7v2.507h2.7Zm0-5.014V13.21H2.7v2.507h2.7Zm-2.7-5.014h1.852a1.346 1.346 0 0 1-.502.096h1.275v-.096H5.4V9.45c0 .156-.026.306-.075.445V8.1H4.05A1.35 1.35 0 0 0 2.7 9.45v1.254Zm5.175.096h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1 0h2.55V8.1h-2.55v2.7Zm5.1-2.7v1.795a1.348 1.348 0 0 1-.075-.445v1.254h.075v.096h1.275c-.177 0-.347-.034-.502-.096H51.3V9.45a1.35 1.35 0 0 0-1.35-1.35h-1.275Zm-.075 5.11v2.508h2.7V13.21h-2.7Zm0 5.015v2.507h2.7v-2.507h-2.7Zm0 5.014v2.507h2.7V23.24h-2.7Zm0 5.015v2.507h2.7v-2.507h-2.7Zm0 5.014v2.507h2.7v-2.507h-2.7Zm0 5.014v2.507h2.7v-2.507h-2.7Zm2.7 5.014h-1.852c.155-.062.325-.096.502-.096h-1.275v.096H48.6v1.254c0-.156.026-.305.075-.445V45.9h1.275a1.35 1.35 0 0 0 1.35-1.35v-1.254Zm-5.175-.096h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7Zm-5.1 0h-2.55v2.7h2.55v-2.7ZM16.2 17.55a4.05 4.05 0 0 1 4.05 4.05v1.35A4.05 4.05 0 0 1 16.2 27h-1.35a4.05 4.05 0 0 1-4.05-4.05V21.6a4.05 4.05 0 0 1 4.05-4.05h1.35Zm0 2.7h-1.35a1.35 1.35 0 0 0-1.35 1.35v1.35c0 .746.604 1.35 1.35 1.35h1.35a1.35 1.35 0 0 0 1.35-1.35V21.6a1.35 1.35 0 0 0-1.35-1.35Zm27 1.35a4.05 4.05 0 0 0-4.05-4.05H29.7a4.05 4.05 0 0 0-4.05 4.05v1.35A4.05 4.05 0 0 0 29.7 27h9.45a4.05 4.05 0 0 0 4.05-4.05V21.6Zm-13.5-1.35h9.45c.746 0 1.35.604 1.35 1.35v1.35a1.35 1.35 0 0 1-1.35 1.35H29.7a1.35 1.35 0 0 1-1.35-1.35V21.6c0-.746.604-1.35 1.35-1.35ZM43.2 37.8a4.05 4.05 0 0 0-4.05-4.05H29.7a4.05 4.05 0 0 0-4.05 4.05v1.35h2.7V37.8c0-.746.604-1.35 1.35-1.35h9.45c.746 0 1.35.604 1.35 1.35v1.35h2.7V37.8Zm-27-4.05a4.05 4.05 0 0 1 4.05 4.05v1.35h-2.7V37.8a1.35 1.35 0 0 0-1.35-1.35h-1.35a1.35 1.35 0 0 0-1.35 1.35v1.35h-2.7V37.8a4.05 4.05 0 0 1 4.05-4.05h1.35Z",
|
|
@@ -3227,29 +3315,29 @@ var SvgDynamicList = function SvgDynamicList(props) {
|
|
|
3227
3315
|
};
|
|
3228
3316
|
var DynamicListIcon = SvgDynamicList;
|
|
3229
3317
|
|
|
3230
|
-
var _path$
|
|
3231
|
-
function _extends$
|
|
3318
|
+
var _path$i;
|
|
3319
|
+
function _extends$i() { _extends$i = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$i.apply(this, arguments); }
|
|
3232
3320
|
var SvgText = function SvgText(props) {
|
|
3233
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3321
|
+
return /*#__PURE__*/React.createElement("svg", _extends$i({
|
|
3234
3322
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3235
3323
|
width: 54,
|
|
3236
3324
|
height: 54,
|
|
3237
3325
|
fill: "currentcolor"
|
|
3238
|
-
}, props), _path$
|
|
3326
|
+
}, props), _path$i || (_path$i = /*#__PURE__*/React.createElement("path", {
|
|
3239
3327
|
d: "M20.58 33.77h-3l-1.18-3.08H11l-1.1 3.08H7l5.27-13.54h2.89zm-5-5.36-1.86-5-1.83 5zM22 20.23h5.41a15.47 15.47 0 0 1 2.4.14 3.42 3.42 0 0 1 1.41.55 3.47 3.47 0 0 1 1 1.14 3 3 0 0 1 .42 1.58 3.26 3.26 0 0 1-1.91 2.94 3.63 3.63 0 0 1 1.91 1.22 3.28 3.28 0 0 1 .66 2 4 4 0 0 1-.43 1.8 3.63 3.63 0 0 1-1.09 1.4 3.89 3.89 0 0 1-1.83.65q-.69.07-3.3.09H22zm2.73 2.25v3.13h3.8a1.79 1.79 0 0 0 1.1-.49 1.41 1.41 0 0 0 .41-1 1.49 1.49 0 0 0-.35-1 1.54 1.54 0 0 0-1-.48c-.27 0-1.05-.05-2.34-.05zm0 5.39v3.62h2.57a11.52 11.52 0 0 0 1.88-.09 1.65 1.65 0 0 0 1-.54 1.6 1.6 0 0 0 .38-1.14 1.75 1.75 0 0 0-.29-1 1.69 1.69 0 0 0-.86-.62 9.28 9.28 0 0 0-2.41-.23zm19.62.92 2.65.84a5.94 5.94 0 0 1-2 3.29A5.74 5.74 0 0 1 41.38 34a5.87 5.87 0 0 1-4.44-1.84 7.09 7.09 0 0 1-1.73-5A7.43 7.43 0 0 1 37 21.87 6 6 0 0 1 41.54 20a5.64 5.64 0 0 1 4 1.47A5.33 5.33 0 0 1 47 24l-2.7.65a2.8 2.8 0 0 0-2.86-2.27A3.09 3.09 0 0 0 39 23.42a5.31 5.31 0 0 0-.93 3.5 5.62 5.62 0 0 0 .93 3.65 3 3 0 0 0 2.4 1.09 2.72 2.72 0 0 0 1.82-.66 4 4 0 0 0 1.13-2.21z"
|
|
3240
3328
|
})));
|
|
3241
3329
|
};
|
|
3242
3330
|
var TextIcon = SvgText;
|
|
3243
3331
|
|
|
3244
|
-
var _path$
|
|
3245
|
-
function _extends$
|
|
3332
|
+
var _path$h;
|
|
3333
|
+
function _extends$h() { _extends$h = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$h.apply(this, arguments); }
|
|
3246
3334
|
var SvgHtml = function SvgHtml(props) {
|
|
3247
|
-
return /*#__PURE__*/React.createElement("svg", _extends$
|
|
3335
|
+
return /*#__PURE__*/React.createElement("svg", _extends$h({
|
|
3248
3336
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3249
3337
|
width: 54,
|
|
3250
3338
|
height: 54,
|
|
3251
3339
|
fill: "none"
|
|
3252
|
-
}, props), _path$
|
|
3340
|
+
}, props), _path$h || (_path$h = /*#__PURE__*/React.createElement("path", {
|
|
3253
3341
|
fill: "currentColor",
|
|
3254
3342
|
fillRule: "evenodd",
|
|
3255
3343
|
d: "M47.008 12.15c1.625 0 2.942 1.36 2.942 3.039v23.622c0 1.678-1.317 3.039-2.942 3.039H6.992c-1.625 0-2.942-1.36-2.942-3.039V15.189c0-1.678 1.317-3.039 2.942-3.039h40.016Zm0 2.026H6.992c-.542 0-.98.454-.98 1.013V16.2h-.004v2.7h.003v19.911c0 .56.44 1.013.98 1.013h40.017c.542 0 .98-.453.98-1.013V18.9h.005v-2.7h-.004v-1.011c0-.56-.44-1.013-.98-1.013ZM14.934 26.055v-3.78h2.194v9.45h-2.194v-3.78h-3.29v3.78H9.45v-9.45h2.194v3.78h3.29Zm4.388-1.89h2.194v7.56h2.193v-7.56h2.194v-1.89h-6.581v1.89Zm14.26-1.89h2.193v9.45h-2.194V25.11l-1.645 3.78-1.645-3.78v6.615h-2.194v-9.45h2.194l1.645 3.78 1.645-3.78Zm4.387 0h2.194v7.56h4.387v1.89h-6.581v-9.45Z",
|
|
@@ -3258,6 +3346,23 @@ var SvgHtml = function SvgHtml(props) {
|
|
|
3258
3346
|
};
|
|
3259
3347
|
var HTMLIcon = SvgHtml;
|
|
3260
3348
|
|
|
3349
|
+
var _path$g;
|
|
3350
|
+
function _extends$g() { _extends$g = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$g.apply(this, arguments); }
|
|
3351
|
+
var SvgExpressionField = function SvgExpressionField(props) {
|
|
3352
|
+
return /*#__PURE__*/React.createElement("svg", _extends$g({
|
|
3353
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3354
|
+
width: 54,
|
|
3355
|
+
height: 54,
|
|
3356
|
+
fill: "none"
|
|
3357
|
+
}, props), _path$g || (_path$g = /*#__PURE__*/React.createElement("path", {
|
|
3358
|
+
fill: "currentcolor",
|
|
3359
|
+
fillRule: "evenodd",
|
|
3360
|
+
d: "M12.78 16.2v6.75c0 1.619-.635 3.059-1.618 4.05.983.991 1.618 2.431 1.618 4.05v6.75h3.51v2.7h-3.51c-1.289 0-2.34-1.213-2.34-2.7v-6.75c0-1.487-1.051-2.7-2.34-2.7v-2.7c1.289 0 2.34-1.213 2.34-2.7V16.2c0-1.487 1.051-2.7 2.34-2.7h3.51v2.7h-3.51Zm30.78 0v6.75c0 1.487 1.051 2.7 2.34 2.7v2.7c-1.289 0-2.34 1.213-2.34 2.7v6.75c0 1.487-1.051 2.7-2.34 2.7h-3.51v-2.7h3.51v-6.75c0-1.619.635-3.059 1.618-4.05-.983-.991-1.618-2.431-1.618-4.05V16.2h-3.51v-2.7h3.51c1.289 0 2.34 1.213 2.34 2.7ZM21.8 34.531c.467-.379.787-.965.959-1.758l1.788-8.34h1.585l.387-1.828h-1.585l.405-1.878h1.585l.387-1.827H25.69c-.847 0-1.505.19-1.972.569-.454.379-.768.965-.94 1.758l-.294 1.378H21.34l-.387 1.827h1.142l-1.898 8.841h-1.585l-.387 1.827h1.622c.848 0 1.499-.19 1.953-.569Zm7.248-7.686-3.797 4.808h2.599l2.12-3.016h.22l.885 3.016h2.599l-1.677-4.36 3.778-4.688h-2.599l-2.12 2.947h-.22l-.885-2.947h-2.599l1.696 4.24Z",
|
|
3361
|
+
clipRule: "evenodd"
|
|
3362
|
+
})));
|
|
3363
|
+
};
|
|
3364
|
+
var ExpressionFieldIcon = SvgExpressionField;
|
|
3365
|
+
|
|
3261
3366
|
var _path$f;
|
|
3262
3367
|
function _extends$f() { _extends$f = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$f.apply(this, arguments); }
|
|
3263
3368
|
var SvgTextfield = function SvgTextfield(props) {
|
|
@@ -3355,6 +3460,7 @@ const iconsByType = type => {
|
|
|
3355
3460
|
iframe: IFrameIcon,
|
|
3356
3461
|
image: ImageIcon,
|
|
3357
3462
|
number: NumberIcon,
|
|
3463
|
+
expression: ExpressionFieldIcon,
|
|
3358
3464
|
radio: RadioIcon,
|
|
3359
3465
|
select: SelectIcon,
|
|
3360
3466
|
separator: SeparatorIcon,
|
|
@@ -3370,7 +3476,7 @@ const iconsByType = type => {
|
|
|
3370
3476
|
}[type];
|
|
3371
3477
|
};
|
|
3372
3478
|
|
|
3373
|
-
const type$
|
|
3479
|
+
const type$c = 'image';
|
|
3374
3480
|
function Image(props) {
|
|
3375
3481
|
const {
|
|
3376
3482
|
field
|
|
@@ -3392,7 +3498,7 @@ function Image(props) {
|
|
|
3392
3498
|
formId
|
|
3393
3499
|
} = useContext(FormContext);
|
|
3394
3500
|
return jsxs("div", {
|
|
3395
|
-
class: formFieldClasses(type$
|
|
3501
|
+
class: formFieldClasses(type$c),
|
|
3396
3502
|
children: [safeSource && jsx("div", {
|
|
3397
3503
|
class: "fjs-image-container",
|
|
3398
3504
|
children: jsx("img", {
|
|
@@ -3416,7 +3522,7 @@ function Image(props) {
|
|
|
3416
3522
|
});
|
|
3417
3523
|
}
|
|
3418
3524
|
Image.config = {
|
|
3419
|
-
type: type$
|
|
3525
|
+
type: type$c,
|
|
3420
3526
|
keyed: false,
|
|
3421
3527
|
label: 'Image view',
|
|
3422
3528
|
group: 'presentation',
|
|
@@ -3508,7 +3614,7 @@ function isNullEquivalentValue(value) {
|
|
|
3508
3614
|
return value === undefined || value === null || value === '';
|
|
3509
3615
|
}
|
|
3510
3616
|
|
|
3511
|
-
const type$
|
|
3617
|
+
const type$b = 'number';
|
|
3512
3618
|
function Numberfield(props) {
|
|
3513
3619
|
const {
|
|
3514
3620
|
disabled,
|
|
@@ -3653,7 +3759,7 @@ function Numberfield(props) {
|
|
|
3653
3759
|
const descriptionId = `${domId}-description`;
|
|
3654
3760
|
const errorMessageId = `${domId}-error-message`;
|
|
3655
3761
|
return jsxs("div", {
|
|
3656
|
-
class: formFieldClasses(type$
|
|
3762
|
+
class: formFieldClasses(type$b, {
|
|
3657
3763
|
errors,
|
|
3658
3764
|
disabled,
|
|
3659
3765
|
readonly
|
|
@@ -3730,7 +3836,7 @@ function Numberfield(props) {
|
|
|
3730
3836
|
});
|
|
3731
3837
|
}
|
|
3732
3838
|
Numberfield.config = {
|
|
3733
|
-
type: type$
|
|
3839
|
+
type: type$b,
|
|
3734
3840
|
keyed: true,
|
|
3735
3841
|
label: 'Number',
|
|
3736
3842
|
group: 'basic-input',
|
|
@@ -3750,7 +3856,7 @@ Numberfield.config = {
|
|
|
3750
3856
|
})
|
|
3751
3857
|
};
|
|
3752
3858
|
|
|
3753
|
-
const type$
|
|
3859
|
+
const type$a = 'radio';
|
|
3754
3860
|
function Radio(props) {
|
|
3755
3861
|
const {
|
|
3756
3862
|
disabled,
|
|
@@ -3803,7 +3909,7 @@ function Radio(props) {
|
|
|
3803
3909
|
const descriptionId = `${domId}-description`;
|
|
3804
3910
|
const errorMessageId = `${domId}-error-message`;
|
|
3805
3911
|
return jsxs("div", {
|
|
3806
|
-
class: formFieldClasses(type$
|
|
3912
|
+
class: formFieldClasses(type$a, {
|
|
3807
3913
|
errors,
|
|
3808
3914
|
disabled,
|
|
3809
3915
|
readonly
|
|
@@ -3847,7 +3953,7 @@ function Radio(props) {
|
|
|
3847
3953
|
});
|
|
3848
3954
|
}
|
|
3849
3955
|
Radio.config = {
|
|
3850
|
-
type: type$
|
|
3956
|
+
type: type$a,
|
|
3851
3957
|
keyed: true,
|
|
3852
3958
|
label: 'Radio group',
|
|
3853
3959
|
group: 'selection',
|
|
@@ -4160,7 +4266,7 @@ function SimpleSelect(props) {
|
|
|
4160
4266
|
});
|
|
4161
4267
|
}
|
|
4162
4268
|
|
|
4163
|
-
const type$
|
|
4269
|
+
const type$9 = 'select';
|
|
4164
4270
|
function Select(props) {
|
|
4165
4271
|
const {
|
|
4166
4272
|
disabled,
|
|
@@ -4199,7 +4305,7 @@ function Select(props) {
|
|
|
4199
4305
|
'aria-describedby': [descriptionId, errorMessageId].join(' ')
|
|
4200
4306
|
};
|
|
4201
4307
|
return jsxs("div", {
|
|
4202
|
-
class: formFieldClasses(type$
|
|
4308
|
+
class: formFieldClasses(type$9, {
|
|
4203
4309
|
errors,
|
|
4204
4310
|
disabled,
|
|
4205
4311
|
readonly
|
|
@@ -4228,7 +4334,7 @@ function Select(props) {
|
|
|
4228
4334
|
});
|
|
4229
4335
|
}
|
|
4230
4336
|
Select.config = {
|
|
4231
|
-
type: type$
|
|
4337
|
+
type: type$9,
|
|
4232
4338
|
keyed: true,
|
|
4233
4339
|
label: 'Select',
|
|
4234
4340
|
group: 'selection',
|
|
@@ -4237,15 +4343,15 @@ Select.config = {
|
|
|
4237
4343
|
create: createEmptyOptions
|
|
4238
4344
|
};
|
|
4239
4345
|
|
|
4240
|
-
const type$
|
|
4346
|
+
const type$8 = 'separator';
|
|
4241
4347
|
function Separator() {
|
|
4242
4348
|
return jsx("div", {
|
|
4243
|
-
class: formFieldClasses(type$
|
|
4349
|
+
class: formFieldClasses(type$8),
|
|
4244
4350
|
children: jsx("hr", {})
|
|
4245
4351
|
});
|
|
4246
4352
|
}
|
|
4247
4353
|
Separator.config = {
|
|
4248
|
-
type: type$
|
|
4354
|
+
type: type$8,
|
|
4249
4355
|
keyed: false,
|
|
4250
4356
|
label: 'Separator',
|
|
4251
4357
|
group: 'presentation',
|
|
@@ -4254,7 +4360,7 @@ Separator.config = {
|
|
|
4254
4360
|
})
|
|
4255
4361
|
};
|
|
4256
4362
|
|
|
4257
|
-
const type$
|
|
4363
|
+
const type$7 = 'spacer';
|
|
4258
4364
|
function Spacer(props) {
|
|
4259
4365
|
const {
|
|
4260
4366
|
field
|
|
@@ -4263,14 +4369,14 @@ function Spacer(props) {
|
|
|
4263
4369
|
height = 60
|
|
4264
4370
|
} = field;
|
|
4265
4371
|
return jsx("div", {
|
|
4266
|
-
class: formFieldClasses(type$
|
|
4372
|
+
class: formFieldClasses(type$7),
|
|
4267
4373
|
style: {
|
|
4268
4374
|
height: height
|
|
4269
4375
|
}
|
|
4270
4376
|
});
|
|
4271
4377
|
}
|
|
4272
4378
|
Spacer.config = {
|
|
4273
|
-
type: type$
|
|
4379
|
+
type: type$7,
|
|
4274
4380
|
keyed: false,
|
|
4275
4381
|
label: 'Spacer',
|
|
4276
4382
|
group: 'presentation',
|
|
@@ -4351,7 +4457,7 @@ function SkipLink(props) {
|
|
|
4351
4457
|
});
|
|
4352
4458
|
}
|
|
4353
4459
|
|
|
4354
|
-
const type$
|
|
4460
|
+
const type$6 = 'taglist';
|
|
4355
4461
|
function Taglist(props) {
|
|
4356
4462
|
const {
|
|
4357
4463
|
disabled,
|
|
@@ -4495,7 +4601,7 @@ function Taglist(props) {
|
|
|
4495
4601
|
const errorMessageId = `${domId}-error-message`;
|
|
4496
4602
|
return jsxs("div", {
|
|
4497
4603
|
ref: focusScopeRef,
|
|
4498
|
-
class: formFieldClasses(type$
|
|
4604
|
+
class: formFieldClasses(type$6, {
|
|
4499
4605
|
errors,
|
|
4500
4606
|
disabled,
|
|
4501
4607
|
readonly
|
|
@@ -4580,7 +4686,7 @@ function Taglist(props) {
|
|
|
4580
4686
|
});
|
|
4581
4687
|
}
|
|
4582
4688
|
Taglist.config = {
|
|
4583
|
-
type: type$
|
|
4689
|
+
type: type$6,
|
|
4584
4690
|
keyed: true,
|
|
4585
4691
|
label: 'Tag list',
|
|
4586
4692
|
group: 'selection',
|
|
@@ -4702,7 +4808,7 @@ function isValidAttribute(lcTag, lcName, value) {
|
|
|
4702
4808
|
return true;
|
|
4703
4809
|
}
|
|
4704
4810
|
|
|
4705
|
-
const type$
|
|
4811
|
+
const type$5 = 'text';
|
|
4706
4812
|
function Text(props) {
|
|
4707
4813
|
const form = useService('form');
|
|
4708
4814
|
const {
|
|
@@ -4749,12 +4855,12 @@ function Text(props) {
|
|
|
4749
4855
|
sanitizeStyleTags: false
|
|
4750
4856
|
});
|
|
4751
4857
|
return jsx("div", {
|
|
4752
|
-
class: formFieldClasses(type$
|
|
4858
|
+
class: formFieldClasses(type$5),
|
|
4753
4859
|
dangerouslySetInnerHTML: dangerouslySetInnerHTML
|
|
4754
4860
|
});
|
|
4755
4861
|
}
|
|
4756
4862
|
Text.config = {
|
|
4757
|
-
type: type$
|
|
4863
|
+
type: type$5,
|
|
4758
4864
|
keyed: false,
|
|
4759
4865
|
label: 'Text view',
|
|
4760
4866
|
group: 'presentation',
|
|
@@ -4764,64 +4870,7 @@ Text.config = {
|
|
|
4764
4870
|
})
|
|
4765
4871
|
};
|
|
4766
4872
|
|
|
4767
|
-
|
|
4768
|
-
* Wrap CSS styles with a given prefix.
|
|
4769
|
-
*
|
|
4770
|
-
* @param {HTMLElement} rootNode
|
|
4771
|
-
* @param {string} prefix
|
|
4772
|
-
*
|
|
4773
|
-
* @returns {HTMLElement}
|
|
4774
|
-
*/
|
|
4775
|
-
function wrapCSSStyles(rootNode, prefix) {
|
|
4776
|
-
const styleTags = rootNode.querySelectorAll('style');
|
|
4777
|
-
styleTags.forEach(styleTag => {
|
|
4778
|
-
const topLevelRules = extractTopLevelRules(styleTag.textContent);
|
|
4779
|
-
const scopedCss = topLevelRules.map(rule => {
|
|
4780
|
-
const {
|
|
4781
|
-
selector,
|
|
4782
|
-
styles
|
|
4783
|
-
} = splitRule(rule);
|
|
4784
|
-
const scopedSelector = scopeSelector(selector, prefix);
|
|
4785
|
-
return `${scopedSelector} ${styles}`;
|
|
4786
|
-
}).join(' ');
|
|
4787
|
-
styleTag.textContent = scopedCss;
|
|
4788
|
-
});
|
|
4789
|
-
return rootNode;
|
|
4790
|
-
}
|
|
4791
|
-
function extractTopLevelRules(cssString) {
|
|
4792
|
-
let cursor = 0;
|
|
4793
|
-
let start = 0;
|
|
4794
|
-
let level = 0;
|
|
4795
|
-
const topLevelRules = [];
|
|
4796
|
-
while (cursor < cssString.length) {
|
|
4797
|
-
if (cssString[cursor] === '{') {
|
|
4798
|
-
level++;
|
|
4799
|
-
}
|
|
4800
|
-
if (cssString[cursor] === '}') {
|
|
4801
|
-
level--;
|
|
4802
|
-
if (level === 0) {
|
|
4803
|
-
topLevelRules.push(cssString.substring(start, cursor + 1));
|
|
4804
|
-
start = cursor + 1;
|
|
4805
|
-
}
|
|
4806
|
-
}
|
|
4807
|
-
cursor++;
|
|
4808
|
-
}
|
|
4809
|
-
return topLevelRules.map(rule => rule.trim());
|
|
4810
|
-
}
|
|
4811
|
-
function splitRule(rule) {
|
|
4812
|
-
const firstBracket = rule.indexOf('{');
|
|
4813
|
-
const selector = rule.substring(0, firstBracket);
|
|
4814
|
-
const styles = rule.substring(firstBracket);
|
|
4815
|
-
return {
|
|
4816
|
-
selector,
|
|
4817
|
-
styles
|
|
4818
|
-
};
|
|
4819
|
-
}
|
|
4820
|
-
function scopeSelector(selector, prefix) {
|
|
4821
|
-
return selector.split(',').map(sel => `${prefix} ${sel.trim()}`).join(', ');
|
|
4822
|
-
}
|
|
4823
|
-
|
|
4824
|
-
const type$3 = 'html';
|
|
4873
|
+
const type$4 = 'html';
|
|
4825
4874
|
function Html(props) {
|
|
4826
4875
|
const form = useService('form');
|
|
4827
4876
|
const {
|
|
@@ -4872,12 +4921,12 @@ function Html(props) {
|
|
|
4872
4921
|
sanitizeStyleTags: false
|
|
4873
4922
|
});
|
|
4874
4923
|
return jsx("div", {
|
|
4875
|
-
class: classNames(formFieldClasses(type$
|
|
4924
|
+
class: classNames(formFieldClasses(type$4), styleScope),
|
|
4876
4925
|
dangerouslySetInnerHTML: dangerouslySetInnerHTML
|
|
4877
4926
|
});
|
|
4878
4927
|
}
|
|
4879
4928
|
Html.config = {
|
|
4880
|
-
type: type$
|
|
4929
|
+
type: type$4,
|
|
4881
4930
|
keyed: false,
|
|
4882
4931
|
label: 'HTML',
|
|
4883
4932
|
group: 'presentation',
|
|
@@ -4887,6 +4936,51 @@ Html.config = {
|
|
|
4887
4936
|
})
|
|
4888
4937
|
};
|
|
4889
4938
|
|
|
4939
|
+
const type$3 = 'expression';
|
|
4940
|
+
function ExpressionField(props) {
|
|
4941
|
+
const {
|
|
4942
|
+
field,
|
|
4943
|
+
onChange
|
|
4944
|
+
} = props;
|
|
4945
|
+
const {
|
|
4946
|
+
computeOn,
|
|
4947
|
+
expression
|
|
4948
|
+
} = field;
|
|
4949
|
+
const evaluation = useExpressionEvaluation(expression);
|
|
4950
|
+
const evaluationMemo = useDeepCompareMemoize(evaluation);
|
|
4951
|
+
const eventBus = useService('eventBus');
|
|
4952
|
+
const sendValue = useCallback(() => {
|
|
4953
|
+
onChange && onChange({
|
|
4954
|
+
field,
|
|
4955
|
+
value: evaluationMemo
|
|
4956
|
+
});
|
|
4957
|
+
}, [field, evaluationMemo, onChange]);
|
|
4958
|
+
useEffectOnChange(evaluationMemo, () => {
|
|
4959
|
+
if (computeOn !== 'change') {
|
|
4960
|
+
return;
|
|
4961
|
+
}
|
|
4962
|
+
sendValue();
|
|
4963
|
+
}, [computeOn, sendValue]);
|
|
4964
|
+
useEffect(() => {
|
|
4965
|
+
if (computeOn === 'presubmit') {
|
|
4966
|
+
eventBus.on('presubmit', sendValue);
|
|
4967
|
+
return () => eventBus.off('presubmit', sendValue);
|
|
4968
|
+
}
|
|
4969
|
+
}, [computeOn, sendValue, eventBus]);
|
|
4970
|
+
return null;
|
|
4971
|
+
}
|
|
4972
|
+
ExpressionField.config = {
|
|
4973
|
+
type: type$3,
|
|
4974
|
+
label: 'Expression',
|
|
4975
|
+
group: 'basic-input',
|
|
4976
|
+
keyed: true,
|
|
4977
|
+
escapeGridRender: true,
|
|
4978
|
+
create: (options = {}) => ({
|
|
4979
|
+
computeOn: 'change',
|
|
4980
|
+
...options
|
|
4981
|
+
})
|
|
4982
|
+
};
|
|
4983
|
+
|
|
4890
4984
|
const type$2 = 'textfield';
|
|
4891
4985
|
function Textfield(props) {
|
|
4892
4986
|
const {
|
|
@@ -5206,7 +5300,7 @@ function Table(props) {
|
|
|
5206
5300
|
key
|
|
5207
5301
|
}) => key);
|
|
5208
5302
|
const evaluatedDataSource = useExpressionEvaluation(dataSource);
|
|
5209
|
-
const data = Array.isArray(evaluatedDataSource) ? evaluatedDataSource : [];
|
|
5303
|
+
const data = Array.isArray(evaluatedDataSource) ? evaluatedDataSource.filter(i => i !== undefined) : [];
|
|
5210
5304
|
const sortedData = sortBy === null ? data : sortByColumn(data, sortBy.key, sortBy.direction);
|
|
5211
5305
|
|
|
5212
5306
|
/** @type {unknown[][]} */
|
|
@@ -5620,7 +5714,7 @@ function FormComponent(props) {
|
|
|
5620
5714
|
});
|
|
5621
5715
|
}
|
|
5622
5716
|
|
|
5623
|
-
const formFields = [Button, Checkbox, Checklist, Default, DynamicList, Numberfield, Datetime, Radio, Select, Taglist, Textfield, Textarea, Text, Image, Table, Html, Spacer, Separator, Group, DynamicList, IFrame];
|
|
5717
|
+
const formFields = [Button, Checkbox, Checklist, Default, DynamicList, Numberfield, Datetime, Radio, Select, Taglist, Textfield, Textarea, ExpressionField, Text, Image, Table, Html, Spacer, Separator, Group, DynamicList, IFrame];
|
|
5624
5718
|
|
|
5625
5719
|
class FormFields {
|
|
5626
5720
|
constructor() {
|
|
@@ -5944,13 +6038,7 @@ const ExpressionLanguageModule = {
|
|
|
5944
6038
|
conditionChecker: ['type', ConditionChecker]
|
|
5945
6039
|
};
|
|
5946
6040
|
|
|
5947
|
-
// bootstrap showdown to support github flavored markdown
|
|
5948
|
-
showdown.setFlavor('github');
|
|
5949
6041
|
class MarkdownRenderer {
|
|
5950
|
-
constructor() {
|
|
5951
|
-
this._converter = new showdown.Converter();
|
|
5952
|
-
}
|
|
5953
|
-
|
|
5954
6042
|
/**
|
|
5955
6043
|
* Render markdown to HTML.
|
|
5956
6044
|
*
|
|
@@ -5959,7 +6047,11 @@ class MarkdownRenderer {
|
|
|
5959
6047
|
* @returns {string} HTML
|
|
5960
6048
|
*/
|
|
5961
6049
|
render(markdown) {
|
|
5962
|
-
|
|
6050
|
+
// @ts-expect-error
|
|
6051
|
+
return marked.parse(markdown, {
|
|
6052
|
+
gfm: true,
|
|
6053
|
+
breaks: true
|
|
6054
|
+
});
|
|
5963
6055
|
}
|
|
5964
6056
|
}
|
|
5965
6057
|
MarkdownRenderer.$inject = [];
|
|
@@ -6910,6 +7002,8 @@ var slice = Array.prototype.slice;
|
|
|
6910
7002
|
* var sum = eventBus.fire('sum', 1, 2);
|
|
6911
7003
|
* console.log(sum); // 3
|
|
6912
7004
|
* ```
|
|
7005
|
+
*
|
|
7006
|
+
* @template [EventMap=null]
|
|
6913
7007
|
*/
|
|
6914
7008
|
function EventBus() {
|
|
6915
7009
|
/**
|
|
@@ -6923,6 +7017,8 @@ function EventBus() {
|
|
|
6923
7017
|
}
|
|
6924
7018
|
|
|
6925
7019
|
/**
|
|
7020
|
+
* @overlord
|
|
7021
|
+
*
|
|
6926
7022
|
* Register an event listener for events with the given name.
|
|
6927
7023
|
*
|
|
6928
7024
|
* The callback will be invoked with `event, ...additionalArguments`
|
|
@@ -6941,6 +7037,25 @@ function EventBus() {
|
|
|
6941
7037
|
* @param {EventBusEventCallback<T>} callback
|
|
6942
7038
|
* @param {any} [that] callback context
|
|
6943
7039
|
*/
|
|
7040
|
+
/**
|
|
7041
|
+
* Register an event listener for events with the given name.
|
|
7042
|
+
*
|
|
7043
|
+
* The callback will be invoked with `event, ...additionalArguments`
|
|
7044
|
+
* that have been passed to {@link EventBus#fire}.
|
|
7045
|
+
*
|
|
7046
|
+
* Returning false from a listener will prevent the events default action
|
|
7047
|
+
* (if any is specified). To stop an event from being processed further in
|
|
7048
|
+
* other listeners execute {@link Event#stopPropagation}.
|
|
7049
|
+
*
|
|
7050
|
+
* Returning anything but `undefined` from a listener will stop the listener propagation.
|
|
7051
|
+
*
|
|
7052
|
+
* @template {keyof EventMap} EventName
|
|
7053
|
+
*
|
|
7054
|
+
* @param {EventName} events to subscribe to
|
|
7055
|
+
* @param {number} [priority=1000] listen priority
|
|
7056
|
+
* @param {EventBusEventCallback<EventMap[EventName]>} callback
|
|
7057
|
+
* @param {any} [that] callback context
|
|
7058
|
+
*/
|
|
6944
7059
|
EventBus.prototype.on = function (events, priority, callback, that) {
|
|
6945
7060
|
events = isArray(events) ? events : [events];
|
|
6946
7061
|
if (isFunction(priority)) {
|
|
@@ -6971,6 +7086,8 @@ EventBus.prototype.on = function (events, priority, callback, that) {
|
|
|
6971
7086
|
};
|
|
6972
7087
|
|
|
6973
7088
|
/**
|
|
7089
|
+
* @overlord
|
|
7090
|
+
*
|
|
6974
7091
|
* Register an event listener that is called only once.
|
|
6975
7092
|
*
|
|
6976
7093
|
* @template T
|
|
@@ -6980,6 +7097,16 @@ EventBus.prototype.on = function (events, priority, callback, that) {
|
|
|
6980
7097
|
* @param {EventBusEventCallback<T>} callback
|
|
6981
7098
|
* @param {any} [that] callback context
|
|
6982
7099
|
*/
|
|
7100
|
+
/**
|
|
7101
|
+
* Register an event listener that is called only once.
|
|
7102
|
+
*
|
|
7103
|
+
* @template {keyof EventMap} EventName
|
|
7104
|
+
*
|
|
7105
|
+
* @param {EventName} events to subscribe to
|
|
7106
|
+
* @param {number} [priority=1000] listen priority
|
|
7107
|
+
* @param {EventBusEventCallback<EventMap[EventName]>} callback
|
|
7108
|
+
* @param {any} [that] callback context
|
|
7109
|
+
*/
|
|
6983
7110
|
EventBus.prototype.once = function (events, priority, callback, that) {
|
|
6984
7111
|
var self = this;
|
|
6985
7112
|
if (isFunction(priority)) {
|
|
@@ -8301,6 +8428,7 @@ class Form {
|
|
|
8301
8428
|
if (properties.readOnly || properties.disabled) {
|
|
8302
8429
|
throw new Error('form is read-only');
|
|
8303
8430
|
}
|
|
8431
|
+
this._emit('presubmit');
|
|
8304
8432
|
const data = this._getSubmitData();
|
|
8305
8433
|
const errors = this.validate();
|
|
8306
8434
|
const result = {
|
|
@@ -8697,7 +8825,7 @@ class Form {
|
|
|
8697
8825
|
}
|
|
8698
8826
|
}
|
|
8699
8827
|
|
|
8700
|
-
const schemaVersion =
|
|
8828
|
+
const schemaVersion = 16;
|
|
8701
8829
|
|
|
8702
8830
|
/**
|
|
8703
8831
|
* @typedef { import('./types').CreateFormOptions } CreateFormOptions
|
|
@@ -8722,5 +8850,5 @@ function createForm(options) {
|
|
|
8722
8850
|
});
|
|
8723
8851
|
}
|
|
8724
8852
|
|
|
8725
|
-
export { ALLOW_ATTRIBUTE, Button, Checkbox, Checklist, ConditionChecker, DATETIME_SUBTYPES, DATETIME_SUBTYPES_LABELS, DATETIME_SUBTYPE_PATH, DATE_DISALLOW_PAST_PATH, DATE_LABEL_PATH, Datetime, Default, Description, DynamicList, Errors, ExpressionLanguageModule, FeelExpressionLanguage, FeelersTemplating, FieldFactory, Form, FormComponent, FormContext, FormField, FormFieldRegistry, FormFields, FormLayouter, FormRenderContext, Group, Html, IFrame, Image, Importer, Label, LocalExpressionContext, MINUTES_IN_DAY, MarkdownRenderer, MarkdownRendererModule, Numberfield, OPTIONS_SOURCES, OPTIONS_SOURCES_DEFAULTS, OPTIONS_SOURCES_LABELS, OPTIONS_SOURCES_PATHS, OPTIONS_SOURCE_DEFAULT, PathRegistry, Radio, RenderModule, RepeatRenderManager, RepeatRenderModule, SANDBOX_ATTRIBUTE, SECURITY_ATTRIBUTES_DEFINITIONS, Select, Separator, Spacer, TIME_INTERVAL_PATH, TIME_LABEL_PATH, TIME_SERIALISINGFORMAT_LABELS, TIME_SERIALISING_FORMATS, TIME_SERIALISING_FORMAT_PATH, TIME_USE24H_PATH, Table, Taglist, Text, Textarea, Textfield, ViewerCommands, ViewerCommandsModule, buildExpressionContext, clone, createForm, createFormContainer, createInjector, escapeHTML, formFields, generateIdForType, generateIndexForType, getAncestryList, getOptionsSource, getSchemaVariables, hasEqualValue, iconsByType, isRequired, pathParse, pathsEqual, runRecursively, sanitizeDateTimePickerValue, sanitizeHTML, sanitizeIFrameSource, sanitizeImageSource, sanitizeMultiSelectValue, sanitizeSingleSelectValue, schemaVersion, useExpressionEvaluation, useSingleLineTemplateEvaluation, useTemplateEvaluation };
|
|
8853
|
+
export { ALLOW_ATTRIBUTE, Button, Checkbox, Checklist, ConditionChecker, DATETIME_SUBTYPES, DATETIME_SUBTYPES_LABELS, DATETIME_SUBTYPE_PATH, DATE_DISALLOW_PAST_PATH, DATE_LABEL_PATH, Datetime, Default, Description, DynamicList, Errors, ExpressionField, ExpressionLanguageModule, FeelExpressionLanguage, FeelersTemplating, FieldFactory, Form, FormComponent, FormContext, FormField, FormFieldRegistry, FormFields, FormLayouter, FormRenderContext, Group, Html, IFrame, Image, Importer, Label, LocalExpressionContext, MINUTES_IN_DAY, MarkdownRenderer, MarkdownRendererModule, Numberfield, OPTIONS_SOURCES, OPTIONS_SOURCES_DEFAULTS, OPTIONS_SOURCES_LABELS, OPTIONS_SOURCES_PATHS, OPTIONS_SOURCE_DEFAULT, PathRegistry, Radio, RenderModule, RepeatRenderManager, RepeatRenderModule, SANDBOX_ATTRIBUTE, SECURITY_ATTRIBUTES_DEFINITIONS, Select, Separator, Spacer, TIME_INTERVAL_PATH, TIME_LABEL_PATH, TIME_SERIALISINGFORMAT_LABELS, TIME_SERIALISING_FORMATS, TIME_SERIALISING_FORMAT_PATH, TIME_USE24H_PATH, Table, Taglist, Text, Textarea, Textfield, ViewerCommands, ViewerCommandsModule, buildExpressionContext, clone, createForm, createFormContainer, createInjector, escapeHTML, formFields, generateIdForType, generateIndexForType, getAncestryList, getOptionsSource, getSchemaVariables, getScrollContainer, hasEqualValue, iconsByType, isRequired, pathParse, pathsEqual, runRecursively, sanitizeDateTimePickerValue, sanitizeHTML, sanitizeIFrameSource, sanitizeImageSource, sanitizeMultiSelectValue, sanitizeSingleSelectValue, schemaVersion, useExpressionEvaluation, useSingleLineTemplateEvaluation, useTemplateEvaluation, wrapCSSStyles };
|
|
8726
8854
|
//# sourceMappingURL=index.es.js.map
|