mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-20 20:33:02 +00:00
Merge branch 'master' into patch-4
This commit is contained in:
commit
7f1b250df5
8 changed files with 36 additions and 23 deletions
14
CHANGELOG.md
14
CHANGELOG.md
|
@ -7,6 +7,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
|
|
||||||
<!-- ## Unreleased -->
|
<!-- ## Unreleased -->
|
||||||
|
|
||||||
|
## [0.47.3](https://github.com/carbon-design-system/carbon-components-svelte/releases/tag/v0.47.3) - 2021-10-22
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- correctly toggle batch expansion button in `DataTable`
|
||||||
|
|
||||||
|
## [0.47.2](https://github.com/carbon-design-system/carbon-components-svelte/releases/tag/v0.47.2) - 2021-10-21
|
||||||
|
|
||||||
|
**Fixes**
|
||||||
|
|
||||||
|
- close the open `Tooltip` when using multiple tooltips
|
||||||
|
- collapse batch expansion button in `DataTable` if one or more rows is collapsed
|
||||||
|
- omit explicit reference to "carbon-icons-svelte" from `icon` prop descriptions
|
||||||
|
|
||||||
## [0.47.1](https://github.com/carbon-design-system/carbon-components-svelte/releases/tag/v0.47.1) - 2021-10-20
|
## [0.47.1](https://github.com/carbon-design-system/carbon-components-svelte/releases/tag/v0.47.1) - 2021-10-20
|
||||||
|
|
||||||
**Fixes**
|
**Fixes**
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
# Component Index
|
# Component Index
|
||||||
|
|
||||||
> 172 components exported from carbon-components-svelte@0.47.1.
|
> 172 components exported from carbon-components-svelte@0.47.3.
|
||||||
|
|
||||||
## Components
|
## Components
|
||||||
|
|
||||||
|
|
|
@ -212,7 +212,7 @@ The preprocessor optimizes imports from the following packages:
|
||||||
- import { Button } from "carbon-components-svelte";
|
- import { Button } from "carbon-components-svelte";
|
||||||
- import { Add16 } from "carbon-icons-svelte";
|
- import { Add16 } from "carbon-icons-svelte";
|
||||||
- import { Airplane } from "carbon-pictograms-svelte";
|
- import { Airplane } from "carbon-pictograms-svelte";
|
||||||
+ import Button from "carbon-components-svelte/Button/Button.svelte";
|
+ import Button from "carbon-components-svelte/src/Button/Button.svelte";
|
||||||
+ import Add16 from "carbon-icons-svelte/lib/Add16/Add16.svelte";
|
+ import Add16 from "carbon-icons-svelte/lib/Add16/Add16.svelte";
|
||||||
+ import Airplane from "carbon-pictograms-svelte/lib/Airplane/Airplane.svelte";
|
+ import Airplane from "carbon-pictograms-svelte/lib/Airplane/Airplane.svelte";
|
||||||
```
|
```
|
||||||
|
|
|
@ -9,15 +9,15 @@
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
|
|
||||||
<div style="margin-top: var(--cds-spacing-12);">
|
<div style="margin-top: var(--cds-spacing-12);">
|
||||||
<Button size="small" on:click="{() => (open = !open)}">
|
<Button size="small" disabled="{open}" on:click="{() => (open = true)}">
|
||||||
{open ? "Close tooltip" : "Open tooltip"}
|
Open
|
||||||
|
</Button>
|
||||||
|
<Button
|
||||||
|
size="small"
|
||||||
|
kind="secondary"
|
||||||
|
disabled="{!open}"
|
||||||
|
on:click="{() => (open = false)}"
|
||||||
|
>
|
||||||
|
Close
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>Open: {open}</div>
|
|
||||||
|
|
||||||
<style>
|
|
||||||
div {
|
|
||||||
margin-top: var(--cds-spacing-05);
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "carbon-components-svelte",
|
"name": "carbon-components-svelte",
|
||||||
"version": "0.47.1",
|
"version": "0.47.3",
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"description": "Svelte implementation of the Carbon Design System",
|
"description": "Svelte implementation of the Carbon Design System",
|
||||||
"svelte": "./src/index.js",
|
"svelte": "./src/index.js",
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"version": "0.47.1",
|
"version": "0.47.3",
|
||||||
"components": {
|
"components": {
|
||||||
"Accordion": {
|
"Accordion": {
|
||||||
"path": "carbon-components-svelte/src/Accordion/Accordion.svelte"
|
"path": "carbon-components-svelte/src/Accordion/Accordion.svelte"
|
||||||
|
|
|
@ -172,10 +172,7 @@
|
||||||
selectedRowIds.length > 0 && selectedRowIds.length < rows.length;
|
selectedRowIds.length > 0 && selectedRowIds.length < rows.length;
|
||||||
$: if (batchExpansion) {
|
$: if (batchExpansion) {
|
||||||
expandable = true;
|
expandable = true;
|
||||||
|
expanded = expandedRowIds.length === expandableRowIds.length;
|
||||||
if (expandedRowIds.length < expandableRowIds.length) {
|
|
||||||
expanded = false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
$: if (radio || batchSelection) selectable = true;
|
$: if (radio || batchSelection) selectable = true;
|
||||||
$: tableSortable.set(sortable);
|
$: tableSortable.set(sortable);
|
||||||
|
|
|
@ -165,12 +165,14 @@
|
||||||
|
|
||||||
<svelte:window
|
<svelte:window
|
||||||
on:mousedown="{({ target }) => {
|
on:mousedown="{({ target }) => {
|
||||||
if (open && target.contains(refTooltip)) {
|
if (open) {
|
||||||
|
if (target.contains(refTooltip)) {
|
||||||
if (refIcon) {
|
if (refIcon) {
|
||||||
refIcon.focus();
|
refIcon.focus();
|
||||||
} else if (ref) {
|
} else if (ref) {
|
||||||
ref.focus();
|
ref.focus();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
open = false;
|
open = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue