@angular/language-service 20.2.0-next.0 → 20.2.0-next.1

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/api_bundle.js CHANGED
@@ -16,7 +16,7 @@ var __copyProps = (to, from, except, desc) => {
16
16
  };
17
17
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
18
 
19
- // bazel-out/k8-fastbuild/bin/packages/language-service/api.js
19
+ // packages/language-service/api.ts
20
20
  var api_exports = {};
21
21
  __export(api_exports, {
22
22
  isNgLanguageService: () => isNgLanguageService
package/api_bundle.js.map CHANGED
@@ -1,7 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["api.ts"],
4
- "sourcesContent": ["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the language service package.\n */\n\nimport ts from 'typescript';\n\nexport interface PluginConfig {\n /**\n * If true, return only Angular results. Otherwise, return Angular + TypeScript\n * results.\n */\n angularOnly: boolean;\n /**\n * If true, enable `strictTemplates` in Angular compiler options regardless\n * of its value in tsconfig.json.\n */\n forceStrictTemplates?: true;\n\n /**\n * If false, disables parsing control flow blocks in the compiler. Should be used only when older\n * versions of Angular that do not support blocks (pre-v17) used with the language service.\n */\n enableBlockSyntax?: false;\n\n /**\n * Version of `@angular/core` that was detected in the user's workspace.\n */\n angularCoreVersion?: string;\n\n /**\n * If false, disables parsing of `@let` declarations in the compiler.\n */\n enableLetSyntax?: false;\n\n /**\n * Whether selectorless is enabled.\n */\n enableSelectorless?: true;\n\n /**\n * A list of diagnostic codes that should be supressed in the language service.\n */\n suppressAngularDiagnosticCodes?: number[];\n}\n\nexport type GetTcbResponse = {\n /**\n * The filename of the SourceFile this typecheck block belongs to.\n * The filename is entirely opaque and unstable, useful only for debugging\n * purposes.\n */\n fileName: string;\n /** The content of the SourceFile this typecheck block belongs to. */\n content: string;\n /**\n * Spans over node(s) in the typecheck block corresponding to the\n * TS code generated for template node under the current cursor position.\n *\n * When the cursor position is over a source for which there is no generated\n * code, `selections` is empty.\n */\n selections: ts.TextSpan[];\n};\n\nexport type GetComponentLocationsForTemplateResponse = ts.DocumentSpan[];\nexport type GetTemplateLocationForComponentResponse = ts.DocumentSpan | undefined;\n\n/**\n * Function that can be invoked to show progress when computing\n * refactoring edits.\n *\n * Useful for refactorings which take a long time to compute edits for.\n */\nexport type ApplyRefactoringProgressFn = (percentage: number, updateMessage: string) => void;\n\n/** Interface describing the result for computing edits of a refactoring. */\nexport interface ApplyRefactoringResult extends Omit<ts.RefactorEditInfo, 'notApplicableReason'> {\n errorMessage?: string;\n warningMessage?: string;\n}\n\n/**\n * `NgLanguageService` describes an instance of an Angular language service,\n * whose API surface is a strict superset of TypeScript's language service.\n */\nexport interface NgLanguageService extends ts.LanguageService {\n getTcb(fileName: string, position: number): GetTcbResponse | undefined;\n getComponentLocationsForTemplate(fileName: string): GetComponentLocationsForTemplateResponse;\n getTemplateLocationForComponent(\n fileName: string,\n position: number,\n ): GetTemplateLocationForComponentResponse;\n getTypescriptLanguageService(): ts.LanguageService;\n\n applyRefactoring(\n fileName: string,\n positionOrRange: number | ts.TextRange,\n refactorName: string,\n reportProgress: ApplyRefactoringProgressFn,\n ): Promise<ApplyRefactoringResult | undefined>;\n\n hasCodeFixesForErrorCode(errorCode: number): boolean;\n\n getTokenTypeFromClassification(classification: number): number | undefined;\n getTokenModifierFromClassification(classification: number): number;\n}\n\nexport function isNgLanguageService(\n ls: ts.LanguageService | NgLanguageService,\n): ls is NgLanguageService {\n return 'getTcb' in ls;\n}\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;AAAA;;;;;AAqHM,SAAU,oBACd,IAA0C;AAE1C,SAAO,YAAY;AACrB;",
4
+ "mappings": ";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAqHO,SAAS,oBACd,IACyB;AACzB,SAAO,YAAY;AACrB;",
6
5
  "names": []
7
6
  }