@coderline/alphatab-vite 1.7.0-alpha.1627 → 1.7.0-alpha.1629

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.
@@ -0,0 +1,60 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
39
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
40
+
41
+ const fs = require('node:fs');
42
+ const bridge_utils = require('./utils.cjs');
43
+
44
+ // index.ts for more details on contents and license of this file
45
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/fsUtils.ts#L388
46
+ /**
47
+ * @internal
48
+ */
49
+ function tryResolveRealFile(file, preserveSymlinks) {
50
+ const fileStat = bridge_utils.tryStatSync(file);
51
+ if (fileStat?.isFile()) {
52
+ return file;
53
+ }
54
+ if (fileStat?.isSymbolicLink()) {
55
+ return preserveSymlinks ? file : fs.realpathSync(file);
56
+ }
57
+ return undefined;
58
+ }
59
+
60
+ exports.tryResolveRealFile = tryResolveRealFile;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * alphaTab Vite Plugin v1.7.0-alpha.1627 (develop, build 1627)
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
3
  *
4
4
  * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
5
  *
@@ -0,0 +1,69 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
39
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
40
+
41
+ const bridge_asset = require('./asset.cjs');
42
+ const bridge_build = require('./build.cjs');
43
+ const bridge_constants = require('./constants.cjs');
44
+ const bridge_optimizer = require('./optimizer.cjs');
45
+ const bridge_resolve = require('./resolve.cjs');
46
+ const bridge_utils = require('./utils.cjs');
47
+ const bridge_worker = require('./worker.cjs');
48
+
49
+
50
+
51
+ exports.fileToUrl = bridge_asset.fileToUrl;
52
+ exports.createToImportMetaURLBasedRelativeRuntime = bridge_build.createToImportMetaURLBasedRelativeRuntime;
53
+ exports.toOutputFilePathInJS = bridge_build.toOutputFilePathInJS;
54
+ exports.ENV_PUBLIC_PATH = bridge_constants.ENV_PUBLIC_PATH;
55
+ exports.tryOptimizedDepResolve = bridge_optimizer.tryOptimizedDepResolve;
56
+ exports.tryFsResolve = bridge_resolve.tryFsResolve;
57
+ exports.cleanUrl = bridge_utils.cleanUrl;
58
+ exports.encodeURIPath = bridge_utils.encodeURIPath;
59
+ exports.evalValue = bridge_utils.evalValue;
60
+ exports.injectQuery = bridge_utils.injectQuery;
61
+ Object.defineProperty(exports, "AlphaTabWorkerTypes", {
62
+ enumerable: true,
63
+ get: () => bridge_worker.AlphaTabWorkerTypes
64
+ });
65
+ exports.WORKER_ASSET_ID = bridge_worker.WORKER_ASSET_ID;
66
+ exports.WORKER_FILE_ID = bridge_worker.WORKER_FILE_ID;
67
+ exports.isSameContent = bridge_worker.isSameContent;
68
+ exports.workerCache = bridge_worker.workerCache;
69
+ exports.workerFileToUrl = bridge_worker.workerFileToUrl;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * alphaTab Vite Plugin v1.7.0-alpha.1627 (develop, build 1627)
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
3
  *
4
4
  * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
5
  *
@@ -0,0 +1,172 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
39
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
40
+
41
+ const fs = require('node:fs');
42
+ const path = require('node:path');
43
+ const vite = require('vite');
44
+ const bridge_constants = require('./constants.cjs');
45
+ const bridge_resolve = require('./resolve.cjs');
46
+ const bridge_utils = require('./utils.cjs');
47
+
48
+ function _interopNamespaceDefault(e) {
49
+ const n = Object.create(null, { [Symbol.toStringTag]: { value: 'Module' } });
50
+ if (e) {
51
+ for (const k in e) {
52
+ if (k !== 'default') {
53
+ const d = Object.getOwnPropertyDescriptor(e, k);
54
+ Object.defineProperty(n, k, d.get ? d : {
55
+ enumerable: true,
56
+ get: () => e[k]
57
+ });
58
+ }
59
+ }
60
+ }
61
+ n.default = e;
62
+ return Object.freeze(n);
63
+ }
64
+
65
+ const path__namespace = /*#__PURE__*/_interopNamespaceDefault(path);
66
+
67
+ // index.ts for more details on contents and license of this file
68
+ // https://github.com/Danielku15/vite/blob/88b7def341f12d07d7d4f83cbe3dc73cc8c6b7be/packages/vite/src/node/optimizer/index.ts#L1356
69
+ /**
70
+ * @internal
71
+ */
72
+ function tryOptimizedDepResolve(config, ssr, url, depId, preserveSymlinks) {
73
+ const optimizer = getDepsOptimizer(config, ssr);
74
+ if (optimizer?.isOptimizedDepFile(depId)) {
75
+ const depFile = bridge_utils.cleanUrl(depId);
76
+ const info = optimizedDepInfoFromFile(optimizer.metadata, depFile);
77
+ const depSrc = info?.src;
78
+ if (depSrc) {
79
+ const resolvedFile = path__namespace.resolve(path__namespace.dirname(depSrc), url);
80
+ return bridge_resolve.tryFsResolve(resolvedFile, preserveSymlinks);
81
+ }
82
+ }
83
+ return undefined;
84
+ }
85
+ // https://github.com/Danielku15/vite/blob/88b7def341f12d07d7d4f83cbe3dc73cc8c6b7be/packages/vite/src/node/optimizer/optimizer.ts#L32-L40
86
+ const depsOptimizerMap = new WeakMap();
87
+ const devSsrDepsOptimizerMap = new WeakMap();
88
+ function getDepsOptimizer(config, ssr) {
89
+ const map = ssr ? devSsrDepsOptimizerMap : depsOptimizerMap;
90
+ let optimizer = map.get(config);
91
+ if (!optimizer) {
92
+ optimizer = createDepsOptimizer(config);
93
+ map.set(config, optimizer);
94
+ }
95
+ return optimizer;
96
+ }
97
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/optimizer/optimizer.ts#L79
98
+ function createDepsOptimizer(config) {
99
+ const depsCacheDirPrefix = vite.normalizePath(path__namespace.resolve(config.cacheDir, 'deps'));
100
+ const metadata = parseDepsOptimizerMetadata(fs.readFileSync(path__namespace.join(depsCacheDirPrefix, bridge_constants.METADATA_FILENAME), 'utf8'), depsCacheDirPrefix);
101
+ const notImplemented = () => {
102
+ throw new Error('not implemented');
103
+ };
104
+ const depsOptimizer = {
105
+ async init() { },
106
+ metadata,
107
+ registerMissingImport: notImplemented,
108
+ run: notImplemented,
109
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/optimizer/index.ts#L916
110
+ isOptimizedDepFile: id => id.startsWith(depsCacheDirPrefix),
111
+ isOptimizedDepUrl: notImplemented,
112
+ getOptimizedDepId: notImplemented,
113
+ close: notImplemented,
114
+ options: {}
115
+ };
116
+ return depsOptimizer;
117
+ }
118
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/optimizer/index.ts#L944
119
+ function parseDepsOptimizerMetadata(jsonMetadata, depsCacheDir) {
120
+ const { hash, lockfileHash, configHash, browserHash, optimized, chunks } = JSON.parse(jsonMetadata, (key, value) => {
121
+ if (key === 'file' || key === 'src') {
122
+ return vite.normalizePath(path__namespace.resolve(depsCacheDir, value));
123
+ }
124
+ return value;
125
+ });
126
+ if (!chunks || Object.values(optimized).some(depInfo => !depInfo.fileHash)) {
127
+ // outdated _metadata.json version, ignore
128
+ return;
129
+ }
130
+ const metadata = {
131
+ hash,
132
+ lockfileHash,
133
+ configHash,
134
+ browserHash,
135
+ optimized: {},
136
+ discovered: {},
137
+ chunks: {},
138
+ depInfoList: []
139
+ };
140
+ for (const id of Object.keys(optimized)) {
141
+ addOptimizedDepInfo(metadata, 'optimized', {
142
+ ...optimized[id],
143
+ id,
144
+ browserHash
145
+ });
146
+ }
147
+ for (const id of Object.keys(chunks)) {
148
+ addOptimizedDepInfo(metadata, 'chunks', {
149
+ ...chunks[id],
150
+ id,
151
+ browserHash,
152
+ needsInterop: false
153
+ });
154
+ }
155
+ return metadata;
156
+ }
157
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/optimizer/index.ts#L322
158
+ function addOptimizedDepInfo(metadata, type, depInfo) {
159
+ metadata[type][depInfo.id] = depInfo;
160
+ metadata.depInfoList.push(depInfo);
161
+ return depInfo;
162
+ }
163
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/optimizer/index.ts#L1248
164
+ /**
165
+ * @internal
166
+ */
167
+ function optimizedDepInfoFromFile(metadata, file) {
168
+ return metadata.depInfoList.find(depInfo => depInfo.file === file);
169
+ }
170
+
171
+ exports.optimizedDepInfoFromFile = optimizedDepInfoFromFile;
172
+ exports.tryOptimizedDepResolve = tryOptimizedDepResolve;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * alphaTab Vite Plugin v1.7.0-alpha.1627 (develop, build 1627)
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
3
  *
4
4
  * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
5
  *
@@ -0,0 +1,51 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
39
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
40
+
41
+ // index.ts for more details on contents and license of this file
42
+ // https://github.com/vitejs/vite/blob/v6.1.1/packages/vite/src/node/plugins/index.ts#L161
43
+ /**
44
+ * @internal
45
+ */
46
+ // biome-ignore lint/complexity/noBannedTypes: Function type needed here
47
+ function getHookHandler(hook) {
48
+ return (typeof hook === 'object' ? hook.handler : hook);
49
+ }
50
+
51
+ exports.getHookHandler = getHookHandler;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * alphaTab Vite Plugin v1.7.0-alpha.1627 (develop, build 1627)
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
3
  *
4
4
  * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
5
  *
@@ -0,0 +1,75 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
39
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
40
+
41
+ const vite = require('vite');
42
+ const bridge_fsUtils = require('./fsUtils.cjs');
43
+ const bridge_utils = require('./utils.cjs');
44
+
45
+ // index.ts for more details on contents and license of this file
46
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/plugins/resolve.ts#L534
47
+ function splitFileAndPostfix(path) {
48
+ const file = bridge_utils.cleanUrl(path);
49
+ return { file, postfix: path.slice(file.length) };
50
+ }
51
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/plugins/resolve.ts#L566-L574
52
+ /**
53
+ * @internal
54
+ */
55
+ function tryFsResolve(fsPath, preserveSymlinks) {
56
+ const { file, postfix } = splitFileAndPostfix(fsPath);
57
+ const res = tryCleanFsResolve(file, preserveSymlinks);
58
+ if (res) {
59
+ return res + postfix;
60
+ }
61
+ return;
62
+ }
63
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/plugins/resolve.ts#L580
64
+ function tryCleanFsResolve(file, preserveSymlinks) {
65
+ if (file.includes('node_modules')) {
66
+ return bridge_fsUtils.tryResolveRealFile(file, preserveSymlinks);
67
+ }
68
+ const normalizedResolved = bridge_fsUtils.tryResolveRealFile(vite.normalizePath(file));
69
+ if (!normalizedResolved) {
70
+ return bridge_fsUtils.tryResolveRealFile(file, preserveSymlinks);
71
+ }
72
+ return normalizedResolved;
73
+ }
74
+
75
+ exports.tryFsResolve = tryFsResolve;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * alphaTab Vite Plugin v1.7.0-alpha.1627 (develop, build 1627)
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
3
  *
4
4
  * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
5
  *
@@ -0,0 +1,38 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * alphaTab Vite Plugin v1.7.0-alpha.1627 (develop, build 1627)
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
3
  *
4
4
  * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
5
  *
@@ -0,0 +1,164 @@
1
+ /*!
2
+ * alphaTab Vite Plugin v1.7.0-alpha.1629 (develop, build 1629)
3
+ *
4
+ * Copyright © 2025, Daniel Kuschny and Contributors, All rights reserved.
5
+ *
6
+ * This Source Code Form is subject to the terms of the Mozilla Public
7
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
8
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9
+ *
10
+ * This library uses code from Vite (https://github.com/vitejs/vite/), licensed under:
11
+ *
12
+ * MIT License
13
+ * Copyright (c) 2019-present, Yuxi (Evan) You and Vite contributors
14
+ *
15
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
16
+ * of this software and associated documentation files (the "Software"), to deal
17
+ * in the Software without restriction, including without limitation the rights
18
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
19
+ * copies of the Software, and to permit persons to whom the Software is
20
+ * furnished to do so, subject to the following conditions:
21
+ *
22
+ * The above copyright notice and this permission notice shall be included in all
23
+ * copies or substantial portions of the Software.
24
+ *
25
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
26
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
27
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
28
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
29
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
30
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31
+ * SOFTWARE.
32
+ *
33
+ * @preserve
34
+ * @license
35
+ */
36
+
37
+ 'use strict';
38
+
39
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
40
+
41
+ const fs = require('node:fs');
42
+ const node_crypto = require('node:crypto');
43
+
44
+ // index.ts for more details on contents and license of this file
45
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L1302
46
+ /**
47
+ * @internal
48
+ */
49
+ function evalValue(rawValue) {
50
+ const fn = new Function(`
51
+ var console, exports, global, module, process, require
52
+ return (\n${rawValue}\n)
53
+ `);
54
+ return fn();
55
+ }
56
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/shared/utils.ts#L31-L34
57
+ const postfixRE = /[?#].*$/;
58
+ /**
59
+ * @internal
60
+ */
61
+ function cleanUrl(url) {
62
+ return url.replace(postfixRE, '');
63
+ }
64
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L393
65
+ /**
66
+ * @internal
67
+ */
68
+ function tryStatSync(file) {
69
+ try {
70
+ // The "throwIfNoEntry" is a performance optimization for cases where the file does not exist
71
+ return fs.statSync(file, { throwIfNoEntry: false });
72
+ }
73
+ catch {
74
+ // Ignore errors
75
+ }
76
+ return;
77
+ }
78
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L1030
79
+ /**
80
+ * @internal
81
+ */
82
+ function getHash(text, length = 8) {
83
+ const h = node_crypto.createHash('sha256').update(text).digest('hex').substring(0, length);
84
+ if (length <= 64) {
85
+ return h;
86
+ }
87
+ return h.padEnd(length, '_');
88
+ }
89
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/shared/utils.ts#L40
90
+ /**
91
+ * @internal
92
+ */
93
+ function withTrailingSlash(path) {
94
+ if (path[path.length - 1] !== '/') {
95
+ return `${path}/`;
96
+ }
97
+ return path;
98
+ }
99
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L1268
100
+ /**
101
+ * @internal
102
+ */
103
+ function joinUrlSegments(a, b) {
104
+ if (!a || !b) {
105
+ return a || b || '';
106
+ }
107
+ if (a[a.length - 1] === '/') {
108
+ a = a.substring(0, a.length - 1);
109
+ }
110
+ if (b[0] !== '/') {
111
+ b = `/${b}`;
112
+ }
113
+ return a + b;
114
+ }
115
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L1281
116
+ /**
117
+ * @internal
118
+ */
119
+ function removeLeadingSlash(str) {
120
+ return str[0] === '/' ? str.slice(1) : str;
121
+ }
122
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L319
123
+ /**
124
+ * @internal
125
+ */
126
+ function injectQuery(builtUrl, query) {
127
+ const queryIndex = builtUrl.indexOf('?');
128
+ return builtUrl + (queryIndex === -1 ? '?' : '&') + query;
129
+ }
130
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L1435
131
+ /**
132
+ * @internal
133
+ */
134
+ function partialEncodeURIPath(uri) {
135
+ if (uri.startsWith('data:')) {
136
+ return uri;
137
+ }
138
+ const filePath = cleanUrl(uri);
139
+ const postfix = filePath !== uri ? uri.slice(filePath.length) : '';
140
+ return filePath.replaceAll('%', '%25') + postfix;
141
+ }
142
+ // https://github.com/vitejs/vite/blob/b7ddfae5f852c2948fab03e94751ce56f5f31ce0/packages/vite/src/node/utils.ts#L1424
143
+ /**
144
+ * @internal
145
+ */
146
+ function encodeURIPath(uri) {
147
+ if (uri.startsWith('data:')) {
148
+ return uri;
149
+ }
150
+ const filePath = cleanUrl(uri);
151
+ const postfix = filePath !== uri ? uri.slice(filePath.length) : '';
152
+ return encodeURI(filePath) + postfix;
153
+ }
154
+
155
+ exports.cleanUrl = cleanUrl;
156
+ exports.encodeURIPath = encodeURIPath;
157
+ exports.evalValue = evalValue;
158
+ exports.getHash = getHash;
159
+ exports.injectQuery = injectQuery;
160
+ exports.joinUrlSegments = joinUrlSegments;
161
+ exports.partialEncodeURIPath = partialEncodeURIPath;
162
+ exports.removeLeadingSlash = removeLeadingSlash;
163
+ exports.tryStatSync = tryStatSync;
164
+ exports.withTrailingSlash = withTrailingSlash;