UNPKG

@capgeminiuk/dcx-react-library

Version:

[![CircleCI](https://circleci.com/gh/Capgemini/dcx-react-library.svg?style=svg)](https://circleci.com/gh/Capgemini/dcx-react-library)

65 lines (64 loc) 1.99 kB
import React, { ReactNode } from 'react'; export declare enum TYPE_LIST { UNORDERED = "unordered", ORDERED = "ordered" } export type UnorderedListType = { /** * allow to specify if the list is ul (unordered) or ol (ordered), with default value unordered. * To specify the type of list please pass: TYPE_LIST. UNORDERED or TYPE_LIST. ORDERED */ type?: TYPE_LIST.UNORDERED; /** * A CSS class for styling list */ className?: string; /** * A CSS class for applying the same styling in case all the items have exactly the same look and feel */ itemClassName?: string; /** * allow to specify a user custom content */ children: ReactNode; /** * allow to specify a user with Additional props/attributes */ listProps?: React.HTMLAttributes<HTMLUListElement>; }; export type OrderedListType = { /** * allow to specify if the list is ul (unordered) or ol (ordered), with default value unordered. * To specify the type of list please pass: TYPE_LIST. UNORDERED or TYPE_LIST. ORDERED */ type?: TYPE_LIST.ORDERED; /** * A CSS class for styling list */ className?: string; /** * A CSS class for applying the same styling in case all the items have exactly the same look and feel */ itemClassName?: string; /** * allow to specify a user custom content */ children: ReactNode; /** * allow to specify a user with Additional props/attributes */ listProps?: React.HTMLAttributes<HTMLOListElement>; /** * specifies the list order should be in descending order */ reversed?: boolean; /** * specifies the start value of the first list item */ start?: number; /** * specifies the type of marking among "1 - a - A - i - I" */ markerType?: 'a' | 'i' | '1' | 'A' | 'I'; }; export declare const List: (props: OrderedListType | UnorderedListType) => React.JSX.Element;