mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-09-17 14:21:14 +00:00
[ACA-1432] unified selection and single info drawer (#385)
* track document list selection state * selection management enhancements * (fix) hide info drawer on selection reset * use store selection * remove event handler * upgrade info drawer for personal files * upgrade favorties * upgrade recent files * move info drawer to a separate component * test fixes * update tests * test fixes * remove obsolete directive * use last selection entry * switch back to first selected node * selection improvements, versioning uses same node * optimised toolbar visibility evaluation * upgrade libs * update js api * test fixes * test fixes * test updates * test fixes * fix e2e tests * show metadata for last clicked node
This commit is contained in:
@@ -38,6 +38,8 @@ import { NodeActionsService } from '../../common/services/node-actions.service';
|
||||
import { NodePermissionService } from '../../common/services/node-permission.service';
|
||||
|
||||
import { PageComponent } from '../page.component';
|
||||
import { Store } from '@ngrx/store';
|
||||
import { AcaState } from '../../store/states/app.state';
|
||||
|
||||
@Component({
|
||||
templateUrl: './files.component.html'
|
||||
@@ -48,8 +50,9 @@ export class FilesComponent extends PageComponent implements OnInit, OnDestroy {
|
||||
|
||||
private nodePath: PathElement[];
|
||||
|
||||
constructor(private router: Router,
|
||||
constructor(router: Router,
|
||||
route: ActivatedRoute,
|
||||
store: Store<AcaState>,
|
||||
private nodesApi: NodesApiService,
|
||||
private nodeActionsService: NodeActionsService,
|
||||
private uploadService: UploadService,
|
||||
@@ -60,10 +63,12 @@ export class FilesComponent extends PageComponent implements OnInit, OnDestroy {
|
||||
private notificationService: NotificationService,
|
||||
public permission: NodePermissionService,
|
||||
preferences: UserPreferencesService) {
|
||||
super(preferences, route);
|
||||
super(preferences, router, route, store);
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
super.ngOnInit();
|
||||
|
||||
const { route, contentManagementService, contentService, nodeActionsService, uploadService } = this;
|
||||
const { data } = route.snapshot;
|
||||
|
||||
@@ -156,14 +161,6 @@ export class FilesComponent extends PageComponent implements OnInit, OnDestroy {
|
||||
}
|
||||
}
|
||||
|
||||
showPreview(node: MinimalNodeEntryEntity) {
|
||||
if (node) {
|
||||
if (node.isFile) {
|
||||
this.router.navigate(['./preview', node.id], { relativeTo: this.route });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
onBreadcrumbNavigate(route: PathElementEntity) {
|
||||
// todo: review this approach once 5.2.3 is out
|
||||
if (this.nodePath && this.nodePath.length > 2) {
|
||||
|
Reference in New Issue
Block a user