mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-14 18:01:06 +00:00
refactor(types): shorten ref, id JSDocs, use CarbonIcon type, export component props
This commit is contained in:
parent
d38e6d8be6
commit
75d4b4cf03
219 changed files with 5168 additions and 5259 deletions
53
types/ProgressIndicator/ProgressIndicator.d.ts
vendored
53
types/ProgressIndicator/ProgressIndicator.d.ts
vendored
|
@ -1,32 +1,33 @@
|
|||
/// <reference types="svelte" />
|
||||
|
||||
export interface ProgressIndicatorProps extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> {
|
||||
/**
|
||||
* Specify the current step index
|
||||
* @default 0
|
||||
*/
|
||||
currentIndex?: number;
|
||||
|
||||
/**
|
||||
* Set to `true` to use the vertical variant
|
||||
* @default false
|
||||
*/
|
||||
vertical?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to specify whether the progress steps should be split equally in size in the div
|
||||
* @default false
|
||||
*/
|
||||
spaceEqually?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to prevent updating `currentIndex`
|
||||
* @default false
|
||||
*/
|
||||
preventChangeOnClick?: boolean;
|
||||
}
|
||||
|
||||
export default class ProgressIndicator {
|
||||
$$prop_def: svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> & {
|
||||
/**
|
||||
* Specify the current step index
|
||||
* @default 0
|
||||
*/
|
||||
currentIndex?: number;
|
||||
|
||||
/**
|
||||
* Set to `true` to use the vertical variant
|
||||
* @default false
|
||||
*/
|
||||
vertical?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to specify whether the progress steps should be split equally in size in the div
|
||||
* @default false
|
||||
*/
|
||||
spaceEqually?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to prevent updating `currentIndex`
|
||||
* @default false
|
||||
*/
|
||||
preventChangeOnClick?: boolean;
|
||||
};
|
||||
|
||||
$$prop_def: ProgressIndicatorProps;
|
||||
$$slot_def: {
|
||||
default: {};
|
||||
};
|
||||
|
|
|
@ -1,20 +1,21 @@
|
|||
/// <reference types="svelte" />
|
||||
|
||||
export interface ProgressIndicatorSkeletonProps extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> {
|
||||
/**
|
||||
* Set to `true` to use the vertical variant
|
||||
* @default false
|
||||
*/
|
||||
vertical?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the number of steps to render
|
||||
* @default 4
|
||||
*/
|
||||
count?: number;
|
||||
}
|
||||
|
||||
export default class ProgressIndicatorSkeleton {
|
||||
$$prop_def: svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["ul"]> & {
|
||||
/**
|
||||
* Set to `true` to use the vertical variant
|
||||
* @default false
|
||||
*/
|
||||
vertical?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the number of steps to render
|
||||
* @default 4
|
||||
*/
|
||||
count?: number;
|
||||
};
|
||||
|
||||
$$prop_def: ProgressIndicatorSkeletonProps;
|
||||
$$slot_def: {};
|
||||
|
||||
$on(eventname: "click", cb: (event: WindowEventMap["click"]) => void): () => void;
|
||||
|
|
100
types/ProgressIndicator/ProgressStep.d.ts
vendored
100
types/ProgressIndicator/ProgressStep.d.ts
vendored
|
@ -1,55 +1,57 @@
|
|||
/// <reference types="svelte" />
|
||||
|
||||
export interface ProgressStepProps extends svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["li"]> {
|
||||
/**
|
||||
* Set to `true` for the complete variant
|
||||
* @default false
|
||||
*/
|
||||
complete?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to use the current variant
|
||||
* @default false
|
||||
*/
|
||||
current?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to disable the progress step
|
||||
* @default false
|
||||
*/
|
||||
disabled?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to indicate an invalid state
|
||||
* @default false
|
||||
*/
|
||||
invalid?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the step description
|
||||
* @default ""
|
||||
*/
|
||||
description?: string;
|
||||
|
||||
/**
|
||||
* Specify the step label
|
||||
* @default ""
|
||||
*/
|
||||
label?: string;
|
||||
|
||||
/**
|
||||
* Specify the step secondary label
|
||||
* @default ""
|
||||
*/
|
||||
secondaryLabel?: string;
|
||||
|
||||
/**
|
||||
* Set an id for the top-level element
|
||||
* @default "ccs-" + Math.random().toString(36)
|
||||
*/
|
||||
id?: string;
|
||||
}
|
||||
|
||||
export default class ProgressStep {
|
||||
$$prop_def: svelte.JSX.HTMLAttributes<HTMLElementTagNameMap["li"]> & {
|
||||
/**
|
||||
* Set to `true` for the complete variant
|
||||
* @default false
|
||||
*/
|
||||
complete?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to use the current variant
|
||||
* @default false
|
||||
*/
|
||||
current?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to disable the progress step
|
||||
* @default false
|
||||
*/
|
||||
disabled?: boolean;
|
||||
|
||||
/**
|
||||
* Set to `true` to indicate an invalid state
|
||||
* @default false
|
||||
*/
|
||||
invalid?: boolean;
|
||||
|
||||
/**
|
||||
* Specify the step description
|
||||
* @default ""
|
||||
*/
|
||||
description?: string;
|
||||
|
||||
/**
|
||||
* Specify the step label
|
||||
* @default ""
|
||||
*/
|
||||
label?: string;
|
||||
|
||||
/**
|
||||
* Specify the step secondary label
|
||||
* @default ""
|
||||
*/
|
||||
secondaryLabel?: string;
|
||||
|
||||
/**
|
||||
* Set an id for the top-level element
|
||||
*/
|
||||
id?: string;
|
||||
};
|
||||
|
||||
$$prop_def: ProgressStepProps;
|
||||
$$slot_def: {
|
||||
default: { props: { class: "bx--progress-label" } };
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue