Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 24 additions & 24 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@jimengio/files-picker",
"version": "0.0.3",
"version": "0.0.4-a1",
"description": "",
"main": "lib/index.js",
"scripts": {
Expand Down Expand Up @@ -28,48 +28,48 @@
},
"devDependencies": {
"@jimengio/ci-progress-webpack-plugin": "^0.1.0",
"@jimengio/doc-frame": "^0.1.12",
"@jimengio/flex-styles": "^0.1.6",
"@jimengio/jimo-basics": "^0.1.4",
"@jimengio/jimo-icons": "^0.3.10",
"@jimengio/router-code-generator": "^0.2.7",
"@jimengio/ruled-router": "^0.2.25",
"@types/node": "^14.0.1",
"@types/prettier": "^2.0.0",
"@types/react": "^16.9.35",
"@jimengio/doc-frame": "^0.1.13",
"@jimengio/flex-styles": "^0.2.0",
"@jimengio/jimo-basics": "^0.1.11",
"@jimengio/jimo-icons": "^0.3.14",
"@jimengio/router-code-generator": "^0.3.0",
"@jimengio/ruled-router": "^0.2.27",
"@types/node": "^14.6.4",
"@types/prettier": "^2.1.0",
"@types/react": "^16.9.49",
"@types/react-dom": "^16.9.8",
"antd": "3.x.x",
"antd": "4.6.3",
"cache-loader": "^4.1.0",
"css-loader": "^3.5.3",
"css-loader": "^4.2.2",
"duplicate-package-checker-webpack-plugin": "^3.0.0",
"emotion": "^10.0.27",
"file-loader": "^6.0.0",
"fork-ts-checker-webpack-plugin": "^5.0.2",
"html-webpack-plugin": "^4.2.2",
"file-loader": "^6.1.0",
"fork-ts-checker-webpack-plugin": "^5.1.0",
"html-webpack-plugin": "^4.4.1",
"html-webpack-tags-plugin": "^2.0.17",
"immer": "^7.0.1",
"mini-css-extract-plugin": "^0.9.0",
"prettier": "^2.0.5",
"immer": "^7.0.8",
"mini-css-extract-plugin": "^0.11.0",
"prettier": "^2.1.1",
"query-string": "^6.12.1",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"style-loader": "^1.2.1",
"thread-loader": "^2.1.3",
"ts-loader": "^7.0.4",
"ts-node": "^8.10.1",
"ts-loader": "^8.0.3",
"ts-node": "^9.0.0",
"tsconfig-paths": "^3.9.0",
"tsconfig-paths-webpack-plugin": "^3.2.0",
"typescript": "3.9.5",
"tsconfig-paths-webpack-plugin": "^3.3.0",
"typescript": "4.0.2",
"typescript-styled-plugin": "^0.15.0",
"url-loader": "^4.1.0",
"webpack": "^4.43.0",
"webpack": "^4.44.1",
"webpack-bundle-analyzer": "^3.7.0",
"webpack-cli": "^3.3.11",
"webpack-dev-server": "^3.11.0",
"webpack-hud": "^0.1.2"
},
"dependencies": {
"@jimengio/api-base": "^0.3.2",
"@jimengio/api-base": "^0.3.7",
"mime-types": "^2.1.27"
}
}
10 changes: 4 additions & 6 deletions src/component/base-display.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React, { FC } from "react";

import { css } from "emotion";
import { Icon } from "antd";
import { PaperClipOutlined, DownloadOutlined, DeleteOutlined } from "@ant-design/icons";
import { Space } from "@jimengio/flex-styles";
import { useDownloadApi } from "../hooks";
import { downloadAsFile } from "../util";
Expand All @@ -25,12 +25,11 @@ let BaseDisplay: FC<IProps> = React.memo((props) => {
const name = path.split("/")[2];
return (
<div key={index} className={style.fileDiv}>
<Icon type="paper-clip" />
<PaperClipOutlined />
<Space width={12} />
{name}
<div style={{ float: "right", textAlign: "right" }}>
<Icon
type="download"
<DownloadOutlined
className={style.mouse}
onClick={async () => {
const downloadUrl = await downloadingResource.startDownload(props.url, path);
Expand All @@ -40,8 +39,7 @@ let BaseDisplay: FC<IProps> = React.memo((props) => {
{readOnly ? null : (
<>
<Space width={15} />
<Icon
type="delete"
<DeleteOutlined
className={style.mouse}
onClick={() => {
onDel(path, name);
Expand Down
5 changes: 3 additions & 2 deletions src/component/base-upload.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import React, { FC, useRef, useEffect, useState } from "react";
import BaseDisplay from "./base-display";

import { css, cx } from "emotion";
import { Icon, Spin, message } from "antd";
import { Spin, message } from "antd";
import { ExclamationOutlined, UploadOutlined } from "@ant-design/icons";
import { useUploadApi } from "../hooks";

import { uploadingLocales } from "../config";
Expand Down Expand Up @@ -65,7 +66,7 @@ let BaseUpload: FC<IProps> = React.memo((props) => {
>
{isEdit ? null : (
<>
<Icon type={error ? "exclamation" : "upload"} /> {text ? text : uploadingLocales.uploadFile}
{error ? <ExclamationOutlined /> : <UploadOutlined />} {text ? text : uploadingLocales.uploadFile}
</>
)}
</div>
Expand Down
9 changes: 5 additions & 4 deletions src/component/dropzone.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import { css, cx } from "emotion";
import { center, column, Space, rowParted } from "@jimengio/flex-styles";

import UploadWrapper from "./upload-wrapper";
import { Icon, message } from "antd";
import { message } from "antd";
import { LinkOutlined, DownloadOutlined, CloseOutlined } from "@ant-design/icons";
import JimoIcon, { EJimoIcon } from "@jimengio/jimo-icons";

import { interpolateLocale } from "../util";
Expand Down Expand Up @@ -168,17 +169,17 @@ let Dropzone: FC<IProps> = React.memo((props) => {
return (
<div key={index} className={cx(rowParted, styleUploadItem)}>
<span>
<Icon type="link" />
<LinkOutlined />
<Space width={5} />
{item.name}
</span>
<span>
<span className={styleIcon} onClick={() => reqDownload(item.filePath)}>
<Icon type="download" />
<DownloadOutlined />
</span>
<Space width={10} />
<span className={styleIcon} onClick={() => delFile(item.filePath)}>
<Icon type="close" />
<CloseOutlined />
</span>
</span>
</div>
Expand Down
Loading