mirror of
https://github.com/PR0M3TH3AN/bitgate.git
synced 2026-11-05 21:11:00 +00:00
Add --bitgate-* theme tokens and a build-injected VERSION.
Widget styles now prefer --bitgate-* custom properties, falling back to the deprecated --gov-* names and then the existing defaults so current pages and overrides keep working. Browser bundles and ESM entry points expose VERSION (and window.bitgate.version) from package.json. Document allowlist on the widget policy preset list. Sync the lockfile so npm ci sees @bitgate/standalone. Co-authored-by: thePR0M3TH3AN <[email protected]>
This commit is contained in:
1 parent
90d4290989
commit
9e6f6c659e
24 files changed
+369
-22
No files matched your search
@@ -135,6 +135,11 @@ describe("<bitgate-provider>", () => {
|
||||
expect(provider.runtime.policies.policy.id).toBe("bitgate-commerce");
|
||||
});
|
||||
|
||||
it("accepts the allowlist policy preset", async () => {
|
||||
const provider = await mountProvider({ policy: "allowlist" });
|
||||
expect(provider.runtime.policies.policy.id).toBe("bitgate-allowlist");
|
||||
});
|
||||
|
||||
it("defaults to administrative-only governance", async () => {
|
||||
const provider = await mountProvider({ policy: null });
|
||||
expect(provider.runtime.policies.policy.id).toBe("bitgate-admin-only");
|
||||
@@ -154,6 +159,7 @@ describe("<bitgate-provider>", () => {
|
||||
const provider = await mountProvider({ policy: "invented" });
|
||||
expect(provider.runtime).toBeNull();
|
||||
expect(provider.getAttribute("data-error")).toMatch(/Unknown policy preset/);
|
||||
expect(provider.getAttribute("data-error")).toMatch(/allowlist/);
|
||||
});
|
||||
|
||||
it("reports a missing relays attribute", async () => {
|
||||
|
||||
Reference in new issue
Block a user