Add create task button to column headers

This commit is contained in:
Gordon
2021-03-31 00:45:53 +01:00
parent 154a325369
commit aafdf128a3
8 changed files with 28988 additions and 3577 deletions

View File

@ -73,7 +73,8 @@ export default class KanbnBoardPanel {
// Restrict the webview to only loading content from allowed paths
localResourceRoots: [
vscode.Uri.file(path.join(this._extensionPath, 'build')),
vscode.Uri.file(path.join(this._workspacePath, '.kanbn'))
vscode.Uri.file(path.join(this._workspacePath, '.kanbn')),
vscode.Uri.file(path.join(this._extensionPath, 'node_modules', 'vscode-codicons', 'dist'))
]
});
@ -151,6 +152,9 @@ export default class KanbnBoardPanel {
const customStyleUri = vscode.Uri
.file(path.join(this._workspacePath, '.kanbn', 'board.css'))
.with({ scheme: 'vscode-resource' });
const codiconsUri = vscode.Uri
.file(path.join(this._extensionPath, 'node_modules', 'vscode-codicons', 'dist', 'codicon.css'))
.with({ scheme: 'vscode-resource' });
// Use a nonce to whitelist which scripts can be run
const nonce = getNonce();
@ -164,7 +168,8 @@ export default class KanbnBoardPanel {
<title>Kanbn Board</title>
<link rel="stylesheet" type="text/css" href="${styleUri}">
<link rel="stylesheet" type="text/css" href="${customStyleUri}">
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; img-src vscode-resource: https:; script-src 'nonce-${nonce}';style-src vscode-resource: 'unsafe-inline' http: https: data:;">
<link rel="stylesheet" type="text/css" href="${codiconsUri}">
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; img-src vscode-resource: https:; script-src 'nonce-${nonce}'; font-src vscode-resource:; style-src vscode-resource: 'unsafe-inline' http: https: data:;">
<base href="${vscode.Uri.file(path.join(this._extensionPath, 'build')).with({ scheme: 'vscode-resource' })}/">
</head>
<body>

View File

@ -0,0 +1,2 @@
import * as path from 'path';
import * as vscode from 'vscode';