@devcustrom/strapi-plugin-api-select 1.1.0 → 1.1.2
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useState, useEffect } from "react";
|
|
2
|
-
import PropTypes from "prop-types";
|
|
2
|
+
import * as PropTypes from "prop-types";
|
|
3
3
|
import {
|
|
4
4
|
Field,
|
|
5
5
|
SingleSelect,
|
|
@@ -95,9 +95,6 @@ const ApiSelectInput = ({
|
|
|
95
95
|
customHeaders = '',
|
|
96
96
|
responseDataPath = '',
|
|
97
97
|
responseMappingConfig = '',
|
|
98
|
-
// 🔥 Новые поля для иконок
|
|
99
|
-
enableIcons = false,
|
|
100
|
-
iconUrlKey = 'iconUrl',
|
|
101
98
|
} = configValues;
|
|
102
99
|
|
|
103
100
|
const getAuthToken = () => {
|
|
@@ -224,9 +221,8 @@ const ApiSelectInput = ({
|
|
|
224
221
|
return placeholder || configPlaceholder || (selectMode === 'single' ? 'Select option...' : 'Select options...');
|
|
225
222
|
};
|
|
226
223
|
|
|
227
|
-
// 🔥 Функция для рендера опции с иконкой
|
|
228
224
|
const renderOptionContent = (option) => {
|
|
229
|
-
const iconUrl = enableIcons ? option.item[iconUrlKey] : null;
|
|
225
|
+
const iconUrl = false//enableIcons ? option.item[iconUrlKey] : null;
|
|
230
226
|
return (
|
|
231
227
|
<Flex gap={2} alignItems="center">
|
|
232
228
|
{
|
|
@@ -319,7 +315,6 @@ const ApiSelectInput = ({
|
|
|
319
315
|
);
|
|
320
316
|
}
|
|
321
317
|
|
|
322
|
-
// Single Select mode
|
|
323
318
|
return (
|
|
324
319
|
<Box padding={2}>
|
|
325
320
|
<Field.Root name={name} error={error} required={required}>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devcustrom/strapi-plugin-api-select",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.2",
|
|
4
4
|
"description": "A powerful Strapi v5 plugin that provides API-driven select fields with support for GET/POST requests, custom headers, flexible response mapping, and multilingual content.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "strapi-server.js",
|