├── .bun-version ├── .github ├── FUNDING.yml └── workflows │ ├── ci.yml │ └── publish-to-npm.yml ├── .gitignore ├── .prettierignore ├── CHANGELOG.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── bun.lock ├── cli.js ├── package.json ├── playground ├── bun.lock ├── index.html ├── package.json ├── src │ ├── App.svelte │ ├── CodeEditor.svelte │ ├── CodeHighlighter.svelte │ ├── Header.svelte │ ├── LogoGithub20.svelte │ ├── TabContentOverlay.svelte │ ├── TabJson.svelte │ ├── TabMarkdown.svelte │ ├── TabTypeScript.svelte │ ├── data.ts │ ├── favicon.svg │ └── index.ts ├── tsconfig.json └── vite.config.ts ├── src ├── ComponentParser.ts ├── cli.ts ├── create-exports.ts ├── element-tag-map.ts ├── get-svelte-entry.ts ├── index.ts ├── parse-exports.ts ├── path.ts ├── rollup-plugin.ts ├── sveld.ts └── writer │ ├── Writer.ts │ ├── WriterMarkdown.ts │ ├── writer-json.ts │ ├── writer-markdown.ts │ └── writer-ts-definitions.ts ├── tests ├── ComponentParser.test.ts ├── Writer.test.ts ├── WriterMarkdown.test.ts ├── __snapshots__ │ ├── fixtures.test.ts.snap │ └── writer-ts-definitions.test.ts.snap ├── create-exports.test.ts ├── e2e │ ├── carbon │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── src │ │ │ ├── Accordion │ │ │ │ ├── Accordion.svelte │ │ │ │ ├── AccordionItem.svelte │ │ │ │ ├── AccordionSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── AspectRatio │ │ │ │ ├── AspectRatio.svelte │ │ │ │ └── index.js │ │ │ ├── Breadcrumb │ │ │ │ ├── Breadcrumb.svelte │ │ │ │ ├── BreadcrumbItem.svelte │ │ │ │ ├── BreadcrumbSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Button │ │ │ │ ├── Button.svelte │ │ │ │ ├── ButtonSet.svelte │ │ │ │ ├── ButtonSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Checkbox │ │ │ │ ├── Checkbox.svelte │ │ │ │ ├── CheckboxSkeleton.svelte │ │ │ │ ├── InlineCheckbox.svelte │ │ │ │ └── index.js │ │ │ ├── CodeSnippet │ │ │ │ ├── CodeSnippet.svelte │ │ │ │ ├── CodeSnippetSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── ComboBox │ │ │ │ ├── ComboBox.svelte │ │ │ │ └── index.js │ │ │ ├── ComposedModal │ │ │ │ ├── ComposedModal.svelte │ │ │ │ ├── ModalBody.svelte │ │ │ │ ├── ModalFooter.svelte │ │ │ │ ├── ModalHeader.svelte │ │ │ │ └── index.js │ │ │ ├── ContentSwitcher │ │ │ │ ├── ContentSwitcher.svelte │ │ │ │ ├── Switch.svelte │ │ │ │ └── index.js │ │ │ ├── Copy │ │ │ │ ├── Copy.svelte │ │ │ │ └── index.js │ │ │ ├── CopyButton │ │ │ │ ├── CopyButton.svelte │ │ │ │ └── index.js │ │ │ ├── DataTable │ │ │ │ ├── DataTable.svelte │ │ │ │ ├── DataTableSkeleton.svelte │ │ │ │ ├── Table.svelte │ │ │ │ ├── TableBody.svelte │ │ │ │ ├── TableCell.svelte │ │ │ │ ├── TableContainer.svelte │ │ │ │ ├── TableHead.svelte │ │ │ │ ├── TableHeader.svelte │ │ │ │ ├── TableRow.svelte │ │ │ │ ├── Toolbar.svelte │ │ │ │ ├── ToolbarBatchActions.svelte │ │ │ │ ├── ToolbarContent.svelte │ │ │ │ ├── ToolbarMenu.svelte │ │ │ │ ├── ToolbarMenuItem.svelte │ │ │ │ ├── ToolbarSearch.svelte │ │ │ │ └── index.js │ │ │ ├── DatePicker │ │ │ │ ├── DatePicker.svelte │ │ │ │ ├── DatePickerInput.svelte │ │ │ │ ├── DatePickerSkeleton.svelte │ │ │ │ ├── createCalendar.js │ │ │ │ └── index.js │ │ │ ├── Dropdown │ │ │ │ ├── Dropdown.svelte │ │ │ │ ├── DropdownSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── FileUploader │ │ │ │ ├── FileUploader.svelte │ │ │ │ ├── FileUploaderButton.svelte │ │ │ │ ├── FileUploaderDropContainer.svelte │ │ │ │ ├── FileUploaderItem.svelte │ │ │ │ ├── FileUploaderSkeleton.svelte │ │ │ │ ├── Filename.svelte │ │ │ │ └── index.js │ │ │ ├── FluidForm │ │ │ │ ├── FluidForm.svelte │ │ │ │ └── index.js │ │ │ ├── Form │ │ │ │ ├── Form.svelte │ │ │ │ └── index.js │ │ │ ├── FormGroup │ │ │ │ ├── FormGroup.svelte │ │ │ │ └── index.js │ │ │ ├── FormItem │ │ │ │ ├── FormItem.svelte │ │ │ │ └── index.js │ │ │ ├── FormLabel │ │ │ │ ├── FormLabel.svelte │ │ │ │ └── index.js │ │ │ ├── Grid │ │ │ │ ├── Column.svelte │ │ │ │ ├── Grid.svelte │ │ │ │ ├── Row.svelte │ │ │ │ └── index.js │ │ │ ├── Icon │ │ │ │ ├── Icon.svelte │ │ │ │ ├── IconSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── InlineLoading │ │ │ │ ├── InlineLoading.svelte │ │ │ │ └── index.js │ │ │ ├── Link │ │ │ │ ├── Link.svelte │ │ │ │ ├── OutboundLink.svelte │ │ │ │ └── index.js │ │ │ ├── ListBox │ │ │ │ ├── ListBox.svelte │ │ │ │ ├── ListBoxField.svelte │ │ │ │ ├── ListBoxMenu.svelte │ │ │ │ ├── ListBoxMenuIcon.svelte │ │ │ │ ├── ListBoxMenuItem.svelte │ │ │ │ ├── ListBoxSelection.svelte │ │ │ │ └── index.js │ │ │ ├── ListItem │ │ │ │ ├── ListItem.svelte │ │ │ │ └── index.js │ │ │ ├── Loading │ │ │ │ ├── Loading.svelte │ │ │ │ └── index.js │ │ │ ├── Modal │ │ │ │ ├── Modal.svelte │ │ │ │ └── index.js │ │ │ ├── MultiSelect │ │ │ │ ├── MultiSelect.svelte │ │ │ │ └── index.js │ │ │ ├── Notification │ │ │ │ ├── InlineNotification.svelte │ │ │ │ ├── NotificationActionButton.svelte │ │ │ │ ├── NotificationButton.svelte │ │ │ │ ├── NotificationIcon.svelte │ │ │ │ ├── NotificationTextDetails.svelte │ │ │ │ ├── ToastNotification.svelte │ │ │ │ └── index.js │ │ │ ├── NumberInput │ │ │ │ ├── NumberInput.svelte │ │ │ │ ├── NumberInputSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── OrderedList │ │ │ │ ├── OrderedList.svelte │ │ │ │ └── index.js │ │ │ ├── OverflowMenu │ │ │ │ ├── OverflowMenu.svelte │ │ │ │ ├── OverflowMenuItem.svelte │ │ │ │ ├── formatStyle.js │ │ │ │ └── index.js │ │ │ ├── Pagination │ │ │ │ ├── Pagination.svelte │ │ │ │ ├── PaginationSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── PaginationNav │ │ │ │ ├── PaginationItem.svelte │ │ │ │ ├── PaginationNav.svelte │ │ │ │ ├── PaginationOverflow.svelte │ │ │ │ └── index.js │ │ │ ├── ProgressIndicator │ │ │ │ ├── ProgressIndicator.svelte │ │ │ │ ├── ProgressIndicatorSkeleton.svelte │ │ │ │ ├── ProgressStep.svelte │ │ │ │ └── index.js │ │ │ ├── RadioButton │ │ │ │ ├── RadioButton.svelte │ │ │ │ ├── RadioButtonSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── RadioButtonGroup │ │ │ │ ├── RadioButtonGroup.svelte │ │ │ │ └── index.js │ │ │ ├── Search │ │ │ │ ├── Search.svelte │ │ │ │ ├── SearchSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Select │ │ │ │ ├── Select.svelte │ │ │ │ ├── SelectItem.svelte │ │ │ │ ├── SelectItemGroup.svelte │ │ │ │ ├── SelectSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── SkeletonPlaceholder │ │ │ │ ├── SkeletonPlaceholder.svelte │ │ │ │ └── index.js │ │ │ ├── SkeletonText │ │ │ │ ├── SkeletonText.svelte │ │ │ │ └── index.js │ │ │ ├── Slider │ │ │ │ ├── Slider.svelte │ │ │ │ ├── SliderSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── StructuredList │ │ │ │ ├── StructuredList.svelte │ │ │ │ ├── StructuredListBody.svelte │ │ │ │ ├── StructuredListCell.svelte │ │ │ │ ├── StructuredListHead.svelte │ │ │ │ ├── StructuredListInput.svelte │ │ │ │ ├── StructuredListRow.svelte │ │ │ │ ├── StructuredListSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Tabs │ │ │ │ ├── Tab.svelte │ │ │ │ ├── TabContent.svelte │ │ │ │ ├── Tabs.svelte │ │ │ │ ├── TabsSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Tag │ │ │ │ ├── Tag.svelte │ │ │ │ ├── TagSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── TextArea │ │ │ │ ├── TextArea.svelte │ │ │ │ ├── TextAreaSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── TextInput │ │ │ │ ├── PasswordInput.svelte │ │ │ │ ├── TextInput.svelte │ │ │ │ ├── TextInputSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Tile │ │ │ │ ├── ClickableTile.svelte │ │ │ │ ├── ExpandableTile.svelte │ │ │ │ ├── RadioTile.svelte │ │ │ │ ├── SelectableTile.svelte │ │ │ │ ├── Tile.svelte │ │ │ │ ├── TileGroup.svelte │ │ │ │ └── index.js │ │ │ ├── TimePicker │ │ │ │ ├── TimePicker.svelte │ │ │ │ ├── TimePickerSelect.svelte │ │ │ │ └── index.js │ │ │ ├── Toggle │ │ │ │ ├── Toggle.svelte │ │ │ │ ├── ToggleSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── ToggleSmall │ │ │ │ ├── ToggleSmall.svelte │ │ │ │ ├── ToggleSmallSkeleton.svelte │ │ │ │ └── index.js │ │ │ ├── Tooltip │ │ │ │ ├── Tooltip.svelte │ │ │ │ └── index.js │ │ │ ├── TooltipDefinition │ │ │ │ ├── TooltipDefinition.svelte │ │ │ │ └── index.js │ │ │ ├── TooltipIcon │ │ │ │ ├── TooltipIcon.svelte │ │ │ │ └── index.js │ │ │ ├── UIShell │ │ │ │ ├── Content.svelte │ │ │ │ ├── GlobalHeader │ │ │ │ │ ├── Header.svelte │ │ │ │ │ ├── HeaderAction.svelte │ │ │ │ │ ├── HeaderActionLink.svelte │ │ │ │ │ ├── HeaderActionSearch.svelte │ │ │ │ │ ├── HeaderNav.svelte │ │ │ │ │ ├── HeaderNavItem.svelte │ │ │ │ │ ├── HeaderNavMenu.svelte │ │ │ │ │ ├── HeaderPanelDivider.svelte │ │ │ │ │ ├── HeaderPanelLink.svelte │ │ │ │ │ ├── HeaderPanelLinks.svelte │ │ │ │ │ └── HeaderUtilities.svelte │ │ │ │ ├── HeaderGlobalAction.svelte │ │ │ │ ├── HeaderSearch.svelte │ │ │ │ ├── SideNav │ │ │ │ │ ├── HamburgerMenu.svelte │ │ │ │ │ ├── SideNav.svelte │ │ │ │ │ ├── SideNavItems.svelte │ │ │ │ │ ├── SideNavLink.svelte │ │ │ │ │ ├── SideNavMenu.svelte │ │ │ │ │ └── SideNavMenuItem.svelte │ │ │ │ ├── SkipToContent.svelte │ │ │ │ ├── index.js │ │ │ │ ├── navStore.js │ │ │ │ └── searchStore.js │ │ │ ├── UnorderedList │ │ │ │ ├── UnorderedList.svelte │ │ │ │ └── index.js │ │ │ └── index.js │ │ ├── test │ │ │ └── Accordion.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── Accordion │ │ │ ├── Accordion.svelte.d.ts │ │ │ ├── AccordionItem.svelte.d.ts │ │ │ └── AccordionSkeleton.svelte.d.ts │ │ │ ├── AspectRatio │ │ │ └── AspectRatio.svelte.d.ts │ │ │ ├── Breadcrumb │ │ │ ├── Breadcrumb.svelte.d.ts │ │ │ ├── BreadcrumbItem.svelte.d.ts │ │ │ └── BreadcrumbSkeleton.svelte.d.ts │ │ │ ├── Button │ │ │ ├── Button.svelte.d.ts │ │ │ ├── ButtonSet.svelte.d.ts │ │ │ └── ButtonSkeleton.svelte.d.ts │ │ │ ├── Checkbox │ │ │ ├── Checkbox.svelte.d.ts │ │ │ └── CheckboxSkeleton.svelte.d.ts │ │ │ ├── CodeSnippet │ │ │ ├── CodeSnippet.svelte.d.ts │ │ │ └── CodeSnippetSkeleton.svelte.d.ts │ │ │ ├── ComboBox │ │ │ └── ComboBox.svelte.d.ts │ │ │ ├── ComposedModal │ │ │ ├── ComposedModal.svelte.d.ts │ │ │ ├── ModalBody.svelte.d.ts │ │ │ ├── ModalFooter.svelte.d.ts │ │ │ └── ModalHeader.svelte.d.ts │ │ │ ├── ContentSwitcher │ │ │ ├── ContentSwitcher.svelte.d.ts │ │ │ └── Switch.svelte.d.ts │ │ │ ├── Copy │ │ │ └── Copy.svelte.d.ts │ │ │ ├── CopyButton │ │ │ └── CopyButton.svelte.d.ts │ │ │ ├── DataTable │ │ │ ├── DataTable.svelte.d.ts │ │ │ ├── DataTableSkeleton.svelte.d.ts │ │ │ ├── Table.svelte.d.ts │ │ │ ├── TableBody.svelte.d.ts │ │ │ ├── TableCell.svelte.d.ts │ │ │ ├── TableContainer.svelte.d.ts │ │ │ ├── TableHead.svelte.d.ts │ │ │ ├── TableHeader.svelte.d.ts │ │ │ ├── TableRow.svelte.d.ts │ │ │ ├── Toolbar.svelte.d.ts │ │ │ ├── ToolbarBatchActions.svelte.d.ts │ │ │ ├── ToolbarContent.svelte.d.ts │ │ │ ├── ToolbarMenu.svelte.d.ts │ │ │ ├── ToolbarMenuItem.svelte.d.ts │ │ │ └── ToolbarSearch.svelte.d.ts │ │ │ ├── DatePicker │ │ │ ├── DatePicker.svelte.d.ts │ │ │ ├── DatePickerInput.svelte.d.ts │ │ │ └── DatePickerSkeleton.svelte.d.ts │ │ │ ├── Dropdown │ │ │ ├── Dropdown.svelte.d.ts │ │ │ └── DropdownSkeleton.svelte.d.ts │ │ │ ├── FileUploader │ │ │ ├── FileUploader.svelte.d.ts │ │ │ ├── FileUploaderButton.svelte.d.ts │ │ │ ├── FileUploaderDropContainer.svelte.d.ts │ │ │ ├── FileUploaderItem.svelte.d.ts │ │ │ ├── FileUploaderSkeleton.svelte.d.ts │ │ │ └── Filename.svelte.d.ts │ │ │ ├── FluidForm │ │ │ └── FluidForm.svelte.d.ts │ │ │ ├── Form │ │ │ └── Form.svelte.d.ts │ │ │ ├── FormGroup │ │ │ └── FormGroup.svelte.d.ts │ │ │ ├── FormItem │ │ │ └── FormItem.svelte.d.ts │ │ │ ├── FormLabel │ │ │ └── FormLabel.svelte.d.ts │ │ │ ├── Grid │ │ │ ├── Column.svelte.d.ts │ │ │ ├── Grid.svelte.d.ts │ │ │ └── Row.svelte.d.ts │ │ │ ├── Icon │ │ │ ├── Icon.svelte.d.ts │ │ │ └── IconSkeleton.svelte.d.ts │ │ │ ├── InlineLoading │ │ │ └── InlineLoading.svelte.d.ts │ │ │ ├── Link │ │ │ ├── Link.svelte.d.ts │ │ │ └── OutboundLink.svelte.d.ts │ │ │ ├── ListBox │ │ │ ├── ListBox.svelte.d.ts │ │ │ ├── ListBoxField.svelte.d.ts │ │ │ ├── ListBoxMenu.svelte.d.ts │ │ │ ├── ListBoxMenuIcon.svelte.d.ts │ │ │ ├── ListBoxMenuItem.svelte.d.ts │ │ │ └── ListBoxSelection.svelte.d.ts │ │ │ ├── ListItem │ │ │ └── ListItem.svelte.d.ts │ │ │ ├── Loading │ │ │ └── Loading.svelte.d.ts │ │ │ ├── Modal │ │ │ └── Modal.svelte.d.ts │ │ │ ├── MultiSelect │ │ │ └── MultiSelect.svelte.d.ts │ │ │ ├── Notification │ │ │ ├── InlineNotification.svelte.d.ts │ │ │ ├── NotificationActionButton.svelte.d.ts │ │ │ ├── NotificationButton.svelte.d.ts │ │ │ ├── NotificationIcon.svelte.d.ts │ │ │ ├── NotificationTextDetails.svelte.d.ts │ │ │ └── ToastNotification.svelte.d.ts │ │ │ ├── NumberInput │ │ │ ├── NumberInput.svelte.d.ts │ │ │ └── NumberInputSkeleton.svelte.d.ts │ │ │ ├── OrderedList │ │ │ └── OrderedList.svelte.d.ts │ │ │ ├── OverflowMenu │ │ │ ├── OverflowMenu.svelte.d.ts │ │ │ └── OverflowMenuItem.svelte.d.ts │ │ │ ├── Pagination │ │ │ ├── Pagination.svelte.d.ts │ │ │ └── PaginationSkeleton.svelte.d.ts │ │ │ ├── PaginationNav │ │ │ └── PaginationNav.svelte.d.ts │ │ │ ├── ProgressIndicator │ │ │ ├── ProgressIndicator.svelte.d.ts │ │ │ ├── ProgressIndicatorSkeleton.svelte.d.ts │ │ │ └── ProgressStep.svelte.d.ts │ │ │ ├── RadioButton │ │ │ ├── RadioButton.svelte.d.ts │ │ │ └── RadioButtonSkeleton.svelte.d.ts │ │ │ ├── RadioButtonGroup │ │ │ └── RadioButtonGroup.svelte.d.ts │ │ │ ├── Search │ │ │ ├── Search.svelte.d.ts │ │ │ └── SearchSkeleton.svelte.d.ts │ │ │ ├── Select │ │ │ ├── Select.svelte.d.ts │ │ │ ├── SelectItem.svelte.d.ts │ │ │ ├── SelectItemGroup.svelte.d.ts │ │ │ └── SelectSkeleton.svelte.d.ts │ │ │ ├── SkeletonPlaceholder │ │ │ └── SkeletonPlaceholder.svelte.d.ts │ │ │ ├── SkeletonText │ │ │ └── SkeletonText.svelte.d.ts │ │ │ ├── Slider │ │ │ ├── Slider.svelte.d.ts │ │ │ └── SliderSkeleton.svelte.d.ts │ │ │ ├── StructuredList │ │ │ ├── StructuredList.svelte.d.ts │ │ │ ├── StructuredListBody.svelte.d.ts │ │ │ ├── StructuredListCell.svelte.d.ts │ │ │ ├── StructuredListHead.svelte.d.ts │ │ │ ├── StructuredListInput.svelte.d.ts │ │ │ ├── StructuredListRow.svelte.d.ts │ │ │ └── StructuredListSkeleton.svelte.d.ts │ │ │ ├── Tabs │ │ │ ├── Tab.svelte.d.ts │ │ │ ├── TabContent.svelte.d.ts │ │ │ ├── Tabs.svelte.d.ts │ │ │ └── TabsSkeleton.svelte.d.ts │ │ │ ├── Tag │ │ │ ├── Tag.svelte.d.ts │ │ │ └── TagSkeleton.svelte.d.ts │ │ │ ├── TextArea │ │ │ ├── TextArea.svelte.d.ts │ │ │ └── TextAreaSkeleton.svelte.d.ts │ │ │ ├── TextInput │ │ │ ├── PasswordInput.svelte.d.ts │ │ │ ├── TextInput.svelte.d.ts │ │ │ └── TextInputSkeleton.svelte.d.ts │ │ │ ├── Tile │ │ │ ├── ClickableTile.svelte.d.ts │ │ │ ├── ExpandableTile.svelte.d.ts │ │ │ ├── RadioTile.svelte.d.ts │ │ │ ├── SelectableTile.svelte.d.ts │ │ │ ├── Tile.svelte.d.ts │ │ │ └── TileGroup.svelte.d.ts │ │ │ ├── TimePicker │ │ │ ├── TimePicker.svelte.d.ts │ │ │ └── TimePickerSelect.svelte.d.ts │ │ │ ├── Toggle │ │ │ ├── Toggle.svelte.d.ts │ │ │ └── ToggleSkeleton.svelte.d.ts │ │ │ ├── ToggleSmall │ │ │ ├── ToggleSmall.svelte.d.ts │ │ │ └── ToggleSmallSkeleton.svelte.d.ts │ │ │ ├── Tooltip │ │ │ └── Tooltip.svelte.d.ts │ │ │ ├── TooltipDefinition │ │ │ └── TooltipDefinition.svelte.d.ts │ │ │ ├── TooltipIcon │ │ │ └── TooltipIcon.svelte.d.ts │ │ │ ├── UIShell │ │ │ ├── Content.svelte.d.ts │ │ │ ├── GlobalHeader │ │ │ │ ├── Header.svelte.d.ts │ │ │ │ ├── HeaderAction.svelte.d.ts │ │ │ │ ├── HeaderActionLink.svelte.d.ts │ │ │ │ ├── HeaderActionSearch.svelte.d.ts │ │ │ │ ├── HeaderNav.svelte.d.ts │ │ │ │ ├── HeaderNavItem.svelte.d.ts │ │ │ │ ├── HeaderNavMenu.svelte.d.ts │ │ │ │ ├── HeaderPanelDivider.svelte.d.ts │ │ │ │ ├── HeaderPanelLink.svelte.d.ts │ │ │ │ ├── HeaderPanelLinks.svelte.d.ts │ │ │ │ └── HeaderUtilities.svelte.d.ts │ │ │ ├── HeaderGlobalAction.svelte.d.ts │ │ │ ├── HeaderSearch.svelte.d.ts │ │ │ ├── SideNav │ │ │ │ ├── SideNav.svelte.d.ts │ │ │ │ ├── SideNavItems.svelte.d.ts │ │ │ │ ├── SideNavLink.svelte.d.ts │ │ │ │ ├── SideNavMenu.svelte.d.ts │ │ │ │ └── SideNavMenuItem.svelte.d.ts │ │ │ └── SkipToContent.svelte.d.ts │ │ │ ├── UnorderedList │ │ │ └── UnorderedList.svelte.d.ts │ │ │ └── index.d.ts │ ├── glob │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── src │ │ │ ├── action │ │ │ │ ├── Action.js │ │ │ │ └── index.js │ │ │ ├── button │ │ │ │ ├── Button.svelte │ │ │ │ └── index.js │ │ │ └── index.js │ │ ├── test │ │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── button │ │ │ └── Button.svelte.d.ts │ │ │ └── index.d.ts │ ├── multi-export-typed-ts-only │ │ ├── .gitignore │ │ ├── bun.lock │ │ ├── button │ │ │ └── button.svelte │ │ ├── index.js │ │ ├── link │ │ │ └── link.svelte │ │ ├── package.json │ │ ├── quote │ │ │ └── quote.svelte │ │ ├── rollup.config.js │ │ ├── secondary-button │ │ │ └── secondary-button.svelte │ │ ├── test.svelte │ │ ├── test │ │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── button │ │ │ └── button.svelte.d.ts │ │ │ ├── index.d.ts │ │ │ ├── link │ │ │ └── link.svelte.d.ts │ │ │ ├── quote │ │ │ └── quote.svelte.d.ts │ │ │ └── secondary-button │ │ │ └── secondary-button.svelte.d.ts │ ├── multi-export-typed │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── src │ │ │ ├── Button.svelte │ │ │ ├── Link.svelte │ │ │ ├── Quote.svelte │ │ │ ├── SecondaryButton.svelte │ │ │ └── index.js │ │ ├── test.svelte │ │ ├── test │ │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── Button.svelte.d.ts │ │ │ ├── Link.svelte.d.ts │ │ │ ├── Quote.svelte.d.ts │ │ │ ├── SecondaryButton.svelte.d.ts │ │ │ └── index.d.ts │ ├── multi-export │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── src │ │ │ ├── Button.svelte │ │ │ ├── Link.svelte │ │ │ ├── Quote.svelte │ │ │ ├── index.js │ │ │ └── nested │ │ │ │ └── Header.svelte │ │ ├── test │ │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── Button.svelte.d.ts │ │ │ ├── Link.svelte.d.ts │ │ │ ├── Quote.svelte.d.ts │ │ │ ├── index.d.ts │ │ │ └── nested │ │ │ └── Header.svelte.d.ts │ ├── multi-folders │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── src │ │ │ ├── Link.svelte │ │ │ ├── Quote.svelte │ │ │ ├── components │ │ │ │ ├── Button.svelte │ │ │ │ ├── Card.svelte │ │ │ │ └── index.js │ │ │ ├── index.js │ │ │ └── nested │ │ │ │ └── Header.svelte │ │ ├── test │ │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── Link.svelte.d.ts │ │ │ ├── Quote.svelte.d.ts │ │ │ ├── components │ │ │ ├── Button.svelte.d.ts │ │ │ └── Card.svelte.d.ts │ │ │ ├── index.d.ts │ │ │ └── nested │ │ │ └── Header.svelte.d.ts │ ├── single-export-default-only │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── component │ │ │ ├── Button.svelte │ │ │ └── index.js │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── test │ │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ │ ├── Button.svelte.d.ts │ │ │ └── index.d.ts │ └── single-export │ │ ├── .gitignore │ │ ├── COMPONENT_API.json │ │ ├── COMPONENT_INDEX.md │ │ ├── bun.lock │ │ ├── component │ │ ├── Button.svelte │ │ └── index.js │ │ ├── package.json │ │ ├── rollup.config.js │ │ ├── test │ │ └── test.svelte │ │ ├── tsconfig.json │ │ └── types │ │ ├── Button.svelte.d.ts │ │ └── index.d.ts ├── element-tag-map.test.ts ├── fixtures.test.ts ├── fixtures │ ├── anchor-props │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── bind-this-multiple │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── bind-this │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── component-comment-multi │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── component-comment-single │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── context-module │ │ ├── input.svelte │ │ ├── output.d.ts │ │ ├── output.json │ │ └── types.ts │ ├── dispatched-events-dynamic │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── dispatched-events-typed │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── dispatched-events │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── empty-export │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── forwarded-events │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── function-declaration │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── generics-multiple │ │ ├── Test.svelte │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── generics-with-rest-props │ │ ├── Test.svelte │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── generics │ │ ├── Test.svelte │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── infer-basic │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── infer-with-types │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── input-events │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── mixed-events │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── no-props │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── prop-comments │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── renamed-props │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── required │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── rest-props-multiple │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── rest-props-simple │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── slots-named │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── slots-spread-typed │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── slots-spread │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── svg-props │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── typed-props │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── typed-slots │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ ├── typedef │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json │ └── typedefs │ │ ├── input.svelte │ │ ├── output.d.ts │ │ └── output.json ├── get-svelte-entry.test.ts ├── parse-exports.test.ts ├── test-e2e.ts └── writer-ts-definitions.test.ts ├── tsconfig.fixtures.json └── tsconfig.json /.bun-version: -------------------------------------------------------------------------------- 1 | 1.2.14 -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | github: metonym 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | .idea 3 | lib 4 | build 5 | dist 6 | node_modules 7 | pnpm* 8 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | tests/e2e 2 | lib 3 | dist 4 | tests/**/*.json -------------------------------------------------------------------------------- /cli.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | (() => { 4 | try { 5 | require("./lib").cli(process); 6 | } catch (error) { 7 | console.error(error); 8 | } 9 | })(); 10 | -------------------------------------------------------------------------------- /playground/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /playground/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "module", 3 | "private": true, 4 | "scripts": { 5 | "dev": "bun --bun vite", 6 | "build": "bun --bun vite build", 7 | "preview": "bun --bun vite preview" 8 | }, 9 | "devDependencies": { 10 | "@sveltejs/vite-plugin-svelte": "^3.1.2", 11 | "@types/codemirror": "^5.60.16", 12 | "carbon-components-svelte": "^0.89.2", 13 | "carbon-preprocess-svelte": "^0.11.11", 14 | "codemirror": "^5.65.19", 15 | "prettier": "^3.5.3", 16 | "svelte": "^4.2.20", 17 | "svelte-highlight": "^7.8.3", 18 | "typescript": "^5.8.3", 19 | "vite": "^5.4.19" 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /playground/src/LogoGithub20.svelte: -------------------------------------------------------------------------------- 1 | 2 | 15 | -------------------------------------------------------------------------------- /playground/src/TabJson.svelte: -------------------------------------------------------------------------------- 1 | 6 | 7 |{description}
17 |7 |10 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/rollup.config.js: -------------------------------------------------------------------------------- 1 | import pkg from "./package.json"; 2 | import svelte from "rollup-plugin-svelte"; 3 | import resolve from "@rollup/plugin-node-resolve"; 4 | import sveld from "sveld"; 5 | 6 | const production = !process.env.ROLLUP_WATCH; 7 | 8 | export default { 9 | input: "index.js", 10 | output: { format: "es", file: pkg.module }, 11 | plugins: [ 12 | svelte(), 13 | resolve(), 14 | production && sveld(), 15 | ], 16 | }; 17 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/secondary-button/secondary-button.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 12 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/test.svelte: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 |{quote} 8 | 9 |
31 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@tsconfig/svelte", 3 | } -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/types/button/button.svelte.d.ts: -------------------------------------------------------------------------------- 1 | import type { SvelteComponentTyped } from "svelte"; 2 | import type { SvelteHTMLElements } from "svelte/elements"; 3 | 4 | type $RestProps = SvelteHTMLElements["button"]; 5 | 6 | type $Props = { 7 | /** 8 | * @default "button" 9 | */ 10 | type?: "button" | "submit" | "reset"; 11 | 12 | /** 13 | * Set to `true` to use the primary variant 14 | * @default false 15 | */ 16 | primary?: boolean; 17 | 18 | [key: `data-${string}`]: any; 19 | }; 20 | 21 | export type ButtonProps = Omit<$RestProps, keyof $Props> & $Props; 22 | 23 | export default class Button extends SvelteComponentTyped< 24 | ButtonProps, 25 | { click: WindowEventMap["click"] }, 26 | { default: {} } 27 | > {} 28 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/types/index.d.ts: -------------------------------------------------------------------------------- 1 | export { default as Button } from "./button/button.svelte"; 2 | export { default as SecondaryButton } from "./secondary-button/secondary-button.svelte"; 3 | export { default as Link } from "./link/link.svelte"; 4 | export { default as Quote } from "./quote/quote.svelte"; 5 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/types/link/link.svelte.d.ts: -------------------------------------------------------------------------------- 1 | import type { SvelteComponentTyped } from "svelte"; 2 | import type { SvelteHTMLElements } from "svelte/elements"; 3 | 4 | type $RestProps = SvelteHTMLElements["a"]; 5 | 6 | type $Props = { 7 | [key: `data-${string}`]: any; 8 | }; 9 | 10 | export type LinkProps = Omit<$RestProps, keyof $Props> & $Props; 11 | 12 | export default class Link extends SvelteComponentTyped< 13 | LinkProps, 14 | { click: WindowEventMap["click"] }, 15 | { default: {} } 16 | > {} 17 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed-ts-only/types/quote/quote.svelte.d.ts: -------------------------------------------------------------------------------- 1 | import type { SvelteComponentTyped } from "svelte"; 2 | import type { SvelteHTMLElements } from "svelte/elements"; 3 | 4 | type $RestProps = SvelteHTMLElements["blockquote"]; 5 | 6 | type $Props = { 7 | /** 8 | * @default "" 9 | */ 10 | quote?: string; 11 | 12 | /** 13 | * @default "" 14 | */ 15 | author?: string; 16 | 17 | [key: `data-${string}`]: any; 18 | }; 19 | 20 | export type QuoteProps = Omit<$RestProps, keyof $Props> & $Props; 21 | 22 | export default class Quote extends SvelteComponentTyped< 23 | QuoteProps, 24 | Record
7 |10 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/src/SecondaryButton.svelte: -------------------------------------------------------------------------------- 1 | 8 | 9 | 12 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/src/index.js: -------------------------------------------------------------------------------- 1 | export { default as Button } from "./Button.svelte"; 2 | export { default as SecondaryButton } from "./SecondaryButton.svelte"; 3 | export { default as Link } from "./Link.svelte"; 4 | export { default as Quote } from "./Quote.svelte"; 5 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/test.svelte: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 |{quote} 8 | 9 |
18 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@tsconfig/svelte", 3 | } -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/types/Button.svelte.d.ts: -------------------------------------------------------------------------------- 1 | import type { SvelteComponentTyped } from "svelte"; 2 | import type { SvelteHTMLElements } from "svelte/elements"; 3 | 4 | type $RestProps = SvelteHTMLElements["button"]; 5 | 6 | type $Props = { 7 | /** 8 | * @default "button" 9 | */ 10 | type?: "button" | "submit" | "reset"; 11 | 12 | /** 13 | * Set to `true` to use the primary variant 14 | * @default false 15 | */ 16 | primary?: boolean; 17 | 18 | [key: `data-${string}`]: any; 19 | }; 20 | 21 | export type ButtonProps = Omit<$RestProps, keyof $Props> & $Props; 22 | 23 | export default class Button extends SvelteComponentTyped< 24 | ButtonProps, 25 | { click: WindowEventMap["click"] }, 26 | { default: {} } 27 | > {} 28 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/types/Link.svelte.d.ts: -------------------------------------------------------------------------------- 1 | import type { SvelteComponentTyped } from "svelte"; 2 | import type { SvelteHTMLElements } from "svelte/elements"; 3 | 4 | type $RestProps = SvelteHTMLElements["a"]; 5 | 6 | type $Props = { 7 | [key: `data-${string}`]: any; 8 | }; 9 | 10 | export type LinkProps = Omit<$RestProps, keyof $Props> & $Props; 11 | 12 | export default class Link extends SvelteComponentTyped< 13 | LinkProps, 14 | { click: WindowEventMap["click"] }, 15 | { default: {} } 16 | > {} 17 | -------------------------------------------------------------------------------- /tests/e2e/multi-export-typed/types/Quote.svelte.d.ts: -------------------------------------------------------------------------------- 1 | import type { SvelteComponentTyped } from "svelte"; 2 | import type { SvelteHTMLElements } from "svelte/elements"; 3 | 4 | type $RestProps = SvelteHTMLElements["blockquote"]; 5 | 6 | type $Props = { 7 | /** 8 | * @default "" 9 | */ 10 | quote?: string; 11 | 12 | /** 13 | * @default "" 14 | */ 15 | author?: string; 16 | 17 | [key: `data-${string}`]: any; 18 | }; 19 | 20 | export type QuoteProps = Omit<$RestProps, keyof $Props> & $Props; 21 | 22 | export default class Quote extends SvelteComponentTyped< 23 | QuoteProps, 24 | Record
14 |17 | -------------------------------------------------------------------------------- /tests/e2e/multi-export/src/index.js: -------------------------------------------------------------------------------- 1 | export { default as Button } from "./Button.svelte"; 2 | export { default as Link } from "./Link.svelte"; 3 | export { default as Quote } from "./Quote.svelte"; 4 | export { default as Header } from "./nested/Header.svelte"; 5 | -------------------------------------------------------------------------------- /tests/e2e/multi-export/src/nested/Header.svelte: -------------------------------------------------------------------------------- 1 |{quote} 15 | 16 |
19 | 20 |
14 |17 | -------------------------------------------------------------------------------- /tests/e2e/multi-folders/src/components/Button.svelte: -------------------------------------------------------------------------------- 1 | 10 | 11 | 14 | -------------------------------------------------------------------------------- /tests/e2e/multi-folders/src/components/Card.svelte: -------------------------------------------------------------------------------- 1 |{quote} 15 | 16 |
19 | 20 |