mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 02:11:05 +00:00
Fix a11y-mouse-events warning, update docs (#765)
* docs: update number of available Carbon icons * docs: add svelte:head example for loading CDN styles * chore(deps-dev): upgrade svelte to 3.40.1 * fix(a11y): disable a11y-mouse-events-have-key-events warning #760 * fix(deps): upgrade carbon-icons-svelte to v10.36.0 to avoid a11y warnings #760 * refactor(overflow-menu): remove formatStyle utility * docs: links in paragraphs should be inline * docs: add note on using all styles for dynamic theming
This commit is contained in:
parent
fa11c2e9c4
commit
6db4112b40
86 changed files with 161 additions and 28 deletions
|
@ -64,8 +64,6 @@
|
|||
import OverflowMenuVertical16 from "carbon-icons-svelte/lib/OverflowMenuVertical16/OverflowMenuVertical16.svelte";
|
||||
import OverflowMenuHorizontal16 from "carbon-icons-svelte/lib/OverflowMenuHorizontal16/OverflowMenuHorizontal16.svelte";
|
||||
|
||||
import { formatStyle } from "./formatStyle";
|
||||
|
||||
const ctxBreadcrumbItem = getContext("BreadcrumbItem");
|
||||
const dispatch = createEventDispatcher();
|
||||
const items = writable([]);
|
||||
|
@ -155,10 +153,11 @@
|
|||
$: if ($items[$currentIndex]) {
|
||||
focusedId.set($items[$currentIndex].id);
|
||||
}
|
||||
$: dynamicPseudoWidth = `#${id} .bx--overflow-menu-options.bx--overflow-menu-options:after {
|
||||
$: styles = `<style>
|
||||
#${id} .bx--overflow-menu-options.bx--overflow-menu-options:after {
|
||||
width: ${buttonWidth ? buttonWidth + "px" : "2rem"};
|
||||
}`;
|
||||
$: styles = formatStyle(dynamicPseudoWidth);
|
||||
}
|
||||
<\/style>`;
|
||||
</script>
|
||||
|
||||
<svelte:head>
|
||||
|
@ -174,6 +173,7 @@
|
|||
}}"
|
||||
/>
|
||||
|
||||
<!-- svelte-ignore a11y-mouse-events-have-key-events -->
|
||||
<button
|
||||
bind:this="{buttonRef}"
|
||||
type="button"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue