UNPKG

@nuralogix.ai/web-ui

Version:

Nuralogix Web UI

901 lines (743 loc) 23.6 kB
import React$1, { ReactNode, InputHTMLAttributes, PropsWithChildren, FC } from 'react'; import * as _stylexjs_stylex from '@stylexjs/stylex'; import { StyleXStyles } from '@stylexjs/stylex'; interface AccordionProps { title: string; children: ReactNode; width?: string; defaultOpen?: boolean; } declare const Accordion: React$1.FC<AccordionProps>; interface BaseInputProps extends InputHTMLAttributes<HTMLInputElement> { unit?: React.ReactNode; icon?: React.ReactNode; invalid?: boolean; inputRef?: React.Ref<HTMLInputElement>; blurOnEnterKeyPress?: boolean; disabled?: boolean; readOnly?: boolean; invalidMessage?: React.ReactNode; label?: React.ReactNode; } declare const BaseInput: React$1.FC<PropsWithChildren<BaseInputProps>>; interface ButtonProps { icon?: React.ReactNode; variant?: 'primary' | 'success' | 'warning' | 'danger' | 'outline' | 'link'; onClick?: () => void; width?: string; type?: 'button' | 'submit' | 'reset'; disabled?: boolean; } declare const Button: React$1.FC<PropsWithChildren<ButtonProps>>; interface CarouselProps { children: React.ReactNode[]; showArrows?: boolean; showNav?: boolean; } declare const Carousel: React$1.FC<CarouselProps>; interface CheckboxProps { checked: boolean; onChange: () => void; label?: string; disabled?: boolean; icon?: React.ReactNode; size?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; borderRadius?: 'none' | 'small' | 'normal' | 'medium' | 'large' | 'extraLarge' | 'full'; boxShadow?: 'small' | 'regular' | 'medium' | 'large' | 'inner' | 'none'; defaultColor?: string; checkedColor?: string; checkedIconColor?: string; } declare const Checkbox: React$1.FC<CheckboxProps>; type ColorBoxProps = { size?: string; width?: string; height?: string; fillColor?: string; children?: React.ReactNode; }; declare const ColorBox: React$1.FC<ColorBoxProps>; interface DatePickerProps { inputType?: 'date' | 'time' | 'datetime-local'; selectedDate?: Date; onChange?: (date: Date) => void; minDate?: string; maxDate?: string; backgroundColor?: string; xpadding?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; ypadding?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; borderRadius?: 'none' | 'small' | 'normal' | 'medium' | 'large' | 'extraLarge' | 'full'; boxShadow?: 'small' | 'regular' | 'medium' | 'large' | 'inner' | 'none'; } declare const DatePicker: React$1.FC<DatePickerProps>; type BandColors = 'YELLOW' | 'LIGHT_GREEN' | 'GREEN' | 'LIGHT_RED' | 'RED'; interface MetadataItem { groupSize: number; bandColors: BandColors; label: number; } interface DialProps { metadata: MetadataItem[]; group: number; subGroup: number; value?: string; width?: string; unit?: string; animate?: boolean; customColours?: Record<BandColors, string>; } declare const Dial: React$1.FC<DialProps>; interface HeadingProps { color?: string; fontWeight?: string; fontSize?: string; LineHeight?: string; } declare const Heading: React$1.FC<PropsWithChildren<HeadingProps>>; interface HrProps { height?: number; variant?: 'primary' | 'secondary'; } declare const Hr: React$1.FC<HrProps>; interface LabelProps { variant?: 'primary' | 'secondary'; } declare const Label: React$1.FC<PropsWithChildren<LabelProps>>; interface LoadingProps { small?: boolean; } declare const Loading: React$1.FC<PropsWithChildren<LoadingProps>>; interface MenuItemProps { label: string; onClick: () => void; icon?: React.ReactNode; index?: number; hoverColor?: string; } interface MenuProps { isOpen: boolean; onClose: () => void; elevation?: '10' | '20' | '30' | '40' | '50' | 'behind' | 'auto'; backgroundColor?: string; hoverColor?: string; padding?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; transition?: 'none' | 'slow' | 'fast'; borderRadius?: 'none' | 'small' | 'normal' | 'medium' | 'large' | 'extraLarge' | 'full'; boxShadow?: 'small' | 'regular' | 'medium' | 'large' | 'inner' | 'none'; items: MenuItemProps[]; } declare const Menu: React$1.FC<MenuProps>; interface ModalProps { isOpen: boolean; onClose: () => void; onProceed?: () => void; title?: string; showConfirmButton?: boolean; showCloseButton?: boolean; closeButtonText?: string; showHeader?: boolean; confirmButtonText?: string; elevation?: '10' | '20' | '30' | '40' | '50' | 'behind' | 'auto'; backgroundColor?: string; variant?: 'primary' | 'success' | 'warning' | 'danger'; closeOnClickOutside?: boolean; } declare const Modal: React$1.FC<PropsWithChildren<ModalProps>>; interface PaginationProps { count: number; initialPage?: number; onPageChange?: (page: number) => void; siblingCount?: number; boundaryCount?: number; hoverColor?: string; selectedColor?: string; variant?: 'none' | 'circled' | 'squared'; size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; disabled?: boolean; hideFirstButton?: boolean; hideLastButton?: boolean; hideNextButton?: boolean; hidePrevButton?: boolean; } declare const Pagination: React$1.FC<PaginationProps>; type TextVariant = 'error'; interface TextProps { bold?: boolean; underline?: boolean; variant?: TextVariant; fontSize?: string; fontFamily?: string; fontWeight?: string; } interface ParagraphProps extends TextProps { } declare const Paragraph: React$1.FC<PropsWithChildren<ParagraphProps>>; interface PopoverProps { children: React.ReactNode; content: React.ReactNode; width?: string; } declare const Popover: React$1.FC<PopoverProps>; interface PopupProps { isOpen: boolean; onClose?: () => void; elevation?: '10' | '20' | '30' | '40' | '50' | 'behind' | 'auto'; backgroundColor?: string; width?: string; height?: string; position?: 'middle' | 'bottomright' | 'bottomleft'; padding?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; margin?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; transition?: 'none' | 'slow' | 'fast'; borderRadius?: 'none' | 'small' | 'normal' | 'medium' | 'large' | 'extraLarge' | 'full'; boxShadow?: 'small' | 'regular' | 'medium' | 'large' | 'inner' | 'none'; } declare const Popup: React$1.FC<PropsWithChildren<PopupProps>>; interface ProgressBarProps { /** * Current value of the progress bar */ percentage: number; /** * Label to display above the progress bar */ label?: ReactNode; /** * Width of the progress bar * @default '100%' */ width?: string; } declare const ProgressBar: React$1.FC<ProgressBarProps>; interface RadioOption { value: string; label: string; } interface RadioButtonGroupProps { options: RadioOption[]; onChange: (value: string) => void; value?: string; direction?: 'row' | 'column'; label?: string; } declare const RadioButtonGroup: React$1.FC<RadioButtonGroupProps>; interface ResultsCardProps { dial: React.ReactNode; headerText: string; infoModalContent?: React.ReactNode; icon?: React.ReactNode; width?: number; } declare const ResultsCard: React$1.FC<ResultsCardProps>; interface Option { value: string; label: React.ReactNode; } interface SelectProps { options?: Option[]; width?: string; value?: string; onChange?: (value: string) => void; placeholder?: React.ReactNode; disabled?: boolean; emptyMessage?: string; } declare const Select: React$1.FC<SelectProps>; interface ColumnType<T> { title: string; width?: number; customRender?: (column: ColumnType<T>, item: T) => JSX.Element; } type SimpleTableProps<T> = { title: string; data: T[]; headers: ColumnType<T>[]; }; declare function SimpleTable<T>({ title, data, headers }: SimpleTableProps<T>): JSX.Element; interface StarRatingProps { rating: number; total: number; fill?: string; width?: string; height?: string; } declare const StarRating: React$1.FC<StarRatingProps>; type BloodPressureProps = { width?: string; height?: string; strokeColor?: string; }; declare const BloodPressure: FC<BloodPressureProps>; type BodyMassIndexProps = { width?: string; height?: string; strokeColor?: string; }; declare const BodyMassIndex: FC<BodyMassIndexProps>; type BodyShapeIndexProps = { width?: string; height?: string; strokeColor?: string; }; declare const BodyShapeIndex: FC<BodyShapeIndexProps>; type BodyTemperatureProps = { width?: string; height?: string; strokeColor?: string; }; declare const BodyTemperature: FC<BodyTemperatureProps>; type BreathingProps = { width?: string; height?: string; strokeColor?: string; }; declare const Breathing: FC<BreathingProps>; type CameraProps = { width?: string; height?: string; strokeColor?: string; }; declare const Camera: React$1.FC<CameraProps>; type CardioVascularDiseaseRiskProps = { width?: string; height?: string; strokeColor?: string; }; declare const CardioVascularDiseaseRisk: FC<CardioVascularDiseaseRiskProps>; type CheckmarkProps = { width?: string; height?: string; strokeColor?: string; }; declare const Checkmark: FC<CheckmarkProps>; interface ChevronProps { width?: string; height?: string; strokeColor?: string; direction?: 'up' | 'down' | 'left' | 'right'; animate?: boolean; disabled?: boolean; } declare const Chevron: React$1.FC<ChevronProps>; type CrossProps = { width?: string; height?: string; strokeColor?: string; }; declare const Cross: FC<CrossProps>; type CardiacWorkloadProps = { width?: string; height?: string; strokeColor?: string; }; declare const CardiacWorkload: FC<CardiacWorkloadProps>; interface GlassesProps { width?: string; height?: string; strokeColor?: string; } declare const Glasses: React$1.FC<GlassesProps>; interface HelpProps { width?: string; height?: string; strokeColor?: string; } declare const Help: React$1.FC<HelpProps>; type FacialSkinAgeProps = { width?: string; height?: string; strokeColor?: string; }; declare const FacialSkinAge: FC<FacialSkinAgeProps>; type FattyLiverDiseaseRiskProps = { width?: string; height?: string; strokeColor?: string; }; declare const FattyLiverDiseaseRisk: FC<FattyLiverDiseaseRiskProps>; type FastingBloodGlucoseProps = { width?: string; height?: string; strokeColor?: string; }; declare const FastingBloodGlucose: FC<FastingBloodGlucoseProps>; type FemaleGenderProps = { width?: string; height?: string; strokeColor?: string; }; declare const FemaleGender: FC<FemaleGenderProps>; type HamburgerMenuProps = { width?: string; height?: string; strokeColor?: string; }; declare const HamburgerMenu: FC<HamburgerMenuProps>; type HealthScoreProps = { width?: string; height?: string; strokeColor?: string; }; declare const HealthScore: FC<HealthScoreProps>; type HeartAttackRiskProps = { width?: string; height?: string; strokeColor?: string; }; declare const HeartAttackRisk: FC<HeartAttackRiskProps>; type HeartRateVariabilityProps = { width?: string; height?: string; strokeColor?: string; }; declare const HeartRateVariability: FC<HeartRateVariabilityProps>; type HemoglobinA1CProps = { width?: string; height?: string; strokeColor?: string; }; declare const HemoglobinA1C: FC<HemoglobinA1CProps>; type HypercholesterolemiaProps = { width?: string; height?: string; strokeColor?: string; }; declare const Hypercholesterolemia: FC<HypercholesterolemiaProps>; type HypertensionProps = { width?: string; height?: string; strokeColor?: string; }; declare const Hypertension: FC<HypertensionProps>; type HypertriglyceridemiaProps = { width?: string; height?: string; strokeColor?: string; }; declare const Hypertriglyceridemia: FC<HypertriglyceridemiaProps>; type InfoProps = { width?: string; height?: string; strokeColor?: string; }; declare const Info: React$1.FC<InfoProps>; type IrregularHeartbeatCountProps = { width?: string; height?: string; strokeColor?: string; }; declare const IrregularHeartbeatCount: FC<IrregularHeartbeatCountProps>; type MaleGenderProps = { width?: string; height?: string; strokeColor?: string; }; declare const MaleGender: FC<MaleGenderProps>; type ManProps = { width?: string; height?: string; strokeColor?: string; }; declare const Man: React$1.FC<ManProps>; type MentalStressIndexProps = { width?: string; height?: string; strokeColor?: string; }; declare const MentalStressIndex: FC<MentalStressIndexProps>; type OverallMetabolicHealthRiskProps = { width?: string; height?: string; strokeColor?: string; }; declare const OverallMetabolicHealthRisk: FC<OverallMetabolicHealthRiskProps>; type PulseRateProps = { width?: string; height?: string; strokeColor?: string; }; declare const PulseRate: FC<PulseRateProps>; interface RotateProps { width?: string; height?: string; strokeColor?: string; } declare const Rotate: React$1.FC<RotateProps>; interface StarProps { width?: string; height?: string; fill?: string; strokeColor?: string; } declare const Star: React$1.FC<StarProps>; type StopwatchProps = { width?: string; height?: string; strokeColor?: string; }; declare const Stopwatch: React$1.FC<StopwatchProps>; type StrokeRiskProps = { width?: string; height?: string; strokeColor?: string; }; declare const StrokeRisk: FC<StrokeRiskProps>; type Type2DiabetesRiskProps = { width?: string; height?: string; strokeColor?: string; }; declare const Type2DiabetesRisk: FC<Type2DiabetesRiskProps>; type VascularCapacityProps = { width?: string; height?: string; strokeColor?: string; }; declare const VascularCapacity: FC<VascularCapacityProps>; type WaistToHeightProps = { width?: string; height?: string; strokeColor?: string; }; declare const WaistToHeight: FC<WaistToHeightProps>; interface WarningProps { width?: string; height?: string; strokeColor?: string; } declare const Warning: React$1.FC<WarningProps>; interface WomanProps { width?: string; height?: string; strokeColor?: string; } declare const Woman: React$1.FC<WomanProps>; interface TablePaginationProps { count: number; rowsPerPage: number[]; initialPage?: number; onPageChange?: (page: number) => void; onRowsPerPageChange?: (newRowsPerPage: number) => void; size?: 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; } declare const TablePagination: React$1.FC<TablePaginationProps>; interface Tab { label: string; content: React.ReactNode; } interface TabsProps { tabs: Tab[]; } declare const Tabs: React$1.FC<TabsProps>; declare const Text: React$1.FC<PropsWithChildren<TextProps>>; interface TextInputProps extends BaseInputProps { value?: string; } declare const TextInput: React$1.FC<PropsWithChildren<TextInputProps>>; interface ThemeToggleProps { isDarkMode: boolean; onToggle: () => void; } declare const Toggle: React$1.FC<ThemeToggleProps>; interface VerificationInputProps { length: number; inputMode?: 'numeric' | 'text'; placeholder?: string; passwordMode?: boolean; onComplete: (code: string) => void; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; backgroundColor?: string; focusColor?: string; borderRadius?: 'none' | 'small' | 'normal' | 'medium' | 'large' | 'extraLarge' | 'full'; boxShadow?: 'small' | 'regular' | 'medium' | 'large' | 'inner' | 'none'; everyThirdGap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; } declare const VerificationInput: React$1.FC<VerificationInputProps>; interface CardProps extends React$1.HTMLAttributes<HTMLDivElement> { width?: string; height?: string; margin?: string; padding?: string; xstyle?: StyleXStyles; } declare const Card: React$1.FC<PropsWithChildren<CardProps>>; interface ContainerProps { height?: string; padding?: string; children?: React.ReactNode; } declare const Container: React$1.FC<ContainerProps>; interface FlexProps { direction?: 'row' | 'column' | 'row-reverse' | 'column-reverse'; wrap?: boolean; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; padding?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; margin?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; alignItems?: 'start' | 'end' | 'center' | 'stretch'; justifyItems?: 'start' | 'end' | 'center' | 'stretch'; alignContent?: 'normal' | 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly' | 'stretch'; justifyContent?: 'normal' | 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly' | 'stretch'; alignSelf?: 'auto' | 'start' | 'end' | 'center' | 'stretch'; justifySelf?: 'auto' | 'start' | 'end' | 'center' | 'stretch'; } declare const Flex: React$1.FC<PropsWithChildren<FlexProps>>; interface GridProps { columns?: 'none' | 'subgrid' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12'; rows?: 'none' | 'subgrid' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9' | '10' | '11' | '12'; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; padding?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; margin?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; alignItems?: 'start' | 'end' | 'center' | 'stretch'; justifyItems?: 'start' | 'end' | 'center' | 'stretch'; alignContent?: 'normal' | 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly' | 'stretch'; justifyContent?: 'normal' | 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly' | 'stretch'; alignSelf?: 'auto' | 'start' | 'end' | 'center' | 'stretch'; justifySelf?: 'auto' | 'start' | 'end' | 'center' | 'stretch'; } declare const Grid: React$1.FC<PropsWithChildren<GridProps>>; interface StackProps { wrap?: boolean; gap?: 'none' | 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl'; justifyContent?: 'normal' | 'flex-start' | 'flex-end' | 'center' | 'space-between' | 'space-around' | 'space-evenly' | 'stretch'; alignItems?: 'start' | 'end' | 'center' | 'stretch'; } declare const Stack: React$1.FC<PropsWithChildren<StackProps>>; declare const themeTokens: { colorTokens: _stylexjs_stylex.VarGroup<Readonly<{ primary: string; secondary: string; svgPrimary: string; svgSecondary: string; textPrimary: string; textSecondary: string; textHighlight: string; dfxPointBandGreen: string; dfxPointBandLightGreen: string; dfxPointBandYellow: string; dfxPointBandLightRed: string; dfxPointBandRed: string; backgroundPrimary: string; backgroundSecondary: string; backgroundTertiary: string; placeholder: string; warning: string; danger: string; success: string; outline: string; borderPrimary: string; }>, symbol>; sizeTokens: _stylexjs_stylex.VarGroup<Readonly<{ none: string; xxs: string; xs: string; s: string; m: string; l: string; xl: string; xxl: string; }>, symbol>; spaceTokens: _stylexjs_stylex.VarGroup<Readonly<{ "0": string; "1": string; "2": string; "3": string; "4": string; "5": string; "6": string; "7": string; "8": string; "9": string; "10": string; px: string; "0.5": string; "1.5": string; "2.5": string; "3.5": string; full: string; }>, symbol>; shadowTokens: _stylexjs_stylex.VarGroup<Readonly<{ small: string; regular: string; medium: string; large: string; inner: string; none: string; }>, symbol>; fontSizeTokens: _stylexjs_stylex.VarGroup<Readonly<{ xxs: string; xs: string; s: string; base: string; m: string; l: string; xl: string; xxl: string; }>, symbol>; fontTokens: _stylexjs_stylex.VarGroup<Readonly<{ family: string; familyCode: string; weightLighter: string; weightLight: string; weightSemiLight: string; weightNormal: string; weightMedium: string; weightSemiBold: string; weightBold: string; weightBolder: string; weightExtraBold: string; spacingTighter: string; spacingTight: string; spacingNormal: string; spacingWide: string; spacingWider: string; spacingWidest: string; }>, symbol>; leadingTokens: _stylexjs_stylex.VarGroup<Readonly<{ none: string; tight: string; normal: string; relaxed: string; loose: string; extraLoose: string; }>, symbol>; borderRadiusTokens: _stylexjs_stylex.VarGroup<Readonly<{ none: string; small: string; normal: string; medium: string; large: string; extraLarge: string; full: string; }>, symbol>; filterTokens: _stylexjs_stylex.VarGroup<Readonly<{ blurNone: string; blurSmall: string; blurMedium: string; blurLarge: string; }>, symbol>; transitionTokens: _stylexjs_stylex.VarGroup<Readonly<{ none: string; fast: string; slow: string; slower: string; }>, symbol>; elevationTokens: _stylexjs_stylex.VarGroup<Readonly<{ "10": string; "20": string; "30": string; "40": string; "50": string; behind: string; auto: string; }>, symbol>; }; type ThemeTokens = typeof themeTokens; interface ThemeProviderProps { theme: ThemeTokens; children: ReactNode; } declare const ThemeProvider: React$1.FC<ThemeProviderProps>; export { Accordion, BaseInput, BloodPressure, BodyMassIndex, BodyShapeIndex, BodyTemperature, Breathing, Button, Camera, Card, CardiacWorkload, CardioVascularDiseaseRisk, Carousel, Checkbox, Checkmark, Chevron, ColorBox, Container, Cross, DatePicker, Dial, FacialSkinAge, FastingBloodGlucose, FattyLiverDiseaseRisk, FemaleGender, Flex, Glasses, Grid, HamburgerMenu, Heading, HealthScore, HeartAttackRisk, HeartRateVariability, Help, HemoglobinA1C, Hr, Hypercholesterolemia, Hypertension, Hypertriglyceridemia, Info, IrregularHeartbeatCount, Label, Loading, MaleGender, Man, MentalStressIndex, Menu, Modal, OverallMetabolicHealthRisk, Pagination, Paragraph, Popover, Popup, ProgressBar, PulseRate, RadioButtonGroup, ResultsCard, Rotate, Select, SimpleTable, Stack, Star, StarRating, Stopwatch, StrokeRisk, TablePagination, Tabs, Text, TextInput, ThemeProvider, Toggle as ThemeToggle, Type2DiabetesRisk, VascularCapacity, VerificationInput, WaistToHeight, Warning, Woman };