@fluixi/compiler 1.0.0-alpha.94 → 1.0.0-alpha.95
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/LICENSE +1 -1
- package/dist/analyze/static-graph.cjs +1 -1
- package/dist/analyze/static-graph.mjs +1 -1
- package/dist/{babel-RJFQVFJW.mjs → babel-V33QLJBF.mjs} +4 -4
- package/dist/{chunk-DP2QDWWH.mjs → chunk-62F2LLBM.mjs} +1 -1
- package/dist/{chunk-E2RWTIYE.mjs → chunk-7GNSGUHK.mjs} +4 -89
- package/dist/{chunk-ZR2QHTEX.mjs → chunk-B64LVPTU.mjs} +2 -2
- package/dist/{chunk-HCCBEJEZ.mjs → chunk-C3AK5PBV.mjs} +1 -1
- package/dist/{chunk-HIZU7WI2.mjs → chunk-GLFUPZ27.mjs} +1 -1
- package/dist/chunk-HUABRVWB.mjs +92 -0
- package/dist/chunk-XCWP7WJG.mjs +584 -0
- package/dist/frontend/babel/index.cjs +1 -1
- package/dist/frontend/babel/index.mjs +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/integrations.cjs +3328 -3269
- package/dist/integrations.d.ts.map +1 -1
- package/dist/integrations.js +19 -8
- package/dist/integrations.mjs +85 -40
- package/dist/lower/compile-template.cjs +1 -1
- package/dist/lower/compile-template.mjs +1 -1
- package/dist/resolve/builtins.cjs +1 -1
- package/dist/resolve/builtins.mjs +1 -1
- package/dist/{server-fns-JLSTKWPS.mjs → server-fns-N3SDJXA7.mjs} +5 -4
- package/dist/{server-functions-BGY3RD4R.mjs → server-functions-LVS66Q4R.mjs} +3 -3
- package/dist/transform/index.cjs +31 -14
- package/dist/transform/index.mjs +31 -14
- package/dist/transform/styles.cjs +31 -13
- package/dist/transform/styles.d.cts +27 -1
- package/dist/transform/styles.d.ts +27 -1
- package/dist/transform/styles.d.ts.map +1 -1
- package/dist/transform/styles.js +45 -16
- package/dist/transform/styles.mjs +31 -13
- package/dist/transform/templates.cjs +30 -13
- package/dist/transform/templates.mjs +30 -13
- package/dist/{transform-GBP6Y4UI.mjs → transform-P4AETYV4.mjs} +12 -563
- package/dist/tsconfig.lib.tsbuildinfo +1 -1
- package/dist/vite-styles.cjs +66 -23
- package/dist/vite-styles.d.cts +16 -7
- package/dist/vite-styles.d.ts +16 -7
- package/dist/vite-styles.d.ts.map +1 -1
- package/dist/vite-styles.js +68 -25
- package/dist/vite-styles.mjs +78 -23
- package/package.json +4 -4
package/LICENSE
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @fluixi/compiler v1.0.0-alpha.
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
2
|
"use strict";
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @fluixi/compiler v1.0.0-alpha.
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
2
|
import {
|
|
3
3
|
analyzeStatic,
|
|
4
4
|
buildJsxIR,
|
|
@@ -10,13 +10,13 @@ import {
|
|
|
10
10
|
lowerTemplate,
|
|
11
11
|
resolveComponentSources,
|
|
12
12
|
shapeOf
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-B64LVPTU.mjs";
|
|
14
14
|
import {
|
|
15
15
|
CORE_CONTROL_FLOW,
|
|
16
16
|
ROUTER_COMPONENTS,
|
|
17
17
|
createComponentResolver
|
|
18
|
-
} from "./chunk-
|
|
19
|
-
import "./chunk-
|
|
18
|
+
} from "./chunk-C3AK5PBV.mjs";
|
|
19
|
+
import "./chunk-GLFUPZ27.mjs";
|
|
20
20
|
|
|
21
21
|
// src/frontend/babel/plugin.ts
|
|
22
22
|
import { declare } from "@babel/helper-plugin-utils";
|
|
@@ -1,91 +1,7 @@
|
|
|
1
|
-
/*! @fluixi/compiler v1.0.0-alpha.
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
var semicolon = ";".charCodeAt(0);
|
|
6
|
-
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
7
|
-
var intToChar = new Uint8Array(64);
|
|
8
|
-
var charToInt = new Uint8Array(128);
|
|
9
|
-
for (let i = 0; i < chars.length; i++) {
|
|
10
|
-
const c = chars.charCodeAt(i);
|
|
11
|
-
intToChar[i] = c;
|
|
12
|
-
charToInt[c] = i;
|
|
13
|
-
}
|
|
14
|
-
function encodeInteger(builder, num) {
|
|
15
|
-
do {
|
|
16
|
-
let clamped = num & 31;
|
|
17
|
-
num >>>= 5;
|
|
18
|
-
if (num > 0) clamped |= 32;
|
|
19
|
-
builder.write(intToChar[clamped]);
|
|
20
|
-
} while (num > 0);
|
|
21
|
-
}
|
|
22
|
-
function encodeSign(num) {
|
|
23
|
-
return num < 0 ? -num << 1 | 1 : num << 1;
|
|
24
|
-
}
|
|
25
|
-
var bufLength = 1024 * 16;
|
|
26
|
-
var td = typeof TextDecoder !== "undefined" ? /* @__PURE__ */ new TextDecoder() : typeof Buffer !== "undefined" ? {
|
|
27
|
-
decode(buf) {
|
|
28
|
-
const out = Buffer.from(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
29
|
-
return out.toString();
|
|
30
|
-
}
|
|
31
|
-
} : {
|
|
32
|
-
decode(buf) {
|
|
33
|
-
let out = "";
|
|
34
|
-
for (let i = 0; i < buf.length; i++) {
|
|
35
|
-
out += String.fromCharCode(buf[i]);
|
|
36
|
-
}
|
|
37
|
-
return out;
|
|
38
|
-
}
|
|
39
|
-
};
|
|
40
|
-
var StringWriter = class {
|
|
41
|
-
constructor() {
|
|
42
|
-
this.pos = 0;
|
|
43
|
-
this.out = "";
|
|
44
|
-
this.buffer = new Uint8Array(bufLength);
|
|
45
|
-
}
|
|
46
|
-
write(v) {
|
|
47
|
-
const { buffer } = this;
|
|
48
|
-
buffer[this.pos++] = v;
|
|
49
|
-
if (this.pos === bufLength) {
|
|
50
|
-
this.out += td.decode(buffer);
|
|
51
|
-
this.pos = 0;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
flush() {
|
|
55
|
-
const { buffer, out, pos } = this;
|
|
56
|
-
return pos > 0 ? out + td.decode(buffer.subarray(0, pos)) : out;
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
function encode(decoded) {
|
|
60
|
-
const writer = new StringWriter();
|
|
61
|
-
let sourcesIndex = 0;
|
|
62
|
-
let sourceLine = 0;
|
|
63
|
-
let sourceColumn = 0;
|
|
64
|
-
let namesIndex = 0;
|
|
65
|
-
for (let i = 0; i < decoded.length; i++) {
|
|
66
|
-
const line = decoded[i];
|
|
67
|
-
if (i > 0) writer.write(semicolon);
|
|
68
|
-
if (line.length === 0) continue;
|
|
69
|
-
let genColumn = 0;
|
|
70
|
-
for (let j = 0; j < line.length; j++) {
|
|
71
|
-
const segment = line[j];
|
|
72
|
-
if (j > 0) writer.write(comma);
|
|
73
|
-
encodeInteger(writer, encodeSign(segment[0] - genColumn));
|
|
74
|
-
genColumn = segment[0];
|
|
75
|
-
if (segment.length === 1) continue;
|
|
76
|
-
encodeInteger(writer, encodeSign(segment[1] - sourcesIndex));
|
|
77
|
-
encodeInteger(writer, encodeSign(segment[2] - sourceLine));
|
|
78
|
-
encodeInteger(writer, encodeSign(segment[3] - sourceColumn));
|
|
79
|
-
sourcesIndex = segment[1];
|
|
80
|
-
sourceLine = segment[2];
|
|
81
|
-
sourceColumn = segment[3];
|
|
82
|
-
if (segment.length === 4) continue;
|
|
83
|
-
encodeInteger(writer, encodeSign(segment[4] - namesIndex));
|
|
84
|
-
namesIndex = segment[4];
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
return writer.flush();
|
|
88
|
-
}
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
|
+
import {
|
|
3
|
+
encode
|
|
4
|
+
} from "./chunk-HUABRVWB.mjs";
|
|
89
5
|
|
|
90
6
|
// ../../node_modules/.pnpm/magic-string@0.30.21/node_modules/magic-string/dist/magic-string.es.mjs
|
|
91
7
|
var BitSet = class _BitSet {
|
|
@@ -1079,6 +995,5 @@ var MagicString = class _MagicString {
|
|
|
1079
995
|
};
|
|
1080
996
|
|
|
1081
997
|
export {
|
|
1082
|
-
encode,
|
|
1083
998
|
MagicString
|
|
1084
999
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @fluixi/compiler v1.0.0-alpha.
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
2
|
import {
|
|
3
3
|
INTRINSICS,
|
|
4
4
|
RESERVED_COMPONENTS,
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
builtinComponentMap,
|
|
8
8
|
isIntrinsicName,
|
|
9
9
|
isPrimitiveModule
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-C3AK5PBV.mjs";
|
|
11
11
|
|
|
12
12
|
// src/analyze/expr-shape.ts
|
|
13
13
|
var CALL = /* @__PURE__ */ new Set(["CallExpression", "OptionalCallExpression"]);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @fluixi/compiler v1.0.0-alpha.
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
2
|
|
|
3
3
|
// src/resolve/component-resolver.ts
|
|
4
4
|
var isMapRule = (rule) => "components" in rule;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @fluixi/compiler v1.0.0-alpha.
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
2
|
var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
|
|
3
3
|
get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
|
|
4
4
|
}) : x)(function(x) {
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
/*! @fluixi/compiler v1.0.0-alpha.95 | (c) 2026 Ibrahima Touré and Fluixi contributors | MIT */
|
|
2
|
+
|
|
3
|
+
// ../../node_modules/.pnpm/@jridgewell+sourcemap-codec@1.6.0/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs
|
|
4
|
+
var comma = ",".charCodeAt(0);
|
|
5
|
+
var semicolon = ";".charCodeAt(0);
|
|
6
|
+
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
7
|
+
var intToChar = new Uint8Array(64);
|
|
8
|
+
var charToInt = new Uint8Array(128);
|
|
9
|
+
for (let i = 0; i < chars.length; i++) {
|
|
10
|
+
const c = chars.charCodeAt(i);
|
|
11
|
+
intToChar[i] = c;
|
|
12
|
+
charToInt[c] = i;
|
|
13
|
+
}
|
|
14
|
+
function encodeInteger(builder, num) {
|
|
15
|
+
do {
|
|
16
|
+
let clamped = num & 31;
|
|
17
|
+
num >>>= 5;
|
|
18
|
+
if (num > 0) clamped |= 32;
|
|
19
|
+
builder.write(intToChar[clamped]);
|
|
20
|
+
} while (num > 0);
|
|
21
|
+
}
|
|
22
|
+
function encodeSign(num) {
|
|
23
|
+
return num < 0 ? -num << 1 | 1 : num << 1;
|
|
24
|
+
}
|
|
25
|
+
var bufLength = 1024 * 16;
|
|
26
|
+
var td = typeof TextDecoder !== "undefined" ? /* @__PURE__ */ new TextDecoder() : typeof Buffer !== "undefined" ? {
|
|
27
|
+
decode(buf) {
|
|
28
|
+
const out = Buffer.from(buf.buffer, buf.byteOffset, buf.byteLength);
|
|
29
|
+
return out.toString();
|
|
30
|
+
}
|
|
31
|
+
} : {
|
|
32
|
+
decode(buf) {
|
|
33
|
+
let out = "";
|
|
34
|
+
for (let i = 0; i < buf.length; i++) {
|
|
35
|
+
out += String.fromCharCode(buf[i]);
|
|
36
|
+
}
|
|
37
|
+
return out;
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
var StringWriter = class {
|
|
41
|
+
constructor() {
|
|
42
|
+
this.pos = 0;
|
|
43
|
+
this.out = "";
|
|
44
|
+
this.buffer = new Uint8Array(bufLength);
|
|
45
|
+
}
|
|
46
|
+
write(v) {
|
|
47
|
+
const { buffer } = this;
|
|
48
|
+
buffer[this.pos++] = v;
|
|
49
|
+
if (this.pos === bufLength) {
|
|
50
|
+
this.out += td.decode(buffer);
|
|
51
|
+
this.pos = 0;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
flush() {
|
|
55
|
+
const { buffer, out, pos } = this;
|
|
56
|
+
return pos > 0 ? out + td.decode(buffer.subarray(0, pos)) : out;
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
function encode(decoded) {
|
|
60
|
+
const writer = new StringWriter();
|
|
61
|
+
let sourcesIndex = 0;
|
|
62
|
+
let sourceLine = 0;
|
|
63
|
+
let sourceColumn = 0;
|
|
64
|
+
let namesIndex = 0;
|
|
65
|
+
for (let i = 0; i < decoded.length; i++) {
|
|
66
|
+
const line = decoded[i];
|
|
67
|
+
if (i > 0) writer.write(semicolon);
|
|
68
|
+
if (line.length === 0) continue;
|
|
69
|
+
let genColumn = 0;
|
|
70
|
+
for (let j = 0; j < line.length; j++) {
|
|
71
|
+
const segment = line[j];
|
|
72
|
+
if (j > 0) writer.write(comma);
|
|
73
|
+
encodeInteger(writer, encodeSign(segment[0] - genColumn));
|
|
74
|
+
genColumn = segment[0];
|
|
75
|
+
if (segment.length === 1) continue;
|
|
76
|
+
encodeInteger(writer, encodeSign(segment[1] - sourcesIndex));
|
|
77
|
+
encodeInteger(writer, encodeSign(segment[2] - sourceLine));
|
|
78
|
+
encodeInteger(writer, encodeSign(segment[3] - sourceColumn));
|
|
79
|
+
sourcesIndex = segment[1];
|
|
80
|
+
sourceLine = segment[2];
|
|
81
|
+
sourceColumn = segment[3];
|
|
82
|
+
if (segment.length === 4) continue;
|
|
83
|
+
encodeInteger(writer, encodeSign(segment[4] - namesIndex));
|
|
84
|
+
namesIndex = segment[4];
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
return writer.flush();
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
export {
|
|
91
|
+
encode
|
|
92
|
+
};
|