@vue.ts/complex-types 1.0.0-beta.4 → 1.0.0-beta.5

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/astro.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
 
3
3
  //#region src/astro.d.ts
4
4
  declare const _default: (options: Options) => {
package/dist/astro.js CHANGED
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createVitePlugin } from "unplugin";
3
3
 
4
4
  //#region src/astro.ts
package/dist/esbuild.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as esbuild0 from "esbuild";
4
4
 
package/dist/esbuild.js CHANGED
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createEsbuildPlugin } from "unplugin";
3
3
 
4
4
  //#region src/esbuild.ts
package/dist/farm.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as _farmfe_core0 from "@farmfe/core";
4
4
 
package/dist/farm.js CHANGED
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createFarmPlugin } from "unplugin";
3
3
 
4
4
  //#region src/farm.ts
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import * as unplugin0 from "unplugin";
3
3
  import { UnpluginFactory } from "unplugin";
4
4
 
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- import { src_default, unplugin, unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { src_default, unplugin, unpluginFactory } from "./src-DMXUChWi.js";
2
2
 
3
3
  export { src_default as default, unplugin, unpluginFactory };
package/dist/nuxt.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as _nuxt_schema0 from "@nuxt/schema";
4
4
 
package/dist/nuxt.js CHANGED
@@ -1,6 +1,6 @@
1
- import "./src-koVD0EYI.js";
2
- import { vite_default } from "./vite-DFtk2L0c.js";
3
- import { webpack_default } from "./webpack-BWJ3ulvy.js";
1
+ import "./src-DMXUChWi.js";
2
+ import { vite_default } from "./vite-IY7LTXSx.js";
3
+ import { webpack_default } from "./webpack-CoqBNEcT.js";
4
4
  import { addVitePlugin, addWebpackPlugin, defineNuxtModule } from "@nuxt/kit";
5
5
 
6
6
  //#region src/nuxt.ts
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as rolldown0 from "rolldown";
4
4
 
package/dist/rolldown.js CHANGED
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createRolldownPlugin } from "unplugin";
3
3
 
4
4
  //#region src/rolldown.ts
package/dist/rollup.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as rollup0 from "rollup";
4
4
 
package/dist/rollup.js CHANGED
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createRollupPlugin } from "unplugin";
3
3
 
4
4
  //#region src/rollup.ts
package/dist/rspack.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
 
4
4
  //#region src/rspack.d.ts
package/dist/rspack.js CHANGED
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createRspackPlugin } from "unplugin";
3
3
 
4
4
  //#region src/rspack.ts
@@ -33,12 +33,12 @@ var Printer = class {
33
33
  containsUndefined(type) {
34
34
  return type.isUnion() ? type.types.some((t) => t.flags & ts.TypeFlags.Undefined) : !!(type.flags & ts.TypeFlags.Undefined);
35
35
  }
36
- printConditionTypeNode(type) {
36
+ printConditionType(type, inner) {
37
37
  const decl = type.root.node;
38
38
  const { trueType, falseType } = decl;
39
39
  const trueTypeNode = this.checker.getTypeAtLocation(trueType);
40
40
  const falseTypeNode = this.checker.getTypeAtLocation(falseType);
41
- return `${this.printType(trueTypeNode)} | ${this.printType(falseTypeNode)}`;
41
+ return `${this.printType(trueTypeNode, inner)} | ${this.printType(falseTypeNode, inner)}`;
42
42
  }
43
43
  printPrimitiveType(type) {
44
44
  if (type.flags & ts.TypeFlags.BooleanLiteral) return "boolean";
@@ -75,7 +75,7 @@ var Printer = class {
75
75
  return Object.keys(props).length > 0 ? `{\n${parts.join("\n")}\n}` : "";
76
76
  } else if (type.isLiteral() || type.flags & ts.TypeFlags.BooleanLiteral || type.flags & ts.TypeFlags.String || type.flags & ts.TypeFlags.Number || type.flags & ts.TypeFlags.BigInt || type.flags & ts.TypeFlags.Any || type.flags & ts.TypeFlags.Unknown || type.flags & ts.TypeFlags.Null) return this.printPrimitiveType(type);
77
77
  else if (type.flags & ts.TypeFlags.Undefined) return "";
78
- else if (type.flags & ts.TypeFlags.Conditional) return this.printConditionTypeNode(type);
78
+ else if (type.flags & ts.TypeFlags.Conditional) return this.printConditionType(type, inner);
79
79
  else if (type.isTypeParameter()) {
80
80
  const symbol = type.getSymbol();
81
81
  const decl = symbol?.declarations?.[0];
@@ -83,7 +83,7 @@ var Printer = class {
83
83
  const ref = ts.getEffectiveConstraintOfTypeParameter(decl);
84
84
  if (!ref) return "";
85
85
  const refType = this.checker.getTypeAtLocation(ref);
86
- return this.printType(refType);
86
+ return this.printType(refType, inner);
87
87
  }
88
88
  return this.typeToString(type);
89
89
  }
@@ -15,7 +15,7 @@ declare class Printer {
15
15
  private typeToString;
16
16
  private printUnionOrIntersection;
17
17
  private containsUndefined;
18
- private printConditionTypeNode;
18
+ private printConditionType;
19
19
  private printPrimitiveType;
20
20
  private printType;
21
21
  printPropsTypeArg(node: ts.Node): string;
package/dist/types.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- import { Options, ResolvedOptions, TransformOptions, Transformer, Transformers, ValidTransforms } from "./types-WYBg4JEW.js";
1
+ import { Options, ResolvedOptions, TransformOptions, Transformer, Transformers, ValidTransforms } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  export { Options, ResolvedOptions, TransformOptions, Transformer, Transformers, ValidTransforms };
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createVitePlugin } from "unplugin";
3
3
 
4
4
  //#region src/vite.ts
package/dist/vite.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as vite0 from "vite";
4
4
 
package/dist/vite.js CHANGED
@@ -1,4 +1,4 @@
1
- import "./src-koVD0EYI.js";
2
- import { vite_default } from "./vite-DFtk2L0c.js";
1
+ import "./src-DMXUChWi.js";
2
+ import { vite_default } from "./vite-IY7LTXSx.js";
3
3
 
4
4
  export { vite_default as default };
@@ -1,4 +1,4 @@
1
- import { unpluginFactory } from "./src-koVD0EYI.js";
1
+ import { unpluginFactory } from "./src-DMXUChWi.js";
2
2
  import { createWebpackPlugin } from "unplugin";
3
3
 
4
4
  //#region src/webpack.ts
package/dist/webpack.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Options } from "./types-WYBg4JEW.js";
1
+ import { Options } from "./types-BRRPmDgG.js";
2
2
  import "./types-u_Hr5uXA.js";
3
3
  import * as webpack0 from "webpack";
4
4
 
package/dist/webpack.js CHANGED
@@ -1,4 +1,4 @@
1
- import "./src-koVD0EYI.js";
2
- import { webpack_default } from "./webpack-BWJ3ulvy.js";
1
+ import "./src-DMXUChWi.js";
2
+ import { webpack_default } from "./webpack-CoqBNEcT.js";
3
3
 
4
4
  export { webpack_default as default };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue.ts/complex-types",
3
- "version": "1.0.0-beta.4",
3
+ "version": "1.0.0-beta.5",
4
4
  "author": "Ray <i@mk1.io> (@so1ve)",
5
5
  "type": "module",
6
6
  "description": "Resolve complex types in Vue SFCs.",
@@ -66,8 +66,8 @@
66
66
  "defu": "^6.1.4",
67
67
  "magic-string": "^0.30.17",
68
68
  "unplugin": "^2.3.5",
69
- "@vue.ts/language": "1.0.0-beta.4",
70
- "@vue.ts/shared": "1.0.0-beta.4"
69
+ "@vue.ts/language": "1.0.0-beta.5",
70
+ "@vue.ts/shared": "1.0.0-beta.5"
71
71
  },
72
72
  "devDependencies": {
73
73
  "@nuxt/schema": "^4.0.2",