Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #6376: Typescript boolean instead of false #6378

Merged
merged 1 commit into from
Apr 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 27 additions & 27 deletions components/lib/datatable/datatable.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1022,7 +1022,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Whether to show it even there is only one page.
* @defaultValue true
*/
alwaysShowPaginator?: boolean | undefined;
alwaysShowPaginator?: boolean;
/**
* The breakpoint to define the maximum width boundary when using stack responsive layout.
* @defaultValue 960px
Expand Down Expand Up @@ -1078,7 +1078,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* When enabled, a rectangle that can be dragged can be used to make a range selection.
* @defaultValue false
*/
dragSelection?: boolean | undefined;
dragSelection?: boolean;
/**
* Defines editing mode, options are "cell" and "row".
* @defaultValue cell
Expand All @@ -1097,7 +1097,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Makes row groups toggleable, default is false.
* @defaultValue false
*/
expandableRowGroups?: boolean | undefined;
expandableRowGroups?: boolean;
/**
* Icon of the row toggler to display the row as expanded.
*/
Expand Down Expand Up @@ -1193,12 +1193,12 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Defines if data is loaded and interacted with in lazy manner.
* @defaultValue false
*/
lazy?: boolean | undefined;
lazy?: boolean;
/**
* Displays a loader to indicate data load is in progress.
* @defaultValue false
*/
loading?: boolean | undefined;
loading?: boolean;
/**
* The icon to show while indicating data load is in progress.
*/
Expand All @@ -1207,7 +1207,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Defines whether metaKey is requred or not for the selection. When true metaKey needs to be pressed to select or unselect an item and when set to false selection of each item can be toggled individually. On touch enabled devices, metaKeySelection is turned off automatically.
* @defaultValue true
*/
metaKeySelection?: boolean | undefined;
metaKeySelection?: boolean;
/**
* An array of SortMeta objects to sort the data by default in multiple sort mode.
*/
Expand All @@ -1221,7 +1221,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* When specified as true, enables the pagination.
* @defaultValue false
*/
paginator?: boolean | undefined;
paginator?: boolean;
/**
* Style class of the paginator element.
*/
Expand Down Expand Up @@ -1253,17 +1253,17 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* When enabled, columns can have an un-sorted state.
* @defaultValue false
*/
removableSort?: boolean | undefined;
removableSort?: boolean;
/**
* When enabled, columns can be reordered using drag and drop.
* @defaultValue false
*/
reorderableColumns?: boolean | undefined;
reorderableColumns?: boolean;
/**
* When enabled, rows can be reordered using drag and drop.
* @defaultValue false
*/
reorderableRows?: boolean | undefined;
reorderableRows?: boolean;
/**
* Defines the reorder indicator down icon.
*/
Expand All @@ -1276,7 +1276,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* When enabled, columns can be resized using drag and drop.
* @defaultValue false
*/
resizableColumns?: boolean | undefined;
resizableColumns?: boolean;
/**
* Defines the responsive mode, valid options are "stack" and "scroll".
* @defaultValue scroll
Expand Down Expand Up @@ -1310,7 +1310,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
/**
* When enabled, background of the rows change on hover.
*/
rowHover?: boolean | undefined;
rowHover?: boolean;
/**
* Number of rows to display per page.
*/
Expand All @@ -1327,22 +1327,22 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* When specified, enables horizontal and/or vertical scrolling.
* @defaultValue false
*/
scrollable?: boolean | undefined;
scrollable?: boolean;
/**
* When specified, selects all rows on page.
* @defaultValue false
*/
selectAll?: boolean | undefined;
selectAll?: boolean;
/**
* Determines whether the cell editor will be opened when clicking to select any row on Selection and Cell Edit modes.
* @defaultValue true
*/
selectOnEdit?: boolean | undefined;
selectOnEdit?: boolean;
/**
* When a selectable row is clicked on RadioButton and Checkbox selection, it automatically decides whether to focus on elements such as checkbox or radio.
* @defaultValue true
*/
selectionAutoFocus?: boolean | undefined;
selectionAutoFocus?: boolean;
/**
* A field property from the row to add Select &#123;field&#125; and Unselect &#123;field&#125; ARIA labels to checkbox/radio buttons.
*/
Expand All @@ -1351,21 +1351,21 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* When enabled with paginator and checkbox selection mode, the select all checkbox in the header will select all rows on the current page.
* @defaultValue false
*/
selectionPageOnly?: boolean | undefined;
selectionPageOnly?: boolean;
/**
* Whether to show grid lines between cells.
* @defaultValue false
*/
showGridlines?: boolean | undefined;
showGridlines?: boolean;
/**
* Whether to show headers.
* @defaultValue true
*/
showHeaders?: boolean | undefined;
showHeaders?: boolean;
/**
* Whether to show the select all checkbox inside the datatable's header.
*/
showSelectAll?: boolean | undefined;
showSelectAll?: boolean;
/**
* Define to set alternative sizes. Valid values: "small", "normal" and "large".
* @defaultValue normal
Expand Down Expand Up @@ -1401,7 +1401,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Whether to displays rows with alternating colors.
* @defaultValue false
*/
stripedRows?: boolean | undefined;
stripedRows?: boolean;
/**
* Inline style of the component.
*/
Expand Down Expand Up @@ -1454,7 +1454,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Function that returns a boolean to decide whether the data should be selectable.
* @param {DataTableDataSelectableEvent<TValue>} event - Custom data selectable event.
*/
isDataSelectable?(event: DataTableDataSelectableEvent): boolean | undefined | null;
isDataSelectable?(event: DataTableDataSelectableEvent): boolean | null;
/**
* Callback to invoke when all rows are selected using the header checkbox.
* @param {DataTableSelectEvent} event - Custom select event.
Expand Down Expand Up @@ -1634,7 +1634,7 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* Callback to invoke to validate the editing row when the save icon is clicked on row editing mode.
* @param {DataTableRowData<TValue>} data - Editing row data.
*/
rowEditValidator?(data: DataTableRowData<TValue>, options: DataTableRowEditValidatorOptions<TValue>): boolean | undefined;
rowEditValidator?(data: DataTableRowData<TValue>, options: DataTableRowEditValidatorOptions<TValue>): boolean;
/**
* Function that receives the row data as the parameter and returns the expanded row content. You can override the rendering of the content by setting options.customRendering = true.
* @param {DataTableRowData<TValue>} data - Editing row data.
Expand All @@ -1646,13 +1646,13 @@ interface DataTableBaseProps<TValue extends DataTableValueArray> extends Omit<Re
* @param {DataTableRowData<TValue>} data - Editing row data.
* @param {DataTableShowRowReorderElementOptions} options - Options for the row reorder element.
*/
showRowReorderElement?(data: DataTableRowData<TValue>, options: DataTableShowRowReorderElementOptions<TValue>): boolean | undefined | null;
showRowReorderElement?(data: DataTableRowData<TValue>, options: DataTableShowRowReorderElementOptions<TValue>): boolean | null;
/**
* Function that returns a boolean by passing the row data to decide if the radio or checkbox should be displayed per row.
* @param {DataTableRowData<TValue>} data - Editing row data.
* @param {DataTableShowSelectionElementOptions} options - Options for the row reorder element.
*/
showSelectionElement?(data: DataTableRowData<TValue>, options: DataTableShowSelectionElementOptions<TValue>): boolean | undefined | null;
showSelectionElement?(data: DataTableRowData<TValue>, options: DataTableShowSelectionElementOptions<TValue>): boolean | null;
/**
* Used to get the child elements of the component.
* @readonly
Expand Down Expand Up @@ -1684,7 +1684,7 @@ interface DataTablePropsSingle<TValue extends DataTableValueArray> extends DataT
* Whether to cell selection is enabled or not.
* @defaultValue false
*/
cellSelection?: false | undefined;
cellSelection?: boolean;
/**
* Specifies the selection mode, valid values are "single", "multiple", "radiobutton" and "checkbox".
*/
Expand Down Expand Up @@ -1714,7 +1714,7 @@ interface DataTablePropsMultiple<TValue extends DataTableValueArray> extends Dat
* Whether to cell selection is enabled or not.
* @defaultValue false
*/
cellSelection?: false | undefined;
cellSelection?: boolean;
/**
* Specifies the selection mode, valid values are "single", "multiple", "radiobutton" and "checkbox".
*/
Expand Down
34 changes: 17 additions & 17 deletions components/lib/dropdown/dropdown.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When present, it specifies that the component should automatically get focus on load.
* @defaultValue false
*/
autoFocus?: boolean | undefined;
autoFocus?: boolean;
/**
* Style class of the component.
*/
Expand All @@ -266,12 +266,12 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When present, it specifies that the component should have invalid state style.
* @defaultValue false
*/
invalid?: boolean | undefined;
invalid?: boolean;
/**
* When present, it specifies that the component should be disabled.
* @defaultValue false
*/
disabled?: boolean | undefined;
disabled?: boolean;
/**
* Specifies the input variant of the component.
* @defaultValue outlined
Expand All @@ -285,17 +285,17 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When present, custom value instead of predefined options can be entered using the editable input field.
* @defaultValue false
*/
editable?: boolean | undefined;
editable?: boolean;
/**
* Whether the selected option will be add highlight class.
* @defaultValue true
*/
highlightOnSelect?: boolean | undefined;
highlightOnSelect?: boolean;
/**
* Whether the selected option will be shown with a check mark.
* @defaultValue false
*/
checkmark?: boolean | undefined;
checkmark?: boolean;
/**
* Template to display when filtering does not return any results.
* @defaultValue No available options
Expand All @@ -310,7 +310,7 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When specified, displays an input field to filter the items on keyup.
* @defaultValue false
*/
filter?: boolean | undefined;
filter?: boolean;
/**
* Icon of the filter to search.
*/
Expand All @@ -328,7 +328,7 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When the panel is opened, it specifies that the filter input should focus automatically.
* @defaultValue false
*/
filterInputAutoFocus?: boolean | undefined;
filterInputAutoFocus?: boolean;
/**
* Locale to use in filtering. The default locale is the host environment's current locale.
*/
Expand Down Expand Up @@ -359,17 +359,17 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When enabled, the focused tab is activated.
* @defaultValue false
*/
selectOnFocus?: false;
selectOnFocus?: boolean;
/**
* When enabled, the focus is placed on the hovered option.
* @defaultValue true
*/
focusOnHover?: boolean | undefined;
focusOnHover?: boolean;
/**
* Whether to focus on the first visible or selected element.
* @defaultValue false
*/
autoOptionFocus?: false;
autoOptionFocus?: boolean;
/**
* Identifier of the focusable input.
*/
Expand All @@ -386,7 +386,7 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* Displays a loader to indicate data load is in progress.
* @defaultValue false
*/
loading?: boolean | undefined;
loading?: boolean;
/**
* The icon to show while indicating data load is in progress.
*/
Expand Down Expand Up @@ -449,12 +449,12 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When present, it specifies that an input field must be filled out before submitting the form.
* @defaultValue false
*/
required?: boolean | undefined;
required?: boolean;
/**
* Clears the filter value when hiding the dropdown.
* @defaultValue false
*/
resetFilterOnHide?: boolean | undefined;
resetFilterOnHide?: boolean;
/**
* Height of the viewport in pixels, a scrollbar is defined if height of list exceeds this value.
* @defaultValue 200px
Expand All @@ -464,17 +464,17 @@ export interface DropdownProps extends Omit<React.DetailedHTMLProps<React.InputH
* When enabled, a clear icon is displayed to clear the value.
* @defaultValue false
*/
showClear?: boolean | undefined;
showClear?: boolean;
/**
* When enabled, a clear icon is displayed to clear the filtered value.
* @defaultValue false
*/
showFilterClear?: boolean | undefined;
showFilterClear?: boolean;
/**
* When enabled, overlay panel will be visible with input focus.
* @defaultValue false
*/
showOnFocus?: boolean | undefined;
showOnFocus?: boolean;
/**
* Inline style of the element.
*/
Expand Down
Loading
Loading