Skip to main content
Glama
deleonio
by deleonio
variant-progress.ts818 B
import type { Generic } from 'adopted-style-sheets'; import { watchValidator } from '../utils'; export const progressVariantOptions = ['bar', 'cycle'] as const; export type ProgressVariantPropType = (typeof progressVariantOptions)[number]; /** * Defines the variant for displaying the progress component. */ export type PropVariantProgress = { variant: ProgressVariantPropType; }; const isProgressVariantPropType = (value: unknown): value is ProgressVariantPropType => { return typeof value === 'string' && progressVariantOptions.includes(value as ProgressVariantPropType); }; export const validateVariantProgress = (component: Generic.Element.Component, value?: ProgressVariantPropType): void => { watchValidator(component, '_variant', isProgressVariantPropType, new Set(progressVariantOptions), value); };

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/deleonio/public-ui-kolibri'

If you have feedback or need assistance with the MCP directory API, please join our Discord server