Dataset Profile editor . Scroll timing Fix
This commit is contained in:
parent
5e77f78a1c
commit
b6236b7e0d
|
@ -44,4 +44,16 @@ export const STEPPER_ANIMATIONS = [
|
|||
animate('600ms ease-in', style({opacity:0.3}))
|
||||
])
|
||||
])
|
||||
];
|
||||
];
|
||||
export const GENERAL_ANIMATIONS = [
|
||||
trigger('enterIn',[
|
||||
transition(':enter',[
|
||||
style({
|
||||
transform:'scale(0)',
|
||||
'transform-origin':'50% 0',
|
||||
opacity:0
|
||||
}),
|
||||
animate('800ms ease', style({transform:'scale(1)', opacity:1}))
|
||||
])
|
||||
])
|
||||
]
|
|
@ -137,23 +137,21 @@ export class DatasetProfileEditorSectionFieldSetComponent implements OnInit, OnC
|
|||
let el = this.myElement.nativeElement.querySelector("#"+this.idprefix+id);
|
||||
// let el = this.myElement.nativeElement.getElementbyId (this.selectedFieldSetId);
|
||||
|
||||
if(el){
|
||||
if(el){
|
||||
|
||||
/*
|
||||
Give time to template to build itself (extending and collapsing).
|
||||
In case we are dragging from one container to another, then the ui takes around 600ms to build
|
||||
individual previews (dataset-profile-editor-field.component.ts);
|
||||
/*
|
||||
Give time to template to build itself (extending and collapsing).
|
||||
In case we are dragging from one container to another, then the ui takes around 600ms to build
|
||||
individual previews (dataset-profile-editor-field.component.ts);
|
||||
|
||||
*/
|
||||
setTimeout(() => {
|
||||
const el = this.myElement.nativeElement.querySelector("#"+this.idprefix+id);
|
||||
if(el){
|
||||
el.scrollIntoView({behavior: "smooth"});
|
||||
}
|
||||
}, 1100);
|
||||
}else{
|
||||
this._scrollOnTop();
|
||||
}
|
||||
*/
|
||||
setTimeout(() => {
|
||||
const el = this.myElement.nativeElement.querySelector("#"+this.idprefix+id);
|
||||
if(el){
|
||||
el.scrollIntoView({behavior: "smooth"});
|
||||
}
|
||||
}, 700);
|
||||
}
|
||||
|
||||
}
|
||||
private _scrollOnTop(){
|
||||
|
|
Loading…
Reference in New Issue