@stillwind/integration 0.12.0 → 0.13.0

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/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @stillwind/integration
2
2
 
3
+ ## 0.13.0
4
+
5
+ ### Patch Changes
6
+
7
+ - The Vite integration no longer stops a build when an import that Stillwind reads for type facts does not resolve. For example, a Svelte component with `import type { HTMLAttributes } from "svelte/elements"` now builds without an alias, although `svelte/elements` exports that path only under the `types` condition.
8
+
9
+ - Vite development servers now load fonts, images, and other files that the stylesheet references from a directory whose name contains `@`, `+`, or `:`, such as a scoped package like `@fontsource-variable/geist`. Before this fix, the development CSS referred to these files by URLs that Vite did not serve, so the page received an HTML response instead of the file. Production builds were not affected.
10
+
11
+ - Updated dependencies:
12
+ - @stillwind/config@0.13.0
13
+ - @stillwind/host@0.13.0
14
+ - @stillwind/native@0.13.0
15
+ - stillwind@0.13.0
16
+
3
17
  ## 0.12.0
4
18
 
5
19
  ### Patch Changes
@@ -1,4 +1,4 @@
1
- import { i as renderChunkStyles, r as createViteProject, t as createVitePlugins } from "../plugin-DiebeZNj.js";
1
+ import { i as renderChunkStyles, r as createViteProject, t as createVitePlugins } from "../plugin-Lp15OaLQ.js";
2
2
  import { registerDevelopmentCss } from "./development.js";
3
3
  import { randomUUID } from "node:crypto";
4
4
  import { fileURLToPath } from "node:url";
@@ -1,4 +1,4 @@
1
- import { r as createViteProject, t as createVitePlugins } from "../plugin-DiebeZNj.js";
1
+ import { r as createViteProject, t as createVitePlugins } from "../plugin-Lp15OaLQ.js";
2
2
  // src/fresh/manifest.ts
3
3
  /** Filters repeated static files for Fresh's move operation without changing the emitted manifest. */
4
4
  function registrationManifest(source) {
@@ -1,4 +1,4 @@
1
- import { r as createViteProject, t as createVitePlugins } from "../plugin-DiebeZNj.js";
1
+ import { r as createViteProject, t as createVitePlugins } from "../plugin-Lp15OaLQ.js";
2
2
  import { addPluginTemplate, defineNuxtModule } from "nuxt/kit";
3
3
  // src/nuxt/index.ts
4
4
  /**
@@ -337,10 +337,10 @@ function resourceReplacements(resources) {
337
337
  * Encodes an absolute file path as a Vite filesystem URL.
338
338
  *
339
339
  * @param file - Canonical absolute path, using either path separator spelling.
340
- * @returns An /@fs/ URL with each path segment encoded for use in stylesheet resource requests.
340
+ * @returns An /@fs/ URL for use in stylesheet resource requests.
341
341
  */
342
342
  function resourceUrl(file) {
343
- return `/@fs/${file.replaceAll("\\", "/").split("/").map((segment) => encodeURIComponent(segment).replaceAll("'", "%27").replaceAll("(", "%28").replaceAll(")", "%29")).join("/")}`;
343
+ return `/@fs/${encodeURI(file.replaceAll("\\", "/")).replaceAll("#", "%23").replaceAll("?", "%3F").replaceAll("'", "%27").replaceAll("(", "%28").replaceAll(")", "%29")}`;
344
344
  }
345
345
  /**
346
346
  * Extracts a readable identity from a bundler resolution without checking file existence or access.
@@ -927,7 +927,13 @@ async function compileProducer(compiler, settings, config, registry, code, id, c
927
927
  };
928
928
  const sourceDependencies = /* @__PURE__ */ new Set();
929
929
  const output = await compiler.compile(code, id, {
930
- resolve: (specifier, importer) => resolveServerSource((specifier, importer, options) => context.resolve(specifier, importer, options), specifier, importer),
930
+ resolve: async (specifier, importer) => {
931
+ try {
932
+ return await resolveServerSource((specifier, importer, options) => context.resolve(specifier, importer, options), specifier, importer);
933
+ } catch {
934
+ return null;
935
+ }
936
+ },
931
937
  read: (id) => readFile(cleanModuleId(id), "utf8"),
932
938
  describe: (resolvedId) => {
933
939
  const virtual = resolvedId.startsWith("\0") || resolvedId.startsWith("virtual:");
@@ -3038,4 +3044,4 @@ function compilerPlugin(project, transform, closed) {
3038
3044
  }
3039
3045
  export { renderChunkStyles as i, stillwind as n, createViteProject as r, createVitePlugins as t };
3040
3046
 
3041
- //# sourceMappingURL=plugin-DiebeZNj.js.map
3047
+ //# sourceMappingURL=plugin-Lp15OaLQ.js.map