mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-25 01:25:36 -05:00
Merge from vscode 6e530127a1bb8ffbd1bfb77dc680c321dc0d71f5 (#6844)
This commit is contained in:
@@ -50,6 +50,7 @@ const indentationFilter = [
|
||||
'!src/vs/css.js',
|
||||
'!src/vs/css.build.js',
|
||||
'!src/vs/loader.js',
|
||||
'!src/vs/base/common/insane/insane.js',
|
||||
'!src/vs/base/common/marked/marked.js',
|
||||
'!src/vs/base/node/terminateProcess.sh',
|
||||
'!src/vs/base/node/cpuUsage.sh',
|
||||
@@ -171,18 +172,16 @@ const eslintFilter = [
|
||||
'!src/vs/nls.js',
|
||||
'!src/vs/css.build.js',
|
||||
'!src/vs/nls.build.js',
|
||||
'!src/**/insane.js',
|
||||
'!src/**/marked.js',
|
||||
'!**/test/**'
|
||||
];
|
||||
|
||||
const tslintFilter = [
|
||||
'src/**/*.ts',
|
||||
'test/**/*.ts',
|
||||
'extensions/**/*.ts',
|
||||
const tslintBaseFilter = [
|
||||
'!**/fixtures/**',
|
||||
'!**/typings/**',
|
||||
'!**/node_modules/**',
|
||||
'!extensions/typescript/test/colorize-fixtures/**',
|
||||
'!extensions/typescript-basics/test/colorize-fixtures/**',
|
||||
'!extensions/vscode-api-tests/testWorkspace/**',
|
||||
'!extensions/vscode-api-tests/testWorkspace2/**',
|
||||
'!extensions/**/*.test.ts',
|
||||
@@ -201,6 +200,29 @@ const sqlFilter = [
|
||||
];
|
||||
|
||||
// {{SQL CARBON EDIT}}
|
||||
|
||||
const tslintCoreFilter = [
|
||||
'src/**/*.ts',
|
||||
'test/**/*.ts',
|
||||
'!extensions/**/*.ts',
|
||||
'!test/smoke/**',
|
||||
...tslintBaseFilter
|
||||
];
|
||||
|
||||
const tslintExtensionsFilter = [
|
||||
'extensions/**/*.ts',
|
||||
'!src/**/*.ts',
|
||||
'!test/**/*.ts',
|
||||
...tslintBaseFilter
|
||||
];
|
||||
|
||||
const tslintHygieneFilter = [
|
||||
'src/**/*.ts',
|
||||
'test/**/*.ts',
|
||||
'extensions/**/*.ts',
|
||||
...tslintBaseFilter
|
||||
];
|
||||
|
||||
const copyrightHeaderLines = [
|
||||
'/*---------------------------------------------------------------------------------------------',
|
||||
' * Copyright (c) Microsoft Corporation. All rights reserved.',
|
||||
@@ -217,12 +239,20 @@ gulp.task('eslint', () => {
|
||||
});
|
||||
|
||||
gulp.task('tslint', () => {
|
||||
const options = { emitError: true };
|
||||
return es.merge([
|
||||
|
||||
return vfs.src(all, { base: '.', follow: true, allowEmpty: true })
|
||||
.pipe(filter(tslintFilter))
|
||||
.pipe(gulptslint.default({ rulesDirectory: 'build/lib/tslint' }))
|
||||
.pipe(gulptslint.default.report(options));
|
||||
// Core: include type information (required by certain rules like no-nodejs-globals)
|
||||
vfs.src(all, { base: '.', follow: true, allowEmpty: true })
|
||||
.pipe(filter(tslintCoreFilter))
|
||||
.pipe(gulptslint.default({ rulesDirectory: 'build/lib/tslint', program: tslint.Linter.createProgram('src/tsconfig.json') }))
|
||||
.pipe(gulptslint.default.report({ emitError: true })),
|
||||
|
||||
// Exenstions: do not include type information
|
||||
vfs.src(all, { base: '.', follow: true, allowEmpty: true })
|
||||
.pipe(filter(tslintExtensionsFilter))
|
||||
.pipe(gulptslint.default({ rulesDirectory: 'build/lib/tslint' }))
|
||||
.pipe(gulptslint.default.report({ emitError: true }))
|
||||
]);
|
||||
});
|
||||
|
||||
function hygiene(some) {
|
||||
@@ -363,7 +393,7 @@ function hygiene(some) {
|
||||
.pipe(copyrights);
|
||||
|
||||
const typescript = result
|
||||
.pipe(filter(tslintFilter))
|
||||
.pipe(filter(tslintHygieneFilter))
|
||||
.pipe(formatting)
|
||||
.pipe(tsl)
|
||||
// {{SQL CARBON EDIT}}
|
||||
|
||||
@@ -41,6 +41,9 @@ const vscodeWebResources = [
|
||||
// Webview
|
||||
'out-build/vs/workbench/contrib/webview/browser/pre/*.js',
|
||||
|
||||
// Extension Worker
|
||||
'out-build/vs/workbench/services/extensions/worker/extensionHostWorkerMain.js',
|
||||
|
||||
// Excludes
|
||||
'!out-build/vs/**/{node,electron-browser,electron-main}/**',
|
||||
'!out-build/vs/editor/standalone/**',
|
||||
|
||||
40
build/lib/tslint/abstractGlobalsRule.js
Normal file
40
build/lib/tslint/abstractGlobalsRule.js
Normal file
@@ -0,0 +1,40 @@
|
||||
"use strict";
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const Lint = require("tslint");
|
||||
class AbstractGlobalsRuleWalker extends Lint.RuleWalker {
|
||||
constructor(file, program, opts, _config) {
|
||||
super(file, opts);
|
||||
this.program = program;
|
||||
this._config = _config;
|
||||
}
|
||||
visitIdentifier(node) {
|
||||
if (this.getDisallowedGlobals().some(disallowedGlobal => disallowedGlobal === node.text)) {
|
||||
if (this._config.allowed && this._config.allowed.some(allowed => allowed === node.text)) {
|
||||
return; // override
|
||||
}
|
||||
const checker = this.program.getTypeChecker();
|
||||
const symbol = checker.getSymbolAtLocation(node);
|
||||
if (symbol) {
|
||||
const valueDeclaration = symbol.valueDeclaration;
|
||||
if (valueDeclaration) {
|
||||
const parent = valueDeclaration.parent;
|
||||
if (parent) {
|
||||
const sourceFile = parent.getSourceFile();
|
||||
if (sourceFile) {
|
||||
const fileName = sourceFile.fileName;
|
||||
if (fileName && fileName.indexOf(this.getDefinitionPattern()) >= 0) {
|
||||
this.addFailureAtNode(node, `Cannot use global '${node.text}' in '${this._config.target}'`);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
super.visitIdentifier(node);
|
||||
}
|
||||
}
|
||||
exports.AbstractGlobalsRuleWalker = AbstractGlobalsRuleWalker;
|
||||
51
build/lib/tslint/abstractGlobalsRule.ts
Normal file
51
build/lib/tslint/abstractGlobalsRule.ts
Normal file
@@ -0,0 +1,51 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as ts from 'typescript';
|
||||
import * as Lint from 'tslint';
|
||||
|
||||
interface AbstractGlobalsRuleConfig {
|
||||
target: string;
|
||||
allowed: string[];
|
||||
}
|
||||
|
||||
export abstract class AbstractGlobalsRuleWalker extends Lint.RuleWalker {
|
||||
|
||||
constructor(file: ts.SourceFile, private program: ts.Program, opts: Lint.IOptions, private _config: AbstractGlobalsRuleConfig) {
|
||||
super(file, opts);
|
||||
}
|
||||
|
||||
protected abstract getDisallowedGlobals(): string[];
|
||||
|
||||
protected abstract getDefinitionPattern(): string;
|
||||
|
||||
visitIdentifier(node: ts.Identifier) {
|
||||
if (this.getDisallowedGlobals().some(disallowedGlobal => disallowedGlobal === node.text)) {
|
||||
if (this._config.allowed && this._config.allowed.some(allowed => allowed === node.text)) {
|
||||
return; // override
|
||||
}
|
||||
|
||||
const checker = this.program.getTypeChecker();
|
||||
const symbol = checker.getSymbolAtLocation(node);
|
||||
if (symbol) {
|
||||
const valueDeclaration = symbol.valueDeclaration;
|
||||
if (valueDeclaration) {
|
||||
const parent = valueDeclaration.parent;
|
||||
if (parent) {
|
||||
const sourceFile = parent.getSourceFile();
|
||||
if (sourceFile) {
|
||||
const fileName = sourceFile.fileName;
|
||||
if (fileName && fileName.indexOf(this.getDefinitionPattern()) >= 0) {
|
||||
this.addFailureAtNode(node, `Cannot use global '${node.text}' in '${this._config.target}'`);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
super.visitIdentifier(node);
|
||||
}
|
||||
}
|
||||
34
build/lib/tslint/noDOMGlobalsRule.js
Normal file
34
build/lib/tslint/noDOMGlobalsRule.js
Normal file
@@ -0,0 +1,34 @@
|
||||
"use strict";
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const Lint = require("tslint");
|
||||
const minimatch = require("minimatch");
|
||||
const abstractGlobalsRule_1 = require("./abstractGlobalsRule");
|
||||
class Rule extends Lint.Rules.TypedRule {
|
||||
applyWithProgram(sourceFile, program) {
|
||||
const configs = this.getOptions().ruleArguments;
|
||||
for (const config of configs) {
|
||||
if (minimatch(sourceFile.fileName, config.target)) {
|
||||
return this.applyWithWalker(new NoDOMGlobalsRuleWalker(sourceFile, program, this.getOptions(), config));
|
||||
}
|
||||
}
|
||||
return [];
|
||||
}
|
||||
}
|
||||
exports.Rule = Rule;
|
||||
class NoDOMGlobalsRuleWalker extends abstractGlobalsRule_1.AbstractGlobalsRuleWalker {
|
||||
getDefinitionPattern() {
|
||||
return 'lib.dom.d.ts';
|
||||
}
|
||||
getDisallowedGlobals() {
|
||||
// intentionally not complete
|
||||
return [
|
||||
"window",
|
||||
"document",
|
||||
"HTMLElement"
|
||||
];
|
||||
}
|
||||
}
|
||||
45
build/lib/tslint/noDOMGlobalsRule.ts
Normal file
45
build/lib/tslint/noDOMGlobalsRule.ts
Normal file
@@ -0,0 +1,45 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as ts from 'typescript';
|
||||
import * as Lint from 'tslint';
|
||||
import * as minimatch from 'minimatch';
|
||||
import { AbstractGlobalsRuleWalker } from './abstractGlobalsRule';
|
||||
|
||||
interface NoDOMGlobalsRuleConfig {
|
||||
target: string;
|
||||
allowed: string[];
|
||||
}
|
||||
|
||||
export class Rule extends Lint.Rules.TypedRule {
|
||||
|
||||
applyWithProgram(sourceFile: ts.SourceFile, program: ts.Program): Lint.RuleFailure[] {
|
||||
const configs = <NoDOMGlobalsRuleConfig[]>this.getOptions().ruleArguments;
|
||||
|
||||
for (const config of configs) {
|
||||
if (minimatch(sourceFile.fileName, config.target)) {
|
||||
return this.applyWithWalker(new NoDOMGlobalsRuleWalker(sourceFile, program, this.getOptions(), config));
|
||||
}
|
||||
}
|
||||
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
class NoDOMGlobalsRuleWalker extends AbstractGlobalsRuleWalker {
|
||||
|
||||
getDefinitionPattern(): string {
|
||||
return 'lib.dom.d.ts';
|
||||
}
|
||||
|
||||
getDisallowedGlobals(): string[] {
|
||||
// intentionally not complete
|
||||
return [
|
||||
"window",
|
||||
"document",
|
||||
"HTMLElement"
|
||||
];
|
||||
}
|
||||
}
|
||||
40
build/lib/tslint/noNodeJSGlobalsRule.js
Normal file
40
build/lib/tslint/noNodeJSGlobalsRule.js
Normal file
@@ -0,0 +1,40 @@
|
||||
"use strict";
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
const Lint = require("tslint");
|
||||
const minimatch = require("minimatch");
|
||||
const abstractGlobalsRule_1 = require("./abstractGlobalsRule");
|
||||
class Rule extends Lint.Rules.TypedRule {
|
||||
applyWithProgram(sourceFile, program) {
|
||||
const configs = this.getOptions().ruleArguments;
|
||||
for (const config of configs) {
|
||||
if (minimatch(sourceFile.fileName, config.target)) {
|
||||
return this.applyWithWalker(new NoNodejsGlobalsRuleWalker(sourceFile, program, this.getOptions(), config));
|
||||
}
|
||||
}
|
||||
return [];
|
||||
}
|
||||
}
|
||||
exports.Rule = Rule;
|
||||
class NoNodejsGlobalsRuleWalker extends abstractGlobalsRule_1.AbstractGlobalsRuleWalker {
|
||||
getDefinitionPattern() {
|
||||
return '@types/node';
|
||||
}
|
||||
getDisallowedGlobals() {
|
||||
// https://nodejs.org/api/globals.html#globals_global_objects
|
||||
return [
|
||||
"Buffer",
|
||||
"__dirname",
|
||||
"__filename",
|
||||
"clearImmediate",
|
||||
"exports",
|
||||
"global",
|
||||
"module",
|
||||
"process",
|
||||
"setImmediate"
|
||||
];
|
||||
}
|
||||
}
|
||||
51
build/lib/tslint/noNodeJSGlobalsRule.ts
Normal file
51
build/lib/tslint/noNodeJSGlobalsRule.ts
Normal file
@@ -0,0 +1,51 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as ts from 'typescript';
|
||||
import * as Lint from 'tslint';
|
||||
import * as minimatch from 'minimatch';
|
||||
import { AbstractGlobalsRuleWalker } from './abstractGlobalsRule';
|
||||
|
||||
interface NoNodejsGlobalsConfig {
|
||||
target: string;
|
||||
allowed: string[];
|
||||
}
|
||||
|
||||
export class Rule extends Lint.Rules.TypedRule {
|
||||
|
||||
applyWithProgram(sourceFile: ts.SourceFile, program: ts.Program): Lint.RuleFailure[] {
|
||||
const configs = <NoNodejsGlobalsConfig[]>this.getOptions().ruleArguments;
|
||||
|
||||
for (const config of configs) {
|
||||
if (minimatch(sourceFile.fileName, config.target)) {
|
||||
return this.applyWithWalker(new NoNodejsGlobalsRuleWalker(sourceFile, program, this.getOptions(), config));
|
||||
}
|
||||
}
|
||||
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
class NoNodejsGlobalsRuleWalker extends AbstractGlobalsRuleWalker {
|
||||
|
||||
getDefinitionPattern(): string {
|
||||
return '@types/node';
|
||||
}
|
||||
|
||||
getDisallowedGlobals(): string[] {
|
||||
// https://nodejs.org/api/globals.html#globals_global_objects
|
||||
return [
|
||||
"Buffer",
|
||||
"__dirname",
|
||||
"__filename",
|
||||
"clearImmediate",
|
||||
"exports",
|
||||
"global",
|
||||
"module",
|
||||
"process",
|
||||
"setImmediate"
|
||||
];
|
||||
}
|
||||
}
|
||||
@@ -84,7 +84,7 @@ export class CmsUtils {
|
||||
// CMS APIs
|
||||
public async getCmsService(): Promise<mssql.ICmsService> {
|
||||
if (!this._cmsService) {
|
||||
this._cmsService = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.mssql).cmsService;
|
||||
this._cmsService = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.IExtension).cmsService;
|
||||
}
|
||||
return this._cmsService;
|
||||
}
|
||||
|
||||
@@ -371,7 +371,7 @@ export class DataTierApplicationWizard {
|
||||
}
|
||||
|
||||
private static async getService(providerName: string): Promise<mssql.IDacFxService> {
|
||||
const service = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.mssql).dacFx;
|
||||
const service = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.IExtension).dacFx;
|
||||
return service;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ if (context.RunTest) {
|
||||
setup(async function () {
|
||||
// Set up CMS provider
|
||||
if (!cmsService) {
|
||||
cmsService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.mssql)).cmsService;
|
||||
cmsService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.IExtension)).cmsService;
|
||||
assert(cmsService !== undefined);
|
||||
}
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ if (context.RunTest) {
|
||||
const databaseName = 'ADS_deployDacpac_' + now.getTime().toString();
|
||||
|
||||
try {
|
||||
const dacfxService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.mssql)).dacFx;
|
||||
const dacfxService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.IExtension)).dacFx;
|
||||
assert(dacfxService, 'DacFx Service Provider is not available');
|
||||
|
||||
// Deploy dacpac
|
||||
@@ -72,7 +72,7 @@ if (context.RunTest) {
|
||||
const databaseName = 'ADS_importBacpac_' + now.getTime().toString();
|
||||
|
||||
try {
|
||||
let dacfxService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.mssql)).dacFx;
|
||||
let dacfxService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.IExtension)).dacFx;
|
||||
assert(dacfxService, 'DacFx Service Provider is not available');
|
||||
|
||||
// Import bacpac
|
||||
|
||||
@@ -31,7 +31,7 @@ if (context.RunTest) {
|
||||
suiteSetup(async function () {
|
||||
let attempts: number = 20;
|
||||
while (attempts > 0) {
|
||||
schemaCompareService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.mssql)).schemaCompare;
|
||||
schemaCompareService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.IExtension)).schemaCompare;
|
||||
if (schemaCompareService) {
|
||||
break;
|
||||
}
|
||||
@@ -120,7 +120,7 @@ class SchemaCompareTester {
|
||||
const targetDB: string = 'ads_schemaCompare_targetDB_' + now.getTime().toString();
|
||||
|
||||
try {
|
||||
let dacfxService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.mssql)).dacFx;
|
||||
let dacfxService = ((await vscode.extensions.getExtension(mssql.extension.name).activate() as mssql.IExtension)).dacFx;
|
||||
assert(dacfxService, 'DacFx Service Provider is not available');
|
||||
let result1 = await dacfxService.deployDacpac(dacpac1, sourceDB, true, ownerUri, azdata.TaskExecutionMode.execute);
|
||||
let result2 = await dacfxService.deployDacpac(dacpac2, targetDB, true, ownerUri, azdata.TaskExecutionMode.execute);
|
||||
@@ -200,7 +200,7 @@ class SchemaCompareTester {
|
||||
const targetDB: string = 'ads_schemaCompare_targetDB_' + now.getTime().toString();
|
||||
|
||||
try {
|
||||
let dacfxService = (vscode.extensions.getExtension('mssql').exports as mssql.mssql).dacFx;
|
||||
let dacfxService = (vscode.extensions.getExtension('mssql').exports as mssql.IExtension).dacFx;
|
||||
assert(dacfxService, 'DacFx Service Provider is not available');
|
||||
let result = await dacfxService.deployDacpac(path.join(__dirname, 'testData/Database2.dacpac'), targetDB, true, ownerUri, azdata.TaskExecutionMode.execute);
|
||||
|
||||
@@ -258,7 +258,7 @@ class SchemaCompareTester {
|
||||
assert(schemaCompareResult.errorMessage === null, `Expected: there should be no error. Actual Error message: "${schemaCompareResult.errorMessage}"`);
|
||||
assert(schemaCompareResult.success === true, `Expected: success in schema compare, Actual: Failure`);
|
||||
assert(schemaCompareResult.differences.length === 4, `Expected: 4 differences. Actual differences: "${schemaCompareResult.differences.length}"`);
|
||||
assert(schemaCompareResult.operationId === operationId, `Operation Id Expected to be same as passed. Expected : ${operationId}, Actual ${schemaCompareResult.operationId}`)
|
||||
assert(schemaCompareResult.operationId === operationId, `Operation Id Expected to be same as passed. Expected : ${operationId}, Actual ${schemaCompareResult.operationId}`);
|
||||
}
|
||||
|
||||
private async assertScriptGenerationResult(resultstatus: azdata.ResultStatus, server: string, database: string): Promise<void> {
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
|
||||
"Once accepted there, we are happy to receive an update request."
|
||||
],
|
||||
"version": "https://github.com/microsoft/vscode-markdown-tm-grammar/commit/05ccfa3db6edbd357390431f9e316adb38ba41d8",
|
||||
"version": "https://github.com/microsoft/vscode-markdown-tm-grammar/commit/eb3898715b50d7911377a650e383a768a3a21f25",
|
||||
"name": "Markdown",
|
||||
"scopeName": "text.html.markdown",
|
||||
"patterns": [
|
||||
@@ -1855,12 +1855,12 @@
|
||||
"name": "markup.fenced_code.block.markdown"
|
||||
},
|
||||
"heading": {
|
||||
"match": "(?:^|\\G)[ ]{0,3}((#{1,6})\\s*(?=[\\S[^#]]).*?\\s*(#{1,6})?)$\\n?",
|
||||
"match": "(?:^|\\G)[ ]{0,3}((#{1,6})\\s+(?=[\\S[^#]]).*?\\s*(#{1,6})?)$\\n?",
|
||||
"captures": {
|
||||
"1": {
|
||||
"patterns": [
|
||||
{
|
||||
"match": "(#{6})\\s*(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"match": "(#{6})\\s+(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"name": "heading.6.markdown",
|
||||
"captures": {
|
||||
"1": {
|
||||
@@ -1875,7 +1875,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"match": "(#{5})\\s*(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"match": "(#{5})\\s+(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"name": "heading.5.markdown",
|
||||
"captures": {
|
||||
"1": {
|
||||
@@ -1890,7 +1890,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"match": "(#{4})\\s*(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"match": "(#{4})\\s+(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"name": "heading.4.markdown",
|
||||
"captures": {
|
||||
"1": {
|
||||
@@ -1905,7 +1905,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"match": "(#{3})\\s*(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"match": "(#{3})\\s+(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"name": "heading.3.markdown",
|
||||
"captures": {
|
||||
"1": {
|
||||
@@ -1920,7 +1920,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"match": "(#{2})\\s*(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"match": "(#{2})\\s+(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"name": "heading.2.markdown",
|
||||
"captures": {
|
||||
"1": {
|
||||
@@ -1935,7 +1935,7 @@
|
||||
}
|
||||
},
|
||||
{
|
||||
"match": "(#{1})\\s*(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"match": "(#{1})\\s+(?=[\\S[^#]])(.*?)\\s*(\\s+#+)?$\\n?",
|
||||
"name": "heading.1.markdown",
|
||||
"captures": {
|
||||
"1": {
|
||||
@@ -1993,7 +1993,7 @@
|
||||
"1": {
|
||||
"patterns": [
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -2015,7 +2015,7 @@
|
||||
"begin": "(\\s*|$)",
|
||||
"patterns": [
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
}
|
||||
],
|
||||
"while": "(?i)^(?!.*</(script|style|pre)>)"
|
||||
@@ -2023,10 +2023,10 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"begin": "(?i)(^|\\G)\\s*(?=</?(address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h1|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul)(\\s|$|/?>))",
|
||||
"begin": "(?i)(^|\\G)\\s*(?=</?[a-zA-Z]+[^\\s/>]*(\\s|$|/?>))",
|
||||
"patterns": [
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
}
|
||||
],
|
||||
"while": "^(?!\\s*$)"
|
||||
@@ -2035,7 +2035,7 @@
|
||||
"begin": "(^|\\G)\\s*(?=(<[a-zA-Z0-9\\-](/?>|\\s.*?>)|</[a-zA-Z0-9\\-]>)\\s*$)",
|
||||
"patterns": [
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
}
|
||||
],
|
||||
"while": "^(?!\\s*$)"
|
||||
@@ -2095,7 +2095,7 @@
|
||||
"include": "#inline"
|
||||
},
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
},
|
||||
{
|
||||
"include": "#heading-setext"
|
||||
@@ -2152,7 +2152,7 @@
|
||||
"include": "#inline"
|
||||
},
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
},
|
||||
{
|
||||
"include": "#heading-setext"
|
||||
@@ -2246,7 +2246,7 @@
|
||||
"end": "(?<=>)",
|
||||
"patterns": [
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -2391,7 +2391,7 @@
|
||||
"end": "(?<=>)",
|
||||
"patterns": [
|
||||
{
|
||||
"include": "text.html.basic"
|
||||
"include": "text.html.derivative"
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -24,8 +24,9 @@
|
||||
"onCommand:markdown.showLockedPreviewToSide",
|
||||
"onCommand:markdown.showSource",
|
||||
"onCommand:markdown.showPreviewSecuritySelector",
|
||||
"onWebviewPanel:markdown.preview",
|
||||
"onCommand:notebook.showPreview"
|
||||
"onCommand:markdown.api.render",
|
||||
"onCommand:notebook.showPreview",
|
||||
"onWebviewPanel:markdown.preview"
|
||||
],
|
||||
"contributes": {
|
||||
"commands": [
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
import { ActiveLineMarker } from './activeLineMarker';
|
||||
import { onceDocumentLoaded } from './events';
|
||||
import { createPosterForVsCode } from './messaging';
|
||||
import { getEditorLineNumberForPageOffset, scrollToRevealSourceLine } from './scroll-sync';
|
||||
import { getEditorLineNumberForPageOffset, scrollToRevealSourceLine, getLineElementForFragment } from './scroll-sync';
|
||||
import { getSettings, getData } from './settings';
|
||||
import throttle = require('lodash.throttle');
|
||||
|
||||
@@ -19,7 +19,7 @@ const settings = getSettings();
|
||||
const vscode = acquireVsCodeApi();
|
||||
|
||||
// Set VS Code state
|
||||
let state = getData<{ line: number }>('data-state');
|
||||
let state = getData<{ line: number, fragment: string }>('data-state');
|
||||
vscode.setState(state);
|
||||
|
||||
const messaging = createPosterForVsCode(vscode);
|
||||
@@ -34,10 +34,19 @@ window.onload = () => {
|
||||
onceDocumentLoaded(() => {
|
||||
if (settings.scrollPreviewWithEditor) {
|
||||
setTimeout(() => {
|
||||
const initialLine = +settings.line;
|
||||
if (!isNaN(initialLine)) {
|
||||
scrollDisabled = true;
|
||||
scrollToRevealSourceLine(initialLine);
|
||||
// Try to scroll to fragment if available
|
||||
if (state.fragment) {
|
||||
const element = getLineElementForFragment(state.fragment);
|
||||
if (element) {
|
||||
scrollDisabled = true;
|
||||
scrollToRevealSourceLine(element.line);
|
||||
}
|
||||
} else {
|
||||
const initialLine = +settings.line;
|
||||
if (!isNaN(initialLine)) {
|
||||
scrollDisabled = true;
|
||||
scrollToRevealSourceLine(initialLine);
|
||||
}
|
||||
}
|
||||
}, 0);
|
||||
}
|
||||
@@ -161,4 +170,4 @@ if (settings.scrollEditorWithPreview) {
|
||||
|
||||
function escapeRegExp(text: string) {
|
||||
return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -134,3 +134,12 @@ export function getEditorLineNumberForPageOffset(offset: number) {
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Try to find the html element by using a fragment id
|
||||
*/
|
||||
export function getLineElementForFragment(fragment: string): CodeLineElement | undefined {
|
||||
return getCodeLineElements().find((element) => {
|
||||
return element.element.id === fragment;
|
||||
});
|
||||
}
|
||||
|
||||
@@ -10,5 +10,5 @@ export { RefreshPreviewCommand } from './refreshPreview';
|
||||
export { ShowPreviewSecuritySelectorCommand } from './showPreviewSecuritySelector';
|
||||
export { MoveCursorToPositionCommand } from './moveCursorToPosition';
|
||||
export { ToggleLockCommand } from './toggleLock';
|
||||
// {{SQL CARBON EDIT}}
|
||||
export { ShowNotebookPreview } from './showNotebookPreview';
|
||||
export { ShowNotebookPreview } from './showNotebookPreview'; // {{SQL CARBON EDIT}}
|
||||
export { RenderDocument } from './renderDocument';
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { Command } from '../commandManager';
|
||||
import { MarkdownEngine } from '../markdownEngine';
|
||||
import { SkinnyTextDocument } from '../tableOfContentsProvider';
|
||||
|
||||
export class RenderDocument implements Command {
|
||||
public readonly id = 'markdown.api.render';
|
||||
|
||||
public constructor(
|
||||
private readonly engine: MarkdownEngine
|
||||
) { }
|
||||
|
||||
public async execute(document: SkinnyTextDocument | string): Promise<string> {
|
||||
return this.engine.render(document);
|
||||
}
|
||||
}
|
||||
@@ -83,7 +83,7 @@ function registerMarkdownCommands(
|
||||
commandManager.register(new commands.ShowPreviewSecuritySelectorCommand(previewSecuritySelector, previewManager));
|
||||
commandManager.register(new commands.OpenDocumentLinkCommand(engine));
|
||||
commandManager.register(new commands.ToggleLockCommand(previewManager));
|
||||
// {{SQL CARBON EDIT}}
|
||||
commandManager.register(new commands.ShowNotebookPreview(engine));
|
||||
commandManager.register(new commands.ShowNotebookPreview(engine)); // {{SQL CARBON EDIT}}
|
||||
commandManager.register(new commands.RenderDocument(engine));
|
||||
return commandManager;
|
||||
}
|
||||
|
||||
@@ -89,6 +89,7 @@ export class MarkdownPreview extends Disposable {
|
||||
private isScrolling = false;
|
||||
private _disposed: boolean = false;
|
||||
private imageInfo: { id: string, width: number, height: number }[] = [];
|
||||
private scrollToFragment: string | undefined;
|
||||
|
||||
public static async revive(
|
||||
webview: vscode.WebviewPanel,
|
||||
@@ -171,19 +172,19 @@ export class MarkdownPreview extends Disposable {
|
||||
this._locked = locked;
|
||||
this.editor = webview;
|
||||
|
||||
this.editor.onDidDispose(() => {
|
||||
this._register(this.editor.onDidDispose(() => {
|
||||
this.dispose();
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
this.editor.onDidChangeViewState(e => {
|
||||
this._register(this.editor.onDidChangeViewState(e => {
|
||||
this._onDidChangeViewStateEmitter.fire(e);
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
_contributionProvider.onContributionsChanged(() => {
|
||||
this._register(_contributionProvider.onContributionsChanged(() => {
|
||||
setImmediate(() => this.refresh());
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
this.editor.webview.onDidReceiveMessage((e: CacheImageSizesMessage | RevealLineMessage | DidClickMessage | ClickLinkMessage | ShowPreviewSecuritySelectorMessage | PreviewStyleLoadErrorMessage) => {
|
||||
this._register(this.editor.webview.onDidReceiveMessage((e: CacheImageSizesMessage | RevealLineMessage | DidClickMessage | ClickLinkMessage | ShowPreviewSecuritySelectorMessage | PreviewStyleLoadErrorMessage) => {
|
||||
if (e.source !== this._resource.toString()) {
|
||||
return;
|
||||
}
|
||||
@@ -213,21 +214,21 @@ export class MarkdownPreview extends Disposable {
|
||||
vscode.window.showWarningMessage(localize('onPreviewStyleLoadError', "Could not load 'markdown.styles': {0}", e.body.unloadedStyles.join(', ')));
|
||||
break;
|
||||
}
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
vscode.workspace.onDidChangeTextDocument(event => {
|
||||
this._register(vscode.workspace.onDidChangeTextDocument(event => {
|
||||
if (this.isPreviewOf(event.document.uri)) {
|
||||
this.refresh();
|
||||
}
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
topmostLineMonitor.onDidChangeTopmostLine(event => {
|
||||
this._register(topmostLineMonitor.onDidChangeTopmostLine(event => {
|
||||
if (this.isPreviewOf(event.resource)) {
|
||||
this.updateForView(event.resource, event.line);
|
||||
}
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
vscode.window.onDidChangeTextEditorSelection(event => {
|
||||
this._register(vscode.window.onDidChangeTextEditorSelection(event => {
|
||||
if (this.isPreviewOf(event.textEditor.document.uri)) {
|
||||
this.postMessage({
|
||||
type: 'onDidChangeTextEditorSelection',
|
||||
@@ -235,19 +236,19 @@ export class MarkdownPreview extends Disposable {
|
||||
source: this.resource.toString()
|
||||
});
|
||||
}
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
|
||||
vscode.window.onDidChangeActiveTextEditor(editor => {
|
||||
this._register(vscode.window.onDidChangeActiveTextEditor(editor => {
|
||||
if (editor && isMarkdownFile(editor.document) && !this._locked) {
|
||||
this.update(editor.document.uri);
|
||||
}
|
||||
}, null, this._disposables);
|
||||
}));
|
||||
}
|
||||
|
||||
private readonly _onDisposeEmitter = new vscode.EventEmitter<void>();
|
||||
private readonly _onDisposeEmitter = this._register(new vscode.EventEmitter<void>());
|
||||
public readonly onDispose = this._onDisposeEmitter.event;
|
||||
|
||||
private readonly _onDidChangeViewStateEmitter = new vscode.EventEmitter<vscode.WebviewPanelOnDidChangeViewStateEvent>();
|
||||
private readonly _onDidChangeViewStateEmitter = this._register(new vscode.EventEmitter<vscode.WebviewPanelOnDidChangeViewStateEvent>());
|
||||
public readonly onDidChangeViewState = this._onDidChangeViewStateEmitter.event;
|
||||
|
||||
public get resource(): vscode.Uri {
|
||||
@@ -264,7 +265,8 @@ export class MarkdownPreview extends Disposable {
|
||||
locked: this._locked,
|
||||
line: this.line,
|
||||
resourceColumn: this.resourceColumn,
|
||||
imageInfo: this.imageInfo
|
||||
imageInfo: this.imageInfo,
|
||||
fragment: this.scrollToFragment
|
||||
};
|
||||
}
|
||||
|
||||
@@ -284,8 +286,12 @@ export class MarkdownPreview extends Disposable {
|
||||
|
||||
public update(resource: vscode.Uri) {
|
||||
const editor = vscode.window.activeTextEditor;
|
||||
// Reposition scroll preview, position scroll to the top if active text editor
|
||||
// doesn't corresponds with preview
|
||||
if (editor && editor.document.uri.fsPath === resource.fsPath) {
|
||||
this.line = getVisibleLine(editor);
|
||||
} else {
|
||||
this.line = 0;
|
||||
}
|
||||
|
||||
// If we have changed resources, cancel any pending updates
|
||||
@@ -433,8 +439,8 @@ export class MarkdownPreview extends Disposable {
|
||||
if (this._resource === markdownResource) {
|
||||
const self = this;
|
||||
const resourceProvider: WebviewResourceProvider = {
|
||||
toWebviewResource: (resource) => {
|
||||
return this.editor.webview.toWebviewResource(normalizeResource(markdownResource, resource));
|
||||
asWebviewUri: (resource) => {
|
||||
return this.editor.webview.asWebviewUri(normalizeResource(markdownResource, resource));
|
||||
},
|
||||
get cspSource() { return self.editor.webview.cspSource; }
|
||||
};
|
||||
@@ -520,11 +526,15 @@ export class MarkdownPreview extends Disposable {
|
||||
}
|
||||
|
||||
private async onDidClickPreviewLink(path: string, fragment: string | undefined) {
|
||||
this.scrollToFragment = undefined;
|
||||
const config = vscode.workspace.getConfiguration('markdown', this.resource);
|
||||
const openLinks = config.get<string>('preview.openMarkdownLinks', 'inPreview');
|
||||
if (openLinks === 'inPreview') {
|
||||
const markdownLink = await resolveLinkToMarkdownFile(path);
|
||||
if (markdownLink) {
|
||||
if (fragment) {
|
||||
this.scrollToFragment = fragment;
|
||||
}
|
||||
this.update(markdownLink);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -65,7 +65,7 @@ export class MarkdownContentProvider {
|
||||
scrollEditorWithPreview: config.scrollEditorWithPreview,
|
||||
doubleClickToSwitchToEditor: config.doubleClickToSwitchToEditor,
|
||||
disableSecurityWarnings: this.cspArbiter.shouldDisableSecurityWarnings(),
|
||||
webviewResourceRoot: resourceProvider.toWebviewResource(markdownDocument.uri).toString(),
|
||||
webviewResourceRoot: resourceProvider.asWebviewUri(markdownDocument.uri).toString(),
|
||||
};
|
||||
|
||||
this.logger.log('provideTextDocumentContent', initialData);
|
||||
@@ -86,7 +86,7 @@ export class MarkdownContentProvider {
|
||||
data-state="${escapeAttribute(JSON.stringify(state || {}))}">
|
||||
<script src="${this.extensionResourcePath(resourceProvider, 'pre.js')}" nonce="${nonce}"></script>
|
||||
${this.getStyles(resourceProvider, sourceUri, config, state)}
|
||||
<base href="${resourceProvider.toWebviewResource(markdownDocument.uri)}">
|
||||
<base href="${resourceProvider.asWebviewUri(markdownDocument.uri)}">
|
||||
</head>
|
||||
<body class="vscode-body ${config.scrollBeyondLastLine ? 'scrollBeyondLastLine' : ''} ${config.wordWrap ? 'wordWrap' : ''} ${config.markEditorSelection ? 'showEditorSelection' : ''}">
|
||||
${body}
|
||||
@@ -110,7 +110,7 @@ export class MarkdownContentProvider {
|
||||
}
|
||||
|
||||
private extensionResourcePath(resourceProvider: WebviewResourceProvider, mediaFile: string): string {
|
||||
const webviewResource = resourceProvider.toWebviewResource(
|
||||
const webviewResource = resourceProvider.asWebviewUri(
|
||||
vscode.Uri.file(this.context.asAbsolutePath(path.join('media', mediaFile))));
|
||||
return webviewResource.toString();
|
||||
}
|
||||
@@ -126,17 +126,17 @@ export class MarkdownContentProvider {
|
||||
|
||||
// Assume it must be a local file
|
||||
if (path.isAbsolute(href)) {
|
||||
return resourceProvider.toWebviewResource(vscode.Uri.file(href)).toString();
|
||||
return resourceProvider.asWebviewUri(vscode.Uri.file(href)).toString();
|
||||
}
|
||||
|
||||
// Use a workspace relative path if there is a workspace
|
||||
const root = vscode.workspace.getWorkspaceFolder(resource);
|
||||
if (root) {
|
||||
return resourceProvider.toWebviewResource(vscode.Uri.file(path.join(root.uri.fsPath, href))).toString();
|
||||
return resourceProvider.asWebviewUri(vscode.Uri.file(path.join(root.uri.fsPath, href))).toString();
|
||||
}
|
||||
|
||||
// Otherwise look relative to the markdown file
|
||||
return resourceProvider.toWebviewResource(vscode.Uri.file(path.join(path.dirname(resource.fsPath), href))).toString();
|
||||
return resourceProvider.asWebviewUri(vscode.Uri.file(path.join(path.dirname(resource.fsPath), href))).toString();
|
||||
}
|
||||
|
||||
private computeCustomStyleSheetIncludes(resourceProvider: WebviewResourceProvider, resource: vscode.Uri, config: MarkdownPreviewConfiguration): string {
|
||||
@@ -176,7 +176,7 @@ export class MarkdownContentProvider {
|
||||
private getStyles(resourceProvider: WebviewResourceProvider, resource: vscode.Uri, config: MarkdownPreviewConfiguration, state?: any): string {
|
||||
const baseStyles: string[] = [];
|
||||
for (const resource of this.contributionProvider.contributions.previewStyles) {
|
||||
baseStyles.push(`<link rel="stylesheet" type="text/css" href="${escapeAttribute(resourceProvider.toWebviewResource(resource))}">`);
|
||||
baseStyles.push(`<link rel="stylesheet" type="text/css" href="${escapeAttribute(resourceProvider.asWebviewUri(resource))}">`);
|
||||
}
|
||||
|
||||
return `${baseStyles.join('\n')}
|
||||
@@ -188,7 +188,7 @@ export class MarkdownContentProvider {
|
||||
const out: string[] = [];
|
||||
for (const resource of this.contributionProvider.contributions.previewScripts) {
|
||||
out.push(`<script async
|
||||
src="${escapeAttribute(resourceProvider.toWebviewResource(resource))}"
|
||||
src="${escapeAttribute(resourceProvider.asWebviewUri(resource))}"
|
||||
nonce="${nonce}"
|
||||
charset="UTF-8"></script>`);
|
||||
}
|
||||
|
||||
@@ -118,7 +118,7 @@ export class MarkdownEngine {
|
||||
return md;
|
||||
}
|
||||
|
||||
private tokenize(
|
||||
private tokenizeDocument(
|
||||
document: SkinnyTextDocument,
|
||||
config: MarkdownItConfig,
|
||||
engine: MarkdownIt
|
||||
@@ -131,25 +131,30 @@ export class MarkdownEngine {
|
||||
this.currentDocument = document.uri;
|
||||
this._slugCount = new Map<string, number>();
|
||||
|
||||
const text = document.getText();
|
||||
const tokens = engine.parse(text.replace(UNICODE_NEWLINE_REGEX, ''), {});
|
||||
const tokens = this.tokenizeString(document.getText(), engine);
|
||||
this._tokenCache.update(document, config, tokens);
|
||||
return tokens;
|
||||
}
|
||||
|
||||
// {{SQL CARBON EDIT}} - Add renderText method
|
||||
public async renderText(document: vscode.Uri, text: string): Promise<string> {
|
||||
public async renderText(document: vscode.Uri, text: string): Promise<string> { // {{SQL CARBON EDIT}} - Add renderText method
|
||||
const config = this.getConfig(document);
|
||||
const engine = await this.getEngine(config);
|
||||
this.currentDocument = document;
|
||||
return engine.render(text, config);
|
||||
}
|
||||
// {{SQL CARBON EDIT}} - End
|
||||
|
||||
public async render(document: SkinnyTextDocument): Promise<string> {
|
||||
const config = this.getConfig(document.uri);
|
||||
private tokenizeString(text: string, engine: MarkdownIt) {
|
||||
return engine.parse(text.replace(UNICODE_NEWLINE_REGEX, ''), {});
|
||||
}
|
||||
|
||||
public async render(input: SkinnyTextDocument | string): Promise<string> {
|
||||
const config = this.getConfig(typeof input === 'string' ? undefined : input.uri);
|
||||
const engine = await this.getEngine(config);
|
||||
return engine.renderer.render(this.tokenize(document, config, engine), {
|
||||
const tokens = typeof input === 'string'
|
||||
? this.tokenizeString(input, engine)
|
||||
: this.tokenizeDocument(input, config, engine);
|
||||
|
||||
return engine.renderer.render(tokens, {
|
||||
...(engine as any).options,
|
||||
...config
|
||||
}, {});
|
||||
@@ -158,14 +163,14 @@ export class MarkdownEngine {
|
||||
public async parse(document: SkinnyTextDocument): Promise<Token[]> {
|
||||
const config = this.getConfig(document.uri);
|
||||
const engine = await this.getEngine(config);
|
||||
return this.tokenize(document, config, engine);
|
||||
return this.tokenizeDocument(document, config, engine);
|
||||
}
|
||||
|
||||
public cleanCache(): void {
|
||||
this._tokenCache.clean();
|
||||
}
|
||||
|
||||
private getConfig(resource: vscode.Uri): MarkdownItConfig {
|
||||
private getConfig(resource?: vscode.Uri): MarkdownItConfig {
|
||||
const config = vscode.workspace.getConfiguration('markdown', resource);
|
||||
return {
|
||||
breaks: config.get<boolean>('preview.breaks', false),
|
||||
@@ -306,13 +311,13 @@ async function getMarkdownOptions(md: () => MarkdownIt) {
|
||||
html: true,
|
||||
highlight: (str: string, lang?: string) => {
|
||||
// Workaround for highlight not supporting tsx: https://github.com/isagalaev/highlight.js/issues/1155
|
||||
if (lang && ['tsx', 'typescriptreact'].indexOf(lang.toLocaleLowerCase()) >= 0) {
|
||||
if (lang && ['tsx', 'typescriptreact'].includes(lang.toLocaleLowerCase())) {
|
||||
lang = 'jsx';
|
||||
}
|
||||
if (lang && lang.toLocaleLowerCase() === 'json5') {
|
||||
lang = 'json';
|
||||
}
|
||||
if (lang && lang.toLocaleLowerCase() === 'c#') {
|
||||
if (lang && ['c#', 'csharp'].includes(lang.toLocaleLowerCase())) {
|
||||
lang = 'cs';
|
||||
}
|
||||
if (lang && hljs.getLanguage(lang)) {
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as assert from 'assert';
|
||||
import * as vscode from 'vscode';
|
||||
import 'mocha';
|
||||
|
||||
import { InMemoryDocument } from './inMemoryDocument';
|
||||
import { createNewMarkdownEngine } from './engine';
|
||||
|
||||
const testFileName = vscode.Uri.file('test.md');
|
||||
|
||||
suite('markdown.engine', () => {
|
||||
suite('rendering', () => {
|
||||
const input = '# hello\n\nworld!';
|
||||
const output = '<h1 id="hello" data-line="0" class="code-line">hello</h1>\n'
|
||||
+ '<p data-line="2" class="code-line">world!</p>\n';
|
||||
|
||||
test('Renders a document', async () => {
|
||||
const doc = new InMemoryDocument(testFileName, input);
|
||||
const engine = createNewMarkdownEngine();
|
||||
assert.strictEqual(await engine.render(doc), output);
|
||||
});
|
||||
|
||||
test('Renders a string', async () => {
|
||||
const engine = createNewMarkdownEngine();
|
||||
assert.strictEqual(await engine.render(input), output);
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -6,7 +6,7 @@
|
||||
import * as vscode from 'vscode';
|
||||
|
||||
export interface WebviewResourceProvider {
|
||||
toWebviewResource(resource: vscode.Uri): vscode.Uri;
|
||||
asWebviewUri(resource: vscode.Uri): vscode.Uri;
|
||||
|
||||
readonly cspSource: string;
|
||||
}
|
||||
@@ -30,4 +30,4 @@ export function normalizeResource(
|
||||
}
|
||||
}
|
||||
return resource;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ import { ApiWrapper } from './apiWrapper';
|
||||
import { UploadFilesCommand, MkDirCommand, SaveFileCommand, PreviewFileCommand, CopyPathCommand, DeleteFilesCommand } from './objectExplorerNodeProvider/hdfsCommands';
|
||||
import { IPrompter } from './prompts/question';
|
||||
import CodeAdapter from './prompts/adapter';
|
||||
import { mssql } from './mssql';
|
||||
import { IExtension } from './mssql';
|
||||
import { OpenSparkJobSubmissionDialogCommand, OpenSparkJobSubmissionDialogFromFileCommand, OpenSparkJobSubmissionDialogTask } from './sparkFeature/dialog/dialogCommands';
|
||||
import { OpenSparkYarnHistoryTask } from './sparkFeature/historyTask';
|
||||
import { MssqlObjectExplorerNodeProvider, mssqlOutputChannel } from './objectExplorerNodeProvider/objectExplorerNodeProvider';
|
||||
@@ -32,7 +32,7 @@ import { SqlToolsServer } from './sqlToolsServer';
|
||||
const msgSampleCodeDataFrame = localize('msgSampleCodeDataFrame', 'This sample code loads the file into a data frame and shows the first 10 results.');
|
||||
|
||||
|
||||
export async function activate(context: vscode.ExtensionContext): Promise<mssql> {
|
||||
export async function activate(context: vscode.ExtensionContext): Promise<IExtension> {
|
||||
// lets make sure we support this platform first
|
||||
let supported = await Utils.verifyPlatform();
|
||||
|
||||
|
||||
2
extensions/mssql/src/mssql.d.ts
vendored
2
extensions/mssql/src/mssql.d.ts
vendored
@@ -23,7 +23,7 @@ export const enum extension {
|
||||
/**
|
||||
* The APIs provided by Mssql extension
|
||||
*/
|
||||
export interface mssql {
|
||||
export interface IExtension {
|
||||
/**
|
||||
* Gets the object explorer API that supports querying over the connections supported by this extension
|
||||
*
|
||||
|
||||
@@ -4,12 +4,12 @@
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { AppContext } from './appContext';
|
||||
import { mssql, ICmsService, IDacFxService, ISchemaCompareService, MssqlObjectExplorerBrowser } from './mssql';
|
||||
import { IExtension, ICmsService, IDacFxService, ISchemaCompareService, MssqlObjectExplorerBrowser } from './mssql';
|
||||
import * as constants from './constants';
|
||||
import { MssqlObjectExplorerNodeProvider } from './objectExplorerNodeProvider/objectExplorerNodeProvider';
|
||||
import * as azdata from 'azdata';
|
||||
|
||||
export function createMssqlApi(context: AppContext): mssql {
|
||||
export function createMssqlApi(context: AppContext): IExtension {
|
||||
return {
|
||||
get cmsService() {
|
||||
return context.getService<ICmsService>(constants.CmsService);
|
||||
|
||||
@@ -471,7 +471,7 @@ export class SchemaCompareOptionsDialog {
|
||||
}
|
||||
|
||||
private async reset() {
|
||||
let service = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.mssql).schemaCompare;
|
||||
let service = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.IExtension).schemaCompare;
|
||||
let result = await service.schemaCompareGetDefaultOptions();
|
||||
this.deploymentOptions = result.defaultDeploymentOptions;
|
||||
this.optionsChanged = true;
|
||||
|
||||
@@ -1012,7 +1012,7 @@ export class SchemaCompareMainWindow {
|
||||
}
|
||||
|
||||
private static async getService(providerName: string): Promise<mssql.ISchemaCompareService> {
|
||||
let service = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.mssql).schemaCompare;
|
||||
let service = (vscode.extensions.getExtension(mssql.extension.name).exports as mssql.IExtension).schemaCompare;
|
||||
return service;
|
||||
}
|
||||
|
||||
|
||||
@@ -114,7 +114,7 @@
|
||||
"fast-plist": "0.1.2",
|
||||
"glob": "^5.0.13",
|
||||
"gulp": "^4.0.0",
|
||||
"gulp-atom-electron": "^1.21.1",
|
||||
"gulp-atom-electron": "^1.22.0",
|
||||
"gulp-azure-storage": "^0.10.0",
|
||||
"gulp-buffer": "0.0.2",
|
||||
"gulp-concat": "^2.6.1",
|
||||
@@ -173,7 +173,7 @@
|
||||
"vinyl": "^2.0.0",
|
||||
"vinyl-fs": "^3.0.0",
|
||||
"vsce": "1.48.0",
|
||||
"vscode-debugprotocol": "1.35.0",
|
||||
"vscode-debugprotocol": "1.36.0-pre.0",
|
||||
"vscode-nls-dev": "^3.3.1",
|
||||
"webpack": "^4.16.5",
|
||||
"webpack-cli": "^3.1.0",
|
||||
|
||||
@@ -29,6 +29,6 @@
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"vscode-windows-ca-certs": "0.1.0",
|
||||
"vscode-windows-registry": "1.0.1"
|
||||
"vscode-windows-registry": "1.0.2"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -743,7 +743,7 @@ ms@2.0.0:
|
||||
resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8"
|
||||
integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=
|
||||
|
||||
nan@^2.0.0, nan@^2.12.1, nan@^2.13.2, nan@^2.14.0:
|
||||
nan@^2.0.0, nan@^2.13.2, nan@^2.14.0:
|
||||
version "2.14.0"
|
||||
resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c"
|
||||
integrity sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==
|
||||
@@ -1210,12 +1210,10 @@ vscode-windows-ca-certs@0.1.0:
|
||||
dependencies:
|
||||
node-addon-api "1.6.2"
|
||||
|
||||
vscode-windows-registry@1.0.1:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/vscode-windows-registry/-/vscode-windows-registry-1.0.1.tgz#bc9f765563eb6dc1c9ad9a41f9eaacc84dfadc7c"
|
||||
integrity sha512-q0aKXi9Py1OBdmXIJJFeJBzpPJMMUxMJNBU9FysWIXEwJyMQGEVevKzM2J3Qz/cHSc5LVqibmoUWzZ7g+97qRg==
|
||||
dependencies:
|
||||
nan "^2.12.1"
|
||||
vscode-windows-registry@1.0.2:
|
||||
version "1.0.2"
|
||||
resolved "https://registry.yarnpkg.com/vscode-windows-registry/-/vscode-windows-registry-1.0.2.tgz#b863e704a6a69c50b3098a55fbddbe595b0c124a"
|
||||
integrity sha512-/CLLvuOSM2Vme2z6aNyB+4Omd7hDxpf4Thrt8ImxnXeQtxzel2bClJpFQvQqK/s4oaXlkBKS7LqVLeZM+uSVIA==
|
||||
|
||||
xterm-addon-search@0.2.0-beta5:
|
||||
version "0.2.0-beta5"
|
||||
|
||||
@@ -17,7 +17,7 @@ arguments=(
|
||||
'--telemetry[show all telemetry events which VS code collects]'
|
||||
'--extensions-dir[set the root path for extensions]:root path:_directories'
|
||||
'--list-extensions[list the installed extensions]'
|
||||
'--category[filters instaled extension list by category, when using --list-extension]'
|
||||
'--category[filters installed extension list by category, when using --list-extension]'
|
||||
'--show-versions[show versions of installed extensions, when using --list-extension]'
|
||||
'--install-extension[install an extension]:id or path:_files -g "*.vsix(-.)"'
|
||||
'--uninstall-extension[uninstall an extension]:id or path:_files -g "*.vsix(-.)"'
|
||||
|
||||
@@ -23,13 +23,7 @@ exports.serviceWorker = [{
|
||||
dest: 'vs/workbench/contrib/resources/browser/resourceServiceWorkerMain.js'
|
||||
}];
|
||||
|
||||
exports.workerExtensionHost = [{
|
||||
name: 'vs/workbench/services/extensions/worker/extensionHostWorker',
|
||||
// include: [],
|
||||
prepend: ['vs/loader.js', 'vs/nls.js'],
|
||||
append: ['vs/workbench/services/extensions/worker/extensionHostWorkerMain'],
|
||||
dest: 'vs/workbench/services/extensions/worker/extensionHostWorkerMain.js'
|
||||
}];
|
||||
exports.workerExtensionHost = [entrypoint('vs/workbench/services/extensions/worker/extensionHostWorker')];
|
||||
|
||||
exports.workbench = require('./vs/workbench/buildfile').collectModules(['vs/workbench/workbench.desktop.main']);
|
||||
exports.workbenchWeb = entrypoint('vs/workbench/workbench.web.api');
|
||||
|
||||
@@ -14,7 +14,7 @@ import { URI, UriComponents } from 'vs/base/common/uri';
|
||||
import { IOpenerService } from 'vs/platform/opener/common/opener';
|
||||
import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace';
|
||||
import { IContextKey } from 'vs/platform/contextkey/common/contextkey';
|
||||
import { WebviewContentOptions, IWebviewService, WebviewElement } from 'vs/workbench/contrib/webview/common/webview';
|
||||
import { WebviewContentOptions, IWebviewService, WebviewElement } from 'vs/workbench/contrib/webview/browser/webview';
|
||||
import { generateUuid } from 'vs/base/common/uuid';
|
||||
|
||||
import { ComponentBase } from 'sql/workbench/browser/modelComponents/componentBase';
|
||||
|
||||
@@ -76,7 +76,9 @@ export class CustomTreeViewPanel extends ViewletPanel {
|
||||
}
|
||||
|
||||
renderBody(container: HTMLElement): void {
|
||||
this.treeView.show(container);
|
||||
if (this.treeView instanceof CustomTreeView) {
|
||||
this.treeView.show(container);
|
||||
}
|
||||
}
|
||||
|
||||
layoutBody(height: number, width: number): void {
|
||||
|
||||
@@ -17,7 +17,7 @@ import { IDashboardWebview, IDashboardViewService } from 'sql/platform/dashboard
|
||||
import { AngularDisposable } from 'sql/base/browser/lifecycle';
|
||||
|
||||
import * as azdata from 'azdata';
|
||||
import { WebviewElement, IWebviewService } from 'vs/workbench/contrib/webview/common/webview';
|
||||
import { WebviewElement, IWebviewService } from 'vs/workbench/contrib/webview/browser/webview';
|
||||
|
||||
@Component({
|
||||
template: '',
|
||||
|
||||
@@ -15,7 +15,7 @@ import { CommonServiceInterface } from 'sql/platform/bootstrap/browser/commonSer
|
||||
import { IDashboardWebview, IDashboardViewService } from 'sql/platform/dashboard/common/dashboardViewService';
|
||||
|
||||
import * as azdata from 'azdata';
|
||||
import { WebviewElement, IWebviewService } from 'vs/workbench/contrib/webview/common/webview';
|
||||
import { WebviewElement, IWebviewService } from 'vs/workbench/contrib/webview/browser/webview';
|
||||
|
||||
interface IWebviewWidgetConfig {
|
||||
id: string;
|
||||
|
||||
@@ -18,7 +18,7 @@ import { IDisposable, toDisposable } from 'vs/base/common/lifecycle';
|
||||
import { IWorkbenchLayoutService } from 'vs/workbench/services/layout/browser/layoutService';
|
||||
import * as DOM from 'vs/base/browser/dom';
|
||||
import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { IWebviewService, WebviewElement } from 'vs/workbench/contrib/webview/common/webview';
|
||||
import { IWebviewService, WebviewElement } from 'vs/workbench/contrib/webview/browser/webview';
|
||||
import { generateUuid } from 'vs/base/common/uuid';
|
||||
import { ITextResourcePropertiesService } from 'vs/editor/common/services/resourceConfiguration';
|
||||
|
||||
|
||||
@@ -855,6 +855,7 @@ export const EventType = {
|
||||
KEY_UP: 'keyup',
|
||||
// HTML Document
|
||||
LOAD: 'load',
|
||||
BEFORE_UNLOAD: 'beforeunload',
|
||||
UNLOAD: 'unload',
|
||||
ABORT: 'abort',
|
||||
ERROR: 'error',
|
||||
|
||||
@@ -9,6 +9,7 @@ import { onUnexpectedError } from 'vs/base/common/errors';
|
||||
import { IMarkdownString, parseHrefAndDimensions, removeMarkdownEscapes } from 'vs/base/common/htmlContent';
|
||||
import { defaultGenerator } from 'vs/base/common/idGenerator';
|
||||
import * as marked from 'vs/base/common/marked/marked';
|
||||
import * as insane from 'vs/base/common/insane/insane';
|
||||
import { parse } from 'vs/base/common/marshalling';
|
||||
import { cloneAndChange } from 'vs/base/common/objects';
|
||||
import { escape } from 'vs/base/common/strings';
|
||||
@@ -185,7 +186,20 @@ export function renderMarkdown(markdown: IMarkdownString, options: MarkdownRende
|
||||
renderer
|
||||
};
|
||||
|
||||
element.innerHTML = marked.parse(markdown.value, markedOptions);
|
||||
const allowedSchemes = ['http', 'https', 'mailto'];
|
||||
if (markdown.isTrusted) {
|
||||
allowedSchemes.push('command');
|
||||
}
|
||||
|
||||
const renderedMarkdown = marked.parse(markdown.value, markedOptions);
|
||||
element.innerHTML = insane(renderedMarkdown, {
|
||||
allowedSchemes,
|
||||
allowedAttributes: {
|
||||
'a': ['href', 'name', 'target', 'data-href'],
|
||||
'iframe': ['allowfullscreen', 'frameborder', 'src'],
|
||||
'img': ['src', 'title', 'alt', 'width', 'height']
|
||||
}
|
||||
});
|
||||
signalInnerHTML!();
|
||||
|
||||
return element;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
@font-face {
|
||||
font-family: "octicons2";
|
||||
src: url("./octicons2.ttf?064476e75412ccad4ae99d4bf24539b4") format("truetype"),
|
||||
url("./octicons2.svg?064476e75412ccad4ae99d4bf24539b4#octicons2") format("svg");
|
||||
src: url("./octicons2.ttf?dee9935d8deb764a470d194d9f0d07f7") format("truetype"),
|
||||
url("./octicons2.svg?dee9935d8deb764a470d194d9f0d07f7#octicons2") format("svg");
|
||||
}
|
||||
|
||||
.octicon, .mega-octicon {
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<missing-glyph horiz-adv-x="0" />
|
||||
<glyph glyph-name="alert"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M527.5 757.5H472.5L62.5 -8.75L90 -55H908.75L936.25 -8.75L527.5 757.5zM142.5 7.5L500 677.5L856.25 7.5H142.5zM468.75 445H531.25V195H468.75V445zM468.75 132.5H531.25V70H468.75V132.5z" />
|
||||
horiz-adv-x="1000" d=" M527.5 757.5H472.5L62.5 -8.75L90 -55H908.75L936.2499999999998 -8.75zM142.5 7.5L499.9999999999999 677.5L856.25 7.5zM468.7499999999999 445H531.25V195H468.75zM468.7499999999999 132.5H531.25V70H468.75z" />
|
||||
<glyph glyph-name="archive"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M906.25 757.5H93.75L62.5 726.25V538.75L93.75 507.5H125V-23.75L156.25 -55H843.75L875 -23.75V507.5H906.25L937.5 538.75V726.25L906.25 757.5zM843.75 570H156.25H125V695H875V570H843.75zM187.5 7.5V507.5H812.5V7.5H187.5zM687.5 382.5H312.5V320H687.5V382.5z" />
|
||||
@@ -198,7 +198,7 @@
|
||||
horiz-adv-x="1000" d=" M125 132.5H187.5V383.125H125V132.5zM187.5 445.625V476.25L218.75 507.5H495.625L522.5 491.875L549.375 445H812.5H906.25L937.5 413.75V-86.25L906.25 -117.5H218.75L187.5 -86.25V70H93.75L62.5 101.25V663.75L93.75 695H370L397.5 679.375L424.375 632.5H781.25L812.5 601.25V445L750 446.875V570H406.25L379.375 585.625L352.5 632.5H125V445.625H187.5zM504.375 398.125L477.5 445H250V257.5H446.875L472.5 303.75L500 320H875V382.5H531.25L504.375 398.125zM465.625 195H250V-55H875V257.5H518.75L493.125 211.25L465.625 195z" />
|
||||
<glyph glyph-name="file-symlink-directory"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M63.179375 663.75L94.429375 695H406.695625L428.7925 685.846875L482.093125 632.546875H906.31875L937.56875 601.296875V257.805L936.89375 257.125625V-23.88125L905.64375 -55.13125H93.75L62.5 -23.88125V413.2906250000001L63.179375 413.97V663.75zM875.0687499999999 570.046875V507.305625H468.78125L446.6843750000001 498.1525L393.0718750000001 444.5406250000001H125.679375V632.5H393.75125L447.051875 579.2L469.14875 570.046875H875.0687499999999zM406.01625 382.0406250000001H125.679375V351.5075000000001H124.976875V101.6937499999999H125V7.36875H874.39375V101.6937499999999H874.4125V351.5075000000001H874.39375V444.805625H481.725625L428.113125 391.19375L406.01625 382.0406250000001zM521.99 253.1075L523.12625 253.128125H611.4300000000001L526.0287500000001 338.529375L570.2231250000001 382.72375L708.975 243.97375L708.5749999999999 199.39L565.45125 61.2625000000001L522.0500000000001 106.2375000000001L609.495 190.63125H523.7268750000001C491.78375 189.3250000000001 461.606875 175.5875 439.64875 152.33125C416.800625 128.13125 405.591875 101.7625000000001 406.244375 70.65625L343.758125 69.3499999999999C342.716875 118.9625 361.625625 160.7375000000001 394.205625 195.239375C427.5518750000001 230.55625 473.45 251.3412500000001 521.99 253.1075z" />
|
||||
horiz-adv-x="1000" d=" M481.87625 632.5H906.25L938.125 601.25V257.5V-23.75L906.875 -55H94.375625L63.125625 -23.75V413.75V663.75L94.375625 695H406.875625L428.749375 685.62375L481.87625 632.5zM874.375 7.5V101.875L875 351.875625V445.625625H481.250625L427.501875 391.87625L405.624375 382.5H125V351.875625V101.875V7.5H874.375zM468.124375 507.5H874.375L875 569.374375H468.75L446.250625 578.750625L393.12375 631.874375H125V444.374375H392.501875L446.250625 498.12375L468.124375 507.5zM611.253125 253.128125L526.250625 338.753125L572.5 381.874375L711.25 243.1262500000001V198.75375L568.128125 60.625L524.3775 105.61875L611.875 190H526.250625C494.281875 188.5625 464.085 174.9187499999999 441.876875 151.88125C431.1175 141.175 422.6368750000001 128.4 416.94375 114.3249999999999C411.2512500000001 100.25625 408.4625000000001 85.1750000000001 408.75 70H346.25C345.860625 93.1687499999999 350.1443750000001 116.175 358.8425000000001 137.65C367.5406250000001 159.125 380.47375 178.6312499999999 396.875 195C429.649375 229.5450000000001 474.339375 250.32875 521.875 253.128125H611.253125z" />
|
||||
<glyph glyph-name="file-symlink-file"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M660.625 748.749375L865.625 542.5037500000001L875 519.996875V-86.25L843.75 -117.5H625V-55H812.5V445H593.75L562.5 476.25V695H187.5V445H125V726.25L156.25 757.5H638.75L660.625 748.749375zM625 507.5H812.5L625 695V507.5zM531.25 382.5H93.75L62.5 351.25V-86.25L93.75 -117.5H531.25L562.5 -86.25V351.25L531.25 382.5zM500 -55H125V320H500V-55zM437.5 226.25V38.75H375V150.8125L209.625 -14.625L165.375 29.625L330.810625 195H220.623125V257.5H406.25L437.5 226.25z" />
|
||||
@@ -225,7 +225,7 @@
|
||||
horiz-adv-x="1000" d=" M568.75 545L537.5 695H462.5L431.25 545L387.5 526.25L262.5 607.5L206.25 557.5L287.5 432.5L275 388.75L125 357.5V282.5L275 251.25L293.75 201.25L212.5 76.25L262.5 26.25L387.5 107.5L437.5 88.75L462.5 -55H537.5L568.75 95L618.75 113.75L743.75 32.5L793.75 82.5L712.5 207.5L731.25 257.5L875 282.5V357.5L725 388.75L706.25 438.75L787.5 563.75L737.5 613.75L612.5 532.5L568.75 545zM587.5 757.5L618.75 607.5L750 688.75L875 563.75L787.5 432.5L937.5 407.5V232.5L787.5 201.25L875 70L750 -55L618.75 32.5L587.5 -117.5H412.5L381.25 32.5L250 -48.75L125 76.25L212.5 207.5L62.5 232.5V407.5L212.5 438.75L131.25 570L256.25 695L387.5 607.5L412.5 757.5H587.5zM625 320C625 251.25 568.75 195 500 195C431.25 195 375 251.25 375 320C375 388.75 431.25 445 500 445C568.75 445 625 388.75 625 320zM500 257.5C537.5 257.5 562.5 282.5 562.5 320C562.5 357.5 537.5 382.5 500 382.5C462.5 382.5 437.5 357.5 437.5 320C437.5 282.5 462.5 257.5 500 257.5z" />
|
||||
<glyph glyph-name="gift"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M748.4625 646.5525C744.40625 666.81375 736.2125000000001 685.861875 724.475 702.329375C712.7375000000001 718.796875 697.74375 732.275625 680.5687499999999 741.798125C663.39375 751.32125 644.4625000000001 756.65125 625.1375 757.406875C605.814375 758.1620625 586.57375 754.32375 568.796875 746.1675C527.75125 732.096875 492.6175 703.03 469.526875 664.0375H467.91875C444.835 703.01125 409.7275 732.074375 368.708125 746.1675C350.931875 754.32375 331.690625 758.1620625 312.3662500000001 757.406875C293.04125 756.65125 274.1125 751.32125 256.938125 741.798125C239.763125 732.275625 224.76875 718.796875 213.03 702.329375C201.291875 685.861875 193.100625 666.81375 189.045 646.5525C185.550625 620.6949999999999 188.018125 594.42625 196.095625 570H93.75L62.5 538.75V-23.75L93.75 -55H843.75L875 -23.75V538.75L843.75 570H741.4375C749.4875 594.433125 751.94375 620.696875 748.4625 646.5525zM248.48 582.8612499999999C249.9 578.45 251.583125 574.154375 253.514375 570H437.5H439.215625V589.119375C435.4881250000001 611.95875 426.0725000000001 633.295625 411.96375 650.875C397.855 668.45375 379.576875 681.6225 359.06125 688.989375C348.096875 694.555 336.12375 697.464375 323.991875 697.51C311.86 697.55625 299.8675 694.7375 288.8668750000001 689.254375C277.866875 683.771875 268.1287500000001 675.759375 260.345 665.786875C252.56125 655.815 246.923125 644.1275 243.83125 631.55625C241.858125 615.1575 243.449375 598.4925000000001 248.48 582.8612499999999zM498.349375 570V589.119375C502.0875 611.905625 511.496875 633.188125 525.58375 650.72125C539.67 668.25375 557.9125 681.386875 578.384375 688.734375C589.34875 694.3 601.321875 697.209375 613.45375 697.255C625.5875 697.300625 637.58125 694.481875 648.58125 688.999375C659.58125 683.51625 669.3187499999999 675.504375 677.1 665.531875C684.8874999999999 655.559375 690.5250000000001 643.8725 693.6125 631.300625C695.5875 614.9075 694 598.2481250000001 688.98125 582.619375C687.59375 578.29375 685.9499999999999 574.079375 684.06875 570H500H498.349375zM437.5 507.5H125V7.5H437.5V507.5zM500 7.5H812.5V507.5H500V7.5z" />
|
||||
horiz-adv-x="1000" d=" M843.75 570H743.75C750 595 750 620 750 645C743.75 663.75 737.5 682.5 725 701.25C712.5 720 700 732.5 681.25 738.75C662.5 745 643.75 757.5 625 757.5C606.25 757.5 587.5 757.5 568.75 745C525 732.5 493.75 701.25 468.75 663.75C443.75 701.25 412.5 732.5 368.75 745C350 751.25 331.25 757.5 312.5 757.5C293.75 757.5 275 751.25 256.25 738.75C237.5 732.5 225 720 212.5 701.25C200 688.75 193.75 663.75 187.5 645C187.5 620 187.5 595 193.75 570H93.75L62.5 538.75V-23.75L93.75 -55H843.75L875 -23.75V538.75L843.75 570zM437.5 7.5H125V507.5H437.5V7.5zM437.5 570H250C250 576.25 250 576.25 250 582.5C243.75 601.25 243.75 613.75 243.75 632.5C250 645 250 657.5 262.5 663.75C268.75 676.25 281.25 682.5 293.75 688.75C300 695 312.5 695 325 695C337.5 695 350 695 362.5 688.75C381.25 682.5 400 670 412.5 651.25C425 632.5 437.5 613.75 437.5 588.75V570zM500 588.75C500 613.75 512.5 632.5 525 651.25C537.5 670 556.25 682.5 575 688.75C587.5 695 600 695 612.5 695C625 695 637.5 695 650 688.75C662.5 682.5 668.75 676.25 681.25 663.75C687.5 657.5 687.5 645 693.75 632.5C693.75 613.75 693.75 601.25 687.5 582.5C687.5 576.25 687.5 576.25 681.25 570H500V588.75zM812.5 7.5H500V507.5H812.5V7.5z" />
|
||||
<glyph glyph-name="gist-secret"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M865.625 542.5L660.625 748.75L638.75 757.5H156.25L125 726.25V-86.25L156.25 -117.5H442.861875L437.5 -112.1374999999999V-55H187.5V695H562.5V476.25L593.75 445H718.75H812.5V419.9156250000001C837.5875000000001 405.40375 859 385.246875 875 361.18125V520L865.625 542.5zM843.75 -117.5H531.25L500 -86.25V-55V163.75L531.25 195H593.75V257.5C593.75 326.535625 649.7125 382.5 718.75 382.5C756.0812500000001 382.5 789.59375 366.1325 812.5 340.181875C831.9499999999999 318.146875 843.75 289.20125 843.75 257.5V195H875H906.25L937.5 163.75V-86.25L906.25 -117.5H843.75zM875 132.5H843.75H812.5H593.75H562.5V-55H812.5H875V132.5zM812.5 507.5H625V695L812.5 507.5zM781.25 257.5V195H656.25V257.5C656.25 292.0175 684.2312499999999 320 718.75 320C753.2687500000001 320 781.25 292.0175 781.25 257.5z" />
|
||||
@@ -237,16 +237,16 @@
|
||||
horiz-adv-x="1000" d=" M875.28125 477.43C875.425 506.336875 867.51875 534.713125 852.4562500000001 559.3812499999999C837.3812499999999 584.049375 815.74375 604.035625 789.9562500000001 617.10125C764.1687499999999 630.166875 735.2562499999999 635.795625 706.45625 633.358125C677.64375 630.9200000000001 650.09375 620.51125 626.86875 603.2975C603.645625 586.084375 585.671875 562.7462499999999 574.96375 535.89625C564.255625 509.045625 561.2287500000001 479.744375 566.2318750000001 451.273125C571.235 422.8025 584.060625 396.28375 603.2800000000001 374.693125C622.5 353.09875 647.3562499999999 337.28375 675.0500000000001 329.016875C664.825 308.2325 649 290.706875 629.3625000000001 278.420625C609.724375 266.13125 587.05 259.5625 563.8818749999999 259.450625H439.3225C393.21 259.2887500000001 348.80875 241.9706250000001 314.7625 210.8718749999999V511.74625C352.5675 519.463125 386.160625 540.9425 409.029375 572.020625C431.8981250000001 603.098125 442.41125 641.56 438.5331250000001 679.9493749999999C434.655625 718.33875 416.66125 753.920625 388.039375 779.797C359.4175 805.673125 322.2075 820 283.6225 820C245.0375 820 207.8275 805.673125 179.205 779.797C150.583125 753.920625 132.589375 718.33875 128.71125 679.9493749999999C124.8325 641.56 135.3475 603.098125 158.215625 572.020625C181.08375 540.9425 214.6775 519.463125 252.4825 511.74625V131.8375C214.748125 124.625 180.95875 103.84375 157.488125 73.43125C134.0175 43.0124999999999 122.4875 5.0625 125.073125 -33.2687500000001C127.65875 -71.5999999999999 144.18125 -107.6624999999999 171.524375 -134.6437500000001C198.8675 -161.6312499999999 235.140625 -177.68125 273.5025 -179.7687499999999C311.8643750000001 -181.8499999999999 349.6625 -169.8249999999999 379.7675 -145.9562499999999C409.873125 -122.09375 430.2043750000001 -88.03125 436.9262500000001 -50.20625C443.64875 -12.3812499999999 436.299375 26.59375 416.260625 59.375C396.223125 92.15625 364.883125 116.46875 328.1525000000001 127.7312500000001C338.3975000000001 148.49375 354.226875 165.9875 373.8643750000001 178.25625C393.501875 190.525 416.16875 197.070625 439.3225 197.170625H563.8818749999999C602.744375 197.349375 640.58125 209.643125 672.1312499999999 232.338125C703.6750000000001 255.0325000000001 727.35625 286.99875 739.8875 323.7856250000001C777.2125 328.693125 811.5 346.96625 836.4 375.21625C861.2937499999999 403.46625 875.1062499999999 439.7775 875.28125 477.43zM190.2025 664.27C190.2025 682.746875 195.68125 700.808125 205.94625 716.17125C216.211875 731.53375 230.801875 743.5074999999999 247.871875 750.57875C264.9425000000001 757.649 283.72625 759.499125 301.8475 755.894375C319.969375 752.29 336.615 743.3925 349.68 730.3275C362.745625 717.2625 371.6425 700.6168749999999 375.2475 682.495C378.851875 664.3731250000001 377.001875 645.589375 369.93125 628.5193750000001C362.86 611.449375 350.88625 596.85875 335.52375 586.59375C320.160625 576.32875 302.099375 570.85 283.6225 570.85C258.8456250000001 570.85 235.084375 580.6925 217.564375 598.211875C200.045 615.73125 190.2025 639.493125 190.2025 664.27zM377.0425 -20.80625C377.0425 -39.2875 371.563125 -57.34375 361.2981250000001 -72.7062500000001C351.033125 -88.06875 336.443125 -100.04375 319.3725 -107.11875C302.3025 -114.1875 283.51875 -116.0375 265.3975000000001 -112.4375C247.275625 -108.8312499999999 230.63 -99.93125 217.564375 -86.86875C204.499375 -73.8000000000001 195.6025 -57.15625 191.9975 -39.0375C188.393125 -20.9124999999999 190.243125 -2.13125 197.31375 14.9375C204.384375 32.0125 216.35875 46.6 231.72125 56.86875C247.08375 67.13125 265.145625 72.6125000000001 283.6225 72.6125000000001C308.39875 72.6125000000001 332.160625 62.76875 349.68 45.25C367.2000000000001 27.725 377.0425 3.96875 377.0425 -20.80625zM719.58125 384.01C701.10625 384.01 683.0437499999999 389.490625 667.68125 399.754375C652.3187499999999 410.0193750000001 640.34375 424.61 633.275 441.68C626.20625 458.75 624.351875 477.53375 627.95625 495.655C631.5625 513.776875 640.45625 530.423125 653.525 543.488125C666.5875 556.5531249999999 683.2375000000001 565.45 701.35625 569.0550000000001C719.475 572.659375 738.2625 570.809375 755.33125 563.73875C772.40625 556.668125 786.9937500000001 544.694375 797.25625 529.33125C807.51875 513.96875 813 495.906875 813 477.43C813 452.65375 803.15625 428.8918750000001 785.6375 411.3725C768.11875 393.854375 744.35625 384.01 719.58125 384.01z" />
|
||||
<glyph glyph-name="git-commit"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M531.414375 507.5C531.304375 507.5 531.19375 507.5 531.08375 507.5C520.953125 507.489375 510.7993750000001 506.493125 500.7675 504.4975C470.4575 498.46875 442.616875 483.5875 420.7643750000001 461.735625C398.9125 439.88375 384.03125 412.0425 378.0025 381.733125C371.9731250000001 351.423125 375.0675 320.0068750000001 386.89375 291.4556250000001C398.7200000000001 262.905 418.7468750000001 238.5018750000001 444.4425 221.333125C470.1375 204.1637500000001 500.346875 195 531.25 195C572.69 195 612.433125 211.461875 641.7375 240.764375C671.0374999999999 270.066875 687.5 309.81 687.5 351.25C687.5 382.153125 678.3375000000001 412.3625 661.1687499999999 438.058125C644 463.753125 619.5956249999999 483.78 591.044375 495.60625C572.04625 503.475625 551.779375 507.47875 531.414375 507.5zM500 134.74375V-117.5H562.5V134.74375C580.4243749999999 137.33125 598.0525 142.1500000000001 614.961875 149.1500000000001C654.93125 165.70625 689.1 193.7437500000001 713.13125 229.71875C737.16875 265.6925 750 307.9856250000001 750 351.25C750 409.26625 726.95625 464.90625 685.93125 505.929375C652.34375 539.5150000000001 608.961875 561.0518750000001 562.5 567.7575V820H500V567.75625C467.830625 563.113125 436.9625 551.3375 409.719375 533.13375C373.745625 509.0975 345.708125 474.933125 329.15125 434.961875C312.5950000000001 394.990625 308.2625 351.0075 316.703125 308.57375C325.14375 266.140625 345.9775 227.1631249999999 376.570625 196.5706250000001C407.1631250000001 165.975 446.140625 145.14375 488.574375 136.70625C492.371875 135.9499999999999 496.181875 135.2937500000001 500 134.74375z" />
|
||||
horiz-adv-x="1000" d=" M686.175 507.5C652.6875 541.7506249999999 608.665625 563.76125 561.1725 570V820H498.6725V570C447.8575 562.346875 401.35875 537.05125 367.330625 498.543125C333.3025 460.035 313.916875 410.776875 312.5743750000001 359.405625C311.2325 308.035 328.02 257.8306250000001 359.99125 217.598125C391.9625 177.36875 437.076875 149.6687499999999 487.423125 139.375H498.6725V-110.625H561.1725V139.375C579.265 141.65625 596.941875 146.49375 613.6724999999999 153.75C653.7937499999999 170.0625 688.0125 198.18 711.8 234.375C735.75 270.28375 748.575 312.4575 748.675 355.6218750000001C748.61875 412.495625 726.16875 467.06375 686.175 507.5V507.5zM642.4250000000001 242.500625C613.02375 213.2731250000001 573.2525 196.87125 531.7975 196.8768750000001C500.914375 196.8562500000001 470.7175 205.983125 445.02125 223.114375C419.3243750000001 240.245 399.281875 264.60625 387.423125 293.1218750000001C378.4468750000001 314.4525 374.340625 337.51625 375.404375 360.634375C376.468125 383.7518750000001 382.6756250000001 406.341875 393.5718750000001 426.758125C404.46875 447.174375 419.7806250000001 464.91 438.395 478.660625C457.00875 492.411875 478.45625 501.833125 501.173125 506.24875C511.360625 507.17 521.61 507.17 531.7975 506.24875C553.2325000000001 506.709375 574.525625 502.6675 594.2975 494.3775C622.813125 482.518125 647.175 462.471875 664.30625 436.775625C681.4375 411.0793750000001 690.5687499999999 380.881875 690.55 349.9987500000001C689.81875 329.375 685.025 309.0975 676.44375 290.3293750000001C667.8625000000001 271.5606250000001 655.66875 254.67 640.55 240.62375L642.4250000000001 242.500625z" />
|
||||
<glyph glyph-name="git-compare"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M218.75 820C187.846875 820 157.6375 810.836125 131.9425 793.667125C106.246875 776.498125 86.22 752.095 74.39375 723.544375C62.5675 694.993125 59.4734375 663.576875 65.5025 633.266875C71.53125 602.9575 86.4125 575.11625 108.264375 553.264375C129.931875 531.596875 157.488125 516.7831249999999 187.5 510.656875V163.75C187.5 122.3125 203.961875 82.56875 233.264375 53.2625C262.566875 23.9625000000001 302.31 7.5 343.75 7.5H459.6875L380.25 -71.9375L424.4375 -116.1875L557.25 16.625V60.875L424.4375 193.6875L380.25 149.4375L459.6875 70H343.75C318.88625 70 295.04 79.875 277.45875 97.45625C259.8775 115.0374999999999 250 138.8875000000001 250 163.75V510.656875C259.7256250000001 512.641875 269.285625 515.55875 278.544375 519.39375C307.0950000000001 531.22 331.498125 551.246875 348.666875 576.941875C365.83625 602.6375 375 632.846875 375 663.75C375 684.26875 370.95875 704.586875 363.1062500000001 723.544375C355.25375 742.50125 343.744375 759.7263125 329.235625 774.2354375C314.72625 788.7445625 297.50125 800.253875 278.544375 808.1061875C259.5875000000001 815.958475 239.269375 820 218.75 820zM218.75 570C200.208125 570 182.0825 575.498125 166.665625 585.8C151.248125 596.1012499999999 139.231875 610.743125 132.13625 627.873125C125.040625 645.00375 123.184375 663.85375 126.80125 682.04C130.41875 700.225625 139.3475 716.9300000000001 152.45875 730.04125C165.57 743.1525 182.274375 752.08125 200.460625 755.69875C218.64625 759.316 237.49625 757.459375 254.626875 750.36375C271.7575 743.268125 286.39875 731.251875 296.700625 715.835C307.001875 700.4175 312.5 682.291875 312.5 663.75C312.5 638.88625 302.623125 615.04 285.0412500000001 597.45875C267.46 579.8775 243.614375 570 218.75 570zM812.5 191.84375V538.75C812.5 580.19 796.0374999999999 619.933125 766.7375 649.235625C737.43125 678.538125 697.6875 695 656.25 695H540.3125L619.75 774.43775L575.5625 818.68774375L442.75 685.875V641.625L575.5625 508.8125L619.75 553.0625L540.3125 632.5H656.25C681.1125 632.5 704.9625000000001 622.623125 722.54375 605.04125C740.125 587.46 750 563.614375 750 538.75V191.84375C730.25 187.8125 711.36875 179.975 694.44375 168.6687499999999C668.75 151.5 648.71875 127.09375 636.8937500000001 98.5437499999999C625.0687499999999 69.99375 621.97375 38.5749999999999 628 8.26875C634.03125 -22.0437499999999 648.9125 -49.88125 670.7625 -71.7374999999999C692.61875 -93.5875 720.4562500000001 -108.46875 750.76875 -114.5C781.0749999999999 -120.5250000000001 812.49375 -117.4312500000001 841.0437499999999 -105.6062499999999C869.59375 -93.78125 894 -73.75 911.16875 -48.05625C928.3375 -22.3625000000001 937.5 7.84375 937.5 38.75C937.5 80.1875 921.0375 119.93125 891.7375 149.2375C869.9125 171.0625 842.2937499999999 185.7625000000001 812.5 191.84375zM729.1625 -39.1999999999999C744.58125 -49.5 762.7062500000001 -55 781.25 -55C806.1125 -55 829.9625000000001 -45.125 847.54375 -27.54375C865.125 -9.9625000000001 875 13.8875 875 38.75C875 57.2937499999999 869.5 75.4187500000001 859.1999999999999 90.8375C848.9 106.25 834.25625 118.26875 817.125 125.3625C799.99375 132.4625 781.1437500000001 134.31875 762.9625 130.6999999999999C744.775 127.08125 728.06875 118.15 714.95625 105.0437500000001C701.85 91.93125 692.91875 75.225 689.3000000000001 57.0375C685.68125 38.8562499999999 687.54375 20.00625 694.6375 2.875C701.73125 -14.25625 713.75 -28.9 729.1625 -39.1999999999999z" />
|
||||
horiz-adv-x="1000" d=" M461.808125 8.0875L382.431875 87.46875L424.308125 131.2125L557.433125 -1.9125V-45.65625L424.308125 -178.78125L379.933125 -134.4125L459.3075 -55.0375H343.6825C323.14 -55.11875 302.78625 -51.13125 283.791875 -43.3062500000001C264.796875 -35.4875 247.538125 -23.98125 233.0125 -9.45625C218.486875 5.06875 206.981875 22.33125 199.15875 41.325C191.335625 60.31875 187.349375 80.675 187.4325 101.2125V448.0925C157.4875 454.468125 129.965 469.200625 108.058125 490.588125C86.3 512.5725 71.495625 540.4762499999999 65.49375 570.819375C59.4916875 601.161875 62.5575 632.6 74.3075 661.211875C86.166875 689.7275 106.21125 714.08875 131.9075 731.219375C157.60375 748.350625 187.799375 757.485 218.6825 757.464375C240.1175 757.925375 261.41 753.883125 281.1825 745.593125C300.123125 737.80125 317.3325000000001 726.330625 331.8150000000001 711.84875C346.296875 697.36625 357.765625 680.153125 365.5575 661.211875C373.848125 641.44 377.89375 620.146875 377.433125 598.711875C377.45375 567.82875 368.3225 537.631875 351.1912500000001 511.935625C334.060625 486.239375 309.6975 466.2 281.1825 454.34125C271.9106250000001 450.485 262.280625 447.553125 252.433125 445.59V101.8375C252.433125 76.9749999999999 262.309375 53.13125 279.89125 35.5500000000001C297.4725 17.96875 321.31875 8.0875 346.183125 8.0875H461.808125zM169.30875 523.7149999999999C184.685625 513.515 202.73 508.08 221.183125 508.09C238.14125 508.08375 254.78375 512.67625 269.3375000000001 521.380625C283.8918750000001 530.085 295.813125 542.576875 303.83 557.52125C311.8475000000001 572.465 315.660625 589.3025 314.864375 606.2425000000001C314.0675 623.1825 308.691875 639.586875 299.308125 653.7125C288.8243750000001 669.24375 274.061875 681.405625 256.808125 688.71625C239.778125 695.653125 221.074375 697.39 203.0575 693.713125C184.808125 690.184375 168.0325 681.275 154.889375 668.131875C141.745625 654.98875 132.836875 638.2168750000001 129.3075 619.9675C125.63125 601.95 127.37 583.24875 134.306875 566.21875C141.6175 548.9649999999999 153.776875 534.19875 169.30875 523.7149999999999zM814.93125 129.9625C844.975 123.8499999999999 872.575 109.08125 894.3125 87.4625000000001C923.5375 58.0625 939.9375 18.29375 939.93125 -23.1625C939.95625 -54.04375 930.825 -84.24375 913.69375 -109.9375C896.5625 -135.6375 872.1999999999999 -155.6812500000001 843.6875 -167.54375C815.1 -179.46875 783.6125000000001 -182.6312500000001 753.225 -176.625C722.8375 -170.625 694.91875 -155.73125 673.01875 -133.825C651.11875 -111.9249999999999 636.21875 -84.00625 630.21875 -53.61875C624.2162500000001 -23.2312499999999 627.38125 8.25 639.30625 36.8375C651.3625 65.1999999999999 671.3249999999999 89.5 696.80625 106.8375C713.60625 118.2125 732.525 126.0749999999999 752.43125 129.9625V476.8375C752.43125 501.70125 742.55625 525.5475 724.975 543.129375C707.3937500000001 560.7106249999999 683.55 570.5875 658.68125 570.5875H543.06L622.4325 491.21125L578.0600000000001 446.83875L444.933125 579.96375V623.71125L578.0600000000001 756.83625L622.4325 712.46375L543.06 633.0875H658.68125C679.225 633.1700000000001 699.5812500000001 629.184375 718.5749999999999 621.3612499999999C737.56875 613.538125 754.8249999999999 602.035 769.35 587.509375C783.875 572.98375 795.3875 555.7225000000001 803.20625 536.728125C811.03125 517.73375 815.0187500000001 497.379375 814.93125 476.8375V129.9625zM792.9937500000001 -116.4312500000001C814.5250000000001 -114.2687499999999 834.6375 -104.725 849.93125 -89.41875C865.24375 -74.125 874.7875 -54 876.95 -32.46875C879.11875 -10.9375 873.76875 10.6750000000001 861.80625 28.7125C851.325 44.24375 836.5625 56.4000000000001 819.30625 63.7125C802.28125 70.6500000000001 783.575 72.3874999999999 765.5625 68.7125C747.3125 65.18125 730.5374999999999 56.275 717.3937500000001 43.13125C704.25 29.9875 695.3375000000001 13.2125 691.8125 -5.0375C688.13125 -23.05 689.86875 -41.75625 696.80625 -58.78125C704.11875 -76.0375 716.275 -90.8062500000001 731.80625 -101.2875C749.84375 -113.2437500000001 771.4625000000001 -118.59375 792.9937500000001 -116.4312500000001z" />
|
||||
<glyph glyph-name="git-merge"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M194.4425 793.667125C220.1375 810.836125 250.346875 820 281.25 820C301.7693750000001 820 322.0875000000001 815.958475 341.044375 808.1061875C360.00125 800.253875 377.22625 788.7445625 391.735625 774.2354375C406.244375 759.7263125 417.75375 742.50125 425.6062500000001 723.544375C433.45875 704.586875 437.5 684.26875 437.5 663.75C437.5 632.846875 428.33625 602.6375 411.166875 576.941875C393.998125 551.246875 369.5950000000001 531.22 341.044375 519.39375C332.2325 515.74375 323.146875 512.925625 313.9056250000001 510.950625C320.36125 446.596875 348.834375 386.1006250000001 394.9675000000001 339.9675000000001C441.1006250000001 293.834375 501.5968750000001 265.3612500000001 565.9512500000001 258.905625C567.925625 268.1468749999999 570.74375 277.2325000000001 574.3937500000001 286.044375C586.2199999999999 314.5950000000001 606.2468749999999 338.998125 631.94375 356.166875C657.6374999999999 373.33625 687.84375 382.5 718.75 382.5C760.1875 382.5 799.93125 366.038125 829.2375 336.735625C858.5374999999999 307.433125 875 267.6900000000001 875 226.25C875 195.346875 865.8375000000001 165.1374999999999 848.6687499999999 139.44375C831.5 113.75 807.09375 93.71875 778.5437499999999 81.8937500000001C749.99375 70.0687499999999 718.5749999999999 66.9749999999999 688.26875 73C657.9562500000001 79.03125 630.11875 93.9125 608.264375 115.7625000000001C586.4125 137.61875 571.53125 165.4562500000001 565.5025 195.7668749999999L565.41625 196.2068750000001C520.02125 200.02125 475.73875 212.830625 435.184375 233.9912500000001C386.228125 259.535 344.14625 296.4975000000001 312.5 341.75V191.84375C322.248125 189.8562500000001 331.808125 186.9312500000001 341.044375 183.1062499999999C360.00125 175.25625 377.22625 163.74375 391.735625 149.2375C406.244375 134.725 417.75375 117.5 425.6062500000001 98.5437499999999C433.45875 79.5875 437.5 59.2687500000001 437.5 38.75C437.5 7.84375 428.33625 -22.3625000000001 411.166875 -48.05625C393.998125 -73.75 369.5950000000001 -93.78125 341.044375 -105.6062499999999C312.493125 -117.4312500000001 281.0768750000001 -120.5250000000001 250.7675 -114.5C220.4575 -108.46875 192.616875 -93.5875 170.764375 -71.7374999999999C148.9125 -49.88125 134.03125 -22.0437499999999 128.0025 8.26875C121.973125 38.5749999999999 125.0675 69.99375 136.89375 98.5437499999999C148.72 127.09375 168.746875 151.5 194.4425 168.6687499999999C211.366875 179.975 230.25 187.8125 250 191.84375V510.656875C219.988125 516.7831249999999 192.431875 531.596875 170.764375 553.264375C148.9125 575.11625 134.03125 602.9575 128.0025 633.266875C121.973125 663.576875 125.0675 694.993125 136.89375 723.544375C148.72 752.095 168.746875 776.498125 194.4425 793.667125zM229.165625 585.8C244.5825 575.498125 262.708125 570 281.25 570C306.114375 570 329.96 579.8775 347.5412500000001 597.45875C365.123125 615.04 375 638.88625 375 663.75C375 682.291875 369.501875 700.4175 359.200625 715.835C348.89875 731.251875 334.2575 743.268125 317.126875 750.36375C299.9962500000001 757.459375 281.14625 759.316 262.960625 755.69875C244.774375 752.08125 228.07 743.1525 214.95875 730.04125C201.8475 716.9300000000001 192.91875 700.225625 189.30125 682.04C185.684375 663.85375 187.540625 645.00375 194.63625 627.873125C201.731875 610.743125 213.748125 596.1012499999999 229.165625 585.8zM718.75 132.5C700.2062500000001 132.5 682.08125 138 666.6625 148.3000000000001C651.25 158.6 639.23125 173.24375 632.1375 190.375C625.04375 207.5037500000001 623.184375 226.35375 626.8000000000001 244.5400000000001C630.41875 262.7256250000001 639.35 279.43 652.45625 292.54125C665.56875 305.6525000000001 682.275 314.58125 700.4625 318.19875C718.6437500000001 321.8162500000001 737.49375 319.959375 754.625 312.8637500000001C771.75625 305.768125 786.4 293.7518750000001 796.6999999999999 278.3343749999999C807 262.9175 812.5 244.791875 812.5 226.25C812.5 201.385625 802.625 177.5374999999999 785.04375 159.95625C767.4625000000001 142.375 743.6125 132.5 718.75 132.5zM229.165625 -39.1999999999999C244.5825 -49.5 262.708125 -55 281.25 -55C306.114375 -55 329.96 -45.125 347.5412500000001 -27.54375C365.123125 -9.9625000000001 375 13.8875 375 38.75C375 57.2937499999999 369.501875 75.4187500000001 359.200625 90.8375C348.89875 106.25 334.2575 118.26875 317.126875 125.3625C299.9962500000001 132.4625 281.14625 134.31875 262.960625 130.6999999999999C244.774375 127.08125 228.07 118.15 214.95875 105.0437500000001C201.8475 91.93125 192.91875 75.225 189.30125 57.0375C185.684375 38.8562499999999 187.540625 20.00625 194.63625 2.875C201.731875 -14.25625 213.748125 -28.9 229.165625 -39.1999999999999z" />
|
||||
horiz-adv-x="1000" d=" M829.55625 336.840625C800.15625 366.068125 760.38125 382.4700000000001 718.9250000000001 382.464375C688.0437499999999 382.485 657.85 373.350625 632.15 356.219375C606.454375 339.08875 586.411875 314.7275 574.5525 286.2118750000001C570.90625 277.3493749999999 568.183125 268.1375 566.4275 258.7156250000001C502.53125 265.7275000000001 442.93875 294.318125 397.4856250000001 339.770625C352.033125 385.223125 323.43875 444.8193750000001 316.4275 508.715625C325.84875 510.47125 335.0643750000001 513.194375 343.9275 516.84125C372.443125 528.7 396.8037500000001 548.739375 413.935 574.435625C431.065625 600.131875 440.196875 630.32875 440.17625 661.211875C440.636875 682.646875 436.59125 703.94 428.3012500000001 723.711875C420.50875 742.653125 409.0425 759.866125 394.56 774.3484375C380.0775 788.83075 362.8687500000001 800.30125 343.9275 808.09325C324.1550000000001 816.38343125 302.8625 820.4254025 281.4275 819.9645975C250.544375 819.9851908125 220.346875 810.850375 194.650625 793.7195C168.954375 776.5885625 148.911875 752.2275 137.0525 723.711875C125.3025 695.1 122.23875 663.661875 128.240625 633.319375C134.2425 602.97625 149.043125 575.0725 170.80125 553.088125C192.708125 531.700625 220.2325 516.968125 250.1775 510.5925V191.8375000000001C230.268125 187.9500000000001 211.346875 180.0875 194.551875 168.7125C169.065625 151.3812499999999 149.10625 127.08125 137.0525 98.7125C125.123125 70.125 121.96 38.6437500000001 127.9625 8.25625C133.964375 -22.13125 148.86125 -50.05 170.763125 -71.95C192.665 -93.85 220.58375 -108.75 250.97125 -114.75C281.3581250000001 -120.75 312.844375 -117.59375 341.42875 -105.6625C369.944375 -93.8062500000001 394.305625 -73.75625 411.4362500000001 -48.0625C428.5668750000001 -22.36875 437.698125 7.83125 437.6775 38.7125C438.138125 60.15 434.0925 81.44375 425.8025 101.2125C418.010625 120.15625 406.54375 137.3625 392.06125 151.84375C377.579375 166.3250000000001 360.37 177.7937500000001 341.42875 185.5875C332.156875 189.4437499999999 322.525625 192.375 312.6775 194.3375V344.340625C344.968125 298.703125 387.865625 261.598125 437.6775 236.2168750000001C478.380625 215.3768749999999 522.745 202.6425000000001 568.3043749999999 198.718125C572.82375 176.05625 582.311875 154.675 596.086875 136.125C609.86125 117.5750000000001 627.58125 102.3125 647.9625 91.43125C668.34375 80.5562500000001 690.8874999999999 74.33125 713.96875 73.2125C737.05 72.09375 760.0875 76.1062499999999 781.4250000000001 84.9625C809.9437499999999 96.8249999999999 834.30625 116.86875 851.4375 142.5687499999999C868.56875 168.2625000000001 877.69375 198.459375 877.675 229.3425000000001C876.20625 270.06625 858.95 308.618125 829.55625 336.840625V336.840625zM317.053125 125.5875C334.3062500000001 118.28125 349.06875 106.11875 359.5525 90.5875C371.56625 72.5562500000001 376.96125 50.9250000000001 374.8225 29.3625C372.684375 7.8 363.14375 -12.3625 347.8225 -27.6812500000001C332.500625 -43.00625 312.346875 -52.5437499999999 290.7850000000001 -54.6875C269.223125 -56.8249999999999 247.58375 -51.425 229.55125 -39.4125C214.02 -28.9250000000001 201.8625 -14.1625 194.551875 3.09375C187.615 20.125 185.8775 38.825 189.554375 56.84375C193.083125 75.09375 201.9925 91.8625 215.135625 105.00625C228.27875 118.15 245.054375 127.05625 263.30375 130.5875C281.32125 134.2625000000001 300.023125 132.5250000000001 317.053125 125.5875V125.5875zM281.4275 569.964375C262.975 569.954375 244.92875 575.389375 229.55125 585.589375C214.02 596.073125 201.8625 610.839375 194.551875 628.093125C187.615 645.1231250000001 185.8775 663.8243749999999 189.554375 681.8418750000001C193.083125 700.09125 201.9925 716.863125 215.135625 730.00625C228.27875 743.149375 245.054375 752.05875 263.30375 755.5875C281.32125 759.2644375 300.023125 757.5274375 317.053125 750.590625C334.3062500000001 743.28 349.06875 731.118125 359.5525 715.586875C368.9362500000001 701.4612500000001 374.3125 685.056875 375.10875 668.1168749999999C375.905 651.176875 372.09375 634.339375 364.0768750000001 619.395625C356.059375 604.45125 344.13875 591.959375 329.584375 583.255C315.03 574.550625 298.38625 569.958125 281.4275 569.964375V569.964375zM785.175 159.9625C769.8812499999999 144.65625 749.76875 135.1125000000001 728.2375 132.9437499999999C706.70625 130.78125 685.0875 136.13125 667.0500000000001 148.0875C651.5187500000001 158.5749999999999 639.3625 173.3375 632.05 190.59375C625.1125 207.623125 623.3775 226.3243749999999 627.05625 244.341875C630.58125 262.59125 639.49375 279.363125 652.6374999999999 292.50625C665.78125 305.6493750000001 682.55625 314.5587500000001 700.80625 318.0875000000001C718.8187499999999 321.764375 737.525 320.0275000000001 754.5500000000001 313.090625C771.80625 305.78 786.56875 293.618125 797.0500000000001 278.086875C809.0125 260.051875 814.3625 238.436875 812.19375 216.906875C810.03125 195.3762499999999 800.4875000000001 175.25625 785.175 159.9625V159.9625z" />
|
||||
<glyph glyph-name="git-pull-request"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M131.9425 793.667125C157.6375 810.836125 187.846875 820 218.75 820C239.269375 820 259.5875000000001 815.958475 278.544375 808.1061875C297.50125 800.253875 314.72625 788.7445625 329.235625 774.2354375C343.744375 759.7263125 355.25375 742.50125 363.1062500000001 723.544375C370.95875 704.586875 375 684.26875 375 663.75C375 632.846875 365.83625 602.6375 348.666875 576.941875C331.498125 551.246875 307.0950000000001 531.22 278.544375 519.39375C269.285625 515.55875 259.7256250000001 512.641875 250 510.656875V191.84375C259.748125 189.8562500000001 269.308125 186.9312500000001 278.544375 183.1062499999999C297.50125 175.25625 314.72625 163.74375 329.235625 149.2375C343.744375 134.725 355.25375 117.5 363.1062500000001 98.5437499999999C370.95875 79.5875 375 59.2687500000001 375 38.75C375 7.84375 365.83625 -22.3625000000001 348.666875 -48.05625C331.498125 -73.75 307.0950000000001 -93.78125 278.544375 -105.6062499999999C249.993125 -117.4312500000001 218.576875 -120.5250000000001 188.2675 -114.5C157.9575 -108.46875 130.116875 -93.5875 108.264375 -71.7374999999999C86.4125 -49.88125 71.53125 -22.0437499999999 65.5025 8.26875C59.4734375 38.5749999999999 62.5675 69.99375 74.39375 98.5437499999999C86.22 127.09375 106.246875 151.5 131.9425 168.6687499999999C148.866875 179.975 167.75 187.8125 187.5 191.84375V510.656875C157.488125 516.7831249999999 129.931875 531.596875 108.264375 553.264375C86.4125 575.11625 71.53125 602.9575 65.5025 633.266875C59.4734375 663.576875 62.5675 694.993125 74.39375 723.544375C86.22 752.095 106.246875 776.498125 131.9425 793.667125zM218.961875 570H218.53875C200.07 570.041875 182.02375 575.5375 166.665625 585.8C151.248125 596.1012499999999 139.231875 610.743125 132.13625 627.873125C125.040625 645.00375 123.184375 663.85375 126.80125 682.04C130.41875 700.225625 139.3475 716.9300000000001 152.45875 730.04125C165.57 743.1525 182.274375 752.08125 200.460625 755.69875C218.64625 759.316 237.49625 757.459375 254.626875 750.36375C271.7575 743.268125 286.39875 731.251875 296.700625 715.835C307.001875 700.4175 312.5 682.291875 312.5 663.75C312.5 638.88625 302.623125 615.04 285.0412500000001 597.45875C267.509375 579.926875 243.749375 570.05625 218.961875 570zM750 191.84375C730.25 187.8125 711.36875 179.975 694.44375 168.6687499999999C668.75 151.5 648.71875 127.09375 636.8937500000001 98.5437499999999C625.0687499999999 69.99375 621.97375 38.5749999999999 628 8.26875C634.03125 -22.0437499999999 648.9125 -49.88125 670.7625 -71.7374999999999C692.61875 -93.5875 720.4562500000001 -108.46875 750.76875 -114.5C781.0749999999999 -120.5250000000001 812.49375 -117.4312500000001 841.0437499999999 -105.6062499999999C869.59375 -93.78125 894 -73.75 911.16875 -48.05625C928.3375 -22.3625000000001 937.5 7.84375 937.5 38.75C937.5 80.1875 921.0375 119.93125 891.7375 149.2375C869.9125 171.0625 842.2937499999999 185.7625000000001 812.5 191.84375V538.75C812.5 580.19 796.0374999999999 619.933125 766.7375 649.235625C737.43125 678.538125 697.6875 695 656.25 695H540.3125L619.75 774.43775L575.5625 818.68774375L442.75 685.875V641.625L575.5625 508.8125L619.75 553.0625L540.3125 632.5H656.25C681.1125 632.5 704.9625000000001 622.623125 722.54375 605.04125C740.125 587.46 750 563.614375 750 538.75V191.84375zM218.75 -55C200.208125 -55 182.0825 -49.5 166.665625 -39.1999999999999C151.248125 -28.9 139.231875 -14.25625 132.13625 2.875C125.040625 20.00625 123.184375 38.8562499999999 126.80125 57.0375C130.41875 75.225 139.3475 91.93125 152.45875 105.0437500000001C165.57 118.15 182.274375 127.08125 200.460625 130.6999999999999C218.64625 134.31875 237.49625 132.4625 254.626875 125.3625C271.7575 118.26875 286.39875 106.25 296.700625 90.8375C307.001875 75.4187500000001 312.5 57.2937499999999 312.5 38.75C312.5 13.8875 302.623125 -9.9625000000001 285.0412500000001 -27.54375C267.46 -45.125 243.614375 -55 218.75 -55zM729.1625 -39.1999999999999C744.58125 -49.5 762.7062500000001 -55 781.25 -55C806.1125 -55 829.9625000000001 -45.125 847.54375 -27.54375C865.125 -9.9625000000001 875 13.8875 875 38.75C875 57.2937499999999 869.5 75.4187500000001 859.1999999999999 90.8375C848.9 106.25 834.25625 118.26875 817.125 125.3625C799.99375 132.4625 781.1437500000001 134.31875 762.9625 130.6999999999999C744.775 127.08125 728.06875 118.15 714.95625 105.0437500000001C701.85 91.93125 692.91875 75.225 689.3000000000001 57.0375C685.68125 38.8562499999999 687.54375 20.00625 694.6375 2.875C701.73125 -14.25625 713.75 -28.9 729.1625 -39.1999999999999z" />
|
||||
horiz-adv-x="1000" d=" M382.431875 149.96875L461.808125 70.5875H346.183125C321.31875 70.5875 297.4725 80.46875 279.89125 98.0500000000001C262.309375 115.63125 252.433125 139.4749999999999 252.433125 164.3375V508.09C262.280625 510.053125 271.9106250000001 512.985 281.1825 516.84125C309.6975 528.7 334.060625 548.739375 351.1912500000001 574.435625C368.3225 600.131875 377.45375 630.32875 377.433125 661.211875C377.89375 682.646875 373.848125 703.94 365.5575 723.711875C357.765625 742.653125 346.296875 759.866125 331.8150000000001 774.3484375C317.3325000000001 788.83075 300.123125 800.30125 281.1825 808.09325C261.41 816.38343125 240.1175 820.4254025 218.6825 819.9645975C187.799375 819.9851908125 157.60375 810.850375 131.9075 793.7195C106.21125 776.5885625 86.166875 752.2275 74.3075 723.711875C62.5575 695.1 59.4916875 663.661875 65.49375 633.319375C71.495625 602.97625 86.3 575.0725 108.058125 553.088125C129.965 531.700625 157.4875 516.968125 187.4325 510.5925V163.7125C187.349375 143.175 191.335625 122.81875 199.15875 103.8250000000001C206.981875 84.83125 218.486875 67.56875 233.0125 53.04375C247.538125 38.51875 264.796875 27.0125 283.791875 19.1937499999999C302.78625 11.36875 323.14 7.38125 343.6825 7.4625H459.3075L379.933125 -71.9125L424.308125 -116.28125L557.433125 16.84375V60.5875L424.308125 193.7125L382.431875 149.96875zM221.183125 570.59C202.73 570.5799999999999 184.685625 576.015 169.30875 586.215C153.776875 596.69875 141.6175 611.465 134.306875 628.71875C127.37 645.74875 125.63125 664.45 129.3075 682.4675C132.836875 700.716875 141.745625 717.48875 154.889375 730.631875C168.0325 743.775 184.808125 752.684375 203.0575 756.213125C221.074375 759.8900625 239.778125 758.1530625 256.808125 751.21625C274.061875 743.905625 288.8243750000001 731.74375 299.308125 716.2125C308.691875 702.086875 314.0675 685.6825 314.864375 668.7425000000001C315.660625 651.8025 311.8475000000001 634.965 303.83 620.02125C295.813125 605.076875 283.8918750000001 592.585 269.3375000000001 583.880625C254.78375 575.17625 238.14125 570.58375 221.183125 570.59V570.59z M894.3125 149.9625000000001C872.575 171.58125 844.975 186.3499999999999 814.93125 192.4625V539.3375000000001C815.0187500000001 559.879375 811.03125 580.23375 803.20625 599.228125C795.3875 618.2225 783.875 635.48375 769.35 650.009375C754.8249999999999 664.535 737.56875 676.038125 718.5749999999999 683.8612499999999C699.5812500000001 691.684375 679.225 695.67 658.68125 695.5875H543.06L622.4325 774.9636875L578.0600000000001 819.33624375L444.933125 686.21125V642.46375L578.0600000000001 509.33875L622.4325 553.7112500000001L543.06 633.0875H658.68125C683.55 633.0875 707.3937500000001 623.210625 724.975 605.629375C742.55625 588.0475 752.43125 564.20125 752.43125 539.3375000000001V192.4625C732.525 188.5749999999999 713.60625 180.7125 696.80625 169.3375C671.3249999999999 152 651.3625 127.6999999999999 639.30625 99.3375C627.38125 70.75 624.2162500000001 39.2687500000001 630.21875 8.88125C636.21875 -21.50625 651.11875 -49.425 673.01875 -71.325C694.91875 -93.23125 722.8375 -108.125 753.225 -114.125C783.6125000000001 -120.13125 815.1 -116.96875 843.6875 -105.04375C872.1999999999999 -93.1812500000001 896.5625 -73.1375 913.69375 -47.4375C930.825 -21.74375 939.95625 8.45625 939.93125 39.3375C939.9375 80.7937500000001 923.5375 120.5625 894.3125 149.9625000000001V149.9625000000001zM849.93125 -26.91875C834.6375 -42.225 814.5250000000001 -51.76875 792.9937500000001 -53.9312500000001C771.4625000000001 -56.09375 749.84375 -50.7437500000001 731.80625 -38.7875C716.275 -28.3062500000001 704.11875 -13.5375 696.80625 3.71875C689.86875 20.74375 688.13125 39.45 691.8125 57.4625C695.3375000000001 75.7125 704.25 92.4875 717.3937500000001 105.63125C730.5374999999999 118.775 747.3125 127.68125 765.5625 131.2125C783.575 134.8874999999999 802.28125 133.1500000000001 819.30625 126.2125C836.5625 118.9000000000001 851.325 106.74375 861.80625 91.2125C873.76875 73.1750000000001 879.11875 51.5625 876.95 30.03125C874.7875 8.5 865.24375 -11.625 849.93125 -26.91875V-26.91875z" />
|
||||
<glyph glyph-name="github-action"
|
||||
unicode="⚦"
|
||||
horiz-adv-x="1000" d=" M190 195H351.25L391.875 132.5H158.75L127.5 163.75V726.25L158.75 757.5H908.75L940 726.25V428.125L877.5 537.5V695H190V195zM536.25 132.5L448.125 -84.375H585.625L937.5 276.25L891.875 382.5H790L841.25 473.75L789.375 570H610L552.5 533.125L410 220.625L466.875 132.5H536.25zM610 507.5H789.375L672.5 320H891.875L531.875 -45L637.5 195H466.875L610 507.5zM434.375 382.5H252.5V445H462.5L434.375 382.5zM378.125 257.5H252.5V320H406.25L378.125 257.5z" />
|
||||
@@ -261,7 +261,7 @@
|
||||
horiz-adv-x="1000" d=" M93.75 -55H937.5V7.5H125V820H62.5V-23.75L93.75 -55zM187.5 101.25V601.25L218.75 632.5H343.75L375 601.25V101.25L343.75 70H218.75L187.5 101.25zM312.5 132.5V570H250V132.5H312.5zM687.5 726.25V101.25L718.75 70H843.75L875 101.25V726.25L843.75 757.5H718.75L687.5 726.25zM812.5 695V132.5H750V695H812.5zM437.5 101.25V476.25L468.75 507.5H593.75L625 476.25V101.25L593.75 70H468.75L437.5 101.25zM562.5 132.5V445H500V132.5H562.5z" />
|
||||
<glyph glyph-name="heart"
|
||||
unicode="♥"
|
||||
horiz-adv-x="1000" d=" M907.1625 577.5074999999999C897.19375 595.451875 884.6625 611.971875 869.56875 627.068125C847.35 649 822.14375 665.8050000000001 793.9437499999999 677.483125C765.75 689.16125 736.125 695 705.075 695C674.03125 695 644.40625 689.16125 616.21125 677.483125C589.4612500000001 666.405 565.403125 650.713125 544.03625 630.4075C542.87875 629.3075 541.73 628.194375 540.588125 627.068125L500 586.0525L459.411875 627.068125C458.27 628.194375 457.12125 629.3075 455.96375 630.4075C434.596875 650.713125 410.53875 666.405 383.78875 677.483125C355.590625 689.16125 325.968125 695 294.921875 695C263.875625 695 234.253125 689.16125 206.055 677.483125C177.85625 665.8050000000001 152.64875 649 130.431875 627.068125C115.33625 611.971875 102.66125 595.451875 92.4075 577.5074999999999C82.438125 559.563125 74.89 540.906875 69.763125 521.538125C64.92125 502.169375 62.5 482.37375 62.5 462.150625C62.5 442.2125 64.92125 422.559375 69.763125 403.190625C74.89 384.1075 82.438125 365.593125 92.4075 347.64875C102.66125 329.704375 115.33625 313.184375 130.431875 298.088125L500 -71.0499999999999L869.56875 298.088125C884.6625 313.184375 897.19375 329.704375 907.1625 347.64875C917.41875 365.593125 924.96875 384.1075 929.8125 403.190625C934.9375 422.559375 937.5 442.2125 937.5 462.150625C937.5 482.37375 934.9375 502.169375 929.8125 521.538125C924.96875 540.906875 917.41875 559.563125 907.1625 577.5074999999999zM825.3937500000001 342.305C836.5375 353.4518750000001 845.5 365.34375 852.53125 378.001875L852.89375 378.66C860.4875 391.945 865.84375 405.218125 869.23125 418.5618750000001L869.3874999999999 419.185C873.1375 433.360625 875 447.638125 875 462.150625C875 477.02625 873.125 491.444375 869.3874999999999 505.545L869.16875 506.378125C865.7625 520.00375 860.41875 533.3456249999999 852.9 546.49875L852.525 547.1524999999999C845.51875 559.766875 836.60625 571.61875 825.5124999999999 582.7325000000001C808.9437499999999 599.05375 790.5375 611.24625 770.03125 619.73875C749.5500000000001 628.221875 728.0625 632.5 705.075 632.5C682.09375 632.5 660.6062499999999 628.221875 640.125 619.73875C619.6581249999999 611.2625 601.281875 599.1012499999999 584.739375 582.82875L500 497.1975L415.261875 582.8275C398.71875 599.100625 380.3425 611.2625 359.875 619.73875C339.39125 628.221875 317.906875 632.5 294.921875 632.5C271.9368750000001 632.5 250.4525 628.221875 229.96875 619.73875C209.46125 611.24625 191.053125 599.053125 174.484375 582.731875C163.344375 571.568125 154.203125 559.61 146.8575 546.8218750000001C139.508125 533.5318749999999 134.02875 519.93625 130.293125 505.960625C126.775625 491.746875 125 477.1825 125 462.150625C125 447.511875 126.74875 433.125625 130.265 418.8818750000001C133.984375 405.2075 139.45875 391.711875 146.8575 378.3350000000001C154.228125 365.5025 163.408125 353.505 174.600625 342.308125L500 17.2874999999999L825.3937500000001 342.305z" />
|
||||
horiz-adv-x="1000" d=" M930 521.24625C924.95625 540.984375 917.175 559.9200000000001 906.875 577.498125C896.9875000000001 595.78375 884.3312500000001 612.439375 869.375 626.875625C847.6875 648.4918749999999 822 665.681875 793.75 677.4962499999999C736.8875 700.834375 673.1125 700.834375 616.249375 677.4962499999999C589.5475 666.19375 565.016875 650.3325 543.75125 630.6212499999999L540.6268749999999 626.875625L500.000625 586.24875L459.374375 626.875625L456.25 630.6212499999999C434.984375 650.3325 410.45375 666.19375 383.75125 677.4962499999999C326.88625 700.834375 263.115 700.834375 206.25 677.4962499999999C177.99875 665.681875 152.31625 648.4918749999999 130.6275 626.875625C115.656875 612.294375 102.82125 595.669375 92.50125 577.498125C82.66125 559.770625 75.100625 540.869375 70 521.24625C64.70125 500.845 62.1788125 479.821875 62.500625 458.74625C62.533125 438.9262500000001 65.0525 419.1925 70 400C75.24 380.6225 82.795 361.945 92.50125 344.374375C102.98375 326.31125 115.803125 309.7075 130.6275 294.996875L500.000625 -74.38125L869.375 294.996875C884.19375 309.556875 896.8249999999999 326.190625 906.875 344.374375C917.05625 361.78875 924.8375 380.500625 930 400C934.95 419.1925 937.46875 438.9262500000001 937.5 458.74625C937.825 479.821875 935.3 500.845 930 521.24625V521.24625zM867.5 419.3712500000001C863.8249999999999 405.395 858.3625000000001 391.949375 851.25 379.37V379.37C843.825 366.411875 834.8 354.445625 824.375 343.74875L498.749375 18.75L173.126875 343.74875C162.515625 354.435 153.2775 366.39875 145.626875 379.37C138.426875 392.2025 132.761875 405.8400000000001 128.750625 419.996875C125.548125 434.151875 123.8725 448.613125 123.75125 463.125625C123.83625 478.053125 125.51125 492.92625 128.750625 507.498125C132.644375 521.6956250000001 138.315 535.346875 145.626875 548.125C153.123125 561.2 162.37625 573.183125 173.126875 583.7462499999999C189.183125 599.5875 208.0425 612.301875 228.74875 621.245C270.475 637.936875 317.024375 637.936875 358.75 621.245C379.323125 612.676875 398.01125 600.15 413.750625 584.371875L498.749375 498.7475L583.7525 584.371875C599.49125 600.15 618.175625 612.676875 638.75 621.245C680.475 637.936875 727.025 637.936875 768.75 621.245C789.45625 612.301875 808.31875 599.5875 824.375 583.7462499999999C835.26875 573.46 844.35 561.42125 851.25 548.125V548.125C858.3625000000001 535.545 863.8249999999999 522.1 867.5 508.12375V508.12375C871.2562499999999 493.84375 873.14375 479.141875 873.125 464.376875C873.98125 449.275625 872.71875 434.1225 869.375 419.3712500000001H867.5z" />
|
||||
<glyph glyph-name="history"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M844.1999999999999 49.75625C904.68125 126.8375 937.5375 221.9925 937.5 319.971875C937.50625 415.6275 906.1625 508.649375 848.2687500000001 584.7950000000001C790.36875 660.940625 709.11875 716.01375 616.9406250000001 741.581875C524.765 767.14975 426.75 761.8038125 337.901875 726.3625C249.054375 690.92125 174.27 627.3375 125 545.346875V694.971875H62.5V476.221875L93.75 444.971875H312.5V507.471875H175.6875C217.434375 579.65875 282.023125 635.895625 359.266875 667.31375C436.51125 698.7325 522.01625 703.544375 602.2975 680.9918749999999C682.5812500000001 658.43875 753.0687499999999 609.8043749999999 802.65625 542.758125C852.2375 475.71125 878.09375 394.066875 876.1375 310.700625C874.1875 227.334375 844.54375 146.9875 791.88125 82.3375C739.2125000000001 17.68125 666.5250000000001 -27.6 585.276875 -46.375C504.028125 -65.15 418.841875 -56.34375 343.151875 -21.34375C267.461875 13.65 205.575 72.85 167.25 146.90625L111.8125 118.03125C157.0025 31.0999999999999 230.06625 -38.15 319.2975 -78.61875C408.52875 -119.0875 508.761875 -128.43125 603.935625 -105.15625C699.1125000000001 -81.88125 783.71875 -27.33125 844.1999999999999 49.75625zM634.125 110.34375L678.375 154.59375L500 332.906875V569.969375H437.5V319.9693750000001L446.625 297.844375L634.125 110.34375z" />
|
||||
@@ -279,13 +279,13 @@
|
||||
horiz-adv-x="1000" d=" M93.75 -55H906.25L937.5 -23.75V257.5L764.375 736.25L735 757.5H266.875L237.5 736.875L62.5 273.75V-23.75L93.75 -55zM875 7.5H125V193.75H284.375625L330.625625 115.625L357.500625 100.625H643.125L670.625 116.875L713.75 193.75H875V7.5zM873.625 256.24875H695L668.125 239.99875L625 163.125H375.625625L328.750625 241.24875L301.875625 256.24875H125V257.5L288.75 695H712.5L873.625 256.24875z" />
|
||||
<glyph glyph-name="info"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M528.3356249999999 693.2325C612.93625 684.84625 692.21875 646.93875 752.625 585.744375C821.875 515.430625 861 419.925 861.1375 320.10875C861.1625 233.1168750000001 831.46875 148.9250000000001 777.29375 81.86875C723.13125 14.825 647.8874999999999 -30.9187499999999 564.498125 -47.79375C481.118125 -64.66875 394.518125 -51.7 319.4000000000001 -11C244.260625 29.7125 185.145 95.725 152.3375 175.975C119.52375 256.2468750000001 115.1325 345.6368750000001 139.9425 428.856875C164.749375 512.0643749999999 217.14875 583.76375 287.986875 631.884375C358.80375 679.99125 443.735 701.61875 528.3356249999999 693.2325zM534.5006249999999 755.4275C633.7375 745.590625 726.5500000000001 701.135 797.11875 629.634375C877.99375 547.5387499999999 923.4875 436.241875 923.6375 320.1475000000001C923.66875 218.9406250000001 889.13125 120.8499999999999 825.90625 42.59375C762.68125 -35.6687499999999 674.68125 -89.2624999999999 576.896875 -109.0500000000001C479.110625 -128.84375 377.58875 -113.6124999999999 289.625625 -65.95C201.6625 -18.2937499999999 132.699375 58.85 94.485 152.3249999999999C56.2705 245.8075 51.168375 349.8431250000001 80.0475 446.713125C108.926875 543.5825 170.00125 627.293125 252.866875 683.584375C335.731875 739.875625 435.2618750000001 765.2649375 534.5006249999999 755.4275zM468.749375 507.5L468.749375 445L531.249375 445L531.249375 507.5L468.749375 507.5zM468.749375 382.5L468.749375 132.5L531.249375 132.5L531.249375 382.5L468.749375 382.5z" />
|
||||
horiz-adv-x="1000" d=" M535.52375 755.545C634.96875 745.600625 727.7249999999999 700.92625 797.5 629.3775C873.51875 552.153125 918.46875 449.6550000000001 923.76875 341.42125C929.06875 233.188125 894.3625 126.7937499999999 826.25625 42.5125C763.6125000000001 -35.35625 675.70625 -88.85 577.7681249999999 -108.7125000000001C479.829375 -128.5749999999999 378.0275000000001 -113.55625 290.0025 -66.25C201.788125 -17.9124999999999 132.923125 59.3375 95.0025 152.5C56.912375 246.1462499999999 51.8418125 349.973125 80.626875 446.8825C109.35 543.4143750000001 170.498125 627.075 253.75125 683.7525C336.313125 740.0675 436.080625 765.489375 535.52375 755.545zM565.0037500000001 -47.49375C648.93125 -30.46875 724.2937499999999 15.275 778.125 81.875C836.4125 154.31875 866.06875 245.649375 861.4625 338.5143750000001C856.8562499999999 431.38 818.3000000000001 519.316875 753.125 585.630625C693.4312500000001 646.5675 614.216875 684.583125 529.3325 693.0375C444.448125 701.49125 359.293125 679.845625 288.7512500000001 631.88C235.653125 595.293125 192.7775 545.755 164.181875 487.959375C135.586875 430.16375 122.220625 366.025625 125.350625 301.61875C128.48 237.2125 148.001875 174.6687499999999 182.065625 119.9187500000001C216.129375 65.1687500000001 263.60625 20.0187500000001 320.0012500000001 -11.25C394.89625 -51.66875 481.6125 -64.49375 565.0037500000001 -47.49375zM531.87625 382.501875L469.37625 382.501875L469.37625 132.5L531.87625 132.5L531.87625 382.501875zM531.87625 507.501875L469.37625 507.501875L469.37625 445.001875L531.87625 445.001875L531.87625 507.501875z" />
|
||||
<glyph glyph-name="issue-closed"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M468.75 7.5C655.5437499999999 7.5 807.5375 156.4875000000001 812.38125 342.11375L871.90625 401.638125C873.95 385.1287500000001 875 368.311875 875 351.25C875 126.88125 693.11875 -55 468.75 -55C244.384375 -55 62.5 126.88125 62.5 351.25C62.5 575.615625 244.384375 757.5 468.75 757.5C603.229375 757.5 722.45 692.1575 796.3875 591.490625L751.63125 546.605C689.59375 636.265 586.031875 695 468.75 695C278.901875 695 125 541.098125 125 351.25C125 161.4000000000001 278.901875 7.5 468.75 7.5zM856.0625 474.190625L937.5 555.62375L893.125 599.99875L680 386.254375L593.750625 472.50875L549.375625 428.13375L657.5 320.004375H701.875L804.9812499999999 423.104375C804.9812499999999 423.1025 804.9812499999999 423.10125 804.9812499999999 423.1L856.06875 474.186875C856.06875 474.188125 856.06875 474.189375 856.0625 474.190625zM437.5 382.5V257.5H500V382.5V570H437.5V382.5zM437.5 132.5V195H500V132.5H437.5z" />
|
||||
<glyph glyph-name="issue-opened"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M93.75 351.25C93.75 144.1432188134525 261.6432188134525 -23.75 468.75 -23.75C675.8567811865476 -23.75 843.75 144.1432188134525 843.75 351.25C843.75 558.3567811865476 675.8567811865476 726.25 468.75 726.25C261.6432188134525 726.25 93.75 558.3567811865476 93.75 351.25z M500 570H437.5V257.5H500V570zM500 132.5H437.5V195H500V132.5z" />
|
||||
horiz-adv-x="1000" d=" M468.749375 757.5C388.40125 757.5 309.856875 733.673125 243.049375 689.03375C176.241875 644.3943750000001 124.17125 580.946875 93.42375 506.714375C62.675625 432.481875 54.631125 350.8006250000001 70.30625 271.995625C85.981875 193.19375 124.6725 120.8 181.4875 63.9875000000001C238.3025 7.175 310.690625 -31.51875 389.495625 -47.19375C468.3 -62.86875 549.9812499999999 -54.8249999999999 624.21375 -24.075C698.44375 6.66875 761.8937500000001 58.74375 806.53125 125.55C851.1750000000001 192.3562500000001 875 270.90125 875 351.25C875 458.994375 832.2 562.325 756.0124999999999 638.511875C679.825 714.69875 576.49375 757.5 468.749375 757.5zM468.749375 7.5C400.7625000000001 7.5 334.3 27.65625 277.770625 65.43125C221.24125 103.2000000000001 177.1825 156.89375 151.164375 219.70375C125.146875 282.51625 118.339375 351.63125 131.603125 418.3125C144.86625 484.993125 177.606875 546.2406249999999 225.680625 594.315C273.7550000000001 642.389375 335.00625 675.129375 401.6875 688.393125C468.368125 701.656875 537.48375 694.84875 600.295625 668.83125C663.10625 642.81375 716.79375 598.7581250000001 754.56875 542.22875C792.3375 485.699375 812.5 419.2375 812.5 351.25C812.5 260.081875 776.28125 172.65 711.8187499999999 108.1875C647.35 43.71875 559.9174999999999 7.5 468.749375 7.5zM500 570H437.5V257.5H500V570zM437.5 195H500V132.5H437.5V195z" />
|
||||
<glyph glyph-name="issue-reopened"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M125 382.5037500000001L330 466.87875L305.625 525.00375L160.625 462.50375C186.081875 536.62625 236.189375 599.776875 302.5856250000001 641.415625C368.981875 683.054375 447.65 700.6625 525.461875 691.301875C603.2731249999999 681.94125 675.51875 646.1775 730.15 589.979375C784.775 533.781875 818.4749999999999 460.549375 825.625 382.5037500000001H888.125C881.41875 473.84625 843.9499999999999 560.219375 781.83125 627.525C719.71875 694.83125 636.61875 739.095 546.10875 753.0925C455.595625 767.0900625 363.010625 749.995 283.4650000000001 704.596875C203.91875 659.19875 142.11 588.17875 108.125 503.12875L57.5 625.00375L0 601.25375L83.75 398.7537500000001L125 382.5037500000001zM452.500625 570H515.000625V257.5H452.500625V570zM452.500625 195H515.000625V132.5H452.500625V195zM883.75 299.375L967.5 97.5L910 70L858.75 195C824.49375 109.6187500000001 762.2375000000001 38.4125 682.18125 -6.9250000000001C602.1324999999999 -52.2625 509.0475 -69.0375 418.2043750000001 -54.50625C327.361875 -39.96875 244.15875 5.0125 182.249375 73.0625C120.34 141.11875 83.403125 228.19125 77.500625 320H140.000625V351.25C140.175625 270.7837500000001 168.625625 192.9375 220.37625 131.31875C272.1275 69.7062500000001 343.8875 28.2312499999999 423.114375 14.1625C502.340625 0.0875 583.9925000000001 14.30625 653.8000000000001 54.33125C723.60625 94.3562499999999 777.125 157.6437500000001 805 233.125L664.375 175L640 232.5L843.125 316.875L883.75 299.375z" />
|
||||
@@ -306,7 +306,7 @@
|
||||
horiz-adv-x="1000" d=" M709.4375 751.81C763.99375 740.70125 814.0625 713.746875 853.375 674.3199999999999C886.6125000000001 640.7975 911.03125 599.564375 924.44375 554.3043749999999C937.85625 509.04375 939.85 461.165 930.25 414.945C916.3375 351.58 881.325 294.8143750000001 830.9499999999999 253.94C780.56875 213.0650000000001 717.8125 190.5 652.9375 189.94375C625.56875 189.9 598.3375 193.88125 572.125 201.7574999999999L522.125 143.1937499999999L498.4375 132.25625H437.5V38.50625L406.25 7.25625H312.5V-86.49375L281.25 -117.74375H93.75L62.5 -86.49375V57.69375L71.625 79.75625L382.5 390.5700000000001C373.6775 418.9875 369.4575 448.6325 370 478.3825C370.76375 534.05375 387.9325 588.263125 419.3556250000001 634.224375C450.779375 680.185 495.061875 715.85625 546.660625 736.771875C598.2593750000001 757.6875 654.88125 762.918375 709.4375 751.81zM791.83125 301.8368750000001C831.08125 333.6287500000001 858.38125 377.805 869.25 427.1325L869.5 426.8200000000001C877.21875 462.88625 875.80625 500.309375 865.39375 535.6912500000001C854.975 571.073125 835.8875 603.293125 809.8625000000001 629.425625C783.8375 655.5587499999999 751.69375 674.77625 716.35625 685.334375C681.0125 695.8925 643.5999999999999 697.455625 607.5 689.8824999999999C558.79875 679.07375 515.114375 652.281875 483.40125 613.7731249999999C451.688125 575.264375 433.77 527.2525 432.5 477.3825C431.824375 448.950625 436.9056250000001 420.675625 447.4375 394.2575L440.5625 360.3825L125 44.75625V-55.24375H250V38.50625L281.25 69.75625H375V163.50625L406.25 194.75625H484.0625L538.8125 258.2575L573.875 267.0075000000001C599.149375 257.13125 626.05 252.0856250000001 653.1875 252.1325000000001C703.7 252.520625 752.58125 270.0450000000001 791.83125 301.8368750000001zM739.46875 472.5325C746.3375 482.810625 750 494.894375 750 507.255625C750 523.831875 743.4125 539.72875 731.69375 551.45C719.975 563.17125 704.075 569.755625 687.5 569.755625C675.1374999999999 569.755625 663.05625 566.0899999999999 652.775 559.2225000000001C642.5 552.355 634.4875 542.59375 629.75625 531.1737499999999C625.0250000000001 519.753125 623.789375 507.18625 626.1999999999999 495.0625C628.6125000000001 482.93875 634.5625 471.8025 643.30625 463.061875C652.04375 454.320625 663.1812500000001 448.368125 675.30625 445.9568750000001C687.4312500000001 443.545 700 444.783125 711.41875 449.513125C722.8375 454.24375 732.6 462.254375 739.46875 472.5325z" />
|
||||
<glyph glyph-name="keyboard"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M875 570H187.5L187.5 132.5H875V570zM187.5 632.5C152.9825 632.5 125 604.5175 125 570V132.5C125 97.9812499999999 152.9825 70 187.5 70H875C909.51875 70 937.5 97.9812499999999 937.5 132.5V570C937.5 604.5175 909.51875 632.5 875 632.5H187.5zM250 507.5H312.5V445H250V507.5zM437.5 507.5H375V445H437.5V507.5zM500 507.5H562.5V445H500V507.5zM687.5 507.5H625V445H687.5V507.5zM750 507.5H812.5V445H750V507.5zM375 320V382.5H250V320H375zM437.5 382.5H500V320H437.5V382.5zM625 382.5H562.5V320H625V382.5zM812.5 382.5V320H687.5V382.5H812.5zM312.5 257.5H250V195H312.5V257.5zM375 257.5H687.5V195H375V257.5zM812.5 257.5H750V195H812.5V257.5z" />
|
||||
horiz-adv-x="1000" d=" M875 632.5H187.5C170.92375 632.5 155.0275 625.918125 143.306875 614.196875C131.585625 602.47625 125 586.57625 125 570V132.5C125 115.925 131.585625 100.025 143.306875 88.3C155.0275 76.58125 170.92375 70 187.5 70H875C891.575 70 907.475 76.58125 919.19375 88.3C930.9125 100.025 937.5 115.925 937.5 132.5V570C937.5 586.57625 930.9125 602.47625 919.19375 614.196875C907.475 625.918125 891.575 632.5 875 632.5zM875 132.5H187.5V570H875V132.5zM687.5 507.5H625V445H687.5V507.5zM625 382.5H562.5V320H625V382.5zM750 507.5H812.5V445H750V507.5zM812.5 257.5H750V195H812.5V257.5zM375 257.5H687.5V195H375V257.5zM812.5 382.5H687.5V320H812.5V382.5zM500 507.5H562.5V445H500V507.5zM500 382.5H437.5V320H500V382.5zM250 257.5H312.5V195H250V257.5zM250 507.5H312.5V445H250V507.5zM437.5 507.5H375V445H437.5V507.5zM250 382.5H375V320H250V382.5z" />
|
||||
<glyph glyph-name="law"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M914.375 382.5L812.5 632.5H875V695H562.5V757.5H500V695H187.5V632.5H250L148.75 382.5H125V320H134.375C144.149375 288.880625 163.9225 261.8575 190.625 243.125C216.978125 224.015 248.6975 213.725 281.25 213.725C313.8025 213.725 345.521875 224.015 371.875 243.125C398.5850000000001 261.989375 418.52375 288.9400000000001 428.75 320H437.5V382.5H409.375L305 632.5H500V132.5H375L350.625 121.25L225.625 -35.625L250 -86.25H812.5L836.875 -35.625L711.875 121.25L687.5 132.5H562.5V632.5H758.125L653.75 382.5H625V320H634.375C644.5999999999999 289.035 664.325 262.0825000000001 690.75 242.9775C717.175 223.8725 748.95625 213.58875 781.5625 213.58875C814.16875 213.58875 845.9499999999999 223.8725 872.375 242.9775C898.8000000000001 262.0825000000001 918.525 289.035 928.75 320H937.5V382.5H914.375zM326.25 288.125C312.466875 280.4968750000001 297.0025 276.41625 281.25 276.25C265.68375 276.3318750000001 250.4012500000001 280.42125 236.875 288.125C223.081875 295.685625 211.46125 306.66125 203.125 320H359.375C351.109375 306.823125 339.734375 295.8781250000001 326.25 288.125zM341.875 382.5H216.875L279.375 532.5L341.875 382.5zM672.5 70L750 -23.75H312.5L390 70H672.5zM783.75 531.25L846.25 381.25H721.25L783.75 531.25zM826.25 286.875C812.5875 278.955625 797.04375 274.854375 781.25 275V275C765.64375 274.7781250000001 750.28125 278.88875 736.875 286.875C723.0625 294.9593749999999 711.46875 306.3400000000001 703.125 320H859.375C851.625 306.09375 840.15625 294.6225 826.25 286.875V286.875z" />
|
||||
@@ -330,7 +330,7 @@
|
||||
horiz-adv-x="1000" d=" M677.04375 652.025625C630.3562499999999 698.714375 567.29375 725.344375 501.27125 726.25H498.77125C432.7487500000001 725.344375 369.685 698.714375 322.995625 652.025625C276.30625 605.3362500000001 249.676875 542.2725 248.77125 476.25C247.931875 429.3575 261.1212500000001 383.283125 286.64625 343.9375L483.361875 -55H516.680625L713.3937500000001 343.9375C738.9187499999999 383.283125 752.1125 429.3575 751.2687500000001 476.25C750.36875 542.2725 723.7375000000001 605.3362500000001 677.04375 652.025625zM495.27125 663.75L500.39625 663.125L505.02125 663.75C554.119375 661.611875 600.5325 640.745625 634.71875 605.441875C668.90625 570.138125 688.275 523.0787499999999 688.83125 473.9375C689.30625 439.0612500000001 679.125 404.8712500000001 659.64375 375.9375L658.39375 373.8125L657.3312500000001 371.625L500.02125 52.5625L342.70875 371.3125L341.64625 373.75L340.39625 375.875C320.9175 404.80875 310.734375 438.99875 311.20875 473.875C311.741875 523.073125 331.1287500000001 570.191875 365.374375 605.51875C399.62 640.8456249999999 446.1131250000001 661.688125 495.27125 663.75zM533.4875 528.2168750000001C523.209375 535.084375 511.125625 538.75 498.764375 538.75C482.188125 538.75 466.29125 532.165 454.57 520.444375C442.84875 508.723125 436.264375 492.82625 436.264375 476.25C436.264375 463.88875 439.929375 451.805 446.7975 441.526875C453.665 431.2487500000001 463.42625 423.2381250000001 474.84625 418.5075000000001C486.266875 413.776875 498.83375 412.539375 510.9575 414.950625C523.0812500000001 417.3625 534.2175 423.315 542.958125 432.055625C551.69875 440.796875 557.651875 451.933125 560.063125 464.056875C562.4749999999999 476.180625 561.2368749999999 488.7475 556.5068749999999 500.1675C551.77625 511.588125 543.7650000000001 521.349375 533.4875 528.2168750000001zM429.318125 580.18375C449.8737500000001 593.91875 474.04125 601.25 498.764375 601.25C531.91625 601.25 563.710625 588.080625 587.1524999999999 564.638125C610.594375 541.19625 623.7643750000001 509.401875 623.7643750000001 476.25C623.7643750000001 451.5275 616.433125 427.36 602.698125 406.8037500000001C588.9625000000001 386.2475 569.4399999999999 370.22625 546.599375 360.765C523.7587500000001 351.304375 498.625625 348.82875 474.3775 353.651875C450.13 358.475 427.8575 370.38 410.375625 387.861875C392.8943750000001 405.3431250000001 380.989375 427.6162500000001 376.16625 451.86375C371.3425000000001 476.11125 373.818125 501.244375 383.279375 524.0856249999999C392.74 546.92625 408.761875 566.44875 429.318125 580.18375z" />
|
||||
<glyph glyph-name="lock"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M687.5 507.5V382.5H312.5V507.5C312.5 611.053125 396.446875 695 500 695C603.553125 695 687.5 611.053125 687.5 507.5zM250 382.5V507.5C250 645.57125 361.9287500000001 757.5 500 757.5C638.0687499999999 757.5 750 645.57125 750 507.5V382.5H812.5L875 320V-55L812.5 -117.5H187.5L125 -55V320L187.5 382.5H250zM187.5 -55V320H250H312.5H687.5H750H812.5V-55H187.5z" />
|
||||
horiz-adv-x="1000" d=" M812.5 382.5H750V507.5C750 573.8043749999999 723.6625 637.38875 676.775 684.2731249999999C629.8937500000001 731.156875 566.3043749999999 757.5 500 757.5C433.695625 757.5 370.1075 731.156875 323.223125 684.2731249999999C276.33875 637.38875 250 573.8043749999999 250 507.5V382.5H187.5L125 320V-55L187.5 -117.5H812.5L875 -55V320L812.5 382.5zM312.5 507.5C312.5 557.2281250000001 332.253125 604.920625 367.41625 640.08375C402.5793750000001 675.246875 450.271875 695 500 695C549.728125 695 597.4206250000001 675.246875 632.58125 640.08375C667.74375 604.920625 687.5 557.2281250000001 687.5 507.5V382.5H312.5V507.5zM812.5 -55H187.5V320H812.5V-55z" />
|
||||
<glyph glyph-name="mail-read"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M515.625 721.878125H483.75L62.5 472.503125V-23.74375L93.75 -54.99375H906.25L937.5 -23.74375V472.503125L515.625 721.878125zM500 658.753125L851.875 451.253125L766.25 351.878125H233.75L151.875 451.253125L500 658.753125zM875 7.50625H125V387.503125L194.375 301.253125L218.75 289.378125H781.25L805.625 301.253125L875 387.503125V7.50625z" />
|
||||
@@ -378,16 +378,16 @@
|
||||
horiz-adv-x="1000" d=" M538.125 632.5L896.875 536.875L937.5 507.5V86.25L914.375 56.25L531.25 -49.375L147.5 56.25L125 86.25V507.5L163.125 536.875L521.25 632.5H538.125zM532.5 570L282.5 507.5L316.875 495L531.25 438.75L718.75 489.375L778.125 507.5L532.5 570zM187.5 110L500 24.375V382.5L187.5 466.25V110zM562.5 382.5V24.375L875 110V468.125L748.75 433.5325V273.124375L686.25 256.874375V416.4075L562.5 382.5z" />
|
||||
<glyph glyph-name="paintcan"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M374.9993750000001 523.89125L437.4993750000001 586.27125V665C437.6756250000001 672.58375 434.911875 679.941875 429.78625 685.53375C424.66 691.125625 417.5693750000001 694.518125 409.999375 695C405.67875 695.62375 401.274375 695.316875 397.0825 694.099375C392.8900000000001 692.8825 389.00625 690.7825 385.6918750000001 687.941875C382.3775 685.100625 379.70875 681.58375 377.864375 677.6275C376.020625 673.670625 375.043125 669.365625 374.9993750000001 665V523.89125zM499.999375 587.503125V665C500.090625 677.385625 497.676875 689.66125 492.903125 701.09C488.129375 712.518125 481.094375 722.86375 472.22 731.504375C463.34625 740.144375 452.816875 746.90125 441.2650000000001 751.36875C429.713125 755.83625 417.3775 757.92175 404.999375 757.500125C392.805625 757.668375 380.70125 755.390625 369.403125 750.801875C358.104375 746.2125 347.84 739.405625 339.216875 730.7825C330.59375 722.159375 323.786875 711.895 319.1975000000001 700.59625C314.60875 689.2975 312.330625 677.19375 312.4993750000001 665V461.510625L121.249375 270.6275C103.844375 252.9699999999999 94.0875 229.171875 94.0875 204.3775000000001C94.0875 179.58125 103.844375 155.7875 121.249375 138.125L348.124375 -88.75C356.7862500000001 -97.5124999999999 367.1025 -104.475 378.475 -109.2312499999999C389.8475000000001 -113.9812499999999 402.049375 -116.4249999999999 414.3743750000001 -116.4249999999999C426.7000000000001 -116.4249999999999 438.901875 -113.9812499999999 450.274375 -109.2312499999999C461.646875 -104.475 471.963125 -97.5124999999999 480.624375 -88.75L788.94375 218.98L747.60625 81.45625C745.40625 71.95625 745.33125 62.0812500000001 747.375 52.5500000000001C749.41875 43.0124999999999 753.53125 34.0375 759.43125 26.275C765.3312500000001 18.50625 772.86875 12.13125 781.5062499999999 7.6062499999999C790.1437500000001 3.08125 799.6750000000001 0.50625 809.4187499999999 0.0749999999999C819.75 -0.4187499999999 830.0562500000001 1.48125 839.525 5.63125C849 9.78125 857.3874999999999 16.06875 864.0250000000001 24C870.6625 31.93125 875.375 41.2875 877.79375 51.34375C880.2125 61.4 880.275 71.875 877.96875 81.9625L806.875 276.906875V280.6275L499.999375 587.503125zM437.4993750000001 498.1275L165.624375 226.2525000000001C162.695625 223.3475 160.370625 219.89125 158.784375 216.083125C157.1975 212.2750000000001 156.38125 208.190625 156.38125 204.065C156.38125 199.9400000000001 157.1975 195.855625 158.784375 192.05C160.370625 188.2375 162.695625 184.78125 165.624375 181.875L392.499375 -44.375C395.305 -47.3625000000001 398.69375 -49.7437500000001 402.45625 -51.375C406.21875 -53 410.275 -53.84375 414.3743750000001 -53.84375C418.474375 -53.84375 422.530625 -53 426.293125 -51.375C430.055625 -49.7437500000001 433.44375 -47.3625000000001 436.249375 -44.375L740.625 257.5025000000001L499.999375 499.236875V322.3631250000001C509.951875 313.7675000000001 516.250625 301.055625 516.250625 286.873125C516.250625 260.985 495.26375 239.998125 469.375625 239.998125C443.4875 239.998125 422.500625 260.985 422.500625 286.873125C422.500625 300.45125 428.27375 312.680625 437.4993750000001 321.2412500000001V498.1275z" />
|
||||
horiz-adv-x="1000" d=" M908.7875 81.80625L837.5375 276.8143750000001V280.560625L530.6625 587.4375V664.936875C530.555 677.334375 528.2275 689.60875 523.78875 701.184375C518.92625 712.565 511.8287500000001 722.85375 502.918125 731.4425C494.0075 740.03125 483.464375 746.7475 471.9125 751.1875C460.398125 755.779375 448.04875 757.907 435.66125 757.435625C423.433125 757.6960625 411.289375 755.35375 400.035625 750.561875C388.8125 745.943125 378.615 739.146875 370.0331250000001 730.565C361.45125 721.983125 354.655 711.7825 350.036875 700.55875C345.245 689.305625 342.9025 677.165 343.1625 664.936875V461.18625L151.9125 273.68625C134.655625 255.95125 125 232.1781249999999 125 207.433125C125 182.6875 134.655625 158.9250000000001 151.9125 141.1875L378.788125 -85.6875C387.53875 -94.5124999999999 397.945625 -101.5187500000001 409.4125 -106.3125C432.275625 -115.4875000000001 457.8 -115.4875000000001 480.663125 -106.3125C492.13 -101.5187500000001 502.536875 -94.5124999999999 511.2875 -85.6875L819.4125 221.8143749999999L778.1625 84.3125C776.29375 74.81875 776.29375 65.05625 778.1625 55.5625C780.1687499999999 46.05625 784.21875 37.09375 790.0374999999999 29.30625C796.09375 21.75 803.5124999999999 15.3937500000001 811.9125 10.5625C820.68125 6.1875 830.25 3.6375 840.0375 3.0625C850.35 2.4312500000001 860.65625 4.3625 870.0375 8.6875C879.36875 12.90625 887.6875 19.09375 894.4125 26.8125C901.2125 34.69375 905.9375 44.14375 908.1625 54.3125C910.125 63.3562500000001 910.3375 72.6875 908.7875 81.80625V81.80625zM408.786875 664.936875C407.87 669.053125 407.87 673.3175 408.786875 677.43375C410.5456250000001 681.4449999999999 413.09625 685.061875 416.2862500000001 688.061875C419.674375 690.73875 423.473125 692.8475 427.53625 694.31C431.861875 695.239375 436.336875 695.239375 440.6625 694.31C448.248125 693.72375 455.36 690.389375 460.663125 684.93375C465.574375 679.19125 468.238125 671.8668749999999 468.1625 664.31125V585.560625L405.6625 523.0606250000001L408.786875 664.936875zM471.286875 -44.4375C468.64625 -47.6 465.18875 -49.975 461.2887500000001 -51.3125C457.548125 -52.9625 453.503125 -53.81875 449.4131250000001 -53.81875C445.32375 -53.81875 441.27875 -52.9625 437.538125 -51.3125C433.638125 -49.975 430.176875 -47.6 427.53625 -44.4375L200.660625 181.8125C197.81375 184.7312499999999 195.489375 188.1062499999999 193.786875 191.80625C192.15375 195.6637499999999 191.315 199.8125 191.315 203.999375C191.315 208.186875 192.15375 212.328125 193.786875 216.1837499999999C195.489375 219.885625 197.81375 223.27 200.660625 226.185625L472.538125 498.059375V319.935625C467.775625 315.57125 463.97875 310.2543750000001 461.395 304.33375C458.811875 298.4131250000001 457.499375 292.0175 457.53875 285.5575C456.77625 277.3318750000001 458.201875 269.053125 461.67 261.555625C465.138125 254.058125 470.525 247.60875 477.2875 242.86375C484.049375 238.11875 491.945 235.24375 500.175625 234.5325000000001C508.405625 233.8212500000001 516.6787499999999 235.2981249999999 524.154375 238.8125C531.630625 242.326875 538.0443750000001 247.753125 542.7475000000001 254.544375C547.450625 261.3356250000001 550.276875 269.2512500000001 550.9375 277.4856250000001C551.5981250000001 285.7206250000001 550.0693749999999 293.988125 546.50875 301.441875C542.948125 308.89625 537.4825 315.274375 530.6625 319.935625V496.808125L771.2875 254.933125L471.286875 -44.4375z" />
|
||||
<glyph glyph-name="pencil"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M62.5 -29.55625L150.44125 -117.5L408.261875 29.825L421.859375 40.2125L937.5 555.8525V647.005625L827.00625 757.5H735.85L220.211875 241.859375L209.825625 228.2618750000001L62.5 -29.55625zM335.729375 65.0750000000001L150.44125 -29.55625L245.07625 155.7312500000001L335.729375 65.0750000000001zM389.844375 99.35L891.925 601.42875L781.43125 711.923125L279.35 209.844375L389.844375 99.35z" />
|
||||
horiz-adv-x="1000" d=" M826.875 757.5H735.625L220.00125 241.875L209.999375 228.1268750000001L62.5 -29.375L150.623125 -117.5L408.126875 30L421.875 40L937.5 555.62625V646.87375L826.875 757.5zM150.623125 -29.375L244.99875 158.125L335.625 67.5L150.623125 -29.375zM389.999375 99.375L279.373125 209.999375L779.375 709.999375L890 599.373125L389.999375 99.375z" />
|
||||
<glyph glyph-name="person"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M500 695C512.36125 695 524.445 691.334375 534.723125 684.466875C545.000625 677.599375 553.011875 667.838125 557.7425000000001 656.4175C562.4725000000001 644.9975 563.710625 632.430625 561.2987499999999 620.306875C558.8874999999999 608.183125 552.9343749999999 597.046875 544.19375 588.305625C535.453125 579.565 524.316875 573.6125 512.193125 571.200625C500.06875 568.789375 487.5025 570.026875 476.081875 574.7574999999999C464.661875 579.488125 454.900625 587.49875 448.033125 597.776875C441.165 608.0550000000001 437.5 620.1387500000001 437.5 632.5C437.5 649.07625 444.084375 664.973125 455.805625 676.694375C467.526875 688.415 483.42375 695 500 695V695zM500 757.5C475.276875 757.5 451.109375 750.16875 430.5537500000001 736.43375C409.9975 722.69875 393.975625 703.17625 384.515 680.3356249999999C375.0537500000001 657.494375 372.578125 632.36125 377.401875 608.11375C382.225 583.86625 394.13 561.5931250000001 411.61125 544.111875C429.0931250000001 526.63 451.365625 514.7249999999999 475.613125 509.901875C499.86125 505.07875 524.994375 507.554375 547.8349999999999 517.015C570.675625 526.4762499999999 590.198125 542.4975 603.9331249999999 563.05375C617.66875 583.61 625 607.7775 625 632.5C625 665.651875 611.83 697.44625 588.3881250000001 720.888125C564.94625 744.330625 533.151875 757.5 500 757.5V757.5zM576.875 476.875H423.125C393.785 476.875 365.6475000000001 465.22 344.90125 444.47375C324.1550000000001 423.7275 312.5 395.589375 312.5 366.25V201.25C311.816875 183.88125 317.9862500000001 166.94375 329.6775 154.08125C341.36875 141.21875 357.64625 133.46875 375 132.5V-13.125C375 -33.0187500000001 382.90125 -52.09375 396.966875 -66.15625C411.031875 -80.225 430.10875 -88.125 450 -88.125H550C560.0625 -88.1312499999999 570.0243750000001 -86.1124999999999 579.290625 -82.1875C588.556875 -78.2624999999999 596.9387499999999 -72.5125 603.936875 -65.28125C610.934375 -58.0499999999999 616.405625 -49.4875 620.024375 -40.09375C623.6431249999999 -30.70625 625.3375 -20.6812500000001 625 -10.625V132.5C642.3562499999999 133.46875 658.63125 141.21875 670.3249999999999 154.08125C682.0125 166.94375 688.18125 183.88125 687.5 201.25V366.25C687.5 395.589375 675.84375 423.7275 655.1 444.47375C634.35 465.22 606.214375 476.875 576.875 476.875V476.875zM375 195V366.25C374.915625 372.5931250000001 376.103125 378.88875 378.491875 384.765625C380.880625 390.6425 384.4225 395.98125 388.908125 400.466875C393.39375 404.9525 398.7325 408.494375 404.609375 410.883125C410.4856250000001 413.271875 416.781875 414.45875 423.125 414.375H576.875C583.218125 414.45875 589.51375 413.271875 595.390625 410.883125C601.266875 408.494375 606.605625 404.9525 611.09125 400.466875C615.576875 395.98125 619.1187500000001 390.6425 621.5074999999999 384.765625C623.89625 378.88875 625.0812500000001 372.5931250000001 625 366.25V195H562.5V-11.875C562.5 -15.1875 561.1825 -18.36875 558.83875 -20.7125C556.494375 -23.05625 553.315 -24.375 550 -24.375H450C446.6843750000001 -24.375 443.505 -23.05625 441.160625 -20.7125C438.816875 -18.36875 437.5 -15.1875 437.5 -11.875V195H375z" />
|
||||
<glyph glyph-name="pin"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M594.759375 7.8562499999999L547.57875 8.3249999999999L391.594375 159.8375L177.096875 -55H81.77375L343.813125 206.245L166.185 378.776875L165.6925 424.59625C192.928125 446.551875 226.248125 460.326875 261.68375 464.275C297.12 468.2225 333.198125 462.190625 365.616875 446.88L579.078125 601.296875L577.641875 735.1949999999999L634.3875 757.5L937.5 463.078125L914.54375 407.97L776.68125 409.35875L617.701875 202.035625C633.4625000000001 170.5437500000001 639.675 135.50625 635.60625 101.08125C631.5437499999999 66.6625 617.36375 34.30625 594.759375 7.8562499999999zM389.8268750000001 252.11875L243.01 394.719375C281.7043750000001 402.9650000000001 322.416875 397.97875 358.324375 380.596875L391.3137500000001 384.153125L632.775 558.629375L645.84375 584.4225L645.0749999999999 656.424375L833.44375 473.464375L759.30625 474.210625L732.75625 461.520625L553.115 226.9881250000001L549.45375 194.94375C567.349375 160.06875 572.4825 120.5250000000001 564 82.9500000000001L437.500625 205.8143750000001L389.8268750000001 252.11875z" />
|
||||
horiz-adv-x="1000" d=" M615.001875 757.5L558.124375 735.000625V601.25L344.375625 446.876875C312.088125 462.23125 276.160625 468.293125 240.62375 464.37875C205.404375 460.41 172.033125 446.54 144.375 424.3775V378.74625L321.87625 206.253125L60.001375 -55H154.99875L369.99875 159.99375L525.623125 8.125H573.1237500000001C595.604375 34.58125 609.7418749999999 67.1 613.746875 101.5875C617.75125 136.06875 611.44625 170.96875 595.626875 201.874375L755 409.378125H892.5L915.625 464.37875L615.001875 757.5zM740 474.373125L713.125 461.250625L533.74875 226.875625L529.99875 195C547.994375 160.61875 553.0962499999999 120.9375 544.37625 83.125L419.3762500000001 208.1225000000001L371.875625 254.371875L224.99875 397.499375C263.8625 405.660625 304.34125 400.6025 340 383.125625L373.1268750000001 386.8718750000001L614.3762499999999 561.249375L627.5 586.87625V658.7525L815 476.25L740 474.373125z" />
|
||||
<glyph glyph-name="play"
|
||||
unicode="⚨"
|
||||
horiz-adv-x="1000" d=" M301.25 -48.75L250 -23.125V670.625L299.375 695L799.375 346.25V295L301.25 -48.75zM312.5 610.625V36.25L726.25 320L312.5 610.625z" />
|
||||
@@ -411,16 +411,13 @@
|
||||
horiz-adv-x="1000" d=" M737.5 257.5L625 632.5H562.5L447.375625 217.5L374.375 526.875H313.75L240.625 257.5H62.5V195.625H264.375L295 218.75L341.25 387.5L411.875 70H476.25L593.125 510L684.375 217.5L714.375 195H937.5V257.5H737.5z" />
|
||||
<glyph glyph-name="question"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M812.5 351.25C812.5 161.4000000000001 658.5999999999999 7.5 468.75 7.5C278.901875 7.5 125 161.4000000000001 125 351.25C125 541.098125 278.901875 695 468.75 695C658.5999999999999 695 812.5 541.098125 812.5 351.25zM875 351.25C875 126.88125 693.11875 -55 468.75 -55C244.384375 -55 62.5 126.88125 62.5 351.25C62.5 575.615625 244.384375 757.5 468.75 757.5C693.11875 757.5 875 575.615625 875 351.25zM424.719375 281.443125V239.7925H498.024375V270.7806250000001C498.024375 279.6662500000001 500.3568750000001 288.3293750000001 505.021875 296.770625C509.686875 305.211875 515.4625000000001 313.7643750000001 522.34875 322.4275C529.235 331.313125 536.7875 340.4206250000001 545.006875 349.750625C553.225625 359.3025 560.77875 369.4100000000001 567.665 380.0725C574.55125 390.735 580.3262500000001 402.175 584.9912499999999 414.3925C589.65625 426.61 591.98875 439.938125 591.98875 454.3775C591.98875 468.594375 589.87875 482.58875 585.658125 496.36125C581.659375 510.35625 574.884375 522.795625 565.3325 533.680625C555.780625 544.565 543.229375 553.339375 527.6800000000001 560.0037500000001C512.13 566.668125 493.02625 570 470.36875 570C449.265625 570 430.93875 566.4456250000001 415.3893750000001 559.3375C400.061875 552.22875 387.178125 542.899375 376.7375 531.348125C366.519375 520.01875 358.744375 507.02375 353.413125 492.363125C348.081875 477.701875 344.860625 462.81875 343.75 447.713125H420.3875000000001C422.164375 462.81875 427.385 474.703125 436.0481250000001 483.36625C444.71125 492.251875 456.37375 496.694375 471.035 496.694375C477.0325 496.694375 482.696875 495.695 488.028125 493.695625C493.359375 491.69625 498.024375 488.80875 502.023125 485.0325C506.02125 481.478125 509.2425000000001 476.924375 511.68625 471.370625C514.129375 465.8175 515.35125 459.5975 515.35125 452.71125C515.35125 441.3825 513.13 430.830625 508.686875 421.056875C504.244375 411.2825 498.58 401.841875 491.69375 392.734375C485.029375 383.84875 477.81 375.0743750000001 470.035 366.410625C462.260625 357.969375 454.93 349.30625 448.0437500000001 340.4206250000001C441.3793750000001 331.5350000000001 435.82625 322.205625 431.383125 312.43125C426.940625 302.879375 424.719375 292.5500000000001 424.719375 281.443125zM424.719375 132.5H498.024375V205.8056250000001H424.719375V132.5z" />
|
||||
horiz-adv-x="1000" d=" M468.750625 757.5C388.401875 757.5 309.8575 733.673125 243.05 689.03375C176.2425 644.3943750000001 124.174375 580.946875 93.42625 506.714375C62.678125 432.481875 54.6301875 350.8006250000001 70.305625 271.995625C85.980625 193.19375 124.67375 120.8 181.48875 63.9875000000001C238.30375 7.175 310.691875 -31.51875 389.49625 -47.19375C468.30125 -62.86875 549.9825000000001 -54.8249999999999 624.2149999999999 -24.075C698.45 6.66875 761.8937500000001 58.74375 806.53125 125.55C851.1750000000001 192.3562500000001 875 270.90125 875 351.25C875 458.994375 832.2 562.325 756.0124999999999 638.511875C679.825 714.69875 576.495 757.5 468.750625 757.5zM468.750625 7.5C400.763125 7.5 334.3006250000001 27.65625 277.77125 65.43125C221.241875 103.2000000000001 177.183125 156.89375 151.165625 219.70375C125.148125 282.51625 118.34 351.63125 131.60375 418.3125C144.8675 484.993125 177.6075 546.2406249999999 225.681875 594.315C273.75625 642.389375 335.0075 675.129375 401.688125 688.393125C468.369375 701.656875 537.484375 694.84875 600.29625 668.83125C663.10625 642.81375 716.79375 598.7581250000001 754.56875 542.22875C792.3375 485.699375 812.5 419.2375 812.5 351.25C812.5 260.081875 776.2875 172.65 711.8187499999999 108.1875C647.3562499999999 43.71875 559.91875 7.5 468.750625 7.5zM565.624375 533.7537500000001C554.82625 544.9975 541.85625 553.923125 527.5 559.99875C509.4375 567.2306249999999 490.073125 570.638125 470.626875 570.000625C451.7525 570.34375 433.015625 566.72125 415.62625 559.3731250000001C400.71625 553.1075000000001 387.455 543.485625 376.876875 531.25125C366.52625 519.9937500000001 358.46 506.83375 353.12625 492.50125C348.1675 477.9425 345.0175 462.83125 343.75 447.503125H420.6237500000001C421.078125 460.94125 426.6706250000001 473.68875 436.2487500000001 483.125C440.745625 487.805625 446.2025 491.455625 452.24375 493.82875C458.285 496.2025 464.768125 497.24125 471.24875 496.873125C476.83875 497.761875 482.535 497.761875 488.125 496.873125C493.26 494.93125 497.9425 491.951875 501.876875 488.1225C506.2187500000001 484.365 509.63875 479.6625 511.8749999999999 474.374375C514.435625 468.459375 515.713125 462.073125 515.625 455.62875C515.648125 444.834375 513.301875 434.166875 508.750625 424.3787500000001C504.211875 414.198125 498.550625 404.55 491.875 395.62375L470.00125 369.378125C462.50125 361.253125 454.99875 352.50125 448.12375 343.7512500000001C441.4575 335.041875 435.799375 325.61 431.25125 315.6293750000001C426.9156250000001 305.7924999999999 424.78 295.126875 424.999375 284.379375V243.1268750000001H500V273.7512500000001C500.211875 282.9181249999999 502.565625 291.910625 506.874375 300.004375C511.989375 309.015 517.844375 317.580625 524.375625 325.62375L546.875 353.1275C555.06625 362.590625 562.58375 372.6137500000001 569.374375 383.12625C576.556875 393.84625 582.4337499999999 405.3900000000001 586.875625 417.504375C591.43375 430.3475 593.7581250000001 443.87 593.75 457.498125C593.86125 471.696875 591.7543750000001 485.828125 587.50125 499.375625C582.781875 512.28125 575.31625 524.0125 565.624375 533.7537500000001zM425 205.6275000000001H498.125V132.5H425V205.6275000000001z" />
|
||||
<glyph glyph-name="quote"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M447.5 601.248125C295.625 503.748125 221.875 403.123125 221.875 234.998125C231.875 238.1231250000001 240.625 238.1231250000001 249.375 238.1231250000001C328.75 238.1231250000001 405.625 184.375 405.625 87.5C405.625 -13.125 341.25 -75.625 249.375 -75.625C130.625 -75.625 62.5 19.375 62.5 190C62.5 427.498125 171.875 598.123125 376.25 716.248125L447.5 601.248125zM885 601.248125C733.125 503.748125 659.375 403.123125 659.375 234.998125C669.375 238.1231250000001 678.125 238.1231250000001 686.875 238.1231250000001C766.25 238.1231250000001 843.125 184.375 843.125 87.5C843.125 -13.125 778.75 -75.625 686.875 -75.625C568.75 -75.625 500.625 19.375 500.625 190C500.625 427.498125 610 598.123125 814.375 716.248125L885.625 601.248125H885z" />
|
||||
<glyph glyph-name="radio-tower"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M188.6875 476.251875C189.263125 567.145 225.536875 654.170625 289.6875 718.564375L245.375 762.6269374999999C169.664375 686.468125 126.8675 583.638125 126.1875 476.251875C126.820625 368.85625 169.625 266.0093750000001 245.375 189.875L289.6875 233.9393750000001C225.496875 298.3062500000001 189.215625 385.349375 188.6875 476.251875zM772.8125 718.251875L817.125 762.3144374999999V762.6269374999999C892.8375 686.468125 935.63125 583.638125 936.3125 476.251875C935.63125 368.9212500000001 892.83125 266.150625 817.125 190.0625L772.8125 234.1268750000001C836.95625 298.4475 873.2375 385.414375 873.8125 476.251875C873.15625 567.03625 836.8875 653.9356250000001 772.8125 718.251875zM333.003125 559.57875C344.02 586.000625 360.163125 609.9775 380.5 630.124375L336.1875 674.186875C310.079375 648.245 289.359375 617.395625 275.220625 583.415C261.0818750000001 549.4337499999999 253.8025 512.9918749999999 253.8025 476.186875C253.8025 439.3818750000001 261.0818750000001 402.94 275.220625 368.959375C289.359375 334.9781250000001 310.079375 304.12875 336.1875 278.186875L380.5 322.249375C360.163125 342.39625 344.02 366.37375 333.003125 392.795625C321.98625 419.2175000000001 316.3137500000001 447.560625 316.3137500000001 476.186875C316.3137500000001 504.81375 321.98625 533.156875 333.003125 559.57875zM687 630.124375L731.3125 673.874375L731.25 674.186875C783.56875 621.536875 813.16875 550.47375 813.6875 476.249375C813.28125 401.976875 783.6999999999999 330.8400000000001 731.3125 278.186875L687 322.249375C707.3375 342.39625 723.4812499999999 366.37375 734.49375 392.795625C745.5125 419.2175000000001 751.1875 447.560625 751.1875 476.186875C751.1875 504.81375 745.5125 533.156875 734.49375 559.57875C723.4812499999999 586.000625 707.3375 609.9775 687 630.124375zM531.25 570C512.708125 570 494.5825 564.5018749999999 479.165625 554.2C463.748125 543.8987500000001 451.731875 529.256875 444.63625 512.1268749999999C437.5406250000001 494.99625 435.68375 476.14625 439.30125 457.96C442.9187500000001 439.774375 451.8475 423.07 464.95875 409.95875C465.723125 409.194375 466.499375 408.445 467.2875 407.709375L252.6875 -75.4375L309.8125 -100.8125L357.9375 7.5H704.5L752.6875 -100.8125L809.8125 -75.4375L594.94875 407.46375C600.309375 412.4275 605.09875 418.026875 609.2006250000001 424.165C619.5018749999999 439.5825 625 457.708125 625 476.25C625 501.11375 615.123125 524.96 597.54125 542.54125C579.96 560.1225 556.114375 570 531.25 570zM531.25 445C525.0693749999999 445 519.0274999999999 446.8325000000001 513.88875 450.2668750000001C508.7493749999999 453.700625 504.74375 458.58125 502.37875 464.29125C500.01375 470.00125 499.395 476.284375 500.600625 482.346875C501.80625 488.40875 504.7825 493.9768749999999 509.153125 498.346875C513.5231249999999 502.7175 519.0912500000001 505.69375 525.15375 506.899375C531.2156249999999 508.105625 537.49875 507.48625 543.20875 505.12125C548.919375 502.75625 553.8 498.750625 557.23375 493.6118750000001C560.6675 488.4725 562.5 482.430625 562.5 476.25C562.5 467.961875 559.2075 460.013125 553.3468750000001 454.153125C547.486875 448.2925 539.538125 445 531.25 445zM539.4375 378.685C533.906875 378.184375 528.3425000000001 378.184375 522.8125 378.685L468.75 257.4975H593.25L539.4375 378.685zM441.25 195L385.6875 70H676.6875L621.0625 195H441.25z" />
|
||||
<glyph glyph-name="record-keys"
|
||||
unicode="⚯"
|
||||
horiz-adv-x="1000" d=" M875 570H187.5L187.5 132.5H875V570zM187.5 632.5C152.9825 632.5 125 604.5175 125 570V132.5C125 97.9812499999999 152.9825 70 187.5 70H875C909.51875 70 937.5 97.9812499999999 937.5 132.5V570C937.5 604.5175 909.51875 632.5 875 632.5H187.5zM250 507.5H312.5V445H250V507.5zM437.5 507.5H375V445H437.5V507.5zM500 507.5H562.5V445H500V507.5zM687.5 507.5H625V445H687.5V507.5zM750 507.5H812.5V445H750V507.5zM375 320V382.5H250V320H375zM437.5 382.5H500V320H437.5V382.5zM625 382.5H562.5V320H625V382.5zM812.5 382.5V320H687.5V382.5H812.5zM312.5 257.5H250V195H312.5V257.5zM375 257.5H687.5V195H375V257.5zM812.5 257.5H750V195H812.5V257.5z" />
|
||||
horiz-adv-x="1000" d=" M187.400625 471.2525C188.040625 562.236875 224.4025 649.326875 288.650625 713.753125L244.274375 757.5C206.480625 720.0231249999999 176.485 675.435 156.01375 626.3050000000001C135.541875 577.174375 125 524.4775 125 471.2525C125 418.0281250000001 135.541875 365.330625 156.01375 316.200625C176.485 267.07 206.480625 222.4825 244.274375 185.00625L288.650625 228.7525C224.4025 293.178125 188.040625 380.26875 187.400625 471.2525zM253.649375 471.2525C253.488125 434.3950000000001 260.705625 397.88 274.874375 363.8537500000001C289.0431250000001 329.8275 309.876875 298.9756250000001 336.15 273.125L380.52625 317.505C359.984375 337.270625 343.8037500000001 361.114375 333.025625 387.505C321.87125 414.0168750000001 316.1325 442.49 316.149375 471.2525C316.061875 499.820625 321.805 528.103125 333.025625 554.375C343.643125 581.03375 359.83875 605.114375 380.52625 625L336.15 669.380625C309.989375 643.445625 289.229375 612.5825 275.06875 578.575625C260.90875 544.5687499999999 253.6275 508.09 253.649375 471.2525zM731.775 270.63L687.4 315.0025C708.0125 334.9500000000001 724.1999999999999 359.01375 734.9 385.628125C746.05625 412.14 751.79375 440.613125 751.775 469.375625C751.8625 497.94375 746.125 526.23375 734.9 552.505625C724.28125 579.1643750000001 708.0875 603.245 687.4 623.13125L731.775 666.878125C757.8937500000001 640.915 778.61875 610.044375 792.75625 576.0425C806.9 542.040625 814.18125 505.575625 814.18125 468.75C814.18125 431.925 806.9 395.4675000000001 792.75625 361.465625C778.61875 327.46375 757.8937500000001 296.59375 731.775 270.63zM816.775 757.5L772.4 713.1275C804.4875000000001 681.54625 829.975 643.896875 847.36875 602.37125C864.7625 560.8456249999999 873.71875 516.274375 873.71875 471.2525C873.71875 426.23125 864.7625 381.659375 847.36875 340.13375C829.975 298.6081250000001 804.4875000000001 260.95875 772.4 229.3781250000001L816.775 185.00625C854.56875 222.4825 884.56875 267.07 905.04375 316.200625C925.5125 365.330625 936.05 418.0281250000001 936.05 471.2525C936.05 524.4775 925.5125 577.174375 905.04375 626.3050000000001C884.56875 675.435 854.56875 720.0231249999999 816.775 757.5zM624.54625 480.60625C626.6875 459.044375 621.2893750000001 437.413125 609.275625 419.380625C604.0875 414.09875 598.439375 409.281875 592.399375 404.999375L807.4 -78.125L749.9 -103.11875L701.7750000000001 5.00625H355.52625L307.4000000000001 -103.11875L249.900625 -78.125L464.90125 404.999375C451.840625 418.1925 442.9337500000001 434.924375 439.2775 453.125625C435.60125 471.1425 437.3381250000001 489.844375 444.275 506.874375C451.585625 524.128125 463.743125 538.894375 479.275 549.378125C497.306875 561.39125 518.9462500000001 566.79 540.508125 564.651875C562.0706250000001 562.51375 582.224375 552.973125 597.545625 537.65125C612.866875 522.3299999999999 622.4075 502.16875 624.54625 480.60625zM524.9025 501.8775C518.9775 500.48125 513.56375 497.44875 509.2775 493.12625C505.9193749999999 489.15875 503.55875 484.445 502.399375 479.378125C500.530625 473.48125 500.530625 467.148125 502.399375 461.250625C504.861875 455.578125 508.7343749999999 450.630625 513.64875 446.876875C518.9143750000001 443.639375 524.969375 441.9125 531.150625 441.8793750000001C539.38875 442.039375 547.24375 445.384375 553.0699999999999 451.2106250000001C558.89625 457.036875 562.240625 464.891875 562.400625 473.129375C562.368125 479.310625 560.6375 485.36625 557.4 490.63125C553.64625 495.54625 548.69875 499.415 543.02625 501.8775C537.1287500000001 503.74625 530.7993749999999 503.74625 524.9025 501.8775zM539.27625 373.749375H522.4L468.025 252.503125H593.025L539.27625 373.749375zM676.775 65L621.15125 190H441.150625L385.5250000000001 65H676.775z" />
|
||||
<glyph glyph-name="remote"
|
||||
unicode="⚩"
|
||||
horiz-adv-x="1000" d=" M806.5 221.825625L558.004375 470.328125L806.50625 718.83L767.8375 757.5L499.999375 489.663125V450.993125L767.83125 183.15625L806.5 221.825625zM187.5 468.8275L441.994375 214.333125L187.5 -40.1625L226.17 -78.8312499999999L499.999375 195V233.6681250000001L226.17 507.496875L187.5 468.8275z" />
|
||||
@@ -429,7 +426,7 @@
|
||||
horiz-adv-x="1000" d=" M394.153125 685.845L142.903125 434.594375V390.400625L394.153125 139.1500000000001L438.346875 183.34375L237.940625 383.75125H355.625C531.4475 383.75125 643.43125 345.945625 712.2062500000001 275.715625C781.0875000000001 205.370625 813.125 95.8937500000001 813.125 -63.125V-85H875.625V-63.125C875.625 102.2312500000001 842.6625 231.81875 756.85625 319.443125C670.9437499999999 407.1818750000001 538.5525 446.25125 355.625 446.25125H242.9475L438.346875 641.650625L394.153125 685.845z" />
|
||||
<glyph glyph-name="repo-clone"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M812.5 195V257.5H875V-23.75L843.75 -55H562.5V7.5H812.5V132.5H233.75C227.51375 132.51875 221.34125 131.2437500000001 215.625 128.75C204.309375 124.05625 195.31875 115.0625 190.625 103.75C188.628125 97.9125 187.573125 91.7937499999999 187.5 85.625V54.375C187.573125 48.2062500000001 188.628125 42.0875 190.625 36.25C195.31875 24.9375 204.309375 15.94375 215.625 11.25C221.34125 8.7562499999999 227.51375 7.48125 233.75 7.5H250V-55H233.75C219.415625 -54.84375 205.22875 -52.0875 191.875 -46.875C165.285 -35.51875 144.196875 -14.2062500000001 133.125 12.5C127.61375 25.7624999999999 124.85 40.0125 125 54.375V648.125C125.25625 661.436875 128.0125 674.58125 133.125 686.875C138.26375 700.679375 146.106875 713.31875 156.195625 724.05125C166.284375 734.78375 178.414375 743.393125 191.875 749.375C205.22875 754.58875 219.415625 757.34125 233.75 757.5H500V695H250V195H812.5zM750 320H906.25L937.5 351.25V726.25L906.25 757.5H625C608.42375 757.5 592.526875 750.915 580.805625 739.194375C569.0849999999999 727.473125 562.5 711.57625 562.5 695V476.25V382.5C562.5 365.92375 569.0849999999999 350.026875 580.805625 338.305625C592.526875 326.585 608.42375 320 625 320H687.5V257.5H750V320zM750 382.5H875V445H750V382.5zM687.5 445H656.25C647.9625 445 640.0124999999999 441.7075000000001 634.15 435.846875C628.2937499999999 429.986875 625 422.038125 625 413.75C625 405.461875 628.2937499999999 397.513125 634.15 391.653125C640.0124999999999 385.7925 647.9625 382.5 656.25 382.5H687.5V445zM687.5 507.5H875V695H687.5V507.5zM375 632.5H312.5V570H375V632.5zM375 507.5H312.5V445H375V507.5zM312.5 382.5H375V320H312.5V382.5zM312.5 -117.5H330L406.25 -23.125L482.5 -117.5H500V70H312.5V-117.5z" />
|
||||
horiz-adv-x="1000" d=" M812.5 195H249.998125V695H499.998125V757.5H233.7475C219.413125 757.34125 205.226875 754.588125 191.87375 749.375C178.3075 743.470625 166.16 734.731875 156.248125 723.7475C146.12 713.150625 138.2525 700.606875 133.12375 686.875C127.9825 674.5899999999999 125.225 661.44 124.998125 648.125V54.375C124.848125 40.0125 127.6125 25.7624999999999 133.12375 12.5C144.080625 -14.2874999999999 165.20625 -35.6375 191.87375 -46.875C205.226875 -52.0875 219.413125 -54.84375 233.7475 -55H249.998125V7.5H233.7475C227.51125 7.48125 221.340625 8.7625 215.62375 11.25625C204.455625 16.1625 195.53375 25.08125 190.6225 36.25C189.674375 42.25 189.674375 48.36875 190.6225 54.375V85.625C189.674375 91.63125 189.674375 97.75 190.6225 103.75C195.53375 114.9187500000001 204.455625 123.8375 215.62375 128.74375C221.340625 131.2375 227.51125 132.51875 233.7475 132.5H812.5V7.5H562.498125V-55H843.75L875 -23.75V257.5H812.5V195zM375 632.5H312.5V570H375V632.5zM312.5 507.5H375V445H312.5V507.5zM312.5 382.5H375V320H312.5V382.5zM330 -117.5H312.5V70H500V-117.5H482.5L406.25 -23.125L330 -117.5zM625 757.5H906.25L937.5 726.25V351.25L906.25 320H750V257.5H687.5V320H625C608.42375 320 592.5275 326.5818750000001 580.806875 338.303125C569.085625 350.02375 562.5 365.92375 562.5 382.5V695C562.5 711.57625 569.085625 727.4762499999999 580.806875 739.196875C592.5275 750.918125 608.42375 757.5 625 757.5zM656.25 382.5H687.5V445H656.25C647.9625 445 640.0124999999999 441.705 634.15 435.845C628.2937499999999 429.984375 625 422.038125 625 413.75C625 405.461875 628.2937499999999 397.515625 634.15 391.6550000000001C640.0124999999999 385.795 647.9625 382.5 656.25 382.5zM750 382.5H875V445H750V382.5zM687.5 507.5H875V695H687.5V507.5z" />
|
||||
<glyph glyph-name="repo-force-push"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M233.751875 757.5H843.75L875 726.25V-23.75L843.75 -55H625V7.5H812.5V132.5H625V195H812.5V695H250.001875V195H437.501875V132.5H250.001875H233.751875H233.74375C227.62 132.5 221.556875 131.28125 215.906875 128.9187500000001C210.255 126.55625 205.128125 123.09375 200.825 118.7312500000001C196.521875 114.375 193.12875 109.2000000000001 190.84125 103.5187500000001C188.554375 97.83125 187.41875 91.75 187.501875 85.625V54.375C187.41875 48.25 188.554375 42.16875 190.84125 36.4812499999999C193.12875 30.8 196.521875 25.625 200.825 21.26875C205.128125 16.90625 210.255 13.44375 215.906875 11.08125C221.559375 8.71875 227.625 7.5 233.751875 7.5H437.501875V-55H233.751875C219.4175 -55 205.225 -52.16875 191.99 -46.6625C178.755 -41.15625 166.73875 -33.09375 156.631875 -22.9250000000001C146.525625 -12.7624999999999 138.528125 -0.6999999999999 133.1 12.5687499999999C127.67125 25.8312500000001 124.919375 40.0437499999999 125.001875 54.375V648.125C124.919375 662.45875 127.67125 676.6675 133.1 689.93375C138.528125 703.2 146.525625 715.2625 156.631875 725.4275C166.73875 735.591875 178.755 743.658125 191.99 749.1625C205.225 754.666875 219.4175 757.50025 233.751875 757.5zM333.751875 455.625L378.126875 411.875L500.001875 533.75V443.125L336.251875 279.375L380.626875 235.625L500.626875 355.625V-117.5H563.126875V361.988125L690 235.625L733.75 279.375L562.501875 451.2325V536.37125L687.5 411.875L731.25 455.625L555.0018749999999 632.5H510.626875L333.751875 455.625z" />
|
||||
@@ -468,7 +465,7 @@
|
||||
horiz-adv-x="1000" d=" M218.75 570H62.5V632.5H187.5V757.5H250V601.25L218.75 570zM812.5 632.5V757.5H750V601.25L781.25 570H937.5V632.5H812.5zM750 38.75V-117.5H812.5V7.5H937.5V70H781.25L750 38.75zM62.5 70V7.5H187.5V-117.5H250V38.75L218.75 70H62.5zM750 163.75L718.75 132.5H281.25L250 163.75V476.25L281.25 507.5H718.75L750 476.25V163.75zM625 382.5H375V257.5H625V382.5z" />
|
||||
<glyph glyph-name="search"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M916.66875 476.25C916.66875 320.92 790.75 195 635.41875 195C480.086875 195 354.166875 320.92 354.166875 476.25C354.166875 631.5799999999999 480.086875 757.5 635.41875 757.5C790.75 757.5 916.66875 631.5799999999999 916.66875 476.25zM979.16875 476.25C979.16875 286.401875 825.2625 132.5 635.41875 132.5C555.511875 132.5 481.974375 159.7624999999999 423.599375 205.49625L88.545625 -174.4874999999999L41.667 -133.1500000000001L378.06375 248.355C324.3062500000001 309.0168750000001 291.666875 388.821875 291.666875 476.25C291.666875 666.098125 445.569375 820 635.41875 820C825.2625 820 979.16875 666.098125 979.16875 476.25z" />
|
||||
horiz-adv-x="1000" d=" M622.2881249999999 757.5C559.8087499999999 757.5645625 498.645625 739.565625 446.156875 705.674375C393.668125 671.783125 352.0925 623.4456250000001 326.44 566.475C300.7875 509.505 292.1500000000001 446.33 301.5668750000001 384.564375C310.9831250000001 322.7987500000001 338.05375 265.071875 379.516875 218.33375L62.5 -141.10625L106.69375 -180L422.535 178.2687500000001C463.19125 146.425 510.8675 124.7562499999999 561.59375 115.06875C612.319375 105.3875000000001 664.625 107.96875 714.15625 122.59375C763.68125 137.21875 809 163.46875 846.325 199.1575C883.6500000000001 234.844375 911.9125 278.933125 928.75 327.7537500000001C945.5875 376.5743750000001 950.50625 428.71125 943.1125 479.82125C935.71875 530.9312500000001 916.21875 579.534375 886.2375 621.580625C856.25 663.6268749999999 816.65625 697.899375 770.74375 721.541875C724.8312500000001 745.185 673.93125 757.5123125 622.2881249999999 757.5V757.5zM622.2881249999999 168.25C569.84375 168.25 518.5775 183.8000000000001 474.971875 212.9393749999999C431.36625 242.075625 397.3787500000001 283.4881250000001 377.3087500000001 331.94C357.2393750000001 380.3925000000001 351.99 433.7075000000001 362.221875 485.14375C372.453125 536.580625 397.708125 583.828125 434.791875 620.911875C471.875625 657.995625 519.1231250000001 683.250625 570.56 693.481875C621.99625 703.71375 675.3125 698.4606249999999 723.7624999999999 678.39125C772.2125 658.321875 813.625 624.3375 842.7624999999999 580.731875C871.9 537.12625 887.4499999999999 485.85625 887.4499999999999 433.411875C887.53125 398.56875 880.725 364.053125 867.425 331.846875C854.125 299.640625 834.6 270.3775 809.9625 245.739375C785.325 221.1012499999999 756.0625 201.5725 723.8562499999999 188.275C691.65 174.975 657.1312499999999 168.1687500000001 622.2881249999999 168.25V168.25z" />
|
||||
<glyph glyph-name="server"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M156.25 507.5L125 538.75V726.25L156.25 757.5H843.75L875 726.25V538.75L843.75 507.5H156.25zM625 695H562.5V632.5H500V695H437.5V632.5H375V695H312.5V632.5H250V695H187.5V570H812.5V695H687.5V632.5H625V695zM156.25 195L125 226.25V413.75L156.25 445H843.75L875 413.75V226.25L843.75 195H156.25zM375 382.5H312.5V320H250V382.5H187.5V257.5H812.5V382.5H687.5V320H625V382.5H562.5V320H500V382.5H437.5V320H375V382.5zM843.75 -117.5L875 -86.25V101.25L843.75 132.5H156.25L125 101.25V-86.25L156.25 -117.5H843.75zM187.5 -55V70H250V7.5H312.5V70H375V7.5H437.5V70H500V7.5H562.5V70H625V7.5H687.5V70H812.5V-55H187.5z" />
|
||||
@@ -486,7 +483,7 @@
|
||||
horiz-adv-x="1000" d=" M688.75 584.375V486.875L751.25 548.75V663.75L720 695H157.50125L126.25125 663.75V633.375625L125 632.498125V-10.625L147.5 -39.375L460 -146.875L500 -117.5V-54.99375H720L751.25 -23.74375V7.50625V89.38125L688.75 151.88125V7.50625H500V525.6231250000001L479.375 554.3731250000001L252.2618750000001 632.5H438.75125H688.75V584.375zM437.5 -72.5L187.5 11.25V587.4981250000001L437.5 503.748125V-72.5zM845 289.996875H534.374375V352.496875H842.5L742.5 452.496875L786.875 496.246875L941.25 342.4968750000001V298.1218750000001L785.625 143.11875L741.875 186.86875L845 289.996875z" />
|
||||
<glyph glyph-name="smiley"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M500 -55C707.10625 -55 875 112.89375 875 320C875 527.106875 707.10625 695 500 695C292.893125 695 125 527.106875 125 320C125 112.89375 292.893125 -55 500 -55zM500 -117.5C741.625 -117.5 937.5 78.375 937.5 320C937.5 561.624375 741.625 757.5 500 757.5C258.375625 757.5 62.5 561.624375 62.5 320C62.5 78.375 258.375625 -117.5 500 -117.5zM343.75 320C378.2675 320 406.25 347.9825 406.25 382.5C406.25 417.0175 378.2675 445 343.75 445C309.2325 445 281.25 417.0175 281.25 382.5C281.25 347.9825 309.2325 320 343.75 320zM656.25 320C690.7687500000001 320 718.75 347.9825 718.75 382.5C718.75 417.0175 690.7687500000001 445 656.25 445C621.7318750000001 445 593.75 417.0175 593.75 382.5C593.75 347.9825 621.7318750000001 320 656.25 320zM499.999375 69.99375C404.881875 69.99375 322.171875 123.1125 279.915 201.3075L334.6475 231.515625C366.250625 172.58125 428.444375 132.49375 499.999375 132.49375C574.10625 132.49375 638.1687499999999 175.4875 668.6125000000001 237.8925000000001L725.13125 211.166875C684.66875 127.6125 599.0625 69.99375 499.999375 69.99375z" />
|
||||
horiz-adv-x="1000" d=" M256.938125 683.769375C328.885 731.8425 413.4700000000001 757.5 499.999375 757.5C616.031875 757.5 727.3125 711.40375 809.3625 629.356875C891.40625 547.309375 937.5 436.0325 937.5 320C937.5 233.470625 911.84375 148.88125 863.76875 76.9375C815.69375 4.9875 747.3625000000001 -51.0812500000001 667.4250000000001 -84.2C587.48 -117.3125 499.5125 -125.975 414.645625 -109.09375C329.77875 -92.2125 251.824375 -50.5437499999999 190.63875 10.64375C129.45375 71.83125 87.788125 149.78125 70.906875 234.65C54.026 319.516875 62.688125 407.484375 95.801875 487.426875C128.915 567.37 184.991875 635.69625 256.938125 683.769375zM291.66 8.2C353.328125 -33.0062499999999 425.83125 -55 499.999375 -55C599.455625 -55 694.8375 -15.4937500000001 765.1625 54.8312500000001C835.4875000000001 125.15625 875 220.5437499999999 875 320C875 394.168125 853.0062499999999 466.6675 811.8 528.335625C770.59375 590.004375 712.025 638.075625 643.5062499999999 666.458125C574.9825 694.84125 499.58375 702.2675 426.84125 687.798125C354.098125 673.328125 287.280625 637.611875 234.83625 585.1675C182.39125 532.7225 146.675 465.90125 132.205625 393.1581250000001C117.73625 320.415625 125.161875 245.013125 153.545 176.4937500000001C181.9275 107.96875 229.99125 49.40625 291.66 8.2zM406.25 382.5C406.25 347.9825 378.2675 320 343.75 320C309.2325 320 281.25 347.9825 281.25 382.5C281.25 417.0175 309.2325 445 343.75 445C378.2675 445 406.25 417.0175 406.25 382.5zM718.75 382.5C718.75 347.9825 690.7687500000001 320 656.25 320C621.7318750000001 320 593.75 347.9825 593.75 382.5C593.75 417.0175 621.7318750000001 445 656.25 445C690.7687500000001 445 718.75 417.0175 718.75 382.5zM500 132.5C466.038125 132.4187499999999 432.689375 141.55625 403.51875 158.9499999999999C374.348125 176.34375 350.44875 201.3306250000001 334.3737500000001 231.2475L279.9987500000001 201.24875C301.883125 160.75 334.5250000000001 127.08125 374.3250000000001 103.9500000000001C414.124375 80.81875 459.536875 69.13125 505.558125 70.1687500000001C551.57875 71.1999999999999 596.423125 84.9187499999999 635.14375 109.8125C673.8625000000001 134.70625 704.95625 169.8125 725 211.250625L668.75 238.1212500000001C653.375 206.4475000000001 629.39375 179.74375 599.551875 161.0625C569.70875 142.3875000000001 535.2075 132.4875000000001 500 132.5z" />
|
||||
<glyph glyph-name="squirrel"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M750 757.5C611.875 757.5 500 675.625 500 575C500 453.75 531.25 385.625 500 195C500 476.25 326.875 591.25 250 591.25C253.125 622.5 220 632.5 220 632.5C220 632.5 206.25 625.625 201.25 611.25C184.375 630.625 166.25 628.125 166.25 628.125L158.125 591.875C158.125 591.875 43.75 551.875 42.5 390.625C55 370 138.125 353.125 196.875 363.75C252.5 360.625 238.75 314.375 226.25 301.875C173.75 249.375 125 320 62.5 320C0 320 0 257.5 62.5 257.5C125 257.5 125 195 250 195C56.875 120 250 -55 250 -55H187.5C125 -55 125 -117.5 125 -117.5H500C687.5 -117.5 812.5 -55 812.5 99.375C812.5 152.5 785.625 211.25 750 257.5C680.625 348.75 764.375 425 812.5 382.5C860.625 340 1000 320 1000 507.5C1000 645.625 888.125 757.5 750 757.5zM156.25 445C138.75 445 125 458.75 125 476.25C125 493.75 138.75 507.5 156.25 507.5C173.75 507.5 187.5 493.75 187.5 476.25C187.5 458.75 173.75 445 156.25 445z" />
|
||||
@@ -495,7 +492,7 @@
|
||||
horiz-adv-x="1000" d=" M599.65875 429.243125L500 757.5L400.34125 429.243125H62.5L335.819375 216.7206250000001L234.35 -117.5L500 89.0625L765.6500000000001 -117.5L664.18125 216.7206250000001L937.5 429.243125H599.65875z" />
|
||||
<glyph glyph-name="stop"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M93.75 320C93.75 95.6343203812402 275.6343203812401 -86.25 500 -86.25C724.3656796187598 -86.25 906.25 95.6343203812402 906.25 320C906.25 544.3656796187599 724.3656796187598 726.25 500 726.25C275.6343203812401 726.25 93.75 544.3656796187599 93.75 320z M508.445625 352.80875L356.040625 507.5L312.5 463.305625L464.904375 308.6143750000001L312.523125 153.94375L356.0637500000001 109.75L508.445625 264.420625L660.825 109.75L704.36875 153.94375L551.98625 308.6143750000001L704.3937500000001 463.305625L660.85 507.5L508.445625 352.80875z" />
|
||||
horiz-adv-x="1000" d=" M256.938125 683.769375C328.885 731.8425 413.4700000000001 757.5 499.999375 757.5C616.031875 757.5 727.3125 711.40375 809.3625 629.356875C891.40625 547.309375 937.5 436.0325 937.5 320C937.5 233.470625 911.84375 148.88125 863.76875 76.9375C815.69375 4.9875 747.3625000000001 -51.0812500000001 667.4250000000001 -84.2C587.48 -117.3125 499.5125 -125.975 414.645625 -109.09375C329.77875 -92.2125 251.824375 -50.5437499999999 190.63875 10.64375C129.45375 71.83125 87.788125 149.78125 70.906875 234.65C54.026 319.516875 62.688125 407.484375 95.801875 487.426875C128.915 567.37 184.991875 635.69625 256.938125 683.769375zM291.66 8.2C353.328125 -33.0062499999999 425.83125 -55 499.999375 -55C599.455625 -55 694.8375 -15.4937500000001 765.1625 54.8312500000001C835.4875000000001 125.15625 875 220.5437499999999 875 320C875 394.168125 853.0062499999999 466.6675 811.8 528.335625C770.59375 590.004375 712.025 638.075625 643.5062499999999 666.458125C574.9825 694.84125 499.58375 702.2675 426.84125 687.798125C354.098125 673.328125 287.280625 637.611875 234.83625 585.1675C182.39125 532.7225 146.675 465.90125 132.205625 393.1581250000001C117.73625 320.415625 125.161875 245.013125 153.545 176.4937500000001C181.9275 107.96875 229.99125 49.40625 291.66 8.2zM508.1250000000001 353.125L660.625 507.5L704.375 463.125L551.875 308.75L704.375 153.75L660.625 110L508.1250000000001 264.375L356.25 110L312.5 153.75L465 308.75L312.5 463.125L356.25 507.5L508.1250000000001 353.125z" />
|
||||
<glyph glyph-name="sync"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M889.375 469.375625L820.775 383.8456250000001C805.5812500000001 440.091875 776.00625 491.81125 734.51875 533.6800000000001C678.75 589.96 604.984375 624.8675000000001 526.1018750000001 632.309375C447.21875 639.75125 368.2281250000001 619.254375 302.91625 574.3975C237.60375 529.54 190.11875 463.170625 168.749375 386.874375H234.374375C255.265625 445.703125 295.5093750000001 495.6975 348.5175 528.673125C401.52625 561.649375 464.15875 575.653125 526.16375 568.3925C588.168125 561.131875 645.86875 533.0374999999999 689.825 488.7075C720.58125 457.69 743.33125 420.010625 756.53125 378.916875L673.125 446.250625L634.375 398.125625L778.125 282.500625L821.25 286.875625L937.5 430.625625L889.375 469.375625zM171.915625 189.4125L113.12375 103.125L62.498625 138.125L166.87375 290.6268750000001L209.37375 298.7518750000001L361.87375 194.375L327.4987500000001 143.75L231.01625 209.4925000000001C244.03 167.7312500000001 266.88125 129.40625 297.97125 97.9000000000001C341.99 53.2937499999999 399.89625 25.0187500000001 462.141875 17.7375C524.3875 10.45625 587.25625 24.60625 640.38125 57.85C693.50625 91.1 733.7125 141.45625 754.375 200.623125H820C798.3 124.56875 750.66875 58.50625 685.3625 13.8875C620.06375 -30.7375000000001 541.2075 -51.1 462.46625 -43.675C383.725 -36.25625 310.063125 -1.51875 254.248125 54.51875C216.30375 92.6125000000001 188.234375 138.9187500000001 171.915625 189.4125z" />
|
||||
@@ -513,7 +510,7 @@
|
||||
horiz-adv-x="1000" d=" M62.5 757.5H937.5V-117.5H62.5V757.5zM125 -55H875V695H125V-55zM250.005 463.306875L294.19875 507.500625L515.1700000000001 286.53L470.975625 242.335625L470.9737500000001 242.3375L294.1943750000001 65.55625L250 109.75L426.78 286.531875L250.005 463.306875z" />
|
||||
<glyph glyph-name="text-size"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M638.6125000000001 632.5H738.6125L937.5 70H840.275L791.9437499999999 213.1075000000001H581.9443749999999L535.2774999999999 70H437.5L638.6125000000001 632.5zM437.5 70L290.861875 445H210.2975L62.5 70H146.541875L178.419375 161.9625H319.261875L352.299375 70H437.5zM678.05625 513.34125L604.166875 289.041875H770.83125L692.5 513.34125C689.46875 525.034375 687.2375 536.941875 685.83125 548.971875C684.1875 536.888125 681.5875 524.969375 678.05625 513.34125zM297.816875 224.1850000000001L249.130625 357.995625L200.444375 224.1850000000001H297.816875z" />
|
||||
horiz-adv-x="1000" d=" M209.999375 382.5L62.5 7.5H146.251875L178.12375 99.375H319.374375L352.500625 7.5H437.5L290.62625 382.5H209.999375zM200.62625 161.875L249.374375 295.624375L298.12625 161.875H200.62625z M738.75 570H638.75L437.5 7.5H535L581.875 150.625H791.875L840 7.5H937.5L738.75 570zM604.3737500000001 226.25L678.125 450.623125C681.8125 462.21625 684.3249999999999 474.155625 685.625 486.251875C687.3125 474.268125 689.6062499999999 462.37375 692.5 450.623125L770.625 226.25H604.3737500000001z" />
|
||||
<glyph glyph-name="three-bars"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M875 507.5H125V632.5H875V507.5zM875 257.5H125V382.5H875V257.5zM125 7.5H875V132.5H125V7.5z" />
|
||||
@@ -528,7 +525,7 @@
|
||||
horiz-adv-x="1000" d=" M333.584375 539.8824999999999L439.93 433.53625L386.4525 380.075L280.115 486.413125L226.023125 487.035625L115.971875 650.55625L169.440625 704.025625L332.961875 593.974375L333.584375 539.8824999999999zM513.393125 253.134375L513.3950000000001 253.1331250000001L566.871875 306.594375L566.870625 306.595625L636.8125 376.518125C668.00625 361.5487500000001 703.075 356.6125 737.19375 362.3893750000001C771.3125 368.166875 802.8 384.3725 827.31875 408.77625C851.73125 433.28625 867.95 464.75875 873.725 498.86C879.50625 532.961875 874.56875 568.015625 859.59375 599.19625L748.23125 487.66125L668.91875 566.9375L780.78125 678.24875C749.59375 693.385625 714.46875 698.435625 680.275 692.6975C646.0875000000001 686.95875 614.53125 670.71625 590.0006249999999 646.2275C565.47 621.73875 549.180625 590.22 543.396875 556.051875C537.6125000000001 521.88375 542.62125 486.7625 557.725625 455.570625L119.981875 17.95625V-21.56875L159.525625 -61.09375H199.07L513.393125 253.134375zM682.33125 -22.74375L507.78875 151.8L654.76875 298.733125C665.38125 296.2050000000001 676.15625 294.419375 687.0125 293.3887500000001L842.7375000000001 137.6624999999999C864.5 115.9000000000001 876.925 86.5750000000001 877.28125 56.1375C877.63125 25.70625 865.875 -3.3375000000001 844.60625 -24.6125C770.29375 -100.0125 682.33125 -22.74375 682.33125 -22.74375z" />
|
||||
<glyph glyph-name="trashcan"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M375 695H562.5V632.5H375V695zM687.5 632.5H625V695C625 729.5175 597.0174999999999 757.5 562.5 757.5H375C340.4825 757.5 312.5 729.5175 312.5 695V632.5H250H187.5H125V570H187.5V7.5L250 -55H687.5L750 7.5V570H812.5V632.5H750H687.5zM250 570V7.5H687.5V570H250zM375 507.5H312.5V70H375V507.5zM437.5 507.5H500V70H437.5V507.5zM625 507.5H562.5V70H625V507.5z" />
|
||||
horiz-adv-x="1000" d=" M750 570H625V632.5C625 649.07625 618.414375 664.97625 606.693125 676.696875C594.9725 688.418125 579.07625 695 562.5 695H375C358.42375 695 342.5275 688.418125 330.806875 676.696875C319.085625 664.97625 312.5 649.07625 312.5 632.5V570H125V507.5H187.5V-55L250 -117.5H687.5L750 -55V507.5H812.5V570H750zM375 632.5H562.5V570H375V632.5zM687.5 -55H250V507.5H687.5V-55zM437.5 445H500V7.5H437.5V445zM562.5 445H625V7.5H562.5V445zM312.5 445H375V7.5H312.5V445z" />
|
||||
<glyph glyph-name="triangle-down"
|
||||
unicode=""
|
||||
horiz-adv-x="1000" d=" M125 472.516875L150.84 507.5L850.41875 507.5L875 473.796875L523.319375 132.5H471.63875L125 472.516875z" />
|
||||
|
||||
|
Before Width: | Height: | Size: 222 KiB After Width: | Height: | Size: 227 KiB |
Binary file not shown.
@@ -117,12 +117,11 @@ abstract class ViewItem {
|
||||
if (typeof size === 'number') {
|
||||
this._size = size;
|
||||
this._cachedVisibleSize = undefined;
|
||||
dom.addClass(container, 'visible');
|
||||
} else {
|
||||
this._size = 0;
|
||||
this._cachedVisibleSize = size.cachedVisibleSize;
|
||||
}
|
||||
|
||||
dom.addClass(container, 'visible');
|
||||
}
|
||||
|
||||
layout(_orthogonalSize: number | undefined): void {
|
||||
|
||||
17
src/vs/base/common/insane/cgmanifest.json
Normal file
17
src/vs/base/common/insane/cgmanifest.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"registrations": [
|
||||
{
|
||||
"component": {
|
||||
"type": "git",
|
||||
"git": {
|
||||
"name": "insane",
|
||||
"repositoryUrl": "https://github.com/bevacqua/insane",
|
||||
"commitHash": "7f5a809f44a37e7d11ee5343b2d8bca4be6ba4ae"
|
||||
}
|
||||
},
|
||||
"license": "MIT",
|
||||
"version": "2.6.2"
|
||||
}
|
||||
],
|
||||
"version": 1
|
||||
}
|
||||
20
src/vs/base/common/insane/insane.d.ts
vendored
Normal file
20
src/vs/base/common/insane/insane.d.ts
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
export as namespace insane;
|
||||
|
||||
export = insane;
|
||||
|
||||
declare function insane(
|
||||
html: string,
|
||||
options?: {
|
||||
readonly allowedSchemes?: readonly string[],
|
||||
readonly allowedTags?: readonly string[],
|
||||
readonly allowedAttributes?: { readonly [key: string]: string[] },
|
||||
},
|
||||
strict?: boolean,
|
||||
): string;
|
||||
|
||||
declare namespace insane { }
|
||||
478
src/vs/base/common/insane/insane.js
Normal file
478
src/vs/base/common/insane/insane.js
Normal file
@@ -0,0 +1,478 @@
|
||||
/*
|
||||
The Source EULA (MIT)
|
||||
|
||||
Copyright © 2015 Nicolas Bevacqua
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
// ESM-comment-begin
|
||||
let __insane_exports;
|
||||
// ESM-comment-end
|
||||
|
||||
|
||||
|
||||
(function () { function r(e, n, t) { function o(i, f) { if (!n[i]) { if (!e[i]) { var c = "function" == typeof require && require; if (!f && c) return c(i, !0); if (u) return u(i, !0); var a = new Error("Cannot find module '" + i + "'"); throw a.code = "MODULE_NOT_FOUND", a } var p = n[i] = { exports: {} }; e[i][0].call(p.exports, function (r) { var n = e[i][1][r]; return o(n || r) }, p, p.exports, r, e, n, t) } return n[i].exports } for (var u = "function" == typeof require && require, i = 0; i < t.length; i++)o(t[i]); return o } return r })()({
|
||||
1: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var toMap = require('./toMap');
|
||||
var uris = ['background', 'base', 'cite', 'href', 'longdesc', 'src', 'usemap'];
|
||||
|
||||
module.exports = {
|
||||
uris: toMap(uris) // attributes that have an href and hence need to be sanitized
|
||||
};
|
||||
|
||||
}, { "./toMap": 10 }], 2: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var defaults = {
|
||||
allowedAttributes: {
|
||||
'*': ['title', 'accesskey'],
|
||||
a: ['href', 'name', 'target', 'aria-label'],
|
||||
iframe: ['allowfullscreen', 'frameborder', 'src'],
|
||||
img: ['src', 'alt', 'title', 'aria-label']
|
||||
},
|
||||
allowedClasses: {},
|
||||
allowedSchemes: ['http', 'https', 'mailto'],
|
||||
allowedTags: [
|
||||
'a', 'abbr', 'article', 'b', 'blockquote', 'br', 'caption', 'code', 'del', 'details', 'div', 'em',
|
||||
'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'hr', 'i', 'img', 'ins', 'kbd', 'li', 'main', 'mark',
|
||||
'ol', 'p', 'pre', 'section', 'span', 'strike', 'strong', 'sub', 'summary', 'sup', 'table',
|
||||
'tbody', 'td', 'th', 'thead', 'tr', 'u', 'ul'
|
||||
],
|
||||
filter: null
|
||||
};
|
||||
|
||||
module.exports = defaults;
|
||||
|
||||
}, {}], 3: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var toMap = require('./toMap');
|
||||
var voids = ['area', 'br', 'col', 'hr', 'img', 'wbr', 'input', 'base', 'basefont', 'link', 'meta'];
|
||||
|
||||
module.exports = {
|
||||
voids: toMap(voids)
|
||||
};
|
||||
|
||||
}, { "./toMap": 10 }], 4: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var he = require('he');
|
||||
var assign = require('assignment');
|
||||
var parser = require('./parser');
|
||||
var sanitizer = require('./sanitizer');
|
||||
var defaults = require('./defaults');
|
||||
|
||||
function insane(html, options, strict) {
|
||||
var buffer = [];
|
||||
var configuration = strict === true ? options : assign({}, defaults, options);
|
||||
var handler = sanitizer(buffer, configuration);
|
||||
|
||||
parser(html, handler);
|
||||
|
||||
return buffer.join('');
|
||||
}
|
||||
|
||||
insane.defaults = defaults;
|
||||
module.exports = insane;
|
||||
__insane_exports = insane;
|
||||
|
||||
}, { "./defaults": 2, "./parser": 7, "./sanitizer": 8, "assignment": 6, "he": 9 }], 5: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
module.exports = function lowercase(string) {
|
||||
return typeof string === 'string' ? string.toLowerCase() : string;
|
||||
};
|
||||
|
||||
}, {}], 6: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
function assignment(result) {
|
||||
var stack = Array.prototype.slice.call(arguments, 1);
|
||||
var item;
|
||||
var key;
|
||||
while (stack.length) {
|
||||
item = stack.shift();
|
||||
for (key in item) {
|
||||
if (item.hasOwnProperty(key)) {
|
||||
if (Object.prototype.toString.call(result[key]) === '[object Object]') {
|
||||
result[key] = assignment(result[key], item[key]);
|
||||
} else {
|
||||
result[key] = item[key];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
module.exports = assignment;
|
||||
|
||||
}, {}], 7: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var he = require('he');
|
||||
var lowercase = require('./lowercase');
|
||||
var attributes = require('./attributes');
|
||||
var elements = require('./elements');
|
||||
var rstart = /^<\s*([\w:-]+)((?:\s+[\w:-]+(?:\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|[^>\s]+))?)*)\s*(\/?)\s*>/;
|
||||
var rend = /^<\s*\/\s*([\w:-]+)[^>]*>/;
|
||||
var rattrs = /([\w:-]+)(?:\s*=\s*(?:(?:"((?:[^"])*)")|(?:'((?:[^'])*)')|([^>\s]+)))?/g;
|
||||
var rtag = /^</;
|
||||
var rtagend = /^<\s*\//;
|
||||
|
||||
function createStack() {
|
||||
var stack = [];
|
||||
stack.lastItem = function lastItem() {
|
||||
return stack[stack.length - 1];
|
||||
};
|
||||
return stack;
|
||||
}
|
||||
|
||||
function parser(html, handler) {
|
||||
var stack = createStack();
|
||||
var last = html;
|
||||
var chars;
|
||||
|
||||
while (html) {
|
||||
parsePart();
|
||||
}
|
||||
parseEndTag(); // clean up any remaining tags
|
||||
|
||||
function parsePart() {
|
||||
chars = true;
|
||||
parseTag();
|
||||
|
||||
var same = html === last;
|
||||
last = html;
|
||||
|
||||
if (same) { // discard, because it's invalid
|
||||
html = '';
|
||||
}
|
||||
}
|
||||
|
||||
function parseTag() {
|
||||
if (html.substr(0, 4) === '<!--') { // comments
|
||||
parseComment();
|
||||
} else if (rtagend.test(html)) {
|
||||
parseEdge(rend, parseEndTag);
|
||||
} else if (rtag.test(html)) {
|
||||
parseEdge(rstart, parseStartTag);
|
||||
}
|
||||
parseTagDecode();
|
||||
}
|
||||
|
||||
function parseEdge(regex, parser) {
|
||||
var match = html.match(regex);
|
||||
if (match) {
|
||||
html = html.substring(match[0].length);
|
||||
match[0].replace(regex, parser);
|
||||
chars = false;
|
||||
}
|
||||
}
|
||||
|
||||
function parseComment() {
|
||||
var index = html.indexOf('-->');
|
||||
if (index >= 0) {
|
||||
if (handler.comment) {
|
||||
handler.comment(html.substring(4, index));
|
||||
}
|
||||
html = html.substring(index + 3);
|
||||
chars = false;
|
||||
}
|
||||
}
|
||||
|
||||
function parseTagDecode() {
|
||||
if (!chars) {
|
||||
return;
|
||||
}
|
||||
var text;
|
||||
var index = html.indexOf('<');
|
||||
if (index >= 0) {
|
||||
text = html.substring(0, index);
|
||||
html = html.substring(index);
|
||||
} else {
|
||||
text = html;
|
||||
html = '';
|
||||
}
|
||||
if (handler.chars) {
|
||||
handler.chars(text);
|
||||
}
|
||||
}
|
||||
|
||||
function parseStartTag(tag, tagName, rest, unary) {
|
||||
var attrs = {};
|
||||
var low = lowercase(tagName);
|
||||
var u = elements.voids[low] || !!unary;
|
||||
|
||||
rest.replace(rattrs, attrReplacer);
|
||||
|
||||
if (!u) {
|
||||
stack.push(low);
|
||||
}
|
||||
if (handler.start) {
|
||||
handler.start(low, attrs, u);
|
||||
}
|
||||
|
||||
function attrReplacer(match, name, doubleQuotedValue, singleQuotedValue, unquotedValue) {
|
||||
if (doubleQuotedValue === void 0 && singleQuotedValue === void 0 && unquotedValue === void 0) {
|
||||
attrs[name] = void 0; // attribute is like <button disabled></button>
|
||||
} else {
|
||||
attrs[name] = he.decode(doubleQuotedValue || singleQuotedValue || unquotedValue || '');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function parseEndTag(tag, tagName) {
|
||||
var i;
|
||||
var pos = 0;
|
||||
var low = lowercase(tagName);
|
||||
if (low) {
|
||||
for (pos = stack.length - 1; pos >= 0; pos--) {
|
||||
if (stack[pos] === low) {
|
||||
break; // find the closest opened tag of the same type
|
||||
}
|
||||
}
|
||||
}
|
||||
if (pos >= 0) {
|
||||
for (i = stack.length - 1; i >= pos; i--) {
|
||||
if (handler.end) { // close all the open elements, up the stack
|
||||
handler.end(stack[i]);
|
||||
}
|
||||
}
|
||||
stack.length = pos;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = parser;
|
||||
|
||||
}, { "./attributes": 1, "./elements": 3, "./lowercase": 5, "he": 9 }], 8: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var he = require('he');
|
||||
var lowercase = require('./lowercase');
|
||||
var attributes = require('./attributes');
|
||||
var elements = require('./elements');
|
||||
|
||||
function sanitizer(buffer, options) {
|
||||
var last;
|
||||
var context;
|
||||
var o = options || {};
|
||||
|
||||
reset();
|
||||
|
||||
return {
|
||||
start: start,
|
||||
end: end,
|
||||
chars: chars
|
||||
};
|
||||
|
||||
function out(value) {
|
||||
buffer.push(value);
|
||||
}
|
||||
|
||||
function start(tag, attrs, unary) {
|
||||
var low = lowercase(tag);
|
||||
|
||||
if (context.ignoring) {
|
||||
ignore(low); return;
|
||||
}
|
||||
if ((o.allowedTags || []).indexOf(low) === -1) {
|
||||
ignore(low); return;
|
||||
}
|
||||
if (o.filter && !o.filter({ tag: low, attrs: attrs })) {
|
||||
ignore(low); return;
|
||||
}
|
||||
|
||||
out('<');
|
||||
out(low);
|
||||
Object.keys(attrs).forEach(parse);
|
||||
out(unary ? '/>' : '>');
|
||||
|
||||
function parse(key) {
|
||||
var value = attrs[key];
|
||||
var classesOk = (o.allowedClasses || {})[low] || [];
|
||||
var attrsOk = (o.allowedAttributes || {})[low] || [];
|
||||
attrsOk = attrsOk.concat((o.allowedAttributes || {})['*'] || []);
|
||||
var valid;
|
||||
var lkey = lowercase(key);
|
||||
if (lkey === 'class' && attrsOk.indexOf(lkey) === -1) {
|
||||
value = value.split(' ').filter(isValidClass).join(' ').trim();
|
||||
valid = value.length;
|
||||
} else {
|
||||
valid = attrsOk.indexOf(lkey) !== -1 && (attributes.uris[lkey] !== true || testUrl(value));
|
||||
}
|
||||
if (valid) {
|
||||
out(' ');
|
||||
out(key);
|
||||
if (typeof value === 'string') {
|
||||
out('="');
|
||||
out(he.encode(value));
|
||||
out('"');
|
||||
}
|
||||
}
|
||||
function isValidClass(className) {
|
||||
return classesOk && classesOk.indexOf(className) !== -1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function end(tag) {
|
||||
var low = lowercase(tag);
|
||||
var allowed = (o.allowedTags || []).indexOf(low) !== -1;
|
||||
if (allowed) {
|
||||
if (context.ignoring === false) {
|
||||
out('</');
|
||||
out(low);
|
||||
out('>');
|
||||
} else {
|
||||
unignore(low);
|
||||
}
|
||||
} else {
|
||||
unignore(low);
|
||||
}
|
||||
}
|
||||
|
||||
function testUrl(text) {
|
||||
var start = text[0];
|
||||
if (start === '#' || start === '/') {
|
||||
return true;
|
||||
}
|
||||
var colon = text.indexOf(':');
|
||||
if (colon === -1) {
|
||||
return true;
|
||||
}
|
||||
var questionmark = text.indexOf('?');
|
||||
if (questionmark !== -1 && colon > questionmark) {
|
||||
return true;
|
||||
}
|
||||
var hash = text.indexOf('#');
|
||||
if (hash !== -1 && colon > hash) {
|
||||
return true;
|
||||
}
|
||||
return o.allowedSchemes.some(matches);
|
||||
|
||||
function matches(scheme) {
|
||||
return text.indexOf(scheme + ':') === 0;
|
||||
}
|
||||
}
|
||||
|
||||
function chars(text) {
|
||||
if (context.ignoring === false) {
|
||||
out(o.transformText ? o.transformText(text) : text);
|
||||
}
|
||||
}
|
||||
|
||||
function ignore(tag) {
|
||||
if (elements.voids[tag]) {
|
||||
return;
|
||||
}
|
||||
if (context.ignoring === false) {
|
||||
context = { ignoring: tag, depth: 1 };
|
||||
} else if (context.ignoring === tag) {
|
||||
context.depth++;
|
||||
}
|
||||
}
|
||||
|
||||
function unignore(tag) {
|
||||
if (context.ignoring === tag) {
|
||||
if (--context.depth <= 0) {
|
||||
reset();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function reset() {
|
||||
context = { ignoring: false, depth: 0 };
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = sanitizer;
|
||||
|
||||
}, { "./attributes": 1, "./elements": 3, "./lowercase": 5, "he": 9 }], 9: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
var escapes = {
|
||||
'&': '&',
|
||||
'<': '<',
|
||||
'>': '>',
|
||||
'"': '"',
|
||||
"'": '''
|
||||
};
|
||||
var unescapes = {
|
||||
'&': '&',
|
||||
'<': '<',
|
||||
'>': '>',
|
||||
'"': '"',
|
||||
''': "'"
|
||||
};
|
||||
var rescaped = /(&|<|>|"|')/g;
|
||||
var runescaped = /[&<>"']/g;
|
||||
|
||||
function escapeHtmlChar(match) {
|
||||
return escapes[match];
|
||||
}
|
||||
function unescapeHtmlChar(match) {
|
||||
return unescapes[match];
|
||||
}
|
||||
|
||||
function escapeHtml(text) {
|
||||
return text == null ? '' : String(text).replace(runescaped, escapeHtmlChar);
|
||||
}
|
||||
|
||||
function unescapeHtml(html) {
|
||||
return html == null ? '' : String(html).replace(rescaped, unescapeHtmlChar);
|
||||
}
|
||||
|
||||
escapeHtml.options = unescapeHtml.options = {};
|
||||
|
||||
module.exports = {
|
||||
encode: escapeHtml,
|
||||
escape: escapeHtml,
|
||||
decode: unescapeHtml,
|
||||
unescape: unescapeHtml,
|
||||
version: '1.0.0-browser'
|
||||
};
|
||||
|
||||
}, {}], 10: [function (require, module, exports) {
|
||||
'use strict';
|
||||
|
||||
function toMap(list) {
|
||||
return list.reduce(asKey, {});
|
||||
}
|
||||
|
||||
function asKey(accumulator, item) {
|
||||
accumulator[item] = true;
|
||||
return accumulator;
|
||||
}
|
||||
|
||||
module.exports = toMap;
|
||||
|
||||
}, {}]
|
||||
}, {}, [4]);
|
||||
|
||||
// BEGIN MONACOCHANGE
|
||||
// __marked_exports = marked;
|
||||
// }).call(this);
|
||||
|
||||
// ESM-comment-begin
|
||||
define(function() { return __insane_exports; });
|
||||
// ESM-comment-end
|
||||
20
src/vs/base/common/insane/insane.license.txt
Normal file
20
src/vs/base/common/insane/insane.license.txt
Normal file
@@ -0,0 +1,20 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright © 2015 Nicolas Bevacqua
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
@@ -49,6 +49,8 @@ export namespace Schemas {
|
||||
|
||||
export const vscodeRemote: string = 'vscode-remote';
|
||||
|
||||
export const vscodeRemoteResource: string = 'vscode-remote-resource';
|
||||
|
||||
export const userData: string = 'vscode-userdata';
|
||||
}
|
||||
|
||||
@@ -64,7 +66,7 @@ class RemoteAuthoritiesImpl {
|
||||
}
|
||||
|
||||
public set(authority: string, host: string, port: number): void {
|
||||
this._hosts[authority] = (host === 'localhost' ? '127.0.0.1' : host);
|
||||
this._hosts[authority] = host;
|
||||
this._ports[authority] = port;
|
||||
}
|
||||
|
||||
@@ -76,9 +78,8 @@ class RemoteAuthoritiesImpl {
|
||||
const host = this._hosts[authority];
|
||||
const port = this._ports[authority];
|
||||
const connectionToken = this._connectionTokens[authority];
|
||||
const scheme = (host === '127.0.0.1' ? Schemas.http : Schemas.vscodeRemote);
|
||||
return URI.from({
|
||||
scheme: scheme,
|
||||
scheme: Schemas.vscodeRemoteResource,
|
||||
authority: `${host}:${port}`,
|
||||
path: `/vscode-remote2`,
|
||||
query: `path=${encodeURIComponent(path)}&tkn=${encodeURIComponent(connectionToken)}`
|
||||
|
||||
@@ -93,14 +93,12 @@ export function PlatformToString(platform: Platform) {
|
||||
}
|
||||
|
||||
let _platform: Platform = Platform.Web;
|
||||
if (_isNative) {
|
||||
if (_isMacintosh) {
|
||||
_platform = Platform.Mac;
|
||||
} else if (_isWindows) {
|
||||
_platform = Platform.Windows;
|
||||
} else if (_isLinux) {
|
||||
_platform = Platform.Linux;
|
||||
}
|
||||
if (_isMacintosh) {
|
||||
_platform = Platform.Mac;
|
||||
} else if (_isWindows) {
|
||||
_platform = Platform.Windows;
|
||||
} else if (_isLinux) {
|
||||
_platform = Platform.Linux;
|
||||
}
|
||||
|
||||
export const isWindows = _isWindows;
|
||||
|
||||
23
src/vs/base/common/search.ts
Normal file
23
src/vs/base/common/search.ts
Normal file
@@ -0,0 +1,23 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as strings from './strings';
|
||||
|
||||
export function buildReplaceStringWithCasePreserved(matches: string[] | null, pattern: string): string {
|
||||
if (matches && (matches[0] !== '')) {
|
||||
if (matches[0].toUpperCase() === matches[0]) {
|
||||
return pattern.toUpperCase();
|
||||
} else if (matches[0].toLowerCase() === matches[0]) {
|
||||
return pattern.toLowerCase();
|
||||
} else if (strings.containsUppercaseCharacter(matches[0][0])) {
|
||||
return pattern[0].toUpperCase() + pattern.substr(1);
|
||||
} else {
|
||||
// we don't understand its pattern yet.
|
||||
return pattern;
|
||||
}
|
||||
} else {
|
||||
return pattern;
|
||||
}
|
||||
}
|
||||
@@ -68,6 +68,8 @@ export interface IDataSource<T> {
|
||||
export interface IRenderer<T> {
|
||||
getHeight(entry: T): number;
|
||||
getTemplateId(entry: T): string;
|
||||
// rationale: will be replaced by quickinput later
|
||||
// tslint:disable-next-line: no-dom-globals
|
||||
renderTemplate(templateId: string, container: HTMLElement, styles: any): any;
|
||||
renderElement(entry: T, templateId: string, templateData: any, styles: any): void;
|
||||
disposeTemplate(templateId: string, templateData: any): void;
|
||||
@@ -92,4 +94,4 @@ export interface IModel<T> {
|
||||
runner: IRunner<T>;
|
||||
filter?: IFilter<T>;
|
||||
accessibilityProvider?: IAccessiblityProvider<T>;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no">
|
||||
|
||||
<meta http-equiv="Content-Security-Policy"
|
||||
content="default-src 'none'; img-src 'self' https: data: blob: vscode-remote:; media-src 'none'; frame-src 'self' {{WEBVIEW_ENDPOINT}} https://*.vscode-webview-test.com; script-src 'self' https://az416426.vo.msecnd.net 'unsafe-eval'; style-src 'self' 'unsafe-inline'; connect-src 'self' ws: wss: https:; font-src 'self' blob: vscode-remote:;">
|
||||
content="default-src 'none'; img-src 'self' https: data: blob:; media-src 'none'; frame-src 'self' {{WEBVIEW_ENDPOINT}} https://*.vscode-webview-test.com; script-src 'self' https://az416426.vo.msecnd.net 'unsafe-eval' https:; style-src 'self' 'unsafe-inline'; connect-src 'self' ws: wss: https:; font-src 'self' blob:;">
|
||||
|
||||
<meta id="vscode-workbench-web-configuration" data-settings="{{WORKBENCH_WEB_CONGIGURATION}}">
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<!-- {{SQL CARBON EDIT}} @anthonydresser add 'unsafe-eval' under script src; since its required by angular -->
|
||||
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; img-src 'self' https: data: blob: vscode-remote: http://127.0.0.1:*; media-src 'none'; frame-src 'self' https://*.vscode-webview-test.com; object-src 'self'; script-src 'self' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; connect-src 'self' https:; font-src 'self' https: vscode-remote: http://127.0.0.1:*;">
|
||||
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; img-src 'self' https: data: blob: vscode-remote-resource:; media-src 'none'; frame-src 'self' https://*.vscode-webview-test.com; object-src 'self'; script-src 'self' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; connect-src 'self' https:; font-src 'self' https: vscode-remote-resource:;">
|
||||
</head>
|
||||
<body class="vs-dark" aria-label="">
|
||||
</body>
|
||||
|
||||
@@ -53,7 +53,7 @@ import { LogLevelSetterChannel } from 'vs/platform/log/common/logIpc';
|
||||
import { setUnexpectedErrorHandler, onUnexpectedError } from 'vs/base/common/errors';
|
||||
import { ElectronURLListener } from 'vs/platform/url/electron-main/electronUrlListener';
|
||||
import { serve as serveDriver } from 'vs/platform/driver/electron-main/driver';
|
||||
import { IMenubarService } from 'vs/platform/menubar/common/menubar';
|
||||
import { IMenubarService } from 'vs/platform/menubar/node/menubar';
|
||||
import { MenubarService } from 'vs/platform/menubar/electron-main/menubarService';
|
||||
import { MenubarChannel } from 'vs/platform/menubar/node/menubarIpc';
|
||||
import { hasArgs } from 'vs/platform/environment/node/argv';
|
||||
@@ -560,7 +560,7 @@ export class CodeApplication extends Disposable {
|
||||
electronIpcServer.registerChannel('url', urlChannel);
|
||||
|
||||
const storageMainService = accessor.get(IStorageMainService);
|
||||
const storageChannel = this._register(new GlobalStorageDatabaseChannel(this.logService, storageMainService as StorageMainService));
|
||||
const storageChannel = this._register(new GlobalStorageDatabaseChannel(this.logService, storageMainService));
|
||||
electronIpcServer.registerChannel('storage', storageChannel);
|
||||
|
||||
// Log level management
|
||||
@@ -688,9 +688,9 @@ export class CodeApplication extends Disposable {
|
||||
}
|
||||
|
||||
private handleRemoteAuthorities(): void {
|
||||
protocol.registerHttpProtocol(Schemas.vscodeRemote, (request, callback) => {
|
||||
protocol.registerHttpProtocol(Schemas.vscodeRemoteResource, (request, callback) => {
|
||||
callback({
|
||||
url: request.url.replace(/^vscode-remote:/, 'http:'),
|
||||
url: request.url.replace(/^vscode-remote-resource:/, 'http:'),
|
||||
method: request.method
|
||||
});
|
||||
});
|
||||
|
||||
@@ -14,16 +14,25 @@ import { IOpenerService, IOpener } from 'vs/platform/opener/common/opener';
|
||||
import { equalsIgnoreCase } from 'vs/base/common/strings';
|
||||
import { IDisposable } from 'vs/base/common/lifecycle';
|
||||
import { LinkedList } from 'vs/base/common/linkedList';
|
||||
import { IDialogService } from 'vs/platform/dialogs/common/dialogs';
|
||||
import { localize } from 'vs/nls';
|
||||
import { IProductService } from 'vs/platform/product/common/product';
|
||||
import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage';
|
||||
import Severity from 'vs/base/common/severity';
|
||||
import { ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation';
|
||||
|
||||
export class OpenerService implements IOpenerService {
|
||||
|
||||
_serviceBrand: any;
|
||||
_serviceBrand!: ServiceIdentifier<any>;
|
||||
|
||||
private readonly _opener = new LinkedList<IOpener>();
|
||||
|
||||
constructor(
|
||||
@ICodeEditorService private readonly _editorService: ICodeEditorService,
|
||||
@ICommandService private readonly _commandService: ICommandService,
|
||||
@IStorageService private readonly _storageService: IStorageService,
|
||||
@IDialogService private readonly _dialogService: IDialogService,
|
||||
@IProductService private readonly _productService: IProductService
|
||||
) {
|
||||
//
|
||||
}
|
||||
@@ -33,7 +42,7 @@ export class OpenerService implements IOpenerService {
|
||||
return { dispose: remove };
|
||||
}
|
||||
|
||||
async open(resource: URI, options?: { openToSide?: boolean }): Promise<boolean> {
|
||||
async open(resource: URI, options?: { openToSide?: boolean, openExternal?: boolean }): Promise<boolean> {
|
||||
// no scheme ?!?
|
||||
if (!resource.scheme) {
|
||||
return Promise.resolve(false);
|
||||
@@ -49,14 +58,58 @@ export class OpenerService implements IOpenerService {
|
||||
return this._doOpen(resource, options);
|
||||
}
|
||||
|
||||
private _doOpen(resource: URI, options?: { openToSide?: boolean }): Promise<boolean> {
|
||||
private _doOpen(resource: URI, options?: { openToSide?: boolean, openExternal?: boolean }): Promise<boolean> {
|
||||
|
||||
const { scheme, path, query, fragment } = resource;
|
||||
const { scheme, authority, path, query, fragment } = resource;
|
||||
|
||||
if (equalsIgnoreCase(scheme, Schemas.http) || equalsIgnoreCase(scheme, Schemas.https) || equalsIgnoreCase(scheme, Schemas.mailto)) {
|
||||
// open http or default mail application
|
||||
return this.openExternal(resource);
|
||||
if (equalsIgnoreCase(scheme, Schemas.mailto) || (options && options.openExternal)) {
|
||||
// open default mail application
|
||||
return this._doOpenExternal(resource);
|
||||
}
|
||||
|
||||
if (equalsIgnoreCase(scheme, Schemas.http) || equalsIgnoreCase(scheme, Schemas.https)) {
|
||||
let trustedDomains: string[] = ['https://code.visualstudio.com'];
|
||||
try {
|
||||
const trustedDomainsSrc = this._storageService.get('http.trustedDomains', StorageScope.GLOBAL);
|
||||
if (trustedDomainsSrc) {
|
||||
trustedDomains = JSON.parse(trustedDomainsSrc);
|
||||
}
|
||||
} catch (err) { }
|
||||
|
||||
const domainToOpen = `${scheme}://${authority}`;
|
||||
|
||||
if (isDomainTrusted(domainToOpen, trustedDomains)) {
|
||||
return this._doOpenExternal(resource);
|
||||
} else {
|
||||
return this._dialogService.show(
|
||||
Severity.Info,
|
||||
localize(
|
||||
'openExternalLinkAt',
|
||||
'Do you want {0} to open the external website?\n{1}',
|
||||
this._productService.nameShort,
|
||||
resource.toString(true)
|
||||
),
|
||||
[
|
||||
localize('openLink', 'Open Link'),
|
||||
localize('cancel', 'Cancel'),
|
||||
localize('configureTrustedDomains', 'Configure Trusted Domains')
|
||||
],
|
||||
{
|
||||
cancelId: 1
|
||||
}).then((choice) => {
|
||||
if (choice === 0) {
|
||||
return this._doOpenExternal(resource);
|
||||
} else if (choice === 2) {
|
||||
return this._commandService.executeCommand('workbench.action.configureTrustedDomains', domainToOpen).then((pickedDomains: string[]) => {
|
||||
if (pickedDomains.indexOf(domainToOpen) !== -1) {
|
||||
return this._doOpenExternal(resource);
|
||||
}
|
||||
return Promise.resolve(false);
|
||||
});
|
||||
}
|
||||
return Promise.resolve(false);
|
||||
});
|
||||
}
|
||||
} else if (equalsIgnoreCase(scheme, Schemas.command)) {
|
||||
// run command or bail out if command isn't known
|
||||
if (!CommandsRegistry.getCommand(path)) {
|
||||
@@ -100,9 +153,27 @@ export class OpenerService implements IOpenerService {
|
||||
}
|
||||
}
|
||||
|
||||
openExternal(resource: URI): Promise<boolean> {
|
||||
private _doOpenExternal(resource: URI): Promise<boolean> {
|
||||
dom.windowOpenNoOpener(encodeURI(resource.toString(true)));
|
||||
|
||||
return Promise.resolve(true);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Check whether a domain like https://www.microsoft.com matches
|
||||
* the list of trusted domains.
|
||||
*/
|
||||
function isDomainTrusted(domain: string, trustedDomains: string[]) {
|
||||
for (let i = 0; i < trustedDomains.length; i++) {
|
||||
if (trustedDomains[i] === '*') {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (trustedDomains[i] === domain) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -86,6 +86,14 @@ export class CursorModelState {
|
||||
|
||||
class AutoClosedAction {
|
||||
|
||||
public static getAllAutoClosedCharacters(autoClosedActions: AutoClosedAction[]): Range[] {
|
||||
let autoClosedCharacters: Range[] = [];
|
||||
for (const autoClosedAction of autoClosedActions) {
|
||||
autoClosedCharacters = autoClosedCharacters.concat(autoClosedAction.getAutoClosedCharactersRanges());
|
||||
}
|
||||
return autoClosedCharacters;
|
||||
}
|
||||
|
||||
private readonly _model: ITextModel;
|
||||
|
||||
private _autoClosedCharactersDecorations: string[];
|
||||
@@ -593,11 +601,12 @@ export class Cursor extends viewEvents.ViewEventEmitter implements ICursors {
|
||||
}
|
||||
const closeChar = m[1];
|
||||
|
||||
const openChar = this.context.config.autoClosingPairsClose[closeChar];
|
||||
if (!openChar) {
|
||||
const autoClosingPairsCandidates = this.context.config.autoClosingPairsClose2.get(closeChar);
|
||||
if (!autoClosingPairsCandidates || autoClosingPairsCandidates.length !== 1) {
|
||||
return null;
|
||||
}
|
||||
|
||||
const openChar = autoClosingPairsCandidates[0].open;
|
||||
const closeCharIndex = edit.text.length - m[2].length - 1;
|
||||
const openCharIndex = edit.text.lastIndexOf(openChar, closeCharIndex - 1);
|
||||
if (openCharIndex === -1) {
|
||||
@@ -738,7 +747,8 @@ export class Cursor extends viewEvents.ViewEventEmitter implements ICursors {
|
||||
private _interpretCompositionEnd(source: string) {
|
||||
if (!this._isDoingComposition && source === 'keyboard') {
|
||||
// composition finishes, let's check if we need to auto complete if necessary.
|
||||
this._executeEditOperation(TypeOperations.compositionEndWithInterceptors(this._prevEditOperationType, this.context.config, this.context.model, this.getSelections()));
|
||||
const autoClosedCharacters = AutoClosedAction.getAllAutoClosedCharacters(this._autoClosedActions);
|
||||
this._executeEditOperation(TypeOperations.compositionEndWithInterceptors(this._prevEditOperationType, this.context.config, this.context.model, this.getSelections(), autoClosedCharacters));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -756,14 +766,8 @@ export class Cursor extends viewEvents.ViewEventEmitter implements ICursors {
|
||||
chr = text.charAt(i);
|
||||
}
|
||||
|
||||
let autoClosedCharacters: Range[] = [];
|
||||
if (this._autoClosedActions.length > 0) {
|
||||
for (let i = 0, len = this._autoClosedActions.length; i < len; i++) {
|
||||
autoClosedCharacters = autoClosedCharacters.concat(this._autoClosedActions[i].getAutoClosedCharactersRanges());
|
||||
}
|
||||
}
|
||||
|
||||
// Here we must interpret each typed character individually, that's why we create a new context
|
||||
// Here we must interpret each typed character individually
|
||||
const autoClosedCharacters = AutoClosedAction.getAllAutoClosedCharacters(this._autoClosedActions);
|
||||
this._executeEditOperation(TypeOperations.typeWithInterceptors(this._prevEditOperationType, this.context.config, this.context.model, this.getSelections(), autoClosedCharacters, chr));
|
||||
}
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ import { ICommand, IConfiguration, ScrollType } from 'vs/editor/common/editorCom
|
||||
import { ITextModel, TextModelResolvedOptions } from 'vs/editor/common/model';
|
||||
import { TextModel } from 'vs/editor/common/model/textModel';
|
||||
import { LanguageIdentifier } from 'vs/editor/common/modes';
|
||||
import { IAutoClosingPair } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { IAutoClosingPair, StandardAutoClosingPairConditional } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry';
|
||||
import { VerticalRevealType } from 'vs/editor/common/view/viewEvents';
|
||||
import { IViewModel } from 'vs/editor/common/viewModel/viewModel';
|
||||
@@ -67,11 +67,22 @@ export interface ICursors {
|
||||
export interface CharacterMap {
|
||||
[char: string]: string;
|
||||
}
|
||||
export interface MultipleCharacterMap {
|
||||
[char: string]: string[];
|
||||
}
|
||||
|
||||
const autoCloseAlways = () => true;
|
||||
const autoCloseNever = () => false;
|
||||
const autoCloseBeforeWhitespace = (chr: string) => (chr === ' ' || chr === '\t');
|
||||
|
||||
function appendEntry<K, V>(target: Map<K, V[]>, key: K, value: V): void {
|
||||
if (target.has(key)) {
|
||||
target.get(key)!.push(value);
|
||||
} else {
|
||||
target.set(key, [value]);
|
||||
}
|
||||
}
|
||||
|
||||
export class CursorConfiguration {
|
||||
_cursorMoveConfigurationBrand: void;
|
||||
|
||||
@@ -90,8 +101,8 @@ export class CursorConfiguration {
|
||||
public readonly autoClosingQuotes: EditorAutoClosingStrategy;
|
||||
public readonly autoSurround: EditorAutoSurroundStrategy;
|
||||
public readonly autoIndent: boolean;
|
||||
public readonly autoClosingPairsOpen: CharacterMap;
|
||||
public readonly autoClosingPairsClose: CharacterMap;
|
||||
public readonly autoClosingPairsOpen2: Map<string, StandardAutoClosingPairConditional[]>;
|
||||
public readonly autoClosingPairsClose2: Map<string, StandardAutoClosingPairConditional[]>;
|
||||
public readonly surroundingPairs: CharacterMap;
|
||||
public readonly shouldAutoCloseBefore: { quote: (ch: string) => boolean, bracket: (ch: string) => boolean };
|
||||
|
||||
@@ -138,8 +149,8 @@ export class CursorConfiguration {
|
||||
this.autoSurround = c.autoSurround;
|
||||
this.autoIndent = c.autoIndent;
|
||||
|
||||
this.autoClosingPairsOpen = {};
|
||||
this.autoClosingPairsClose = {};
|
||||
this.autoClosingPairsOpen2 = new Map<string, StandardAutoClosingPairConditional[]>();
|
||||
this.autoClosingPairsClose2 = new Map<string, StandardAutoClosingPairConditional[]>();
|
||||
this.surroundingPairs = {};
|
||||
this._electricChars = null;
|
||||
|
||||
@@ -151,8 +162,10 @@ export class CursorConfiguration {
|
||||
let autoClosingPairs = CursorConfiguration._getAutoClosingPairs(languageIdentifier);
|
||||
if (autoClosingPairs) {
|
||||
for (const pair of autoClosingPairs) {
|
||||
this.autoClosingPairsOpen[pair.open] = pair.close;
|
||||
this.autoClosingPairsClose[pair.close] = pair.open;
|
||||
appendEntry(this.autoClosingPairsOpen2, pair.open.charAt(pair.open.length - 1), pair);
|
||||
if (pair.close.length === 1) {
|
||||
appendEntry(this.autoClosingPairsClose2, pair.close, pair);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -190,7 +203,7 @@ export class CursorConfiguration {
|
||||
}
|
||||
}
|
||||
|
||||
private static _getAutoClosingPairs(languageIdentifier: LanguageIdentifier): IAutoClosingPair[] | null {
|
||||
private static _getAutoClosingPairs(languageIdentifier: LanguageIdentifier): StandardAutoClosingPairConditional[] | null {
|
||||
try {
|
||||
return LanguageConfigurationRegistry.getAutoClosingPairs(languageIdentifier.id);
|
||||
} catch (e) {
|
||||
|
||||
@@ -63,7 +63,8 @@ export class DeleteOperations {
|
||||
const lineText = model.getLineContent(position.lineNumber);
|
||||
const character = lineText[position.column - 2];
|
||||
|
||||
if (!config.autoClosingPairsOpen.hasOwnProperty(character)) {
|
||||
const autoClosingPairCandidates = config.autoClosingPairsOpen2.get(character);
|
||||
if (!autoClosingPairCandidates) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -78,9 +79,14 @@ export class DeleteOperations {
|
||||
}
|
||||
|
||||
const afterCharacter = lineText[position.column - 1];
|
||||
const closeCharacter = config.autoClosingPairsOpen[character];
|
||||
|
||||
if (afterCharacter !== closeCharacter) {
|
||||
let foundAutoClosingPair = false;
|
||||
for (const autoClosingPairCandidate of autoClosingPairCandidates) {
|
||||
if (autoClosingPairCandidate.open === character && autoClosingPairCandidate.close === afterCharacter) {
|
||||
foundAutoClosingPair = true;
|
||||
}
|
||||
}
|
||||
if (!foundAutoClosingPair) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,9 +13,10 @@ import { CursorColumns, CursorConfiguration, EditOperationResult, EditOperationT
|
||||
import { WordCharacterClass, getMapForWordSeparators } from 'vs/editor/common/controller/wordCharacterClassifier';
|
||||
import { Range } from 'vs/editor/common/core/range';
|
||||
import { Selection } from 'vs/editor/common/core/selection';
|
||||
import { Position } from 'vs/editor/common/core/position';
|
||||
import { ICommand, ICursorStateComputerData } from 'vs/editor/common/editorCommon';
|
||||
import { ITextModel } from 'vs/editor/common/model';
|
||||
import { EnterAction, IndentAction } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { EnterAction, IndentAction, StandardAutoClosingPairConditional } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry';
|
||||
import { IElectricAction } from 'vs/editor/common/modes/supports/electricCharacter';
|
||||
|
||||
@@ -433,7 +434,11 @@ export class TypeOperations {
|
||||
private static _isAutoClosingCloseCharType(config: CursorConfiguration, model: ITextModel, selections: Selection[], autoClosedCharacters: Range[], ch: string): boolean {
|
||||
const autoCloseConfig = isQuote(ch) ? config.autoClosingQuotes : config.autoClosingBrackets;
|
||||
|
||||
if (autoCloseConfig === 'never' || !config.autoClosingPairsClose.hasOwnProperty(ch)) {
|
||||
if (autoCloseConfig === 'never') {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!config.autoClosingPairsClose2.has(ch)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -469,15 +474,6 @@ export class TypeOperations {
|
||||
return true;
|
||||
}
|
||||
|
||||
private static _countNeedlesInHaystack(haystack: string, needle: string): number {
|
||||
let cnt = 0;
|
||||
let lastIndex = -1;
|
||||
while ((lastIndex = haystack.indexOf(needle, lastIndex + 1)) !== -1) {
|
||||
cnt++;
|
||||
}
|
||||
return cnt;
|
||||
}
|
||||
|
||||
private static _runAutoClosingCloseCharType(prevEditOperationType: EditOperationType, config: CursorConfiguration, model: ITextModel, selections: Selection[], ch: string): EditOperationResult {
|
||||
let commands: ICommand[] = [];
|
||||
for (let i = 0, len = selections.length; i < len; i++) {
|
||||
@@ -492,65 +488,98 @@ export class TypeOperations {
|
||||
});
|
||||
}
|
||||
|
||||
private static _isBeforeClosingBrace(config: CursorConfiguration, ch: string, characterAfter: string) {
|
||||
const thisBraceIsSymmetric = (config.autoClosingPairsOpen[ch] === ch);
|
||||
let isBeforeCloseBrace = false;
|
||||
for (let otherCloseBrace in config.autoClosingPairsClose) {
|
||||
const otherBraceIsSymmetric = (config.autoClosingPairsOpen[otherCloseBrace] === otherCloseBrace);
|
||||
if (!thisBraceIsSymmetric && otherBraceIsSymmetric) {
|
||||
continue;
|
||||
}
|
||||
if (characterAfter === otherCloseBrace) {
|
||||
isBeforeCloseBrace = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return isBeforeCloseBrace;
|
||||
}
|
||||
|
||||
private static _isAutoClosingOpenCharType(config: CursorConfiguration, model: ITextModel, selections: Selection[], ch: string): boolean {
|
||||
const chIsQuote = isQuote(ch);
|
||||
const autoCloseConfig = chIsQuote ? config.autoClosingQuotes : config.autoClosingBrackets;
|
||||
|
||||
if (autoCloseConfig === 'never' || !config.autoClosingPairsOpen.hasOwnProperty(ch)) {
|
||||
private static _isBeforeClosingBrace(config: CursorConfiguration, autoClosingPair: StandardAutoClosingPairConditional, characterAfter: string) {
|
||||
const otherAutoClosingPairs = config.autoClosingPairsClose2.get(characterAfter);
|
||||
if (!otherAutoClosingPairs) {
|
||||
return false;
|
||||
}
|
||||
|
||||
let shouldAutoCloseBefore = chIsQuote ? config.shouldAutoCloseBefore.quote : config.shouldAutoCloseBefore.bracket;
|
||||
const thisBraceIsSymmetric = (autoClosingPair.open === autoClosingPair.close);
|
||||
for (const otherAutoClosingPair of otherAutoClosingPairs) {
|
||||
const otherBraceIsSymmetric = (otherAutoClosingPair.open === otherAutoClosingPair.close);
|
||||
if (!thisBraceIsSymmetric && otherBraceIsSymmetric) {
|
||||
continue;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
private static _findAutoClosingPairOpen(config: CursorConfiguration, model: ITextModel, positions: Position[], ch: string): StandardAutoClosingPairConditional | null {
|
||||
const autoClosingPairCandidates = config.autoClosingPairsOpen2.get(ch);
|
||||
if (!autoClosingPairCandidates) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// Determine which auto-closing pair it is
|
||||
let autoClosingPair: StandardAutoClosingPairConditional | null = null;
|
||||
for (const autoClosingPairCandidate of autoClosingPairCandidates) {
|
||||
if (autoClosingPair === null || autoClosingPairCandidate.open.length > autoClosingPair.open.length) {
|
||||
let candidateIsMatch = true;
|
||||
for (const position of positions) {
|
||||
const relevantText = model.getValueInRange(new Range(position.lineNumber, position.column - autoClosingPairCandidate.open.length + 1, position.lineNumber, position.column));
|
||||
if (relevantText + ch !== autoClosingPairCandidate.open) {
|
||||
candidateIsMatch = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (candidateIsMatch) {
|
||||
autoClosingPair = autoClosingPairCandidate;
|
||||
}
|
||||
}
|
||||
}
|
||||
return autoClosingPair;
|
||||
}
|
||||
|
||||
private static _isAutoClosingOpenCharType(config: CursorConfiguration, model: ITextModel, selections: Selection[], ch: string, insertOpenCharacter: boolean): StandardAutoClosingPairConditional | null {
|
||||
const chIsQuote = isQuote(ch);
|
||||
const autoCloseConfig = chIsQuote ? config.autoClosingQuotes : config.autoClosingBrackets;
|
||||
if (autoCloseConfig === 'never') {
|
||||
return null;
|
||||
}
|
||||
|
||||
const autoClosingPair = this._findAutoClosingPairOpen(config, model, selections.map(s => s.getPosition()), ch);
|
||||
if (!autoClosingPair) {
|
||||
return null;
|
||||
}
|
||||
|
||||
const shouldAutoCloseBefore = chIsQuote ? config.shouldAutoCloseBefore.quote : config.shouldAutoCloseBefore.bracket;
|
||||
|
||||
for (let i = 0, len = selections.length; i < len; i++) {
|
||||
const selection = selections[i];
|
||||
if (!selection.isEmpty()) {
|
||||
return false;
|
||||
return null;
|
||||
}
|
||||
|
||||
const position = selection.getPosition();
|
||||
const lineText = model.getLineContent(position.lineNumber);
|
||||
|
||||
// Do not auto-close ' or " after a word character
|
||||
if ((chIsQuote && position.column > 1) && autoCloseConfig !== 'always') {
|
||||
const wordSeparators = getMapForWordSeparators(config.wordSeparators);
|
||||
const characterBeforeCode = lineText.charCodeAt(position.column - 2);
|
||||
const characterBeforeType = wordSeparators.get(characterBeforeCode);
|
||||
if (characterBeforeType === WordCharacterClass.Regular) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Only consider auto closing the pair if a space follows or if another autoclosed pair follows
|
||||
const characterAfter = lineText.charAt(position.column - 1);
|
||||
if (characterAfter) {
|
||||
let isBeforeCloseBrace = TypeOperations._isBeforeClosingBrace(config, ch, characterAfter);
|
||||
if (lineText.length > position.column - 1) {
|
||||
const characterAfter = lineText.charAt(position.column - 1);
|
||||
const isBeforeCloseBrace = TypeOperations._isBeforeClosingBrace(config, autoClosingPair, characterAfter);
|
||||
|
||||
if (!isBeforeCloseBrace && !shouldAutoCloseBefore(characterAfter)) {
|
||||
return false;
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
if (!model.isCheapToTokenize(position.lineNumber)) {
|
||||
// Do not force tokenization
|
||||
return false;
|
||||
return null;
|
||||
}
|
||||
|
||||
// Do not auto-close ' or " after a word character
|
||||
if (autoClosingPair.open.length === 1 && chIsQuote && autoCloseConfig !== 'always') {
|
||||
const wordSeparators = getMapForWordSeparators(config.wordSeparators);
|
||||
if (insertOpenCharacter && position.column > 1 && wordSeparators.get(lineText.charCodeAt(position.column - 2)) === WordCharacterClass.Regular) {
|
||||
return null;
|
||||
}
|
||||
if (!insertOpenCharacter && position.column > 2 && wordSeparators.get(lineText.charCodeAt(position.column - 3)) === WordCharacterClass.Regular) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
model.forceTokenization(position.lineNumber);
|
||||
@@ -558,25 +587,24 @@ export class TypeOperations {
|
||||
|
||||
let shouldAutoClosePair = false;
|
||||
try {
|
||||
shouldAutoClosePair = LanguageConfigurationRegistry.shouldAutoClosePair(ch, lineTokens, position.column);
|
||||
shouldAutoClosePair = LanguageConfigurationRegistry.shouldAutoClosePair(autoClosingPair, lineTokens, insertOpenCharacter ? position.column : position.column - 1);
|
||||
} catch (e) {
|
||||
onUnexpectedError(e);
|
||||
}
|
||||
|
||||
if (!shouldAutoClosePair) {
|
||||
return false;
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
return autoClosingPair;
|
||||
}
|
||||
|
||||
private static _runAutoClosingOpenCharType(prevEditOperationType: EditOperationType, config: CursorConfiguration, model: ITextModel, selections: Selection[], ch: string): EditOperationResult {
|
||||
private static _runAutoClosingOpenCharType(prevEditOperationType: EditOperationType, config: CursorConfiguration, model: ITextModel, selections: Selection[], ch: string, insertOpenCharacter: boolean, autoClosingPair: StandardAutoClosingPairConditional): EditOperationResult {
|
||||
let commands: ICommand[] = [];
|
||||
for (let i = 0, len = selections.length; i < len; i++) {
|
||||
const selection = selections[i];
|
||||
const closeCharacter = config.autoClosingPairsOpen[ch];
|
||||
commands[i] = new TypeWithAutoClosingCommand(selection, ch, closeCharacter);
|
||||
commands[i] = new TypeWithAutoClosingCommand(selection, ch, insertOpenCharacter, autoClosingPair.close);
|
||||
}
|
||||
return new EditOperationResult(EditOperationType.Typing, commands, {
|
||||
shouldPushStackElementBefore: true,
|
||||
@@ -679,14 +707,6 @@ export class TypeOperations {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (electricAction.appendText) {
|
||||
const command = new ReplaceCommandWithOffsetCursorState(selection, ch + electricAction.appendText, 0, -electricAction.appendText.length);
|
||||
return new EditOperationResult(EditOperationType.Typing, [command], {
|
||||
shouldPushStackElementBefore: false,
|
||||
shouldPushStackElementAfter: true
|
||||
});
|
||||
}
|
||||
|
||||
if (electricAction.matchOpenBracket) {
|
||||
let endColumn = (lineTokens.getLineContent() + ch).lastIndexOf(electricAction.matchOpenBracket) + 1;
|
||||
let match = model.findMatchingBracketUp(electricAction.matchOpenBracket, {
|
||||
@@ -722,87 +742,44 @@ export class TypeOperations {
|
||||
return null;
|
||||
}
|
||||
|
||||
public static compositionEndWithInterceptors(prevEditOperationType: EditOperationType, config: CursorConfiguration, model: ITextModel, selections: Selection[]): EditOperationResult | null {
|
||||
if (config.autoClosingQuotes === 'never') {
|
||||
/**
|
||||
* This is very similar with typing, but the character is already in the text buffer!
|
||||
*/
|
||||
public static compositionEndWithInterceptors(prevEditOperationType: EditOperationType, config: CursorConfiguration, model: ITextModel, selections: Selection[], autoClosedCharacters: Range[]): EditOperationResult | null {
|
||||
let ch: string | null = null;
|
||||
// extract last typed character
|
||||
for (const selection of selections) {
|
||||
if (!selection.isEmpty()) {
|
||||
return null;
|
||||
}
|
||||
const position = selection.getPosition();
|
||||
const currentChar = model.getValueInRange(new Range(position.lineNumber, position.column - 1, position.lineNumber, position.column));
|
||||
if (ch === null) {
|
||||
ch = currentChar;
|
||||
} else if (ch !== currentChar) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
if (!ch) {
|
||||
return null;
|
||||
}
|
||||
|
||||
let commands: ICommand[] = [];
|
||||
|
||||
for (let i = 0; i < selections.length; i++) {
|
||||
if (!selections[i].isEmpty()) {
|
||||
continue;
|
||||
}
|
||||
const position = selections[i].getPosition();
|
||||
const lineText = model.getLineContent(position.lineNumber);
|
||||
const ch = lineText.charAt(position.column - 2);
|
||||
|
||||
if (config.autoClosingPairsClose.hasOwnProperty(ch)) { // first of all, it's a closing tag
|
||||
if (ch === config.autoClosingPairsClose[ch] /** isEqualPair */) {
|
||||
const lineTextBeforeCursor = lineText.substr(0, position.column - 2);
|
||||
const chCntBefore = this._countNeedlesInHaystack(lineTextBeforeCursor, ch);
|
||||
|
||||
if (chCntBefore % 2 === 1) {
|
||||
continue; // it pairs with the opening tag.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// As we are not typing in a new character, so we don't need to run `_runAutoClosingCloseCharType`
|
||||
// Next step, let's try to check if it's an open char.
|
||||
if (config.autoClosingPairsOpen.hasOwnProperty(ch)) {
|
||||
if (isQuote(ch) && position.column > 2) {
|
||||
const wordSeparators = getMapForWordSeparators(config.wordSeparators);
|
||||
const characterBeforeCode = lineText.charCodeAt(position.column - 3);
|
||||
const characterBeforeType = wordSeparators.get(characterBeforeCode);
|
||||
if (characterBeforeType === WordCharacterClass.Regular) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
const characterAfter = lineText.charAt(position.column - 1);
|
||||
|
||||
if (characterAfter) {
|
||||
let isBeforeCloseBrace = TypeOperations._isBeforeClosingBrace(config, ch, characterAfter);
|
||||
let shouldAutoCloseBefore = isQuote(ch) ? config.shouldAutoCloseBefore.quote : config.shouldAutoCloseBefore.bracket;
|
||||
if (isBeforeCloseBrace) {
|
||||
// In normal auto closing logic, we will auto close if the cursor is even before a closing brace intentionally.
|
||||
// However for composition mode, we do nothing here as users might clear all the characters for composition and we don't want to do a unnecessary auto close.
|
||||
// Related: microsoft/vscode#57250.
|
||||
continue;
|
||||
}
|
||||
if (!shouldAutoCloseBefore(characterAfter)) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
if (!model.isCheapToTokenize(position.lineNumber)) {
|
||||
// Do not force tokenization
|
||||
continue;
|
||||
}
|
||||
|
||||
model.forceTokenization(position.lineNumber);
|
||||
const lineTokens = model.getLineTokens(position.lineNumber);
|
||||
|
||||
let shouldAutoClosePair = false;
|
||||
|
||||
try {
|
||||
shouldAutoClosePair = LanguageConfigurationRegistry.shouldAutoClosePair(ch, lineTokens, position.column - 1);
|
||||
} catch (e) {
|
||||
onUnexpectedError(e);
|
||||
}
|
||||
|
||||
if (shouldAutoClosePair) {
|
||||
const closeCharacter = config.autoClosingPairsOpen[ch];
|
||||
commands[i] = new ReplaceCommandWithOffsetCursorState(selections[i], closeCharacter, 0, -closeCharacter.length);
|
||||
}
|
||||
}
|
||||
if (this._isAutoClosingCloseCharType(config, model, selections, autoClosedCharacters, ch)) {
|
||||
// Unfortunately, the close character is at this point "doubled", so we need to delete it...
|
||||
const commands = selections.map(s => new ReplaceCommand(new Range(s.positionLineNumber, s.positionColumn, s.positionLineNumber, s.positionColumn + 1), '', false));
|
||||
return new EditOperationResult(EditOperationType.Typing, commands, {
|
||||
shouldPushStackElementBefore: true,
|
||||
shouldPushStackElementAfter: false
|
||||
});
|
||||
}
|
||||
|
||||
return new EditOperationResult(EditOperationType.Typing, commands, {
|
||||
shouldPushStackElementBefore: true,
|
||||
shouldPushStackElementAfter: false
|
||||
});
|
||||
const autoClosingPairOpenCharType = this._isAutoClosingOpenCharType(config, model, selections, ch, false);
|
||||
if (autoClosingPairOpenCharType) {
|
||||
return this._runAutoClosingOpenCharType(prevEditOperationType, config, model, selections, ch, false, autoClosingPairOpenCharType);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
public static typeWithInterceptors(prevEditOperationType: EditOperationType, config: CursorConfiguration, model: ITextModel, selections: Selection[], autoClosedCharacters: Range[], ch: string): EditOperationResult {
|
||||
@@ -840,8 +817,9 @@ export class TypeOperations {
|
||||
return this._runAutoClosingCloseCharType(prevEditOperationType, config, model, selections, ch);
|
||||
}
|
||||
|
||||
if (this._isAutoClosingOpenCharType(config, model, selections, ch)) {
|
||||
return this._runAutoClosingOpenCharType(prevEditOperationType, config, model, selections, ch);
|
||||
const autoClosingPairOpenCharType = this._isAutoClosingOpenCharType(config, model, selections, ch, true);
|
||||
if (autoClosingPairOpenCharType) {
|
||||
return this._runAutoClosingOpenCharType(prevEditOperationType, config, model, selections, ch, true, autoClosingPairOpenCharType);
|
||||
}
|
||||
|
||||
if (this._isSurroundSelectionType(config, model, selections, ch)) {
|
||||
@@ -929,12 +907,14 @@ export class TypeOperations {
|
||||
|
||||
export class TypeWithAutoClosingCommand extends ReplaceCommandWithOffsetCursorState {
|
||||
|
||||
private _closeCharacter: string;
|
||||
private readonly _openCharacter: string;
|
||||
private readonly _closeCharacter: string;
|
||||
public closeCharacterRange: Range | null;
|
||||
public enclosingRange: Range | null;
|
||||
|
||||
constructor(selection: Selection, openCharacter: string, closeCharacter: string) {
|
||||
super(selection, openCharacter + closeCharacter, 0, -closeCharacter.length);
|
||||
constructor(selection: Selection, openCharacter: string, insertOpenCharacter: boolean, closeCharacter: string) {
|
||||
super(selection, (insertOpenCharacter ? openCharacter : '') + closeCharacter, 0, -closeCharacter.length);
|
||||
this._openCharacter = openCharacter;
|
||||
this._closeCharacter = closeCharacter;
|
||||
this.closeCharacterRange = null;
|
||||
this.enclosingRange = null;
|
||||
@@ -944,7 +924,7 @@ export class TypeWithAutoClosingCommand extends ReplaceCommandWithOffsetCursorSt
|
||||
let inverseEditOperations = helper.getInverseEditOperations();
|
||||
let range = inverseEditOperations[0].range;
|
||||
this.closeCharacterRange = new Range(range.startLineNumber, range.endColumn - this._closeCharacter.length, range.endLineNumber, range.endColumn);
|
||||
this.enclosingRange = range;
|
||||
this.enclosingRange = new Range(range.startLineNumber, range.endColumn - this._openCharacter.length - this._closeCharacter.length, range.endLineNumber, range.endColumn);
|
||||
return super.computeCursorState(model, helper);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -78,7 +78,9 @@ export interface LanguageConfiguration {
|
||||
*
|
||||
* @deprecated Will be replaced by a better API soon.
|
||||
*/
|
||||
__electricCharacterSupport?: IBracketElectricCharacterContribution;
|
||||
__electricCharacterSupport?: {
|
||||
docComment?: IDocComment;
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -155,10 +157,6 @@ export interface OnEnterRule {
|
||||
action: EnterAction;
|
||||
}
|
||||
|
||||
export interface IBracketElectricCharacterContribution {
|
||||
docComment?: IDocComment;
|
||||
}
|
||||
|
||||
/**
|
||||
* Definition of documentation comments (e.g. Javadoc/JSdoc)
|
||||
*/
|
||||
|
||||
@@ -12,7 +12,7 @@ import { Range } from 'vs/editor/common/core/range';
|
||||
import { ITextModel } from 'vs/editor/common/model';
|
||||
import { DEFAULT_WORD_REGEXP, ensureValidWordDefinition } from 'vs/editor/common/model/wordHelper';
|
||||
import { LanguageId, LanguageIdentifier } from 'vs/editor/common/modes';
|
||||
import { EnterAction, FoldingRules, IAutoClosingPair, IAutoClosingPairConditional, IndentAction, IndentationRule, LanguageConfiguration } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { EnterAction, FoldingRules, IAutoClosingPair, IndentAction, IndentationRule, LanguageConfiguration, StandardAutoClosingPairConditional } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { createScopedLineTokens } from 'vs/editor/common/modes/supports';
|
||||
import { CharacterPairSupport } from 'vs/editor/common/modes/supports/characterPair';
|
||||
import { BracketElectricCharacterSupport, IElectricAction } from 'vs/editor/common/modes/supports/electricCharacter';
|
||||
@@ -97,16 +97,7 @@ export class RichEditSupport {
|
||||
|
||||
public get electricCharacter(): BracketElectricCharacterSupport | null {
|
||||
if (!this._electricCharacter) {
|
||||
let autoClosingPairs: IAutoClosingPairConditional[] = [];
|
||||
if (this._conf.autoClosingPairs) {
|
||||
autoClosingPairs = this._conf.autoClosingPairs;
|
||||
} else if (this._conf.brackets) {
|
||||
autoClosingPairs = this._conf.brackets.map(b => {
|
||||
return { open: b[0], close: b[1] };
|
||||
});
|
||||
}
|
||||
|
||||
this._electricCharacter = new BracketElectricCharacterSupport(this.brackets, autoClosingPairs, this._conf.__electricCharacterSupport);
|
||||
this._electricCharacter = new BracketElectricCharacterSupport(this.brackets);
|
||||
}
|
||||
return this._electricCharacter;
|
||||
}
|
||||
@@ -261,7 +252,7 @@ export class LanguageConfigurationRegistryImpl {
|
||||
return value.characterPair || null;
|
||||
}
|
||||
|
||||
public getAutoClosingPairs(languageId: LanguageId): IAutoClosingPair[] {
|
||||
public getAutoClosingPairs(languageId: LanguageId): StandardAutoClosingPairConditional[] {
|
||||
let characterPairSupport = this._getCharacterPairSupport(languageId);
|
||||
if (!characterPairSupport) {
|
||||
return [];
|
||||
@@ -285,13 +276,9 @@ export class LanguageConfigurationRegistryImpl {
|
||||
return characterPairSupport.getSurroundingPairs();
|
||||
}
|
||||
|
||||
public shouldAutoClosePair(character: string, context: LineTokens, column: number): boolean {
|
||||
let scopedLineTokens = createScopedLineTokens(context, column - 1);
|
||||
let characterPairSupport = this._getCharacterPairSupport(scopedLineTokens.languageId);
|
||||
if (!characterPairSupport) {
|
||||
return false;
|
||||
}
|
||||
return characterPairSupport.shouldAutoClosePair(character, scopedLineTokens, column - scopedLineTokens.firstCharOffset);
|
||||
public shouldAutoClosePair(autoClosingPair: StandardAutoClosingPairConditional, context: LineTokens, column: number): boolean {
|
||||
const scopedLineTokens = createScopedLineTokens(context, column - 1);
|
||||
return CharacterPairSupport.shouldAutoClosePair(autoClosingPair, scopedLineTokens, column - scopedLineTokens.firstCharOffset);
|
||||
}
|
||||
|
||||
// end characterPair
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { CharacterPair, IAutoClosingPair, IAutoClosingPairConditional, StandardAutoClosingPairConditional } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { IAutoClosingPair, StandardAutoClosingPairConditional, LanguageConfiguration } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { ScopedLineTokens } from 'vs/editor/common/modes/supports';
|
||||
|
||||
export class CharacterPairSupport {
|
||||
@@ -15,7 +15,7 @@ export class CharacterPairSupport {
|
||||
private readonly _surroundingPairs: IAutoClosingPair[];
|
||||
private readonly _autoCloseBefore: string;
|
||||
|
||||
constructor(config: { brackets?: CharacterPair[]; autoClosingPairs?: IAutoClosingPairConditional[], surroundingPairs?: IAutoClosingPair[], autoCloseBefore?: string }) {
|
||||
constructor(config: LanguageConfiguration) {
|
||||
if (config.autoClosingPairs) {
|
||||
this._autoClosingPairs = config.autoClosingPairs.map(el => new StandardAutoClosingPairConditional(el));
|
||||
} else if (config.brackets) {
|
||||
@@ -24,12 +24,18 @@ export class CharacterPairSupport {
|
||||
this._autoClosingPairs = [];
|
||||
}
|
||||
|
||||
if (config.__electricCharacterSupport && config.__electricCharacterSupport.docComment) {
|
||||
const docComment = config.__electricCharacterSupport.docComment;
|
||||
// IDocComment is legacy, only partially supported
|
||||
this._autoClosingPairs.push(new StandardAutoClosingPairConditional({ open: docComment.open, close: docComment.close || '' }));
|
||||
}
|
||||
|
||||
this._autoCloseBefore = typeof config.autoCloseBefore === 'string' ? config.autoCloseBefore : CharacterPairSupport.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED;
|
||||
|
||||
this._surroundingPairs = config.surroundingPairs || this._autoClosingPairs;
|
||||
}
|
||||
|
||||
public getAutoClosingPairs(): IAutoClosingPair[] {
|
||||
public getAutoClosingPairs(): StandardAutoClosingPairConditional[] {
|
||||
return this._autoClosingPairs;
|
||||
}
|
||||
|
||||
@@ -37,22 +43,15 @@ export class CharacterPairSupport {
|
||||
return this._autoCloseBefore;
|
||||
}
|
||||
|
||||
public shouldAutoClosePair(character: string, context: ScopedLineTokens, column: number): boolean {
|
||||
public static shouldAutoClosePair(autoClosingPair: StandardAutoClosingPairConditional, context: ScopedLineTokens, column: number): boolean {
|
||||
// Always complete on empty line
|
||||
if (context.getTokenCount() === 0) {
|
||||
return true;
|
||||
}
|
||||
|
||||
let tokenIndex = context.findTokenIndexAtOffset(column - 2);
|
||||
let standardTokenType = context.getStandardTokenType(tokenIndex);
|
||||
|
||||
for (const autoClosingPair of this._autoClosingPairs) {
|
||||
if (autoClosingPair.open === character) {
|
||||
return autoClosingPair.isOK(standardTokenType);
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
const tokenIndex = context.findTokenIndexAtOffset(column - 2);
|
||||
const standardTokenType = context.getStandardTokenType(tokenIndex);
|
||||
return autoClosingPair.isOK(standardTokenType);
|
||||
}
|
||||
|
||||
public getSurroundingPairs(): IAutoClosingPair[] {
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { IAutoClosingPairConditional, IBracketElectricCharacterContribution, StandardAutoClosingPairConditional } from 'vs/editor/common/modes/languageConfiguration';
|
||||
import { ScopedLineTokens, ignoreBracketsInToken } from 'vs/editor/common/modes/supports';
|
||||
import { BracketsUtils, RichEditBrackets } from 'vs/editor/common/modes/supports/richEditBrackets';
|
||||
|
||||
@@ -12,29 +11,17 @@ import { BracketsUtils, RichEditBrackets } from 'vs/editor/common/modes/supports
|
||||
* @internal
|
||||
*/
|
||||
export interface IElectricAction {
|
||||
// Only one of the following properties should be defined:
|
||||
|
||||
// The line will be indented at the same level of the line
|
||||
// which contains the matching given bracket type.
|
||||
matchOpenBracket?: string;
|
||||
|
||||
// The text will be appended after the electric character.
|
||||
appendText?: string;
|
||||
matchOpenBracket: string;
|
||||
}
|
||||
|
||||
export class BracketElectricCharacterSupport {
|
||||
|
||||
private readonly _richEditBrackets: RichEditBrackets | null;
|
||||
private readonly _complexAutoClosePairs: StandardAutoClosingPairConditional[];
|
||||
|
||||
constructor(richEditBrackets: RichEditBrackets | null, autoClosePairs: IAutoClosingPairConditional[], contribution: IBracketElectricCharacterContribution | null | undefined) {
|
||||
contribution = contribution || {};
|
||||
constructor(richEditBrackets: RichEditBrackets | null) {
|
||||
this._richEditBrackets = richEditBrackets;
|
||||
this._complexAutoClosePairs = autoClosePairs.filter(pair => pair.open.length > 1 && !!pair.close).map(el => new StandardAutoClosingPairConditional(el));
|
||||
if (contribution.docComment) {
|
||||
// IDocComment is legacy, only partially supported
|
||||
this._complexAutoClosePairs.push(new StandardAutoClosingPairConditional({ open: contribution.docComment.open, close: contribution.docComment.close || '' }));
|
||||
}
|
||||
}
|
||||
|
||||
public getElectricCharacters(): string[] {
|
||||
@@ -48,11 +35,6 @@ export class BracketElectricCharacterSupport {
|
||||
}
|
||||
}
|
||||
|
||||
// auto close
|
||||
for (let pair of this._complexAutoClosePairs) {
|
||||
result.push(pair.open.charAt(pair.open.length - 1));
|
||||
}
|
||||
|
||||
// Filter duplicate entries
|
||||
result = result.filter((item, pos, array) => {
|
||||
return array.indexOf(item) === pos;
|
||||
@@ -62,12 +44,6 @@ export class BracketElectricCharacterSupport {
|
||||
}
|
||||
|
||||
public onElectricCharacter(character: string, context: ScopedLineTokens, column: number): IElectricAction | null {
|
||||
return (this._onElectricAutoClose(character, context, column) ||
|
||||
this._onElectricAutoIndent(character, context, column));
|
||||
}
|
||||
|
||||
private _onElectricAutoIndent(character: string, context: ScopedLineTokens, column: number): IElectricAction | null {
|
||||
|
||||
if (!this._richEditBrackets || this._richEditBrackets.brackets.length === 0) {
|
||||
return null;
|
||||
}
|
||||
@@ -103,44 +79,4 @@ export class BracketElectricCharacterSupport {
|
||||
matchOpenBracket: bracketText
|
||||
};
|
||||
}
|
||||
|
||||
private _onElectricAutoClose(character: string, context: ScopedLineTokens, column: number): IElectricAction | null {
|
||||
if (!this._complexAutoClosePairs.length) {
|
||||
return null;
|
||||
}
|
||||
|
||||
let line = context.getLineContent();
|
||||
|
||||
for (let i = 0, len = this._complexAutoClosePairs.length; i < len; i++) {
|
||||
let pair = this._complexAutoClosePairs[i];
|
||||
|
||||
// See if the right electric character was pressed
|
||||
if (character !== pair.open.charAt(pair.open.length - 1)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// check if the full open bracket matches
|
||||
let start = column - pair.open.length + 1;
|
||||
let actual = line.substring(start - 1, column - 1) + character;
|
||||
if (actual !== pair.open) {
|
||||
continue;
|
||||
}
|
||||
|
||||
let lastTokenIndex = context.findTokenIndexAtOffset(column - 1);
|
||||
let lastTokenStandardType = context.getStandardTokenType(lastTokenIndex);
|
||||
// If we're in a scope listed in 'notIn', do nothing
|
||||
if (!pair.isOK(lastTokenStandardType)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// If this line already contains the closing tag, do nothing.
|
||||
if (line.indexOf(pair.close, column - 1) >= 0) {
|
||||
continue;
|
||||
}
|
||||
|
||||
return { appendText: pair.close };
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -202,16 +202,33 @@ export class OutlineGroup extends TreeElement {
|
||||
}
|
||||
}
|
||||
|
||||
class MovingAverage {
|
||||
|
||||
private _n = 1;
|
||||
private _val = 0;
|
||||
|
||||
update(value: number): this {
|
||||
this._val = this._val + (value - this._val) / this._n;
|
||||
this._n += 1;
|
||||
return this;
|
||||
}
|
||||
|
||||
get value(): number {
|
||||
return this._val;
|
||||
}
|
||||
}
|
||||
|
||||
export class OutlineModel extends TreeElement {
|
||||
|
||||
private static readonly _requestDurations = new LRUCache<string, MovingAverage>(50, 0.7);
|
||||
private static readonly _requests = new LRUCache<string, { promiseCnt: number, source: CancellationTokenSource, promise: Promise<any>, model: OutlineModel | undefined }>(9, 0.75);
|
||||
private static readonly _keys = new class {
|
||||
|
||||
private _counter = 1;
|
||||
private _data = new WeakMap<DocumentSymbolProvider, number>();
|
||||
|
||||
for(textModel: ITextModel): string {
|
||||
return `${textModel.id}/${textModel.getVersionId()}/${this._hash(DocumentSymbolProviderRegistry.all(textModel))}`;
|
||||
for(textModel: ITextModel, version: boolean): string {
|
||||
return `${textModel.id}/${version ? textModel.getVersionId() : ''}/${this._hash(DocumentSymbolProviderRegistry.all(textModel))}`;
|
||||
}
|
||||
|
||||
private _hash(providers: DocumentSymbolProvider[]): string {
|
||||
@@ -231,7 +248,7 @@ export class OutlineModel extends TreeElement {
|
||||
|
||||
static create(textModel: ITextModel, token: CancellationToken): Promise<OutlineModel> {
|
||||
|
||||
let key = this._keys.for(textModel);
|
||||
let key = this._keys.for(textModel, true);
|
||||
let data = OutlineModel._requests.get(key);
|
||||
|
||||
if (!data) {
|
||||
@@ -243,6 +260,18 @@ export class OutlineModel extends TreeElement {
|
||||
model: undefined,
|
||||
};
|
||||
OutlineModel._requests.set(key, data);
|
||||
|
||||
// keep moving average of request durations
|
||||
const now = Date.now();
|
||||
data.promise.then(() => {
|
||||
let key = this._keys.for(textModel, false);
|
||||
let avg = this._requestDurations.get(key);
|
||||
if (!avg) {
|
||||
avg = new MovingAverage();
|
||||
this._requestDurations.set(key, avg);
|
||||
}
|
||||
avg.update(Date.now() - now);
|
||||
});
|
||||
}
|
||||
|
||||
if (data!.model) {
|
||||
@@ -272,7 +301,18 @@ export class OutlineModel extends TreeElement {
|
||||
});
|
||||
}
|
||||
|
||||
static _create(textModel: ITextModel, token: CancellationToken): Promise<OutlineModel> {
|
||||
static getRequestDelay(textModel: ITextModel | null): number {
|
||||
if (!textModel) {
|
||||
return 350;
|
||||
}
|
||||
const avg = this._requestDurations.get(this._keys.for(textModel, false));
|
||||
if (!avg) {
|
||||
return 350;
|
||||
}
|
||||
return Math.max(350, Math.floor(1.3 * avg.value));
|
||||
}
|
||||
|
||||
private static _create(textModel: ITextModel, token: CancellationToken): Promise<OutlineModel> {
|
||||
|
||||
const cts = new CancellationTokenSource(token);
|
||||
const result = new OutlineModel(textModel);
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { CharCode } from 'vs/base/common/charCode';
|
||||
import { containsUppercaseCharacter } from 'vs/base/common/strings';
|
||||
import { buildReplaceStringWithCasePreserved } from 'vs/base/common/search';
|
||||
|
||||
const enum ReplacePatternKind {
|
||||
StaticValue = 0,
|
||||
@@ -51,17 +51,8 @@ export class ReplacePattern {
|
||||
|
||||
public buildReplaceString(matches: string[] | null, preserveCase?: boolean): string {
|
||||
if (this._state.kind === ReplacePatternKind.StaticValue) {
|
||||
if (preserveCase && matches && (matches[0] !== '')) {
|
||||
if (matches[0].toUpperCase() === matches[0]) {
|
||||
return this._state.staticValue.toUpperCase();
|
||||
} else if (matches[0].toLowerCase() === matches[0]) {
|
||||
return this._state.staticValue.toLowerCase();
|
||||
} else if (containsUppercaseCharacter(matches[0][0])) {
|
||||
return this._state.staticValue[0].toUpperCase() + this._state.staticValue.substr(1);
|
||||
} else {
|
||||
// we don't understand its pattern yet.
|
||||
return this._state.staticValue;
|
||||
}
|
||||
if (preserveCase) {
|
||||
return buildReplaceStringWithCasePreserved(matches, this._state.staticValue);
|
||||
} else {
|
||||
return this._state.staticValue;
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
import * as assert from 'assert';
|
||||
import { ReplacePattern, ReplacePiece, parseReplaceString } from 'vs/editor/contrib/find/replacePattern';
|
||||
import { buildReplaceStringWithCasePreserved } from 'vs/base/common/search';
|
||||
|
||||
suite('Replace Pattern test', () => {
|
||||
|
||||
@@ -154,6 +155,29 @@ suite('Replace Pattern test', () => {
|
||||
assert.equal(actual, 'a{}');
|
||||
});
|
||||
|
||||
test('buildReplaceStringWithCasePreserved test', () => {
|
||||
let replacePattern = 'Def';
|
||||
let actual: string | string[] = 'abc';
|
||||
|
||||
assert.equal(buildReplaceStringWithCasePreserved([actual], replacePattern), 'def');
|
||||
actual = 'Abc';
|
||||
assert.equal(buildReplaceStringWithCasePreserved([actual], replacePattern), 'Def');
|
||||
actual = 'ABC';
|
||||
assert.equal(buildReplaceStringWithCasePreserved([actual], replacePattern), 'DEF');
|
||||
|
||||
actual = ['abc', 'Abc'];
|
||||
assert.equal(buildReplaceStringWithCasePreserved(actual, replacePattern), 'def');
|
||||
actual = ['Abc', 'abc'];
|
||||
assert.equal(buildReplaceStringWithCasePreserved(actual, replacePattern), 'Def');
|
||||
actual = ['ABC', 'abc'];
|
||||
assert.equal(buildReplaceStringWithCasePreserved(actual, replacePattern), 'DEF');
|
||||
|
||||
actual = ['AbC'];
|
||||
assert.equal(buildReplaceStringWithCasePreserved(actual, replacePattern), 'Def');
|
||||
actual = ['aBC'];
|
||||
assert.equal(buildReplaceStringWithCasePreserved(actual, replacePattern), 'Def');
|
||||
});
|
||||
|
||||
test('preserve case', () => {
|
||||
let replacePattern = parseReplaceString('Def');
|
||||
let actual = replacePattern.buildReplaceString(['abc'], true);
|
||||
|
||||
@@ -105,7 +105,11 @@ export class RangesCollector {
|
||||
}
|
||||
|
||||
|
||||
interface PreviousRegion { indent: number; line: number; marker: boolean; }
|
||||
interface PreviousRegion {
|
||||
indent: number; // indent or -2 if a marker
|
||||
endAbove: number; // end line number for the region above
|
||||
line: number; // start line of the region. Only used for marker regions.
|
||||
}
|
||||
|
||||
export function computeRanges(model: ITextModel, offSide: boolean, markers?: FoldingMarkers, foldingRangesLimit = MAX_FOLDING_REGIONS_FOR_INDENT_LIMIT): FoldingRegions {
|
||||
const tabSize = model.getOptions().tabSize;
|
||||
@@ -117,16 +121,19 @@ export function computeRanges(model: ITextModel, offSide: boolean, markers?: Fol
|
||||
}
|
||||
|
||||
let previousRegions: PreviousRegion[] = [];
|
||||
previousRegions.push({ indent: -1, line: model.getLineCount() + 1, marker: false }); // sentinel, to make sure there's at least one entry
|
||||
let line = model.getLineCount() + 1;
|
||||
previousRegions.push({ indent: -1, endAbove: line, line }); // sentinel, to make sure there's at least one entry
|
||||
|
||||
for (let line = model.getLineCount(); line > 0; line--) {
|
||||
let lineContent = model.getLineContent(line);
|
||||
let indent = TextModel.computeIndentLevel(lineContent, tabSize);
|
||||
let previous = previousRegions[previousRegions.length - 1];
|
||||
if (indent === -1) {
|
||||
if (offSide && !previous.marker) {
|
||||
// for offSide languages, empty lines are associated to the next block
|
||||
previous.line = line;
|
||||
if (offSide) {
|
||||
// for offSide languages, empty lines are associated to the previous block
|
||||
// note: the next block is already written to the results, so this only
|
||||
// impacts the end position of the block before
|
||||
previous.endAbove = line;
|
||||
}
|
||||
continue; // only whitespace
|
||||
}
|
||||
@@ -136,7 +143,7 @@ export function computeRanges(model: ITextModel, offSide: boolean, markers?: Fol
|
||||
if (m[1]) { // start pattern match
|
||||
// discard all regions until the folding pattern
|
||||
let i = previousRegions.length - 1;
|
||||
while (i > 0 && !previousRegions[i].marker) {
|
||||
while (i > 0 && previousRegions[i].indent !== -2) {
|
||||
i--;
|
||||
}
|
||||
if (i > 0) {
|
||||
@@ -145,15 +152,15 @@ export function computeRanges(model: ITextModel, offSide: boolean, markers?: Fol
|
||||
|
||||
// new folding range from pattern, includes the end line
|
||||
result.insertFirst(line, previous.line, indent);
|
||||
previous.marker = false;
|
||||
previous.indent = indent;
|
||||
previous.line = line;
|
||||
previous.indent = indent;
|
||||
previous.endAbove = line;
|
||||
continue;
|
||||
} else {
|
||||
// no end marker found, treat line as a regular line
|
||||
}
|
||||
} else { // end pattern match
|
||||
previousRegions.push({ indent: -2, line, marker: true });
|
||||
previousRegions.push({ indent: -2, endAbove: line, line });
|
||||
continue;
|
||||
}
|
||||
}
|
||||
@@ -165,16 +172,16 @@ export function computeRanges(model: ITextModel, offSide: boolean, markers?: Fol
|
||||
} while (previous.indent > indent);
|
||||
|
||||
// new folding range
|
||||
let endLineNumber = previous.line - 1;
|
||||
let endLineNumber = previous.endAbove - 1;
|
||||
if (endLineNumber - line >= 1) { // needs at east size 1
|
||||
result.insertFirst(line, endLineNumber, indent);
|
||||
}
|
||||
}
|
||||
if (previous.indent === indent) {
|
||||
previous.line = line;
|
||||
previous.endAbove = line;
|
||||
} else { // previous.indent < indent
|
||||
// new region with a bigger indent
|
||||
previousRegions.push({ indent, line, marker: false });
|
||||
previousRegions.push({ indent, endAbove: line, line });
|
||||
}
|
||||
}
|
||||
return result.toIndentRanges(model);
|
||||
|
||||
@@ -316,5 +316,17 @@ suite('Folding with regions', () => {
|
||||
/* 8*/ '#endregionff',
|
||||
], [], true, markers);
|
||||
});
|
||||
|
||||
test('Issue 79359', () => {
|
||||
assertRanges([
|
||||
/* 1*/ '#region',
|
||||
/* 2*/ '',
|
||||
/* 3*/ 'class A',
|
||||
/* 4*/ ' foo',
|
||||
/* 5*/ '',
|
||||
/* 6*/ 'class A',
|
||||
/* 7*/ ' foo',
|
||||
/* 8*/ '',
|
||||
/* 9*/ '#endregion',
|
||||
], [r(1, 9, -1, true), r(3, 4, 0), r(6, 7, 0)], true, markers);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -38,6 +38,9 @@ import { INotificationService } from 'vs/platform/notification/common/notificati
|
||||
import { IOpenerService } from 'vs/platform/opener/common/opener';
|
||||
import { IAccessibilityService } from 'vs/platform/accessibility/common/accessibility';
|
||||
import { clearAllFontInfos } from 'vs/editor/browser/config/configuration';
|
||||
import { IDialogService } from 'vs/platform/dialogs/common/dialogs';
|
||||
import { IProductService } from 'vs/platform/product/common/product';
|
||||
import { IStorageService } from 'vs/platform/storage/common/storage';
|
||||
|
||||
type Omit<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
|
||||
|
||||
@@ -51,7 +54,13 @@ function withAllStandaloneServices<T extends editorCommon.IEditor>(domElement: H
|
||||
}
|
||||
|
||||
if (!services.has(IOpenerService)) {
|
||||
services.set(IOpenerService, new OpenerService(services.get(ICodeEditorService), services.get(ICommandService)));
|
||||
services.set(IOpenerService, new OpenerService(
|
||||
services.get(ICodeEditorService),
|
||||
services.get(ICommandService),
|
||||
services.get(IStorageService),
|
||||
services.get(IDialogService),
|
||||
services.get(IProductService)
|
||||
));
|
||||
}
|
||||
|
||||
let result = callback(services);
|
||||
|
||||
@@ -27,11 +27,9 @@ function isArrayOf(elemType: (x: any) => boolean, obj: any): boolean {
|
||||
if (!(Array.isArray(obj))) {
|
||||
return false;
|
||||
}
|
||||
for (let idx in obj) {
|
||||
if (obj.hasOwnProperty(idx)) {
|
||||
if (!(elemType(obj[idx]))) {
|
||||
return false;
|
||||
}
|
||||
for (const el of obj) {
|
||||
if (!(elemType(el))) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
@@ -298,10 +296,8 @@ function compileAction(lexer: monarchCommon.ILexerMin, ruleName: string, action:
|
||||
}
|
||||
else if (Array.isArray(action)) {
|
||||
let results: monarchCommon.FuzzyAction[] = [];
|
||||
for (let idx in action) {
|
||||
if (action.hasOwnProperty(idx)) {
|
||||
results[idx] = compileAction(lexer, ruleName, action[idx]);
|
||||
}
|
||||
for (let i = 0, len = action.length; i < len; i++) {
|
||||
results[i] = compileAction(lexer, ruleName, action[i]);
|
||||
}
|
||||
return { group: results };
|
||||
}
|
||||
@@ -331,13 +327,10 @@ function compileAction(lexer: monarchCommon.ILexerMin, ruleName: string, action:
|
||||
const def = lexer.defaultToken;
|
||||
return {
|
||||
test: function (id, matches, state, eos) {
|
||||
for (let idx in cases) {
|
||||
if (cases.hasOwnProperty(idx)) {
|
||||
const _case = cases[idx];
|
||||
const didmatch = (!_case.test || _case.test(id, matches, state, eos));
|
||||
if (didmatch) {
|
||||
return _case.value;
|
||||
}
|
||||
for (const _case of cases) {
|
||||
const didmatch = (!_case.test || _case.test(id, matches, state, eos));
|
||||
if (didmatch) {
|
||||
return _case.value;
|
||||
}
|
||||
}
|
||||
return def;
|
||||
@@ -425,64 +418,61 @@ export function compile(languageId: string, json: IMonarchLanguage): monarchComm
|
||||
|
||||
// Compile an array of rules into newrules where RegExp objects are created.
|
||||
function addRules(state: string, newrules: monarchCommon.IRule[], rules: any[]) {
|
||||
for (let idx in rules) {
|
||||
if (rules.hasOwnProperty(idx)) {
|
||||
const rule = rules[idx];
|
||||
let include = rule.include;
|
||||
if (include) {
|
||||
if (typeof (include) !== 'string') {
|
||||
throw monarchCommon.createError(lexer, 'an \'include\' attribute must be a string at: ' + state);
|
||||
}
|
||||
if (include[0] === '@') {
|
||||
include = include.substr(1); // peel off starting @
|
||||
}
|
||||
if (!json.tokenizer[include]) {
|
||||
throw monarchCommon.createError(lexer, 'include target \'' + include + '\' is not defined at: ' + state);
|
||||
}
|
||||
addRules(state + '.' + include, newrules, json.tokenizer[include]);
|
||||
for (const rule of rules) {
|
||||
|
||||
let include = rule.include;
|
||||
if (include) {
|
||||
if (typeof (include) !== 'string') {
|
||||
throw monarchCommon.createError(lexer, 'an \'include\' attribute must be a string at: ' + state);
|
||||
}
|
||||
else {
|
||||
const newrule = new Rule(state);
|
||||
if (include[0] === '@') {
|
||||
include = include.substr(1); // peel off starting @
|
||||
}
|
||||
if (!json.tokenizer[include]) {
|
||||
throw monarchCommon.createError(lexer, 'include target \'' + include + '\' is not defined at: ' + state);
|
||||
}
|
||||
addRules(state + '.' + include, newrules, json.tokenizer[include]);
|
||||
}
|
||||
else {
|
||||
const newrule = new Rule(state);
|
||||
|
||||
|
||||
// Set up new rule attributes
|
||||
if (Array.isArray(rule) && rule.length >= 1 && rule.length <= 3) {
|
||||
newrule.setRegex(lexerMin, rule[0]);
|
||||
if (rule.length >= 3) {
|
||||
if (typeof (rule[1]) === 'string') {
|
||||
newrule.setAction(lexerMin, { token: rule[1], next: rule[2] });
|
||||
}
|
||||
else if (typeof (rule[1]) === 'object') {
|
||||
const rule1 = rule[1];
|
||||
rule1.next = rule[2];
|
||||
newrule.setAction(lexerMin, rule1);
|
||||
}
|
||||
else {
|
||||
throw monarchCommon.createError(lexer, 'a next state as the last element of a rule can only be given if the action is either an object or a string, at: ' + state);
|
||||
}
|
||||
// Set up new rule attributes
|
||||
if (Array.isArray(rule) && rule.length >= 1 && rule.length <= 3) {
|
||||
newrule.setRegex(lexerMin, rule[0]);
|
||||
if (rule.length >= 3) {
|
||||
if (typeof (rule[1]) === 'string') {
|
||||
newrule.setAction(lexerMin, { token: rule[1], next: rule[2] });
|
||||
}
|
||||
else if (typeof (rule[1]) === 'object') {
|
||||
const rule1 = rule[1];
|
||||
rule1.next = rule[2];
|
||||
newrule.setAction(lexerMin, rule1);
|
||||
}
|
||||
else {
|
||||
newrule.setAction(lexerMin, rule[1]);
|
||||
throw monarchCommon.createError(lexer, 'a next state as the last element of a rule can only be given if the action is either an object or a string, at: ' + state);
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (!rule.regex) {
|
||||
throw monarchCommon.createError(lexer, 'a rule must either be an array, or an object with a \'regex\' or \'include\' field at: ' + state);
|
||||
}
|
||||
if (rule.name) {
|
||||
if (typeof rule.name === 'string') {
|
||||
newrule.name = rule.name;
|
||||
}
|
||||
}
|
||||
if (rule.matchOnlyAtStart) {
|
||||
newrule.matchOnlyAtLineStart = bool(rule.matchOnlyAtLineStart, false);
|
||||
}
|
||||
newrule.setRegex(lexerMin, rule.regex);
|
||||
newrule.setAction(lexerMin, rule.action);
|
||||
newrule.setAction(lexerMin, rule[1]);
|
||||
}
|
||||
|
||||
newrules.push(newrule);
|
||||
}
|
||||
else {
|
||||
if (!rule.regex) {
|
||||
throw monarchCommon.createError(lexer, 'a rule must either be an array, or an object with a \'regex\' or \'include\' field at: ' + state);
|
||||
}
|
||||
if (rule.name) {
|
||||
if (typeof rule.name === 'string') {
|
||||
newrule.name = rule.name;
|
||||
}
|
||||
}
|
||||
if (rule.matchOnlyAtStart) {
|
||||
newrule.matchOnlyAtLineStart = bool(rule.matchOnlyAtLineStart, false);
|
||||
}
|
||||
newrule.setRegex(lexerMin, rule.regex);
|
||||
newrule.setAction(lexerMin, rule.action);
|
||||
}
|
||||
|
||||
newrules.push(newrule);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -520,26 +510,24 @@ export function compile(languageId: string, json: IMonarchLanguage): monarchComm
|
||||
{ open: '<', close: '>', token: 'delimiter.angle' }];
|
||||
}
|
||||
let brackets: IMonarchLanguageBracket[] = [];
|
||||
for (let bracketIdx in json.brackets) {
|
||||
if (json.brackets.hasOwnProperty(bracketIdx)) {
|
||||
let desc = <any>json.brackets[bracketIdx];
|
||||
if (desc && Array.isArray(desc) && desc.length === 3) {
|
||||
desc = { token: desc[2], open: desc[0], close: desc[1] };
|
||||
}
|
||||
if (desc.open === desc.close) {
|
||||
throw monarchCommon.createError(lexer, 'open and close brackets in a \'brackets\' attribute must be different: ' + desc.open +
|
||||
'\n hint: use the \'bracket\' attribute if matching on equal brackets is required.');
|
||||
}
|
||||
if (typeof desc.open === 'string' && typeof desc.token === 'string' && typeof desc.close === 'string') {
|
||||
brackets.push({
|
||||
token: desc.token + lexer.tokenPostfix,
|
||||
open: monarchCommon.fixCase(lexer, desc.open),
|
||||
close: monarchCommon.fixCase(lexer, desc.close)
|
||||
});
|
||||
}
|
||||
else {
|
||||
throw monarchCommon.createError(lexer, 'every element in the \'brackets\' array must be a \'{open,close,token}\' object or array');
|
||||
}
|
||||
for (let el of json.brackets) {
|
||||
let desc: any = el;
|
||||
if (desc && Array.isArray(desc) && desc.length === 3) {
|
||||
desc = { token: desc[2], open: desc[0], close: desc[1] };
|
||||
}
|
||||
if (desc.open === desc.close) {
|
||||
throw monarchCommon.createError(lexer, 'open and close brackets in a \'brackets\' attribute must be different: ' + desc.open +
|
||||
'\n hint: use the \'bracket\' attribute if matching on equal brackets is required.');
|
||||
}
|
||||
if (typeof desc.open === 'string' && typeof desc.token === 'string' && typeof desc.close === 'string') {
|
||||
brackets.push({
|
||||
token: desc.token + lexer.tokenPostfix,
|
||||
open: monarchCommon.fixCase(lexer, desc.open),
|
||||
close: monarchCommon.fixCase(lexer, desc.close)
|
||||
});
|
||||
}
|
||||
else {
|
||||
throw monarchCommon.createError(lexer, 'every element in the \'brackets\' array must be a \'{open,close,token}\' object or array');
|
||||
}
|
||||
}
|
||||
lexer.brackets = brackets;
|
||||
|
||||
@@ -228,8 +228,6 @@ class MonarchLineState implements modes.IState {
|
||||
}
|
||||
}
|
||||
|
||||
const hasOwnProperty = Object.hasOwnProperty;
|
||||
|
||||
interface IMonarchTokensCollector {
|
||||
enterMode(startOffset: number, modeId: string): void;
|
||||
emit(startOffset: number, type: string): void;
|
||||
@@ -423,22 +421,24 @@ export class MonarchTokenizer implements modes.ITokenizationSupport {
|
||||
public getLoadStatus(): ILoadStatus {
|
||||
let promises: Thenable<any>[] = [];
|
||||
for (let nestedModeId in this._embeddedModes) {
|
||||
const tokenizationSupport = modes.TokenizationRegistry.get(nestedModeId);
|
||||
if (tokenizationSupport) {
|
||||
// The nested mode is already loaded
|
||||
if (tokenizationSupport instanceof MonarchTokenizer) {
|
||||
const nestedModeStatus = tokenizationSupport.getLoadStatus();
|
||||
if (nestedModeStatus.loaded === false) {
|
||||
promises.push(nestedModeStatus.promise);
|
||||
if (this._embeddedModes.hasOwnProperty(nestedModeId)) {
|
||||
const tokenizationSupport = modes.TokenizationRegistry.get(nestedModeId);
|
||||
if (tokenizationSupport) {
|
||||
// The nested mode is already loaded
|
||||
if (tokenizationSupport instanceof MonarchTokenizer) {
|
||||
const nestedModeStatus = tokenizationSupport.getLoadStatus();
|
||||
if (nestedModeStatus.loaded === false) {
|
||||
promises.push(nestedModeStatus.promise);
|
||||
}
|
||||
}
|
||||
continue;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
const tokenizationSupportPromise = modes.TokenizationRegistry.getPromise(nestedModeId);
|
||||
if (tokenizationSupportPromise) {
|
||||
// The nested mode is in the process of being loaded
|
||||
promises.push(tokenizationSupportPromise);
|
||||
const tokenizationSupportPromise = modes.TokenizationRegistry.getPromise(nestedModeId);
|
||||
if (tokenizationSupportPromise) {
|
||||
// The nested mode is in the process of being loaded
|
||||
promises.push(tokenizationSupportPromise);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -490,11 +490,7 @@ export class MonarchTokenizer implements modes.ITokenizationSupport {
|
||||
let popOffset = -1;
|
||||
let hasEmbeddedPopRule = false;
|
||||
|
||||
for (let idx in rules) {
|
||||
if (!hasOwnProperty.call(rules, idx)) {
|
||||
continue;
|
||||
}
|
||||
let rule: monarchCommon.IRule = rules[idx];
|
||||
for (const rule of rules) {
|
||||
if (!monarchCommon.isIAction(rule.action) || rule.action.nextEmbedded !== '@pop') {
|
||||
continue;
|
||||
}
|
||||
@@ -619,16 +615,13 @@ export class MonarchTokenizer implements modes.ITokenizationSupport {
|
||||
|
||||
// try each rule until we match
|
||||
let restOfLine = line.substr(pos);
|
||||
for (let idx in rules) {
|
||||
if (hasOwnProperty.call(rules, idx)) {
|
||||
let rule: monarchCommon.IRule = rules[idx];
|
||||
if (pos === 0 || !rule.matchOnlyAtLineStart) {
|
||||
matches = restOfLine.match(rule.regex);
|
||||
if (matches) {
|
||||
matched = matches[0];
|
||||
action = rule.action;
|
||||
break;
|
||||
}
|
||||
for (const rule of rules) {
|
||||
if (pos === 0 || !rule.matchOnlyAtLineStart) {
|
||||
matches = restOfLine.match(rule.regex);
|
||||
if (matches) {
|
||||
matched = matches[0];
|
||||
action = rule.action;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3998,8 +3998,12 @@ suite('autoClosingPairs', () => {
|
||||
{ open: '\'', close: '\'', notIn: ['string', 'comment'] },
|
||||
{ open: '\"', close: '\"', notIn: ['string'] },
|
||||
{ open: '`', close: '`', notIn: ['string', 'comment'] },
|
||||
{ open: '/**', close: ' */', notIn: ['string'] }
|
||||
{ open: '/**', close: ' */', notIn: ['string'] },
|
||||
{ open: 'begin', close: 'end', notIn: ['string'] }
|
||||
],
|
||||
__electricCharacterSupport: {
|
||||
docComment: { open: '/**', close: ' */' }
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
@@ -4439,6 +4443,28 @@ suite('autoClosingPairs', () => {
|
||||
mode.dispose();
|
||||
});
|
||||
|
||||
test('multi-character autoclose', () => {
|
||||
let mode = new AutoClosingMode();
|
||||
usingCursor({
|
||||
text: [
|
||||
'',
|
||||
],
|
||||
languageIdentifier: mode.getLanguageIdentifier()
|
||||
}, (model, cursor) => {
|
||||
|
||||
model.setValue('begi');
|
||||
cursor.setSelections('test', [new Selection(1, 5, 1, 5)]);
|
||||
cursorCommand(cursor, H.Type, { text: 'n' }, 'keyboard');
|
||||
assert.strictEqual(model.getLineContent(1), 'beginend');
|
||||
|
||||
model.setValue('/*');
|
||||
cursor.setSelections('test', [new Selection(1, 3, 1, 3)]);
|
||||
cursorCommand(cursor, H.Type, { text: '*' }, 'keyboard');
|
||||
assert.strictEqual(model.getLineContent(1), '/** */');
|
||||
});
|
||||
mode.dispose();
|
||||
});
|
||||
|
||||
test('issue #55314: Do not auto-close when ending with open', () => {
|
||||
const languageId = new LanguageIdentifier('myElectricMode', 5);
|
||||
class ElectricMode extends MockMode {
|
||||
@@ -4477,7 +4503,7 @@ suite('autoClosingPairs', () => {
|
||||
model.forceTokenization(model.getLineCount());
|
||||
assertType(model, cursor, 3, 4, '"', '"', `does not double quote when ending with open`);
|
||||
model.forceTokenization(model.getLineCount());
|
||||
assertType(model, cursor, 4, 2, '"', '""', `double quote when ending with open`);
|
||||
assertType(model, cursor, 4, 2, '"', '"', `does not double quote when ending with open`);
|
||||
model.forceTokenization(model.getLineCount());
|
||||
assertType(model, cursor, 4, 3, '"', '"', `does not double quote when ending with open`);
|
||||
});
|
||||
@@ -4772,31 +4798,18 @@ suite('autoClosingPairs', () => {
|
||||
|
||||
// on the mac US intl kb layout
|
||||
|
||||
// Typing ` + space
|
||||
// Typing ' + space
|
||||
cursorCommand(cursor, H.CompositionStart, null, 'keyboard');
|
||||
cursorCommand(cursor, H.Type, { text: '\'' }, 'keyboard');
|
||||
cursorCommand(cursor, H.ReplacePreviousChar, { replaceCharCnt: 1, text: '\'' }, 'keyboard');
|
||||
cursorCommand(cursor, H.CompositionEnd, null, 'keyboard');
|
||||
|
||||
assert.equal(model.getValue(), '\'\'');
|
||||
|
||||
// Typing " + space within string
|
||||
cursor.setSelections('test', [new Selection(1, 2, 1, 2)]);
|
||||
cursorCommand(cursor, H.CompositionStart, null, 'keyboard');
|
||||
cursorCommand(cursor, H.Type, { text: '"' }, 'keyboard');
|
||||
cursorCommand(cursor, H.ReplacePreviousChar, { replaceCharCnt: 1, text: '"' }, 'keyboard');
|
||||
cursorCommand(cursor, H.CompositionEnd, null, 'keyboard');
|
||||
|
||||
assert.equal(model.getValue(), '\'"\'');
|
||||
|
||||
// Typing ' + space after '
|
||||
model.setValue('\'');
|
||||
cursor.setSelections('test', [new Selection(1, 2, 1, 2)]);
|
||||
// Typing one more ' + space
|
||||
cursorCommand(cursor, H.CompositionStart, null, 'keyboard');
|
||||
cursorCommand(cursor, H.Type, { text: '\'' }, 'keyboard');
|
||||
cursorCommand(cursor, H.ReplacePreviousChar, { replaceCharCnt: 1, text: '\'' }, 'keyboard');
|
||||
cursorCommand(cursor, H.CompositionEnd, null, 'keyboard');
|
||||
|
||||
assert.equal(model.getValue(), '\'\'');
|
||||
|
||||
// Typing ' as a closing tag
|
||||
|
||||
@@ -7,6 +7,10 @@ import { URI } from 'vs/base/common/uri';
|
||||
import { OpenerService } from 'vs/editor/browser/services/openerService';
|
||||
import { TestCodeEditorService } from 'vs/editor/test/browser/editorTestServices';
|
||||
import { CommandsRegistry, ICommandService, NullCommandService } from 'vs/platform/commands/common/commands';
|
||||
import { deepClone } from 'vs/base/common/objects';
|
||||
import { IDialogService } from 'vs/platform/dialogs/common/dialogs';
|
||||
import { IProductService } from 'vs/platform/product/common/product';
|
||||
import { IStorageService } from 'vs/platform/storage/common/storage';
|
||||
|
||||
suite('OpenerService', function () {
|
||||
|
||||
@@ -24,19 +28,77 @@ suite('OpenerService', function () {
|
||||
}
|
||||
};
|
||||
|
||||
function getStorageService(trustedDomainsSetting: string[]) {
|
||||
let _settings = deepClone(trustedDomainsSetting);
|
||||
|
||||
return new class implements IStorageService {
|
||||
get = () => JSON.stringify(_settings);
|
||||
store = (key: string, val: string) => _settings = JSON.parse(val);
|
||||
|
||||
// Don't care
|
||||
_serviceBrand: any;
|
||||
|
||||
onDidChangeStorage = () => ({ dispose: () => { } });
|
||||
onWillSaveState = () => ({ dispose: () => { } });
|
||||
|
||||
getBoolean = () => true;
|
||||
getNumber = () => 0;
|
||||
remove = () => { };
|
||||
logStorage = () => { };
|
||||
};
|
||||
}
|
||||
|
||||
function getDialogService() {
|
||||
return new class implements IDialogService {
|
||||
_showInvoked = 0;
|
||||
show = () => {
|
||||
this._showInvoked++;
|
||||
return Promise.resolve({} as any);
|
||||
}
|
||||
get confirmInvoked() { return this._showInvoked; }
|
||||
|
||||
// Don't care
|
||||
_serviceBrand: any;
|
||||
confirm = () => {
|
||||
return Promise.resolve({} as any);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
function getProductService(): IProductService {
|
||||
return new class {
|
||||
nameShort: 'VS Code';
|
||||
|
||||
_serviceBrand: any;
|
||||
} as IProductService;
|
||||
}
|
||||
|
||||
|
||||
setup(function () {
|
||||
lastCommand = undefined;
|
||||
});
|
||||
|
||||
test('delegate to editorService, scheme:///fff', function () {
|
||||
const openerService = new OpenerService(editorService, NullCommandService);
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
NullCommandService,
|
||||
getStorageService([]),
|
||||
getDialogService(),
|
||||
getProductService()
|
||||
);
|
||||
openerService.open(URI.parse('another:///somepath'));
|
||||
assert.equal(editorService.lastInput!.options!.selection, undefined);
|
||||
});
|
||||
|
||||
test('delegate to editorService, scheme:///fff#L123', function () {
|
||||
|
||||
const openerService = new OpenerService(editorService, NullCommandService);
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
NullCommandService,
|
||||
getStorageService([]),
|
||||
getDialogService(),
|
||||
getProductService()
|
||||
);
|
||||
|
||||
openerService.open(URI.parse('file:///somepath#L23'));
|
||||
assert.equal(editorService.lastInput!.options!.selection!.startLineNumber, 23);
|
||||
@@ -59,7 +121,13 @@ suite('OpenerService', function () {
|
||||
|
||||
test('delegate to editorService, scheme:///fff#123,123', function () {
|
||||
|
||||
const openerService = new OpenerService(editorService, NullCommandService);
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
NullCommandService,
|
||||
getStorageService([]),
|
||||
getDialogService(),
|
||||
getProductService()
|
||||
);
|
||||
|
||||
openerService.open(URI.parse('file:///somepath#23'));
|
||||
assert.equal(editorService.lastInput!.options!.selection!.startLineNumber, 23);
|
||||
@@ -78,7 +146,13 @@ suite('OpenerService', function () {
|
||||
|
||||
test('delegate to commandsService, command:someid', function () {
|
||||
|
||||
const openerService = new OpenerService(editorService, commandService);
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
commandService,
|
||||
getStorageService([]),
|
||||
getDialogService(),
|
||||
getProductService()
|
||||
);
|
||||
|
||||
const id = `aCommand${Math.random()}`;
|
||||
CommandsRegistry.registerCommand(id, function () { });
|
||||
@@ -98,4 +172,70 @@ suite('OpenerService', function () {
|
||||
assert.equal(lastCommand!.args[0], 12);
|
||||
assert.equal(lastCommand!.args[1], true);
|
||||
});
|
||||
|
||||
test('links are protected by dialog.show', function () {
|
||||
const dialogService = getDialogService();
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
commandService,
|
||||
getStorageService([]),
|
||||
dialogService,
|
||||
getProductService()
|
||||
);
|
||||
|
||||
openerService.open(URI.parse('https://www.microsoft.com'));
|
||||
assert.equal(dialogService.confirmInvoked, 1);
|
||||
});
|
||||
|
||||
test('links on the whitelisted domains can be opened without dialog.show', function () {
|
||||
const dialogService = getDialogService();
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
commandService,
|
||||
getStorageService(['https://microsoft.com']),
|
||||
dialogService,
|
||||
getProductService()
|
||||
);
|
||||
|
||||
openerService.open(URI.parse('https://microsoft.com'));
|
||||
openerService.open(URI.parse('https://microsoft.com/'));
|
||||
openerService.open(URI.parse('https://microsoft.com/en-us/'));
|
||||
openerService.open(URI.parse('https://microsoft.com/en-us/?foo=bar'));
|
||||
openerService.open(URI.parse('https://microsoft.com/en-us/?foo=bar#baz'));
|
||||
|
||||
assert.equal(dialogService.confirmInvoked, 0);
|
||||
});
|
||||
|
||||
test('variations of links are protected by dialog confirmation', function () {
|
||||
const dialogService = getDialogService();
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
commandService,
|
||||
getStorageService(['https://microsoft.com']),
|
||||
dialogService,
|
||||
getProductService()
|
||||
);
|
||||
|
||||
openerService.open(URI.parse('http://microsoft.com'));
|
||||
openerService.open(URI.parse('https://www.microsoft.com'));
|
||||
|
||||
assert.equal(dialogService.confirmInvoked, 2);
|
||||
});
|
||||
|
||||
test('* removes all link protection', function () {
|
||||
const dialogService = getDialogService();
|
||||
const openerService = new OpenerService(
|
||||
editorService,
|
||||
commandService,
|
||||
getStorageService(['*']),
|
||||
dialogService,
|
||||
getProductService()
|
||||
);
|
||||
|
||||
openerService.open(URI.parse('https://code.visualstudio.com/'));
|
||||
openerService.open(URI.parse('https://www.microsoft.com'));
|
||||
openerService.open(URI.parse('https://www.github.com'));
|
||||
|
||||
assert.equal(dialogService.confirmInvoked, 0);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -7,6 +7,7 @@ import * as assert from 'assert';
|
||||
import { StandardTokenType } from 'vs/editor/common/modes';
|
||||
import { CharacterPairSupport } from 'vs/editor/common/modes/supports/characterPair';
|
||||
import { TokenText, createFakeScopedLineTokens } from 'vs/editor/test/common/modesTestUtils';
|
||||
import { StandardAutoClosingPairConditional } from 'vs/editor/common/modes/languageConfiguration';
|
||||
|
||||
suite('CharacterPairSupport', () => {
|
||||
|
||||
@@ -52,8 +53,21 @@ suite('CharacterPairSupport', () => {
|
||||
assert.deepEqual(characaterPairSupport.getSurroundingPairs(), []);
|
||||
});
|
||||
|
||||
function findAutoClosingPair(characterPairSupport: CharacterPairSupport, character: string): StandardAutoClosingPairConditional | null {
|
||||
for (const autoClosingPair of characterPairSupport.getAutoClosingPairs()) {
|
||||
if (autoClosingPair.open === character) {
|
||||
return autoClosingPair;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function testShouldAutoClose(characterPairSupport: CharacterPairSupport, line: TokenText[], character: string, column: number): boolean {
|
||||
return characterPairSupport.shouldAutoClosePair(character, createFakeScopedLineTokens(line), column);
|
||||
const autoClosingPair = findAutoClosingPair(characterPairSupport, character);
|
||||
if (!autoClosingPair) {
|
||||
return false;
|
||||
}
|
||||
return CharacterPairSupport.shouldAutoClosePair(autoClosingPair, createFakeScopedLineTokens(line), column);
|
||||
}
|
||||
|
||||
test('shouldAutoClosePair in empty line', () => {
|
||||
|
||||
@@ -21,86 +21,20 @@ suite('Editor Modes - Auto Indentation', () => {
|
||||
assert.deepEqual(actual, null);
|
||||
}
|
||||
|
||||
function testAppends(electricCharacterSupport: BracketElectricCharacterSupport, line: TokenText[], character: string, offset: number, appendText: string): void {
|
||||
let actual = _testOnElectricCharacter(electricCharacterSupport, line, character, offset);
|
||||
assert.deepEqual(actual, { appendText: appendText });
|
||||
}
|
||||
|
||||
function testMatchBracket(electricCharacterSupport: BracketElectricCharacterSupport, line: TokenText[], character: string, offset: number, matchOpenBracket: string): void {
|
||||
let actual = _testOnElectricCharacter(electricCharacterSupport, line, character, offset);
|
||||
assert.deepEqual(actual, { matchOpenBracket: matchOpenBracket });
|
||||
}
|
||||
|
||||
test('Doc comments', () => {
|
||||
let brackets = new BracketElectricCharacterSupport(null, [{ open: '/**', close: ' */' }], null);
|
||||
|
||||
testAppends(brackets, [
|
||||
{ text: '/*', type: StandardTokenType.Other },
|
||||
], '*', 3, ' */');
|
||||
|
||||
testDoesNothing(brackets, [
|
||||
{ text: '/*', type: StandardTokenType.Other },
|
||||
{ text: ' ', type: StandardTokenType.Other },
|
||||
{ text: '*/', type: StandardTokenType.Other },
|
||||
], '*', 3);
|
||||
});
|
||||
|
||||
test('getElectricCharacters uses all sources and dedups', () => {
|
||||
let sup = new BracketElectricCharacterSupport(
|
||||
new RichEditBrackets(fakeLanguageIdentifier, [
|
||||
['{', '}'],
|
||||
['(', ')']
|
||||
]), [
|
||||
{ open: '{', close: '}', notIn: ['string', 'comment'] },
|
||||
{ open: '"', close: '"', notIn: ['string', 'comment'] },
|
||||
{ open: 'begin', close: 'end', notIn: ['string'] }
|
||||
],
|
||||
{ docComment: { open: '/**', close: ' */' } }
|
||||
])
|
||||
);
|
||||
|
||||
assert.deepEqual(sup.getElectricCharacters(), ['}', ')', 'n', '*']);
|
||||
});
|
||||
|
||||
test('auto-close', () => {
|
||||
let sup = new BracketElectricCharacterSupport(
|
||||
new RichEditBrackets(fakeLanguageIdentifier, [
|
||||
['{', '}'],
|
||||
['(', ')']
|
||||
]), [
|
||||
{ open: '{', close: '}', notIn: ['string', 'comment'] },
|
||||
{ open: '"', close: '"', notIn: ['string', 'comment'] },
|
||||
{ open: 'begin', close: 'end', notIn: ['string'] }
|
||||
],
|
||||
{ docComment: { open: '/**', close: ' */' } }
|
||||
);
|
||||
|
||||
testDoesNothing(sup, [], 'a', 0);
|
||||
|
||||
testDoesNothing(sup, [{ text: 'egi', type: StandardTokenType.Other }], 'b', 1);
|
||||
testDoesNothing(sup, [{ text: 'bgi', type: StandardTokenType.Other }], 'e', 2);
|
||||
testDoesNothing(sup, [{ text: 'bei', type: StandardTokenType.Other }], 'g', 3);
|
||||
testDoesNothing(sup, [{ text: 'beg', type: StandardTokenType.Other }], 'i', 4);
|
||||
|
||||
testDoesNothing(sup, [{ text: 'egin', type: StandardTokenType.Other }], 'b', 1);
|
||||
testDoesNothing(sup, [{ text: 'bgin', type: StandardTokenType.Other }], 'e', 2);
|
||||
testDoesNothing(sup, [{ text: 'bein', type: StandardTokenType.Other }], 'g', 3);
|
||||
testDoesNothing(sup, [{ text: 'begn', type: StandardTokenType.Other }], 'i', 4);
|
||||
testAppends(sup, [{ text: 'begi', type: StandardTokenType.Other }], 'n', 5, 'end');
|
||||
|
||||
testDoesNothing(sup, [{ text: '3gin', type: StandardTokenType.Other }], 'b', 1);
|
||||
testDoesNothing(sup, [{ text: 'bgin', type: StandardTokenType.Other }], '3', 2);
|
||||
testDoesNothing(sup, [{ text: 'b3in', type: StandardTokenType.Other }], 'g', 3);
|
||||
testDoesNothing(sup, [{ text: 'b3gn', type: StandardTokenType.Other }], 'i', 4);
|
||||
testDoesNothing(sup, [{ text: 'b3gi', type: StandardTokenType.Other }], 'n', 5);
|
||||
|
||||
testDoesNothing(sup, [{ text: 'begi', type: StandardTokenType.String }], 'n', 5);
|
||||
|
||||
testAppends(sup, [{ text: '"', type: StandardTokenType.String }, { text: 'begi', type: StandardTokenType.Other }], 'n', 6, 'end');
|
||||
testDoesNothing(sup, [{ text: '"', type: StandardTokenType.String }, { text: 'begi', type: StandardTokenType.String }], 'n', 6);
|
||||
|
||||
testAppends(sup, [{ text: '/*', type: StandardTokenType.String }], '*', 3, ' */');
|
||||
|
||||
testDoesNothing(sup, [{ text: 'begi', type: StandardTokenType.Other }, { text: 'end', type: StandardTokenType.Other }], 'n', 5);
|
||||
assert.deepEqual(sup.getElectricCharacters(), ['}', ')']);
|
||||
});
|
||||
|
||||
test('matchOpenBracket', () => {
|
||||
@@ -108,12 +42,7 @@ suite('Editor Modes - Auto Indentation', () => {
|
||||
new RichEditBrackets(fakeLanguageIdentifier, [
|
||||
['{', '}'],
|
||||
['(', ')']
|
||||
]), [
|
||||
{ open: '{', close: '}', notIn: ['string', 'comment'] },
|
||||
{ open: '"', close: '"', notIn: ['string', 'comment'] },
|
||||
{ open: 'begin', close: 'end', notIn: ['string'] }
|
||||
],
|
||||
{ docComment: { open: '/**', close: ' */' } }
|
||||
])
|
||||
);
|
||||
|
||||
testDoesNothing(sup, [{ text: '\t{', type: StandardTokenType.Other }], '\t', 1);
|
||||
|
||||
8
src/vs/monaco.d.ts
vendored
8
src/vs/monaco.d.ts
vendored
@@ -4565,7 +4565,9 @@ declare namespace monaco.languages {
|
||||
*
|
||||
* @deprecated Will be replaced by a better API soon.
|
||||
*/
|
||||
__electricCharacterSupport?: IBracketElectricCharacterContribution;
|
||||
__electricCharacterSupport?: {
|
||||
docComment?: IDocComment;
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -4640,10 +4642,6 @@ declare namespace monaco.languages {
|
||||
action: EnterAction;
|
||||
}
|
||||
|
||||
export interface IBracketElectricCharacterContribution {
|
||||
docComment?: IDocComment;
|
||||
}
|
||||
|
||||
/**
|
||||
* Definition of documentation comments (e.g. Javadoc/JSdoc)
|
||||
*/
|
||||
|
||||
7
src/vs/nls.d.ts
vendored
7
src/vs/nls.d.ts
vendored
@@ -8,5 +8,12 @@ export interface ILocalizeInfo {
|
||||
comment: string[];
|
||||
}
|
||||
|
||||
/**
|
||||
* Localize a message. `message` can contain `{n}` notation where it is replaced by the nth value in `...args`.
|
||||
*/
|
||||
export declare function localize(info: ILocalizeInfo, message: string, ...args: (string | number | boolean | undefined | null)[]): string;
|
||||
|
||||
/**
|
||||
* Localize a message. `message` can contain `{n}` notation where it is replaced by the nth value in `...args`.
|
||||
*/
|
||||
export declare function localize(key: string, message: string, ...args: (string | number | boolean | undefined | null)[]): string;
|
||||
|
||||
@@ -99,6 +99,10 @@ export const enum ConfigurationScope {
|
||||
* Resource specific configuration, which can be configured in the user, workspace or folder settings.
|
||||
*/
|
||||
RESOURCE,
|
||||
/**
|
||||
* Machine specific configuration that can also be configured in workspace or folder settings.
|
||||
*/
|
||||
MACHINE_OVERRIDABLE,
|
||||
}
|
||||
|
||||
export interface IConfigurationPropertySchema extends IJSONSchema {
|
||||
|
||||
@@ -20,7 +20,7 @@ export class DownloadService implements IDownloadService {
|
||||
) { }
|
||||
|
||||
async download(resource: URI, target: URI, cancellationToken: CancellationToken = CancellationToken.None): Promise<void> {
|
||||
if (resource.scheme === Schemas.file) {
|
||||
if (resource.scheme === Schemas.file || resource.scheme === Schemas.vscodeRemote) {
|
||||
await this.fileService.copy(resource, target);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -199,6 +199,7 @@ export interface IExtensionManagementService {
|
||||
|
||||
zip(extension: ILocalExtension): Promise<URI>;
|
||||
unzip(zipLocation: URI, type: ExtensionType): Promise<IExtensionIdentifier>;
|
||||
getManifest(vsix: URI): Promise<IExtensionManifest>;
|
||||
install(vsix: URI): Promise<ILocalExtension>;
|
||||
installFromGallery(extension: IGalleryExtension): Promise<ILocalExtension>;
|
||||
uninstall(extension: ILocalExtension, force?: boolean): Promise<void>;
|
||||
|
||||
@@ -9,7 +9,7 @@ import { Event } from 'vs/base/common/event';
|
||||
import { URI, UriComponents } from 'vs/base/common/uri';
|
||||
import { IURITransformer, DefaultURITransformer, transformAndReviveIncomingURIs } from 'vs/base/common/uriIpc';
|
||||
import { cloneAndChange } from 'vs/base/common/objects';
|
||||
import { ExtensionType } from 'vs/platform/extensions/common/extensions';
|
||||
import { ExtensionType, IExtensionManifest } from 'vs/platform/extensions/common/extensions';
|
||||
|
||||
function transformIncomingURI(uri: UriComponents, transformer: IURITransformer | null): URI {
|
||||
return URI.revive(transformer ? transformer.transformIncoming(uri) : uri);
|
||||
@@ -62,6 +62,7 @@ export class ExtensionManagementChannel implements IServerChannel {
|
||||
case 'zip': return this.service.zip(transformIncomingExtension(args[0], uriTransformer)).then(uri => transformOutgoingURI(uri, uriTransformer));
|
||||
case 'unzip': return this.service.unzip(transformIncomingURI(args[0], uriTransformer), args[1]);
|
||||
case 'install': return this.service.install(transformIncomingURI(args[0], uriTransformer));
|
||||
case 'getManifest': return this.service.getManifest(transformIncomingURI(args[0], uriTransformer));
|
||||
case 'installFromGallery': return this.service.installFromGallery(args[0]);
|
||||
case 'uninstall': return this.service.uninstall(transformIncomingExtension(args[0], uriTransformer), args[1]);
|
||||
case 'reinstallFromGallery': return this.service.reinstallFromGallery(transformIncomingExtension(args[0], uriTransformer));
|
||||
@@ -99,6 +100,10 @@ export class ExtensionManagementChannelClient implements IExtensionManagementSer
|
||||
return Promise.resolve(this.channel.call<ILocalExtension>('install', [vsix])).then(local => transformIncomingExtension(local, null));
|
||||
}
|
||||
|
||||
getManifest(vsix: URI): Promise<IExtensionManifest> {
|
||||
return Promise.resolve(this.channel.call<IExtensionManifest>('getManifest', [vsix]));
|
||||
}
|
||||
|
||||
installFromGallery(extension: IGalleryExtension): Promise<ILocalExtension> {
|
||||
return Promise.resolve(this.channel.call<ILocalExtension>('installFromGallery', [extension])).then(local => transformIncomingExtension(local, null));
|
||||
}
|
||||
|
||||
@@ -164,6 +164,12 @@ export class ExtensionManagementService extends Disposable implements IExtension
|
||||
return this.install(zipLocation, type).then(local => local.identifier);
|
||||
}
|
||||
|
||||
async getManifest(vsix: URI): Promise<IExtensionManifest> {
|
||||
const downloadLocation = await this.downloadVsix(vsix);
|
||||
const zipPath = path.resolve(downloadLocation.fsPath);
|
||||
return getManifest(zipPath);
|
||||
}
|
||||
|
||||
private collectFiles(extension: ILocalExtension): Promise<IFile[]> {
|
||||
|
||||
const collectFilesFromDirectory = async (dir: string): Promise<string[]> => {
|
||||
|
||||
@@ -71,7 +71,7 @@ export function restoreRecentlyOpened(data: RecentlyOpenedStorageData | undefine
|
||||
result.workspaces.push({ folderUri: URI.file(workspace) });
|
||||
} else if (isLegacySerializedWorkspace(workspace)) {
|
||||
result.workspaces.push({ workspace: { id: workspace.id, configPath: URI.file(workspace.configPath) } });
|
||||
} else if (isUriComponents(window)) {
|
||||
} else if (isUriComponents(workspace)) {
|
||||
// added by 1.26-insiders
|
||||
result.workspaces.push({ folderUri: URI.revive(<UriComponents>workspace) });
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { AbstractLifecycleService } from 'vs/platform/lifecycle/common/lifecycleService';
|
||||
import { localize } from 'vs/nls';
|
||||
import { ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation';
|
||||
import { addDisposableListener, EventType } from 'vs/base/browser/dom';
|
||||
|
||||
export class BrowserLifecycleService extends AbstractLifecycleService {
|
||||
|
||||
@@ -22,10 +23,10 @@ export class BrowserLifecycleService extends AbstractLifecycleService {
|
||||
}
|
||||
|
||||
private registerListeners(): void {
|
||||
window.onbeforeunload = () => this.beforeUnload();
|
||||
addDisposableListener(window, EventType.BEFORE_UNLOAD, () => this.onBeforeUnload());
|
||||
}
|
||||
|
||||
private beforeUnload(): string | null {
|
||||
private onBeforeUnload(): string | null {
|
||||
let veto = false;
|
||||
|
||||
// Before Shutdown
|
||||
@@ -34,7 +35,7 @@ export class BrowserLifecycleService extends AbstractLifecycleService {
|
||||
if (value === true) {
|
||||
veto = true;
|
||||
} else if (value instanceof Promise && !veto) {
|
||||
console.warn(new Error('Long running onBeforeShutdown currently not supported'));
|
||||
console.warn(new Error('Long running onBeforeShutdown currently not supported in the web'));
|
||||
veto = true;
|
||||
}
|
||||
},
|
||||
@@ -49,11 +50,14 @@ export class BrowserLifecycleService extends AbstractLifecycleService {
|
||||
// No Veto: continue with Will Shutdown
|
||||
this._onWillShutdown.fire({
|
||||
join() {
|
||||
console.warn(new Error('Long running onWillShutdown currently not supported'));
|
||||
console.warn(new Error('Long running onWillShutdown currently not supported in the web'));
|
||||
},
|
||||
reason: ShutdownReason.QUIT
|
||||
});
|
||||
|
||||
// Finally end with Shutdown event
|
||||
this._onShutdown.fire();
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { IChannel } from 'vs/base/parts/ipc/common/ipc';
|
||||
import { IMenubarService, IMenubarData } from 'vs/platform/menubar/common/menubar';
|
||||
import { IMenubarService, IMenubarData } from 'vs/platform/menubar/node/menubar';
|
||||
import { IMainProcessService } from 'vs/platform/ipc/electron-browser/mainProcessService';
|
||||
import { ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation';
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti
|
||||
import { mnemonicMenuLabel as baseMnemonicLabel } from 'vs/base/common/labels';
|
||||
import { IWindowsMainService, IWindowsCountChangedEvent } from 'vs/platform/windows/electron-main/windows';
|
||||
import { IHistoryMainService } from 'vs/platform/history/common/history';
|
||||
import { IMenubarData, IMenubarKeybinding, MenubarMenuItem, isMenubarMenuItemSeparator, isMenubarMenuItemSubmenu, isMenubarMenuItemAction, IMenubarMenu, isMenubarMenuItemUriAction } from 'vs/platform/menubar/common/menubar';
|
||||
import { IMenubarData, IMenubarKeybinding, MenubarMenuItem, isMenubarMenuItemSeparator, isMenubarMenuItemSubmenu, isMenubarMenuItemAction, IMenubarMenu, isMenubarMenuItemUriAction } from 'vs/platform/menubar/node/menubar';
|
||||
import { URI } from 'vs/base/common/uri';
|
||||
import { IStateService } from 'vs/platform/state/common/state';
|
||||
import { ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain';
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { IMenubarService, IMenubarData } from 'vs/platform/menubar/common/menubar';
|
||||
import { IMenubarService, IMenubarData } from 'vs/platform/menubar/node/menubar';
|
||||
import { Menubar } from 'vs/platform/menubar/electron-main/menubar';
|
||||
import { ILogService } from 'vs/platform/log/common/log';
|
||||
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import { IServerChannel } from 'vs/base/parts/ipc/common/ipc';
|
||||
import { IMenubarService } from 'vs/platform/menubar/common/menubar';
|
||||
import { IMenubarService } from 'vs/platform/menubar/node/menubar';
|
||||
import { Event } from 'vs/base/common/event';
|
||||
|
||||
export class MenubarChannel implements IServerChannel {
|
||||
|
||||
@@ -11,6 +11,7 @@ export const IOpenerService = createDecorator<IOpenerService>('openerService');
|
||||
|
||||
export interface IOpener {
|
||||
open(resource: URI, options?: { openToSide?: boolean }): Promise<boolean>;
|
||||
open(resource: URI, options?: { openExternal?: boolean }): Promise<boolean>;
|
||||
}
|
||||
|
||||
export interface IOpenerService {
|
||||
@@ -29,18 +30,11 @@ export interface IOpenerService {
|
||||
* @return A promise that resolves when the opening is done.
|
||||
*/
|
||||
open(resource: URI, options?: { openToSide?: boolean }): Promise<boolean>;
|
||||
|
||||
/**
|
||||
* Opens a URL externally.
|
||||
*
|
||||
* @param url A resource to open externally.
|
||||
*/
|
||||
openExternal(resource: URI): Promise<boolean>;
|
||||
open(resource: URI, options?: { openExternal?: boolean }): Promise<boolean>;
|
||||
}
|
||||
|
||||
export const NullOpenerService: IOpenerService = Object.freeze({
|
||||
_serviceBrand: undefined,
|
||||
registerOpener() { return { dispose() { } }; },
|
||||
open() { return Promise.resolve(false); },
|
||||
openExternal() { return Promise.resolve(false); }
|
||||
});
|
||||
|
||||
@@ -37,7 +37,7 @@ export class BrowserStorageService extends Disposable implements IStorageService
|
||||
private workspaceStorageFile: URI;
|
||||
|
||||
private initializePromise: Promise<void>;
|
||||
private periodicSaveScheduler = this._register(new RunOnceScheduler(() => this.saveState(), 5000));
|
||||
private periodicSaveScheduler = this._register(new RunOnceScheduler(() => this.collectState(), 5000));
|
||||
|
||||
get hasPendingUpdate(): boolean {
|
||||
return this.globalStorageDatabase.hasPendingUpdate || this.workspaceStorageDatabase.hasPendingUpdate;
|
||||
@@ -57,14 +57,19 @@ export class BrowserStorageService extends Disposable implements IStorageService
|
||||
this.periodicSaveScheduler.schedule();
|
||||
}
|
||||
|
||||
private saveState(): void {
|
||||
private collectState(): void {
|
||||
runWhenIdle(() => {
|
||||
|
||||
// this event will potentially cause new state to be stored
|
||||
// since new state will only be created while the document
|
||||
// has focus, one optimization is to not run this when the
|
||||
// document has no focus, assuming that state has not changed
|
||||
if (document.hasFocus()) {
|
||||
//
|
||||
// another optimization is to not collect more state if we
|
||||
// have a pending update already running which indicates
|
||||
// that the connection is either slow or disconnected and
|
||||
// thus unhealthy.
|
||||
if (document.hasFocus() && !this.hasPendingUpdate) {
|
||||
this._onWillSaveState.fire({ reason: WillSaveStateReason.NONE });
|
||||
}
|
||||
|
||||
@@ -197,7 +202,7 @@ export class FileStorageDatabase extends Disposable implements IStorageDatabase
|
||||
this._register(this.fileService.watch(this.file));
|
||||
this._register(this.fileService.onFileChanges(e => {
|
||||
if (document.hasFocus()) {
|
||||
return; // ignore changes from ourselves by checking for focus
|
||||
return; // optimization: ignore changes from ourselves by checking for focus
|
||||
}
|
||||
|
||||
if (!e.contains(this.file, FileChangeType.UPDATED)) {
|
||||
@@ -251,15 +256,17 @@ export class FileStorageDatabase extends Disposable implements IStorageDatabase
|
||||
|
||||
await this.pendingUpdate;
|
||||
|
||||
this._hasPendingUpdate = true;
|
||||
this.pendingUpdate = (async () => {
|
||||
try {
|
||||
this._hasPendingUpdate = true;
|
||||
|
||||
await this.fileService.writeFile(this.file, VSBuffer.fromString(JSON.stringify(mapToSerializable(items))));
|
||||
|
||||
this.pendingUpdate = this.fileService.writeFile(this.file, VSBuffer.fromString(JSON.stringify(mapToSerializable(items))))
|
||||
.then(() => {
|
||||
this.ensureWatching(); // now that the file must exist, ensure we watch it for changes
|
||||
})
|
||||
.finally(() => {
|
||||
} finally {
|
||||
this._hasPendingUpdate = false;
|
||||
});
|
||||
}
|
||||
})();
|
||||
|
||||
return this.pendingUpdate;
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
import { IChannel, IServerChannel } from 'vs/base/parts/ipc/common/ipc';
|
||||
import { Event, Emitter } from 'vs/base/common/event';
|
||||
import { StorageMainService, IStorageChangeEvent } from 'vs/platform/storage/node/storageMainService';
|
||||
import { IStorageChangeEvent, IStorageMainService } from 'vs/platform/storage/node/storageMainService';
|
||||
import { IUpdateRequest, IStorageDatabase, IStorageItemsChangeEvent } from 'vs/base/parts/storage/common/storage';
|
||||
import { mapToSerializable, serializableToMap, values } from 'vs/base/common/map';
|
||||
import { Disposable, IDisposable, dispose } from 'vs/base/common/lifecycle';
|
||||
@@ -38,7 +38,7 @@ export class GlobalStorageDatabaseChannel extends Disposable implements IServerC
|
||||
|
||||
constructor(
|
||||
private logService: ILogService,
|
||||
private storageMainService: StorageMainService
|
||||
private storageMainService: IStorageMainService
|
||||
) {
|
||||
super();
|
||||
|
||||
@@ -203,4 +203,4 @@ export class GlobalStorageDatabaseChannelClient extends Disposable implements IS
|
||||
|
||||
dispose(this.onDidChangeItemsOnMainListener);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,6 +34,16 @@ export interface IStorageMainService {
|
||||
*/
|
||||
readonly onWillSaveState: Event<void>;
|
||||
|
||||
/**
|
||||
* Access to all cached items of this storage service.
|
||||
*/
|
||||
readonly items: Map<string, string>;
|
||||
|
||||
/**
|
||||
* Required call to ensure the service can be used.
|
||||
*/
|
||||
initialize(): Promise<void>;
|
||||
|
||||
/**
|
||||
* Retrieve an element stored with the given key from storage. Use
|
||||
* the provided defaultValue if the element is null or undefined.
|
||||
|
||||
@@ -16,18 +16,19 @@ import { cleanRemoteAuthority } from 'vs/platform/telemetry/common/telemetryUtil
|
||||
|
||||
export async function resolveWorkbenchCommonProperties(storageService: IStorageService, commit: string | undefined, version: string | undefined, machineId: string, remoteAuthority?: string): Promise<{ [name: string]: string | undefined }> {
|
||||
const result: { [name: string]: string | undefined; } = Object.create(null);
|
||||
const instanceId = storageService.get(instanceStorageKey, StorageScope.GLOBAL)!;
|
||||
const firstSessionDate = storageService.get(firstSessionDateStorageKey, StorageScope.GLOBAL)!;
|
||||
const lastSessionDate = storageService.get(lastSessionDateStorageKey, StorageScope.GLOBAL)!;
|
||||
|
||||
/**
|
||||
* Note: In the web, session date information is fetched from browser storage, so these dates are tied to a specific
|
||||
* browser and not the machine overall.
|
||||
*/
|
||||
// __GDPR__COMMON__ "common.firstSessionDate" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" }
|
||||
result['common.firstSessionDate'] = firstSessionDate;
|
||||
// __GDPR__COMMON__ "common.lastSessionDate" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" }
|
||||
result['common.lastSessionDate'] = lastSessionDate || '';
|
||||
// __GDPR__COMMON__ "common.isNewSession" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" }
|
||||
result['common.isNewSession'] = !lastSessionDate ? '1' : '0';
|
||||
// __GDPR__COMMON__ "common.instanceId" : { "classification": "SystemMetaData", "purpose": "FeatureInsight" }
|
||||
result['common.instanceId'] = instanceId;
|
||||
// __GDPR__COMMON__ "common.remoteAuthority" : { "classification": "SystemMetaData", "purpose": "PerformanceAndHealth" }
|
||||
result['common.remoteAuthority'] = cleanRemoteAuthority(remoteAuthority);
|
||||
|
||||
|
||||
@@ -27,12 +27,16 @@ export class RelayURLService extends URLService implements IURLHandler {
|
||||
openerService.registerOpener(this);
|
||||
}
|
||||
|
||||
async open(uri: URI): Promise<boolean> {
|
||||
if (uri.scheme !== product.urlProtocol) {
|
||||
async open(resource: URI, options?: { openToSide?: boolean, openExternal?: boolean }): Promise<boolean> {
|
||||
if (options && options.openExternal) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return await this.urlService.open(uri);
|
||||
if (resource.scheme !== product.urlProtocol) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return await this.urlService.open(resource);
|
||||
}
|
||||
|
||||
handleURL(uri: URI): Promise<boolean> {
|
||||
|
||||
@@ -240,6 +240,8 @@ export interface IWindowService {
|
||||
closeWorkspace(): Promise<void>;
|
||||
updateTouchBar(items: ISerializableCommandAction[][]): Promise<void>;
|
||||
enterWorkspace(path: URI): Promise<IEnterWorkspaceResult | undefined>;
|
||||
// rationale: will eventually move to electron-browser
|
||||
// tslint:disable-next-line: no-dom-globals
|
||||
toggleFullScreen(target?: HTMLElement): Promise<void>;
|
||||
setRepresentedFilename(fileName: string): Promise<void>;
|
||||
getRecentlyOpened(): Promise<IRecentlyOpened>;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user