Skip to content

Commit 73c76df

Browse files
committed
[FIX]: added missing dependencies for build
1 parent 8ebb9ed commit 73c76df

File tree

18 files changed

+19426
-17115
lines changed

18 files changed

+19426
-17115
lines changed

build/components/dropzone/components/Dropzone/Dropzone.d.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React from "react";
1+
import * as React from "react";
22
import "./Dropzone.scss";
33
import { DropzoneProps } from "./DropzoneProps";
44
declare const Dropzone: React.FC<DropzoneProps>;
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { FC } from "react";
1+
import * as React from "react";
22
import { DropzoneFooterProps } from "./DropzoneFooterProps";
3-
declare const DropzoneFooter: FC<DropzoneFooterProps>;
3+
declare const DropzoneFooter: React.FC<DropzoneFooterProps>;
44
export default DropzoneFooter;
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
import { CSSProperties } from "react";
1+
import * as React from "react";
22
export interface IconProps {
33
size?: "micro" | "small" | "semi-medium" | "medium" | "large";
44
color?: string;
55
colorFill?: string;
66
onClick?: Function;
7-
style?: CSSProperties;
7+
style?: React.CSSProperties;
88
className?: string;
99
}

build/components/icons/Info/Info.d.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { FC } from "react";
1+
import * as React from "react";
22
import { InfoProps } from "./InfoProps";
3-
declare const Info: FC<InfoProps>;
3+
declare const Info: React.FC<InfoProps>;
44
export default Info;
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { FC } from "react";
1+
import * as React from "react";
22
import { VideoPreviewProps } from "./VideoPreviewProps";
33
import "./VideoPreview.scss";
4-
declare const VideoPreview: FC<VideoPreviewProps>;
4+
declare const VideoPreview: React.FC<VideoPreviewProps>;
55
export default VideoPreview;

build/index.es.js

+4-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/index.es.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/index.js

+4-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/index.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/utils/loader.d.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { FC } from "react";
1+
import * as React from "react";
22
interface loaderProps {
33
color?: string;
44
}
5-
declare const Loader: FC<loaderProps>;
5+
declare const Loader: React.FC<loaderProps>;
66
export default Loader;

package-lock.json

+19,368-17,057
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+5-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@dropzone-ui/react",
3-
"version": "6.7.10",
3+
"version": "6.7.12",
44
"description": "The best and most complete React library for managing file uploads. Multilanguage support. Server side support. Material design styles. Code generator on webpage.",
55
"main": "./build/index.js",
66
"module": "./build/index.es.js",
@@ -37,7 +37,9 @@
3737
},
3838
"homepage": "https://dropzone-ui.herokuapp.com/",
3939
"dependencies": {
40-
40+
"@dynamicss/dynamicss": "^2.2.2",
41+
"@unlimited-react-components/kernel": "^1.0.2",
42+
"@unlimited-react-components/material-button": "^1.2.8"
4143
},
4244
"peerDependencies": {
4345
"axios": "latest",
@@ -95,4 +97,4 @@
9597
"test": "jest",
9698
"test:coveralls": "jest --coverage && coveralls < coverage/lcov.info"
9799
}
98-
}
100+
}

src/components/dropzone/components/Dropzone/Dropzone.tsx

+14-14
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { mergeProps } from "@unlimited-react-components/kernel";
2-
import React, { useEffect, useRef, useState } from "react";
2+
import * as React from "react";
33
import "./Dropzone.scss";
44
import useDropzoneStyles from "../hooks/useDropzoneStyles";
55
import {
@@ -72,9 +72,9 @@ const Dropzone: React.FC<DropzoneProps> = (props: DropzoneProps) => {
7272
disableScroll,
7373
} = mergeProps(props, DropzonePropsDefault);
7474
//ref for ripple
75-
const dz_ui_ripple_ref = useRef<HTMLDivElement>(null);
75+
const dz_ui_ripple_ref = React.useRef<HTMLDivElement>(null);
7676
//re-validation: for development purposes and for preventing clean fileList in web page code generator
77-
useEffect(() => {
77+
React.useEffect(() => {
7878
if (files.length > 0) {
7979
let fileList: FileList = files.map((x) => x.file) as unknown as FileList;
8080
const remainingValids: number =
@@ -99,18 +99,18 @@ const Dropzone: React.FC<DropzoneProps> = (props: DropzoneProps) => {
9999
ValidateErrorLocalizerSelector(localization);
100100

101101
//ref to the hidden input tag
102-
const inputRef = useRef<HTMLInputElement>(null);
102+
const inputRef = React.useRef<HTMLInputElement>(null);
103103
// whether is draggin or not
104-
const [isDragging, setIsDragging] = useState<boolean>(false);
104+
const [isDragging, setIsDragging] = React.useState<boolean>(false);
105105
// list of files (local)
106-
const [files, setFiles] = useState<FileValidated[]>([]);
106+
const [files, setFiles] = React.useState<FileValidated[]>([]);
107107
const [localView, setLocalView] =
108-
useState<FileItemContainerProps["view"]>("grid");
109-
const [localMessage, setLocalMessage] = useState<string>("");
108+
React.useState<FileItemContainerProps["view"]>("grid");
109+
const [localMessage, setLocalMessage] = React.useState<string>("");
110110

111111
//ClassName for dynamic style
112-
const [onUploadingStart, setOnUploadingStart] = useState<boolean>(false);
113-
// const [queueFiles, setQueueFiles] = useState<FileValidated[]>([]);
112+
const [onUploadingStart, setOnUploadingStart] = React.useState<boolean>(false);
113+
// const [queueFiles, setQueueFiles] = React.useState<FileValidated[]>([]);
114114
// const offset:number= header && footer? 50: (!header && footer?23:(header && !footer?22:0)) ;
115115

116116
const classNameCreated: string = useDropzoneStyles(
@@ -125,21 +125,21 @@ const Dropzone: React.FC<DropzoneProps> = (props: DropzoneProps) => {
125125
}${clickable ? ` clickable` : ``}`;
126126

127127
//number of files
128-
const [numberOfValidFiles, setNumberOfValidFiles] = useState<number>(0);
129-
useEffect(() => {
128+
const [numberOfValidFiles, setNumberOfValidFiles] = React.useState<number>(0);
129+
React.useEffect(() => {
130130
if (value) {
131131
setFiles(value);
132132
setNumberOfValidFiles(value.filter((x: FileValidated) => x.valid).length);
133133
}
134134
}, [value]);
135-
useEffect(() => {
135+
React.useEffect(() => {
136136
if (disableScroll) {
137137
setLocalView("grid");
138138
} else if (view) {
139139
setLocalView(view);
140140
}
141141
}, [view, disableScroll]);
142-
useEffect(() => {
142+
React.useEffect(() => {
143143
if (uploadingMessage) {
144144
setLocalMessage(uploadingMessage);
145145
}

src/components/dropzone/components/DropzoneFooter.tsx/DropzoneFooter.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
import React, { FC } from "react";
1+
import * as React from "react";
22
import { DropzoneLocalizerSelector } from "../../../../localization";
33
import {
44
FunctionLabel,
55
LocalLabels,
66
} from "../../../../localization/localization";
77
import { DropzoneFooterProps } from "./DropzoneFooterProps";
88

9-
const DropzoneFooter: FC<DropzoneFooterProps> = (
9+
const DropzoneFooter: React.FC<DropzoneFooterProps> = (
1010
props: DropzoneFooterProps
1111
) => {
1212
const { accept, message, localization } = props;
+4-4
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
import { CSSProperties } from "react";
1+
import * as React from "react";
22

33
export interface IconProps {
4-
size?: "micro"|"small" |"semi-medium"| "medium" | "large";
4+
size?: "micro" | "small" | "semi-medium" | "medium" | "large";
55
color?: string;
66
colorFill?: string;
77
onClick?: Function;
8-
style?:CSSProperties;
9-
className?:string;
8+
style?: React.CSSProperties;
9+
className?: string;
1010
}

src/components/icons/Info/Info.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import React,{ FC } from "react";
1+
import * as React from "react";
22
import { InfoProps } from "./InfoProps";
33
import { parseSize } from "../utils/utils";
44

5-
const Info: FC<InfoProps> = (props: InfoProps) => {
5+
const Info: React.FC<InfoProps> = (props: InfoProps) => {
66
const { size, color, colorFill, onClick } = props;
77
const finalSize = parseSize(size);
88
return (

src/components/video-preview/VideoPreview.tsx

+8-10
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,14 @@
1-
import React, { FC, Fragment } from "react";
2-
import { useEffect } from "react";
3-
import { useState } from "react";
4-
import { useRef } from "react";
1+
import * as React from "react";
2+
53
import { Cancel } from "../icons";
64
import { VideoPreviewProps } from "./VideoPreviewProps";
75
import "./VideoPreview.scss";
8-
const VideoPreview: FC<VideoPreviewProps> = (props: VideoPreviewProps) => {
6+
const VideoPreview: React.FC<VideoPreviewProps> = (props: VideoPreviewProps) => {
97
const { videoSrc, openVideo, onClose, autoplay, controls, style } = props;
10-
const videoRef = useRef<HTMLVideoElement>(null);
11-
const [source, setSource] = useState<string | undefined>(undefined);
8+
const videoRef = React.useRef<HTMLVideoElement>(null);
9+
const [source, setSource] = React.useState<string | undefined>(undefined);
1210

13-
useEffect(() => {
11+
React.useEffect(() => {
1412
//if not undefined
1513
if (!videoSrc) {
1614
return;
@@ -31,7 +29,7 @@ const VideoPreview: FC<VideoPreviewProps> = (props: VideoPreviewProps) => {
3129
}
3230
}
3331
}, [videoSrc]);
34-
useEffect(() => {
32+
React.useEffect(() => {
3533
if (source && videoRef.current) {
3634
videoRef.current.load();
3735
}
@@ -89,7 +87,7 @@ const VideoPreview: FC<VideoPreviewProps> = (props: VideoPreviewProps) => {
8987
</div>
9088
);
9189
} else {
92-
return <Fragment></Fragment>;
90+
return <React.Fragment></React.Fragment>;
9391
}
9492
};
9593
export default VideoPreview;

src/utils/loader.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import { hexColorToRGB } from "@unlimited-react-components/kernel";
2-
import React, { FC } from "react";
2+
import * as React from "react";
33
interface loaderProps{
44
color?:string ;
55
}
6-
const Loader: FC<loaderProps> = (props: loaderProps) => {
6+
const Loader: React.FC<loaderProps> = (props: loaderProps) => {
77
const {color="#8b6b10"}=props;
88
return (
99
<svg

0 commit comments

Comments
 (0)