@prisma/orm-toolchain 8.0.0-rc.20-dev.1 → 8.0.0-rc.20-dev.3

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.
@@ -12,7 +12,7 @@ import { EMPTY_GENERATOR_FUNCTIONS } from "@prisma/orm-framework/components/comp
12
12
  import { fileURLToPath, pathToFileURL } from "node:url";
13
13
  import { normalize as normalize$1 } from "node:path";
14
14
  import { format, resolveFormatOptions } from "@prisma/orm-framework/psl-parser/format";
15
- import { EMPTY_DATA_TYPES, assembleAttributeSpecs, blockSpecContext, blockSpecFactoryOf, buildSymbolTable, contributedTypeOf, createBinder, entityReference, findBlockDescriptor, isNamespaceLike, isPrismaNextSchema, isPslIdentifier, matchesSelector, memberEntries, renameLegacyDirective, typeReferenceNode } from "@prisma/orm-framework/psl-parser";
15
+ import { EMPTY_DATA_TYPES, assembleAttributeSpecs, blockSpecContext, blockSpecFactoryOf, buildSymbolTable, contributedTypeOf, createBinder, entityReference, findBlockDescriptor, groupedTypeLabel, isNamespaceLike, isPrismaNextSchema, isPslIdentifier, matchesSelector, memberEntries, renameLegacyDirective, typeReferenceNode } from "@prisma/orm-framework/psl-parser";
16
16
  import { CompletionItemKind, CompletionItemTag, ConnectionError, ConnectionErrors, DiagnosticSeverity, DidChangeWatchedFilesNotification, DocumentDiagnosticReportKind, FoldingRangeKind, InsertTextFormat, LSPErrorCodes, MarkupKind, ProposedFeatures, RegistrationRequest, ResponseError, SemanticTokenModifiers, SemanticTokenTypes, TextDocumentSyncKind, UnregistrationRequest, createConnection } from "vscode-languageserver";
17
17
  import { TextDocument } from "vscode-languageserver-textdocument";
18
18
  import { ArrayLiteralAst, AttributeArgAst, AttributeArgListAst, BooleanLiteralExprAst, CompositeTypeDeclarationAst, FieldAttributeAst, FieldDeclarationAst, FunctionCallAst, GenericBlockDeclarationAst, IdentifierAst, KeyValuePairAst, MixinDeclarationAst, MixinInclusionAst, ModelAttributeAst, ModelDeclarationAst, NamespaceDeclarationAst, NumberLiteralExprAst, ObjectLiteralExprAst, PathExprAst, PslSources, StringLiteralExprAst, SyntaxNode, SyntaxToken, TaggedLiteralExprAst, TypesBlockAst, any, filterChildren, isTrivia, nonTriviaSibling, parse, skipTriviaToken } from "@prisma/orm-framework/psl-parser/syntax";
@@ -2036,7 +2036,7 @@ function renderSignatureLabel(name, signature, params) {
2036
2036
  if (index > 0) label += ", ";
2037
2037
  const positional = index < (signature.positional?.length ?? 0);
2038
2038
  const optional = "optional" in param.type && param.type.optional === true;
2039
- const typeLabel = optional && param.type.label.includes(" | ") ? `(${param.type.label})` : param.type.label;
2039
+ const typeLabel = optional ? groupedTypeLabel(param.type) : param.type.label;
2040
2040
  const text = positional ? `${typeLabel}${optional ? "?" : ""}` : namedParameterText(param.key, param.type);
2041
2041
  const start = label.length;
2042
2042
  label += text;
@@ -3970,4 +3970,4 @@ function startServer(streams) {
3970
3970
  //#endregion
3971
3971
  export { startServer };
3972
3972
 
3973
- //# sourceMappingURL=exports-CKgwcXbp.mjs.map
3973
+ //# sourceMappingURL=exports-Dc7BjdfY.mjs.map