chore: update docs

This commit is contained in:
Alessandro
2022-07-24 15:12:57 +00:00
committed by GitHub
parent b6839254d4
commit b4ae6ed1aa
2 changed files with 16 additions and 2 deletions

View File

@@ -79,4 +79,17 @@ a `sl-lazy-load` event is emitted.
<sl-tree-item lazy> Parent Node </sl-tree-item>
```
### Indentation size
Use the `--indentation-size` custom property to set the tree item's indentation.
```html preview
<sl-tree-item style="--indentation-size: 3rem" expanded>
Parent Node
<sl-tree-item> Child 1 </sl-tree-item>
<sl-tree-item> Child 2 </sl-tree-item>
<sl-tree-item> Child 3 </sl-tree-item>
</sl-tree-item>
```
[component-metadata:sl-tree-item]

View File

@@ -55,10 +55,11 @@ export default css`
display: flex;
align-items: center;
justify-content: center;
box-sizing: content-box;
color: var(--sl-color-neutral-400);
padding: var(--sl-spacing-x-small);
width: 2rem;
height: 2rem;
width: 1rem;
height: 1rem;
}
.tree-item__item {