Default XSD root — points at the schemas directory shipped alongside
the validator source under scripts/office/schemas/.
Two layouts are supported because vp pack collapses the source tree
to dist/index.mjs:
dev / source layout: this file sits at src/scripts/office/validators/,
so ../schemas resolves to src/scripts/office/schemas/.
published / dist layout: bundled file sits at dist/index.mjs, and
vite.config.ts copies the schemas to dist/schemas/, so
./schemas (relative to the bundle) is the right path.
We probe in order and return whichever exists; if neither does we fall
back to the source path so the error message points somewhere sensible.
Default XSD root — points at the schemas directory shipped alongside the validator source under
scripts/office/schemas/.Two layouts are supported because
vp packcollapses the source tree todist/index.mjs:src/scripts/office/validators/, so../schemasresolves tosrc/scripts/office/schemas/.dist/index.mjs, andvite.config.tscopies the schemas todist/schemas/, so./schemas(relative to the bundle) is the right path.We probe in order and return whichever exists; if neither does we fall back to the source path so the error message points somewhere sensible.