diff --git a/README.md b/README.md
index 4c391645..7181fdb7 100644
--- a/README.md
+++ b/README.md
@@ -537,26 +537,26 @@ import { ComboBox } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :--------------- | :---------------------------------------------------------- | :------------------------------ |
-| items | ComboBoxItem[]
| [] |
-| itemToString | (item: ComboBoxItem) => string;
| (item: ComboBoxItem) => string; |
-| selectedIndex | number
| -1 |
-| value | string
| "" |
-| size | "sm" | "xl"
| - |
-| disabled | boolean
| false |
-| titleText | string
| "" |
-| placeholder | string
| "" |
-| helperText | string
| "" |
-| invalidText | string
| "" |
-| invalid | boolean
| false |
-| light | boolean
| false |
-| open | boolean
| false |
-| shouldFilterItem | (item: ComboBoxItem, value: string) => boolean
| () => true |
-| translateWithId | (id: any) => string;
| - |
-| id | string
| - |
-| name | string
| - |
-| ref | null | HTMLInputElement
| null |
+| Prop name | Type | Default |
+| :--------------- | :---------------------------------------------------------- | :----------------------------- |
+| items | ComboBoxItem[]
| [] |
+| itemToString | (item: ComboBoxItem) => string
| (item: ComboBoxItem) => string |
+| selectedIndex | number
| -1 |
+| value | string
| "" |
+| size | "sm" | "xl"
| - |
+| disabled | boolean
| false |
+| titleText | string
| "" |
+| placeholder | string
| "" |
+| helperText | string
| "" |
+| invalidText | string
| "" |
+| invalid | boolean
| false |
+| light | boolean
| false |
+| open | boolean
| false |
+| shouldFilterItem | (item: ComboBoxItem, value: string) => boolean
| () => true |
+| translateWithId | (id: any) => string
| - |
+| id | string
| - |
+| name | string
| - |
+| ref | null | HTMLInputElement
| null |
@@ -916,11 +916,11 @@ import { TableHeader } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------------- | :------------------------- | :-------- |
-| scope | string
| "col" |
-| translateWithId | () => string;
| () => ""; |
-| id | string
| - |
+| Prop name | Type | Default |
+| :-------------- | :------------------------ | :------- |
+| scope | string
| "col" |
+| translateWithId | () => string
| () => "" |
+| id | string
| - |
@@ -1093,26 +1093,26 @@ import { Dropdown } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------------- | :------------------------------------------- | :--------------------------------------- |
-| items | DropdownItem[]
| [] |
-| itemToString | (item: DropdownItem) => string;
| (item: DropdownItem) => DropdownItemText | DropdownItemId; |
-| selectedIndex | number
| -1 |
-| type | "default" | "inline"
| "default" |
-| size | "sm" | "lg" | "xl"
| - |
-| open | boolean
| false |
-| inline | boolean
| false |
-| light | boolean
| false |
-| disabled | boolean
| false |
-| titleText | string
| "" |
-| invalid | boolean
| false |
-| invalidText | string
| "" |
-| helperText | string
| "" |
-| label | string
| - |
-| translateWithId | (id: any) => string;
| - |
-| id | string
| - |
-| name | string
| - |
-| ref | null | HTMLButtonElement
| null |
+| Prop name | Type | Default |
+| :-------------- | :------------------------------------------ | :--------------------------------------- |
+| items | DropdownItem[]
| [] |
+| itemToString | (item: DropdownItem) => string
| (item: DropdownItem) => DropdownItemText | DropdownItemId |
+| selectedIndex | number
| -1 |
+| type | "default" | "inline"
| "default" |
+| size | "sm" | "lg" | "xl"
| - |
+| open | boolean
| false |
+| inline | boolean
| false |
+| light | boolean
| false |
+| disabled | boolean
| false |
+| titleText | string
| "" |
+| invalid | boolean
| false |
+| invalidText | string
| "" |
+| helperText | string
| "" |
+| label | string
| - |
+| translateWithId | (id: any) => string
| - |
+| id | string
| - |
+| name | string
| - |
+| ref | null | HTMLButtonElement
| null |
@@ -1158,7 +1158,7 @@ import { FileUploader } from "carbon-components-svelte";
| accept | string[]
| [] |
| files | string[]
| [] |
| multiple | boolean
| false |
-| clearFiles | () => any;
| () => void; |
+| clearFiles | () => any
| () => void |
| labelDescription | string
| "" |
| labelTitle | string
| "" |
| kind | "primary" | "secondary" | "tertiary" | "ghost" | "danger"
| "primary" |
@@ -1216,18 +1216,18 @@ import { FileUploaderDropContainer } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :------------ | :---------------------------------------- | :----------------------- |
-| accept | string[]
| [] |
-| multiple | boolean
| false |
-| validateFiles | (files: Files) => Files
| (files: Files) => Files; |
-| labelText | string
| "Add file" |
-| role | string
| "button" |
-| disabled | boolean
| false |
-| tabindex | string
| "0" |
-| id | string
| - |
-| name | string
| "" |
-| ref | null | HTMLInputElement
| null |
+| Prop name | Type | Default |
+| :------------ | :---------------------------------------- | :---------------------- |
+| accept | string[]
| [] |
+| multiple | boolean
| false |
+| validateFiles | (files: Files) => Files
| (files: Files) => Files |
+| labelText | string
| "Add file" |
+| role | string
| "button" |
+| disabled | boolean
| false |
+| tabindex | string
| "0" |
+| id | string
| - |
+| name | string
| "" |
+| ref | null | HTMLInputElement
| null |
@@ -1395,7 +1395,6 @@ import { Column } from "carbon-components-svelte";
| lg | ColumnBreakpoint
| - |
| xlg | ColumnBreakpoint
| - |
| max | ColumnBreakpoint
| - |
-| | string[]
| - |
@@ -1592,15 +1591,14 @@ import { ListBoxField } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------------- | :------------------------------------------------------ | :-------------- |
-| disabled | boolean
| false |
-| role | string
| "combobox" |
-| tabindex | string
| "-1" |
-| | { close: "close"; open: "open"; }
| - |
-| translateWithId | (id: ListBoxFieldTranslationId) => string;
| (id) => string; |
-| id | string
| - |
-| ref | null | HTMLElement
| null |
+| Prop name | Type | Default |
+| :-------------- | :------------------------------------------------------ | :------------- |
+| disabled | boolean
| false |
+| role | string
| "combobox" |
+| tabindex | string
| "-1" |
+| translateWithId | (id: ListBoxFieldTranslationId) => string;
| (id) => string |
+| id | string
| - |
+| ref | null | HTMLElement
| null |
@@ -1642,11 +1640,10 @@ import { ListBoxMenuIcon } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------------- | :--------------------------------------------------------- | :-------------- |
-| open | boolean
| false |
-| | { close: "close"; open: "open" }
| - |
-| translateWithId | (id: ListBoxMenuIconTranslationId) => string;
| (id) => string; |
+| Prop name | Type | Default |
+| :-------------- | :-------------------------------------------------------- | :------------- |
+| open | boolean
| false |
+| translateWithId | (id: ListBoxMenuIconTranslationId) => string
| (id) => string |
@@ -1689,13 +1686,12 @@ import { ListBoxSelection } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------------- | :---------------------------------------------------------------------- | :-------------- |
-| selectionCount | \*
| - |
-| disabled | boolean
| false |
-| | { clearAll: "clearAll"; clearSelection: "clearSelection" }
| - |
-| translateWithId | (id: ListBoxSelectionTranslationId) => string;
| (id) => string; |
-| ref | null | HTMLElement
| null |
+| Prop name | Type | Default |
+| :-------------- | :--------------------------------------------------------- | :------------- |
+| selectionCount | \*
| - |
+| disabled | boolean
| false |
+| translateWithId | (id: ListBoxSelectionTranslationId) => string
| (id) => string |
+| ref | null | HTMLElement
| null |
@@ -1802,7 +1798,7 @@ import { MultiSelect } from "carbon-components-svelte";
| Prop name | Type | Default |
| :---------------- | :------------------------------------------------------------------------ | :---------------------------------------------------------- |
| items | MultiSelectItem[]
| [] |
-| itemToString | (item: MultiSelectItem) => string;
| (item: MultiSelectItem) => MultiSelectItemText | MultiSelectItemId; |
+| itemToString | (item: MultiSelectItem) => string
| (item: MultiSelectItem) => MultiSelectItemText | MultiSelectItemId |
| selectedIds | MultiSelectItemId[]
| [] |
| value | string
| "" |
| size | "sm" | "lg" | "xl"
| - |
@@ -1816,7 +1812,7 @@ import { MultiSelect } from "carbon-components-svelte";
| locale | string
| "en" |
| placeholder | string
| "" |
| sortItem | (a: MultiSelectItem, b: MultiSelectItem) => MultiSelectItem;
| (a: MultiSelectItem, b: MultiSelectItem) => MultiSelectItem |
-| translateWithId | (id: any) => string;
| - |
+| translateWithId | (id: any) => string
| - |
| titleText | string
| "" |
| useTitleInItem | boolean
| false |
| invalid | boolean
| false |
@@ -2019,29 +2015,28 @@ import { NumberInput } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------------- | :-------------------------------------------------------------- | :---------------------------------------- |
-| size | "sm" | "xl"
| - |
-| value | string
| "" |
-| step | number
| 1 |
-| max | number
| - |
-| min | number
| - |
-| light | boolean
| false |
-| readonly | boolean
| false |
-| mobile | boolean
| false |
-| allowEmpty | boolean
| false |
-| disabled | boolean
| false |
-| iconDescription | string
| "" |
-| invalid | boolean
| false |
-| invalidText | string
| "Provide invalidText" |
-| helperText | string
| "" |
-| label | string
| "" |
-| hideLabel | boolean
| false |
-| translateWithId | (id: NumberInputTranslationId) => string;
| (id: NumberInputTranslationId) => string; |
-| | { increment: "increment"; decrement: "decrement" }
| - |
-| id | string
| - |
-| name | string
| - |
-| ref | null | HTMLInputElement
| null |
+| Prop name | Type | Default |
+| :-------------- | :---------------------------------------------------- | :--------------------------------------- |
+| size | "sm" | "xl"
| - |
+| value | string
| "" |
+| step | number
| 1 |
+| max | number
| - |
+| min | number
| - |
+| light | boolean
| false |
+| readonly | boolean
| false |
+| mobile | boolean
| false |
+| allowEmpty | boolean
| false |
+| disabled | boolean
| false |
+| iconDescription | string
| "" |
+| invalid | boolean
| false |
+| invalidText | string
| "Provide invalidText" |
+| helperText | string
| "" |
+| label | string
| "" |
+| hideLabel | boolean
| false |
+| translateWithId | (id: NumberInputTranslationId) => string
| (id: NumberInputTranslationId) => string |
+| id | string
| - |
+| name | string
| - |
+| ref | null | HTMLInputElement
| null |
@@ -2163,23 +2158,23 @@ import { Pagination } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :---------------- | :---------------------------------------------------------------- | :--------------------------------------------------- |
-| page | number
| 1 |
-| total | number
| 0 |
-| disabled | boolean
| false |
-| forwardText | string
| "Next page" |
-| backwardText | string
| "Previous page" |
-| itemsPerPageText | string
| "Items per page:" |
-| itemText | (min: number, max: number) => string;
| (min: number, max: number) => string; |
-| itemRangeText | (min: number, max: number, total: number) => string;
| (min: number, max: number, total: number) => string; |
-| pageInputDisabled | boolean
| false |
-| pageSize | number
| 10 |
-| pageSizes | number[]
| [10] |
-| pagesUnknown | boolean
| false |
-| pageText | (page: number) => string;
| (current: number) => string; |
-| pageRangeText | (current: number, total: number) => string;
| (current: number, total: number) => string; |
-| id | string
| - |
+| Prop name | Type | Default |
+| :---------------- | :--------------------------------------------------------------- | :-------------------------------------------------- |
+| page | number
| 1 |
+| total | number
| 0 |
+| disabled | boolean
| false |
+| forwardText | string
| "Next page" |
+| backwardText | string
| "Previous page" |
+| itemsPerPageText | string
| "Items per page:" |
+| itemText | (min: number, max: number) => string
| (min: number, max: number) => string |
+| itemRangeText | (min: number, max: number, total: number) => string
| (min: number, max: number, total: number) => string |
+| pageInputDisabled | boolean
| false |
+| pageSize | number
| 10 |
+| pageSizes | number[]
| [10] |
+| pagesUnknown | boolean
| false |
+| pageText | (page: number) => string
| (current: number) => string |
+| pageRangeText | (current: number, total: number) => string
| (current: number, total: number) => string |
+| id | string
| - |
@@ -2230,7 +2225,6 @@ import { PaginationNav } from "carbon-components-svelte";
| loop | boolean
| false |
| forwardText | string
| "Next page" |
| backwardText | string
| "Next page" |
-| | 4
| - |
@@ -2595,13 +2589,12 @@ import { SkeletonText } from "carbon-components-svelte";
**API**
-| Prop name | Type | Default |
-| :-------- | :-------------------- | :------ |
-| lines | number
| 3 |
-| heading | boolean
| false |
-| paragraph | boolean
| false |
-| width | string
| "100%" |
-| | number[]
| - |
+| Prop name | Type | Default |
+| :-------- | :------------------- | :------ |
+| lines | number
| 3 |
+| heading | boolean
| false |
+| paragraph | boolean
| false |
+| width | string
| "100%" |
diff --git a/package.json b/package.json
index 329116f9..e2c8e3a7 100644
--- a/package.json
+++ b/package.json
@@ -6,6 +6,7 @@
"svelte": "./src/index.js",
"main": "./lib/index.js",
"module": "./lib/index.mjs",
+ "types": "./types/index.d.ts",
"scripts": {
"start": "start-storybook -p 9090",
"build": "build-storybook",
diff --git a/src/ComboBox/ComboBox.svelte b/src/ComboBox/ComboBox.svelte
index 3ebc33fc..70170f40 100644
--- a/src/ComboBox/ComboBox.svelte
+++ b/src/ComboBox/ComboBox.svelte
@@ -11,7 +11,7 @@
/**
* Override the display of a combobox item
- * @type {(item: ComboBoxItem) => string;} [itemToString = (item: ComboBoxItem) => string;]
+ * @type {(item: ComboBoxItem) => string} [itemToString = (item: ComboBoxItem) => string]
*/
export let itemToString = (item) => item.text || item.id;
@@ -89,7 +89,7 @@
/**
* Override the default translation ids
- * @type {(id: any) => string;} [translateWithId]
+ * @type {(id: any) => string} [translateWithId]
*/
export let translateWithId = undefined;
diff --git a/src/DataTable/TableHeader.svelte b/src/DataTable/TableHeader.svelte
index dc5d216c..0c52e1e9 100644
--- a/src/DataTable/TableHeader.svelte
+++ b/src/DataTable/TableHeader.svelte
@@ -7,7 +7,7 @@
/**
* Override the default id translations
- * @type {() => string;} [translateWithId = () => "";]
+ * @type {() => string} [translateWithId = () => ""]
*/
export let translateWithId = () => "";
diff --git a/src/Dropdown/Dropdown.svelte b/src/Dropdown/Dropdown.svelte
index 4082a39f..9cc881ba 100644
--- a/src/Dropdown/Dropdown.svelte
+++ b/src/Dropdown/Dropdown.svelte
@@ -13,7 +13,7 @@
/**
* Override the display of a dropdown item
- * @type {(item: DropdownItem) => string;} [itemToString = (item: DropdownItem) => DropdownItemText | DropdownItemId;]
+ * @type {(item: DropdownItem) => string} [itemToString = (item: DropdownItem) => DropdownItemText | DropdownItemId]
*/
export let itemToString = (item) => item.text || item.id;
@@ -91,7 +91,7 @@
/**
* Override the default translation ids
- * @type {(id: any) => string;} [translateWithId]
+ * @type {(id: any) => string} [translateWithId]
*/
export let translateWithId = undefined;
diff --git a/src/FileUploader/FileUploader.svelte b/src/FileUploader/FileUploader.svelte
index c1223a34..f9e67a2a 100644
--- a/src/FileUploader/FileUploader.svelte
+++ b/src/FileUploader/FileUploader.svelte
@@ -25,7 +25,7 @@
/**
* Override the default behavior of clearing the array of uploaded files
- * @type {() => any;} [clearFiles = () => void;]
+ * @type {() => any} [clearFiles = () => void]
*/
export const clearFiles = () => {
files = [];
diff --git a/src/FileUploader/FileUploaderDropContainer.svelte b/src/FileUploader/FileUploaderDropContainer.svelte
index 9a21738b..e5ad31dc 100644
--- a/src/FileUploader/FileUploaderDropContainer.svelte
+++ b/src/FileUploader/FileUploaderDropContainer.svelte
@@ -18,7 +18,7 @@
/**
* Override the default behavior of validating uploaded files
* The default behavior does not validate files
- * @type {(files: Files) => Files} [validateFiles = (files: Files) => Files;]
+ * @type {(files: Files) => Files} [validateFiles = (files: Files) => Files]
*/
export let validateFiles = (files) => files;
diff --git a/src/Grid/Column.svelte b/src/Grid/Column.svelte
index 1c476c16..d1fffb87 100644
--- a/src/Grid/Column.svelte
+++ b/src/Grid/Column.svelte
@@ -32,7 +32,7 @@
/**
* @typedef {boolean | number} ColumnSize
- * @typedef {{span?: ColumnSize: offset: number;}} ColumnSizeDescriptor
+ * @typedef {{span?: ColumnSize; offset: number;}} ColumnSizeDescriptor
* @typedef {ColumnSize | ColumnSizeDescriptor} ColumnBreakpoint
*/
diff --git a/src/ListBox/ListBoxField.svelte b/src/ListBox/ListBoxField.svelte
index 81d71033..d97397ce 100644
--- a/src/ListBox/ListBoxField.svelte
+++ b/src/ListBox/ListBoxField.svelte
@@ -30,7 +30,7 @@
/**
* Override the default translation ids
- * @type {(id: ListBoxFieldTranslationId) => string;} [translateWithId = (id) => string;]
+ * @type {(id: ListBoxFieldTranslationId) => string} [translateWithId = (id) => string]
*/
export let translateWithId = (id) => defaultTranslations[id];
diff --git a/src/ListBox/ListBoxMenuIcon.svelte b/src/ListBox/ListBoxMenuIcon.svelte
index 5ccd3fc4..82d9437b 100644
--- a/src/ListBox/ListBoxMenuIcon.svelte
+++ b/src/ListBox/ListBoxMenuIcon.svelte
@@ -18,7 +18,7 @@
/**
* Override the default translation ids
- * @type {(id: ListBoxMenuIconTranslationId) => string;} [translateWithId = (id) => string;]
+ * @type {(id: ListBoxMenuIconTranslationId) => string} [translateWithId = (id) => string]
*/
export let translateWithId = (id) => defaultTranslations[id];
diff --git a/src/ListBox/ListBoxSelection.svelte b/src/ListBox/ListBoxSelection.svelte
index 05961442..9afe68dc 100644
--- a/src/ListBox/ListBoxSelection.svelte
+++ b/src/ListBox/ListBoxSelection.svelte
@@ -1,7 +1,7 @@