Skip to content

Commit 1824e62

Browse files
got rid of redundant data.preveiw title prop.
will stick with data filename for now
1 parent 7bce159 commit 1824e62

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/data.preview.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,6 @@ export class DataPreview {
9898
private _fileName: string;
9999
private _fileExtension: string;
100100
private _fileSize: number;
101-
private _title: string;
102101
private _html: string;
103102
private _panel: WebviewPanel;
104103
private _status: StatusBarItem;
@@ -152,7 +151,6 @@ export class DataPreview {
152151
this._fileName = path.basename(uri.fsPath);
153152
this._fileExtension = this._fileName.substr(this._fileName.lastIndexOf('.'));
154153
this._previewUri = this._uri.with({scheme: 'data'});
155-
this._title = `${this._fileName}`;
156154

157155
// parse view config
158156
viewConfig = this.parseConfig(viewConfig);
@@ -222,7 +220,7 @@ export class DataPreview {
222220
private initWebview(viewType: string, viewColumn: ViewColumn): void {
223221
if (!this._panel) {
224222
// create new webview panel
225-
this._panel = window.createWebviewPanel(viewType, this._title, viewColumn, this.getWebviewOptions());
223+
this._panel = window.createWebviewPanel(viewType, this._fileName, viewColumn, this.getWebviewOptions());
226224
this._panel.iconPath = Uri.file(path.join(this._extensionPath, './images/data-preview.svg'));
227225
}
228226
this._logger.debug('initWebview(): data.view created!');

0 commit comments

Comments
 (0)