monaco-editor11 1.0.7 → 1.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/css.worker-C7FogG4G.js +93 -0
- package/dist/assets/editor.worker-iXcRX1Tq.js +26 -0
- package/dist/assets/html.worker-C8VxctEJ.js +470 -0
- package/dist/assets/json.worker-CMC9kgPL.js +58 -0
- package/dist/assets/ts.worker-CtTJ3hNN.js +67731 -0
- package/dist/index.d.ts +0 -6
- package/dist/monaco-editor11.es.js +49 -78
- package/dist/monaco-editor11.umd.js +1 -50
- package/dist/monaco.d.ts +8 -0
- package/dist/workers/common/initialize.js +16 -0
- package/dist/workers/common/workers.js +141 -0
- package/dist/workers/editor/common/abstractSyntaxTokenBackend.js +128 -0
- package/dist/workers/editor/common/abstractText.js +89 -0
- package/dist/workers/editor/common/ast.js +485 -0
- package/dist/workers/editor/common/autoIndent.js +390 -0
- package/dist/workers/editor/common/beforeEditPositionMapper.js +110 -0
- package/dist/workers/editor/common/bracketPairsImpl.js +717 -0
- package/dist/workers/editor/common/bracketPairsTree.js +343 -0
- package/dist/workers/editor/common/brackets.js +108 -0
- package/dist/workers/editor/common/characterClassifier.js +59 -0
- package/dist/workers/editor/common/characterPair.js +40 -0
- package/dist/workers/editor/common/colorizedBracketPairsDecorationProvider.js +97 -0
- package/dist/workers/editor/common/columnRange.js +35 -0
- package/dist/workers/editor/common/combineTextEditInfos.js +124 -0
- package/dist/workers/editor/common/common.js +20 -0
- package/dist/workers/editor/common/computeMovedLines.js +249 -0
- package/dist/workers/editor/common/concat23Trees.js +192 -0
- package/dist/workers/editor/common/contiguousMultilineTokens.js +32 -0
- package/dist/workers/editor/common/contiguousMultilineTokensBuilder.js +23 -0
- package/dist/workers/editor/common/contiguousTokensEditing.js +128 -0
- package/dist/workers/editor/common/contiguousTokensStore.js +207 -0
- package/dist/workers/editor/common/coordinatesConverter.js +51 -0
- package/dist/workers/editor/common/cursor.js +899 -0
- package/dist/workers/editor/common/cursorAtomicMoveOperations.js +145 -0
- package/dist/workers/editor/common/cursorCollection.js +194 -0
- package/dist/workers/editor/common/cursorColumnSelection.js +93 -0
- package/dist/workers/editor/common/cursorColumns.js +112 -0
- package/dist/workers/editor/common/cursorCommon.js +250 -0
- package/dist/workers/editor/common/cursorContext.js +15 -0
- package/dist/workers/editor/common/cursorDeleteOperations.js +231 -0
- package/dist/workers/editor/common/cursorMoveCommands.js +676 -0
- package/dist/workers/editor/common/cursorMoveOperations.js +290 -0
- package/dist/workers/editor/common/cursorTypeEditOperations.js +968 -0
- package/dist/workers/editor/common/cursorTypeOperations.js +173 -0
- package/dist/workers/editor/common/cursorUtils.js +75 -0
- package/dist/workers/editor/common/cursorWordOperations.js +720 -0
- package/dist/workers/editor/common/defaultDocumentColorsComputer.js +138 -0
- package/dist/workers/editor/common/defaultLinesDiffComputer.js +188 -0
- package/dist/workers/editor/common/diffAlgorithm.js +139 -0
- package/dist/workers/editor/common/diffEditor.js +38 -0
- package/dist/workers/editor/common/dynamicProgrammingDiffing.js +101 -0
- package/dist/workers/editor/common/edit.js +183 -0
- package/dist/workers/editor/common/editOperation.js +36 -0
- package/dist/workers/editor/common/editStack.js +363 -0
- package/dist/workers/editor/common/editorAction.js +26 -0
- package/dist/workers/editor/common/editorBaseApi.js +43 -0
- package/dist/workers/editor/common/editorColorRegistry.js +102 -0
- package/dist/workers/editor/common/editorCommon.js +13 -0
- package/dist/workers/editor/common/editorConfigurationSchema.js +338 -0
- package/dist/workers/editor/common/editorContextKeys.js +84 -0
- package/dist/workers/editor/common/editorFeatures.js +17 -0
- package/dist/workers/editor/common/editorOptions.js +3440 -0
- package/dist/workers/editor/common/editorTheme.js +23 -0
- package/dist/workers/editor/common/editorWebWorker.js +299 -0
- package/dist/workers/editor/common/editorWorker.js +9 -0
- package/dist/workers/editor/common/editorWorkerHost.js +15 -0
- package/dist/workers/editor/common/editorZoom.js +26 -0
- package/dist/workers/editor/common/electricCharacter.js +55 -0
- package/dist/workers/editor/common/encodedTokenAttributes.js +79 -0
- package/dist/workers/editor/common/enterAction.js +53 -0
- package/dist/workers/editor/common/eolCounter.js +44 -0
- package/dist/workers/editor/common/findSectionHeaders.js +128 -0
- package/dist/workers/editor/common/fixBrackets.js +67 -0
- package/dist/workers/editor/common/fixedArray.js +70 -0
- package/dist/workers/editor/common/fontInfo.js +172 -0
- package/dist/workers/editor/common/fontInfoFromSettings.js +29 -0
- package/dist/workers/editor/common/getIconClasses.js +106 -0
- package/dist/workers/editor/common/getPositionOffsetTransformerFromTextModel.js +24 -0
- package/dist/workers/editor/common/glyphLanesModel.js +61 -0
- package/dist/workers/editor/common/guidesTextModelPart.js +405 -0
- package/dist/workers/editor/common/heuristicSequenceOptimizations.js +374 -0
- package/dist/workers/editor/common/indentRules.js +63 -0
- package/dist/workers/editor/common/indentation.js +39 -0
- package/dist/workers/editor/common/indentationGuesser.js +178 -0
- package/dist/workers/editor/common/indentationLineProcessor.js +193 -0
- package/dist/workers/editor/common/inlineDecorations.js +26 -0
- package/dist/workers/editor/common/inplaceReplaceSupport.js +87 -0
- package/dist/workers/editor/common/inputMode.js +22 -0
- package/dist/workers/editor/common/intervalTree.js +1002 -0
- package/dist/workers/editor/common/language.js +9 -0
- package/dist/workers/editor/common/languageBracketsConfiguration.js +133 -0
- package/dist/workers/editor/common/languageConfiguration.js +138 -0
- package/dist/workers/editor/common/languageConfigurationRegistry.js +361 -0
- package/dist/workers/editor/common/languageFeatureDebounce.js +137 -0
- package/dist/workers/editor/common/languageFeatureRegistry.js +180 -0
- package/dist/workers/editor/common/languageFeatures.js +9 -0
- package/dist/workers/editor/common/languageFeaturesService.js +47 -0
- package/dist/workers/editor/common/languageSelector.js +112 -0
- package/dist/workers/editor/common/languageService.js +92 -0
- package/dist/workers/editor/common/languages.js +522 -0
- package/dist/workers/editor/common/languagesAssociations.js +193 -0
- package/dist/workers/editor/common/languagesRegistry.js +237 -0
- package/dist/workers/editor/common/legacyLinesDiffComputer.js +468 -0
- package/dist/workers/editor/common/length.js +129 -0
- package/dist/workers/editor/common/lineDecorations.js +208 -0
- package/dist/workers/editor/common/lineEdit.js +75 -0
- package/dist/workers/editor/common/lineHeights.js +370 -0
- package/dist/workers/editor/common/linePart.js +25 -0
- package/dist/workers/editor/common/lineRange.js +312 -0
- package/dist/workers/editor/common/lineSequence.js +36 -0
- package/dist/workers/editor/common/lineTokens.js +405 -0
- package/dist/workers/editor/common/linesDiffComputer.js +29 -0
- package/dist/workers/editor/common/linesDiffComputers.js +13 -0
- package/dist/workers/editor/common/linesLayout.js +765 -0
- package/dist/workers/editor/common/linesSliceCharSequence.js +205 -0
- package/dist/workers/editor/common/linkComputer.js +269 -0
- package/dist/workers/editor/common/markerDecorations.js +9 -0
- package/dist/workers/editor/common/markerDecorationsService.js +248 -0
- package/dist/workers/editor/common/minimapTokensColorTracker.js +58 -0
- package/dist/workers/editor/common/mirrorTextModel.js +117 -0
- package/dist/workers/editor/common/model.js +9 -0
- package/dist/workers/editor/common/modelLineProjection.js +350 -0
- package/dist/workers/editor/common/modelLineProjectionData.js +297 -0
- package/dist/workers/editor/common/modelService.js +413 -0
- package/dist/workers/editor/common/modesRegistry.js +75 -0
- package/dist/workers/editor/common/monospaceLineBreaksComputer.js +473 -0
- package/dist/workers/editor/common/myersDiffAlgorithm.js +159 -0
- package/dist/workers/editor/common/nodeReader.js +127 -0
- package/dist/workers/editor/common/nullTokenize.js +29 -0
- package/dist/workers/editor/common/offsetRange.js +225 -0
- package/dist/workers/editor/common/onEnter.js +109 -0
- package/dist/workers/editor/common/oneCursor.js +117 -0
- package/dist/workers/editor/common/overviewZoneManager.js +176 -0
- package/dist/workers/editor/common/parser.js +121 -0
- package/dist/workers/editor/common/pieceTreeBase.js +1473 -0
- package/dist/workers/editor/common/pieceTreeTextBuffer.js +461 -0
- package/dist/workers/editor/common/pieceTreeTextBufferBuilder.js +140 -0
- package/dist/workers/editor/common/point.js +50 -0
- package/dist/workers/editor/common/position.js +142 -0
- package/dist/workers/editor/common/positionToOffset.js +17 -0
- package/dist/workers/editor/common/positionToOffsetImpl.js +98 -0
- package/dist/workers/editor/common/prefixSumComputer.js +226 -0
- package/dist/workers/editor/common/range.js +421 -0
- package/dist/workers/editor/common/rangeMapping.js +229 -0
- package/dist/workers/editor/common/rangeSingleLine.js +17 -0
- package/dist/workers/editor/common/rbTreeBase.js +362 -0
- package/dist/workers/editor/common/rect.js +163 -0
- package/dist/workers/editor/common/replaceCommand.js +158 -0
- package/dist/workers/editor/common/resolverService.js +5 -0
- package/dist/workers/editor/common/rgba.js +35 -0
- package/dist/workers/editor/common/richEditBrackets.js +356 -0
- package/dist/workers/editor/common/selection.js +145 -0
- package/dist/workers/editor/common/semanticTokensDto.js +82 -0
- package/dist/workers/editor/common/semanticTokensProviderStyling.js +263 -0
- package/dist/workers/editor/common/semanticTokensStyling.js +9 -0
- package/dist/workers/editor/common/semanticTokensStylingService.js +47 -0
- package/dist/workers/editor/common/shiftCommand.js +241 -0
- package/dist/workers/editor/common/smallImmutableSet.js +108 -0
- package/dist/workers/editor/common/sparseMultilineTokens.js +548 -0
- package/dist/workers/editor/common/sparseTokensStore.js +210 -0
- package/dist/workers/editor/common/standaloneEnums.js +1017 -0
- package/dist/workers/editor/common/standaloneStrings.js +42 -0
- package/dist/workers/editor/common/stringBuilder.js +122 -0
- package/dist/workers/editor/common/stringEdit.js +165 -0
- package/dist/workers/editor/common/supports.js +58 -0
- package/dist/workers/editor/common/surroundSelectionCommand.js +44 -0
- package/dist/workers/editor/common/textChange.js +248 -0
- package/dist/workers/editor/common/textEdit.js +269 -0
- package/dist/workers/editor/common/textLength.js +87 -0
- package/dist/workers/editor/common/textModel.js +2031 -0
- package/dist/workers/editor/common/textModelBracketPairs.js +45 -0
- package/dist/workers/editor/common/textModelDefaults.js +18 -0
- package/dist/workers/editor/common/textModelEditSource.js +166 -0
- package/dist/workers/editor/common/textModelEvents.js +216 -0
- package/dist/workers/editor/common/textModelGuides.js +40 -0
- package/dist/workers/editor/common/textModelPart.js +23 -0
- package/dist/workers/editor/common/textModelSearch.js +455 -0
- package/dist/workers/editor/common/textModelStringEdit.js +11 -0
- package/dist/workers/editor/common/textModelSync.impl.js +307 -0
- package/dist/workers/editor/common/textModelText.js +26 -0
- package/dist/workers/editor/common/textModelTokens.js +436 -0
- package/dist/workers/editor/common/textResourceConfiguration.js +6 -0
- package/dist/workers/editor/common/textToHtmlTokenizer.js +139 -0
- package/dist/workers/editor/common/tokenStore.js +407 -0
- package/dist/workers/editor/common/tokenWithTextArray.js +73 -0
- package/dist/workers/editor/common/tokenization.js +287 -0
- package/dist/workers/editor/common/tokenizationRegistry.js +123 -0
- package/dist/workers/editor/common/tokenizationTextModelPart.js +275 -0
- package/dist/workers/editor/common/tokenizer.js +301 -0
- package/dist/workers/editor/common/tokenizerSyntaxTokenBackend.js +261 -0
- package/dist/workers/editor/common/treeSitterLibraryService.js +9 -0
- package/dist/workers/editor/common/treeSitterSyntaxTokenBackend.js +167 -0
- package/dist/workers/editor/common/treeSitterThemeService.js +9 -0
- package/dist/workers/editor/common/treeSitterTokenizationImpl.js +713 -0
- package/dist/workers/editor/common/treeSitterTree.js +395 -0
- package/dist/workers/editor/common/treeViewsDnd.js +24 -0
- package/dist/workers/editor/common/treeViewsDndService.js +12 -0
- package/dist/workers/editor/common/trimTrailingWhitespaceCommand.js +98 -0
- package/dist/workers/editor/common/unicodeTextModelHighlighter.js +188 -0
- package/dist/workers/editor/common/utils.js +62 -0
- package/dist/workers/editor/common/viewContext.js +22 -0
- package/dist/workers/editor/common/viewEventHandler.js +186 -0
- package/dist/workers/editor/common/viewEvents.js +180 -0
- package/dist/workers/editor/common/viewLayout.js +368 -0
- package/dist/workers/editor/common/viewLineRenderer.js +948 -0
- package/dist/workers/editor/common/viewLinesViewportData.js +30 -0
- package/dist/workers/editor/common/viewModel.js +98 -0
- package/dist/workers/editor/common/viewModelDecoration.js +55 -0
- package/dist/workers/editor/common/viewModelDecorations.js +132 -0
- package/dist/workers/editor/common/viewModelEventDispatcher.js +398 -0
- package/dist/workers/editor/common/viewModelImpl.js +1163 -0
- package/dist/workers/editor/common/viewModelLines.js +938 -0
- package/dist/workers/editor/common/wordCharacterClassifier.js +87 -0
- package/dist/workers/editor/common/wordHelper.js +127 -0
- package/dist/workers/editor/editor.worker.js +11 -0
- package/dist/workers/language/css.worker.js +8 -0
- package/dist/workers/language/cssMode.js +198 -0
- package/dist/workers/language/cssWorker.js +183 -0
- package/dist/workers/language/html.worker.js +8 -0
- package/dist/workers/language/htmlMode.js +213 -0
- package/dist/workers/language/htmlWorker.js +126 -0
- package/dist/workers/language/json.worker.js +8 -0
- package/dist/workers/language/jsonMode.js +224 -0
- package/dist/workers/language/jsonWorker.js +187 -0
- package/dist/workers/language/languageFeatures.js +1009 -0
- package/dist/workers/language/lib.index.js +103 -0
- package/dist/workers/language/lib.js +1107 -0
- package/dist/workers/language/lspLanguageFeatures.js +716 -0
- package/dist/workers/language/monaco.contribution.js +144 -0
- package/dist/workers/language/tokenization.js +189 -0
- package/dist/workers/language/ts.worker.js +14 -0
- package/dist/workers/language/tsMode.js +212 -0
- package/dist/workers/language/tsWorker.js +352 -0
- package/dist/workers/language/typescriptServices.js +210154 -0
- package/dist/workers/language/typescriptServicesMetadata.js +3 -0
- package/dist/workers/language/workerManager.js +65 -0
- package/package.json +3 -2
|
@@ -0,0 +1,250 @@
|
|
|
1
|
+
import { Position } from './core/position.js';
|
|
2
|
+
import { Range } from './core/range.js';
|
|
3
|
+
import { Selection } from './core/selection.js';
|
|
4
|
+
import { createScopedLineTokens } from './languages/supports.js';
|
|
5
|
+
import { CursorColumns } from './core/cursorColumns.js';
|
|
6
|
+
import { normalizeIndentation } from './core/misc/indentation.js';
|
|
7
|
+
import { InputMode } from './inputMode.js';
|
|
8
|
+
|
|
9
|
+
/*---------------------------------------------------------------------------------------------
|
|
10
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
11
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
12
|
+
*--------------------------------------------------------------------------------------------*/
|
|
13
|
+
const autoCloseAlways = () => true;
|
|
14
|
+
const autoCloseNever = () => false;
|
|
15
|
+
const autoCloseBeforeWhitespace = (chr) => (chr === ' ' || chr === '\t');
|
|
16
|
+
class CursorConfiguration {
|
|
17
|
+
static shouldRecreate(e) {
|
|
18
|
+
return (e.hasChanged(165 /* EditorOption.layoutInfo */)
|
|
19
|
+
|| e.hasChanged(148 /* EditorOption.wordSeparators */)
|
|
20
|
+
|| e.hasChanged(45 /* EditorOption.emptySelectionClipboard */)
|
|
21
|
+
|| e.hasChanged(85 /* EditorOption.multiCursorMergeOverlapping */)
|
|
22
|
+
|| e.hasChanged(88 /* EditorOption.multiCursorPaste */)
|
|
23
|
+
|| e.hasChanged(89 /* EditorOption.multiCursorLimit */)
|
|
24
|
+
|| e.hasChanged(10 /* EditorOption.autoClosingBrackets */)
|
|
25
|
+
|| e.hasChanged(11 /* EditorOption.autoClosingComments */)
|
|
26
|
+
|| e.hasChanged(15 /* EditorOption.autoClosingQuotes */)
|
|
27
|
+
|| e.hasChanged(13 /* EditorOption.autoClosingDelete */)
|
|
28
|
+
|| e.hasChanged(14 /* EditorOption.autoClosingOvertype */)
|
|
29
|
+
|| e.hasChanged(20 /* EditorOption.autoSurround */)
|
|
30
|
+
|| e.hasChanged(145 /* EditorOption.useTabStops */)
|
|
31
|
+
|| e.hasChanged(141 /* EditorOption.trimWhitespaceOnDelete */)
|
|
32
|
+
|| e.hasChanged(59 /* EditorOption.fontInfo */)
|
|
33
|
+
|| e.hasChanged(104 /* EditorOption.readOnly */)
|
|
34
|
+
|| e.hasChanged(147 /* EditorOption.wordSegmenterLocales */)
|
|
35
|
+
|| e.hasChanged(93 /* EditorOption.overtypeOnPaste */));
|
|
36
|
+
}
|
|
37
|
+
constructor(languageId, modelOptions, configuration, languageConfigurationService) {
|
|
38
|
+
this.languageConfigurationService = languageConfigurationService;
|
|
39
|
+
this._cursorMoveConfigurationBrand = undefined;
|
|
40
|
+
this._languageId = languageId;
|
|
41
|
+
const options = configuration.options;
|
|
42
|
+
const layoutInfo = options.get(165 /* EditorOption.layoutInfo */);
|
|
43
|
+
const fontInfo = options.get(59 /* EditorOption.fontInfo */);
|
|
44
|
+
this.readOnly = options.get(104 /* EditorOption.readOnly */);
|
|
45
|
+
this.tabSize = modelOptions.tabSize;
|
|
46
|
+
this.indentSize = modelOptions.indentSize;
|
|
47
|
+
this.insertSpaces = modelOptions.insertSpaces;
|
|
48
|
+
this.stickyTabStops = options.get(132 /* EditorOption.stickyTabStops */);
|
|
49
|
+
this.lineHeight = fontInfo.lineHeight;
|
|
50
|
+
this.typicalHalfwidthCharacterWidth = fontInfo.typicalHalfwidthCharacterWidth;
|
|
51
|
+
this.pageSize = Math.max(1, Math.floor(layoutInfo.height / this.lineHeight) - 2);
|
|
52
|
+
this.useTabStops = options.get(145 /* EditorOption.useTabStops */);
|
|
53
|
+
this.trimWhitespaceOnDelete = options.get(141 /* EditorOption.trimWhitespaceOnDelete */);
|
|
54
|
+
this.wordSeparators = options.get(148 /* EditorOption.wordSeparators */);
|
|
55
|
+
this.emptySelectionClipboard = options.get(45 /* EditorOption.emptySelectionClipboard */);
|
|
56
|
+
this.copyWithSyntaxHighlighting = options.get(31 /* EditorOption.copyWithSyntaxHighlighting */);
|
|
57
|
+
this.multiCursorMergeOverlapping = options.get(85 /* EditorOption.multiCursorMergeOverlapping */);
|
|
58
|
+
this.multiCursorPaste = options.get(88 /* EditorOption.multiCursorPaste */);
|
|
59
|
+
this.multiCursorLimit = options.get(89 /* EditorOption.multiCursorLimit */);
|
|
60
|
+
this.autoClosingBrackets = options.get(10 /* EditorOption.autoClosingBrackets */);
|
|
61
|
+
this.autoClosingComments = options.get(11 /* EditorOption.autoClosingComments */);
|
|
62
|
+
this.autoClosingQuotes = options.get(15 /* EditorOption.autoClosingQuotes */);
|
|
63
|
+
this.autoClosingDelete = options.get(13 /* EditorOption.autoClosingDelete */);
|
|
64
|
+
this.autoClosingOvertype = options.get(14 /* EditorOption.autoClosingOvertype */);
|
|
65
|
+
this.autoSurround = options.get(20 /* EditorOption.autoSurround */);
|
|
66
|
+
this.autoIndent = options.get(16 /* EditorOption.autoIndent */);
|
|
67
|
+
this.wordSegmenterLocales = options.get(147 /* EditorOption.wordSegmenterLocales */);
|
|
68
|
+
this.overtypeOnPaste = options.get(93 /* EditorOption.overtypeOnPaste */);
|
|
69
|
+
this.surroundingPairs = {};
|
|
70
|
+
this._electricChars = null;
|
|
71
|
+
this.shouldAutoCloseBefore = {
|
|
72
|
+
quote: this._getShouldAutoClose(languageId, this.autoClosingQuotes, true),
|
|
73
|
+
comment: this._getShouldAutoClose(languageId, this.autoClosingComments, false),
|
|
74
|
+
bracket: this._getShouldAutoClose(languageId, this.autoClosingBrackets, false),
|
|
75
|
+
};
|
|
76
|
+
this.autoClosingPairs = this.languageConfigurationService.getLanguageConfiguration(languageId).getAutoClosingPairs();
|
|
77
|
+
const surroundingPairs = this.languageConfigurationService.getLanguageConfiguration(languageId).getSurroundingPairs();
|
|
78
|
+
if (surroundingPairs) {
|
|
79
|
+
for (const pair of surroundingPairs) {
|
|
80
|
+
this.surroundingPairs[pair.open] = pair.close;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
const commentsConfiguration = this.languageConfigurationService.getLanguageConfiguration(languageId).comments;
|
|
84
|
+
this.blockCommentStartToken = commentsConfiguration?.blockCommentStartToken ?? null;
|
|
85
|
+
}
|
|
86
|
+
get electricChars() {
|
|
87
|
+
if (!this._electricChars) {
|
|
88
|
+
this._electricChars = {};
|
|
89
|
+
const electricChars = this.languageConfigurationService.getLanguageConfiguration(this._languageId).electricCharacter?.getElectricCharacters();
|
|
90
|
+
if (electricChars) {
|
|
91
|
+
for (const char of electricChars) {
|
|
92
|
+
this._electricChars[char] = true;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
return this._electricChars;
|
|
97
|
+
}
|
|
98
|
+
get inputMode() {
|
|
99
|
+
return InputMode.getInputMode();
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Should return opening bracket type to match indentation with
|
|
103
|
+
*/
|
|
104
|
+
onElectricCharacter(character, context, column) {
|
|
105
|
+
const scopedLineTokens = createScopedLineTokens(context, column - 1);
|
|
106
|
+
const electricCharacterSupport = this.languageConfigurationService.getLanguageConfiguration(scopedLineTokens.languageId).electricCharacter;
|
|
107
|
+
if (!electricCharacterSupport) {
|
|
108
|
+
return null;
|
|
109
|
+
}
|
|
110
|
+
return electricCharacterSupport.onElectricCharacter(character, scopedLineTokens, column - scopedLineTokens.firstCharOffset);
|
|
111
|
+
}
|
|
112
|
+
normalizeIndentation(str) {
|
|
113
|
+
return normalizeIndentation(str, this.indentSize, this.insertSpaces);
|
|
114
|
+
}
|
|
115
|
+
_getShouldAutoClose(languageId, autoCloseConfig, forQuotes) {
|
|
116
|
+
switch (autoCloseConfig) {
|
|
117
|
+
case 'beforeWhitespace':
|
|
118
|
+
return autoCloseBeforeWhitespace;
|
|
119
|
+
case 'languageDefined':
|
|
120
|
+
return this._getLanguageDefinedShouldAutoClose(languageId, forQuotes);
|
|
121
|
+
case 'always':
|
|
122
|
+
return autoCloseAlways;
|
|
123
|
+
case 'never':
|
|
124
|
+
return autoCloseNever;
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
_getLanguageDefinedShouldAutoClose(languageId, forQuotes) {
|
|
128
|
+
const autoCloseBeforeSet = this.languageConfigurationService.getLanguageConfiguration(languageId).getAutoCloseBeforeSet(forQuotes);
|
|
129
|
+
return c => autoCloseBeforeSet.indexOf(c) !== -1;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* Returns a visible column from a column.
|
|
133
|
+
* @see {@link CursorColumns}
|
|
134
|
+
*/
|
|
135
|
+
visibleColumnFromColumn(model, position) {
|
|
136
|
+
return CursorColumns.visibleColumnFromColumn(model.getLineContent(position.lineNumber), position.column, this.tabSize);
|
|
137
|
+
}
|
|
138
|
+
/**
|
|
139
|
+
* Returns a visible column from a column.
|
|
140
|
+
* @see {@link CursorColumns}
|
|
141
|
+
*/
|
|
142
|
+
columnFromVisibleColumn(model, lineNumber, visibleColumn) {
|
|
143
|
+
const result = CursorColumns.columnFromVisibleColumn(model.getLineContent(lineNumber), visibleColumn, this.tabSize);
|
|
144
|
+
const minColumn = model.getLineMinColumn(lineNumber);
|
|
145
|
+
if (result < minColumn) {
|
|
146
|
+
return minColumn;
|
|
147
|
+
}
|
|
148
|
+
const maxColumn = model.getLineMaxColumn(lineNumber);
|
|
149
|
+
if (result > maxColumn) {
|
|
150
|
+
return maxColumn;
|
|
151
|
+
}
|
|
152
|
+
return result;
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
class CursorState {
|
|
156
|
+
static fromModelState(modelState) {
|
|
157
|
+
return new PartialModelCursorState(modelState);
|
|
158
|
+
}
|
|
159
|
+
static fromViewState(viewState) {
|
|
160
|
+
return new PartialViewCursorState(viewState);
|
|
161
|
+
}
|
|
162
|
+
static fromModelSelection(modelSelection) {
|
|
163
|
+
const selection = Selection.liftSelection(modelSelection);
|
|
164
|
+
const modelState = new SingleCursorState(Range.fromPositions(selection.getSelectionStart()), 0 /* SelectionStartKind.Simple */, 0, selection.getPosition(), 0);
|
|
165
|
+
return CursorState.fromModelState(modelState);
|
|
166
|
+
}
|
|
167
|
+
static fromModelSelections(modelSelections) {
|
|
168
|
+
const states = [];
|
|
169
|
+
for (let i = 0, len = modelSelections.length; i < len; i++) {
|
|
170
|
+
states[i] = this.fromModelSelection(modelSelections[i]);
|
|
171
|
+
}
|
|
172
|
+
return states;
|
|
173
|
+
}
|
|
174
|
+
constructor(modelState, viewState) {
|
|
175
|
+
this._cursorStateBrand = undefined;
|
|
176
|
+
this.modelState = modelState;
|
|
177
|
+
this.viewState = viewState;
|
|
178
|
+
}
|
|
179
|
+
equals(other) {
|
|
180
|
+
return (this.viewState.equals(other.viewState) && this.modelState.equals(other.modelState));
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
class PartialModelCursorState {
|
|
184
|
+
constructor(modelState) {
|
|
185
|
+
this.modelState = modelState;
|
|
186
|
+
this.viewState = null;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
class PartialViewCursorState {
|
|
190
|
+
constructor(viewState) {
|
|
191
|
+
this.modelState = null;
|
|
192
|
+
this.viewState = viewState;
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
/**
|
|
196
|
+
* Represents the cursor state on either the model or on the view model.
|
|
197
|
+
*/
|
|
198
|
+
class SingleCursorState {
|
|
199
|
+
constructor(selectionStart, selectionStartKind, selectionStartLeftoverVisibleColumns, position, leftoverVisibleColumns) {
|
|
200
|
+
this.selectionStart = selectionStart;
|
|
201
|
+
this.selectionStartKind = selectionStartKind;
|
|
202
|
+
this.selectionStartLeftoverVisibleColumns = selectionStartLeftoverVisibleColumns;
|
|
203
|
+
this.position = position;
|
|
204
|
+
this.leftoverVisibleColumns = leftoverVisibleColumns;
|
|
205
|
+
this._singleCursorStateBrand = undefined;
|
|
206
|
+
this.selection = SingleCursorState._computeSelection(this.selectionStart, this.position);
|
|
207
|
+
}
|
|
208
|
+
equals(other) {
|
|
209
|
+
return (this.selectionStartLeftoverVisibleColumns === other.selectionStartLeftoverVisibleColumns
|
|
210
|
+
&& this.leftoverVisibleColumns === other.leftoverVisibleColumns
|
|
211
|
+
&& this.selectionStartKind === other.selectionStartKind
|
|
212
|
+
&& this.position.equals(other.position)
|
|
213
|
+
&& this.selectionStart.equalsRange(other.selectionStart));
|
|
214
|
+
}
|
|
215
|
+
hasSelection() {
|
|
216
|
+
return (!this.selection.isEmpty() || !this.selectionStart.isEmpty());
|
|
217
|
+
}
|
|
218
|
+
move(inSelectionMode, lineNumber, column, leftoverVisibleColumns) {
|
|
219
|
+
if (inSelectionMode) {
|
|
220
|
+
// move just position
|
|
221
|
+
return new SingleCursorState(this.selectionStart, this.selectionStartKind, this.selectionStartLeftoverVisibleColumns, new Position(lineNumber, column), leftoverVisibleColumns);
|
|
222
|
+
}
|
|
223
|
+
else {
|
|
224
|
+
// move everything
|
|
225
|
+
return new SingleCursorState(new Range(lineNumber, column, lineNumber, column), 0 /* SelectionStartKind.Simple */, leftoverVisibleColumns, new Position(lineNumber, column), leftoverVisibleColumns);
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
static _computeSelection(selectionStart, position) {
|
|
229
|
+
if (selectionStart.isEmpty() || !position.isBeforeOrEqual(selectionStart.getStartPosition())) {
|
|
230
|
+
return Selection.fromPositions(selectionStart.getStartPosition(), position);
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
return Selection.fromPositions(selectionStart.getEndPosition(), position);
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
class EditOperationResult {
|
|
238
|
+
constructor(type, commands, opts) {
|
|
239
|
+
this._editOperationResultBrand = undefined;
|
|
240
|
+
this.type = type;
|
|
241
|
+
this.commands = commands;
|
|
242
|
+
this.shouldPushStackElementBefore = opts.shouldPushStackElementBefore;
|
|
243
|
+
this.shouldPushStackElementAfter = opts.shouldPushStackElementAfter;
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
function isQuote(ch) {
|
|
247
|
+
return (ch === '\'' || ch === '"' || ch === '`');
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
export { CursorConfiguration, CursorState, EditOperationResult, PartialModelCursorState, PartialViewCursorState, SingleCursorState, isQuote };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
class CursorContext {
|
|
6
|
+
constructor(model, viewModel, coordinatesConverter, cursorConfig) {
|
|
7
|
+
this._cursorContextBrand = undefined;
|
|
8
|
+
this.model = model;
|
|
9
|
+
this.viewModel = viewModel;
|
|
10
|
+
this.coordinatesConverter = coordinatesConverter;
|
|
11
|
+
this.cursorConfig = cursorConfig;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export { CursorContext };
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
import { firstNonWhitespaceIndex, getLeftDeleteOffset } from '../../../base/common/strings.js';
|
|
2
|
+
import { ReplaceCommand } from '../commands/replaceCommand.js';
|
|
3
|
+
import { isQuote, EditOperationResult } from '../cursorCommon.js';
|
|
4
|
+
import { CursorColumns } from '../core/cursorColumns.js';
|
|
5
|
+
import { MoveOperations } from './cursorMoveOperations.js';
|
|
6
|
+
import { Range } from '../core/range.js';
|
|
7
|
+
import { Position } from '../core/position.js';
|
|
8
|
+
|
|
9
|
+
/*---------------------------------------------------------------------------------------------
|
|
10
|
+
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
11
|
+
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
12
|
+
*--------------------------------------------------------------------------------------------*/
|
|
13
|
+
class DeleteOperations {
|
|
14
|
+
static deleteRight(prevEditOperationType, config, model, selections) {
|
|
15
|
+
const commands = [];
|
|
16
|
+
let shouldPushStackElementBefore = (prevEditOperationType !== 3 /* EditOperationType.DeletingRight */);
|
|
17
|
+
for (let i = 0, len = selections.length; i < len; i++) {
|
|
18
|
+
const selection = selections[i];
|
|
19
|
+
const deleteSelection = this.getDeleteRightRange(selection, model, config);
|
|
20
|
+
if (deleteSelection.isEmpty()) {
|
|
21
|
+
// Probably at end of file => ignore
|
|
22
|
+
commands[i] = null;
|
|
23
|
+
continue;
|
|
24
|
+
}
|
|
25
|
+
if (deleteSelection.startLineNumber !== deleteSelection.endLineNumber) {
|
|
26
|
+
shouldPushStackElementBefore = true;
|
|
27
|
+
}
|
|
28
|
+
commands[i] = new ReplaceCommand(deleteSelection, '');
|
|
29
|
+
}
|
|
30
|
+
return [shouldPushStackElementBefore, commands];
|
|
31
|
+
}
|
|
32
|
+
static getDeleteRightRange(selection, model, config) {
|
|
33
|
+
if (!selection.isEmpty()) {
|
|
34
|
+
return selection;
|
|
35
|
+
}
|
|
36
|
+
const position = selection.getPosition();
|
|
37
|
+
const rightOfPosition = MoveOperations.right(config, model, position);
|
|
38
|
+
if (config.trimWhitespaceOnDelete && rightOfPosition.lineNumber !== position.lineNumber) {
|
|
39
|
+
// Smart line join (deleting leading whitespace) is on
|
|
40
|
+
// (and) Delete is happening at the end of a line
|
|
41
|
+
const currentLineHasContent = (model.getLineFirstNonWhitespaceColumn(position.lineNumber) > 0);
|
|
42
|
+
const firstNonWhitespaceColumn = model.getLineFirstNonWhitespaceColumn(rightOfPosition.lineNumber);
|
|
43
|
+
if (currentLineHasContent && firstNonWhitespaceColumn > 0) {
|
|
44
|
+
// The next line has content
|
|
45
|
+
return new Range(rightOfPosition.lineNumber, firstNonWhitespaceColumn, position.lineNumber, position.column);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
return new Range(rightOfPosition.lineNumber, rightOfPosition.column, position.lineNumber, position.column);
|
|
49
|
+
}
|
|
50
|
+
static isAutoClosingPairDelete(autoClosingDelete, autoClosingBrackets, autoClosingQuotes, autoClosingPairsOpen, model, selections, autoClosedCharacters) {
|
|
51
|
+
if (autoClosingBrackets === 'never' && autoClosingQuotes === 'never') {
|
|
52
|
+
return false;
|
|
53
|
+
}
|
|
54
|
+
if (autoClosingDelete === 'never') {
|
|
55
|
+
return false;
|
|
56
|
+
}
|
|
57
|
+
for (let i = 0, len = selections.length; i < len; i++) {
|
|
58
|
+
const selection = selections[i];
|
|
59
|
+
const position = selection.getPosition();
|
|
60
|
+
if (!selection.isEmpty()) {
|
|
61
|
+
return false;
|
|
62
|
+
}
|
|
63
|
+
const lineText = model.getLineContent(position.lineNumber);
|
|
64
|
+
if (position.column < 2 || position.column >= lineText.length + 1) {
|
|
65
|
+
return false;
|
|
66
|
+
}
|
|
67
|
+
const character = lineText.charAt(position.column - 2);
|
|
68
|
+
const autoClosingPairCandidates = autoClosingPairsOpen.get(character);
|
|
69
|
+
if (!autoClosingPairCandidates) {
|
|
70
|
+
return false;
|
|
71
|
+
}
|
|
72
|
+
if (isQuote(character)) {
|
|
73
|
+
if (autoClosingQuotes === 'never') {
|
|
74
|
+
return false;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
else {
|
|
78
|
+
if (autoClosingBrackets === 'never') {
|
|
79
|
+
return false;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
const afterCharacter = lineText.charAt(position.column - 1);
|
|
83
|
+
let foundAutoClosingPair = false;
|
|
84
|
+
for (const autoClosingPairCandidate of autoClosingPairCandidates) {
|
|
85
|
+
if (autoClosingPairCandidate.open === character && autoClosingPairCandidate.close === afterCharacter) {
|
|
86
|
+
foundAutoClosingPair = true;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
if (!foundAutoClosingPair) {
|
|
90
|
+
return false;
|
|
91
|
+
}
|
|
92
|
+
// Must delete the pair only if it was automatically inserted by the editor
|
|
93
|
+
if (autoClosingDelete === 'auto') {
|
|
94
|
+
let found = false;
|
|
95
|
+
for (let j = 0, lenJ = autoClosedCharacters.length; j < lenJ; j++) {
|
|
96
|
+
const autoClosedCharacter = autoClosedCharacters[j];
|
|
97
|
+
if (position.lineNumber === autoClosedCharacter.startLineNumber && position.column === autoClosedCharacter.startColumn) {
|
|
98
|
+
found = true;
|
|
99
|
+
break;
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
if (!found) {
|
|
103
|
+
return false;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
return true;
|
|
108
|
+
}
|
|
109
|
+
static _runAutoClosingPairDelete(config, model, selections) {
|
|
110
|
+
const commands = [];
|
|
111
|
+
for (let i = 0, len = selections.length; i < len; i++) {
|
|
112
|
+
const position = selections[i].getPosition();
|
|
113
|
+
const deleteSelection = new Range(position.lineNumber, position.column - 1, position.lineNumber, position.column + 1);
|
|
114
|
+
commands[i] = new ReplaceCommand(deleteSelection, '');
|
|
115
|
+
}
|
|
116
|
+
return [true, commands];
|
|
117
|
+
}
|
|
118
|
+
static deleteLeft(prevEditOperationType, config, model, selections, autoClosedCharacters) {
|
|
119
|
+
if (this.isAutoClosingPairDelete(config.autoClosingDelete, config.autoClosingBrackets, config.autoClosingQuotes, config.autoClosingPairs.autoClosingPairsOpenByEnd, model, selections, autoClosedCharacters)) {
|
|
120
|
+
return this._runAutoClosingPairDelete(config, model, selections);
|
|
121
|
+
}
|
|
122
|
+
const commands = [];
|
|
123
|
+
let shouldPushStackElementBefore = (prevEditOperationType !== 2 /* EditOperationType.DeletingLeft */);
|
|
124
|
+
for (let i = 0, len = selections.length; i < len; i++) {
|
|
125
|
+
const deleteRange = DeleteOperations.getDeleteLeftRange(selections[i], model, config);
|
|
126
|
+
// Ignore empty delete ranges, as they have no effect
|
|
127
|
+
// They happen if the cursor is at the beginning of the file.
|
|
128
|
+
if (deleteRange.isEmpty()) {
|
|
129
|
+
commands[i] = null;
|
|
130
|
+
continue;
|
|
131
|
+
}
|
|
132
|
+
if (deleteRange.startLineNumber !== deleteRange.endLineNumber) {
|
|
133
|
+
shouldPushStackElementBefore = true;
|
|
134
|
+
}
|
|
135
|
+
commands[i] = new ReplaceCommand(deleteRange, '');
|
|
136
|
+
}
|
|
137
|
+
return [shouldPushStackElementBefore, commands];
|
|
138
|
+
}
|
|
139
|
+
static getDeleteLeftRange(selection, model, config) {
|
|
140
|
+
if (!selection.isEmpty()) {
|
|
141
|
+
return selection;
|
|
142
|
+
}
|
|
143
|
+
const position = selection.getPosition();
|
|
144
|
+
// Unintend when using tab stops and cursor is within indentation
|
|
145
|
+
if (config.useTabStops && position.column > 1) {
|
|
146
|
+
const lineContent = model.getLineContent(position.lineNumber);
|
|
147
|
+
const firstNonWhitespaceIndex$1 = firstNonWhitespaceIndex(lineContent);
|
|
148
|
+
const lastIndentationColumn = (firstNonWhitespaceIndex$1 === -1
|
|
149
|
+
? /* entire string is whitespace */ lineContent.length + 1
|
|
150
|
+
: firstNonWhitespaceIndex$1 + 1);
|
|
151
|
+
if (position.column <= lastIndentationColumn) {
|
|
152
|
+
const fromVisibleColumn = config.visibleColumnFromColumn(model, position);
|
|
153
|
+
const toVisibleColumn = CursorColumns.prevIndentTabStop(fromVisibleColumn, config.indentSize);
|
|
154
|
+
const toColumn = config.columnFromVisibleColumn(model, position.lineNumber, toVisibleColumn);
|
|
155
|
+
return new Range(position.lineNumber, toColumn, position.lineNumber, position.column);
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
return Range.fromPositions(DeleteOperations.getPositionAfterDeleteLeft(position, model), position);
|
|
159
|
+
}
|
|
160
|
+
static getPositionAfterDeleteLeft(position, model) {
|
|
161
|
+
if (position.column > 1) {
|
|
162
|
+
// Convert 1-based columns to 0-based offsets and back.
|
|
163
|
+
const idx = getLeftDeleteOffset(position.column - 1, model.getLineContent(position.lineNumber));
|
|
164
|
+
return position.with(undefined, idx + 1);
|
|
165
|
+
}
|
|
166
|
+
else if (position.lineNumber > 1) {
|
|
167
|
+
const newLine = position.lineNumber - 1;
|
|
168
|
+
return new Position(newLine, model.getLineMaxColumn(newLine));
|
|
169
|
+
}
|
|
170
|
+
else {
|
|
171
|
+
return position;
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
static cut(config, model, selections) {
|
|
175
|
+
const commands = [];
|
|
176
|
+
let lastCutRange = null;
|
|
177
|
+
selections.sort((a, b) => Position.compare(a.getStartPosition(), b.getEndPosition()));
|
|
178
|
+
for (let i = 0, len = selections.length; i < len; i++) {
|
|
179
|
+
const selection = selections[i];
|
|
180
|
+
if (selection.isEmpty()) {
|
|
181
|
+
if (config.emptySelectionClipboard) {
|
|
182
|
+
// This is a full line cut
|
|
183
|
+
const position = selection.getPosition();
|
|
184
|
+
let startLineNumber, startColumn, endLineNumber, endColumn;
|
|
185
|
+
if (position.lineNumber < model.getLineCount()) {
|
|
186
|
+
// Cutting a line in the middle of the model
|
|
187
|
+
startLineNumber = position.lineNumber;
|
|
188
|
+
startColumn = 1;
|
|
189
|
+
endLineNumber = position.lineNumber + 1;
|
|
190
|
+
endColumn = 1;
|
|
191
|
+
}
|
|
192
|
+
else if (position.lineNumber > 1 && lastCutRange?.endLineNumber !== position.lineNumber) {
|
|
193
|
+
// Cutting the last line & there are more than 1 lines in the model & a previous cut operation does not touch the current cut operation
|
|
194
|
+
startLineNumber = position.lineNumber - 1;
|
|
195
|
+
startColumn = model.getLineMaxColumn(position.lineNumber - 1);
|
|
196
|
+
endLineNumber = position.lineNumber;
|
|
197
|
+
endColumn = model.getLineMaxColumn(position.lineNumber);
|
|
198
|
+
}
|
|
199
|
+
else {
|
|
200
|
+
// Cutting the single line that the model contains
|
|
201
|
+
startLineNumber = position.lineNumber;
|
|
202
|
+
startColumn = 1;
|
|
203
|
+
endLineNumber = position.lineNumber;
|
|
204
|
+
endColumn = model.getLineMaxColumn(position.lineNumber);
|
|
205
|
+
}
|
|
206
|
+
const deleteSelection = new Range(startLineNumber, startColumn, endLineNumber, endColumn);
|
|
207
|
+
lastCutRange = deleteSelection;
|
|
208
|
+
if (!deleteSelection.isEmpty()) {
|
|
209
|
+
commands[i] = new ReplaceCommand(deleteSelection, '');
|
|
210
|
+
}
|
|
211
|
+
else {
|
|
212
|
+
commands[i] = null;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
else {
|
|
216
|
+
// Cannot cut empty selection
|
|
217
|
+
commands[i] = null;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
else {
|
|
221
|
+
commands[i] = new ReplaceCommand(selection, '');
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
return new EditOperationResult(0 /* EditOperationType.Other */, commands, {
|
|
225
|
+
shouldPushStackElementBefore: true,
|
|
226
|
+
shouldPushStackElementAfter: true
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export { DeleteOperations };
|