feat(schematics): add schematic search/build with Playwright browser support
Some checks failed
Deploy to Docker / deploy (push) Failing after 33s
Some checks failed
Deploy to Docker / deploy (push) Failing after 33s
Switch Docker base image from node:22-alpine to Playwright Noble for in-container Chromium support. Add persistent cache volume for schematics. New files: schematics browser, cache, Java block ID mapping. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { log } from './utils.js';
|
||||
import { JAVA_TO_BEDROCK } from './java-block-ids.js';
|
||||
|
||||
const TAG = 'BlockMap';
|
||||
|
||||
@@ -615,6 +616,13 @@ export function resolveBlock(gcId, gcName) {
|
||||
}
|
||||
}
|
||||
|
||||
// Try Java string ID (for prismarine-schematic sources)
|
||||
const javaId = gcId?.replace(/^minecraft:/, '');
|
||||
if (javaId && JAVA_TO_BEDROCK.has(javaId)) {
|
||||
const entry = JAVA_TO_BEDROCK.get(javaId);
|
||||
return { block: entry.bedrock, data: entry.data, matched: true, name: entry.name };
|
||||
}
|
||||
|
||||
// Try name-based lookup
|
||||
if (gcName) {
|
||||
const lower = gcName.toLowerCase().trim();
|
||||
|
||||
Reference in New Issue
Block a user