Compare commits
1 Commits
master
...
VM/RED-978
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
00b1b40a31 |
@ -1,13 +0,0 @@
|
|||||||
import { Injectable, signal } from '@angular/core';
|
|
||||||
|
|
||||||
@Injectable({
|
|
||||||
providedIn: 'root',
|
|
||||||
})
|
|
||||||
export class ActiveListingEntityService {
|
|
||||||
readonly #activeEntity = signal<string>('');
|
|
||||||
readonly activeEntity = this.#activeEntity.asReadonly();
|
|
||||||
|
|
||||||
updateEntity(entity: string = '') {
|
|
||||||
this.#activeEntity.set(entity);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@ -15,7 +15,6 @@
|
|||||||
(mouseenter)="itemMouseEnterFn && itemMouseEnterFn(entity)"
|
(mouseenter)="itemMouseEnterFn && itemMouseEnterFn(entity)"
|
||||||
(mouseleave)="itemMouseLeaveFn && itemMouseLeaveFn(entity)"
|
(mouseleave)="itemMouseLeaveFn && itemMouseLeaveFn(entity)"
|
||||||
[class.help-mode-active]="helpModeService?.isHelpModeActive$ | async"
|
[class.help-mode-active]="helpModeService?.isHelpModeActive$ | async"
|
||||||
[class.active-entity]="activeListingEntityService.activeEntity() === entity.id"
|
|
||||||
[id]="rowIdPrefix + '-' + ((entity[namePropertyKey] | snakeCase) ?? entity.id)"
|
[id]="rowIdPrefix + '-' + ((entity[namePropertyKey] | snakeCase) ?? entity.id)"
|
||||||
[ngClass]="getTableItemClasses(entity)"
|
[ngClass]="getTableItemClasses(entity)"
|
||||||
[routerLink]="entity.routerLink"
|
[routerLink]="entity.routerLink"
|
||||||
@ -29,7 +28,6 @@
|
|||||||
} @else {
|
} @else {
|
||||||
<div
|
<div
|
||||||
[class.help-mode-active]="helpModeService?.isHelpModeActive$ | async"
|
[class.help-mode-active]="helpModeService?.isHelpModeActive$ | async"
|
||||||
[class.active-entity]="activeListingEntityService.activeEntity() === entity.id"
|
|
||||||
[id]="rowIdPrefix + '-' + ((entity[namePropertyKey] | snakeCase) ?? entity.id)"
|
[id]="rowIdPrefix + '-' + ((entity[namePropertyKey] | snakeCase) ?? entity.id)"
|
||||||
[ngClass]="getTableItemClasses(entity)"
|
[ngClass]="getTableItemClasses(entity)"
|
||||||
[routerLink]="entity.routerLink"
|
[routerLink]="entity.routerLink"
|
||||||
|
|||||||
@ -33,7 +33,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
&:hover,
|
&:hover,
|
||||||
&.active-entity,
|
&:has(iqser-circle-button[aria-expanded='true']),
|
||||||
&.help-mode-active {
|
&.help-mode-active {
|
||||||
.selection-column iqser-round-checkbox .wrapper {
|
.selection-column iqser-round-checkbox .wrapper {
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
|
|||||||
@ -15,7 +15,6 @@ import { IListable } from '../models/listable';
|
|||||||
import { Id } from '../models/trackable';
|
import { Id } from '../models/trackable';
|
||||||
import { ListingService } from '../services/listing.service';
|
import { ListingService } from '../services/listing.service';
|
||||||
import { TableItemComponent } from './table-item/table-item.component';
|
import { TableItemComponent } from './table-item/table-item.component';
|
||||||
import { ActiveListingEntityService } from '../services/active-listing-entity.service';
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'iqser-table-content',
|
selector: 'iqser-table-content',
|
||||||
@ -54,7 +53,6 @@ export class TableContentComponent<Class extends IListable<PrimaryKey>, PrimaryK
|
|||||||
constructor(
|
constructor(
|
||||||
@Inject(forwardRef(() => ListingComponent)) readonly listingComponent: ListingComponent<Class>,
|
@Inject(forwardRef(() => ListingComponent)) readonly listingComponent: ListingComponent<Class>,
|
||||||
readonly listingService: ListingService<Class>,
|
readonly listingService: ListingService<Class>,
|
||||||
readonly activeListingEntityService: ActiveListingEntityService,
|
|
||||||
@Optional() readonly helpModeService: HelpModeService,
|
@Optional() readonly helpModeService: HelpModeService,
|
||||||
) {
|
) {
|
||||||
super();
|
super();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user