Improve notebook link handling (#6087)

* Improve notebook link handling
- Single click now works for links inside Output areas
- Command links in untrusted notebooks have link color
- Refactored to use directive so code is in 1 place and can be easily
  added elsewhere if needed

* Removed unneeded service from constructor
This commit is contained in:
Kevin Cunnane
2019-06-20 11:40:12 -07:00
committed by GitHub
parent 578ac6cae5
commit b37b14eabd
7 changed files with 82 additions and 62 deletions

View File

@@ -44,6 +44,10 @@ export class OutputAreaComponent extends AngularDisposable implements OnInit {
}
}
public get isTrusted(): boolean {
return this.cellModel.trustedMode;
}
private setFocusAndScroll(node: HTMLElement): void {
if (node) {
node.focus();