unplugin-isolated-decl 0.13.9 → 0.13.10

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/esbuild.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import "./transformer-CiAWE027.js";
2
- import { IsolatedDecl } from "./src-B5I0aiDn.js";
2
+ import { IsolatedDecl } from "./src-DVArCSR0.js";
3
3
 
4
4
  //#region src/esbuild.ts
5
5
  /**
package/dist/farm.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import "./transformer-CiAWE027.js";
2
- import { IsolatedDecl } from "./src-B5I0aiDn.js";
2
+ import { IsolatedDecl } from "./src-DVArCSR0.js";
3
3
 
4
4
  //#region src/farm.ts
5
5
  /**
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { type UnpluginInstance } from "unplugin";
2
2
  import { type Options } from "./core/options.js";
3
- export { Options };
3
+ export type { Options };
4
4
  /**
5
5
  * The main unplugin instance.
6
6
  */
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
1
  import "./transformer-CiAWE027.js";
2
- import { IsolatedDecl } from "./src-B5I0aiDn.js";
2
+ import { IsolatedDecl } from "./src-DVArCSR0.js";
3
3
 
4
4
  export { IsolatedDecl };
package/dist/rolldown.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import "./transformer-CiAWE027.js";
2
- import { IsolatedDecl } from "./src-B5I0aiDn.js";
2
+ import { IsolatedDecl } from "./src-DVArCSR0.js";
3
3
 
4
4
  //#region src/rolldown.ts
5
5
  /**
package/dist/rollup.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import "./transformer-CiAWE027.js";
2
- import { IsolatedDecl } from "./src-B5I0aiDn.js";
2
+ import { IsolatedDecl } from "./src-DVArCSR0.js";
3
3
 
4
4
  //#region src/rollup.ts
5
5
  /**
@@ -198,8 +198,14 @@ const IsolatedDecl = createUnplugin((rawOptions = {}) => {
198
198
  imports,
199
199
  map
200
200
  });
201
- const importsInDts = filterImports(program);
202
- for (const { source } of importsInDts) {
201
+ const typeImports = program.body.filter((node) => {
202
+ if (!("source" in node) || !node.source) return false;
203
+ if ("importKind" in node && node.importKind === "type") return true;
204
+ if ("exportKind" in node && node.exportKind === "type") return true;
205
+ if (node.type === "ImportDeclaration") return !!node.specifiers && node.specifiers.every((spec) => spec.type === "ImportSpecifier" && spec.importKind === "type");
206
+ return node.type === "ExportNamedDeclaration" && node.specifiers && node.specifiers.every((spec) => spec.exportKind === "type");
207
+ });
208
+ for (const { source } of typeImports) {
203
209
  const resolved = (await resolve(context, source.value, id))?.id;
204
210
  if (resolved && filter(resolved) && !outputFiles[stripExt(resolved)]) {
205
211
  let source$1;
package/dist/vite.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import "./transformer-CiAWE027.js";
2
- import { IsolatedDecl } from "./src-B5I0aiDn.js";
2
+ import { IsolatedDecl } from "./src-DVArCSR0.js";
3
3
 
4
4
  //#region src/vite.ts
5
5
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "unplugin-isolated-decl",
3
- "version": "0.13.9",
3
+ "version": "0.13.10",
4
4
  "description": "A blazing-fast tool for generating isolated declarations.",
5
5
  "type": "module",
6
6
  "keywords": [
@@ -63,16 +63,16 @@
63
63
  "dependencies": {
64
64
  "debug": "^4.4.0",
65
65
  "magic-string": "^0.30.17",
66
- "oxc-parser": "^0.65.0",
67
- "oxc-transform": "^0.65.0",
66
+ "oxc-parser": "^0.66.0",
67
+ "oxc-transform": "^0.66.0",
68
68
  "unplugin": "^2.3.2",
69
69
  "unplugin-utils": "^0.2.4"
70
70
  },
71
71
  "devDependencies": {
72
72
  "@farmfe/core": "^1.7.4",
73
- "@oxc-project/types": "^0.65.0",
73
+ "@oxc-project/types": "^0.66.0",
74
74
  "@rollup/plugin-alias": "^5.1.1",
75
- "@swc/core": "^1.11.21",
75
+ "@swc/core": "^1.11.22",
76
76
  "@sxzz/eslint-config": "^6.1.2",
77
77
  "@sxzz/prettier-config": "^2.2.1",
78
78
  "@sxzz/test-utils": "^0.5.5",
@@ -86,11 +86,11 @@
86
86
  "rolldown": "^1.0.0-beta.8",
87
87
  "rollup": "^4.40.0",
88
88
  "tinyglobby": "^0.2.13",
89
- "tsdown": "^0.9.5",
89
+ "tsdown": "^0.9.6",
90
90
  "tsx": "^4.19.3",
91
91
  "typescript": "^5.8.3",
92
92
  "unplugin-oxc": "^0.3.5",
93
- "vite": "^6.3.2",
93
+ "vite": "^6.3.3",
94
94
  "vitest": "^3.1.2"
95
95
  },
96
96
  "engines": {