@ssa-ui-kit/core 2.4.0 → 2.6.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/dist/components/JsonSchemaForm/index.d.ts +12 -0
- package/dist/components/JsonSchemaForm/templates/ArrayFieldItemTemplate.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/ArrayFieldTemplate.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/BaseInputTemplate.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/FieldTemplate.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/IconButton.d.ts +8 -0
- package/dist/components/JsonSchemaForm/templates/ObjectFieldTemplate.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/SubmitButton.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/TitleFieldTemplate.d.ts +2 -0
- package/dist/components/JsonSchemaForm/templates/index.d.ts +4 -0
- package/dist/components/JsonSchemaForm/widgets/CheckboxWidget.d.ts +2 -0
- package/dist/components/JsonSchemaForm/widgets/CheckboxesWidget.d.ts +2 -0
- package/dist/components/JsonSchemaForm/widgets/PasswordWidget.d.ts +2 -0
- package/dist/components/JsonSchemaForm/widgets/RadioWidget.d.ts +2 -0
- package/dist/components/JsonSchemaForm/widgets/RangeWidget.d.ts +2 -0
- package/dist/components/JsonSchemaForm/widgets/SelectWidget.d.ts +2 -0
- package/dist/components/JsonSchemaForm/widgets/index.d.ts +4 -0
- package/dist/components/RadioGroup/types.d.ts +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/index.js +845 -2
- package/dist/index.js.map +1 -1
- package/package.json +8 -3
package/dist/index.js
CHANGED
|
@@ -111,6 +111,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
111
111
|
ImageItem: () => (/* reexport */ ImageItem),
|
|
112
112
|
Indicator: () => (/* reexport */ Indicator_Indicator),
|
|
113
113
|
Input: () => (/* reexport */ Input_Input),
|
|
114
|
+
JsonSchema: () => (/* reexport */ JsonSchemaForm_namespaceObject),
|
|
114
115
|
Label: () => (/* reexport */ Label_Label),
|
|
115
116
|
LargeTab: () => (/* reexport */ LargeTab_LargeTab),
|
|
116
117
|
Link: () => (/* reexport */ Link),
|
|
@@ -926,6 +927,20 @@ __webpack_require__.d(colorPalettes_namespaceObject, {
|
|
|
926
927
|
getBalancePalette: () => (getBalancePalette)
|
|
927
928
|
});
|
|
928
929
|
|
|
930
|
+
// NAMESPACE OBJECT: ./src/components/JsonSchemaForm/index.ts
|
|
931
|
+
var JsonSchemaForm_namespaceObject = {};
|
|
932
|
+
__webpack_require__.r(JsonSchemaForm_namespaceObject);
|
|
933
|
+
__webpack_require__.d(JsonSchemaForm_namespaceObject, {
|
|
934
|
+
Form: () => (JsonSchemaForm_Form),
|
|
935
|
+
Templates: () => (templates),
|
|
936
|
+
Theme: () => (Theme),
|
|
937
|
+
Widgets: () => (widgets),
|
|
938
|
+
generateForm: () => (generateForm),
|
|
939
|
+
generateTemplates: () => (generateTemplates),
|
|
940
|
+
generateTheme: () => (generateTheme),
|
|
941
|
+
generateWidgets: () => (generateWidgets)
|
|
942
|
+
});
|
|
943
|
+
|
|
929
944
|
;// ./src/themes/main.ts
|
|
930
945
|
const main = {
|
|
931
946
|
colors: {
|
|
@@ -4052,7 +4067,7 @@ function DropdownOptions_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tri
|
|
|
4052
4067
|
|
|
4053
4068
|
const DropdownOptionsBase = /*#__PURE__*/base_default()("ul", true ? {
|
|
4054
4069
|
target: "e1qg2z4z0"
|
|
4055
|
-
} : 0)("position:absolute;width:100%;list-style:none;margin:4px 0 0;padding:0;background:#fff;border-radius:8px;overflow:hidden auto;z-index:2;filter:", ({
|
|
4070
|
+
} : 0)("position:absolute;width:100%;min-width:max-content;list-style:none;margin:4px 0 0;padding:0;background:#fff;border-radius:8px;overflow:hidden auto;z-index:2;filter:", ({
|
|
4056
4071
|
theme
|
|
4057
4072
|
}) => `drop-shadow(-4px 4px 14px ${theme.colors.greyDarker14})`, ";backdrop-filter:", ({
|
|
4058
4073
|
theme
|
|
@@ -8594,10 +8609,11 @@ const CollapsibleNavBarPopover = ({
|
|
|
8594
8609
|
padding: 0,
|
|
8595
8610
|
background: navBarTheme === 'default' ? theme.colors.greyGraphite : '#F4F5F9',
|
|
8596
8611
|
borderRadius: 5,
|
|
8597
|
-
|
|
8612
|
+
minWidth: 85,
|
|
8598
8613
|
'& > a': {
|
|
8599
8614
|
color: navBarTheme === 'default' ? theme.colors.white : theme.colors.greyDarker80,
|
|
8600
8615
|
padding: 5,
|
|
8616
|
+
whiteSpace: 'nowrap',
|
|
8601
8617
|
fontSize: 12,
|
|
8602
8618
|
fontWeight: navBarTheme === 'default' ? 400 : 500,
|
|
8603
8619
|
'&.active': {
|
|
@@ -16865,6 +16881,831 @@ const WithVisibleUpToLG = (Component, styles) => {
|
|
|
16865
16881
|
};
|
|
16866
16882
|
;// ./src/components/WithVisibleUpToLG/index.ts
|
|
16867
16883
|
|
|
16884
|
+
;// external "@rjsf/core"
|
|
16885
|
+
const core_namespaceObject = require("@rjsf/core");
|
|
16886
|
+
;// external "@rjsf/utils"
|
|
16887
|
+
const external_rjsf_utils_namespaceObject = require("@rjsf/utils");
|
|
16888
|
+
;// ./src/components/JsonSchemaForm/templates/SubmitButton.tsx
|
|
16889
|
+
function SubmitButton_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
16890
|
+
|
|
16891
|
+
|
|
16892
|
+
|
|
16893
|
+
var SubmitButton_ref = true ? {
|
|
16894
|
+
name: "xda5ep",
|
|
16895
|
+
styles: "margin-top:12px"
|
|
16896
|
+
} : 0;
|
|
16897
|
+
const SubmitButton = ({
|
|
16898
|
+
uiSchema
|
|
16899
|
+
}) => {
|
|
16900
|
+
const {
|
|
16901
|
+
submitText,
|
|
16902
|
+
norender,
|
|
16903
|
+
props: submitButtonProps
|
|
16904
|
+
} = (0,external_rjsf_utils_namespaceObject.getSubmitButtonOptions)(uiSchema);
|
|
16905
|
+
if (norender) {
|
|
16906
|
+
return null;
|
|
16907
|
+
}
|
|
16908
|
+
return (0,jsx_runtime_namespaceObject.jsx)(Button_Button, {
|
|
16909
|
+
type: "submit",
|
|
16910
|
+
css: SubmitButton_ref,
|
|
16911
|
+
...submitButtonProps,
|
|
16912
|
+
"data-testid": "rjsf-submit-button",
|
|
16913
|
+
children: submitText
|
|
16914
|
+
});
|
|
16915
|
+
};
|
|
16916
|
+
;// ./src/components/JsonSchemaForm/templates/IconButton.tsx
|
|
16917
|
+
|
|
16918
|
+
|
|
16919
|
+
|
|
16920
|
+
|
|
16921
|
+
const IconButton = props => {
|
|
16922
|
+
const {
|
|
16923
|
+
iconType = 'button',
|
|
16924
|
+
icon,
|
|
16925
|
+
onClick,
|
|
16926
|
+
...otherProps
|
|
16927
|
+
} = props;
|
|
16928
|
+
return (0,jsx_runtime_namespaceObject.jsx)(Button_Button, {
|
|
16929
|
+
onClick: onClick,
|
|
16930
|
+
type: iconType,
|
|
16931
|
+
startIcon: icon,
|
|
16932
|
+
...otherProps
|
|
16933
|
+
});
|
|
16934
|
+
};
|
|
16935
|
+
const AddButton = props => {
|
|
16936
|
+
const {
|
|
16937
|
+
registry: {
|
|
16938
|
+
translateString
|
|
16939
|
+
}
|
|
16940
|
+
} = props;
|
|
16941
|
+
return (0,jsx_runtime_namespaceObject.jsx)(IconButton, {
|
|
16942
|
+
title: translateString(external_rjsf_utils_namespaceObject.TranslatableString.AddItemButton),
|
|
16943
|
+
...props,
|
|
16944
|
+
variant: "tertiary",
|
|
16945
|
+
icon: (0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, {
|
|
16946
|
+
name: "plus",
|
|
16947
|
+
size: 16
|
|
16948
|
+
})
|
|
16949
|
+
});
|
|
16950
|
+
};
|
|
16951
|
+
const RemoveButton = props => {
|
|
16952
|
+
const {
|
|
16953
|
+
registry: {
|
|
16954
|
+
translateString
|
|
16955
|
+
}
|
|
16956
|
+
} = props;
|
|
16957
|
+
return (0,jsx_runtime_namespaceObject.jsx)(IconButton, {
|
|
16958
|
+
title: translateString(external_rjsf_utils_namespaceObject.TranslatableString.RemoveButton),
|
|
16959
|
+
...props,
|
|
16960
|
+
variant: "tertiary",
|
|
16961
|
+
icon: (0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, {
|
|
16962
|
+
name: "cross",
|
|
16963
|
+
size: 14
|
|
16964
|
+
})
|
|
16965
|
+
});
|
|
16966
|
+
};
|
|
16967
|
+
const CopyButton = props => {
|
|
16968
|
+
const {
|
|
16969
|
+
registry: {
|
|
16970
|
+
translateString
|
|
16971
|
+
}
|
|
16972
|
+
} = props;
|
|
16973
|
+
return (0,jsx_runtime_namespaceObject.jsx)(IconButton, {
|
|
16974
|
+
title: translateString(external_rjsf_utils_namespaceObject.TranslatableString.CopyButton),
|
|
16975
|
+
...props,
|
|
16976
|
+
variant: "tertiary",
|
|
16977
|
+
icon: (0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, {
|
|
16978
|
+
name: "copy",
|
|
16979
|
+
size: 16
|
|
16980
|
+
})
|
|
16981
|
+
});
|
|
16982
|
+
};
|
|
16983
|
+
const MoveDownButton = props => {
|
|
16984
|
+
const {
|
|
16985
|
+
registry: {
|
|
16986
|
+
translateString
|
|
16987
|
+
}
|
|
16988
|
+
} = props;
|
|
16989
|
+
return (0,jsx_runtime_namespaceObject.jsx)(IconButton, {
|
|
16990
|
+
title: translateString(external_rjsf_utils_namespaceObject.TranslatableString.MoveDownButton),
|
|
16991
|
+
...props,
|
|
16992
|
+
variant: "tertiary",
|
|
16993
|
+
icon: (0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, {
|
|
16994
|
+
name: "arrow-down",
|
|
16995
|
+
size: 16
|
|
16996
|
+
})
|
|
16997
|
+
});
|
|
16998
|
+
};
|
|
16999
|
+
const MoveUpButton = props => {
|
|
17000
|
+
const {
|
|
17001
|
+
registry: {
|
|
17002
|
+
translateString
|
|
17003
|
+
}
|
|
17004
|
+
} = props;
|
|
17005
|
+
return (0,jsx_runtime_namespaceObject.jsx)(IconButton, {
|
|
17006
|
+
title: translateString(external_rjsf_utils_namespaceObject.TranslatableString.MoveUpButton),
|
|
17007
|
+
...props,
|
|
17008
|
+
variant: "tertiary",
|
|
17009
|
+
icon: (0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, {
|
|
17010
|
+
name: "arrow-up",
|
|
17011
|
+
size: 16
|
|
17012
|
+
})
|
|
17013
|
+
});
|
|
17014
|
+
};
|
|
17015
|
+
;// ./src/components/JsonSchemaForm/templates/BaseInputTemplate.tsx
|
|
17016
|
+
function BaseInputTemplate_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17017
|
+
|
|
17018
|
+
|
|
17019
|
+
|
|
17020
|
+
|
|
17021
|
+
var BaseInputTemplate_ref = true ? {
|
|
17022
|
+
name: "1ni3g9k",
|
|
17023
|
+
styles: "border:0 !important"
|
|
17024
|
+
} : 0;
|
|
17025
|
+
const BaseInputTemplate = props => {
|
|
17026
|
+
const {
|
|
17027
|
+
id,
|
|
17028
|
+
value,
|
|
17029
|
+
name,
|
|
17030
|
+
disabled,
|
|
17031
|
+
schema,
|
|
17032
|
+
type,
|
|
17033
|
+
options,
|
|
17034
|
+
placeholder,
|
|
17035
|
+
onChange,
|
|
17036
|
+
onChangeOverride,
|
|
17037
|
+
onBlur,
|
|
17038
|
+
onFocus
|
|
17039
|
+
} = props;
|
|
17040
|
+
const inputProps = (0,external_rjsf_utils_namespaceObject.getInputProps)(schema, type, options, false);
|
|
17041
|
+
const handleChange = onChangeOverride ? onChangeOverride : ({
|
|
17042
|
+
target
|
|
17043
|
+
}) => onChange(target.value === '' ? options.emptyValue : target.value);
|
|
17044
|
+
const handleBlur = ({
|
|
17045
|
+
target
|
|
17046
|
+
}) => onBlur(id, target && target.value);
|
|
17047
|
+
const handleFocus = ({
|
|
17048
|
+
target
|
|
17049
|
+
}) => onFocus(id, target && target.value);
|
|
17050
|
+
const register = fieldName => ({
|
|
17051
|
+
onBlur: handleBlur,
|
|
17052
|
+
onChange: handleChange,
|
|
17053
|
+
name: fieldName,
|
|
17054
|
+
ref: () => {}
|
|
17055
|
+
});
|
|
17056
|
+
return (0,jsx_runtime_namespaceObject.jsx)(FieldControl, {
|
|
17057
|
+
children: (0,jsx_runtime_namespaceObject.jsx)(Input_Input, {
|
|
17058
|
+
register: register,
|
|
17059
|
+
inputProps: {
|
|
17060
|
+
id,
|
|
17061
|
+
value: value ?? '',
|
|
17062
|
+
onFocus: handleFocus
|
|
17063
|
+
},
|
|
17064
|
+
disabled: disabled,
|
|
17065
|
+
name: name,
|
|
17066
|
+
placeholder: placeholder,
|
|
17067
|
+
css: BaseInputTemplate_ref,
|
|
17068
|
+
...inputProps
|
|
17069
|
+
})
|
|
17070
|
+
});
|
|
17071
|
+
};
|
|
17072
|
+
;// ./src/components/JsonSchemaForm/templates/ArrayFieldItemTemplate.tsx
|
|
17073
|
+
function ArrayFieldItemTemplate_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17074
|
+
|
|
17075
|
+
|
|
17076
|
+
var ArrayFieldItemTemplate_ref = true ? {
|
|
17077
|
+
name: "82a6rk",
|
|
17078
|
+
styles: "flex:1"
|
|
17079
|
+
} : 0;
|
|
17080
|
+
var ArrayFieldItemTemplate_ref2 = true ? {
|
|
17081
|
+
name: "490tlg",
|
|
17082
|
+
styles: "display:flex;gap:4px"
|
|
17083
|
+
} : 0;
|
|
17084
|
+
const ArrayFieldItemTemplate = props => {
|
|
17085
|
+
const {
|
|
17086
|
+
children,
|
|
17087
|
+
disabled,
|
|
17088
|
+
hasCopy,
|
|
17089
|
+
hasMoveDown,
|
|
17090
|
+
hasMoveUp,
|
|
17091
|
+
hasRemove,
|
|
17092
|
+
hasToolbar,
|
|
17093
|
+
index,
|
|
17094
|
+
onCopyIndexClick,
|
|
17095
|
+
onDropIndexClick,
|
|
17096
|
+
onReorderClick,
|
|
17097
|
+
readonly,
|
|
17098
|
+
registry,
|
|
17099
|
+
uiSchema
|
|
17100
|
+
} = props;
|
|
17101
|
+
const {
|
|
17102
|
+
CopyButton,
|
|
17103
|
+
MoveDownButton,
|
|
17104
|
+
MoveUpButton,
|
|
17105
|
+
RemoveButton
|
|
17106
|
+
} = registry.templates.ButtonTemplates;
|
|
17107
|
+
const {
|
|
17108
|
+
toolbarAlign = 'top'
|
|
17109
|
+
} = registry.formContext;
|
|
17110
|
+
const buttonCss = {
|
|
17111
|
+
width: '32px',
|
|
17112
|
+
height: '32px',
|
|
17113
|
+
justifyContent: 'center'
|
|
17114
|
+
};
|
|
17115
|
+
return (0,jsx_runtime_namespaceObject.jsxs)(Wrapper_Wrapper, {
|
|
17116
|
+
alignItems: toolbarAlign,
|
|
17117
|
+
style: {
|
|
17118
|
+
gap: 8
|
|
17119
|
+
},
|
|
17120
|
+
children: [(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17121
|
+
css: ArrayFieldItemTemplate_ref,
|
|
17122
|
+
children: children
|
|
17123
|
+
}), hasToolbar && (0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
17124
|
+
css: ArrayFieldItemTemplate_ref2,
|
|
17125
|
+
children: [(hasMoveUp || hasMoveDown) && (0,jsx_runtime_namespaceObject.jsx)(MoveUpButton, {
|
|
17126
|
+
disabled: disabled || readonly || !hasMoveUp,
|
|
17127
|
+
onClick: onReorderClick(index, index - 1),
|
|
17128
|
+
css: buttonCss,
|
|
17129
|
+
uiSchema: uiSchema,
|
|
17130
|
+
registry: registry
|
|
17131
|
+
}), (hasMoveUp || hasMoveDown) && (0,jsx_runtime_namespaceObject.jsx)(MoveDownButton, {
|
|
17132
|
+
disabled: disabled || readonly || !hasMoveDown,
|
|
17133
|
+
onClick: onReorderClick(index, index + 1),
|
|
17134
|
+
css: buttonCss,
|
|
17135
|
+
uiSchema: uiSchema,
|
|
17136
|
+
registry: registry
|
|
17137
|
+
}), hasCopy && (0,jsx_runtime_namespaceObject.jsx)(CopyButton, {
|
|
17138
|
+
disabled: disabled || readonly,
|
|
17139
|
+
onClick: onCopyIndexClick(index),
|
|
17140
|
+
css: buttonCss,
|
|
17141
|
+
uiSchema: uiSchema,
|
|
17142
|
+
registry: registry
|
|
17143
|
+
}), hasRemove && (0,jsx_runtime_namespaceObject.jsx)(RemoveButton, {
|
|
17144
|
+
disabled: disabled || readonly,
|
|
17145
|
+
onClick: onDropIndexClick(index),
|
|
17146
|
+
css: buttonCss,
|
|
17147
|
+
uiSchema: uiSchema,
|
|
17148
|
+
registry: registry
|
|
17149
|
+
})]
|
|
17150
|
+
})]
|
|
17151
|
+
});
|
|
17152
|
+
};
|
|
17153
|
+
;// ./src/components/JsonSchemaForm/templates/ArrayFieldTemplate.tsx
|
|
17154
|
+
function ArrayFieldTemplate_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17155
|
+
|
|
17156
|
+
|
|
17157
|
+
|
|
17158
|
+
var ArrayFieldTemplate_ref = true ? {
|
|
17159
|
+
name: "um7lt0",
|
|
17160
|
+
styles: "gap:8px;width:100%"
|
|
17161
|
+
} : 0;
|
|
17162
|
+
var ArrayFieldTemplate_ref2 = true ? {
|
|
17163
|
+
name: "rnnx2x",
|
|
17164
|
+
styles: "font-size:12px"
|
|
17165
|
+
} : 0;
|
|
17166
|
+
const ArrayFieldTemplate = props => {
|
|
17167
|
+
const {
|
|
17168
|
+
canAdd,
|
|
17169
|
+
disabled,
|
|
17170
|
+
idSchema,
|
|
17171
|
+
items,
|
|
17172
|
+
onAddClick,
|
|
17173
|
+
readonly,
|
|
17174
|
+
registry,
|
|
17175
|
+
required,
|
|
17176
|
+
schema,
|
|
17177
|
+
title,
|
|
17178
|
+
uiSchema
|
|
17179
|
+
} = props;
|
|
17180
|
+
const uiOptions = (0,external_rjsf_utils_namespaceObject.getUiOptions)(uiSchema);
|
|
17181
|
+
const ArrayFieldDescriptionTemplate = (0,external_rjsf_utils_namespaceObject.getTemplate)('ArrayFieldDescriptionTemplate', registry, uiOptions);
|
|
17182
|
+
const ArrayFieldItemTemplate = (0,external_rjsf_utils_namespaceObject.getTemplate)('ArrayFieldItemTemplate', registry, uiOptions);
|
|
17183
|
+
const ArrayFieldTitleTemplate = (0,external_rjsf_utils_namespaceObject.getTemplate)('ArrayFieldTitleTemplate', registry, uiOptions);
|
|
17184
|
+
const {
|
|
17185
|
+
ButtonTemplates: {
|
|
17186
|
+
AddButton
|
|
17187
|
+
}
|
|
17188
|
+
} = registry.templates;
|
|
17189
|
+
return (0,jsx_runtime_namespaceObject.jsxs)(Wrapper_Wrapper, {
|
|
17190
|
+
direction: "column",
|
|
17191
|
+
alignItems: "flex-start",
|
|
17192
|
+
css: ArrayFieldTemplate_ref,
|
|
17193
|
+
children: [(0,jsx_runtime_namespaceObject.jsx)(ArrayFieldTitleTemplate, {
|
|
17194
|
+
idSchema: idSchema,
|
|
17195
|
+
required: required,
|
|
17196
|
+
title: uiOptions.title || title,
|
|
17197
|
+
schema: schema,
|
|
17198
|
+
uiSchema: uiSchema,
|
|
17199
|
+
registry: registry
|
|
17200
|
+
}), (uiOptions.description || schema.description) && (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17201
|
+
css: ArrayFieldTemplate_ref2,
|
|
17202
|
+
children: (0,jsx_runtime_namespaceObject.jsx)(ArrayFieldDescriptionTemplate, {
|
|
17203
|
+
description: uiOptions.description || schema.description,
|
|
17204
|
+
idSchema: idSchema,
|
|
17205
|
+
schema: schema,
|
|
17206
|
+
uiSchema: uiSchema,
|
|
17207
|
+
registry: registry
|
|
17208
|
+
})
|
|
17209
|
+
}), items && items.map(({
|
|
17210
|
+
key,
|
|
17211
|
+
...itemProps
|
|
17212
|
+
}) => (0,jsx_runtime_namespaceObject.jsx)(ArrayFieldItemTemplate, {
|
|
17213
|
+
...itemProps
|
|
17214
|
+
}, key)), canAdd && (0,jsx_runtime_namespaceObject.jsx)(AddButton, {
|
|
17215
|
+
disabled: disabled || readonly,
|
|
17216
|
+
onClick: onAddClick,
|
|
17217
|
+
uiSchema: uiSchema,
|
|
17218
|
+
registry: registry
|
|
17219
|
+
})]
|
|
17220
|
+
});
|
|
17221
|
+
};
|
|
17222
|
+
;// ./src/components/JsonSchemaForm/templates/TitleFieldTemplate.tsx
|
|
17223
|
+
|
|
17224
|
+
function TitleFieldTemplate_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17225
|
+
var TitleFieldTemplate_ref = true ? {
|
|
17226
|
+
name: "16ceglb",
|
|
17227
|
+
styles: "font-weight:600"
|
|
17228
|
+
} : 0;
|
|
17229
|
+
const TitleFieldTemplate = ({
|
|
17230
|
+
id,
|
|
17231
|
+
title
|
|
17232
|
+
}) => {
|
|
17233
|
+
return title ? (0,jsx_runtime_namespaceObject.jsx)("label", {
|
|
17234
|
+
htmlFor: id,
|
|
17235
|
+
title: typeof title === 'string' ? title : '',
|
|
17236
|
+
css: TitleFieldTemplate_ref,
|
|
17237
|
+
children: title
|
|
17238
|
+
}) : null;
|
|
17239
|
+
};
|
|
17240
|
+
;// ./src/components/JsonSchemaForm/templates/ObjectFieldTemplate.tsx
|
|
17241
|
+
function ObjectFieldTemplate_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17242
|
+
|
|
17243
|
+
|
|
17244
|
+
|
|
17245
|
+
var ObjectFieldTemplate_ref = true ? {
|
|
17246
|
+
name: "rnnx2x",
|
|
17247
|
+
styles: "font-size:12px"
|
|
17248
|
+
} : 0;
|
|
17249
|
+
const ObjectFieldTemplate = props => {
|
|
17250
|
+
const {
|
|
17251
|
+
disabled,
|
|
17252
|
+
description,
|
|
17253
|
+
idSchema,
|
|
17254
|
+
onAddClick,
|
|
17255
|
+
readonly,
|
|
17256
|
+
registry,
|
|
17257
|
+
required,
|
|
17258
|
+
schema,
|
|
17259
|
+
title,
|
|
17260
|
+
uiSchema,
|
|
17261
|
+
properties,
|
|
17262
|
+
formData
|
|
17263
|
+
} = props;
|
|
17264
|
+
const uiOptions = (0,external_rjsf_utils_namespaceObject.getUiOptions)(uiSchema);
|
|
17265
|
+
const TitleFieldTemplate = (0,external_rjsf_utils_namespaceObject.getTemplate)('TitleFieldTemplate', registry, uiOptions);
|
|
17266
|
+
const DescriptionFieldTemplate = (0,external_rjsf_utils_namespaceObject.getTemplate)('DescriptionFieldTemplate', registry, uiOptions);
|
|
17267
|
+
const {
|
|
17268
|
+
ButtonTemplates: {
|
|
17269
|
+
AddButton
|
|
17270
|
+
}
|
|
17271
|
+
} = registry.templates;
|
|
17272
|
+
return (0,jsx_runtime_namespaceObject.jsxs)(Wrapper_Wrapper, {
|
|
17273
|
+
id: idSchema.$id,
|
|
17274
|
+
direction: "column",
|
|
17275
|
+
alignItems: "stretch",
|
|
17276
|
+
className: "form-group",
|
|
17277
|
+
children: [(0,jsx_runtime_namespaceObject.jsx)(TitleFieldTemplate, {
|
|
17278
|
+
id: (0,external_rjsf_utils_namespaceObject.titleId)(idSchema),
|
|
17279
|
+
title: title,
|
|
17280
|
+
required: required,
|
|
17281
|
+
schema: schema,
|
|
17282
|
+
uiSchema: uiSchema,
|
|
17283
|
+
registry: registry
|
|
17284
|
+
}), description && (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17285
|
+
css: ObjectFieldTemplate_ref,
|
|
17286
|
+
children: (0,jsx_runtime_namespaceObject.jsx)(DescriptionFieldTemplate, {
|
|
17287
|
+
id: (0,external_rjsf_utils_namespaceObject.descriptionId)(idSchema),
|
|
17288
|
+
description: description,
|
|
17289
|
+
schema: schema,
|
|
17290
|
+
uiSchema: uiSchema,
|
|
17291
|
+
registry: registry
|
|
17292
|
+
})
|
|
17293
|
+
}), properties.filter(e => !e.hidden).map(element => element.content), (0,external_rjsf_utils_namespaceObject.canExpand)(schema, uiSchema, formData) && (0,jsx_runtime_namespaceObject.jsx)(AddButton, {
|
|
17294
|
+
disabled: disabled || readonly,
|
|
17295
|
+
onClick: onAddClick(schema),
|
|
17296
|
+
uiSchema: uiSchema,
|
|
17297
|
+
registry: registry
|
|
17298
|
+
})]
|
|
17299
|
+
});
|
|
17300
|
+
};
|
|
17301
|
+
;// ./src/components/JsonSchemaForm/templates/FieldTemplate.tsx
|
|
17302
|
+
|
|
17303
|
+
|
|
17304
|
+
|
|
17305
|
+
const FieldTemplate = props => {
|
|
17306
|
+
const {
|
|
17307
|
+
id,
|
|
17308
|
+
classNames,
|
|
17309
|
+
style,
|
|
17310
|
+
label,
|
|
17311
|
+
displayLabel,
|
|
17312
|
+
disabled,
|
|
17313
|
+
rawErrors,
|
|
17314
|
+
registry,
|
|
17315
|
+
uiSchema,
|
|
17316
|
+
children,
|
|
17317
|
+
readonly,
|
|
17318
|
+
required,
|
|
17319
|
+
schema,
|
|
17320
|
+
rawHelp,
|
|
17321
|
+
help,
|
|
17322
|
+
onDropPropertyClick,
|
|
17323
|
+
onKeyChange
|
|
17324
|
+
} = props;
|
|
17325
|
+
const uiOptions = (0,external_rjsf_utils_namespaceObject.getUiOptions)(uiSchema);
|
|
17326
|
+
const WrapIfAdditionalTemplate = (0,external_rjsf_utils_namespaceObject.getTemplate)('WrapIfAdditionalTemplate', registry, uiOptions);
|
|
17327
|
+
const status = rawErrors && rawErrors.length > 0 ? 'error' : 'basic';
|
|
17328
|
+
return (0,jsx_runtime_namespaceObject.jsx)(WrapIfAdditionalTemplate, {
|
|
17329
|
+
classNames: classNames,
|
|
17330
|
+
style: style,
|
|
17331
|
+
disabled: disabled,
|
|
17332
|
+
id: id,
|
|
17333
|
+
label: label,
|
|
17334
|
+
onDropPropertyClick: onDropPropertyClick,
|
|
17335
|
+
onKeyChange: onKeyChange,
|
|
17336
|
+
readonly: readonly,
|
|
17337
|
+
required: required,
|
|
17338
|
+
schema: schema,
|
|
17339
|
+
uiSchema: uiSchema,
|
|
17340
|
+
registry: registry,
|
|
17341
|
+
children: (0,jsx_runtime_namespaceObject.jsxs)(FieldRoot, {
|
|
17342
|
+
status: status,
|
|
17343
|
+
disabled: disabled,
|
|
17344
|
+
asChild: true,
|
|
17345
|
+
children: [displayLabel && (0,jsx_runtime_namespaceObject.jsx)(FieldLabel, {
|
|
17346
|
+
htmlFor: id,
|
|
17347
|
+
children: label
|
|
17348
|
+
}), children, (0,jsx_runtime_namespaceObject.jsx)(FieldError, {
|
|
17349
|
+
children: rawErrors?.join(', ')
|
|
17350
|
+
}), rawHelp && (0,jsx_runtime_namespaceObject.jsx)(FieldDescription, {
|
|
17351
|
+
children: help
|
|
17352
|
+
})]
|
|
17353
|
+
})
|
|
17354
|
+
});
|
|
17355
|
+
};
|
|
17356
|
+
;// ./src/components/JsonSchemaForm/templates/index.ts
|
|
17357
|
+
|
|
17358
|
+
|
|
17359
|
+
|
|
17360
|
+
|
|
17361
|
+
|
|
17362
|
+
|
|
17363
|
+
|
|
17364
|
+
|
|
17365
|
+
function generateTemplates() {
|
|
17366
|
+
return {
|
|
17367
|
+
ArrayFieldItemTemplate: ArrayFieldItemTemplate,
|
|
17368
|
+
ArrayFieldTemplate: ArrayFieldTemplate,
|
|
17369
|
+
BaseInputTemplate: BaseInputTemplate,
|
|
17370
|
+
ButtonTemplates: {
|
|
17371
|
+
SubmitButton: SubmitButton,
|
|
17372
|
+
AddButton: AddButton,
|
|
17373
|
+
RemoveButton: RemoveButton,
|
|
17374
|
+
CopyButton: CopyButton,
|
|
17375
|
+
MoveDownButton: MoveDownButton,
|
|
17376
|
+
MoveUpButton: MoveUpButton
|
|
17377
|
+
},
|
|
17378
|
+
TitleFieldTemplate: TitleFieldTemplate,
|
|
17379
|
+
ObjectFieldTemplate: ObjectFieldTemplate,
|
|
17380
|
+
FieldTemplate: FieldTemplate
|
|
17381
|
+
};
|
|
17382
|
+
}
|
|
17383
|
+
/* harmony default export */ const templates = (generateTemplates());
|
|
17384
|
+
;// ./src/components/JsonSchemaForm/widgets/CheckboxWidget.tsx
|
|
17385
|
+
function CheckboxWidget_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17386
|
+
|
|
17387
|
+
|
|
17388
|
+
|
|
17389
|
+
var CheckboxWidget_ref = true ? {
|
|
17390
|
+
name: "1ykowef",
|
|
17391
|
+
styles: "margin-bottom:0"
|
|
17392
|
+
} : 0;
|
|
17393
|
+
const CheckboxWidget = props => {
|
|
17394
|
+
const {
|
|
17395
|
+
id,
|
|
17396
|
+
value,
|
|
17397
|
+
label,
|
|
17398
|
+
hideLabel,
|
|
17399
|
+
onChange
|
|
17400
|
+
} = props;
|
|
17401
|
+
return (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17402
|
+
children: (0,jsx_runtime_namespaceObject.jsx)(Checkbox_Checkbox, {
|
|
17403
|
+
id: id,
|
|
17404
|
+
initialState: value,
|
|
17405
|
+
onChange: onChange,
|
|
17406
|
+
text: (0,external_rjsf_utils_namespaceObject.labelValue)(label, hideLabel, ''),
|
|
17407
|
+
css: CheckboxWidget_ref
|
|
17408
|
+
})
|
|
17409
|
+
});
|
|
17410
|
+
};
|
|
17411
|
+
;// ./src/components/JsonSchemaForm/widgets/CheckboxesWidget.tsx
|
|
17412
|
+
|
|
17413
|
+
|
|
17414
|
+
|
|
17415
|
+
|
|
17416
|
+
const CheckboxesWidget = props => {
|
|
17417
|
+
const {
|
|
17418
|
+
id,
|
|
17419
|
+
options,
|
|
17420
|
+
value,
|
|
17421
|
+
readonly,
|
|
17422
|
+
disabled,
|
|
17423
|
+
onChange,
|
|
17424
|
+
onBlur,
|
|
17425
|
+
onFocus
|
|
17426
|
+
} = props;
|
|
17427
|
+
const {
|
|
17428
|
+
enumOptions = [],
|
|
17429
|
+
enumDisabled = [],
|
|
17430
|
+
inline = false,
|
|
17431
|
+
emptyValue
|
|
17432
|
+
} = options;
|
|
17433
|
+
const selectedIndexes = (0,external_rjsf_utils_namespaceObject.enumOptionsIndexForValue)(value, enumOptions, true);
|
|
17434
|
+
const [selectedOptions, setSelectedOptions] = (0,external_react_namespaceObject.useState)(selectedIndexes);
|
|
17435
|
+
const handleChange = nextValue => {
|
|
17436
|
+
const newSelectedOptions = [...selectedOptions];
|
|
17437
|
+
const index = newSelectedOptions.indexOf(String(nextValue));
|
|
17438
|
+
if (index > -1) {
|
|
17439
|
+
newSelectedOptions.splice(index, 1);
|
|
17440
|
+
} else {
|
|
17441
|
+
newSelectedOptions.push(String(nextValue));
|
|
17442
|
+
}
|
|
17443
|
+
setSelectedOptions(newSelectedOptions);
|
|
17444
|
+
onChange((0,external_rjsf_utils_namespaceObject.enumOptionsValueForIndex)(newSelectedOptions, enumOptions, emptyValue));
|
|
17445
|
+
};
|
|
17446
|
+
const handleBlur = ({
|
|
17447
|
+
target
|
|
17448
|
+
}) => onBlur(id, (0,external_rjsf_utils_namespaceObject.enumOptionsValueForIndex)(target.value, enumOptions, emptyValue));
|
|
17449
|
+
const handleFocus = ({
|
|
17450
|
+
target
|
|
17451
|
+
}) => onFocus(id, (0,external_rjsf_utils_namespaceObject.enumOptionsValueForIndex)(target.value, enumOptions, emptyValue));
|
|
17452
|
+
const divProps = {
|
|
17453
|
+
id,
|
|
17454
|
+
onBlur: !readonly ? handleBlur : undefined,
|
|
17455
|
+
onFocus: !readonly ? handleFocus : undefined
|
|
17456
|
+
};
|
|
17457
|
+
return (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17458
|
+
...divProps,
|
|
17459
|
+
children: Array.isArray(enumOptions) && enumOptions.map((option, i) => (0,jsx_runtime_namespaceObject.jsxs)(external_react_namespaceObject.Fragment, {
|
|
17460
|
+
children: [(0,jsx_runtime_namespaceObject.jsx)(Checkbox_Checkbox, {
|
|
17461
|
+
id: (0,external_rjsf_utils_namespaceObject.optionId)(id, i),
|
|
17462
|
+
onChange: () => handleChange(i),
|
|
17463
|
+
isDisabled: disabled || Array.isArray(enumDisabled) && enumDisabled.indexOf(option.value) !== -1,
|
|
17464
|
+
initialState: selectedOptions.includes(String(i)),
|
|
17465
|
+
name: id,
|
|
17466
|
+
text: option.label
|
|
17467
|
+
}), !inline && (0,jsx_runtime_namespaceObject.jsx)("br", {})]
|
|
17468
|
+
}, i))
|
|
17469
|
+
});
|
|
17470
|
+
};
|
|
17471
|
+
;// ./src/components/JsonSchemaForm/widgets/RadioWidget.tsx
|
|
17472
|
+
|
|
17473
|
+
function RadioWidget_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17474
|
+
|
|
17475
|
+
|
|
17476
|
+
|
|
17477
|
+
|
|
17478
|
+
|
|
17479
|
+
const RadioWidget = props => {
|
|
17480
|
+
const {
|
|
17481
|
+
id,
|
|
17482
|
+
name,
|
|
17483
|
+
disabled,
|
|
17484
|
+
options,
|
|
17485
|
+
value,
|
|
17486
|
+
required,
|
|
17487
|
+
onChange
|
|
17488
|
+
} = props;
|
|
17489
|
+
const {
|
|
17490
|
+
enumOptions = [],
|
|
17491
|
+
enumDisabled = [],
|
|
17492
|
+
inline = false,
|
|
17493
|
+
emptyValue
|
|
17494
|
+
} = options;
|
|
17495
|
+
const selectedIndex = (0,external_rjsf_utils_namespaceObject.enumOptionsIndexForValue)(value, enumOptions);
|
|
17496
|
+
const handleChange = nextValue => onChange((0,external_rjsf_utils_namespaceObject.enumOptionsValueForIndex)(nextValue, enumOptions, emptyValue));
|
|
17497
|
+
return (0,jsx_runtime_namespaceObject.jsx)(RadioGroup_RadioGroup, {
|
|
17498
|
+
name: name,
|
|
17499
|
+
onChange: handleChange,
|
|
17500
|
+
initialState: selectedIndex,
|
|
17501
|
+
isRequired: required,
|
|
17502
|
+
css: /*#__PURE__*/(0,react_namespaceObject.css)({
|
|
17503
|
+
[`> label`]: {
|
|
17504
|
+
display: inline ? 'inline-flex' : 'flex'
|
|
17505
|
+
}
|
|
17506
|
+
}, true ? "" : 0, true ? "" : 0),
|
|
17507
|
+
children: Array.isArray(enumOptions) ? enumOptions.map((option, i) => (0,jsx_runtime_namespaceObject.jsx)(Radio_Radio, {
|
|
17508
|
+
id: (0,external_rjsf_utils_namespaceObject.optionId)(id, i),
|
|
17509
|
+
name: id,
|
|
17510
|
+
isDisabled: disabled || Array.isArray(enumDisabled) && enumDisabled.indexOf(option.value) !== -1,
|
|
17511
|
+
text: option.label,
|
|
17512
|
+
className: /*#__PURE__*/(0,css_namespaceObject.css)( true ? {
|
|
17513
|
+
name: "1ykowef",
|
|
17514
|
+
styles: "margin-bottom:0"
|
|
17515
|
+
} : 0),
|
|
17516
|
+
value: String(i)
|
|
17517
|
+
}, i)) : undefined
|
|
17518
|
+
});
|
|
17519
|
+
};
|
|
17520
|
+
;// ./src/components/JsonSchemaForm/widgets/SelectWidget.tsx
|
|
17521
|
+
|
|
17522
|
+
|
|
17523
|
+
|
|
17524
|
+
const SelectWidget = props => {
|
|
17525
|
+
const {
|
|
17526
|
+
disabled,
|
|
17527
|
+
options,
|
|
17528
|
+
placeholder,
|
|
17529
|
+
onChange,
|
|
17530
|
+
onChangeOverride,
|
|
17531
|
+
value
|
|
17532
|
+
} = props;
|
|
17533
|
+
const {
|
|
17534
|
+
enumOptions = [],
|
|
17535
|
+
enumDisabled = []
|
|
17536
|
+
} = options;
|
|
17537
|
+
const selectedIndex = (0,external_rjsf_utils_namespaceObject.enumOptionsIndexForValue)(value, enumOptions);
|
|
17538
|
+
const handleChange = onChangeOverride ? onChangeOverride : ({
|
|
17539
|
+
value
|
|
17540
|
+
}) => onChange((0,external_rjsf_utils_namespaceObject.enumOptionsValueForIndex)(value, enumOptions));
|
|
17541
|
+
return (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17542
|
+
children: (0,jsx_runtime_namespaceObject.jsx)(Dropdown_Dropdown, {
|
|
17543
|
+
isDisabled: disabled,
|
|
17544
|
+
onChange: handleChange,
|
|
17545
|
+
placeholder: placeholder,
|
|
17546
|
+
selectedItem: selectedIndex ? {
|
|
17547
|
+
value: selectedIndex,
|
|
17548
|
+
label: enumOptions[Number(selectedIndex)].label
|
|
17549
|
+
} : undefined,
|
|
17550
|
+
children: Array.isArray(enumOptions) && enumOptions.map((option, i) => (0,jsx_runtime_namespaceObject.jsx)(DropdownOption_DropdownOption, {
|
|
17551
|
+
value: String(i),
|
|
17552
|
+
label: option.label,
|
|
17553
|
+
isDisabled: disabled || Array.isArray(enumDisabled) && enumDisabled.indexOf(option.value) !== -1
|
|
17554
|
+
}, i))
|
|
17555
|
+
})
|
|
17556
|
+
});
|
|
17557
|
+
};
|
|
17558
|
+
;// ./src/components/JsonSchemaForm/widgets/PasswordWidget.tsx
|
|
17559
|
+
function PasswordWidget_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17560
|
+
|
|
17561
|
+
|
|
17562
|
+
|
|
17563
|
+
|
|
17564
|
+
|
|
17565
|
+
|
|
17566
|
+
var PasswordWidget_ref = true ? {
|
|
17567
|
+
name: "1ni3g9k",
|
|
17568
|
+
styles: "border:0 !important"
|
|
17569
|
+
} : 0;
|
|
17570
|
+
const PasswordWidget = props => {
|
|
17571
|
+
const {
|
|
17572
|
+
id,
|
|
17573
|
+
value,
|
|
17574
|
+
name,
|
|
17575
|
+
disabled,
|
|
17576
|
+
options,
|
|
17577
|
+
placeholder,
|
|
17578
|
+
onChange,
|
|
17579
|
+
onChangeOverride,
|
|
17580
|
+
onBlur,
|
|
17581
|
+
onFocus
|
|
17582
|
+
} = props;
|
|
17583
|
+
const [visible, toggleVisibility] = (0,hooks_namespaceObject.useToggle)();
|
|
17584
|
+
const handleChange = onChangeOverride ? onChangeOverride : ({
|
|
17585
|
+
target
|
|
17586
|
+
}) => onChange(target.value === '' ? options.emptyValue : target.value);
|
|
17587
|
+
const handleBlur = ({
|
|
17588
|
+
target
|
|
17589
|
+
}) => onBlur(id, target && target.value);
|
|
17590
|
+
const handleFocus = ({
|
|
17591
|
+
target
|
|
17592
|
+
}) => onFocus(id, target && target.value);
|
|
17593
|
+
const register = fieldName => ({
|
|
17594
|
+
onBlur: handleBlur,
|
|
17595
|
+
onChange: handleChange,
|
|
17596
|
+
name: fieldName,
|
|
17597
|
+
ref: () => {}
|
|
17598
|
+
});
|
|
17599
|
+
return (0,jsx_runtime_namespaceObject.jsx)(FieldControl, {
|
|
17600
|
+
children: (0,jsx_runtime_namespaceObject.jsx)(Input_Input, {
|
|
17601
|
+
register: register,
|
|
17602
|
+
inputProps: {
|
|
17603
|
+
id,
|
|
17604
|
+
value: value ?? '',
|
|
17605
|
+
onFocus: handleFocus
|
|
17606
|
+
},
|
|
17607
|
+
disabled: disabled,
|
|
17608
|
+
name: name,
|
|
17609
|
+
placeholder: placeholder,
|
|
17610
|
+
css: PasswordWidget_ref,
|
|
17611
|
+
type: visible ? 'text' : 'password',
|
|
17612
|
+
endElement: (0,jsx_runtime_namespaceObject.jsx)(Button_Button, {
|
|
17613
|
+
variant: "tertiary",
|
|
17614
|
+
endIcon: (0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, {
|
|
17615
|
+
name: visible ? 'invisible' : 'visible',
|
|
17616
|
+
size: 16
|
|
17617
|
+
}),
|
|
17618
|
+
onClick: () => toggleVisibility()
|
|
17619
|
+
})
|
|
17620
|
+
})
|
|
17621
|
+
});
|
|
17622
|
+
};
|
|
17623
|
+
;// ./src/components/JsonSchemaForm/widgets/RangeWidget.tsx
|
|
17624
|
+
function RangeWidget_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17625
|
+
|
|
17626
|
+
|
|
17627
|
+
var RangeWidget_ref = true ? {
|
|
17628
|
+
name: "1d3w5wq",
|
|
17629
|
+
styles: "width:100%"
|
|
17630
|
+
} : 0;
|
|
17631
|
+
const RangeWidget = props => {
|
|
17632
|
+
const {
|
|
17633
|
+
id,
|
|
17634
|
+
disabled,
|
|
17635
|
+
options,
|
|
17636
|
+
onChangeOverride,
|
|
17637
|
+
value,
|
|
17638
|
+
schema,
|
|
17639
|
+
onChange,
|
|
17640
|
+
onBlur,
|
|
17641
|
+
onFocus
|
|
17642
|
+
} = props;
|
|
17643
|
+
const {
|
|
17644
|
+
min,
|
|
17645
|
+
max,
|
|
17646
|
+
step
|
|
17647
|
+
} = (0,external_rjsf_utils_namespaceObject.rangeSpec)(schema);
|
|
17648
|
+
const emptyValue = options.emptyValue || '';
|
|
17649
|
+
const handleChange = nextValue => onChangeOverride ? onChangeOverride : onChange(nextValue === '' ? emptyValue : nextValue);
|
|
17650
|
+
const handleBlur = () => onBlur(id, value);
|
|
17651
|
+
const handleFocus = () => onFocus(id, value);
|
|
17652
|
+
return (0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
17653
|
+
children: (0,jsx_runtime_namespaceObject.jsx)("input", {
|
|
17654
|
+
id: id,
|
|
17655
|
+
type: "range",
|
|
17656
|
+
min: min,
|
|
17657
|
+
max: max,
|
|
17658
|
+
step: step,
|
|
17659
|
+
disabled: disabled,
|
|
17660
|
+
onChange: e => handleChange(e.target.value),
|
|
17661
|
+
onBlur: handleBlur,
|
|
17662
|
+
onFocus: handleFocus,
|
|
17663
|
+
css: RangeWidget_ref
|
|
17664
|
+
})
|
|
17665
|
+
});
|
|
17666
|
+
};
|
|
17667
|
+
;// ./src/components/JsonSchemaForm/widgets/index.ts
|
|
17668
|
+
|
|
17669
|
+
|
|
17670
|
+
|
|
17671
|
+
|
|
17672
|
+
|
|
17673
|
+
|
|
17674
|
+
function generateWidgets() {
|
|
17675
|
+
return {
|
|
17676
|
+
CheckboxWidget: CheckboxWidget,
|
|
17677
|
+
CheckboxesWidget: CheckboxesWidget,
|
|
17678
|
+
RadioWidget: RadioWidget,
|
|
17679
|
+
PasswordWidget: PasswordWidget,
|
|
17680
|
+
SelectWidget: SelectWidget,
|
|
17681
|
+
RangeWidget: RangeWidget
|
|
17682
|
+
};
|
|
17683
|
+
}
|
|
17684
|
+
/* harmony default export */ const widgets = (generateWidgets());
|
|
17685
|
+
;// ./src/components/JsonSchemaForm/index.ts
|
|
17686
|
+
|
|
17687
|
+
function JsonSchemaForm_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
17688
|
+
|
|
17689
|
+
|
|
17690
|
+
|
|
17691
|
+
function generateTheme() {
|
|
17692
|
+
return {
|
|
17693
|
+
templates: generateTemplates(),
|
|
17694
|
+
widgets: generateWidgets()
|
|
17695
|
+
};
|
|
17696
|
+
}
|
|
17697
|
+
const Theme = generateTheme();
|
|
17698
|
+
function generateForm() {
|
|
17699
|
+
return (0,core_namespaceObject.withTheme)(generateTheme());
|
|
17700
|
+
}
|
|
17701
|
+
const UnstyledForm = generateForm();
|
|
17702
|
+
const JsonSchemaForm_Form = /*#__PURE__*/base_default()(UnstyledForm, true ? {
|
|
17703
|
+
target: "e1yfg9n10"
|
|
17704
|
+
} : 0)( true ? {
|
|
17705
|
+
name: "173skgr",
|
|
17706
|
+
styles: ".form-group{margin-bottom:16px;}.form-group:last-child{margin-bottom:0;}"
|
|
17707
|
+
} : 0);
|
|
17708
|
+
|
|
16868
17709
|
;// ./src/components/index.ts
|
|
16869
17710
|
|
|
16870
17711
|
|
|
@@ -16975,6 +17816,8 @@ const WithVisibleUpToLG = (Component, styles) => {
|
|
|
16975
17816
|
|
|
16976
17817
|
|
|
16977
17818
|
|
|
17819
|
+
|
|
17820
|
+
|
|
16978
17821
|
|
|
16979
17822
|
|
|
16980
17823
|
|