本文整理汇总了TypeScript中rebirth-common.RebirthWindow类的典型用法代码示例。如果您正苦于以下问题:TypeScript RebirthWindow类的具体用法?TypeScript RebirthWindow怎么用?TypeScript RebirthWindow使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了RebirthWindow类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的TypeScript代码示例。
示例1: constructor
constructor(private elmRef: ElementRef, private renderer: Renderer, private rebirthWindow: RebirthWindow) {
let protocol = this.rebirthWindow.getOwnerDocument(this.elmRef).location.protocol === 'https:' ? 'https:' : 'http:';
this.duoShuoUrl = `${protocol}//static.duoshuo.com/embed.js`;
this.rebirthWindow.getGlobalObject().duoshuoQuery = { short_name: "greengerong" };
}
开发者ID:VINOlive,项目名称:rebirth,代码行数:5,代码来源:duoshuo-comment.component.ts
示例2: ngOnInit
ngOnInit() {
let duoshuoElm = this.elmRef.nativeElement.querySelector('.ds-thread');
this.rebirthWindow.createScript(`${this.duoShuoUrl}?rn=${Math.random()}`,
this.renderer, this.elmRef, () => {
this.rebirthWindow.getGlobalObject().DUOSHUO.EmbedThread(duoshuoElm);
});
}
开发者ID:VINOlive,项目名称:rebirth,代码行数:8,代码来源:duoshuo-comment.component.ts
示例3: setTimeout
setTimeout(() => this.rebirthWindow.getGlobalObject().alert(`${this.article.title}修改成功`));
开发者ID:VINOlive,项目名称:rebirth,代码行数:1,代码来源:md-editor.component.ts
示例4:
this.renderer, this.elmRef, () => {
this.rebirthWindow.getGlobalObject().DUOSHUO.EmbedThread(duoshuoElm);
});
开发者ID:VINOlive,项目名称:rebirth,代码行数:3,代码来源:duoshuo-comment.component.ts
示例5:
.subscribe(result => {
this.article = result;
this.rebirthWindow.scrollToTop(this.elmRef);
}, (e) => console.log(e, 'ArticleListComponent error'));
开发者ID:VINOlive,项目名称:rebirth,代码行数:4,代码来源:article-list.component.ts
注:本文中的rebirth-common.RebirthWindow类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论