FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix(docs): updated table property descriptions by ddonahue007 · Pull Request #3745 · patternfly/patternfly-react · GitHub

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .tsx  (3) All 1 file type selected
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
    • Body.tsx
    • Header.tsx
    • Table.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,19 @@ export type OnRowClick = (
) => void;

export interface TableBodyProps {
/** Additional classes added to the TableBody */
className?: string;
/** This prop should not be set manually */
children?: React.ReactNode;
/** This prop should not be set manually */
headerData?: IRow[];
/** This prop should not be set manually */
rows?: IRow[];
/** This prop should not be set manually */
rowKey?: RowKeyType;
/** This prop should not be set manually */
onRowClick?: OnRowClick;
/** This prop should not be set manually */
onRow?: Function;
}

Expand Down
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ const ContextHeader: React.FunctionComponent<ContextHeaderProps> = ({
}: ContextHeaderProps) => <Header {...props} headerRows={headerRows as ColumnsType} className={className} />;

export interface HeaderProps extends React.HTMLProps<HTMLTableRowElement> {
/** Additional classes added to the TableHeader */
className?: string;
}

Expand Down
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -203,13 +203,17 @@ export interface IRow extends RowType {
}

export interface TableProps {
/** Adds an accessible name for the Table */
'aria-label'?: string;
/** Content rendered inside the Table */
children?: React.ReactNode;
/** Additional classes added to the Table */
className?: string;
/** Style variant for the Table */
variant?: 'compact';
/** Render borders */
borders?: boolean;
/** Specifies the grid breakpoints */
gridBreakPoint?: '' | 'grid' | 'grid-md' | 'grid-lg' | 'grid-xl' | 'grid-2xl';
/** Specifies the initial sorting pattern for the table - asc/desc and the index of the column to sort by */
sortBy?: ISortBy;
Expand All @@ -219,25 +223,37 @@ export interface TableProps {
onExpand?: OnExpand;
/** Function triggered when a row's checkbox is selected. When this is used, one checkbox will be positioned in the first or second cell of a non-expandable row */
onSelect?: OnSelect;
/** Enables or Disables the ability to select all */
canSelectAll?: boolean;
/** Function triggered when sort icon is clicked */
onSort?: OnSort;
/** Actions to add to the Table */
actions?: IActions;
/** Resolver for the given action */
actionResolver?: IActionsResolver;
/** Specifies if the Kebab for actions is disabled */
areActionsDisabled?: IAreActionsDisabled;
/** Component to place in the header */
header?: React.ReactNode;
/** Component used for caption*/
caption?: React.ReactNode;
/** label for row */
rowLabeledBy?: string;
/** ID for expand */
expandId?: string;
/** ID for content */
contentId?: string;
/** The desired position to show the dropdown when clicking on the actions Kebab. Can only be used together with `actions` property */
dropdownPosition?: 'right' | 'left';
/** The desired direction to show the dropdown when clicking on the actions Kebab. Can only be used together with `actions` property */
dropdownDirection?: 'up' | 'down';
/** Row data */
rows: (IRow | string[])[];
/** Cell data */
cells: (ICell | string)[];
/** Wrapper for the body */
bodyWrapper?: Function;
/** Wrapper for the row */
rowWrapper?: (props: RowWrapperProps) => JSX.Element;
/** A valid WAI-ARIA role to be applied to the table element */
role?: string;
Expand Down

Back | FazBrowse Home | New Git URL