diff --git a/COMPONENT_INDEX.md b/COMPONENT_INDEX.md index 85875a50..6088c4cc 100644 --- a/COMPONENT_INDEX.md +++ b/COMPONENT_INDEX.md @@ -659,16 +659,16 @@ None. ### Events -| Event name | Type | Detail | -| :------------ | :--------- | :----- | -| click | forwarded | -- | -| mouseover | forwarded | -- | -| mouseenter | forwarded | -- | -| mouseleave | forwarded | -- | -| transitionend | forwarded | -- | -| submit | dispatched | -- | -| close | dispatched | -- | -| open | dispatched | -- | +| Event name | Type | Detail | +| :------------ | :--------- | :------------------------------ | +| transitionend | dispatched | { open: boolean; } | +| click | forwarded | -- | +| mouseover | forwarded | -- | +| mouseenter | forwarded | -- | +| mouseleave | forwarded | -- | +| submit | dispatched | -- | +| close | dispatched | -- | +| open | dispatched | -- | ## `Content` @@ -916,6 +916,8 @@ None. | hideLabel | let | No | boolean | false | Set to `true` to visually hide the label text | | invalid | let | No | boolean | false | Set to `true` to indicate an invalid state | | invalidText | let | No | string | "" | Specify the invalid state text | +| warn | let | No | boolean | false | Set to `true` to indicate an warning state | +| warnText | let | No | string | "" | Specify the warning state text | | name | let | No | string | -- | Set a name for the input element | ### Slots @@ -988,6 +990,7 @@ export interface DropdownItem { | warnText | let | No | string | "" | Specify the warning state text | | helperText | let | No | string | "" | Specify the helper text | | label | let | No | string | -- | Specify the list box label | +| hideLabel | let | No | boolean | false | Set to `true` to visually hide the label text | | translateWithId | let | No | (id: any) => string | -- | Override the default translation ids | | id | let | No | string | "ccs-" + Math.random().toString(36) | Set an id for the list box component | | name | let | No | string | -- | Specify a name attribute for the list box | @@ -2040,17 +2043,18 @@ None. ### Events -| Event name | Type | Detail | -| :---------------------- | :--------- | :----- | -| keydown | forwarded | -- | -| click | forwarded | -- | -| mouseover | forwarded | -- | -| mouseenter | forwarded | -- | -| mouseleave | forwarded | -- | -| submit | dispatched | -- | -| click:button--secondary | dispatched | -- | -| close | dispatched | -- | -| open | dispatched | -- | +| Event name | Type | Detail | +| :---------------------- | :--------- | :------------------------------ | +| transitionend | dispatched | { open: boolean; } | +| keydown | forwarded | -- | +| click | forwarded | -- | +| mouseover | forwarded | -- | +| mouseenter | forwarded | -- | +| mouseleave | forwarded | -- | +| submit | dispatched | -- | +| click:button--secondary | dispatched | -- | +| close | dispatched | -- | +| open | dispatched | -- | ## `ModalBody` @@ -3401,6 +3405,7 @@ None. | Event name | Type | Detail | | :--------- | :-------- | :----- | +| click | forwarded | -- | | mouseover | forwarded | -- | | mouseenter | forwarded | -- | | mouseleave | forwarded | -- | @@ -3624,6 +3629,7 @@ None. | Prop name | Kind | Reactive | Type | Default value | Description | | :-------- | :--------------- | :------- | :-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------ | ------------------------------------------------------ | | type | let | No | "red" | "magenta" | "purple" | "blue" | "cyan" | "teal" | "green" | "gray" | "cool-gray" | "warm-gray" | "high-contrast" | -- | Specify the type of tag | +| size | let | No | "sm" | "default" | "default" | -- | | filter | let | No | boolean | false | Set to `true` to use filterable variant | | disabled | let | No | boolean | false | Set to `true` to disable a filterable tag | | skeleton | let | No | boolean | false | Set to `true` to display the skeleton state | @@ -3639,18 +3645,21 @@ None. ### Events -| Event name | Type | Detail | -| :--------- | :-------- | :----- | -| click | forwarded | -- | -| mouseover | forwarded | -- | -| mouseenter | forwarded | -- | -| mouseleave | forwarded | -- | +| Event name | Type | Detail | +| :--------- | :--------- | :----- | +| click | forwarded | -- | +| mouseover | forwarded | -- | +| mouseenter | forwarded | -- | +| mouseleave | forwarded | -- | +| close | dispatched | -- | ## `TagSkeleton` ### Props -None. +| Prop name | Kind | Reactive | Type | Default value | Description | +| :-------- | :--------------- | :------- | :--------------------------------- | ---------------------- | ----------- | +| size | let | No | "sm" | "default" | "default" | -- | ### Slots @@ -3957,16 +3966,17 @@ None. ### Events -| Event name | Type | Detail | -| :--------- | :-------- | :----- | -| click | forwarded | -- | -| mouseover | forwarded | -- | -| mouseenter | forwarded | -- | -| mouseleave | forwarded | -- | -| change | forwarded | -- | -| keyup | forwarded | -- | -| focus | forwarded | -- | -| blur | forwarded | -- | +| Event name | Type | Detail | +| :--------- | :--------- | :--------------------------------- | +| toggle | dispatched | { toggled: boolean; } | +| click | forwarded | -- | +| mouseover | forwarded | -- | +| mouseenter | forwarded | -- | +| mouseleave | forwarded | -- | +| change | forwarded | -- | +| keyup | forwarded | -- | +| focus | forwarded | -- | +| blur | forwarded | -- | ## `ToggleSkeleton` @@ -4141,6 +4151,7 @@ None. | expanded | let | Yes | boolean | false | Set to `true` to expand the search bar | | value | let | Yes | number | string | "" | Specify the value of the search input | | persistent | let | No | boolean | false | Set to `true` to keep the search bar expanded | +| disabled | let | No | boolean | false | Set to `true` to disable the search bar | | tabindex | let | No | string | "0" | Specify the tabindex | ### Slots @@ -4225,19 +4236,20 @@ None. ### Props -| Prop name | Kind | Reactive | Type | Default value | Description | -| :---------- | :--------------- | :------- | :-------------------------------------------------------------- | ------------------------------------------------ | ----------------------------------------------------- | -| ref | let | Yes | null | HTMLButtonElement | null | Obtain a reference to the button HTML element | -| tooltipText | let | No | string | "" | Specify the tooltip text | -| align | let | No | "start" | "center" | "end" | "center" | Set the alignment of the tooltip relative to the icon | -| direction | let | No | "top" | "right" | "bottom" | "left" | "bottom" | Set the direction of the tooltip relative to the icon | -| id | let | No | string | "ccs-" + Math.random().toString(36) | Set an id for the span element | +| Prop name | Kind | Reactive | Type | Default value | Description | +| :---------- | :--------------- | :------- | :-------------------------------------------------------------- | ------------------------------------------------ | ------------------------------------------------------------------------ | +| ref | let | Yes | null | HTMLButtonElement | null | Obtain a reference to the button HTML element | +| tooltipText | let | No | string | "" | Specify the tooltip text.
Alternatively, use the "tooltipText" slot | +| align | let | No | "start" | "center" | "end" | "center" | Set the alignment of the tooltip relative to the icon | +| direction | let | No | "top" | "right" | "bottom" | "left" | "bottom" | Set the direction of the tooltip relative to the icon | +| id | let | No | string | "ccs-" + Math.random().toString(36) | Set an id for the span element | ### Slots -| Slot name | Default | Props | Fallback | -| :-------- | :------ | :---- | :------- | -| -- | Yes | -- | -- | +| Slot name | Default | Props | Fallback | +| :---------- | :------ | :---- | :------------------------- | +| -- | Yes | -- | -- | +| tooltipText | No | -- | {tooltipText} | ### Events diff --git a/docs/package.json b/docs/package.json index 6280de78..6d5fbdf4 100644 --- a/docs/package.json +++ b/docs/package.json @@ -9,10 +9,9 @@ "build:svite": "svite build" }, "devDependencies": { - "@carbon/themes": "10.26.0", "@sveltech/routify": "^1.9.9", "autoprefixer": "^10.2.3", - "carbon-components": "10.27.0", + "carbon-components": "10.28.0", "carbon-components-svelte": "../", "clipboard-copy": "^3.1.0", "mdsvex": "^0.8.8", diff --git a/docs/src/App.svelte b/docs/src/App.svelte index 32b6194b..235e35fc 100644 --- a/docs/src/App.svelte +++ b/docs/src/App.svelte @@ -6,29 +6,12 @@ diff --git a/docs/src/layouts/ComponentLayout.svelte b/docs/src/layouts/ComponentLayout.svelte index dc836fea..238f0a52 100644 --- a/docs/src/layouts/ComponentLayout.svelte +++ b/docs/src/layouts/ComponentLayout.svelte @@ -207,4 +207,8 @@ display: block; } } + + .preview-viewer > .bx--aspect-ratio { + outline: 1px solid var(--cds-interactive-04); + } diff --git a/docs/src/pages/components/AspectRatio.svx b/docs/src/pages/components/AspectRatio.svx index 46dd8819..e2d015cc 100644 --- a/docs/src/pages/components/AspectRatio.svx +++ b/docs/src/pages/components/AspectRatio.svx @@ -9,43 +9,43 @@ Supported aspect ratios: `"2x1"`, `"16x9"`, `"4x3"`, `"1x1"`, `"3x4"`, `"9x16"`, ### Default (2x1) - + 2x1 ### Ratio 16x9 - + 16x9 ### Ratio 4x3 - + 4x3 ### Ratio 1x1 - + 1x1 ### Ratio 3x4 - + 3x4 ### Ratio 9x16 - + 9x16 ### Ratio 1x2 - + 1x2 diff --git a/docs/src/pages/components/DatePicker.svx b/docs/src/pages/components/DatePicker.svx index 5971be61..3ac83e15 100644 --- a/docs/src/pages/components/DatePicker.svx +++ b/docs/src/pages/components/DatePicker.svx @@ -43,6 +43,12 @@ components: ["DatePicker", "DatePickerInput", "DatePickerSkeleton"] +### Warning state + + + + + ### Disabled state diff --git a/docs/src/pages/components/Dropdown.svx b/docs/src/pages/components/Dropdown.svx index 70654277..4db48c86 100644 --- a/docs/src/pages/components/Dropdown.svx +++ b/docs/src/pages/components/Dropdown.svx @@ -13,6 +13,12 @@ components: ["Dropdown", "DropdownSkeleton"] {id: "1", text: "Email"}, {id: "2", text: "Fax"}]}" /> +### Hidden label + + + ### Format item display text Use the `itemToString` prop to format the display of individual items. diff --git a/docs/src/pages/components/Link.svx b/docs/src/pages/components/Link.svx index de56bdf4..115ec048 100644 --- a/docs/src/pages/components/Link.svx +++ b/docs/src/pages/components/Link.svx @@ -1,3 +1,7 @@ +--- +components: ["Link", "OutboundLink"] +--- + - + diff --git a/docs/src/pages/framed/Tabs/TabsReactive.svelte b/docs/src/pages/framed/Tabs/TabsReactive.svelte new file mode 100644 index 00000000..68a5b4ba --- /dev/null +++ b/docs/src/pages/framed/Tabs/TabsReactive.svelte @@ -0,0 +1,36 @@ + + + + + + +
+ Content 1 + Content 2 + Content 3 +
+
+ +
+

Selected index: {selected}

+
+ +
+ +
+ + diff --git a/docs/yarn.lock b/docs/yarn.lock index edf0ee21..58ecb718 100644 --- a/docs/yarn.lock +++ b/docs/yarn.lock @@ -119,21 +119,6 @@ lodash "^4.17.19" to-fast-properties "^2.0.0" -"@carbon/colors@^10.19.0": - version "10.19.0" - resolved "https://registry.npmjs.org/@carbon/colors/-/colors-10.19.0.tgz#b3fe4b8302f5a0d8450d4fe9af36eed40c035426" - integrity sha512-LrlxOuIrpWQmn8VmSu0VwuT4hRiXmSOtt9Yjs5OKEUuSIxADZFMpY+fJIvMu7q69Y4XeV6XNYrJpIExOfb62iw== - -"@carbon/import-once@^10.5.0": - version "10.5.0" - resolved "https://registry.npmjs.org/@carbon/import-once/-/import-once-10.5.0.tgz#9a84b50a761aa561ae6600a6c34b9955d97b3fd8" - integrity sha512-OlyJpA5wJ9XNv/FAogN4TGhwmrdyVYeoJ/ARkcmbdWiXwq4OTCVki9MUlV779+HYseLlXBxtlA1No3/R4Sds0g== - -"@carbon/layout@^10.17.0": - version "10.17.0" - resolved "https://registry.npmjs.org/@carbon/layout/-/layout-10.17.0.tgz#de2b80673c0ee13c451adf7060e63b117a87bc30" - integrity sha512-FS198XBh0dxfjU2GJ35b85gQbnuNFSK8IcpSBsgX7KKSIktwpPy0WV40EGQoZD/qFPIJpzZRngkJWD+d6vhf7w== - "@carbon/telemetry@0.0.0-alpha.6": version "0.0.0-alpha.6" resolved "https://registry.npmjs.org/@carbon/telemetry/-/telemetry-0.0.0-alpha.6.tgz#1d11e64f310e98f32c3db0c55f02e047f2398087" @@ -150,24 +135,6 @@ winston "^3.3.3" yargs "^16.1.1" -"@carbon/themes@10.26.0": - version "10.26.0" - resolved "https://registry.npmjs.org/@carbon/themes/-/themes-10.26.0.tgz#61720c0e51ebe6a1121e22d0f764b0d55cf8533d" - integrity sha512-8S/S3S9l+7lbxGpbz81eoRxOYtloFTMPBZtcOmfUE1bwX3y31hhxc+4hrTCqdS0LQQSDvGebfYxiF7bfiVRFRg== - dependencies: - "@carbon/colors" "^10.19.0" - "@carbon/layout" "^10.17.0" - "@carbon/type" "^10.20.0" - color "^3.1.2" - -"@carbon/type@^10.20.0": - version "10.20.0" - resolved "https://registry.npmjs.org/@carbon/type/-/type-10.20.0.tgz#cea815adb8edceb98b4f7111d82ce6aa6ac59a96" - integrity sha512-F12I0oSR9CwFavdO357+a+2S7bGK4V3iaT5F89WNBR6RyV6jSTVq02rqWaRtmDK7Axy0dH/8Dxbq/xnLynFb6g== - dependencies: - "@carbon/import-once" "^10.5.0" - "@carbon/layout" "^10.17.0" - "@dabh/diagnostics@^2.0.2": version "2.0.2" resolved "https://registry.npmjs.org/@dabh/diagnostics/-/diagnostics-2.0.2.tgz#290d08f7b381b8f94607dc8f471a12c675f9db31" @@ -870,15 +837,15 @@ caniuse-lite@^1.0.30001173, caniuse-lite@^1.0.30001178: integrity sha512-n8JVqXuZMVSPKiPiypjFtDTXc4jWIdjxull0f92WLo7e1MSi3uJ3NvveakSh/aCl1QKFAvIz3vIj0v+0K+FrXw== carbon-components-svelte@../: - version "0.26.0" + version "0.27.0" dependencies: carbon-icons-svelte "^10.21.0" flatpickr "4.6.9" -carbon-components@10.27.0: - version "10.27.0" - resolved "https://registry.npmjs.org/carbon-components/-/carbon-components-10.27.0.tgz#b984ee1b87371a64ecd041853993ffc69c9191a0" - integrity sha512-kDW3ezjfqxTydIMLZ+pTxA3oWsmhET330NTVe47hXeCRsoZ000tq0ZwGbbliSjlW2wY4s5nKxWkMj0b+dkeFyQ== +carbon-components@10.28.0: + version "10.28.0" + resolved "https://registry.yarnpkg.com/carbon-components/-/carbon-components-10.28.0.tgz#c4d2b23df2559cf3b0226867c45e2e84e0af7c4e" + integrity sha512-bFsyngr625zc/t2gl4BPFYl0/ed4q38rrPihQxBXHhLAdeZNyy8xyOQlbh1PEQbTu47H/s/bxVo6QiFm/VmLZA== dependencies: "@carbon/telemetry" "0.0.0-alpha.6" flatpickr "4.6.1" @@ -1052,7 +1019,7 @@ color-name@^1.0.0, color-name@~1.1.4: resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -color-string@^1.5.2, color-string@^1.5.4: +color-string@^1.5.2: version "1.5.4" resolved "https://registry.npmjs.org/color-string/-/color-string-1.5.4.tgz#dd51cd25cfee953d138fe4002372cc3d0e504cb6" integrity sha512-57yF5yt8Xa3czSEW1jfQDE79Idk0+AkN/4KWad6tbdxUmAs3MvjxlWSWD4deYytcRfoZ9nhKyFl1kj5tBvidbw== @@ -1068,14 +1035,6 @@ color@3.0.x: color-convert "^1.9.1" color-string "^1.5.2" -color@^3.1.2: - version "3.1.3" - resolved "https://registry.npmjs.org/color/-/color-3.1.3.tgz#ca67fb4e7b97d611dcde39eceed422067d91596e" - integrity sha512-xgXAcTHa2HeFCGLE9Xs/R82hujGtu9Jd9x4NW3T34+OMs7VoPsjwzRczKHvTAHeJwWFwX5j15+MgAppE8ztObQ== - dependencies: - color-convert "^1.9.1" - color-string "^1.5.4" - colorette@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/colorette/-/colorette-1.2.1.tgz#4d0b921325c14faf92633086a536db6e89564b1b" diff --git a/package.json b/package.json index 066ca6be..f3d30f10 100644 --- a/package.json +++ b/package.json @@ -25,12 +25,11 @@ "flatpickr": "4.6.9" }, "devDependencies": { - "@carbon/themes": "^10.26.0", - "@rollup/plugin-commonjs": "^16.0.0", - "@rollup/plugin-node-resolve": "^10.0.0", + "@rollup/plugin-commonjs": "^17.1.0", + "@rollup/plugin-node-resolve": "^11.1.1", "@tsconfig/svelte": "^1.0.10", - "autoprefixer": "^10.2.3", - "carbon-components": "10.27.0", + "autoprefixer": "^10.2.4", + "carbon-components": "10.28.0", "gh-pages": "^3.1.0", "husky": "^4.3.8", "lint-staged": "^10.5.3", @@ -38,13 +37,13 @@ "postcss": "^8.2.4", "prettier": "^2.2.1", "prettier-plugin-svelte": "^2.1.1", - "rollup": "^2.38.0", + "rollup": "^2.38.4", "rollup-plugin-svelte": "^7.1.0", "rollup-plugin-terser": "^7.0.2", - "sass": "^1.32.5", + "sass": "^1.32.6", "sveld": "0.3.0", - "svelte": "^3.32.0", - "svelte-check": "^1.1.28", + "svelte": "^3.32.1", + "svelte-check": "^1.1.32", "typescript": "^4.1.3" }, "husky": { diff --git a/src/ComposedModal/ComposedModal.svelte b/src/ComposedModal/ComposedModal.svelte index 29b2dbce..43c4621e 100644 --- a/src/ComposedModal/ComposedModal.svelte +++ b/src/ComposedModal/ComposedModal.svelte @@ -1,4 +1,8 @@
{#if label} -

{label} -

+ {/if} {#if title} -

{title} -

+ {/if} diff --git a/tests/Tag.test.svelte b/tests/Tag.test.svelte index 7e5cc57e..25524fdf 100644 --- a/tests/Tag.test.svelte +++ b/tests/Tag.test.svelte @@ -27,7 +27,7 @@ high-contrast -Filterable +Filterable Custom icon diff --git a/tests/Toggle.test.svelte b/tests/Toggle.test.svelte index bff61a99..d5af2c9e 100644 --- a/tests/Toggle.test.svelte +++ b/tests/Toggle.test.svelte @@ -4,7 +4,13 @@ - + diff --git a/tests/TooltipIcon.test.svelte b/tests/TooltipIcon.test.svelte index d5f08a12..bac010c1 100644 --- a/tests/TooltipIcon.test.svelte +++ b/tests/TooltipIcon.test.svelte @@ -23,3 +23,10 @@ + + + Carbon is an open source design system by IBM. + + diff --git a/tsconfig.json b/tsconfig.json index 567d6246..db2b31af 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1 +1 @@ -{ "extends": "@tsconfig/svelte/tsconfig.json" } +{ "extends": "@tsconfig/svelte" } diff --git a/types/ComposedModal/ComposedModal.d.ts b/types/ComposedModal/ComposedModal.d.ts index 4e78ba91..c79b4ae6 100644 --- a/types/ComposedModal/ComposedModal.d.ts +++ b/types/ComposedModal/ComposedModal.d.ts @@ -49,11 +49,11 @@ export default class ComposedModal { default: {}; }; + $on(eventname: "transitionend", cb: (event: CustomEvent<{ open: boolean }>) => void): () => void; $on(eventname: "click", cb: (event: WindowEventMap["click"]) => void): () => void; $on(eventname: "mouseover", cb: (event: WindowEventMap["mouseover"]) => void): () => void; $on(eventname: "mouseenter", cb: (event: WindowEventMap["mouseenter"]) => void): () => void; $on(eventname: "mouseleave", cb: (event: WindowEventMap["mouseleave"]) => void): () => void; - $on(eventname: "transitionend", cb: (event: WindowEventMap["transitionend"]) => void): () => void; $on(eventname: "submit", cb: (event: CustomEvent) => void): () => void; $on(eventname: "close", cb: (event: CustomEvent) => void): () => void; $on(eventname: "open", cb: (event: CustomEvent) => void): () => void; diff --git a/types/DataTable/ToolbarSearch.d.ts b/types/DataTable/ToolbarSearch.d.ts index 8ca3c8c5..6880a947 100644 --- a/types/DataTable/ToolbarSearch.d.ts +++ b/types/DataTable/ToolbarSearch.d.ts @@ -19,6 +19,12 @@ export interface ToolbarSearchProps { */ persistent?: boolean; + /** + * Set to `true` to disable the search bar + * @default false + */ + disabled?: boolean; + /** * Specify the tabindex * @default "0" diff --git a/types/DatePicker/DatePickerInput.d.ts b/types/DatePicker/DatePickerInput.d.ts index 312cfbf1..56b85a04 100644 --- a/types/DatePicker/DatePickerInput.d.ts +++ b/types/DatePicker/DatePickerInput.d.ts @@ -66,6 +66,18 @@ export interface DatePickerInputProps extends svelte.JSX.HTMLAttributes) => void): () => void; $on(eventname: "keydown", cb: (event: WindowEventMap["keydown"]) => void): () => void; $on(eventname: "click", cb: (event: WindowEventMap["click"]) => void): () => void; $on(eventname: "mouseover", cb: (event: WindowEventMap["mouseover"]) => void): () => void; diff --git a/types/Tabs/Tab.d.ts b/types/Tabs/Tab.d.ts index c0fd922f..28d20dbe 100644 --- a/types/Tabs/Tab.d.ts +++ b/types/Tabs/Tab.d.ts @@ -45,6 +45,7 @@ export default class Tab { default: {}; }; + $on(eventname: "click", cb: (event: WindowEventMap["click"]) => void): () => void; $on(eventname: "mouseover", cb: (event: WindowEventMap["mouseover"]) => void): () => void; $on(eventname: "mouseenter", cb: (event: WindowEventMap["mouseenter"]) => void): () => void; $on(eventname: "mouseleave", cb: (event: WindowEventMap["mouseleave"]) => void): () => void; diff --git a/types/Tag/Tag.d.ts b/types/Tag/Tag.d.ts index 20d122dc..cf27439f 100644 --- a/types/Tag/Tag.d.ts +++ b/types/Tag/Tag.d.ts @@ -19,6 +19,11 @@ export interface TagProps | "warm-gray" | "high-contrast"; + /** + * @default "default" + */ + size?: "sm" | "default"; + /** * Set to `true` to use filterable variant * @default false @@ -65,5 +70,6 @@ export default class Tag { $on(eventname: "mouseover", cb: (event: WindowEventMap["mouseover"]) => void): () => void; $on(eventname: "mouseenter", cb: (event: WindowEventMap["mouseenter"]) => void): () => void; $on(eventname: "mouseleave", cb: (event: WindowEventMap["mouseleave"]) => void): () => void; + $on(eventname: "close", cb: (event: CustomEvent) => void): () => void; $on(eventname: string, cb: (event: Event) => void): () => void; } diff --git a/types/Tag/TagSkeleton.d.ts b/types/Tag/TagSkeleton.d.ts index 09ef38f2..4b804129 100644 --- a/types/Tag/TagSkeleton.d.ts +++ b/types/Tag/TagSkeleton.d.ts @@ -1,6 +1,11 @@ /// -export interface TagSkeletonProps extends svelte.JSX.HTMLAttributes {} +export interface TagSkeletonProps extends svelte.JSX.HTMLAttributes { + /** + * @default "default" + */ + size?: "sm" | "default"; +} export default class TagSkeleton { $$prop_def: TagSkeletonProps; diff --git a/types/Toggle/Toggle.d.ts b/types/Toggle/Toggle.d.ts index d2440b41..7f5e82b4 100644 --- a/types/Toggle/Toggle.d.ts +++ b/types/Toggle/Toggle.d.ts @@ -53,6 +53,7 @@ export default class Toggle { $$prop_def: ToggleProps; $$slot_def: {}; + $on(eventname: "toggle", cb: (event: CustomEvent<{ toggled: boolean }>) => void): () => void; $on(eventname: "click", cb: (event: WindowEventMap["click"]) => void): () => void; $on(eventname: "mouseover", cb: (event: WindowEventMap["mouseover"]) => void): () => void; $on(eventname: "mouseenter", cb: (event: WindowEventMap["mouseenter"]) => void): () => void; diff --git a/types/TooltipIcon/TooltipIcon.d.ts b/types/TooltipIcon/TooltipIcon.d.ts index 265b1157..d58f26bc 100644 --- a/types/TooltipIcon/TooltipIcon.d.ts +++ b/types/TooltipIcon/TooltipIcon.d.ts @@ -2,7 +2,8 @@ export interface TooltipIconProps extends svelte.JSX.HTMLAttributes { /** - * Specify the tooltip text + * Specify the tooltip text. + * Alternatively, use the "tooltipText" slot * @default "" */ tooltipText?: string; @@ -36,6 +37,7 @@ export default class TooltipIcon { $$prop_def: TooltipIconProps; $$slot_def: { default: {}; + tooltipText: {}; }; $on(eventname: "click", cb: (event: WindowEventMap["click"]) => void): () => void; diff --git a/yarn.lock b/yarn.lock index f741cbdf..f3f24b16 100644 --- a/yarn.lock +++ b/yarn.lock @@ -105,21 +105,6 @@ lodash "^4.17.19" to-fast-properties "^2.0.0" -"@carbon/colors@^10.19.0": - version "10.19.0" - resolved "https://registry.npmjs.org/@carbon/colors/-/colors-10.19.0.tgz#b3fe4b8302f5a0d8450d4fe9af36eed40c035426" - integrity sha512-LrlxOuIrpWQmn8VmSu0VwuT4hRiXmSOtt9Yjs5OKEUuSIxADZFMpY+fJIvMu7q69Y4XeV6XNYrJpIExOfb62iw== - -"@carbon/import-once@^10.5.0": - version "10.5.0" - resolved "https://registry.npmjs.org/@carbon/import-once/-/import-once-10.5.0.tgz#9a84b50a761aa561ae6600a6c34b9955d97b3fd8" - integrity sha512-OlyJpA5wJ9XNv/FAogN4TGhwmrdyVYeoJ/ARkcmbdWiXwq4OTCVki9MUlV779+HYseLlXBxtlA1No3/R4Sds0g== - -"@carbon/layout@^10.17.0": - version "10.17.0" - resolved "https://registry.npmjs.org/@carbon/layout/-/layout-10.17.0.tgz#de2b80673c0ee13c451adf7060e63b117a87bc30" - integrity sha512-FS198XBh0dxfjU2GJ35b85gQbnuNFSK8IcpSBsgX7KKSIktwpPy0WV40EGQoZD/qFPIJpzZRngkJWD+d6vhf7w== - "@carbon/telemetry@0.0.0-alpha.6": version "0.0.0-alpha.6" resolved "https://registry.npmjs.org/@carbon/telemetry/-/telemetry-0.0.0-alpha.6.tgz#1d11e64f310e98f32c3db0c55f02e047f2398087" @@ -136,24 +121,6 @@ winston "^3.3.3" yargs "^16.1.1" -"@carbon/themes@^10.26.0": - version "10.26.0" - resolved "https://registry.npmjs.org/@carbon/themes/-/themes-10.26.0.tgz#61720c0e51ebe6a1121e22d0f764b0d55cf8533d" - integrity sha512-8S/S3S9l+7lbxGpbz81eoRxOYtloFTMPBZtcOmfUE1bwX3y31hhxc+4hrTCqdS0LQQSDvGebfYxiF7bfiVRFRg== - dependencies: - "@carbon/colors" "^10.19.0" - "@carbon/layout" "^10.17.0" - "@carbon/type" "^10.20.0" - color "^3.1.2" - -"@carbon/type@^10.20.0": - version "10.20.0" - resolved "https://registry.npmjs.org/@carbon/type/-/type-10.20.0.tgz#cea815adb8edceb98b4f7111d82ce6aa6ac59a96" - integrity sha512-F12I0oSR9CwFavdO357+a+2S7bGK4V3iaT5F89WNBR6RyV6jSTVq02rqWaRtmDK7Axy0dH/8Dxbq/xnLynFb6g== - dependencies: - "@carbon/import-once" "^10.5.0" - "@carbon/layout" "^10.17.0" - "@dabh/diagnostics@^2.0.2": version "2.0.2" resolved "https://registry.npmjs.org/@dabh/diagnostics/-/diagnostics-2.0.2.tgz#290d08f7b381b8f94607dc8f471a12c675f9db31" @@ -184,10 +151,10 @@ "@nodelib/fs.scandir" "2.1.4" fastq "^1.6.0" -"@rollup/plugin-commonjs@^16.0.0": - version "16.0.0" - resolved "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-16.0.0.tgz#169004d56cd0f0a1d0f35915d31a036b0efe281f" - integrity sha512-LuNyypCP3msCGVQJ7ki8PqYdpjfEkE/xtFa5DqlF+7IBD0JsfMZ87C58heSwIMint58sAUZbt3ITqOmdQv/dXw== +"@rollup/plugin-commonjs@^17.1.0": + version "17.1.0" + resolved "https://registry.yarnpkg.com/@rollup/plugin-commonjs/-/plugin-commonjs-17.1.0.tgz#757ec88737dffa8aa913eb392fade2e45aef2a2d" + integrity sha512-PoMdXCw0ZyvjpCMT5aV4nkL0QywxP29sODQsSGeDpr/oI49Qq9tRtAsb/LbYbDzFlOydVEqHmmZWFtXJEAX9ew== dependencies: "@rollup/pluginutils" "^3.1.0" commondir "^1.0.1" @@ -209,6 +176,18 @@ is-module "^1.0.0" resolve "^1.17.0" +"@rollup/plugin-node-resolve@^11.1.1": + version "11.1.1" + resolved "https://registry.yarnpkg.com/@rollup/plugin-node-resolve/-/plugin-node-resolve-11.1.1.tgz#47bc34252914794a1b06fb50371d7520a03f91f3" + integrity sha512-zlBXR4eRS+2m79TsUZWhsd0slrHUYdRx4JF+aVQm+MI0wsKdlpC2vlDVjmlGvtZY1vsefOT9w3JxvmWSBei+Lg== + dependencies: + "@rollup/pluginutils" "^3.1.0" + "@types/resolve" "1.17.1" + builtin-modules "^3.1.0" + deepmerge "^4.2.2" + is-module "^1.0.0" + resolve "^1.19.0" + "@rollup/pluginutils@^3.1.0": version "3.1.0" resolved "https://registry.npmjs.org/@rollup/pluginutils/-/pluginutils-3.1.0.tgz#706b4524ee6dc8b103b3c995533e5ad680c02b9b" @@ -390,13 +369,13 @@ at-least-node@^1.0.0: resolved "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz#602cd4b46e844ad4effc92a8011a3c46e0238dc2" integrity sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg== -autoprefixer@^10.2.3: - version "10.2.3" - resolved "https://registry.npmjs.org/autoprefixer/-/autoprefixer-10.2.3.tgz#2834b55b75cfc10fa80c66000a66dc94b7136804" - integrity sha512-vlz+iv+EnLkVaTgX8wApfYzmK3LUfK8Z9XAnmflzxMy/+oFuNK8fVGQV79SOpBv4jxk2YQJimw4hXIKZ29570A== +autoprefixer@^10.2.4: + version "10.2.4" + resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-10.2.4.tgz#c0e7cf24fcc6a1ae5d6250c623f0cb8beef2f7e1" + integrity sha512-DCCdUQiMD+P/as8m3XkeTUkUKuuRqLGcwD0nll7wevhqoJfMRpJlkFd1+MQh1pvupjiQuip42lc/VFvfUTMSKw== dependencies: browserslist "^4.16.1" - caniuse-lite "^1.0.30001178" + caniuse-lite "^1.0.30001181" colorette "^1.2.1" fraction.js "^4.0.13" normalize-range "^0.1.2" @@ -471,15 +450,20 @@ callsites@^3.0.0: resolved "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== -caniuse-lite@^1.0.30001173, caniuse-lite@^1.0.30001178: +caniuse-lite@^1.0.30001173: version "1.0.30001180" resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001180.tgz#67abcd6d1edf48fa5e7d1e84091d1d65ab76e33b" integrity sha512-n8JVqXuZMVSPKiPiypjFtDTXc4jWIdjxull0f92WLo7e1MSi3uJ3NvveakSh/aCl1QKFAvIz3vIj0v+0K+FrXw== -carbon-components@10.27.0: - version "10.27.0" - resolved "https://registry.npmjs.org/carbon-components/-/carbon-components-10.27.0.tgz#b984ee1b87371a64ecd041853993ffc69c9191a0" - integrity sha512-kDW3ezjfqxTydIMLZ+pTxA3oWsmhET330NTVe47hXeCRsoZ000tq0ZwGbbliSjlW2wY4s5nKxWkMj0b+dkeFyQ== +caniuse-lite@^1.0.30001181: + version "1.0.30001183" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001183.tgz#7a57ba9d6584119bb5f2bc76d3cc47ba9356b3e2" + integrity sha512-7JkwTEE1hlRKETbCFd8HDZeLiQIUcl8rC6JgNjvHCNaxOeNmQ9V4LvQXRUsKIV2CC73qKxljwVhToaA3kLRqTw== + +carbon-components@10.28.0: + version "10.28.0" + resolved "https://registry.yarnpkg.com/carbon-components/-/carbon-components-10.28.0.tgz#c4d2b23df2559cf3b0226867c45e2e84e0af7c4e" + integrity sha512-bFsyngr625zc/t2gl4BPFYl0/ed4q38rrPihQxBXHhLAdeZNyy8xyOQlbh1PEQbTu47H/s/bxVo6QiFm/VmLZA== dependencies: "@carbon/telemetry" "0.0.0-alpha.6" flatpickr "4.6.1" @@ -603,7 +587,7 @@ color-name@^1.0.0, color-name@~1.1.4: resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -color-string@^1.5.2, color-string@^1.5.4: +color-string@^1.5.2: version "1.5.4" resolved "https://registry.npmjs.org/color-string/-/color-string-1.5.4.tgz#dd51cd25cfee953d138fe4002372cc3d0e504cb6" integrity sha512-57yF5yt8Xa3czSEW1jfQDE79Idk0+AkN/4KWad6tbdxUmAs3MvjxlWSWD4deYytcRfoZ9nhKyFl1kj5tBvidbw== @@ -619,14 +603,6 @@ color@3.0.x: color-convert "^1.9.1" color-string "^1.5.2" -color@^3.1.2: - version "3.1.3" - resolved "https://registry.npmjs.org/color/-/color-3.1.3.tgz#ca67fb4e7b97d611dcde39eceed422067d91596e" - integrity sha512-xgXAcTHa2HeFCGLE9Xs/R82hujGtu9Jd9x4NW3T34+OMs7VoPsjwzRczKHvTAHeJwWFwX5j15+MgAppE8ztObQ== - dependencies: - color-convert "^1.9.1" - color-string "^1.5.4" - colorette@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/colorette/-/colorette-1.2.1.tgz#4d0b921325c14faf92633086a536db6e89564b1b" @@ -1266,6 +1242,13 @@ is-callable@^1.1.4, is-callable@^1.2.2: resolved "https://registry.npmjs.org/is-callable/-/is-callable-1.2.2.tgz#c7c6715cd22d4ddb48d3e19970223aceabb080d9" integrity sha512-dnMqspv5nU3LoewK2N/y7KLtxtakvTuaCsU9FU50/QDmdbHNy/4/JuRtMHqRU22o3q+W89YQndQEeCVwK+3qrA== +is-core-module@^2.1.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.2.0.tgz#97037ef3d52224d85163f5597b2b63d9afed981a" + integrity sha512-XRAfAdyyY5F5cOXn7hYQDqh2Xmii+DEfIcQGxK/uNwMHhIkPWO0g8msXcbzLe+MpGoR951MlqM/2iIlU4vKDdQ== + dependencies: + has "^1.0.3" + is-date-object@^1.0.1: version "1.0.2" resolved "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.2.tgz#bda736f2cd8fd06d32844e7743bfa7494c3bfd7e" @@ -2036,6 +2019,14 @@ resolve@^1.10.0, resolve@^1.17.0: dependencies: path-parse "^1.0.6" +resolve@^1.19.0: + version "1.19.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.19.0.tgz#1af5bf630409734a067cae29318aac7fa29a267c" + integrity sha512-rArEXAgsBG4UgRGcynxWIWKFvh/XZCcS8UJdHhwy91zwAvCZIbcs+vAbflgBnNjYMs/i/i+/Ux6IZhML1yPvxg== + dependencies: + is-core-module "^2.1.0" + path-parse "^1.0.6" + responselike@^2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/responselike/-/responselike-2.0.0.tgz#26391bcc3174f750f9a79eacc40a12a5c42d7723" @@ -2097,12 +2088,12 @@ rollup@^2.33.3: optionalDependencies: fsevents "~2.1.2" -rollup@^2.38.0: - version "2.38.0" - resolved "https://registry.npmjs.org/rollup/-/rollup-2.38.0.tgz#57942d5a10826cb12ed1f19c261f774efa502d2d" - integrity sha512-ay9zDiNitZK/LNE/EM2+v5CZ7drkB2xyDljvb1fQJCGnq43ZWRkhxN145oV8GmoW1YNi4sA/1Jdkr2LfawJoXw== +rollup@^2.38.4: + version "2.38.4" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.38.4.tgz#1b84ea8728c73b1a00a6a6e9c630ec8c3fe48cea" + integrity sha512-B0LcJhjiwKkTl79aGVF/u5KdzsH8IylVfV56Ut6c9ouWLJcUK17T83aZBetNYSnZtXf2OHD4+2PbmRW+Fp5ulg== optionalDependencies: - fsevents "~2.1.2" + fsevents "~2.3.1" run-parallel@^1.1.9: version "1.1.10" @@ -2126,10 +2117,10 @@ safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -sass@^1.32.5: - version "1.32.5" - resolved "https://registry.npmjs.org/sass/-/sass-1.32.5.tgz#2882d22ad5748c05fa9bff6c3b0ffbc4f4b9e1dc" - integrity sha512-kU1yJ5zUAmPxr7f3q0YXTAd1oZjSR1g3tYyv+xu0HZSl5JiNOaE987eiz7wCUvbm4I9fGWGU2TgApTtcP4GMNQ== +sass@^1.32.6: + version "1.32.6" + resolved "https://registry.yarnpkg.com/sass/-/sass-1.32.6.tgz#e3646c8325cd97ff75a8a15226007f3ccd221393" + integrity sha512-1bcDHDcSqeFtMr0JXI3xc/CXX6c4p0wHHivJdru8W7waM7a1WjKMm4m/Z5sY7CbVw4Whi2Chpcw6DFfSWwGLzQ== dependencies: chokidar ">=2.0.0 <4.0.0" @@ -2426,10 +2417,10 @@ sveld@0.3.0: rollup-plugin-svelte "^6.1.1" svelte "^3.30.0" -svelte-check@^1.1.28: - version "1.1.28" - resolved "https://registry.npmjs.org/svelte-check/-/svelte-check-1.1.28.tgz#f7ef1cff9a0b05368880c6a4a523cdc9c1edeb1a" - integrity sha512-jp1i8JImIwyH8gp2G9nLZ1+HXUgxPbuuT4StzeAvHdQ27b0u8XANoODcjl2w15i1J33EiH4S4CE9M3o9kau4cg== +svelte-check@^1.1.32: + version "1.1.32" + resolved "https://registry.yarnpkg.com/svelte-check/-/svelte-check-1.1.32.tgz#a3b6865130ad82861122664b27f93f9e57350484" + integrity sha512-tnG79CAz9F5kY8EYGeTfKNSN2OPbSQR/BVAFB60cFYa4P59Ti+6iGZ4gxNFm+dmzFSgZ5bjDq/AJneA0h7Pxow== dependencies: chalk "^4.0.0" chokidar "^3.4.1" @@ -2455,10 +2446,10 @@ svelte@^3.30.0: resolved "https://registry.npmjs.org/svelte/-/svelte-3.30.0.tgz#cbde341e96bf34f4ac73c8f14f8a014e03bfb7d6" integrity sha512-z+hdIACb9TROGvJBQWcItMtlr4s0DBUgJss6qWrtFkOoIInkG+iAMo/FJZQFyDBQZc+dul2+TzYSi/tpTT5/Ag== -svelte@^3.32.0: - version "3.32.0" - resolved "https://registry.npmjs.org/svelte/-/svelte-3.32.0.tgz#06d7dcdf65e62a708c74231f7099569df43e3af6" - integrity sha512-+EA3qfKDG0uB16s7m1z9Nc1o01G7YC4eq1cnHOzCy+fKsvGAJrjhjBIM3zCW2eZUu639UbHQElaOPQWUjBN3Yw== +svelte@^3.32.1: + version "3.32.1" + resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.32.1.tgz#c4b6e35517d0ed77e652cc8964ef660afa2f70f3" + integrity sha512-j1KmD2ZOU0RGq1/STDXjwfh0/eJ/Deh2NXyuz1bpR9eOcz9yImn4CGxXdbSAN7cMTm9a7IyPUIbuBCzu/pXK0g== terser@^5.0.0: version "5.3.0"