mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-03 06:51:53 +01:00
Issue Reporter: display message if url length exceeds limits, #42603
This commit is contained in:
@@ -58,10 +58,7 @@ ${this._data.issueDescription}
|
||||
VS Code version: ${this._data.versionInfo && this._data.versionInfo.vscodeVersion}
|
||||
OS version: ${this._data.versionInfo && this._data.versionInfo.os}
|
||||
|
||||
${this.getInfos()}
|
||||
|
||||
<!-- Generated by VS Code Issue Helper -->
|
||||
`;
|
||||
${this.getInfos()}`;
|
||||
}
|
||||
|
||||
private getIssueTypeTitle(): string {
|
||||
@@ -168,20 +165,12 @@ ${this._data.workspaceInfo};
|
||||
return `${e.manifest.name}|${e.manifest.publisher.substr(0, 3)}|${e.manifest.version}`;
|
||||
}).join('\n');
|
||||
|
||||
const extensionTable = `<details><summary>Extensions (${this._data.enabledNonThemeExtesions.length})</summary>
|
||||
return `<details><summary>Extensions (${this._data.enabledNonThemeExtesions.length})</summary>
|
||||
|
||||
${tableHeader}
|
||||
${table}
|
||||
${themeExclusionStr}
|
||||
|
||||
</details>`;
|
||||
|
||||
// 2000 chars is browsers de-facto limit for URLs, 400 chars are allowed for other string parts of the issue URL
|
||||
// http://stackoverflow.com/questions/417142/what-is-the-maximum-length-of-a-url-in-different-browsers
|
||||
if (encodeURIComponent(extensionTable).length > 1600) {
|
||||
return 'the listing length exceeds browsers\' URL characters limit';
|
||||
}
|
||||
|
||||
return extensionTable;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user