jamespot-react-components 1.0.161 → 1.0.163
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 +544 -548
- package/build/jamespot-react-components.js.LICENSE.txt +0 -30
- package/build/jamespot-react-components.js.map +1 -1
- package/build/src/components/Editors/components/EditorInputCheckbox.d.ts +11 -0
- package/build/src/components/Form/Input/JRCInputTinyMCE/JRCInputTinyMCE.d.ts +3 -2
- package/build/src/components/Form/Input/JRCInputTinyMCE/JRCTinyMCEFileUploadModal.d.ts +8 -0
- package/build/src/components/JRCCropImage/JRCCropImage.d.ts +8 -5
- package/build/src/components/Widgets/JRCWidgetSlider/JRCWidgetSlider.d.ts +10 -0
- package/build/src/components/Widgets/JRCWidgetSlider/JRCWidgetSlider.stories.d.ts +5 -0
- package/build/src/components/Widgets/JRCWidgetSlider/JRCWidgetSliderEditor.d.ts +21 -0
- package/build/src/components/Widgets/JRCWidgetSlider/components/SliderArrows.d.ts +10 -0
- package/build/src/components/Widgets/JRCWidgetSlider/components/SliderDots.d.ts +12 -0
- package/build/src/components/Widgets/JRCWidgetSlider/components/SliderImage.d.ts +6 -0
- package/build/src/components/Widgets/JRCWidgetSlider/components/SliderSlideTitle.d.ts +3 -0
- package/build/src/components/Widgets/JRCWidgetSlider/mock.d.ts +2 -0
- package/build/src/components/Widgets/JRCWidgetSlider/types.d.ts +16 -0
- package/build/src/components/Widgets/JRCWidgetSlider/utils.d.ts +2 -0
- package/build/src/index.d.ts +1 -0
- package/build/src/types.d.ts +1 -1
- package/build/src/utils/utils.color.d.ts +2 -0
- package/package.json +3 -3
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare const CSSInputWrapper: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
3
|
+
export declare const EditorInputCheckbox: ({ label, initialValue, options, onChange, }: {
|
|
4
|
+
label: string;
|
|
5
|
+
initialValue: string[];
|
|
6
|
+
options: {
|
|
7
|
+
label: string;
|
|
8
|
+
value: string;
|
|
9
|
+
}[];
|
|
10
|
+
onChange: (value: string[]) => void;
|
|
11
|
+
}) => React.JSX.Element;
|
|
@@ -6,12 +6,13 @@ import { DataCy } from '../../../../types/dataAttributes';
|
|
|
6
6
|
declare global {
|
|
7
7
|
const tinymce: any;
|
|
8
8
|
}
|
|
9
|
-
export type
|
|
9
|
+
export type TinyMention = {
|
|
10
10
|
type: 'autocompleteitem';
|
|
11
11
|
value: string;
|
|
12
12
|
text: string;
|
|
13
13
|
icon?: string;
|
|
14
|
-
}
|
|
14
|
+
};
|
|
15
|
+
export type MentionQuery = (query: string) => Promise<TinyMention[]>;
|
|
15
16
|
export type JRCInputTinyMCEProps = DataCy & {
|
|
16
17
|
token?: string;
|
|
17
18
|
commonOptions: TinyMCECommonOptions;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
type JRCTinyMCEFileUploadModalProps = {
|
|
3
|
+
closeHandler: () => void;
|
|
4
|
+
open: boolean;
|
|
5
|
+
token?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const JRCTinyMCEFileUploadModal: ({ open, closeHandler, token }: JRCTinyMCEFileUploadModalProps) => React.JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { Area as _Area, Point as _Point, Size as _Size } from 'react-easy-crop/types';
|
|
3
2
|
import { JRCModalProps } from '../JRCModal/templates/JRCModal.types';
|
|
4
|
-
|
|
5
|
-
export type
|
|
6
|
-
|
|
3
|
+
import 'react-image-crop/dist/ReactCrop.css';
|
|
4
|
+
export type Area = {
|
|
5
|
+
width: number;
|
|
6
|
+
height: number;
|
|
7
|
+
x: number;
|
|
8
|
+
y: number;
|
|
9
|
+
};
|
|
7
10
|
export type JRCCropImageProps = Pick<JRCModalProps, 'open' | 'closeHandler'> & {
|
|
8
11
|
aspectRatio?: number | undefined;
|
|
9
12
|
allowCustomRatio?: boolean;
|
|
@@ -13,4 +16,4 @@ export type JRCCropImageProps = Pick<JRCModalProps, 'open' | 'closeHandler'> & {
|
|
|
13
16
|
}) => void;
|
|
14
17
|
zIndex?: number;
|
|
15
18
|
};
|
|
16
|
-
export declare function JRCCropImage(props: JRCCropImageProps): React.JSX.Element;
|
|
19
|
+
export declare function JRCCropImage({ save, ...props }: JRCCropImageProps): React.JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WidgetSliderSlide } from './types';
|
|
3
|
+
export type JRCWidgetSliderProps = {
|
|
4
|
+
slides: WidgetSliderSlide[];
|
|
5
|
+
maxWidth: number;
|
|
6
|
+
loop: boolean;
|
|
7
|
+
useDots?: boolean;
|
|
8
|
+
startAt?: number;
|
|
9
|
+
};
|
|
10
|
+
export declare const JRCWidgetSlider: ({ slides, maxWidth, loop, useDots, startAt, }: JRCWidgetSliderProps) => React.JSX.Element;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { JRCWidgetSliderEditorProps, WidgetSliderSlide } from './types';
|
|
3
|
+
export declare const CSSSlide: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
4
|
+
export declare const CSSSlideTitle: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
5
|
+
export declare const JRCWidgetSliderEditor: ({ slides, loop, useDots, onChange, onSave, }: JRCWidgetSliderEditorProps & {
|
|
6
|
+
onSave: (content: Partial<JRCWidgetSliderEditorProps>) => void;
|
|
7
|
+
onChange: (content: Partial<JRCWidgetSliderEditorProps>, override?: boolean) => void;
|
|
8
|
+
}) => React.JSX.Element;
|
|
9
|
+
export declare const EditorSlide: ({ initialSlide, onSave, onClickDelete, }: {
|
|
10
|
+
initialSlide: WidgetSliderSlide;
|
|
11
|
+
onSave: (slide: WidgetSliderSlide) => void;
|
|
12
|
+
onClickDelete: () => void;
|
|
13
|
+
}) => React.JSX.Element;
|
|
14
|
+
/**
|
|
15
|
+
* TODO: STANDALONE COMPONENT
|
|
16
|
+
*/
|
|
17
|
+
export declare const DeleteWithPrompt: ({ title, description, onClick, }: {
|
|
18
|
+
title: string;
|
|
19
|
+
description?: string | undefined;
|
|
20
|
+
onClick: () => void;
|
|
21
|
+
}) => React.JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
type SliderArrowsProps = {
|
|
3
|
+
step: number;
|
|
4
|
+
total: number;
|
|
5
|
+
loop: boolean;
|
|
6
|
+
onClickPrev: () => void;
|
|
7
|
+
onClickNext: () => void;
|
|
8
|
+
};
|
|
9
|
+
export declare const SliderArrows: ({ step, total, loop, onClickPrev, onClickNext }: SliderArrowsProps) => React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare function neighborValue(index: number, step: number, range: number, rangeDecreaseValue?: number): number;
|
|
3
|
+
/**
|
|
4
|
+
* TODO: STANDALONE COMPONENT
|
|
5
|
+
*/
|
|
6
|
+
export declare const SliderDots: ({ step, steps, range, rangeDecreaseValue, onClick, }: {
|
|
7
|
+
step: number;
|
|
8
|
+
steps: number;
|
|
9
|
+
range?: number | undefined;
|
|
10
|
+
rangeDecreaseValue?: number | undefined;
|
|
11
|
+
onClick: (index: number) => void;
|
|
12
|
+
}) => React.JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { TVariants } from 'components/JRCTypography/JRCTypography.d';
|
|
2
|
+
export type WidgetSliderSlide = {
|
|
3
|
+
title: string;
|
|
4
|
+
titleHeading: TVariants;
|
|
5
|
+
text: string;
|
|
6
|
+
textColor: string;
|
|
7
|
+
opacityFilter: number;
|
|
8
|
+
opacityColor: string;
|
|
9
|
+
uri: string;
|
|
10
|
+
};
|
|
11
|
+
export type JRCWidgetSliderEditorProps = {
|
|
12
|
+
slides: WidgetSliderSlide[];
|
|
13
|
+
loop: boolean;
|
|
14
|
+
useDots?: boolean;
|
|
15
|
+
startAt?: number;
|
|
16
|
+
};
|
package/build/src/index.d.ts
CHANGED
|
@@ -136,6 +136,7 @@ export { JRCTag } from './components/JRCTag/JRCTag';
|
|
|
136
136
|
export { JRCTemplateBase } from './components/Templates/JRCBase.template';
|
|
137
137
|
export { JRCTemplateTwoColumns } from './components/Templates/JRCTwoColumns.template';
|
|
138
138
|
export { JRCThemeProvider } from './components/JRCThemeProvider/JRCThemeProvider';
|
|
139
|
+
export { JRCTinyMCEFileUploadModal } from './components/Form/Input/JRCInputTinyMCE/JRCTinyMCEFileUploadModal';
|
|
139
140
|
export { JRCTinyMCEImageUploadModal } from './components/Form/Input/JRCInputTinyMCE/JRCTinyMCEImageUploadModal';
|
|
140
141
|
export { JRCTinyMCEVideoUploadModal } from './components/Form/Input/JRCInputTinyMCE/JRCTinyMCEVideoUploadModal';
|
|
141
142
|
export { JRCTooltip } from './components/JRCTooltip/JRCTooltip';
|
package/build/src/types.d.ts
CHANGED
|
@@ -78,7 +78,7 @@ export type { JRCTypographyProps } from './components/JRCTypography/JRCTypograph
|
|
|
78
78
|
export type { JRCValidationButtonProps } from './components/JRCButton/JRCValidationButton';
|
|
79
79
|
export type { JRCValueLabelProps } from './components/Form/Common/types';
|
|
80
80
|
export type { JRCWritableFormInputProps } from './components/Form/Input/JRCFormFieldRender';
|
|
81
|
-
export type { MentionQuery } from './components/Form/Input/JRCInputTinyMCE/JRCInputTinyMCE';
|
|
81
|
+
export type { MentionQuery, TinyMention } from './components/Form/Input/JRCInputTinyMCE/JRCInputTinyMCE';
|
|
82
82
|
export type { MessageType } from './components/Common/util/getColor.util';
|
|
83
83
|
export type { TextareaFormInputProps } from './components/Form/Input/JRCFormTextarea/JRCFormTextarea';
|
|
84
84
|
export type { ThemeConfigOptions, ThemeType } from './styles/theme';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jamespot-react-components",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.163",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./build/jamespot-react-components.js",
|
|
6
6
|
"types": "./build/src/index.d.ts",
|
|
@@ -92,15 +92,15 @@
|
|
|
92
92
|
"chroma-js": "^2.1.1",
|
|
93
93
|
"classnames": "^2.3.1",
|
|
94
94
|
"dompurify": "^3.0.5",
|
|
95
|
-
"jamespot-user-api": "^1.0.
|
|
95
|
+
"jamespot-user-api": "^1.0.133",
|
|
96
96
|
"moment": "2.29.4",
|
|
97
97
|
"react": "^17.x",
|
|
98
98
|
"react-beautiful-dnd": "^13.1.1",
|
|
99
99
|
"react-dnd": "^14.0.4",
|
|
100
100
|
"react-dnd-html5-backend": "^14.0.2",
|
|
101
101
|
"react-dom": "^17.0.2",
|
|
102
|
-
"react-easy-crop": "^4.6.3",
|
|
103
102
|
"react-hook-form": "^7.25.0",
|
|
103
|
+
"react-image-crop": "^11.0.4",
|
|
104
104
|
"react-intl": "^5.8.6",
|
|
105
105
|
"react-redux": "^7.2.9",
|
|
106
106
|
"react-router-dom": "^6.2.1",
|