mirror of https://github.com/Squidex/squidex.git
28 changed files with 1164 additions and 807 deletions
@ -0,0 +1,31 @@ |
|||
<ul class="nav navbar-nav" *ngIf="assets.uploadsDelayed | async; let uploads" (sqxFileDrop)="addFiles($event)"> |
|||
<li class="nav-item dropdown"> |
|||
<span class="nav-link dropdown-toggle" (click)="modalMenu.toggle()"> |
|||
<i class="icon-upload-3"></i> |
|||
|
|||
<span>{{uploads.length}}</span> |
|||
</span> |
|||
|
|||
<div class="dropdown-menu container" *ngIf="modalMenu.isOpen | async" (sqxFileDrop)="addFiles($event)" @fade> |
|||
<div class="uploads"> |
|||
<small class="uploads-empty text-muted" *ngIf="uploads.length === 0"> |
|||
No upload in progress, drop files here. |
|||
</small> |
|||
|
|||
<div class="upload row no-gutters" *ngFor="let upload of uploads"> |
|||
<div class="col-6"> |
|||
<div class="upload-name">{{upload.name}}</div> |
|||
</div> |
|||
<div class="col"> |
|||
<sqx-progress-bar [value]="upload.progress" [trailWidth]="0.8" [strokeWidth]="0.8" [showText]="false" [animated]="false"></sqx-progress-bar> |
|||
</div> |
|||
<div class="col-auto"> |
|||
<button type="button" class="btn btn-text-secondary" (click)="stopUpload(upload)"> |
|||
<i class="icon-close"></i> |
|||
</button> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
</li> |
|||
</ul> |
|||
@ -0,0 +1,70 @@ |
|||
@import '_vars'; |
|||
@import '_mixins'; |
|||
|
|||
.nav { |
|||
& { |
|||
padding-right: 2rem; |
|||
} |
|||
.nav-item { |
|||
& { |
|||
line-height: 2rem; |
|||
} |
|||
|
|||
.nav-link { |
|||
color: $color-dark-foreground; |
|||
padding-top: 0; |
|||
padding-bottom: 0; |
|||
} |
|||
} |
|||
} |
|||
|
|||
.icon-upload-3 { |
|||
vertical-align: middle; |
|||
font-size: 1.4rem; |
|||
font-weight: lighter; |
|||
padding-right: .5rem; |
|||
} |
|||
|
|||
.dropdown-menu { |
|||
@include absolute(2.6rem, 0, auto, auto); |
|||
display: block; |
|||
min-width: 30rem; |
|||
max-width: 60%; |
|||
min-height: 4rem; |
|||
padding: 1rem; |
|||
} |
|||
|
|||
.uploads { |
|||
& { |
|||
border: 2px solid transparent; |
|||
} |
|||
|
|||
&-empty { |
|||
line-height: 2rem; |
|||
} |
|||
} |
|||
|
|||
.upload { |
|||
& { |
|||
line-height: 2rem; |
|||
min-height: 2rem; |
|||
max-height: 2rem; |
|||
margin-bottom: .5rem; |
|||
} |
|||
|
|||
&:last-child { |
|||
margin: 0; |
|||
} |
|||
|
|||
&-name { |
|||
@include truncate; |
|||
padding-right: .5rem; |
|||
padding-left: .5rem; |
|||
} |
|||
} |
|||
|
|||
.drag { |
|||
& > .uploads { |
|||
border-color: $color-theme-blue; |
|||
} |
|||
} |
|||
@ -0,0 +1,49 @@ |
|||
/* |
|||
* Squidex Headless CMS |
|||
* |
|||
* @license |
|||
* Copyright (c) Squidex UG (haftungsbeschränkt). All rights reserved. |
|||
*/ |
|||
|
|||
import { ChangeDetectionStrategy, Component } from '@angular/core'; |
|||
|
|||
import { |
|||
AssetsState, |
|||
DialogModel, |
|||
fadeAnimation, |
|||
UploadingAsset |
|||
} from '@app/shared/internal'; |
|||
|
|||
@Component({ |
|||
selector: 'sqx-asset-uploader', |
|||
styleUrls: ['./asset-uploader.component.scss'], |
|||
templateUrl: './asset-uploader.component.html', |
|||
animations: [ |
|||
fadeAnimation |
|||
], |
|||
changeDetection: ChangeDetectionStrategy.OnPush |
|||
}) |
|||
export class AssetUploaderComponent { |
|||
public modalMenu = new DialogModel(true); |
|||
|
|||
constructor( |
|||
public readonly assets: AssetsState |
|||
) { |
|||
} |
|||
|
|||
public addFiles(files: File[]) { |
|||
for (let file of files) { |
|||
this.assets.upload(file).subscribe(); |
|||
} |
|||
|
|||
this.modalMenu.show(); |
|||
} |
|||
|
|||
public stopUpload(upload: UploadingAsset) { |
|||
this.assets.remove(upload); |
|||
} |
|||
|
|||
public trackByUpload(index: number, upload: UploadingAsset) { |
|||
return upload.id; |
|||
} |
|||
} |
|||
@ -1,7 +0,0 @@ |
|||
Open *demo.html* to see a list of all the glyphs in your font along with their codes/ligatures. |
|||
|
|||
To use the generated font in desktop programs, you can install the TTF font. In order to copy the character associated with each icon, refer to the text box at the bottom right corner of each glyph in demo.html. The character inside this text box may be invisible; but it can still be copied. See this guide for more info: https://icomoon.io/#docs/local-fonts |
|||
|
|||
You won't need any of the files located under the *demo-files* directory when including the generated font in your own projects. |
|||
|
|||
You can import *selection.json* back to the IcoMoon app using the *Import Icons* button (or via Main Menu → Manage Projects) to retrieve your icon selection. |
|||
File diff suppressed because it is too large
Binary file not shown.
|
Before Width: | Height: | Size: 88 KiB After Width: | Height: | Size: 92 KiB |
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
Loading…
Reference in new issue