UNPKG

@pfantato/printful-ts

Version:

Typescript SDK to integrate with Printful

18 lines (17 loc) 472 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Color = exports.ColorValue = void 0; const zod_1 = require("zod"); const color_string_1 = require("color-string"); exports.ColorValue = zod_1.z.string().refine(val => { try { return color_string_1.default.get(val) !== null; } catch (_a) { return false; } }); exports.Color = zod_1.z.object({ name: zod_1.z.string(), value: exports.ColorValue, });