jamespot-react-components 1.0.150 → 1.0.152
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/build/jamespot-react-components.js +255 -249
- package/build/jamespot-react-components.js.map +1 -1
- package/build/src/components/Form/Input/JRCInputCheckbox/JRCInputCheckbox.d.ts +4 -3
- package/build/src/components/Form/Input/JRCInputFile/JRCInputFile.d.ts +1 -1
- package/build/src/components/Form/Input/JRCSelect/JRCInputSelect.d.ts +2 -1
- package/build/src/components/Form/Input/JRCSelect/JRCInputSelectHierarchicalTree.d.ts +3 -3
- package/build/src/components/Form/Input/JRCSelect/JRCInputSelectList.d.ts +5 -4
- package/build/src/components/JRCCropImage/JRCCropImage.d.ts +1 -1
- package/build/src/components/JRCFileViewer/JRCFileViewer.d.ts +1 -1
- package/build/src/components/JRCHtml/JRCHtml.d.ts +1 -1
- package/build/src/components/JRCModal/JRCModal.styles.d.ts +8 -6
- package/build/src/components/JRCModal/JRCModalContent.d.ts +27 -0
- package/build/src/components/JRCModal/JRCModalContentForm.d.ts +13 -0
- package/build/src/components/JRCModal/JRCModalLayout.d.ts +17 -0
- package/build/src/components/JRCModal/templates/JRCModal.d.ts +3 -0
- package/build/src/components/JRCModal/{JRCModal.stories.d.ts → templates/JRCModal.stories.d.ts} +1 -2
- package/build/src/components/JRCModal/templates/JRCModal.types.d.ts +24 -0
- package/build/src/components/JRCModal/templates/JRCModalForm.d.ts +3 -0
- package/build/src/components/JRCModal/templates/JRCModalForm.stories.d.ts +4 -0
- package/build/src/components/JRCTypography/JRCTypography.styles.d.ts +1 -1
- package/build/src/index.d.ts +7 -2
- package/build/src/types.d.ts +4 -1
- package/package.json +2 -2
- package/build/src/components/JRCModal/JRCModal.d.ts +0 -56
|
@@ -20,16 +20,17 @@ export type CheckboxProps<TFieldValues> = DataCy & {
|
|
|
20
20
|
backgroundOnHover?: boolean;
|
|
21
21
|
backgroundOnSelect?: boolean;
|
|
22
22
|
valueTypeIsBoolean?: boolean;
|
|
23
|
-
setOptionsChecked?: (string | number | TFieldValues)[] | undefined;
|
|
24
|
-
getOptionsChecked?: (options: (string | number | TFieldValues)[] | undefined) => void;
|
|
25
23
|
readOnly?: boolean;
|
|
26
24
|
getReadOnlyLabel?: (value: TFieldValues) => React.ReactNode;
|
|
27
25
|
};
|
|
28
26
|
export type JRCInputCheckboxProps<TFieldValues extends FieldValues = FieldValues> = CheckboxProps<TFieldValues> & JRCInputFieldProps<TFieldValues>;
|
|
29
|
-
export type NativeCheckboxProps<TFieldValues extends FieldValues = FieldValues> = CheckboxProps<TFieldValues> & Omit<ControllerRenderProps<TFieldValues>, 'value'> & {
|
|
27
|
+
export type NativeCheckboxProps<TFieldValues extends FieldValues = FieldValues> = CheckboxProps<TFieldValues> & Omit<ControllerRenderProps<TFieldValues>, 'value' | 'ref'> & {
|
|
28
|
+
ref?: React.ForwardedRef<HTMLInputElement>;
|
|
29
|
+
} & {
|
|
30
30
|
value: TFieldValues | TFieldValues[];
|
|
31
31
|
};
|
|
32
32
|
export declare const ReadOnlyUl: import("styled-components").StyledComponent<"ul", import("styled-components").DefaultTheme, {}, never>;
|
|
33
|
+
export declare const JRCInputCheckboxRaw: <T extends FieldValues = FieldValues>(props: NativeCheckboxProps<T>) => JSX.Element;
|
|
33
34
|
export declare function JRCInputCheckbox<TFieldValues extends FieldValues = FieldValues>({ name, control, rules, label, htmlFor, labelIsLegend, description, helper, ...props }: JRCInputCheckboxProps<TFieldValues>): React.JSX.Element;
|
|
34
35
|
export declare namespace JRCInputCheckbox {
|
|
35
36
|
var defaultProps: {
|
|
@@ -11,7 +11,7 @@ export type NativeInputFileProps = DataCy & Omit<React.ComponentPropsWithoutRef<
|
|
|
11
11
|
onChange: (files: ApiWrapper<jFileLittle>[]) => void;
|
|
12
12
|
};
|
|
13
13
|
export type JRCInputFileProps<T extends FieldValues = FieldValues> = JRCInputFieldProps<T> & Omit<NativeInputFileProps, 'value' | 'onChange'>;
|
|
14
|
-
export declare const InputFile: React.ForwardRefExoticComponent<DataCy & Omit<Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref">, "
|
|
14
|
+
export declare const InputFile: React.ForwardRefExoticComponent<DataCy & Omit<Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref">, "onChange" | "value"> & {
|
|
15
15
|
token?: string | undefined;
|
|
16
16
|
attrName?: string | undefined;
|
|
17
17
|
onLoading?: ((state: boolean) => void) | undefined;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { JRCInputSelectProps, NativeSelectProps } from './JRCInputSelect.types';
|
|
3
3
|
import type { FieldValues } from 'react-hook-form';
|
|
4
|
-
export declare const Select: <T extends FieldValues = FieldValues>(props: NativeSelectProps<T>) => JSX.Element;
|
|
4
|
+
export declare const Select: <T extends FieldValues = FieldValues>(props: Pick<Partial<NativeSelectProps<T>>, "ref"> & Omit<NativeSelectProps<T>, "ref">) => JSX.Element;
|
|
5
5
|
export declare function JRCInputSelect<T extends FieldValues = FieldValues>(props: JRCInputSelectProps<T>): React.JSX.Element;
|
|
6
|
+
export declare const JRCInputSelectRaw: <T extends FieldValues = FieldValues>(props: Pick<Partial<NativeSelectProps<T>>, "ref"> & Omit<NativeSelectProps<T>, "ref">) => JSX.Element;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { JRCInputSelectProps } from './JRCInputSelect.types';
|
|
3
|
-
import {
|
|
3
|
+
import { JRCModalLayoutProps } from 'components/JRCModal/JRCModalLayout';
|
|
4
4
|
import { AutoCompleteConcept, PagingResults } from 'jamespot-user-api';
|
|
5
|
-
export type JRCInputSelectHierarchicalTreeProps = Omit<JRCInputSelectProps, 'asyncPromise'> &
|
|
5
|
+
export type JRCInputSelectHierarchicalTreeProps = Omit<JRCInputSelectProps, 'asyncPromise'> & JRCModalLayoutProps & {
|
|
6
6
|
asyncPromise?: (inputValue: string, page?: number) => Promise<PagingResults<any>>;
|
|
7
7
|
hierarchicalTaxonomyPromise: (uriConcept: string) => Promise<PagingResults<AutoCompleteConcept>>;
|
|
8
8
|
displayModal?: boolean;
|
|
@@ -11,7 +11,7 @@ export type JRCInputSelectHierarchicalTreeProps = Omit<JRCInputSelectProps, 'asy
|
|
|
11
11
|
value: any;
|
|
12
12
|
}>;
|
|
13
13
|
};
|
|
14
|
-
export declare const JRCInputSelectHierarchicalTree: React.ForwardRefExoticComponent<Omit<JRCInputSelectProps<import("react-hook-form").FieldValues>, "asyncPromise"> &
|
|
14
|
+
export declare const JRCInputSelectHierarchicalTree: React.ForwardRefExoticComponent<Omit<JRCInputSelectProps<import("react-hook-form").FieldValues>, "asyncPromise"> & JRCModalLayoutProps & {
|
|
15
15
|
asyncPromise?: ((inputValue: string, page?: number) => Promise<PagingResults<any>>) | undefined;
|
|
16
16
|
hierarchicalTaxonomyPromise: (uriConcept: string) => Promise<PagingResults<AutoCompleteConcept>>;
|
|
17
17
|
displayModal?: boolean | undefined;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { JRCInputSelectProps } from './JRCInputSelect.types';
|
|
3
|
-
import { JRCModalProps } from 'components/JRCModal/JRCModal';
|
|
4
3
|
import { BaseAutocomplete, PagingResults } from 'jamespot-user-api';
|
|
5
|
-
|
|
4
|
+
import { FieldValues } from 'react-hook-form';
|
|
5
|
+
import { JRCModalProps } from '../../../JRCModal/templates/JRCModal.types';
|
|
6
|
+
export type JRCInputSelectListProps<T extends FieldValues = FieldValues> = Omit<JRCInputSelectProps<T>, 'asyncPromise'> & Pick<JRCModalProps, 'inPlace'> & {
|
|
6
7
|
asyncPromise?: (inputValue: string, page?: number) => Promise<PagingResults<any>>;
|
|
7
8
|
displayModal?: boolean;
|
|
8
|
-
|
|
9
|
+
onChange: (values: BaseAutocomplete[]) => void;
|
|
9
10
|
};
|
|
10
|
-
export declare const JRCInputSelectList: ({ asyncPromise, displayModal, inPlace, width, placeholder,
|
|
11
|
+
export declare const JRCInputSelectList: <T extends FieldValues = FieldValues>({ asyncPromise, displayModal, inPlace, width, placeholder, onChange, control, name, ...props }: JRCInputSelectListProps<T>) => React.JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { Area as _Area, Point as _Point, Size as _Size } from 'react-easy-crop/types';
|
|
3
|
-
import { JRCModalProps } from '../JRCModal/JRCModal';
|
|
3
|
+
import { JRCModalProps } from '../JRCModal/templates/JRCModal.types';
|
|
4
4
|
export type Size = _Size;
|
|
5
5
|
export type Point = _Point;
|
|
6
6
|
export type Area = _Area;
|
|
@@ -7,6 +7,6 @@ export type JRCHtmlProps = LimitLinesProps & {
|
|
|
7
7
|
};
|
|
8
8
|
export declare const JRCHtml: React.ForwardRefExoticComponent<LimitLinesProps & {
|
|
9
9
|
className?: string | undefined;
|
|
10
|
-
as?: "symbol" | "object" | "g" | "b" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "dialog" | "
|
|
10
|
+
as?: "symbol" | "object" | "g" | "b" | "div" | "a" | "abbr" | "address" | "area" | "article" | "aside" | "audio" | "base" | "bdi" | "bdo" | "big" | "blockquote" | "body" | "br" | "button" | "canvas" | "caption" | "cite" | "code" | "col" | "colgroup" | "data" | "datalist" | "dd" | "del" | "details" | "dfn" | "dialog" | "dl" | "dt" | "em" | "embed" | "fieldset" | "figcaption" | "figure" | "footer" | "form" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "head" | "header" | "hgroup" | "hr" | "html" | "i" | "iframe" | "img" | "input" | "ins" | "kbd" | "keygen" | "label" | "legend" | "li" | "link" | "main" | "map" | "mark" | "menu" | "menuitem" | "meta" | "meter" | "nav" | "noindex" | "noscript" | "ol" | "optgroup" | "option" | "output" | "p" | "param" | "picture" | "pre" | "progress" | "q" | "rp" | "rt" | "ruby" | "s" | "samp" | "slot" | "script" | "section" | "select" | "small" | "source" | "span" | "strong" | "style" | "sub" | "summary" | "sup" | "table" | "template" | "tbody" | "td" | "textarea" | "tfoot" | "th" | "thead" | "time" | "title" | "tr" | "track" | "u" | "ul" | "var" | "video" | "wbr" | "webview" | "svg" | "animate" | "animateMotion" | "animateTransform" | "circle" | "clipPath" | "defs" | "desc" | "ellipse" | "feBlend" | "feColorMatrix" | "feComponentTransfer" | "feComposite" | "feConvolveMatrix" | "feDiffuseLighting" | "feDisplacementMap" | "feDistantLight" | "feDropShadow" | "feFlood" | "feFuncA" | "feFuncB" | "feFuncG" | "feFuncR" | "feGaussianBlur" | "feImage" | "feMerge" | "feMergeNode" | "feMorphology" | "feOffset" | "fePointLight" | "feSpecularLighting" | "feSpotLight" | "feTile" | "feTurbulence" | "filter" | "foreignObject" | "image" | "line" | "linearGradient" | "marker" | "mask" | "metadata" | "mpath" | "path" | "pattern" | "polygon" | "polyline" | "radialGradient" | "rect" | "stop" | "switch" | "text" | "textPath" | "tspan" | "use" | "view" | React.ComponentClass<any, any> | React.FunctionComponent<any> | undefined;
|
|
11
11
|
__html: string | undefined;
|
|
12
12
|
} & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -1,28 +1,30 @@
|
|
|
1
|
+
import { ModalVariant } from './JRCModalLayout';
|
|
1
2
|
export type ModalBorderRadius = 'medium' | 'small';
|
|
2
3
|
export declare const JRCModalBox: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
3
4
|
isFullHeight?: boolean | undefined;
|
|
5
|
+
overflow?: "hidden" | "visible" | undefined;
|
|
4
6
|
}, never>;
|
|
5
7
|
export declare const JRCModalContainerFull: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
6
8
|
isFullScreen?: boolean | undefined;
|
|
7
9
|
maxHeight?: string | undefined;
|
|
8
10
|
}, never>;
|
|
9
11
|
export declare const JRCModalContainer: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
10
|
-
|
|
11
|
-
overflow?: "hidden" | "visible" |
|
|
12
|
+
variant?: ModalVariant | undefined;
|
|
13
|
+
overflow?: "hidden" | "visible" | undefined;
|
|
12
14
|
radius?: ModalBorderRadius | undefined;
|
|
13
15
|
maxHeight?: string | undefined;
|
|
14
16
|
}, never>;
|
|
15
17
|
export declare const JRCModalTitle: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
16
18
|
export declare const JRCModalOptions: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
17
|
-
export declare const
|
|
18
|
-
|
|
19
|
+
export declare const JRCModalBody: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
20
|
+
modalOverflow?: "hidden" | "visible" | "scroll" | undefined;
|
|
19
21
|
}, never>;
|
|
20
22
|
export declare const JRCModalContentFull: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
21
23
|
export declare const JRCModalContentScrollbox: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
22
24
|
export declare const JRCModalHeader: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
23
|
-
|
|
25
|
+
modalOverflow?: "hidden" | "visible" | "scroll" | undefined;
|
|
24
26
|
}, never>;
|
|
25
27
|
export declare const JRCModalFooter: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
26
|
-
|
|
28
|
+
modalOverflow?: "hidden" | "visible" | "scroll" | undefined;
|
|
27
29
|
}, never>;
|
|
28
30
|
export declare const JRCModalClose: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { ButtonColors } from '../JRCButton/JRCButton';
|
|
3
|
+
export type JRCModalContentBase = {
|
|
4
|
+
title?: ReactNode;
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
options?: ReactNode;
|
|
7
|
+
overflow?: 'visible' | 'hidden' | 'scroll';
|
|
8
|
+
onClickIconClose?: () => void;
|
|
9
|
+
};
|
|
10
|
+
export type JRCModalContentProps = JRCModalContentBase & {
|
|
11
|
+
isFull?: boolean;
|
|
12
|
+
buttons?: JRCModalButtonType[];
|
|
13
|
+
};
|
|
14
|
+
export interface JRCModalButtonType {
|
|
15
|
+
children: ReactNode;
|
|
16
|
+
color?: ButtonColors;
|
|
17
|
+
variant?: 'contained' | 'outlined';
|
|
18
|
+
clickHandler?: () => void;
|
|
19
|
+
dataCy?: string;
|
|
20
|
+
}
|
|
21
|
+
export declare const ModalOptions: ({ children }: {
|
|
22
|
+
children?: React.ReactNode;
|
|
23
|
+
}) => React.JSX.Element;
|
|
24
|
+
export declare const ModalTitle: ({ children }: {
|
|
25
|
+
children?: React.ReactNode;
|
|
26
|
+
}) => React.JSX.Element;
|
|
27
|
+
export declare const JRCModalContent: ({ title, onClickIconClose, overflow, options, children, buttons, isFull, }: JRCModalContentProps) => React.JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React, { FormEvent } from 'react';
|
|
2
|
+
import { JRCModalButtonType, JRCModalContentBase } from './JRCModalContent';
|
|
3
|
+
export type JRCModalContentFormProps = JRCModalContentBase & {
|
|
4
|
+
buttons?: JRCModalFormButtonType[];
|
|
5
|
+
onSubmit: (e: FormEvent) => Promise<void>;
|
|
6
|
+
loading?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export interface JRCModalFormButtonType extends JRCModalButtonType {
|
|
9
|
+
loading?: boolean;
|
|
10
|
+
isSubmit?: boolean;
|
|
11
|
+
disabled?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export declare const JRCModalContentForm: ({ onSubmit, children, loading, title, onClickIconClose, options, buttons, overflow, }: JRCModalContentFormProps) => React.JSX.Element;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { ModalBorderRadius } from './JRCModal.styles';
|
|
3
|
+
export type ModalVariant = 'full-width' | 'full-screen' | 'full-height' | 'fixed-height';
|
|
4
|
+
export interface JRCModalLayoutProps {
|
|
5
|
+
open: boolean;
|
|
6
|
+
closeHandler: () => void;
|
|
7
|
+
children?: ReactNode;
|
|
8
|
+
enableClickAwayCloseModal?: boolean;
|
|
9
|
+
radius?: ModalBorderRadius;
|
|
10
|
+
portalId?: string;
|
|
11
|
+
inPlace?: boolean;
|
|
12
|
+
className?: string;
|
|
13
|
+
maxHeight?: string;
|
|
14
|
+
variant?: ModalVariant;
|
|
15
|
+
overflow?: 'visible' | 'hidden';
|
|
16
|
+
}
|
|
17
|
+
export declare const JRCModalLayout: React.ForwardRefExoticComponent<JRCModalLayoutProps & React.RefAttributes<HTMLDivElement>>;
|
package/build/src/components/JRCModal/{JRCModal.stories.d.ts → templates/JRCModal.stories.d.ts}
RENAMED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { JRCModalProps } from './JRCModal';
|
|
2
1
|
import { Meta, Story } from '@storybook/react';
|
|
3
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
3
|
export default _default;
|
|
5
|
-
export declare const Modal: Story<
|
|
4
|
+
export declare const Modal: Story<import("@storybook/react").Args>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { FormEvent, ForwardedRef, ReactNode } from 'react';
|
|
2
|
+
import { JRCModalButtonType } from '../JRCModalContent';
|
|
3
|
+
import { JRCModalFormButtonType } from '../JRCModalContentForm';
|
|
4
|
+
type JRCModalBaseProps = {
|
|
5
|
+
title?: ReactNode;
|
|
6
|
+
children?: ReactNode;
|
|
7
|
+
options?: ReactNode;
|
|
8
|
+
open: boolean;
|
|
9
|
+
closeHandler: () => void;
|
|
10
|
+
portalId?: string;
|
|
11
|
+
inPlace?: boolean;
|
|
12
|
+
ref?: ForwardedRef<HTMLDivElement>;
|
|
13
|
+
enableClickAwayCloseModal?: boolean;
|
|
14
|
+
};
|
|
15
|
+
export type JRCModalProps = JRCModalBaseProps & {
|
|
16
|
+
buttons?: JRCModalButtonType[];
|
|
17
|
+
};
|
|
18
|
+
export type JRCModalFormProps = JRCModalBaseProps & {
|
|
19
|
+
buttons?: JRCModalFormButtonType[];
|
|
20
|
+
onSubmit: (e: FormEvent) => Promise<void>;
|
|
21
|
+
loading?: boolean;
|
|
22
|
+
maxHeight?: string;
|
|
23
|
+
};
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { JRCModalFormProps } from './JRCModal.types';
|
|
3
|
+
export declare const JRCModalForm: ({ title, children, options, open, closeHandler, buttons, onSubmit, loading, portalId, inPlace, ref, enableClickAwayCloseModal, maxHeight, }: JRCModalFormProps) => React.JSX.Element;
|
|
@@ -9,4 +9,4 @@ export declare const SIZES: Readonly<{
|
|
|
9
9
|
xxl: 24;
|
|
10
10
|
xxxl: 32;
|
|
11
11
|
}>;
|
|
12
|
-
export declare const Typography: import("styled-components").StyledComponent<"p", import("styled-components").DefaultTheme, Pick<JRCTypographyProps, "color" | "size" | "
|
|
12
|
+
export declare const Typography: import("styled-components").StyledComponent<"p", import("styled-components").DefaultTheme, Pick<JRCTypographyProps, "color" | "size" | "weight" | "align"> & FastCssProps, never>;
|
package/build/src/index.d.ts
CHANGED
|
@@ -90,7 +90,7 @@ export { JRCImageStepper } from './components/Stepper/JRCImageStepper';
|
|
|
90
90
|
export { JRCImg } from './components/JRCImg/JRCImg';
|
|
91
91
|
export { JRCInputAudience } from './components/Form/Input/JRCSelect/JRCInputAudience';
|
|
92
92
|
export { JRCInputAutocomplete } from './components/Form/Input/JRCSelect/JRCInputAutocomplete';
|
|
93
|
-
export { JRCInputCheckbox } from './components/Form/Input/JRCInputCheckbox/JRCInputCheckbox';
|
|
93
|
+
export { JRCInputCheckbox, JRCInputCheckboxRaw } from './components/Form/Input/JRCInputCheckbox/JRCInputCheckbox';
|
|
94
94
|
export { JRCInputCommunity } from './components/Form/Input/JRCSelect/JRCAutocompleteCommunity';
|
|
95
95
|
export { JRCInputDate } from './components/Form/Input/JRCInputDate/JRCInputDate';
|
|
96
96
|
export { JRCInputEmail } from './components/Form/Input/JRCFormEmail/JRCInputEmail';
|
|
@@ -100,6 +100,7 @@ export { JRCInputReorderCheckbox } from './components/Form/Input/JRCInputCheckbo
|
|
|
100
100
|
export { JRCInputRichText } from './components/Form/Input/JRCInputRichText/JRCInputRichText';
|
|
101
101
|
export { JRCInputSearch } from './components/Form/Input/JRCInputSearch/JRCInputSearch';
|
|
102
102
|
export { JRCInputSelect } from './components/Form/Input/JRCSelect/JRCInputSelect';
|
|
103
|
+
export { JRCInputSelectRaw } from './components/Form/Input/JRCSelect/JRCInputSelect';
|
|
103
104
|
export { JRCInputSelectHierarchicalTree } from './components/Form/Input/JRCSelect/JRCInputSelectHierarchicalTree';
|
|
104
105
|
export { JRCInputSelectList } from './components/Form/Input/JRCSelect/JRCInputSelectList';
|
|
105
106
|
export { JRCInputTaxonomy } from './components/Form/Input/JRCSelect/JRCInputTaxonomy';
|
|
@@ -112,7 +113,11 @@ export { JRCList } from './components/JRCList/JRCList';
|
|
|
112
113
|
export { JRCLoader } from './components/JRCLoader/JRCLoader';
|
|
113
114
|
export { JRCMainColumn } from './components/Templates/JRCMainColumn';
|
|
114
115
|
export { JRCMenu } from './components/JRCMenu/JRCMenu';
|
|
115
|
-
export { JRCModal } from './components/JRCModal/JRCModal';
|
|
116
|
+
export { JRCModal } from './components/JRCModal/templates/JRCModal';
|
|
117
|
+
export { JRCModalForm } from './components/JRCModal/templates/JRCModalForm';
|
|
118
|
+
export { JRCModalLayout } from './components/JRCModal/JRCModalLayout';
|
|
119
|
+
export { JRCModalContent } from './components/JRCModal/JRCModalContent';
|
|
120
|
+
export { JRCModalContentForm } from './components/JRCModal/JRCModalContentForm';
|
|
116
121
|
export { JRCModalImg } from './components/JRCModalImg/JRCModalImg';
|
|
117
122
|
export { JRCPageNotLogged } from './components/Pages/JRCPageNotLogged';
|
|
118
123
|
export { JRCPagination } from './components/JRCPagination/JRCPagination';
|
package/build/src/types.d.ts
CHANGED
|
@@ -61,8 +61,11 @@ export { JRCLinkToProps, JRCStyledHrefProps } from './components/JRCHref/JRCHref
|
|
|
61
61
|
export { JRCListProps, PaginationPagination } from './components/JRCList/JRCList';
|
|
62
62
|
export { JRCLoaderProps } from './components/JRCLoader/JRCLoader';
|
|
63
63
|
export { JRCMenuProps, JRCMenuItemProps } from './components/JRCMenu/JRCMenu';
|
|
64
|
-
export {
|
|
64
|
+
export { JRCModalProps, JRCModalFormProps } from './components/JRCModal/templates/JRCModal.types';
|
|
65
|
+
export { JRCModalContentProps, JRCModalButtonType } from './components/JRCModal/JRCModalContent';
|
|
66
|
+
export { JRCModalContentFormProps, JRCModalFormButtonType } from './components/JRCModal/JRCModalContentForm';
|
|
65
67
|
export { JRCModalImgButtonType, JRCModalImgProps } from './components/JRCModalImg/JRCModalImg';
|
|
68
|
+
export { JRCModalLayoutProps } from './components/JRCModal/JRCModalLayout';
|
|
66
69
|
export { JRCPaginationProps } from './components/JRCPagination/JRCPagination';
|
|
67
70
|
export { JRCSkeletonLineProps } from './components/JRCSkeleton/JRCSkeletonLine';
|
|
68
71
|
export { JRCSkeletonSquareProps } from './components/JRCSkeleton/JRCSkeletonSquare';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jamespot-react-components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.152",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./build/jamespot-react-components.js",
|
|
6
6
|
"types": "./build/src/index.d.ts",
|
|
@@ -89,7 +89,7 @@
|
|
|
89
89
|
"chroma-js": "^2.1.1",
|
|
90
90
|
"classnames": "^2.3.1",
|
|
91
91
|
"dompurify": "^3.0.5",
|
|
92
|
-
"jamespot-user-api": "^1.0.
|
|
92
|
+
"jamespot-user-api": "^1.0.124",
|
|
93
93
|
"moment": "^2.29.1",
|
|
94
94
|
"react": "^17.x",
|
|
95
95
|
"react-beautiful-dnd": "^13.1.1",
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import React, { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
-
import { ButtonColors } from '../JRCButton/JRCButton';
|
|
3
|
-
import { ModalBorderRadius } from './JRCModal.styles';
|
|
4
|
-
/**
|
|
5
|
-
* Interface to provide Modal Buttons
|
|
6
|
-
* @member color button color ButtonColors
|
|
7
|
-
* @member isClosed optional boolean (default false). If true, when click on the button, the modal is closes
|
|
8
|
-
* @member clickHandler optional, callback when the button is click
|
|
9
|
-
* @member children default ReactNode children in the Modal content
|
|
10
|
-
*/
|
|
11
|
-
export interface JRCModalButtonType extends ComponentPropsWithoutRef<'button'> {
|
|
12
|
-
children: ReactNode;
|
|
13
|
-
color?: ButtonColors;
|
|
14
|
-
variant?: 'contained' | 'outlined';
|
|
15
|
-
isClosed?: boolean;
|
|
16
|
-
clickHandler?: (setLoading: (isLoading: boolean) => void) => Promise<void>;
|
|
17
|
-
dataCy?: string;
|
|
18
|
-
preventClose?: boolean;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Interface for JRCModal props
|
|
22
|
-
* @member open boolean that open or close the Modal
|
|
23
|
-
* @member closeHandler callback called when the Modal is closed
|
|
24
|
-
* @member buttons array of JRCModalButton possibly added to the Modal
|
|
25
|
-
* @member title optional string or JSX.Element (header content) if hasHeader= true
|
|
26
|
-
* @member showIconClose boolean to show/hide the close (x) button of the Modal
|
|
27
|
-
* @member enableClickAwayCloseModal boolean to enable the close of the Modal by Click Outside of Modal
|
|
28
|
-
* @member contentFull content without padding
|
|
29
|
-
* @member overflow allow overflow hidden (crop background for radius)
|
|
30
|
-
* @member radius border radius size
|
|
31
|
-
* @member children default ReactNode children in the Modal content
|
|
32
|
-
* @member portalId id attribute for createPortal
|
|
33
|
-
* @member inPlace if true, does not use a portal
|
|
34
|
-
* @member className use for overriding the styled-components styles
|
|
35
|
-
*/
|
|
36
|
-
export interface JRCModalProps {
|
|
37
|
-
open: boolean;
|
|
38
|
-
closeHandler: () => void;
|
|
39
|
-
buttons?: JRCModalButtonType[];
|
|
40
|
-
children?: ReactNode;
|
|
41
|
-
title?: React.ReactNode;
|
|
42
|
-
showIconClose?: boolean;
|
|
43
|
-
enableClickAwayCloseModal?: boolean;
|
|
44
|
-
contentFull?: boolean;
|
|
45
|
-
overflow?: 'hidden' | 'scroll' | 'visible';
|
|
46
|
-
radius?: ModalBorderRadius;
|
|
47
|
-
isFull?: boolean;
|
|
48
|
-
isFullHeight?: boolean;
|
|
49
|
-
isFullScreen?: boolean;
|
|
50
|
-
modalOptions?: ReactNode;
|
|
51
|
-
portalId?: string;
|
|
52
|
-
inPlace?: boolean;
|
|
53
|
-
className?: string;
|
|
54
|
-
maxHeight?: string;
|
|
55
|
-
}
|
|
56
|
-
export declare const JRCModal: React.ForwardRefExoticComponent<JRCModalProps & React.RefAttributes<HTMLDivElement>>;
|