This commit is contained in:
CHEVALLIER Abel
2025-11-13 16:23:22 +01:00
parent de9c515a47
commit cb235644dc
34924 changed files with 3811102 additions and 0 deletions

261
node_modules/ng-zorro-antd/upload/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,261 @@
import * as i0 from '@angular/core';
import { TemplateRef, OnInit, ElementRef, OnChanges, AfterViewInit, EventEmitter } from '@angular/core';
import { Observable, Subscription } from 'rxjs';
import { NzSafeAny, IndexableObject, BooleanInput } from 'ng-zorro-antd/core/types';
import { Direction } from '@angular/cdk/bidi';
import { NzUploadI18nInterface } from 'ng-zorro-antd/i18n';
/**
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE
*/
/** Status */
type UploadFileStatus = 'error' | 'success' | 'done' | 'uploading' | 'removed';
type NzUploadType = 'select' | 'drag';
/** Built-in styles of the uploading list. */
type NzUploadListType = 'text' | 'picture' | 'picture-card';
interface NzUploadFile {
uid: string;
size?: number;
name: string;
filename?: string;
lastModified?: string;
lastModifiedDate?: Date;
url?: string;
status?: UploadFileStatus;
originFileObj?: File;
percent?: number;
thumbUrl?: string;
response?: NzSafeAny;
error?: NzSafeAny;
linkProps?: {
download: string;
};
type?: string;
[key: string]: NzSafeAny;
}
interface NzUploadChangeParam {
file: NzUploadFile;
fileList: NzUploadFile[];
event?: {
percent: number;
};
/** Callback type. */
type?: string;
}
interface NzShowUploadList {
showRemoveIcon?: boolean;
showPreviewIcon?: boolean;
showDownloadIcon?: boolean;
}
/**
* @deprecated will be removed in v22.0.0
* Use `NzBeforeUploadFileType` instead.
*/
type NzUploadTransformFileType = string | Blob | NzUploadFile | Observable<string | Blob | File>;
type NzBeforeUploadFileType = boolean | Observable<boolean | NzUploadFile | Blob | File | boolean> | Promise<boolean | NzUploadFile | Blob | File | boolean>;
interface ZipButtonOptions {
disabled?: boolean;
accept?: string | string[];
action?: string | ((file: NzUploadFile) => string | Observable<string>);
directory?: boolean;
openFileDialogOnClick?: boolean;
beforeUpload?(file: NzUploadFile, fileList: NzUploadFile[]): NzBeforeUploadFileType;
customRequest?(item: NzSafeAny): Subscription;
data?: {} | ((file: NzUploadFile) => {} | Observable<{}>);
headers?: {} | ((file: NzUploadFile) => {} | Observable<{}>);
name?: string;
multiple?: boolean;
withCredentials?: boolean;
filters?: UploadFilter[];
transformFile?(file: NzUploadFile): NzUploadTransformFileType;
onStart?(file: NzUploadFile): void;
onProgress?(e: NzSafeAny, file: NzUploadFile): void;
onSuccess?(ret: NzSafeAny, file: NzUploadFile, xhr: NzSafeAny): void;
onError?(err: NzSafeAny, file: NzUploadFile): void;
}
interface UploadFilter {
name: string;
fn(fileList: NzUploadFile[]): NzUploadFile[] | Observable<NzUploadFile[]>;
}
interface NzUploadXHRArgs {
action?: string;
name?: string;
headers?: IndexableObject;
file: NzUploadFile;
postFile: string | Blob | File | NzUploadFile;
data?: IndexableObject;
withCredentials?: boolean;
onProgress?(e: NzSafeAny, file: NzUploadFile): void;
onSuccess?(ret: NzSafeAny, file: NzUploadFile, xhr: NzSafeAny): void;
onError?(err: NzSafeAny, file: NzUploadFile): void;
}
type NzIconRenderTemplate = TemplateRef<{
$implicit: NzUploadFile;
}>;
declare class NzUploadBtnComponent implements OnInit {
reqs: Record<string, Subscription>;
private destroyed;
file: ElementRef<HTMLInputElement>;
options: ZipButtonOptions;
onClick(): void;
onFileDrop(e: DragEvent): void;
onChange(e: Event): void;
private traverseFileTree;
private attrAccept;
private attachUid;
uploadFiles(fileList: FileList | File[]): void;
private upload;
private post;
private xhr;
private clean;
abort(file?: NzUploadFile): void;
private http;
private elementRef;
private destroyRef;
constructor();
ngOnInit(): void;
static ɵfac: i0.ɵɵFactoryDeclaration<NzUploadBtnComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<NzUploadBtnComponent, "[nz-upload-btn]", ["nzUploadBtn"], { "options": { "alias": "options"; "required": false; }; }, {}, never, ["*"], true, never>;
}
type UploadListIconType = '' | 'uploading' | 'thumbnail';
interface UploadListFile extends NzUploadFile {
isImageUrl?: boolean;
isUploading?: boolean;
iconType?: UploadListIconType;
showDownload?: boolean;
}
declare class NzUploadListComponent implements OnChanges {
list: UploadListFile[];
private get showPic();
locale: NzSafeAny;
listType: NzUploadListType;
set items(list: NzUploadFile[]);
icons: NzShowUploadList;
onPreview?: (file: NzUploadFile) => void;
onRemove: (file: NzUploadFile) => void;
onDownload?: (file: NzUploadFile) => void;
previewFile?: (file: NzUploadFile) => Observable<string>;
previewIsImage?: (file: NzUploadFile) => boolean;
iconRender: NzIconRenderTemplate | null;
dir: Direction;
private document;
private destroyRef;
private ngZone;
private cdr;
private platform;
private genErr;
private extname;
isImageUrl(file: NzUploadFile): boolean;
private getIconType;
private previewImage;
private genThumb;
private showDownload;
private fixData;
handlePreview(file: NzUploadFile, e: Event): void;
handleRemove(file: NzUploadFile, e: Event): void;
handleDownload(file: NzUploadFile): void;
detectChanges(): void;
ngOnChanges(): void;
static ɵfac: i0.ɵɵFactoryDeclaration<NzUploadListComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<NzUploadListComponent, "nz-upload-list", ["nzUploadList"], { "locale": { "alias": "locale"; "required": false; }; "listType": { "alias": "listType"; "required": false; }; "items": { "alias": "items"; "required": false; }; "icons": { "alias": "icons"; "required": false; }; "onPreview": { "alias": "onPreview"; "required": false; }; "onRemove": { "alias": "onRemove"; "required": false; }; "onDownload": { "alias": "onDownload"; "required": false; }; "previewFile": { "alias": "previewFile"; "required": false; }; "previewIsImage": { "alias": "previewIsImage"; "required": false; }; "iconRender": { "alias": "iconRender"; "required": false; }; "dir": { "alias": "dir"; "required": false; }; }, {}, never, never, true, never>;
}
/**
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://github.com/NG-ZORRO/ng-zorro-antd/blob/master/LICENSE
*/
declare class NzUploadComponent implements OnInit, AfterViewInit, OnChanges {
static ngAcceptInputType_nzShowUploadList: BooleanInput | NzShowUploadList;
private cdr;
private i18n;
private directionality;
private destroyRef;
uploadComp: NzUploadBtnComponent;
listComp: NzUploadListComponent;
locale: NzUploadI18nInterface;
dir: Direction;
nzType: NzUploadType;
nzLimit: number;
nzSize: number;
nzFileType?: string;
nzAccept?: string | string[];
nzAction?: string | ((file: NzUploadFile) => string | Observable<string>);
nzDirectory: boolean;
nzOpenFileDialogOnClick: boolean;
nzBeforeUpload?: (file: NzUploadFile, fileList: NzUploadFile[]) => NzBeforeUploadFileType;
nzCustomRequest?: (item: NzUploadXHRArgs) => Subscription;
nzData?: {} | ((file: NzUploadFile) => {} | Observable<{}>);
nzFilter: UploadFilter[];
nzFileList: NzUploadFile[];
nzDisabled: boolean;
nzHeaders?: {} | ((file: NzUploadFile) => {} | Observable<{}>);
nzListType: NzUploadListType;
nzMultiple: boolean;
nzName: string;
private _showUploadList;
private document;
set nzShowUploadList(value: boolean | NzShowUploadList);
get nzShowUploadList(): boolean | NzShowUploadList;
nzShowButton: boolean;
nzWithCredentials: boolean;
nzRemove?: (file: NzUploadFile) => boolean | Observable<boolean>;
nzPreview?: (file: NzUploadFile) => void;
nzPreviewFile?: (file: NzUploadFile) => Observable<string>;
nzPreviewIsImage?: (file: NzUploadFile) => boolean;
/**
* @deprecated will be removed in v22.0.0
* Use `nzBeforeUpload` instead.
*/
nzTransformFile?: (file: NzUploadFile) => NzUploadTransformFileType;
nzDownload?: (file: NzUploadFile) => void;
nzIconRender: NzIconRenderTemplate | null;
nzFileListRender: TemplateRef<{
$implicit: NzUploadFile[];
}> | null;
readonly nzChange: EventEmitter<NzUploadChangeParam>;
readonly nzFileListChange: EventEmitter<NzUploadFile[]>;
_btnOptions?: ZipButtonOptions;
private zipOptions;
private readonly platform;
private fileToObject;
private getFileItem;
private removeFileItem;
private onStart;
private onProgress;
private onSuccess;
private onError;
private dragState?;
fileDrop(e: DragEvent): void;
private detectChangesList;
onRemove: (file: NzUploadFile) => void;
private prefixCls;
classList: string[];
private setClassMap;
ngOnInit(): void;
ngAfterViewInit(): void;
ngOnChanges(): void;
static ɵfac: i0.ɵɵFactoryDeclaration<NzUploadComponent, never>;
static ɵcmp: i0.ɵɵComponentDeclaration<NzUploadComponent, "nz-upload", ["nzUpload"], { "nzType": { "alias": "nzType"; "required": false; }; "nzLimit": { "alias": "nzLimit"; "required": false; }; "nzSize": { "alias": "nzSize"; "required": false; }; "nzFileType": { "alias": "nzFileType"; "required": false; }; "nzAccept": { "alias": "nzAccept"; "required": false; }; "nzAction": { "alias": "nzAction"; "required": false; }; "nzDirectory": { "alias": "nzDirectory"; "required": false; }; "nzOpenFileDialogOnClick": { "alias": "nzOpenFileDialogOnClick"; "required": false; }; "nzBeforeUpload": { "alias": "nzBeforeUpload"; "required": false; }; "nzCustomRequest": { "alias": "nzCustomRequest"; "required": false; }; "nzData": { "alias": "nzData"; "required": false; }; "nzFilter": { "alias": "nzFilter"; "required": false; }; "nzFileList": { "alias": "nzFileList"; "required": false; }; "nzDisabled": { "alias": "nzDisabled"; "required": false; }; "nzHeaders": { "alias": "nzHeaders"; "required": false; }; "nzListType": { "alias": "nzListType"; "required": false; }; "nzMultiple": { "alias": "nzMultiple"; "required": false; }; "nzName": { "alias": "nzName"; "required": false; }; "nzShowUploadList": { "alias": "nzShowUploadList"; "required": false; }; "nzShowButton": { "alias": "nzShowButton"; "required": false; }; "nzWithCredentials": { "alias": "nzWithCredentials"; "required": false; }; "nzRemove": { "alias": "nzRemove"; "required": false; }; "nzPreview": { "alias": "nzPreview"; "required": false; }; "nzPreviewFile": { "alias": "nzPreviewFile"; "required": false; }; "nzPreviewIsImage": { "alias": "nzPreviewIsImage"; "required": false; }; "nzTransformFile": { "alias": "nzTransformFile"; "required": false; }; "nzDownload": { "alias": "nzDownload"; "required": false; }; "nzIconRender": { "alias": "nzIconRender"; "required": false; }; "nzFileListRender": { "alias": "nzFileListRender"; "required": false; }; }, { "nzChange": "nzChange"; "nzFileListChange": "nzFileListChange"; }, never, ["*"], true, never>;
static ngAcceptInputType_nzLimit: unknown;
static ngAcceptInputType_nzSize: unknown;
static ngAcceptInputType_nzDirectory: unknown;
static ngAcceptInputType_nzOpenFileDialogOnClick: unknown;
static ngAcceptInputType_nzDisabled: unknown;
static ngAcceptInputType_nzMultiple: unknown;
static ngAcceptInputType_nzShowButton: unknown;
static ngAcceptInputType_nzWithCredentials: unknown;
}
declare class NzUploadModule {
static ɵfac: i0.ɵɵFactoryDeclaration<NzUploadModule, never>;
static ɵmod: i0.ɵɵNgModuleDeclaration<NzUploadModule, never, [typeof NzUploadComponent, typeof NzUploadBtnComponent, typeof NzUploadListComponent], [typeof NzUploadComponent]>;
static ɵinj: i0.ɵɵInjectorDeclaration<NzUploadModule>;
}
export { NzUploadBtnComponent, NzUploadComponent, NzUploadListComponent, NzUploadModule };
export type { NzBeforeUploadFileType, NzIconRenderTemplate, NzShowUploadList, NzUploadChangeParam, NzUploadFile, NzUploadListType, NzUploadTransformFileType, NzUploadType, NzUploadXHRArgs, UploadFileStatus, UploadFilter, ZipButtonOptions };

3
node_modules/ng-zorro-antd/upload/package.json generated vendored Normal file
View File

@@ -0,0 +1,3 @@
{
"module": "../fesm2022/ng-zorro-antd-upload.mjs"
}

5
node_modules/ng-zorro-antd/upload/style/entry.less generated vendored Normal file
View File

@@ -0,0 +1,5 @@
@import './index.less';
// style dependencies
@import '../../progress/style/entry.less';
@import '../../tooltip/style/entry.less';
@import './patch.less';

995
node_modules/ng-zorro-antd/upload/style/index.css generated vendored Normal file
View File

@@ -0,0 +1,995 @@
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
/* stylelint-disable no-duplicate-selectors */
.ant-upload {
box-sizing: border-box;
margin: 0;
padding: 0;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
font-variant: tabular-nums;
line-height: 1.5715;
list-style: none;
font-feature-settings: 'tnum';
outline: 0;
}
.ant-upload p {
margin: 0;
}
.ant-upload-btn {
display: block;
width: 100%;
outline: none;
}
.ant-upload input[type='file'] {
cursor: pointer;
}
.ant-upload.ant-upload-select {
display: inline-block;
}
.ant-upload.ant-upload-disabled {
color: rgba(0, 0, 0, 0.25);
cursor: not-allowed;
}
.ant-upload.ant-upload-select-picture-card {
width: 104px;
height: 104px;
margin-right: 8px;
margin-bottom: 8px;
text-align: center;
vertical-align: top;
background-color: #fafafa;
border: 1px dashed #d9d9d9;
border-radius: 2px;
cursor: pointer;
transition: border-color 0.3s;
}
.ant-upload.ant-upload-select-picture-card > .ant-upload {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
text-align: center;
}
.ant-upload.ant-upload-select-picture-card:hover {
border-color: #1890ff;
}
.ant-upload-disabled.ant-upload.ant-upload-select-picture-card:hover {
border-color: #d9d9d9;
}
.ant-upload.ant-upload-drag {
position: relative;
width: 100%;
height: 100%;
text-align: center;
background: #fafafa;
border: 1px dashed #d9d9d9;
border-radius: 2px;
cursor: pointer;
transition: border-color 0.3s;
}
.ant-upload.ant-upload-drag .ant-upload {
padding: 16px 0;
}
.ant-upload.ant-upload-drag.ant-upload-drag-hover:not(.ant-upload-disabled) {
border-color: #096dd9;
}
.ant-upload.ant-upload-drag.ant-upload-disabled {
cursor: not-allowed;
}
.ant-upload.ant-upload-drag .ant-upload-btn {
display: table;
height: 100%;
}
.ant-upload.ant-upload-drag .ant-upload-drag-container {
display: table-cell;
vertical-align: middle;
}
.ant-upload.ant-upload-drag:not(.ant-upload-disabled):hover {
border-color: #40a9ff;
}
.ant-upload.ant-upload-drag p.ant-upload-drag-icon {
margin-bottom: 20px;
}
.ant-upload.ant-upload-drag p.ant-upload-drag-icon .anticon {
color: #40a9ff;
font-size: 48px;
}
.ant-upload.ant-upload-drag p.ant-upload-text {
margin: 0 0 4px;
color: rgba(0, 0, 0, 0.85);
font-size: 16px;
}
.ant-upload.ant-upload-drag p.ant-upload-hint {
color: rgba(0, 0, 0, 0.45);
font-size: 14px;
}
.ant-upload.ant-upload-drag .anticon-plus {
color: rgba(0, 0, 0, 0.25);
font-size: 30px;
transition: all 0.3s;
}
.ant-upload.ant-upload-drag .anticon-plus:hover {
color: rgba(0, 0, 0, 0.45);
}
.ant-upload.ant-upload-drag:hover .anticon-plus {
color: rgba(0, 0, 0, 0.45);
}
.ant-upload-picture-card-wrapper {
display: inline-block;
width: 100%;
}
.ant-upload-picture-card-wrapper::before {
display: table;
content: '';
}
.ant-upload-picture-card-wrapper::after {
display: table;
clear: both;
content: '';
}
.ant-upload-list {
box-sizing: border-box;
margin: 0;
padding: 0;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
font-variant: tabular-nums;
list-style: none;
font-feature-settings: 'tnum';
line-height: 1.5715;
}
.ant-upload-list::before {
display: table;
content: '';
}
.ant-upload-list::after {
display: table;
clear: both;
content: '';
}
.ant-upload-list-item {
position: relative;
height: 22.001px;
margin-top: 8px;
font-size: 14px;
}
.ant-upload-list-item-name {
display: inline-block;
width: 100%;
padding-left: 22px;
overflow: hidden;
line-height: 1.5715;
white-space: nowrap;
text-overflow: ellipsis;
}
.ant-upload-list-item-card-actions {
position: absolute;
right: 0;
}
.ant-upload-list-item-card-actions-btn {
opacity: 0;
}
.ant-upload-list-item-card-actions-btn.ant-btn-sm {
height: 22.001px;
line-height: 1;
vertical-align: top;
}
.ant-upload-list-item-card-actions.picture {
top: 22px;
line-height: 0;
}
.ant-upload-list-item-card-actions-btn:focus,
.ant-upload-list-item-card-actions.picture .ant-upload-list-item-card-actions-btn {
opacity: 1;
}
.ant-upload-list-item-card-actions .anticon {
color: rgba(0, 0, 0, 0.45);
transition: all 0.3s;
}
.ant-upload-list-item-card-actions:hover .anticon {
color: rgba(0, 0, 0, 0.85);
}
.ant-upload-list-item-info {
height: 100%;
transition: background-color 0.3s;
}
.ant-upload-list-item-info > span {
display: block;
width: 100%;
height: 100%;
}
.ant-upload-list-item-info .anticon-loading .anticon,
.ant-upload-list-item-info .ant-upload-text-icon .anticon {
position: absolute;
top: 5px;
color: rgba(0, 0, 0, 0.45);
font-size: 14px;
}
.ant-upload-list-item:hover .ant-upload-list-item-info {
background-color: #f5f5f5;
}
.ant-upload-list-item:hover .ant-upload-list-item-card-actions-btn {
opacity: 1;
}
.ant-upload-list-item-error,
.ant-upload-list-item-error .ant-upload-text-icon > .anticon,
.ant-upload-list-item-error .ant-upload-list-item-name {
color: #ff4d4f;
}
.ant-upload-list-item-error .ant-upload-list-item-card-actions .anticon {
color: #ff4d4f;
}
.ant-upload-list-item-error .ant-upload-list-item-card-actions-btn {
opacity: 1;
}
.ant-upload-list-item-progress {
position: absolute;
bottom: -12px;
width: 100%;
padding-left: 26px;
font-size: 14px;
line-height: 0;
}
.ant-upload-list-picture .ant-upload-list-item,
.ant-upload-list-picture-card .ant-upload-list-item {
position: relative;
height: 66px;
padding: 8px;
border: 1px solid #d9d9d9;
border-radius: 2px;
}
.ant-upload-list-picture .ant-upload-list-item:hover,
.ant-upload-list-picture-card .ant-upload-list-item:hover {
background: transparent;
}
.ant-upload-list-picture .ant-upload-list-item-error,
.ant-upload-list-picture-card .ant-upload-list-item-error {
border-color: #ff4d4f;
}
.ant-upload-list-picture .ant-upload-list-item-info,
.ant-upload-list-picture-card .ant-upload-list-item-info {
padding: 0;
}
.ant-upload-list-picture .ant-upload-list-item:hover .ant-upload-list-item-info,
.ant-upload-list-picture-card .ant-upload-list-item:hover .ant-upload-list-item-info {
background: transparent;
}
.ant-upload-list-picture .ant-upload-list-item-uploading,
.ant-upload-list-picture-card .ant-upload-list-item-uploading {
border-style: dashed;
}
.ant-upload-list-picture .ant-upload-list-item-thumbnail,
.ant-upload-list-picture-card .ant-upload-list-item-thumbnail {
width: 48px;
height: 48px;
line-height: 60px;
text-align: center;
opacity: 0.8;
}
.ant-upload-list-picture .ant-upload-list-item-thumbnail .anticon,
.ant-upload-list-picture-card .ant-upload-list-item-thumbnail .anticon {
font-size: 26px;
}
.ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#e6f7ff'],
.ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#e6f7ff'] {
fill: #fff2f0;
}
.ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#1890ff'],
.ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#1890ff'] {
fill: #ff4d4f;
}
.ant-upload-list-picture .ant-upload-list-item-icon,
.ant-upload-list-picture-card .ant-upload-list-item-icon {
position: absolute;
top: 50%;
left: 50%;
font-size: 26px;
transform: translate(-50%, -50%);
}
.ant-upload-list-picture .ant-upload-list-item-icon .anticon,
.ant-upload-list-picture-card .ant-upload-list-item-icon .anticon {
font-size: 26px;
}
.ant-upload-list-picture .ant-upload-list-item-image,
.ant-upload-list-picture-card .ant-upload-list-item-image {
max-width: 100%;
}
.ant-upload-list-picture .ant-upload-list-item-thumbnail img,
.ant-upload-list-picture-card .ant-upload-list-item-thumbnail img {
display: block;
width: 48px;
height: 48px;
overflow: hidden;
}
.ant-upload-list-picture .ant-upload-list-item-name,
.ant-upload-list-picture-card .ant-upload-list-item-name {
display: inline-block;
box-sizing: border-box;
max-width: 100%;
margin: 0 0 0 8px;
padding-right: 8px;
padding-left: 48px;
overflow: hidden;
line-height: 44px;
white-space: nowrap;
text-overflow: ellipsis;
transition: all 0.3s;
}
.ant-upload-list-picture .ant-upload-list-item-uploading .ant-upload-list-item-name,
.ant-upload-list-picture-card .ant-upload-list-item-uploading .ant-upload-list-item-name {
margin-bottom: 12px;
}
.ant-upload-list-picture .ant-upload-list-item-progress,
.ant-upload-list-picture-card .ant-upload-list-item-progress {
bottom: 14px;
width: calc(100% - 24px);
margin-top: 0;
padding-left: 56px;
}
.ant-upload-list-picture-card-container {
display: inline-block;
width: 104px;
height: 104px;
margin: 0 8px 8px 0;
vertical-align: top;
}
.ant-upload-list-picture-card .ant-upload-list-item {
height: 100%;
margin: 0;
}
.ant-upload-list-picture-card .ant-upload-list-item-info {
position: relative;
height: 100%;
overflow: hidden;
}
.ant-upload-list-picture-card .ant-upload-list-item-info::before {
position: absolute;
z-index: 1;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.5);
opacity: 0;
transition: all 0.3s;
content: ' ';
}
.ant-upload-list-picture-card .ant-upload-list-item:hover .ant-upload-list-item-info::before {
opacity: 1;
}
.ant-upload-list-picture-card .ant-upload-list-item-actions {
position: absolute;
top: 50%;
left: 50%;
z-index: 10;
white-space: nowrap;
transform: translate(-50%, -50%);
opacity: 0;
transition: all 0.3s;
}
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-eye,
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-download,
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-delete {
z-index: 10;
width: 16px;
margin: 0 4px;
color: rgba(255, 255, 255, 0.85);
font-size: 16px;
cursor: pointer;
transition: all 0.3s;
}
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-eye:hover,
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-download:hover,
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-delete:hover {
color: #fff;
}
.ant-upload-list-picture-card .ant-upload-list-item-info:hover + .ant-upload-list-item-actions,
.ant-upload-list-picture-card .ant-upload-list-item-actions:hover {
opacity: 1;
}
.ant-upload-list-picture-card .ant-upload-list-item-thumbnail,
.ant-upload-list-picture-card .ant-upload-list-item-thumbnail img {
position: static;
display: block;
width: 100%;
height: 100%;
object-fit: contain;
}
.ant-upload-list-picture-card .ant-upload-list-item-name {
display: none;
margin: 8px 0 0;
padding: 0;
line-height: 1.5715;
text-align: center;
}
.ant-upload-list-picture-card .ant-upload-list-item-file + .ant-upload-list-item-name {
position: absolute;
bottom: 10px;
display: block;
}
.ant-upload-list-picture-card .ant-upload-list-item-uploading.ant-upload-list-item {
background-color: #fafafa;
}
.ant-upload-list-picture-card .ant-upload-list-item-uploading .ant-upload-list-item-info {
height: auto;
}
.ant-upload-list-picture-card .ant-upload-list-item-uploading .ant-upload-list-item-info::before,
.ant-upload-list-picture-card .ant-upload-list-item-uploading .ant-upload-list-item-info .anticon-eye,
.ant-upload-list-picture-card .ant-upload-list-item-uploading .ant-upload-list-item-info .anticon-delete {
display: none;
}
.ant-upload-list-picture-card .ant-upload-list-item-progress {
bottom: 32px;
width: calc(100% - 14px);
padding-left: 0;
}
.ant-upload-list-text-container,
.ant-upload-list-picture-container {
transition: opacity 0.3s, height 0.3s;
}
.ant-upload-list-text-container::before,
.ant-upload-list-picture-container::before {
display: table;
width: 0;
height: 0;
content: '';
}
.ant-upload-list-text-container .ant-upload-span,
.ant-upload-list-picture-container .ant-upload-span {
display: block;
flex: auto;
}
.ant-upload-list-text .ant-upload-span,
.ant-upload-list-picture .ant-upload-span {
display: flex;
align-items: center;
}
.ant-upload-list-text .ant-upload-span > *,
.ant-upload-list-picture .ant-upload-span > * {
flex: none;
}
.ant-upload-list-text .ant-upload-list-item-name,
.ant-upload-list-picture .ant-upload-list-item-name {
flex: auto;
margin: 0;
padding: 0 8px;
}
.ant-upload-list-text .ant-upload-list-item-card-actions,
.ant-upload-list-picture .ant-upload-list-item-card-actions {
position: static;
}
.ant-upload-list-text .ant-upload-text-icon .anticon {
position: static;
}
.ant-upload-list .ant-upload-animate-inline-appear,
.ant-upload-list .ant-upload-animate-inline-enter,
.ant-upload-list .ant-upload-animate-inline-leave {
animation-duration: 0.3s;
animation-timing-function: cubic-bezier(0.78, 0.14, 0.15, 0.86);
animation-fill-mode: forwards;
}
.ant-upload-list .ant-upload-animate-inline-appear,
.ant-upload-list .ant-upload-animate-inline-enter {
animation-name: uploadAnimateInlineIn;
}
.ant-upload-list .ant-upload-animate-inline-leave {
animation-name: uploadAnimateInlineOut;
}
@keyframes uploadAnimateInlineIn {
from {
width: 0;
height: 0;
margin: 0;
padding: 0;
opacity: 0;
}
}
@keyframes uploadAnimateInlineOut {
to {
width: 0;
height: 0;
margin: 0;
padding: 0;
opacity: 0;
}
}
.ant-upload-rtl {
direction: rtl;
}
.ant-upload-rtl.ant-upload.ant-upload-select-picture-card {
margin-right: auto;
margin-left: 8px;
}
.ant-upload-list-rtl {
direction: rtl;
}
.ant-upload-list-rtl .ant-upload-list-item-list-type-text:hover .ant-upload-list-item-name-icon-count-1 {
padding-right: 22px;
padding-left: 14px;
}
.ant-upload-list-rtl .ant-upload-list-item-list-type-text:hover .ant-upload-list-item-name-icon-count-2 {
padding-right: 22px;
padding-left: 28px;
}
.ant-upload-list-rtl .ant-upload-list-item-name {
padding-right: 22px;
padding-left: 0;
}
.ant-upload-list-rtl .ant-upload-list-item-name-icon-count-1 {
padding-left: 14px;
}
.ant-upload-list-rtl .ant-upload-list-item-card-actions {
right: auto;
left: 0;
}
.ant-upload-list-rtl .ant-upload-list-item-card-actions .anticon {
padding-right: 0;
padding-left: 5px;
}
.ant-upload-list-rtl .ant-upload-list-item-info {
padding: 0 4px 0 12px;
}
.ant-upload-list-rtl .ant-upload-list-item-error .ant-upload-list-item-card-actions .anticon {
padding-right: 0;
padding-left: 5px;
}
.ant-upload-list-rtl .ant-upload-list-item-progress {
padding-right: 26px;
padding-left: 0;
}
.ant-upload-list-picture .ant-upload-list-item-info,
.ant-upload-list-picture-card .ant-upload-list-item-info {
padding: 0;
}
.ant-upload-list-rtl.ant-upload-list-picture .ant-upload-list-item-thumbnail,
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-thumbnail {
right: 8px;
left: auto;
}
.ant-upload-list-rtl.ant-upload-list-picture .ant-upload-list-item-icon,
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-icon {
right: 50%;
left: auto;
transform: translate(50%, -50%);
}
.ant-upload-list-rtl.ant-upload-list-picture .ant-upload-list-item-name,
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-name {
margin: 0 8px 0 0;
padding-right: 48px;
padding-left: 8px;
}
.ant-upload-list-rtl.ant-upload-list-picture .ant-upload-list-item-name-icon-count-1,
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-name-icon-count-1 {
padding-right: 48px;
padding-left: 18px;
}
.ant-upload-list-rtl.ant-upload-list-picture .ant-upload-list-item-name-icon-count-2,
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-name-icon-count-2 {
padding-right: 48px;
padding-left: 36px;
}
.ant-upload-list-rtl.ant-upload-list-picture .ant-upload-list-item-progress,
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-progress {
padding-right: 0;
padding-left: 0;
}
.ant-upload-list-rtl .ant-upload-list-picture-card-container {
margin: 0 0 8px 8px;
}
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-actions {
right: 50%;
left: auto;
transform: translate(50%, -50%);
}
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item-file + .ant-upload-list-item-name {
margin: 8px 0 0;
padding: 0;
}
.ant-progress {
box-sizing: border-box;
margin: 0;
padding: 0;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
font-variant: tabular-nums;
line-height: 1.5715;
list-style: none;
font-feature-settings: 'tnum';
display: inline-block;
}
.ant-progress-line {
position: relative;
width: 100%;
font-size: 14px;
}
.ant-progress-steps {
display: inline-block;
}
.ant-progress-steps-outer {
display: flex;
flex-direction: row;
align-items: center;
}
.ant-progress-steps-item {
flex-shrink: 0;
min-width: 2px;
margin-right: 2px;
background: #f3f3f3;
transition: all 0.3s;
}
.ant-progress-steps-item-active {
background: #1890ff;
}
.ant-progress-small.ant-progress-line,
.ant-progress-small.ant-progress-line .ant-progress-text .anticon {
font-size: 12px;
}
.ant-progress-outer {
display: inline-block;
width: 100%;
margin-right: 0;
padding-right: 0;
}
.ant-progress-show-info .ant-progress-outer {
margin-right: calc(-2em - 8px);
padding-right: calc(2em + 8px);
}
.ant-progress-inner {
position: relative;
display: inline-block;
width: 100%;
overflow: hidden;
vertical-align: middle;
background-color: #f5f5f5;
border-radius: 100px;
}
.ant-progress-circle-trail {
stroke: #f5f5f5;
}
.ant-progress-circle-path {
animation: ant-progress-appear 0.3s;
}
.ant-progress-inner:not(.ant-progress-circle-gradient) .ant-progress-circle-path {
stroke: #1890ff;
}
.ant-progress-success-bg,
.ant-progress-bg {
position: relative;
background-color: #1890ff;
border-radius: 100px;
transition: all 0.4s cubic-bezier(0.08, 0.82, 0.17, 1) 0s;
}
.ant-progress-success-bg {
position: absolute;
top: 0;
left: 0;
background-color: #52c41a;
}
.ant-progress-text {
display: inline-block;
width: 2em;
margin-left: 8px;
color: rgba(0, 0, 0, 0.85);
font-size: 1em;
line-height: 1;
white-space: nowrap;
text-align: left;
vertical-align: middle;
word-break: normal;
}
.ant-progress-text .anticon {
font-size: 14px;
}
.ant-progress-status-active .ant-progress-bg::before {
position: absolute;
top: 0;
right: 0;
bottom: 0;
left: 0;
background: #fff;
border-radius: 10px;
opacity: 0;
animation: ant-progress-active 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite;
content: '';
}
.ant-progress-status-exception .ant-progress-bg {
background-color: #ff4d4f;
}
.ant-progress-status-exception .ant-progress-text {
color: #ff4d4f;
}
.ant-progress-status-exception .ant-progress-inner:not(.ant-progress-circle-gradient) .ant-progress-circle-path {
stroke: #ff4d4f;
}
.ant-progress-status-success .ant-progress-bg {
background-color: #52c41a;
}
.ant-progress-status-success .ant-progress-text {
color: #52c41a;
}
.ant-progress-status-success .ant-progress-inner:not(.ant-progress-circle-gradient) .ant-progress-circle-path {
stroke: #52c41a;
}
.ant-progress-circle .ant-progress-inner {
position: relative;
line-height: 1;
background-color: transparent;
}
.ant-progress-circle .ant-progress-text {
position: absolute;
top: 50%;
left: 50%;
width: 100%;
margin: 0;
padding: 0;
color: rgba(0, 0, 0, 0.85);
font-size: 1em;
line-height: 1;
white-space: normal;
text-align: center;
transform: translate(-50%, -50%);
}
.ant-progress-circle .ant-progress-text .anticon {
font-size: 1.16666667em;
}
.ant-progress-circle.ant-progress-status-exception .ant-progress-text {
color: #ff4d4f;
}
.ant-progress-circle.ant-progress-status-success .ant-progress-text {
color: #52c41a;
}
@keyframes ant-progress-active {
0% {
transform: translateX(-100%) scaleX(0);
opacity: 0.1;
}
20% {
transform: translateX(-100%) scaleX(0);
opacity: 0.5;
}
100% {
transform: translateX(0) scaleX(1);
opacity: 0;
}
}
.ant-progress-rtl {
direction: rtl;
}
.ant-progress-rtl.ant-progress-show-info .ant-progress-outer {
margin-right: 0;
margin-left: calc(-2em - 8px);
padding-right: 0;
padding-left: calc(2em + 8px);
}
.ant-progress-rtl .ant-progress-success-bg {
right: 0;
left: auto;
}
.ant-progress-rtl.ant-progress-line .ant-progress-text,
.ant-progress-rtl.ant-progress-steps .ant-progress-text {
margin-right: 8px;
margin-left: 0;
text-align: right;
}
.ant-tooltip {
box-sizing: border-box;
margin: 0;
padding: 0;
color: rgba(0, 0, 0, 0.85);
font-size: 14px;
font-variant: tabular-nums;
line-height: 1.5715;
list-style: none;
font-feature-settings: 'tnum';
--antd-arrow-background-color: rgba(0, 0, 0, 0.75);
position: absolute;
z-index: 1070;
display: block;
width: max-content;
max-width: 250px;
visibility: visible;
}
.ant-tooltip-content {
position: relative;
}
.ant-tooltip-hidden {
display: none;
}
.ant-tooltip-inner {
min-width: 30px;
min-height: 32px;
padding: calc(12px / 2) 8px;
color: #fff;
text-align: start;
text-decoration: none;
word-wrap: break-word;
background-color: rgba(0, 0, 0, 0.75);
border-radius: 2px;
box-shadow: 0 3px 6px -4px rgba(0, 0, 0, 0.12), 0 6px 16px 0 rgba(0, 0, 0, 0.08), 0 9px 28px 8px rgba(0, 0, 0, 0.05);
}
.ant-tooltip-arrow {
position: absolute;
z-index: 1;
display: block;
width: 16px;
height: 16px;
overflow: hidden;
pointer-events: none;
}
.ant-tooltip-arrow::before {
position: absolute;
bottom: 0;
width: 16px;
height: calc(16px / 2);
background: var(--antd-arrow-background-color);
content: '';
clip-path: polygon(1.65685425px 100%, 50% 1.65685425px, 14.34314575px 100%, 1.65685425px 100%);
clip-path: path('M 0 8 A 4 4 0 0 0 2.82842712474619 6.82842712474619 L 6.585786437626905 3.0710678118654755 A 2 2 0 0 1 9.414213562373096 3.0710678118654755 L 13.17157287525381 6.82842712474619 A 4 4 0 0 0 16 8 Z');
inset-inline-start: 0;
}
.ant-tooltip-arrow::after {
position: absolute;
bottom: 0;
z-index: 0;
width: 8.97056275px;
height: 8.97056275px;
margin: auto;
background: transparent;
border-radius: 0 0 2px;
box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.05);
transform: translateY(50%) rotate(-135deg);
content: '';
inset-inline: 0;
}
.ant-tooltip-arrow::before {
background: var(--antd-arrow-background-color);
}
.ant-tooltip-placement-top > .ant-tooltip-arrow,
.ant-tooltip-placement-topLeft > .ant-tooltip-arrow,
.ant-tooltip-placement-topRight > .ant-tooltip-arrow {
bottom: 0px;
transform: translateY(100%) rotate(180deg);
}
.ant-tooltip-placement-top > .ant-tooltip-arrow {
left: 50%;
transform: translateX(-50%) translateY(100%) rotate(180deg);
}
.ant-tooltip-placement-topLeft > .ant-tooltip-arrow {
left: 16px;
}
.ant-tooltip-placement-topRight > .ant-tooltip-arrow {
right: 16px;
}
.ant-tooltip-placement-bottom > .ant-tooltip-arrow,
.ant-tooltip-placement-bottomLeft > .ant-tooltip-arrow,
.ant-tooltip-placement-bottomRight > .ant-tooltip-arrow {
top: 0px;
transform: translateY(-100%);
}
.ant-tooltip-placement-bottom > .ant-tooltip-arrow {
left: 50%;
transform: translateX(-50%) translateY(-100%);
}
.ant-tooltip-placement-bottomLeft > .ant-tooltip-arrow {
left: 16px;
}
.ant-tooltip-placement-bottomRight > .ant-tooltip-arrow {
right: 16px;
}
.ant-tooltip-placement-left > .ant-tooltip-arrow,
.ant-tooltip-placement-leftTop > .ant-tooltip-arrow,
.ant-tooltip-placement-leftBottom > .ant-tooltip-arrow {
right: 0px;
transform: translateX(100%) rotate(90deg);
}
.ant-tooltip-placement-left > .ant-tooltip-arrow {
top: 50%;
transform: translateY(-50%) translateX(100%) rotate(90deg);
}
.ant-tooltip-placement-leftTop > .ant-tooltip-arrow {
top: 16px;
}
.ant-tooltip-placement-leftBottom > .ant-tooltip-arrow {
bottom: 16px;
}
.ant-tooltip-placement-right > .ant-tooltip-arrow,
.ant-tooltip-placement-rightTop > .ant-tooltip-arrow,
.ant-tooltip-placement-rightBottom > .ant-tooltip-arrow {
left: 0px;
transform: translateX(-100%) rotate(-90deg);
}
.ant-tooltip-placement-right > .ant-tooltip-arrow {
top: 50%;
transform: translateY(-50%) translateX(-100%) rotate(-90deg);
}
.ant-tooltip-placement-rightTop > .ant-tooltip-arrow {
top: 16px;
}
.ant-tooltip-placement-rightBottom > .ant-tooltip-arrow {
bottom: 16px;
}
.ant-tooltip-pink .ant-tooltip-inner {
background-color: #eb2f96;
}
.ant-tooltip-pink .ant-tooltip-arrow {
--antd-arrow-background-color: #eb2f96;
}
.ant-tooltip-magenta .ant-tooltip-inner {
background-color: #eb2f96;
}
.ant-tooltip-magenta .ant-tooltip-arrow {
--antd-arrow-background-color: #eb2f96;
}
.ant-tooltip-red .ant-tooltip-inner {
background-color: #f5222d;
}
.ant-tooltip-red .ant-tooltip-arrow {
--antd-arrow-background-color: #f5222d;
}
.ant-tooltip-volcano .ant-tooltip-inner {
background-color: #fa541c;
}
.ant-tooltip-volcano .ant-tooltip-arrow {
--antd-arrow-background-color: #fa541c;
}
.ant-tooltip-orange .ant-tooltip-inner {
background-color: #fa8c16;
}
.ant-tooltip-orange .ant-tooltip-arrow {
--antd-arrow-background-color: #fa8c16;
}
.ant-tooltip-yellow .ant-tooltip-inner {
background-color: #fadb14;
}
.ant-tooltip-yellow .ant-tooltip-arrow {
--antd-arrow-background-color: #fadb14;
}
.ant-tooltip-gold .ant-tooltip-inner {
background-color: #faad14;
}
.ant-tooltip-gold .ant-tooltip-arrow {
--antd-arrow-background-color: #faad14;
}
.ant-tooltip-cyan .ant-tooltip-inner {
background-color: #13c2c2;
}
.ant-tooltip-cyan .ant-tooltip-arrow {
--antd-arrow-background-color: #13c2c2;
}
.ant-tooltip-lime .ant-tooltip-inner {
background-color: #a0d911;
}
.ant-tooltip-lime .ant-tooltip-arrow {
--antd-arrow-background-color: #a0d911;
}
.ant-tooltip-green .ant-tooltip-inner {
background-color: #52c41a;
}
.ant-tooltip-green .ant-tooltip-arrow {
--antd-arrow-background-color: #52c41a;
}
.ant-tooltip-blue .ant-tooltip-inner {
background-color: #1890ff;
}
.ant-tooltip-blue .ant-tooltip-arrow {
--antd-arrow-background-color: #1890ff;
}
.ant-tooltip-geekblue .ant-tooltip-inner {
background-color: #2f54eb;
}
.ant-tooltip-geekblue .ant-tooltip-arrow {
--antd-arrow-background-color: #2f54eb;
}
.ant-tooltip-purple .ant-tooltip-inner {
background-color: #722ed1;
}
.ant-tooltip-purple .ant-tooltip-arrow {
--antd-arrow-background-color: #722ed1;
}
.ant-tooltip-rtl {
direction: rtl;
}
.ant-tooltip {
position: relative;
}
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item {
float: unset;
}

565
node_modules/ng-zorro-antd/upload/style/index.less generated vendored Normal file
View File

@@ -0,0 +1,565 @@
@import '../../style/themes/index';
@import '../../style/mixins/index';
@upload-prefix-cls: ~'@{ant-prefix}-upload';
@upload-item: ~'@{ant-prefix}-upload-list-item';
@upload-picture-card-size: 104px;
@upload-picture-card-border-style: @border-style-base;
.@{upload-prefix-cls} {
.reset-component();
outline: 0;
p {
margin: 0;
}
&-btn {
display: block;
width: 100%;
outline: none;
}
input[type='file'] {
cursor: pointer;
}
&&-select {
display: inline-block;
}
&&-disabled {
color: @disabled-color;
cursor: not-allowed;
}
&&-select-picture-card {
width: @upload-picture-card-size;
height: @upload-picture-card-size;
margin-right: 8px;
margin-bottom: 8px;
text-align: center;
vertical-align: top;
background-color: @background-color-light;
border: @border-width-base dashed @border-color-base;
border-radius: @border-radius-base;
cursor: pointer;
transition: border-color 0.3s;
> .@{upload-prefix-cls} {
display: flex;
align-items: center;
justify-content: center;
height: 100%;
text-align: center;
}
&:hover {
border-color: @primary-color;
.@{upload-prefix-cls}-disabled& {
border-color: @border-color-base;
}
}
}
&&-drag {
position: relative;
width: 100%;
height: 100%;
text-align: center;
background: @background-color-light;
border: @border-width-base dashed @border-color-base;
border-radius: @border-radius-base;
cursor: pointer;
transition: border-color 0.3s;
.@{upload-prefix-cls} {
padding: @padding-md 0;
}
&.@{upload-prefix-cls}-drag-hover:not(.@{upload-prefix-cls}-disabled) {
border-color: @primary-7;
}
&.@{upload-prefix-cls}-disabled {
cursor: not-allowed;
}
.@{upload-prefix-cls}-btn {
display: table;
height: 100%;
}
.@{upload-prefix-cls}-drag-container {
display: table-cell;
vertical-align: middle;
}
&:not(.@{upload-prefix-cls}-disabled):hover {
border-color: @primary-5;
}
p.@{upload-prefix-cls}-drag-icon {
.@{iconfont-css-prefix} {
color: @primary-5;
font-size: 48px;
}
margin-bottom: 20px;
}
p.@{upload-prefix-cls}-text {
margin: 0 0 4px;
color: @heading-color;
font-size: @font-size-lg;
}
p.@{upload-prefix-cls}-hint {
color: @text-color-secondary;
font-size: @font-size-base;
}
.@{iconfont-css-prefix}-plus {
color: @disabled-color;
font-size: 30px;
transition: all 0.3s;
&:hover {
color: @text-color-secondary;
}
}
&:hover .@{iconfont-css-prefix}-plus {
color: @text-color-secondary;
}
}
&-picture-card-wrapper {
.clearfix();
display: inline-block;
width: 100%;
}
}
.@{upload-prefix-cls}-list {
.reset-component();
.clearfix();
line-height: @line-height-base;
// ============================ Item ============================
&-item {
position: relative;
height: @line-height-base * @font-size-base;
margin-top: @margin-xs;
font-size: @font-size-base;
&-name {
display: inline-block;
width: 100%;
padding-left: @font-size-base + 8px;
overflow: hidden;
line-height: @line-height-base;
white-space: nowrap;
text-overflow: ellipsis;
}
&-card-actions {
position: absolute;
right: 0;
&-btn {
opacity: 0;
}
&-btn.@{ant-prefix}-btn-sm {
height: @line-height-base * @font-size-base;
line-height: 1;
vertical-align: top;
}
&.picture {
top: 22px;
line-height: 0;
}
&-btn:focus,
&.picture &-btn {
opacity: 1;
}
.@{iconfont-css-prefix} {
color: @upload-actions-color;
transition: all 0.3s;
}
&:hover .@{iconfont-css-prefix} {
color: @text-color;
}
}
&-info {
height: 100%;
transition: background-color 0.3s;
> span {
display: block;
width: 100%;
height: 100%;
}
.@{iconfont-css-prefix}-loading,
.@{upload-prefix-cls}-text-icon {
.@{iconfont-css-prefix} {
position: absolute;
top: (@font-size-base / 2) - 2px;
color: @text-color-secondary;
font-size: @font-size-base;
}
}
}
&:hover &-info {
background-color: @item-hover-bg;
}
&:hover &-card-actions-btn {
opacity: 1;
}
&-error,
&-error .@{upload-prefix-cls}-text-icon > .@{iconfont-css-prefix},
&-error &-name {
color: @error-color;
}
&-error &-card-actions {
.@{iconfont-css-prefix} {
color: @error-color;
}
&-btn {
opacity: 1;
}
}
&-progress {
position: absolute;
bottom: -12px;
width: 100%;
padding-left: @font-size-base + 12px;
font-size: @font-size-base;
line-height: 0;
}
}
// =================== Picture & Picture Card ===================
&-picture,
&-picture-card {
.@{upload-item} {
position: relative;
height: 66px;
padding: @padding-xs;
border: @border-width-base @upload-picture-card-border-style @border-color-base;
border-radius: @border-radius-base;
&:hover {
background: transparent;
}
&-error {
border-color: @error-color;
}
}
.@{upload-item}-info {
padding: 0;
}
.@{upload-item}:hover .@{upload-item}-info {
background: transparent;
}
.@{upload-item}-uploading {
border-style: dashed;
}
.@{upload-item}-thumbnail {
width: 48px;
height: 48px;
line-height: 60px;
text-align: center;
opacity: 0.8;
.@{iconfont-css-prefix} {
font-size: 26px;
}
}
// Adjust the color of the error icon : https://github.com/ant-design/ant-design/pull/24160
.@{upload-item}-error .@{upload-item}-thumbnail {
.@{iconfont-css-prefix} {
svg path {
&[fill='#e6f7ff'] {
fill: @error-color-deprecated-bg;
}
&[fill='#1890ff'] {
fill: @error-color;
}
}
}
}
.@{upload-item}-icon {
position: absolute;
top: 50%;
left: 50%;
font-size: 26px;
transform: translate(-50%, -50%);
.@{iconfont-css-prefix} {
font-size: 26px;
}
}
.@{upload-item}-image {
max-width: 100%;
}
.@{upload-item}-thumbnail img {
display: block;
width: 48px;
height: 48px;
overflow: hidden;
}
.@{upload-item}-name {
display: inline-block;
box-sizing: border-box;
max-width: 100%;
margin: 0 0 0 8px;
padding-right: 8px;
padding-left: 48px;
overflow: hidden;
line-height: 44px;
white-space: nowrap;
text-overflow: ellipsis;
transition: all 0.3s;
}
.@{upload-item}-uploading .@{upload-item}-name {
margin-bottom: 12px;
}
.@{upload-item}-progress {
bottom: 14px;
width: ~'calc(100% - 24px)';
margin-top: 0;
padding-left: 56px;
}
}
// ======================== Picture Card ========================
&-picture-card {
&-container {
display: inline-block;
width: @upload-picture-card-size;
height: @upload-picture-card-size;
margin: 0 @margin-xs @margin-xs 0;
vertical-align: top;
}
.@{upload-item} {
height: 100%;
margin: 0;
}
.@{upload-item}-info {
position: relative;
height: 100%;
overflow: hidden;
&::before {
position: absolute;
z-index: 1;
width: 100%;
height: 100%;
background-color: fade(@black, 50%);
opacity: 0;
transition: all 0.3s;
content: ' ';
}
}
.@{upload-item}:hover .@{upload-item}-info::before {
opacity: 1;
}
.@{upload-item}-actions {
position: absolute;
top: 50%;
left: 50%;
z-index: 10;
white-space: nowrap;
transform: translate(-50%, -50%);
opacity: 0;
transition: all 0.3s;
.@{iconfont-css-prefix}-eye,
.@{iconfont-css-prefix}-download,
.@{iconfont-css-prefix}-delete {
z-index: 10;
width: 16px;
margin: 0 4px;
color: @text-color-dark;
font-size: 16px;
cursor: pointer;
transition: all 0.3s;
&:hover {
color: @text-color-inverse;
}
}
}
.@{upload-item}-info:hover + .@{upload-item}-actions,
.@{upload-item}-actions:hover {
opacity: 1;
}
.@{upload-item}-thumbnail,
.@{upload-item}-thumbnail img {
position: static;
display: block;
width: 100%;
height: 100%;
object-fit: contain;
}
.@{upload-item}-name {
display: none;
margin: 8px 0 0;
padding: 0;
line-height: @line-height-base;
text-align: center;
}
.@{upload-item}-file + .@{upload-item}-name {
position: absolute;
bottom: 10px;
display: block;
}
.@{upload-item}-uploading {
&.@{upload-item} {
background-color: @background-color-light;
}
.@{upload-item}-info {
height: auto;
&::before,
.@{iconfont-css-prefix}-eye,
.@{iconfont-css-prefix}-delete {
display: none;
}
}
}
.@{upload-item}-progress {
bottom: 32px;
width: calc(100% - 14px);
padding-left: 0;
}
}
// ======================= Picture & Text =======================
&-text,
&-picture {
&-container {
transition: opacity @animation-duration-slow, height @animation-duration-slow;
&::before {
display: table;
width: 0;
height: 0;
content: '';
}
// Don't know why span here, just stretch it
.@{upload-prefix-cls}-span {
display: block;
flex: auto;
}
}
// text & picture no need this additional element.
// But it used for picture-card, let's keep it.
.@{upload-prefix-cls}-span {
display: flex;
align-items: center;
> * {
flex: none;
}
}
.@{upload-item}-name {
flex: auto;
margin: 0;
padding: 0 @padding-xs;
}
.@{upload-item}-card-actions {
position: static;
}
}
// ============================ Text ============================
&-text {
.@{upload-prefix-cls}-text-icon {
.@{iconfont-css-prefix} {
position: static;
}
}
}
// =========================== Motion ===========================
.@{upload-prefix-cls}-animate-inline-appear,
.@{upload-prefix-cls}-animate-inline-enter,
.@{upload-prefix-cls}-animate-inline-leave {
animation-duration: @animation-duration-slow;
animation-timing-function: @ease-in-out-circ;
animation-fill-mode: forwards;
}
.@{upload-prefix-cls}-animate-inline-appear,
.@{upload-prefix-cls}-animate-inline-enter {
animation-name: uploadAnimateInlineIn;
}
.@{upload-prefix-cls}-animate-inline-leave {
animation-name: uploadAnimateInlineOut;
}
}
@keyframes uploadAnimateInlineIn {
from {
width: 0;
height: 0;
margin: 0;
padding: 0;
opacity: 0;
}
}
@keyframes uploadAnimateInlineOut {
to {
width: 0;
height: 0;
margin: 0;
padding: 0;
opacity: 0;
}
}
@import './rtl';

File diff suppressed because one or more lines are too long

3
node_modules/ng-zorro-antd/upload/style/patch.less generated vendored Normal file
View File

@@ -0,0 +1,3 @@
.ant-upload-list-rtl.ant-upload-list-picture-card .ant-upload-list-item {
float: unset;
}

165
node_modules/ng-zorro-antd/upload/style/rtl.less generated vendored Normal file
View File

@@ -0,0 +1,165 @@
@import '../../style/themes/index';
@import '../../style/mixins/index';
@upload-prefix-cls: ~'@{ant-prefix}-upload';
@upload-item: ~'@{ant-prefix}-upload-list-item';
.@{upload-prefix-cls} {
&-rtl {
direction: rtl;
}
&&-select-picture-card {
.@{upload-prefix-cls}-rtl& {
margin-right: auto;
margin-left: 8px;
}
}
}
.@{upload-prefix-cls}-list {
&-rtl {
direction: rtl;
}
&-item-list-type-text {
&:hover {
.@{upload-prefix-cls}-list-item-name-icon-count-1 {
.@{upload-prefix-cls}-list-rtl & {
padding-right: 22px;
padding-left: 14px;
}
}
.@{upload-prefix-cls}-list-item-name-icon-count-2 {
.@{upload-prefix-cls}-list-rtl & {
padding-right: 22px;
padding-left: 28px;
}
}
}
}
&-item {
&-name {
.@{upload-prefix-cls}-list-rtl & {
padding-right: @font-size-base + 8px;
padding-left: 0;
}
}
&-name-icon-count-1 {
.@{upload-prefix-cls}-list-rtl & {
padding-left: 14px;
}
}
&-card-actions {
.@{upload-prefix-cls}-list-rtl & {
right: auto;
left: 0;
}
.@{iconfont-css-prefix} {
.@{upload-prefix-cls}-list-rtl & {
padding-right: 0;
padding-left: 5px;
}
}
}
&-info {
.@{upload-prefix-cls}-list-rtl & {
padding: 0 4px 0 12px;
}
}
&-error &-card-actions {
.@{iconfont-css-prefix} {
.@{upload-prefix-cls}-list-rtl & {
padding-right: 0;
padding-left: 5px;
}
}
}
&-progress {
.@{upload-prefix-cls}-list-rtl & {
padding-right: @font-size-base + 12px;
padding-left: 0;
}
}
}
&-picture,
&-picture-card {
.@{upload-item}-info {
padding: 0;
}
.@{upload-item}-thumbnail {
.@{upload-prefix-cls}-list-rtl& {
right: 8px;
left: auto;
}
}
.@{upload-item}-icon {
.@{upload-prefix-cls}-list-rtl& {
right: 50%;
left: auto;
transform: translate(50%, -50%);
}
}
.@{upload-item}-name {
.@{upload-prefix-cls}-list-rtl& {
margin: 0 8px 0 0;
padding-right: 48px;
padding-left: 8px;
}
}
.@{upload-item}-name-icon-count-1 {
.@{upload-prefix-cls}-list-rtl& {
padding-right: 48px;
padding-left: 18px;
}
}
.@{upload-item}-name-icon-count-2 {
.@{upload-prefix-cls}-list-rtl& {
padding-right: 48px;
padding-left: 36px;
}
}
.@{upload-item}-progress {
.@{upload-prefix-cls}-list-rtl& {
padding-right: 0;
padding-left: 0;
}
}
}
&-picture-card {
&-container {
.@{upload-prefix-cls}-list-rtl & {
margin: 0 0 @margin-xs @margin-xs;
}
}
.@{upload-item}-actions {
.@{upload-prefix-cls}-list-rtl& {
right: 50%;
left: auto;
transform: translate(50%, -50%);
}
}
.@{upload-item}-file + .@{upload-item}-name {
.@{upload-prefix-cls}-list-rtl& {
margin: 8px 0 0;
padding: 0;
}
}
}
}