diff --git a/src/app/common/lesson-title-config/lesson-title-config.component.html b/src/app/common/lesson-title-config/lesson-title-config.component.html index fa183b81e21133d6dbb5270c8de0ed3f1583436f..e3e3f5460f3ab06dbd1caff1eb4eeccf05b84675 100644 --- a/src/app/common/lesson-title-config/lesson-title-config.component.html +++ b/src/app/common/lesson-title-config/lesson-title-config.component.html @@ -1,7 +1,7 @@ <div class="title-config"> <div class="title-wrap"> - <div class="row"> + <div class="row" style="margin: 5px;"> <div class="p-content" style="width:100%"> <div class="p-tool-box d-flex" style="background: #fff;"> <nz-select class="ml-1" style="width: 120px;" [(ngModel)]="__fontFamily" diff --git a/src/app/form/form.component.ts b/src/app/form/form.component.ts index bea5651f44b845a17deac48e60b8fd20c4002851..5a0d1f1c2436f83698f4c312442ec789182fdfbd 100644 --- a/src/app/form/form.component.ts +++ b/src/app/form/form.component.ts @@ -29,11 +29,13 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { } ngOnInit() { - let _this = this; + let _this = this; (<any>window).courseware.getData(function(data){ if(data){ _this.titleObj = data; - _this.appRef.tick(); + setTimeout(() => { + _this.appRef.tick(); + }, 1); } }); diff --git a/src/app/play/play.component.ts b/src/app/play/play.component.ts index 6e5b40fe1ede539fc04e53dd0d646394c313fd42..882a870ed42b9edc6742eaaa1d7c6b96f23cd1f4 100644 --- a/src/app/play/play.component.ts +++ b/src/app/play/play.component.ts @@ -48,7 +48,9 @@ export class PlayComponent implements OnInit, OnDestroy, OnChanges, AfterViewIni (<any>window).courseware.getData(function(data){ if(data){ _this.data.contentObj.titleObj.content = data.content; - _this.appRef.tick(); + setTimeout(() => { + _this.appRef.tick(); + }, 1); } });