pragmate-ui
Version:
An advanced, on-demand React UI library optimized for BeyondJS. Pragmate UI provides modular, responsive, and accessible components with a focus on efficient bundle sizes and a streamlined development process.
143 lines (125 loc) • 3.41 kB
TypeScript
/************
Processor: ts
************/
import * as __beyond_dep_ns_0 from 'react';
import __beyond_dep_def_0 from 'react';
// components\add-item.tsx
declare namespace ns_0 {
import React = __beyond_dep_def_0;
export function AddDynamicItem(): React.JSX.Element;
}
// components\dragabble-list.tsx
declare namespace ns_1 {
import React = __beyond_dep_def_0;
export function DraggableList({
children,
className
}: {
children: any;
className?: string;
}): React.JSX.Element;
}
// components\header.tsx
declare namespace ns_2 {
import React = __beyond_dep_def_0;
export function Header({
children
}: {
children: any;
}): React.JSX.Element;
}
// components\item.tsx
declare namespace ns_3 {
import React = __beyond_dep_def_0;
export function DynamicItem(props: any): React.JSX.Element;
}
// components\list.tsx
declare namespace ns_4 {
import React = __beyond_dep_def_0;
import IPuiProps = ns_6.IPuiProps;
export function List({
className
}: IPuiProps): React.JSX.Element;
}
// context.tsx
declare namespace ns_5 {
import React = __beyond_dep_def_0;
import IDynamicContext = ns_6.IDynamicContext;
export const DynamicListContext: React.Context<IDynamicContext>;
export const useDynamicListContext: () => IDynamicContext;
}
// definitions.ts
declare namespace ns_6 {
import HTMLAttributes = __beyond_dep_ns_0.HTMLAttributes;
export interface IDynamicContext {
addItem?: () => void;
removeItem?: (index: number) => void;
values?: any[];
setValue: (index: any, value: any) => void;
setValues?: (values: any[]) => void;
setItems?: (items: any[]) => void;
draggable?: boolean;
name: string;
getDefaultValue?: () => any;
registerRef: (index: number, ref: any) => void;
refs: React.MutableRefObject<any[]>;
orderValues?: string[];
Item?: React.ComponentType<any>;
}
export interface IPUIEvent {
target: {
name: string;
value: any;
};
currentTarget: {
name: string;
value: any;
};
}
export interface DynamicListProps {
children?: React.ReactNode;
className?: string;
onChange?: (data: IPUIEvent) => void;
value?: any[];
name: string;
defaultValue?: any;
draggable?: boolean;
specs?: Record<string, any>;
Item: React.ComponentType<any>;
}
export type DynamicItemProps = {
value?: any;
className?: string;
};
export interface IPuiFormProps {
className?: string;
onChange?: (data: IPUIEvent) => void;
value?: any;
name: string;
defaultValue?: any;
}
export interface IPuiProps extends HTMLAttributes<HTMLElement> {}
}
// provider.tsx
declare namespace ns_7 {
import React = __beyond_dep_def_0;
import DynamicListProps = ns_6.DynamicListProps;
export function Provider({
name,
onChange,
draggable,
children,
value,
Item,
specs,
className
}: DynamicListProps): React.JSX.Element;
}
export import AddDynamicItem = ns_0.AddDynamicItem;
export import DraggableList = ns_1.DraggableList;
export import Header = ns_2.Header;
export import DynamicItem = ns_3.DynamicItem;
export import List = ns_4.List;
export import useDynamicListContext = ns_5.useDynamicListContext;
export import Provider = ns_7.Provider;
export declare const hmr: {on: (event: string, listener: any) => void, off: (event: string, listener: any) => void };