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

feat(typescript)!: support svelte 4 #1773

Merged
merged 4 commits into from
Jul 19, 2023
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
256 changes: 128 additions & 128 deletions COMPONENT_INDEX.md

Large diffs are not rendered by default.

42 changes: 21 additions & 21 deletions docs/src/COMPONENT_API.json
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -2117,7 +2117,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render\nIcon is rendered to the left of the label text",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -4811,7 +4811,7 @@
"name": "iconMenu",
"kind": "let",
"description": "Specify the icon to render for the closed state.\nDefaults to `<Menu size={20} />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand All @@ -4822,7 +4822,7 @@
"name": "iconClose",
"kind": "let",
"description": "Specify the icon to render for the opened state.\nDefaults to `<Close size={20} />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -4871,7 +4871,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render when the action panel is closed.\nDefaults to `<Switcher size={20} />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand All @@ -4882,7 +4882,7 @@
"name": "closeIcon",
"kind": "let",
"description": "Specify the icon to render when the action panel is open.\nDefaults to `<Close size={20} />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -4998,7 +4998,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -5051,7 +5051,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -5755,7 +5755,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render\n`inline` must be `false`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -6574,7 +6574,7 @@
"name": "primaryButtonIcon",
"kind": "let",
"description": "Specify the primary button icon",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -6765,7 +6765,7 @@
"name": "primaryButtonIcon",
"kind": "let",
"description": "Specify the primary button icon",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -7461,7 +7461,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -8029,7 +8029,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render.\nDefaults to `<OverflowMenuVertical />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -10013,7 +10013,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render.\nDefaults to `<Search />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -10739,7 +10739,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -10809,7 +10809,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -12287,7 +12287,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -14039,7 +14039,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render for the tooltip button.\nDefault to `<Information />`",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -14321,7 +14321,7 @@
"name": "icon",
"kind": "let",
"description": "Specify the icon to render",
"type": "typeof import(\"svelte\").SvelteComponent",
"type": "typeof import(\"svelte\").SvelteComponent<any>",
"isFunction": false,
"isFunctionDeclaration": false,
"isRequired": false,
Expand Down Expand Up @@ -14585,9 +14585,9 @@
"ts": "type TreeNodeId = string | number"
},
{
"type": "{ id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent; disabled?: boolean; children?: TreeNode[]; }",
"type": "{ id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent<any>; disabled?: boolean; children?: TreeNode[]; }",
"name": "TreeNode",
"ts": "interface TreeNode { id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent; disabled?: boolean; children?: TreeNode[]; }"
"ts": "interface TreeNode { id: TreeNodeId; text: any; icon?: typeof import(\"svelte\").SvelteComponent<any>; disabled?: boolean; children?: TreeNode[]; }"
}
],
"rest_props": { "type": "Element", "name": "ul" }
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"@tsconfig/svelte": "^4.0.1",
"autoprefixer": "^10.4.8",
"carbon-components": "10.57.0",
"carbon-icons-svelte": "^11.2.0",
"carbon-icons-svelte": "^12.1.0",
"postcss": "^8.4.16",
"prettier": "^2.7.1",
"prettier-plugin-svelte": "^2.7.0",
Expand All @@ -39,8 +39,8 @@
"sass": "^1.49.11",
"standard-version": "^9.5.0",
"sveld": "^0.18.1",
"svelte": "^3.58.0",
"svelte-check": "^3.4.3",
"svelte": "^4.1.0",
"svelte-check": "^3.4.6",
"typescript": "^4.7.4"
},
"standard-version": {
Expand Down
2 changes: 1 addition & 1 deletion src/Button/Button.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/ComposedModal/ModalFooter.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

/**
* Specify the primary button icon
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let primaryButtonIcon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/ContextMenu/ContextMenuOption.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
/**
* Specify the icon to render
* Icon is rendered to the left of the label text
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/Link/Link.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
/**
* Specify the icon to render
* `inline` must be `false`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/Modal/Modal.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@

/**
* Specify the primary button icon
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let primaryButtonIcon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/Notification/NotificationButton.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = Close;

Expand Down
2 changes: 1 addition & 1 deletion src/OverflowMenu/OverflowMenu.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
/**
* Specify the icon to render.
* Defaults to `<OverflowMenuVertical />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = OverflowMenuVertical;

Expand Down
2 changes: 1 addition & 1 deletion src/Search/Search.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
/**
* Specify the icon to render.
* Defaults to `<Search />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = IconSearch;

Expand Down
2 changes: 1 addition & 1 deletion src/Tag/Tag.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/Tooltip/Tooltip.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
/**
* Specify the icon to render for the tooltip button.
* Default to `<Information />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = Information;

Expand Down
2 changes: 1 addition & 1 deletion src/TooltipIcon/TooltipIcon.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/TreeView/TreeView.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script>
/**
* @typedef {string | number} TreeNodeId
* @typedef {{ id: TreeNodeId; text: any; icon?: typeof import("svelte").SvelteComponent; disabled?: boolean; children?: TreeNode[]; }} TreeNode
* @typedef {{ id: TreeNodeId; text: any; icon?: typeof import("svelte").SvelteComponent<any>; disabled?: boolean; children?: TreeNode[]; }} TreeNode
* @event {TreeNode & { expanded: boolean; leaf: boolean; }} select
* @event {TreeNode & { expanded: boolean; leaf: boolean; }} toggle
* @event {TreeNode & { expanded: boolean; leaf: boolean; }} focus
Expand Down
2 changes: 1 addition & 1 deletion src/TreeView/TreeViewNode.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/TreeView/TreeViewNodeList.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
4 changes: 2 additions & 2 deletions src/UIShell/HamburgerMenu.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
/**
* Specify the icon to render for the closed state.
* Defaults to `<Menu size={20} />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let iconMenu = Menu;

/**
* Specify the icon to render for the opened state.
* Defaults to `<Close size={20} />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let iconClose = Close;

Expand Down
4 changes: 2 additions & 2 deletions src/UIShell/Header.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,14 @@
/**
* Specify the icon to render for the closed state.
* Defaults to `<Menu size={20} />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let iconMenu = Menu;

/**
* Specify the icon to render for the opened state.
* Defaults to `<Close size={20} />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let iconClose = Close;

Expand Down
4 changes: 2 additions & 2 deletions src/UIShell/HeaderAction.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@
/**
* Specify the icon to render when the action panel is closed.
* Defaults to `<Switcher size={20} />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = Switcher;

/**
* Specify the icon to render when the action panel is open.
* Defaults to `<Close size={20} />`
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let closeIcon = Close;

Expand Down
2 changes: 1 addition & 1 deletion src/UIShell/HeaderActionLink.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
2 changes: 1 addition & 1 deletion src/UIShell/HeaderGlobalAction.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

/**
* Specify the icon to render
* @type {typeof import("svelte").SvelteComponent}
* @type {typeof import("svelte").SvelteComponent<any>}
*/
export let icon = undefined;

Expand Down
Loading