Fix issues caused by refactoring

Signed-off-by: trivernis <trivernis@protonmail.com>
pull/4/head
trivernis 3 years ago
parent 60faf81187
commit aa563830c1

@ -13,13 +13,14 @@ import {MatProgressBarModule} from "@angular/material/progress-bar";
import {ScrollingModule} from "@angular/cdk/scrolling";
import {MatTabsModule} from "@angular/material/tabs";
import {FlexModule} from "@angular/flex-layout";
import {MatOptionModule} from "@angular/material/core";
import {MatOptionModule, MatRippleModule} from "@angular/material/core";
import {MatSelectModule} from "@angular/material/select";
import {MatCheckboxModule} from "@angular/material/checkbox";
import {SharedModule} from "../shared/shared.module";
import {MatDividerModule} from "@angular/material/divider";
import {NgIconsModule} from "@ng-icons/core";
import * as materialIcons from "@ng-icons/material-icons";
import {MatMenuModule} from "@angular/material/menu";
@NgModule({
@ -49,6 +50,8 @@ import * as materialIcons from "@ng-icons/material-icons";
NgIconsModule.withIcons({...materialIcons}),
FlexModule,
MatButtonModule,
MatMenuModule,
MatRippleModule,
]
})
export class CoreModule {

@ -29,7 +29,7 @@
</div>
<mat-form-field appearance="fill" class="form-field-mode">
<mat-label>Mode</mat-label>
<mat-select #modeSelect [(value)]="editMode">
<mat-select [(value)]="editMode">
<mat-option value="Toggle">Toggle</mat-option>
<mat-option value="Add">Add</mat-option>
<mat-option value="Remove">Remove</mat-option>

@ -31,7 +31,7 @@ export class FileGridEntryComponent implements OnInit, OnChanges {
private cachedFile: File | undefined;
private urlSetTimeout: number | undefined;
constructor(private fileService: FileService, private errorBroker: ErrorBrokerService) {
constructor(private fileService: FileService) {
}
async ngOnInit() {

@ -68,8 +68,6 @@ export class FileGridComponent implements OnChanges, OnInit {
* @param {FileGridEntryComponent} clickedEntry
*/
setSelectedFile(clickedEntry: GridEntry) {
const previousSelectionSize = this.selectedEntries.length;
if (!(this.shiftClicked || this.ctrlClicked) && this.selectedEntries.length > 0) {
this.selectedEntries.forEach(entry => {
if (entry !== clickedEntry) entry.selected = false

@ -29,7 +29,7 @@ export class TagFilterListItemComponent implements OnChanges {
public selectedIndices: number[] = [];
constructor(private changeDetector: ChangeDetectorRef) {
constructor() {
}
public ngOnChanges(changes: SimpleChanges): void {

@ -9,8 +9,4 @@ export class Selectable<T> {
public unselect() {
this.selected = false;
}
public toggle() {
this.selected = !this.selected;
}
}

Loading…
Cancel
Save