mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-30 12:11:56 +00:00
chore: update Taiga UI and remove unnecessary styles (#2200)
* chore: update Taiga UI and remove unnecessary styles * update workflow and package lock --------- Co-authored-by: Lucy Cifferello <12953208+elvece@users.noreply.github.com>
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
<div class="wrapper" (elasticContainer)="height = $event">
|
||||
<ng-content></ng-content>
|
||||
</div>
|
||||
@@ -1,10 +0,0 @@
|
||||
:host {
|
||||
display: block;
|
||||
overflow: hidden;
|
||||
transition: height 0.25s;
|
||||
}
|
||||
|
||||
.wrapper {
|
||||
padding-top: 1px;
|
||||
margin-top: -1px;
|
||||
}
|
||||
@@ -1,12 +0,0 @@
|
||||
import { ChangeDetectionStrategy, Component, HostBinding } from '@angular/core'
|
||||
|
||||
@Component({
|
||||
selector: 'elastic-container',
|
||||
templateUrl: './elastic-container.component.html',
|
||||
styleUrls: ['./elastic-container.component.scss'],
|
||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
})
|
||||
export class ElasticContainerComponent {
|
||||
@HostBinding('style.height.px')
|
||||
height = NaN
|
||||
}
|
||||
@@ -1,35 +0,0 @@
|
||||
import { Directive, ElementRef, inject, Output } from '@angular/core'
|
||||
import { ResizeObserverService } from '@ng-web-apis/resize-observer'
|
||||
import {
|
||||
MUTATION_OBSERVER_INIT,
|
||||
MutationObserverService,
|
||||
} from '@ng-web-apis/mutation-observer'
|
||||
import { distinctUntilChanged, map, merge } from 'rxjs'
|
||||
|
||||
@Directive({
|
||||
selector: '[elasticContainer]',
|
||||
providers: [
|
||||
ResizeObserverService,
|
||||
MutationObserverService,
|
||||
{
|
||||
provide: MUTATION_OBSERVER_INIT,
|
||||
useValue: {
|
||||
childList: true,
|
||||
characterData: true,
|
||||
subtree: true,
|
||||
},
|
||||
},
|
||||
],
|
||||
})
|
||||
export class ElasticContainerDirective {
|
||||
private readonly elementRef = inject(ElementRef)
|
||||
|
||||
@Output()
|
||||
readonly elasticContainer = merge(
|
||||
inject(ResizeObserverService),
|
||||
inject(MutationObserverService),
|
||||
).pipe(
|
||||
map(() => this.elementRef.nativeElement.clientHeight - 1), // Compensate for padding
|
||||
distinctUntilChanged(),
|
||||
)
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
import { NgModule } from '@angular/core'
|
||||
|
||||
import { ElasticContainerComponent } from './elastic-container.component'
|
||||
import { ElasticContainerDirective } from './elastic-container.directive'
|
||||
|
||||
@NgModule({
|
||||
declarations: [ElasticContainerComponent, ElasticContainerDirective],
|
||||
exports: [ElasticContainerComponent],
|
||||
})
|
||||
export class ElasticContainerModule {}
|
||||
@@ -9,9 +9,6 @@ export * from './components/alert/alert.component'
|
||||
export * from './components/alert/alert.module'
|
||||
export * from './components/alert/alert-button.directive'
|
||||
export * from './components/alert/alert-input.directive'
|
||||
export * from './components/elastic-container/elastic-container.component'
|
||||
export * from './components/elastic-container/elastic-container.directive'
|
||||
export * from './components/elastic-container/elastic-container.module'
|
||||
export * from './components/markdown/markdown.component'
|
||||
export * from './components/markdown/markdown.component.module'
|
||||
export * from './components/text-spinner/text-spinner.component'
|
||||
|
||||
Reference in New Issue
Block a user