@bigbinary/neeto-form-frontend 4.2.2 → 4.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/javascript/src/translations/en.json +1 -0
- package/dist/BuildForm.js +36 -14
- package/dist/BuildForm.js.map +1 -1
- package/dist/cjs/BuildForm.js +36 -14
- package/dist/cjs/BuildForm.js.map +1 -1
- package/dist/main.css +1 -1
- package/dist/main.css.map +1 -1
- package/package.json +8 -8
|
@@ -140,6 +140,7 @@
|
|
|
140
140
|
"hideQuestionHelpDescription": "When enabled, this question will not be visible in the created form. It can be used to track \"reference ids\" and UTM parameters.",
|
|
141
141
|
"responseVisibleOnlyToHostHelpDescription": "When enabled, the response to this question will only be visible to the host",
|
|
142
142
|
"readOnlyHelpDescription": "When enabled, the client will only be able to see the answer of this question, but will not be able to change the answer of this question. Since you are marking this question as \"read-only\" you should pre-fill the question with an answer.",
|
|
143
|
+
"fitImagesHelpDescription": "When enabled, images zoom to fill the entire space (some edges may get cut off). When disabled, the complete image is shown (may have empty space around it).",
|
|
143
144
|
"verifyHuman": "Verify that you are a human",
|
|
144
145
|
"pictureChoiceSettings": "Picture choice settings",
|
|
145
146
|
"addPicturesToOptions": "Add pictures to options",
|
package/dist/BuildForm.js
CHANGED
|
@@ -1883,6 +1883,7 @@ var Options = function Options(_ref) {
|
|
|
1883
1883
|
}, shallow),
|
|
1884
1884
|
selectedLanguage = _useBuildFormStore.selectedLanguage,
|
|
1885
1885
|
isPictureChoiceEnabled = _useBuildFormStore.isPictureChoiceEnabled;
|
|
1886
|
+
var bulkAddHelpDocUrl = useHelpDoc("bulkAddOptions");
|
|
1886
1887
|
var _useFormikContext = useFormikContext(),
|
|
1887
1888
|
values = _useFormikContext.values,
|
|
1888
1889
|
setFieldValue = _useFormikContext.setFieldValue;
|
|
@@ -1917,19 +1918,31 @@ var Options = function Options(_ref) {
|
|
|
1917
1918
|
className: "mb-2 block"
|
|
1918
1919
|
}, optionLabelProps), {}, {
|
|
1919
1920
|
children: t("neetoForm.questions.common.questionFields.field.options")
|
|
1920
|
-
})), /*#__PURE__*/jsx(
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1921
|
+
})), /*#__PURE__*/jsx("div", {
|
|
1922
|
+
className: classnames(["neeto-form-engine-fields-wrapper", {
|
|
1923
|
+
"neeto-form-engine-fields-wrapper--fit-image": values.shouldFitImages
|
|
1924
|
+
}]),
|
|
1925
|
+
style: {
|
|
1926
|
+
"--neeto-form-engine-picture-choice-image-height": "".concat(values.imageHeight, "px")
|
|
1927
|
+
},
|
|
1928
|
+
children: /*#__PURE__*/jsx(OptionFields, {
|
|
1929
|
+
isPictureChoice: isPictureChoice,
|
|
1930
|
+
name: name,
|
|
1931
|
+
shouldDestroy: true,
|
|
1932
|
+
bulkActionProps: {
|
|
1933
|
+
enabled: true,
|
|
1934
|
+
bulkAddHelpDocUrl: bulkAddHelpDocUrl
|
|
1935
|
+
},
|
|
1936
|
+
destroyFlagName: "_destroy",
|
|
1937
|
+
disabled: isManageOptionDisabled,
|
|
1938
|
+
draggable: !isManageOptionDisabled,
|
|
1939
|
+
isAddOptionEnabled: !isAddOptionDisabled,
|
|
1940
|
+
isDeleteOptionEnabled: !isRemoveOptionDisabled,
|
|
1941
|
+
isNewItemsPrefilled: isDefaultLanguage(selectedLanguage),
|
|
1942
|
+
minOptions: MINIMUM_OPTIONS,
|
|
1943
|
+
shouldResetEmptyOptionOnBlur: false,
|
|
1944
|
+
onChange: setOptionsAttributes
|
|
1945
|
+
})
|
|
1933
1946
|
})]
|
|
1934
1947
|
}), !isDropdown && isPictureChoiceEnabled && /*#__PURE__*/jsxs(Block, {
|
|
1935
1948
|
title: t("neetoForm.questions.common.questionFields.field.pictureChoiceSettings"),
|
|
@@ -1939,7 +1952,16 @@ var Options = function Options(_ref) {
|
|
|
1939
1952
|
}), isPictureChoice && /*#__PURE__*/jsxs(Fragment, {
|
|
1940
1953
|
children: [/*#__PURE__*/jsx(Switch, {
|
|
1941
1954
|
name: "shouldFitImages",
|
|
1942
|
-
label: t("neetoForm.questions.common.questionFields.field.fitImages")
|
|
1955
|
+
label: t("neetoForm.questions.common.questionFields.field.fitImages"),
|
|
1956
|
+
labelProps: {
|
|
1957
|
+
helpIconProps: {
|
|
1958
|
+
"data-testid": "fit-images-help-popover-button",
|
|
1959
|
+
popoverProps: {
|
|
1960
|
+
position: "top",
|
|
1961
|
+
description: t("neetoForm.questions.common.questionFields.field.fitImagesHelpDescription")
|
|
1962
|
+
}
|
|
1963
|
+
}
|
|
1964
|
+
}
|
|
1943
1965
|
}), /*#__PURE__*/jsxs("div", {
|
|
1944
1966
|
className: "mt-4",
|
|
1945
1967
|
children: [/*#__PURE__*/jsx(Typography, {
|