|
@@ -1,4 +1,4 @@
|
|
|
-import { Component, Input } from '@angular/core';
|
|
|
+import { Component, Input, inject } from '@angular/core';
|
|
|
import { CdkDragDrop, moveItemInArray } from '@angular/cdk/drag-drop';
|
|
|
import { ModalService } from 'src/services/modal/modal.service';
|
|
|
|
|
@@ -10,14 +10,16 @@ import { ModalService } from 'src/services/modal/modal.service';
|
|
|
export class ToolsModalComponent {
|
|
|
@Input() public proficiencies: any = { tools: [], languages: [] };
|
|
|
|
|
|
- public tools: any;
|
|
|
- public languages: any;
|
|
|
+ public tools: string[] = [];
|
|
|
+ public languages: string[] = [];
|
|
|
|
|
|
- public constructor(public modalAccessor: ModalService) {}
|
|
|
+ private modalAccessor: ModalService = inject(ModalService);
|
|
|
|
|
|
ngOnInit(): void {
|
|
|
this.tools = JSON.parse(JSON.stringify(this.proficiencies.tools));
|
|
|
this.languages = JSON.parse(JSON.stringify(this.proficiencies.languages));
|
|
|
+ this.proficiencies.tools = this.tools;
|
|
|
+ this.proficiencies.languages = this.languages;
|
|
|
}
|
|
|
|
|
|
public dropTools(event: CdkDragDrop<string[]>): void {
|