@retikolo/drag-drop-content-types 1.5.1 → 1.5.3

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.
@@ -77,6 +77,7 @@ const SortModal = () => {
77
77
  rank: data.body.rank,
78
78
  title: data.body.title?.length > 0 ? data.body.title : mainField,
79
79
  subtitle: data.body.subtitle?.length > 0 ? data.body.subtitle : null,
80
+ mainField,
80
81
  };
81
82
  setSettings(fetchedSettings);
82
83
  } catch (e) {
@@ -212,10 +213,10 @@ const SortModal = () => {
212
213
  fetchContentTypeConfig();
213
214
  }, []);
214
215
 
215
- // Fetch settings on page render
216
+ // Fetch settings when mainField changes
216
217
  useEffect(() => {
217
218
  fetchSettings();
218
- }, []);
219
+ }, [mainField]);
219
220
 
220
221
  // Update view when settings change
221
222
  useEffect(() => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@retikolo/drag-drop-content-types",
3
- "version": "1.5.1",
3
+ "version": "1.5.3",
4
4
  "description": "This plugin add a drag and droppable list that allows you to sort content type entries.",
5
5
  "strapi": {
6
6
  "name": "drag-drop-content-types",
@@ -27,7 +27,7 @@
27
27
  },
28
28
  "peerDependencies": {
29
29
  "@strapi/design-system": "^1.13.1",
30
- "@strapi/icons": "1.13.1",
30
+ "@strapi/icons": "^1.13.1",
31
31
  "@strapi/strapi": "^4.0.0"
32
32
  },
33
33
  "author": {