@cloud-ru/uikit-product-fields-predefined 0.13.5 → 0.13.7
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/CHANGELOG.md +22 -0
- package/dist/cjs/components/AIDisclaimer/AIDisclaimer.d.ts +1 -1
- package/dist/cjs/components/AIDisclaimer/AIDisclaimer.js +1 -1
- package/dist/cjs/components/FieldAi/FieldAi.d.ts +3 -3
- package/dist/cjs/components/FieldAi/FieldAi.js +4 -4
- package/dist/cjs/components/FieldAi/components/CheckItem/CheckItem.d.ts +1 -1
- package/dist/cjs/components/FieldAi/components/CheckItem/CheckItem.js +1 -1
- package/dist/cjs/components/FieldAi/components/MobileFieldAi/MobileFieldAi.d.ts +1 -1
- package/dist/cjs/components/FieldAi/components/MobileFieldAi/MobileFieldAi.js +1 -1
- package/dist/cjs/components/FieldAi/components/MobileFieldAi/styles.module.css +21 -0
- package/dist/cjs/components/FieldAi/components/PasswordValidation/PasswordValidation.d.ts +1 -1
- package/dist/cjs/components/FieldAi/components/PasswordValidation/PasswordValidation.js +1 -1
- package/dist/cjs/components/FieldAi/components/WithPasswordValidation/WithPasswordValidation.d.ts +1 -1
- package/dist/cjs/components/FieldAi/components/WithPasswordValidation/WithPasswordValidation.js +1 -1
- package/dist/cjs/components/FieldAi/styles.module.css +9 -0
- package/dist/cjs/components/FieldChat/FieldChat.d.ts +2 -2
- package/dist/cjs/components/FieldChat/FieldChat.js +3 -3
- package/dist/cjs/components/FieldPhone/FieldPhone.d.ts +3 -3
- package/dist/cjs/components/FieldPhone/FieldPhone.js +2 -2
- package/dist/cjs/components/FieldPhone/countries.js +1 -1
- package/dist/cjs/components/FieldPhone/hooks/useMapCountryToOptions.js +1 -1
- package/dist/cjs/components/SelectCreate/SelectCreate.d.ts +1 -1
- package/dist/cjs/components/SelectCreate/SelectCreate.js +5 -5
- package/dist/cjs/components/SelectCreate/SelectFooter/SelectFooter.js +2 -2
- package/dist/cjs/components/SelectCreate/types.d.ts +2 -2
- package/dist/cjs/components/SelectCreate/useSelectDataStates.d.ts +1 -1
- package/dist/cjs/components/SelectCreate/useSelectDataStates.js +2 -2
- package/dist/cjs/helperComponents/FieldSubmitButton/FieldSubmitButton.js +2 -2
- package/dist/cjs/helpers/isTouchDevice.d.ts +1 -1
- package/dist/cjs/index.d.ts +1 -1
- package/dist/cjs/index.js +1 -1
- package/dist/esm/components/AIDisclaimer/AIDisclaimer.d.ts +1 -1
- package/dist/esm/components/AIDisclaimer/AIDisclaimer.js +1 -1
- package/dist/esm/components/FieldAi/FieldAi.d.ts +3 -3
- package/dist/esm/components/FieldAi/FieldAi.js +4 -4
- package/dist/esm/components/FieldAi/components/CheckItem/CheckItem.d.ts +1 -1
- package/dist/esm/components/FieldAi/components/CheckItem/CheckItem.js +1 -1
- package/dist/esm/components/FieldAi/components/MobileFieldAi/MobileFieldAi.d.ts +1 -1
- package/dist/esm/components/FieldAi/components/MobileFieldAi/MobileFieldAi.js +1 -1
- package/dist/esm/components/FieldAi/components/MobileFieldAi/styles.module.css +21 -0
- package/dist/esm/components/FieldAi/components/PasswordValidation/PasswordValidation.d.ts +1 -1
- package/dist/esm/components/FieldAi/components/PasswordValidation/PasswordValidation.js +1 -1
- package/dist/esm/components/FieldAi/components/WithPasswordValidation/WithPasswordValidation.d.ts +1 -1
- package/dist/esm/components/FieldAi/components/WithPasswordValidation/WithPasswordValidation.js +1 -1
- package/dist/esm/components/FieldAi/styles.module.css +9 -0
- package/dist/esm/components/FieldChat/FieldChat.d.ts +2 -2
- package/dist/esm/components/FieldChat/FieldChat.js +3 -3
- package/dist/esm/components/FieldPhone/FieldPhone.d.ts +3 -3
- package/dist/esm/components/FieldPhone/FieldPhone.js +2 -2
- package/dist/esm/components/FieldPhone/countries.js +1 -1
- package/dist/esm/components/FieldPhone/hooks/useMapCountryToOptions.js +1 -1
- package/dist/esm/components/SelectCreate/SelectCreate.d.ts +1 -1
- package/dist/esm/components/SelectCreate/SelectCreate.js +5 -5
- package/dist/esm/components/SelectCreate/SelectFooter/SelectFooter.js +2 -2
- package/dist/esm/components/SelectCreate/types.d.ts +2 -2
- package/dist/esm/components/SelectCreate/useSelectDataStates.d.ts +1 -1
- package/dist/esm/components/SelectCreate/useSelectDataStates.js +2 -2
- package/dist/esm/helperComponents/FieldSubmitButton/FieldSubmitButton.js +2 -2
- package/dist/esm/helpers/isTouchDevice.d.ts +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/tsconfig.cjs.tsbuildinfo +1 -1
- package/dist/tsconfig.esm.tsbuildinfo +1 -1
- package/package.json +8 -9
- package/src/components/FieldAi/FieldAi.tsx +2 -2
- package/src/components/FieldAi/components/MobileFieldAi/styles.module.scss +9 -0
- package/src/components/FieldAi/styles.module.scss +18 -0
|
@@ -11,9 +11,9 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
11
11
|
};
|
|
12
12
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
13
|
import { useMemo } from 'react';
|
|
14
|
-
import { AttachmentSVG } from '@
|
|
15
|
-
import { useLocale } from '@
|
|
16
|
-
import { AdaptiveFieldTextArea } from '@
|
|
14
|
+
import { AttachmentSVG } from '@cloud-ru/uikit-product-icons';
|
|
15
|
+
import { useLocale } from '@cloud-ru/uikit-product-locale';
|
|
16
|
+
import { AdaptiveFieldTextArea } from '@cloud-ru/uikit-product-mobile-fields';
|
|
17
17
|
import { ButtonFunction } from '@snack-uikit/button';
|
|
18
18
|
import { FileUpload } from '@snack-uikit/drop-zone';
|
|
19
19
|
import { Tooltip } from '@snack-uikit/tooltip';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { FieldTextProps } from '@
|
|
2
|
-
import { WithLayoutType } from '@
|
|
1
|
+
import { FieldTextProps } from '@cloud-ru/uikit-product-mobile-fields';
|
|
2
|
+
import { WithLayoutType } from '@cloud-ru/uikit-product-utils';
|
|
3
3
|
import { CountrySettings, FieldPhoneOptionsProps } from './types';
|
|
4
4
|
export type FieldPhoneProps = WithLayoutType<Omit<FieldTextProps, 'prefix' | 'prefixIcon' | 'postfix' | 'placeholder' | 'autocomplete' | 'decoratorRef' | 'allowMoreThanMaxLength' | 'onKeyDown' | 'button' | 'maxLength' | 'inputMode'> & {
|
|
5
5
|
/** Включить скролл для основной части списка стран */
|
|
@@ -21,5 +21,5 @@ export declare const FieldPhone: import("react").ForwardRefExoticComponent<Omit<
|
|
|
21
21
|
/** options — объект конфигурации для изменения стандартного списка стран */
|
|
22
22
|
options?: CountrySettings;
|
|
23
23
|
} & {
|
|
24
|
-
layoutType: import("@
|
|
24
|
+
layoutType: import("@cloud-ru/uikit-product-utils").LayoutType;
|
|
25
25
|
} & import("react").RefAttributes<HTMLInputElement>>;
|
|
@@ -14,8 +14,8 @@ import cn from 'classnames';
|
|
|
14
14
|
import mergeRefs from 'merge-refs';
|
|
15
15
|
import { forwardRef, useEffect, useMemo, useRef, useState } from 'react';
|
|
16
16
|
import { useIMask } from 'react-imask';
|
|
17
|
-
import { AdaptiveDroplist } from '@
|
|
18
|
-
import { AdaptiveFieldText } from '@
|
|
17
|
+
import { AdaptiveDroplist } from '@cloud-ru/uikit-product-mobile-dropdown';
|
|
18
|
+
import { AdaptiveFieldText } from '@cloud-ru/uikit-product-mobile-fields';
|
|
19
19
|
import { useValueControl } from '@snack-uikit/utils';
|
|
20
20
|
import { PLACEHOLDER_CHAR } from './constants';
|
|
21
21
|
import { useCountries } from './hooks';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { AbkhaziaSVG, AfghanistanSVG, AlbaniaSVG, AlgeriaSVG, AndorraSVG, AngolaSVG, AntiguaAndBarbudaSVG, ArgentinaSVG, ArmeniaSVG, AustraliaSVG, AustriaSVG, AzerbaijanSVG, BahamasSVG, BahrainSVG, BangladeshSVG, BarbadosSVG, BelarusSVG, BelgiumSVG, BelizeSVG, BeninSVG, BhutanSVG, BosniaAndHerzegovinaSVG, BotswanaSVG, BrazilSVG, CambodiaSVG, CameroonSVG, CaymanIslandsSVG, CentralAfricanRepublicSVG, ChadSVG, ChileSVG, ColombiaSVG, CongoSVG, CostaRicaSVG, CoteDIvoireSVG, CroatiaSVG, CyprusSVG, DenmarkSVG, DjiboutiSVG, DominicanRepublicSVG, EcuadorSVG, EgyptSVG, EstoniaSVG, EthiopiaSVG, FijiSVG, FinlandSVG, FranceSVG, FrenchPolynesiaSVG, GeorgiaSVG, GermanySVG, GhanaSVG, GibraltarSVG, GreeceSVG, GuatemalaSVG, GuernseySVG, GuineaSVG, GuyanaSVG, HaitiSVG, HondurasSVG, HongKongSVG, HungarySVG, IcelandSVG, IndiaSVG, IndonesiaSVG, IranSVG, IraqSVG, IrelandSVG, IsleOfManSVG, IsraelSVG, ItalySVG, JapanSVG, JordanSVG, KazakhstanSVG, KenyaSVG, KiribatiSVG, KosovoSVG, KyrgyzstanSVG, LatviaSVG, LebanonSVG, LesothoSVG, LibyaSVG, LiechtensteinSVG, LithuaniaSVG, LuxembourgSVG, MadagascarSVG, MalaysiaSVG, MaldivesSVG, MaliSVG, MaltaSVG, MauritaniaSVG, MauritiusSVG, MayotteSVG, MoldovaSVG, MonacoSVG, MontenegroSVG, MoroccoSVG, MozambiqueSVG, MyanmarSVG, NamibiaSVG, NetherlandsSVG, NewCaledoniaSVG, NewZealandSVG, NicaraguaSVG, NigeriaSVG, NigerSVG, NorfolkIslandSVG, NorthMacedoniaSVG, NorwaySVG, OmanSVG, PalestineSVG, ParaguaySVG, PeruSVG, PolandSVG, PortugalSVG, QatarSVG, RomaniaSVG, RussiaSVG, RwandaSVG, SaintPierreAndMiquelonSVG, SanMarinoSVG, SaoTomeAndPrincipeSVG, SaudiArabiaSVG, SenegalSVG, SerbiaSVG, SierraLeoneSVG, SingaporeSVG, SintMaartenSVG, SlovakiaSVG, SomalilandSVG, SouthAfricaSVG, SouthKoreaSVG, SouthSudanSVG, SpainSVG, SriLankaSVG, SudanSVG, SurinameSVG, SwedenSVG, SwitzerlandSVG, SyriaSVG, TaiwanSVG, TajikistanSVG, TanzaniaSVG, ThailandSVG, TongaSVG, TransnistriaSVG, TurkeySVG, TurkmenistanSVG, TuvaluSVG, UgandaSVG, UkraineSVG, UnitedArabEmiratesSVG, UruguaySVG, UzbekistanSVG, VanuatuSVG, VenezuelaSVG, VietnamSVG, WallisAndFutunaSVG, YemenSVG, ZimbabweSVG, } from '@
|
|
2
|
+
import { AbkhaziaSVG, AfghanistanSVG, AlbaniaSVG, AlgeriaSVG, AndorraSVG, AngolaSVG, AntiguaAndBarbudaSVG, ArgentinaSVG, ArmeniaSVG, AustraliaSVG, AustriaSVG, AzerbaijanSVG, BahamasSVG, BahrainSVG, BangladeshSVG, BarbadosSVG, BelarusSVG, BelgiumSVG, BelizeSVG, BeninSVG, BhutanSVG, BosniaAndHerzegovinaSVG, BotswanaSVG, BrazilSVG, CambodiaSVG, CameroonSVG, CaymanIslandsSVG, CentralAfricanRepublicSVG, ChadSVG, ChileSVG, ColombiaSVG, CongoSVG, CostaRicaSVG, CoteDIvoireSVG, CroatiaSVG, CyprusSVG, DenmarkSVG, DjiboutiSVG, DominicanRepublicSVG, EcuadorSVG, EgyptSVG, EstoniaSVG, EthiopiaSVG, FijiSVG, FinlandSVG, FranceSVG, FrenchPolynesiaSVG, GeorgiaSVG, GermanySVG, GhanaSVG, GibraltarSVG, GreeceSVG, GuatemalaSVG, GuernseySVG, GuineaSVG, GuyanaSVG, HaitiSVG, HondurasSVG, HongKongSVG, HungarySVG, IcelandSVG, IndiaSVG, IndonesiaSVG, IranSVG, IraqSVG, IrelandSVG, IsleOfManSVG, IsraelSVG, ItalySVG, JapanSVG, JordanSVG, KazakhstanSVG, KenyaSVG, KiribatiSVG, KosovoSVG, KyrgyzstanSVG, LatviaSVG, LebanonSVG, LesothoSVG, LibyaSVG, LiechtensteinSVG, LithuaniaSVG, LuxembourgSVG, MadagascarSVG, MalaysiaSVG, MaldivesSVG, MaliSVG, MaltaSVG, MauritaniaSVG, MauritiusSVG, MayotteSVG, MoldovaSVG, MonacoSVG, MontenegroSVG, MoroccoSVG, MozambiqueSVG, MyanmarSVG, NamibiaSVG, NetherlandsSVG, NewCaledoniaSVG, NewZealandSVG, NicaraguaSVG, NigeriaSVG, NigerSVG, NorfolkIslandSVG, NorthMacedoniaSVG, NorwaySVG, OmanSVG, PalestineSVG, ParaguaySVG, PeruSVG, PolandSVG, PortugalSVG, QatarSVG, RomaniaSVG, RussiaSVG, RwandaSVG, SaintPierreAndMiquelonSVG, SanMarinoSVG, SaoTomeAndPrincipeSVG, SaudiArabiaSVG, SenegalSVG, SerbiaSVG, SierraLeoneSVG, SingaporeSVG, SintMaartenSVG, SlovakiaSVG, SomalilandSVG, SouthAfricaSVG, SouthKoreaSVG, SouthSudanSVG, SpainSVG, SriLankaSVG, SudanSVG, SurinameSVG, SwedenSVG, SwitzerlandSVG, SyriaSVG, TaiwanSVG, TajikistanSVG, TanzaniaSVG, ThailandSVG, TongaSVG, TransnistriaSVG, TurkeySVG, TurkmenistanSVG, TuvaluSVG, UgandaSVG, UkraineSVG, UnitedArabEmiratesSVG, UruguaySVG, UzbekistanSVG, VanuatuSVG, VenezuelaSVG, VietnamSVG, WallisAndFutunaSVG, YemenSVG, ZimbabweSVG, } from '@cloud-ru/uikit-product-icons';
|
|
3
3
|
export const RUSSIA_COUNTRY_CODE = {
|
|
4
4
|
value: 'russia',
|
|
5
5
|
iso2: 'RU',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useCallback } from 'react';
|
|
2
|
-
import { useLocale } from '@
|
|
2
|
+
import { useLocale } from '@cloud-ru/uikit-product-locale';
|
|
3
3
|
export function useMapCountryToOptions() {
|
|
4
4
|
const { t } = useLocale('FieldsPredefined');
|
|
5
5
|
const mapCountryToOption = useCallback(({ value: id, mask, caption, beforeContent, iso2 }) => ({
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { WithLayoutType, WithSupportProps } from '@
|
|
1
|
+
import { WithLayoutType, WithSupportProps } from '@cloud-ru/uikit-product-utils';
|
|
2
2
|
import { IconPredefinedProps } from '@snack-uikit/icon-predefined';
|
|
3
3
|
import { EntityName, FieldSelectProps, LayoutProps } from './types';
|
|
4
4
|
export type SelectCreateProps = WithSupportProps<WithLayoutType & LayoutProps & {
|
|
@@ -20,11 +20,11 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
20
20
|
};
|
|
21
21
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
22
22
|
import { memo, useCallback, useMemo } from 'react';
|
|
23
|
-
import { PlusSVG } from '@
|
|
24
|
-
import { useLocale } from '@
|
|
25
|
-
import { AdaptiveFieldSelect } from '@
|
|
26
|
-
import { AdaptiveDrawer, AdaptiveModal } from '@
|
|
27
|
-
import { extractSupportProps } from '@
|
|
23
|
+
import { PlusSVG } from '@cloud-ru/uikit-product-icons';
|
|
24
|
+
import { useLocale } from '@cloud-ru/uikit-product-locale';
|
|
25
|
+
import { AdaptiveFieldSelect } from '@cloud-ru/uikit-product-mobile-fields';
|
|
26
|
+
import { AdaptiveDrawer, AdaptiveModal } from '@cloud-ru/uikit-product-mobile-modal';
|
|
27
|
+
import { extractSupportProps } from '@cloud-ru/uikit-product-utils';
|
|
28
28
|
import { ButtonFunction } from '@snack-uikit/button';
|
|
29
29
|
import { WithTooltip } from '@snack-uikit/tooltip';
|
|
30
30
|
import { useOpen } from '../../hooks';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { PlusSVG } from '@
|
|
3
|
-
import { useLocale } from '@
|
|
2
|
+
import { PlusSVG } from '@cloud-ru/uikit-product-icons';
|
|
3
|
+
import { useLocale } from '@cloud-ru/uikit-product-locale';
|
|
4
4
|
import { ButtonFunction } from '@snack-uikit/button';
|
|
5
5
|
import { WithTooltip } from '@snack-uikit/tooltip';
|
|
6
6
|
import styled from './styles.module.css';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { FieldSelectMultipleProps, FieldSelectSingleProps } from '@
|
|
3
|
-
import { AdaptiveDrawerProps, AdaptiveModalProps } from '@
|
|
2
|
+
import { FieldSelectMultipleProps, FieldSelectSingleProps } from '@cloud-ru/uikit-product-mobile-fields';
|
|
3
|
+
import { AdaptiveDrawerProps, AdaptiveModalProps } from '@cloud-ru/uikit-product-mobile-modal';
|
|
4
4
|
type CommonModalDrawerProps = 'open' | 'onClose' | 'approveButton' | 'cancelButton' | 'layoutType';
|
|
5
5
|
type CreateLayoutModalProps = Omit<AdaptiveModalProps, CommonModalDrawerProps> & {
|
|
6
6
|
content: ReactNode;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { FieldSelectProps } from '@
|
|
1
|
+
import { FieldSelectProps } from '@cloud-ru/uikit-product-mobile-fields';
|
|
2
2
|
import { IconPredefinedProps } from '@snack-uikit/icon-predefined';
|
|
3
3
|
import { EntityName } from './types';
|
|
4
4
|
type Props = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useMemo } from 'react';
|
|
3
|
-
import { SearchSVG, UpdateSVG } from '@
|
|
4
|
-
import { useLocale } from '@
|
|
3
|
+
import { SearchSVG, UpdateSVG } from '@cloud-ru/uikit-product-icons';
|
|
4
|
+
import { useLocale } from '@cloud-ru/uikit-product-locale';
|
|
5
5
|
import { ButtonTonal } from '@snack-uikit/button';
|
|
6
6
|
import { capitalize } from '../../helpers';
|
|
7
7
|
export function useSelectDataStates({ onRefetch, entityName, entityIcon }) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { ArrowUpSVG } from '@
|
|
3
|
-
import { useLocale } from '@
|
|
2
|
+
import { ArrowUpSVG } from '@cloud-ru/uikit-product-icons';
|
|
3
|
+
import { useLocale } from '@cloud-ru/uikit-product-locale';
|
|
4
4
|
import { ButtonFilled } from '@snack-uikit/button';
|
|
5
5
|
import { Tooltip } from '@snack-uikit/tooltip';
|
|
6
6
|
export function FieldSubmitButton({ active, handleClick, size = 'xs', className, fullWidth, showTooltip = true, }) {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { LayoutType } from '@
|
|
1
|
+
import { LayoutType } from '@cloud-ru/uikit-product-utils';
|
|
2
2
|
export declare function isTouchDevice(layoutType: LayoutType): boolean;
|
package/dist/esm/index.d.ts
CHANGED
package/dist/esm/index.js
CHANGED