提交 7df39921 编写于 作者: R robertfoss

web-terminal: Add support for URL to Link parsing

This is desirable since it enables people who are viewing job results
to quickly go from the logs to more detailed information about an issue.
上级 e4b31f54
......@@ -2,11 +2,13 @@ import _ from 'underscore';
import $ from 'jquery';
import { Terminal } from 'xterm';
import * as fit from 'xterm/lib/addons/fit/fit';
import * as webLinks from 'xterm/lib/addons/webLinks/webLinks';
import { canScrollUp, canScrollDown } from '~/lib/utils/dom_utils';
const SCROLL_MARGIN = 5;
Terminal.applyAddon(fit);
Terminal.applyAddon(webLinks);
export default class GLTerminal {
constructor(element, options = {}) {
......@@ -48,6 +50,7 @@ export default class GLTerminal {
this.terminal.open(this.container);
this.terminal.fit();
this.terminal.webLinksInit();
this.terminal.focus();
this.socket.onopen = () => {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册