Skip to content

Commit

Permalink
feat(plex-327): selector de transparecia en table head
Browse files Browse the repository at this point in the history
  • Loading branch information
ma7payne committed Jul 28, 2023
1 parent 7005996 commit 432fba0
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
15 changes: 13 additions & 2 deletions src/lib/css/plex-table.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
@import "./variables.scss";

$tags: 0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100;

plex-table {
table {
width: 100%;
Expand All @@ -11,7 +13,12 @@ plex-table {
top: 0 !important;
z-index: 10 !important;
height: fit-content;
background-color: rgba(255, 255, 255, 0.5) !important;

@each $tag in $tags {
&.opacity-#{$tag} {
background-color: rgba(255, 255, 255, $tag/100) !important;
}
}

&.sortable {
.th-label {
Expand Down Expand Up @@ -125,7 +132,11 @@ plex-layout-sidebar {
table {
thead {
th {
background-color: rgba(0, 39, 56, 0.5) !important;
@each $tag in $tags {
&.opacity-#{$tag} {
background-color: rgba(0, 39, 56, $tag/100) !important;
}
}
}
}

Expand Down
5 changes: 4 additions & 1 deletion src/lib/table/table.component.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component, EventEmitter, Input, Optional, Output, Self, ViewEncapsulation } from '@angular/core';
import { Component, EventEmitter, Input, Optional, Output, Self } from '@angular/core';
import { Observable } from 'rxjs';
import { PlexColumnDirective } from './columns.directive';
import { IPlexTableColumns } from './table.interfaces';
Expand All @@ -21,6 +21,7 @@ import { IPlexTableColumns } from './table.interfaces';
(click)="onColumnClick(column)"
*ngIf="vm.displayColumns[column.key] || !column.opcional"
[class.column-right]="column.right"
class="opacity-{{headOpacity}}"
>
<div class="d-flex">
<div class="th-label">
Expand Down Expand Up @@ -65,6 +66,8 @@ export class PlexTableComponent {

public _height: string;

@Input() headOpacity = 0;

/**
* Indica la altura del listado respecto a su contenedor
*/
Expand Down

0 comments on commit 432fba0

Please sign in to comment.