From 4694a73f1410bdec7cf4a7a9585e1df89158a390 Mon Sep 17 00:00:00 2001 From: ALPAC-4 Date: Tue, 26 Mar 2024 16:02:05 +0900 Subject: [PATCH] fix: allow url that is not in main branch --- _package/package.json | 2 +- _package/src/zods/Chain.ts | 8 ++++---- chain.schema.json | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/_package/package.json b/_package/package.json index 06686c1..393d765 100644 --- a/_package/package.json +++ b/_package/package.json @@ -1,6 +1,6 @@ { "name": "@initia/initia-registry-types", - "version": "0.0.7", + "version": "0.0.8", "description": "The package provides TypeScript type definitions and Zod integration for initia-registry.", "types": "./dist/types/index.d.ts", "exports": { diff --git a/_package/src/zods/Chain.ts b/_package/src/zods/Chain.ts index 9c93b20..51867d9 100644 --- a/_package/src/zods/Chain.ts +++ b/_package/src/zods/Chain.ts @@ -266,7 +266,7 @@ export const ChainSchema = z .string() .regex( new RegExp( - "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.png$" + "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.png$" ) ) .optional(), @@ -274,7 +274,7 @@ export const ChainSchema = z .string() .regex( new RegExp( - "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.svg$" + "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.svg$" ) ) .optional(), @@ -312,7 +312,7 @@ export const ChainSchema = z .string() .regex( new RegExp( - "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.png$" + "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.png$" ) ) .optional(), @@ -320,7 +320,7 @@ export const ChainSchema = z .string() .regex( new RegExp( - "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.svg$" + "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.svg$" ) ) .optional(), diff --git a/chain.schema.json b/chain.schema.json index 8317000..963cb29 100644 --- a/chain.schema.json +++ b/chain.schema.json @@ -425,12 +425,12 @@ "png": { "type": "string", "format": "uri-reference", - "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.png$" + "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.png$" }, "svg": { "type": "string", "format": "uri-reference", - "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.svg$" + "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.svg$" }, "theme": { "type": "object", @@ -486,12 +486,12 @@ "png": { "type": "string", "format": "uri-reference", - "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.png$" + "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.png$" }, "svg": { "type": "string", "format": "uri-reference", - "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/main/(|testnets/|devnets/)[a-z0-9]+/images/.+\\.svg$" + "pattern": "^https://raw\\.githubusercontent\\.com/initia-labs/initia-registry/.+\\.svg$" } }, "additionalProperties": false