mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-14 18:01:06 +00:00
Alignment with Carbon version 10.32 (#588)
* feat(code-snippet): add copy functionality - docs: add custom feedback copy text example * feat(tile): support disabled state for SelectableTile, RadioTile Closes #539 * build(rollup): add clipboard-copy to globals * feat(copy-button): add copy functionality * feat(content-switcher): deprecate the light prop - docs: remove the light variant example * fix(toolbar-search): remove outer div * feat(search): add searchClass prop * fix(composed-modal): set hasScrollingContent class on ModalBody * docs(data-table): add expandable size examples * feat(tooltip): add TooltipFooter component * fix(time-picker): correctly display invalidText * feat(breadcrumb): support overflow menu * feat(multi-select): export inputRef prop * chore(deps-dev): upgrade carbon-components to v10.32.0 * feat(form): add noMargin prop to FormGroup * docs(tooltip): document TooltipFooter * feat(context-menu): support danger kind for ContextMenuOption * feat(data-table): support rendering empty table header in skeleton * refactor(types): use shorter import path in DataTableSkeleton * feat(data-table): allow sorting to be disabled for a specific header * docs(data-table): update example to desort the Protocol header As an example, it makes more sense because all the values ("http") are the same. * fix(context-menu): set initial y offset of context menu based on window height #577 * fix(context-menu): render submenu based on viewport constraints #577
This commit is contained in:
parent
f13e3b100e
commit
fa9b90cd79
61 changed files with 825 additions and 233 deletions
6
types/DataTable/DataTable.d.ts
vendored
6
types/DataTable/DataTable.d.ts
vendored
|
@ -9,7 +9,7 @@ export interface DataTableEmptyHeader {
|
|||
key: DataTableKey;
|
||||
empty: boolean;
|
||||
display?: (item: Value) => DataTableValue;
|
||||
sort?: (a: DataTableValue, b: DataTableValue) => 0 | -1 | 1;
|
||||
sort?: false | ((a: DataTableValue, b: DataTableValue) => 0 | -1 | 1);
|
||||
columnMenu?: boolean;
|
||||
}
|
||||
|
||||
|
@ -17,7 +17,7 @@ export interface DataTableNonEmptyHeader {
|
|||
key: DataTableKey;
|
||||
value: DataTableValue;
|
||||
display?: (item: Value) => DataTableValue;
|
||||
sort?: (a: DataTableValue, b: DataTableValue) => 0 | -1 | 1;
|
||||
sort?: false | ((a: DataTableValue, b: DataTableValue) => 0 | -1 | 1);
|
||||
columnMenu?: boolean;
|
||||
}
|
||||
|
||||
|
@ -141,7 +141,7 @@ export default class DataTable extends SvelteComponentTyped<
|
|||
["click:header--expand"]: CustomEvent<{ expanded: boolean }>;
|
||||
["click:header"]: CustomEvent<{
|
||||
header: DataTableHeader;
|
||||
sortDirection: "ascending" | "descending" | "none";
|
||||
sortDirection?: "ascending" | "descending" | "none";
|
||||
}>;
|
||||
["click:row"]: CustomEvent<DataTableRow>;
|
||||
["mouseenter:row"]: CustomEvent<DataTableRow>;
|
||||
|
|
2
types/DataTable/DataTableSkeleton.d.ts
vendored
2
types/DataTable/DataTableSkeleton.d.ts
vendored
|
@ -1,6 +1,6 @@
|
|||
/// <reference types="svelte" />
|
||||
import { SvelteComponentTyped } from "svelte";
|
||||
import { DataTableHeader } from "../DataTable/DataTable";
|
||||
import { DataTableHeader } from "./DataTable";
|
||||
|
||||
export interface DataTableSkeletonProps
|
||||
extends DataTableHeader,
|
||||
|
|
6
types/DataTable/TableHeader.d.ts
vendored
6
types/DataTable/TableHeader.d.ts
vendored
|
@ -3,6 +3,12 @@ import { SvelteComponentTyped } from "svelte";
|
|||
|
||||
export interface TableHeaderProps
|
||||
extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["th"]> {
|
||||
/**
|
||||
* Set to `true` to disable sorting on this specific cell
|
||||
* @default false
|
||||
*/
|
||||
disableSorting?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the `scope` attribute
|
||||
* @default "col"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue