mirror of
https://github.com/wavetermdev/xterm.js.git
synced 2026-08-05 13:43:48 -07:00
Fix webgl packaging
This commit is contained in:
+1
-1
@@ -8,7 +8,7 @@ import { WebglRenderer } from './WebglRenderer';
|
||||
import { IRenderService } from 'browser/services/Services';
|
||||
import { IColorSet } from 'browser/Types';
|
||||
|
||||
export class WebglRendererAddon implements ITerminalAddon {
|
||||
export class WebglAddon implements ITerminalAddon {
|
||||
constructor(
|
||||
private _preserveDrawingBuffer?: boolean
|
||||
) {}
|
||||
@@ -6,7 +6,7 @@
|
||||
const path = require('path');
|
||||
|
||||
const addonName = 'WebglAddon';
|
||||
const mainFile = 'xterm-addon-weblg.js';
|
||||
const mainFile = 'xterm-addon-webgl.js';
|
||||
|
||||
module.exports = {
|
||||
entry: `./out/${addonName}.js`,
|
||||
@@ -21,6 +21,14 @@ module.exports = {
|
||||
}
|
||||
]
|
||||
},
|
||||
resolve: {
|
||||
modules: ['./node_modules'],
|
||||
extensions: [ '.js' ],
|
||||
alias: {
|
||||
common: path.resolve('../../out/common'),
|
||||
browser: path.resolve('../../out/browser')
|
||||
}
|
||||
},
|
||||
output: {
|
||||
filename: mainFile,
|
||||
path: path.resolve('./lib'),
|
||||
|
||||
+3
-2
@@ -13,7 +13,7 @@ import { AttachAddon } from '../addons/xterm-addon-attach/out/AttachAddon';
|
||||
import { FitAddon } from '../addons/xterm-addon-fit/out/FitAddon';
|
||||
import { SearchAddon, ISearchOptions } from '../addons/xterm-addon-search/out/SearchAddon';
|
||||
import { WebLinksAddon } from '../addons/xterm-addon-web-links/out/WebLinksAddon';
|
||||
import { WebglRendererAddon } from '../addons/xterm-addon-webgl/out/WebglRendererAddon';
|
||||
import { WebglAddon } from '../addons/xterm-addon-webgl/out/WebglAddon';
|
||||
|
||||
// Use webpacked version (yarn package)
|
||||
// import { Terminal } from '../lib/xterm';
|
||||
@@ -21,6 +21,7 @@ import { WebglRendererAddon } from '../addons/xterm-addon-webgl/out/WebglRendere
|
||||
// import { FitAddon } from 'xterm-addon-fit';
|
||||
// import { SearchAddon, ISearchOptions } from 'xterm-addon-search';
|
||||
// import { WebLinksAddon } from 'xterm-addon-web-links';
|
||||
// import { WebglAddon } from 'xterm-addon-webgl';
|
||||
|
||||
// Pulling in the module's types relies on the <reference> above, it's looks a
|
||||
// little weird here as we're importing "this" module
|
||||
@@ -44,7 +45,7 @@ let socketURL;
|
||||
let socket;
|
||||
let pid;
|
||||
|
||||
(<any>window).webgl = () => term.loadAddon(new WebglRendererAddon());
|
||||
(<any>window).webgl = () => term.loadAddon(new WebglAddon());
|
||||
|
||||
const terminalContainer = document.getElementById('terminal-container');
|
||||
const actionElements = {
|
||||
|
||||
Reference in New Issue
Block a user