easy-email-pro-theme 1.7.4 → 1.7.6

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.
Files changed (2) hide show
  1. package/lib/index.js +9 -12
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -2296,20 +2296,17 @@ const SlateField$2 = (props) => {
2296
2296
  [onChangeHandle]
2297
2297
  );
2298
2298
  useEffect(() => {
2299
- if (initedRef.current)
2300
- return;
2301
- if (!isEqual$3(fallbackValue, formItemFieldValue)) {
2302
- form.setFieldValue(fieldName, fallbackValue);
2299
+ if (initedRef.current) {
2300
+ if (!isEqual$3(currentValue, formItemFieldValue)) {
2301
+ form.setFieldValue(fieldName, currentValue);
2302
+ }
2303
+ } else {
2304
+ if (!isEqual$3(fallbackValue, formItemFieldValue)) {
2305
+ form.setFieldValue(fieldName, fallbackValue);
2306
+ }
2303
2307
  }
2304
2308
  initedRef.current = true;
2305
- }, [fallbackValue, fieldName, form, formItemFieldValue]);
2306
- useEffect(() => {
2307
- if (!initedRef.current)
2308
- return;
2309
- if (!isEqual$3(currentValue, formItemFieldValue)) {
2310
- form.setFieldValue(fieldName, currentValue);
2311
- }
2312
- }, [currentValue, fieldName, form, formItemFieldValue]);
2309
+ }, [currentValue]);
2313
2310
  return /* @__PURE__ */ React__default.createElement(
2314
2311
  Form.Item,
2315
2312
  __spreadProps(__spreadValues({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "easy-email-pro-theme",
3
- "version": "1.7.4",
3
+ "version": "1.7.6",
4
4
  "description": "",
5
5
  "files": [
6
6
  "lib"