motely-wasm 1.0.2 → 1.0.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.
Files changed (110) hide show
  1. package/index.d.ts +11 -25
  2. package/index.js +7 -39
  3. package/package.json +14 -83
  4. package/pkg/Motely.WASM.deps.json +238 -0
  5. package/pkg/Motely.WASM.dll +0 -0
  6. package/pkg/System.Private.CoreLib.dll +0 -0
  7. package/pkg/System.Runtime.InteropServices.JavaScript.dll +0 -0
  8. package/pkg/System.Runtime.dll +0 -0
  9. package/pkg/System.Threading.Channels.dll +0 -0
  10. package/pkg/corebindings.c +298 -0
  11. package/pkg/dotnet.d.ts +785 -0
  12. package/pkg/dotnet.diagnostics.js +4 -0
  13. package/pkg/dotnet.es6.extpost.js +2 -0
  14. package/pkg/dotnet.es6.lib.js +156 -0
  15. package/pkg/dotnet.es6.pre.js +3 -0
  16. package/pkg/dotnet.native.js +16 -0
  17. package/pkg/dotnet.native.js.symbols +8944 -0
  18. package/pkg/dotnet.native.wasm +0 -0
  19. package/pkg/dotnet.native.worker.mjs +1 -0
  20. package/pkg/driver.c +587 -0
  21. package/pkg/emcc-default.rsp +1 -0
  22. package/pkg/emcc-link.rsp +21 -0
  23. package/pkg/gc-common.h +73 -0
  24. package/pkg/icudt.dat +0 -0
  25. package/pkg/icudt_CJK.dat +0 -0
  26. package/pkg/icudt_EFIGS.dat +0 -0
  27. package/pkg/icudt_no_CJK.dat +0 -0
  28. package/pkg/libSystem.Globalization.Native.a +0 -0
  29. package/pkg/libSystem.IO.Compression.Native.a +0 -0
  30. package/pkg/libSystem.Native.a +0 -0
  31. package/pkg/libbrotlicommon.a +0 -0
  32. package/pkg/libbrotlidec.a +0 -0
  33. package/pkg/libbrotlienc.a +0 -0
  34. package/pkg/libicudata.a +0 -0
  35. package/pkg/libicui18n.a +0 -0
  36. package/pkg/libicuuc.a +0 -0
  37. package/pkg/libmono-component-debugger-static.a +0 -0
  38. package/pkg/libmono-component-debugger-stub-static.a +0 -0
  39. package/pkg/libmono-component-diagnostics_tracing-static.a +0 -0
  40. package/pkg/libmono-component-diagnostics_tracing-stub-static.a +0 -0
  41. package/pkg/libmono-component-hot_reload-static.a +0 -0
  42. package/pkg/libmono-component-hot_reload-stub-static.a +0 -0
  43. package/pkg/libmono-component-marshal-ilgen-static.a +0 -0
  44. package/pkg/libmono-component-marshal-ilgen-stub-static.a +0 -0
  45. package/pkg/libmono-ee-interp.a +0 -0
  46. package/pkg/libmono-icall-table.a +0 -0
  47. package/pkg/libmono-profiler-aot.a +0 -0
  48. package/pkg/libmono-profiler-browser.a +0 -0
  49. package/pkg/libmono-profiler-log.a +0 -0
  50. package/pkg/libmono-wasm-eh-js.a +0 -0
  51. package/pkg/libmono-wasm-eh-wasm.a +0 -0
  52. package/pkg/libmono-wasm-nosimd.a +0 -0
  53. package/pkg/libmono-wasm-simd.a +0 -0
  54. package/pkg/libmonosgen-2.0.a +0 -0
  55. package/pkg/libz.a +0 -0
  56. package/pkg/package.json +44 -0
  57. package/pkg/pinvoke.c +94 -0
  58. package/pkg/pinvoke.h +62 -0
  59. package/pkg/runtime.c +433 -0
  60. package/pkg/runtime.h +23 -0
  61. package/pkg/wasm-bundled-timezones.a +0 -0
  62. package/pkg/wasm-config.h +13 -0
  63. package/pkg/wasm-props.json +25 -0
  64. package/LICENSE +0 -21
  65. package/README.md +0 -368
  66. package/dist/.stamp +0 -0
  67. package/dist/Motely.WASM.runtimeconfig.json +0 -47
  68. package/dist/_framework/Motely.Orchestration.Browser.wasm +0 -0
  69. package/dist/_framework/Motely.Orchestration.wasm +0 -0
  70. package/dist/_framework/Motely.Repository.wasm +0 -0
  71. package/dist/_framework/Motely.WASM.wasm +0 -0
  72. package/dist/_framework/Motely.wasm +0 -0
  73. package/dist/_framework/System.Collections.Concurrent.wasm +0 -0
  74. package/dist/_framework/System.Collections.wasm +0 -0
  75. package/dist/_framework/System.ComponentModel.Primitives.wasm +0 -0
  76. package/dist/_framework/System.Console.wasm +0 -0
  77. package/dist/_framework/System.IO.Pipelines.wasm +0 -0
  78. package/dist/_framework/System.Linq.wasm +0 -0
  79. package/dist/_framework/System.Memory.wasm +0 -0
  80. package/dist/_framework/System.ObjectModel.wasm +0 -0
  81. package/dist/_framework/System.Private.CoreLib.wasm +0 -0
  82. package/dist/_framework/System.Private.Uri.wasm +0 -0
  83. package/dist/_framework/System.Runtime.InteropServices.JavaScript.wasm +0 -0
  84. package/dist/_framework/System.Security.Cryptography.wasm +0 -0
  85. package/dist/_framework/System.Text.Encodings.Web.wasm +0 -0
  86. package/dist/_framework/System.Text.Json.wasm +0 -0
  87. package/dist/_framework/System.Text.RegularExpressions.wasm +0 -0
  88. package/dist/_framework/System.Threading.Channels.wasm +0 -0
  89. package/dist/_framework/System.Threading.wasm +0 -0
  90. package/dist/_framework/YamlDotNet.wasm +0 -0
  91. package/dist/_framework/aot-instances.wasm +0 -0
  92. package/dist/_framework/dotnet.boot.js +0 -187
  93. package/dist/_framework/dotnet.js.map +0 -1
  94. package/dist/_framework/dotnet.native.js +0 -5549
  95. package/dist/_framework/dotnet.native.wasm +0 -0
  96. package/dist/_framework/dotnet.native.worker.mjs +0 -181
  97. package/dist/_framework/dotnet.runtime.js.map +0 -1
  98. package/dist/duckdb.d.ts +0 -14
  99. package/dist/duckdb.js +0 -98
  100. package/dist/index.html +0 -227
  101. package/dist/loader.d.ts +0 -17
  102. package/dist/loader.js +0 -38
  103. package/dist/main.js +0 -10
  104. package/dist/package.json +0 -1
  105. package/dist/serve.json +0 -11
  106. package/docs/NEXTJS_INTEGRATION.md +0 -202
  107. package/motely-wasm.d.ts +0 -197
  108. package/scripts/prepare-public.js +0 -33
  109. /package/{dist/_framework → pkg}/dotnet.js +0 -0
  110. /package/{dist/_framework → pkg}/dotnet.runtime.js +0 -0
package/index.d.ts CHANGED
@@ -1,27 +1,13 @@
1
- /**
2
- * Node/build-script entry (require('motely-wasm')).
3
- * Runtime: only getDistPath and getFrameworkPath.
4
- * For loadMotely and browser API use ESM: import { loadMotely } from 'motely-wasm'
5
- */
6
- export function getDistPath(): string;
7
- export function getFrameworkPath(): string;
1
+ // Auto-generated TypeScript type definitions for motely-wasm
2
+ // Generated from C# JSExport/JSInvokable methods
3
+ // TODO: Implement full reflection-based generation
8
4
 
9
- export type {
10
- MotelyWasmApi,
11
- SeedAnalysisResult,
12
- AnteAnalysis,
13
- ShopItem,
14
- Pack,
15
- SearchResponse,
16
- SearchHit,
17
- SearchProgress,
18
- ValidateResult,
19
- VersionInfo,
20
- ErrorResult,
21
- } from "./motely-wasm";
5
+ export interface MotelyWasmApi {
6
+ // Placeholder - replace with actual generated types
7
+ GetVersion(): Promise<string>;
8
+ AnalyzeSeed(seed: string, deck: string, stake: string, ante?: number, shop?: number, config?: string): Promise<string>;
9
+ }
22
10
 
23
- export { initDuckDbWasmResults } from "./dist/loader";
24
- export type {
25
- DuckDbWasmResultsHandle,
26
- DuckDbWasmResultsOptions,
27
- } from "./dist/loader";
11
+ export const info: string;
12
+
13
+ // TODO: Add full type definitions based on actual JSExport methods
package/index.js CHANGED
@@ -1,39 +1,7 @@
1
- /**
2
- * motely-wasm - Balatro seed analyzer and searcher
3
- *
4
- * This package provides the WASM build files for Motely.
5
- *
6
- * Usage:
7
- * // 1. Get path to WASM files (for build scripts / copying to public folder)
8
- * const { getDistPath, getFrameworkPath } = require('motely-wasm');
9
- * console.log(getDistPath()); // Full path to dist/
10
- * console.log(getFrameworkPath()); // Full path to dist/_framework/
11
- *
12
- * // 2. In your browser code, load directly from your served public path:
13
- * // (Do NOT import loadMotely - it breaks bundlers like Webpack/Turbopack)
14
- * const { dotnet } = await import('/motely-wasm/_framework/dotnet.js');
15
- * const { getAssemblyExports, getConfig } = await dotnet.create();
16
- * const exports = await getAssemblyExports(getConfig().mainAssemblyName);
17
- * const api = exports.Motely.WASM.MotelyWasm;
18
- *
19
- * IMPORTANT: Copy dist/ to your public folder (e.g., public/motely-wasm/).
20
- * The WASM files must be served with COOP/COEP headers for multi-threading.
21
- */
22
- const path = require('path');
23
-
24
- /**
25
- * Get the path to the dist folder containing WASM files.
26
- * Copy this folder to your public directory.
27
- */
28
- function getDistPath() {
29
- return path.join(__dirname, 'dist');
30
- }
31
-
32
- /**
33
- * Get the path to the _framework folder containing the actual WASM runtime.
34
- */
35
- function getFrameworkPath() {
36
- return path.join(__dirname, 'dist', '_framework');
37
- }
38
-
39
- module.exports = { getDistPath, getFrameworkPath };
1
+
2
+ // This entry point assumes the WASM files are in ./pkg/
3
+ // Consumers (like Next.js) will copy ./pkg/ to their public dir.
4
+
5
+ export const info = "Motely WASM Package";
6
+
7
+ // Future: Add typed exports here if we wrap the dotnet.js logic
package/package.json CHANGED
@@ -1,83 +1,14 @@
1
- {
2
- "name": "motely-wasm",
3
- "version": "1.0.2",
4
- "description": "Balatro seed analyzer and searcher for the browser - WASM with SIMD + multi-threading (front-end only)",
5
- "author": "OptimusPi",
6
- "license": "MIT",
7
- "type": "commonjs",
8
- "main": "dist/loader.js",
9
- "browser": "dist/loader.js",
10
- "types": "dist/loader.d.ts",
11
- "sideEffects": false,
12
- "bin": {
13
- "motely-wasm-prepare": "scripts/prepare-public.js"
14
- },
15
- "exports": {
16
- ".": {
17
- "types": "./dist/loader.d.ts",
18
- "browser": {
19
- "default": "./dist/loader.js",
20
- "types": "./dist/loader.d.ts"
21
- },
22
- "import": {
23
- "default": "./dist/loader.js",
24
- "types": "./dist/loader.d.ts"
25
- },
26
- "require": {
27
- "default": "./index.js",
28
- "types": "./index.d.ts"
29
- },
30
- "default": {
31
- "default": "./dist/loader.js",
32
- "types": "./dist/loader.d.ts"
33
- }
34
- }
35
- },
36
- "files": [
37
- "dist/",
38
- "docs/",
39
- "scripts/prepare-public.js",
40
- "index.js",
41
- "index.d.ts",
42
- "motely-wasm.d.ts"
43
- ],
44
- "scripts": {
45
- "build": "dotnet publish -c Release && node scripts/prepare-npm.js && npx tsc",
46
- "prepack": "node scripts/prepack.js",
47
- "prepublishOnly": "npm run build",
48
- "postinstall": "node scripts/prepare-public.js",
49
- "dev": "node scripts/serve-with-headers.cjs 3333 dist"
50
- },
51
- "homepage": "https://github.com/OptimusPi/Motely#readme",
52
- "bugs": {
53
- "url": "https://github.com/OptimusPi/Motely/issues"
54
- },
55
- "repository": {
56
- "type": "git",
57
- "url": "https://github.com/OptimusPi/Motely.git"
58
- },
59
- "engines": {
60
- "node": ">=18"
61
- },
62
- "publishConfig": {
63
- "access": "public"
64
- },
65
- "keywords": [
66
- "balatro",
67
- "JAML",
68
- "Jimbo",
69
- "Ante",
70
- "Markup",
71
- "Language",
72
- "wasm",
73
- "seed",
74
- "analyzer",
75
- "searcher"
76
- ],
77
- "dependencies": {
78
- "@duckdb/duckdb-wasm": "^1.32.0"
79
- },
80
- "devDependencies": {
81
- "typescript": "^5.9.3"
82
- }
83
- }
1
+ {
2
+ "name": "motely-wasm",
3
+ "version": "1.0.5",
4
+ "description": "WASM binaries and JS interop for Motely Seed Oracle",
5
+ "main": "index.js",
6
+ "types": "index.d.ts",
7
+ "files": [
8
+ "pkg/",
9
+ "index.js",
10
+ "index.d.ts"
11
+ ],
12
+ "dependencies": {},
13
+ "devDependencies": {}
14
+ }
@@ -0,0 +1,238 @@
1
+ {
2
+ "runtimeTarget": {
3
+ "name": ".NETCoreApp,Version=v10.0/browser-wasm",
4
+ "signature": ""
5
+ },
6
+ "compilationOptions": {},
7
+ "targets": {
8
+ ".NETCoreApp,Version=v10.0": {},
9
+ ".NETCoreApp,Version=v10.0/browser-wasm": {
10
+ "Motely.WASM/1.0.0": {
11
+ "dependencies": {
12
+ "runtimepack.Microsoft.NETCore.App.Runtime.Mono.multithread.browser-wasm": "10.0.2"
13
+ },
14
+ "runtime": {
15
+ "Motely.WASM.dll": {}
16
+ }
17
+ },
18
+ "runtimepack.Microsoft.NETCore.App.Runtime.Mono.multithread.browser-wasm/10.0.2": {
19
+ "runtime": {
20
+ "System.Runtime.InteropServices.JavaScript.dll": {
21
+ "assemblyVersion": "10.0.0.0",
22
+ "fileVersion": "10.0.225.61305"
23
+ },
24
+ "System.Runtime.dll": {
25
+ "assemblyVersion": "10.0.0.0",
26
+ "fileVersion": "10.0.225.61305"
27
+ },
28
+ "System.Threading.Channels.dll": {
29
+ "assemblyVersion": "10.0.0.0",
30
+ "fileVersion": "10.0.225.61305"
31
+ }
32
+ },
33
+ "native": {
34
+ "System.Private.CoreLib.dll": {
35
+ "assemblyVersion": "10.0.0.0",
36
+ "fileVersion": "10.0.225.61305"
37
+ },
38
+ "dotnet.d.ts": {
39
+ "fileVersion": "0.0.0.0"
40
+ },
41
+ "dotnet.diagnostics.js": {
42
+ "fileVersion": "0.0.0.0"
43
+ },
44
+ "dotnet.diagnostics.js.map": {
45
+ "fileVersion": "0.0.0.0"
46
+ },
47
+ "dotnet.js": {
48
+ "fileVersion": "0.0.0.0"
49
+ },
50
+ "dotnet.js.map": {
51
+ "fileVersion": "0.0.0.0"
52
+ },
53
+ "dotnet.native.js": {
54
+ "fileVersion": "0.0.0.0"
55
+ },
56
+ "dotnet.native.js.symbols": {
57
+ "fileVersion": "0.0.0.0"
58
+ },
59
+ "dotnet.native.wasm": {
60
+ "fileVersion": "0.0.0.0"
61
+ },
62
+ "dotnet.native.worker.mjs": {
63
+ "fileVersion": "0.0.0.0"
64
+ },
65
+ "dotnet.runtime.js": {
66
+ "fileVersion": "0.0.0.0"
67
+ },
68
+ "dotnet.runtime.js.map": {
69
+ "fileVersion": "0.0.0.0"
70
+ },
71
+ "icudt.dat": {
72
+ "fileVersion": "0.0.0.0"
73
+ },
74
+ "icudt_CJK.dat": {
75
+ "fileVersion": "0.0.0.0"
76
+ },
77
+ "icudt_EFIGS.dat": {
78
+ "fileVersion": "0.0.0.0"
79
+ },
80
+ "icudt_no_CJK.dat": {
81
+ "fileVersion": "0.0.0.0"
82
+ },
83
+ "libSystem.Globalization.Native.a": {
84
+ "fileVersion": "0.0.0.0"
85
+ },
86
+ "libSystem.IO.Compression.Native.a": {
87
+ "fileVersion": "0.0.0.0"
88
+ },
89
+ "libSystem.Native.a": {
90
+ "fileVersion": "0.0.0.0"
91
+ },
92
+ "libbrotlicommon.a": {
93
+ "fileVersion": "0.0.0.0"
94
+ },
95
+ "libbrotlidec.a": {
96
+ "fileVersion": "0.0.0.0"
97
+ },
98
+ "libbrotlienc.a": {
99
+ "fileVersion": "0.0.0.0"
100
+ },
101
+ "libicudata.a": {
102
+ "fileVersion": "0.0.0.0"
103
+ },
104
+ "libicui18n.a": {
105
+ "fileVersion": "0.0.0.0"
106
+ },
107
+ "libicuuc.a": {
108
+ "fileVersion": "0.0.0.0"
109
+ },
110
+ "libmono-component-debugger-static.a": {
111
+ "fileVersion": "0.0.0.0"
112
+ },
113
+ "libmono-component-debugger-stub-static.a": {
114
+ "fileVersion": "0.0.0.0"
115
+ },
116
+ "libmono-component-diagnostics_tracing-static.a": {
117
+ "fileVersion": "0.0.0.0"
118
+ },
119
+ "libmono-component-diagnostics_tracing-stub-static.a": {
120
+ "fileVersion": "0.0.0.0"
121
+ },
122
+ "libmono-component-hot_reload-static.a": {
123
+ "fileVersion": "0.0.0.0"
124
+ },
125
+ "libmono-component-hot_reload-stub-static.a": {
126
+ "fileVersion": "0.0.0.0"
127
+ },
128
+ "libmono-component-marshal-ilgen-static.a": {
129
+ "fileVersion": "0.0.0.0"
130
+ },
131
+ "libmono-component-marshal-ilgen-stub-static.a": {
132
+ "fileVersion": "0.0.0.0"
133
+ },
134
+ "libmono-ee-interp.a": {
135
+ "fileVersion": "0.0.0.0"
136
+ },
137
+ "libmono-icall-table.a": {
138
+ "fileVersion": "0.0.0.0"
139
+ },
140
+ "libmono-profiler-aot.a": {
141
+ "fileVersion": "0.0.0.0"
142
+ },
143
+ "libmono-profiler-browser.a": {
144
+ "fileVersion": "0.0.0.0"
145
+ },
146
+ "libmono-profiler-log.a": {
147
+ "fileVersion": "0.0.0.0"
148
+ },
149
+ "libmono-wasm-eh-js.a": {
150
+ "fileVersion": "0.0.0.0"
151
+ },
152
+ "libmono-wasm-eh-wasm.a": {
153
+ "fileVersion": "0.0.0.0"
154
+ },
155
+ "libmono-wasm-nosimd.a": {
156
+ "fileVersion": "0.0.0.0"
157
+ },
158
+ "libmono-wasm-simd.a": {
159
+ "fileVersion": "0.0.0.0"
160
+ },
161
+ "libmonosgen-2.0.a": {
162
+ "fileVersion": "0.0.0.0"
163
+ },
164
+ "libz.a": {
165
+ "fileVersion": "0.0.0.0"
166
+ },
167
+ "package.json": {
168
+ "fileVersion": "0.0.0.0"
169
+ },
170
+ "wasm-bundled-timezones.a": {
171
+ "fileVersion": "0.0.0.0"
172
+ },
173
+ "gc-common.h": {
174
+ "fileVersion": "0.0.0.0"
175
+ },
176
+ "pinvoke.h": {
177
+ "fileVersion": "0.0.0.0"
178
+ },
179
+ "runtime.h": {
180
+ "fileVersion": "0.0.0.0"
181
+ },
182
+ "wasm-config.h": {
183
+ "fileVersion": "0.0.0.0"
184
+ },
185
+ "corebindings.c": {
186
+ "fileVersion": "0.0.0.0"
187
+ },
188
+ "driver.c": {
189
+ "fileVersion": "0.0.0.0"
190
+ },
191
+ "emcc-default.rsp": {
192
+ "fileVersion": "0.0.0.0"
193
+ },
194
+ "emcc-link.rsp": {
195
+ "fileVersion": "0.0.0.0"
196
+ },
197
+ "pinvoke.c": {
198
+ "fileVersion": "0.0.0.0"
199
+ },
200
+ "runtime.c": {
201
+ "fileVersion": "0.0.0.0"
202
+ },
203
+ "wasm-props.json": {
204
+ "fileVersion": "0.0.0.0"
205
+ },
206
+ "dotnet.es6.extpost.js": {
207
+ "fileVersion": "0.0.0.0"
208
+ },
209
+ "dotnet.es6.lib.js": {
210
+ "fileVersion": "0.0.0.0"
211
+ },
212
+ "dotnet.es6.pre.js": {
213
+ "fileVersion": "0.0.0.0"
214
+ }
215
+ }
216
+ }
217
+ }
218
+ },
219
+ "libraries": {
220
+ "Motely.WASM/1.0.0": {
221
+ "type": "project",
222
+ "serviceable": false,
223
+ "sha512": ""
224
+ },
225
+ "runtimepack.Microsoft.NETCore.App.Runtime.Mono.multithread.browser-wasm/10.0.2": {
226
+ "type": "runtimepack",
227
+ "serviceable": false,
228
+ "sha512": ""
229
+ }
230
+ },
231
+ "runtimes": {
232
+ "browser-wasm": [
233
+ "browser",
234
+ "any",
235
+ "base"
236
+ ]
237
+ }
238
+ }
Binary file
Binary file
Binary file