Skip to content
This repository was archived by the owner on Sep 26, 2022. It is now read-only.

Commit 0e2b134

Browse files
fix: all Playground docs Selects + Icon
Signed-off-by: Florian-Schoenherr <[email protected]>
1 parent 190d185 commit 0e2b134

File tree

8 files changed

+14
-9
lines changed

8 files changed

+14
-9
lines changed

packages/docs/src/playground/AppBar.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,13 @@
1717
let values = {
1818
variants: [],
1919
collapsed: false,
20-
color: [],
20+
color: controls.color.items[0],
2121
};
2222
</script>
2323

2424
<Playground {variants} {controls} bind:values>
2525
<AppBar
26-
class="{values.color[0]}-color"
26+
class="{values.color}-color"
2727
collapsed={values.collapsed}
2828
{...formatVariant(values.variants)}>
2929
<span slot="icon">

packages/docs/src/playground/Avatar.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@
1818
size: 48,
1919
tile: false,
2020
icon: false,
21-
color: ['primary'],
21+
color: 'primary',
2222
};
2323
</script>
2424

2525
<Playground {controls} bind:values>
26-
<Avatar tile={values.tile} size="{values.size}px" class="{values.color[0]}-color">
26+
<Avatar tile={values.tile} size="{values.size}px" class="{values.color}-color">
2727
{#if values.icon}
2828
<Icon path={mdiHome} />
2929
{:else}MS{/if}

packages/docs/src/playground/Breadcrumbs.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
1414
let values = {
1515
large: false,
16-
divider: ['/'],
16+
divider: '/',
1717
};
1818
1919
const items = [

packages/docs/src/playground/Chip.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,13 @@
3535
active: true,
3636
avatar: false,
3737
icon: items[0].value,
38-
size: ['default'],
38+
size: 'default',
3939
};
4040
</script>
4141

4242
<Playground {controls} {variants} bind:values>
4343
<Chip
44-
size={values.size[0]}
44+
size={values.size}
4545
close={values.close}
4646
bind:active={values.active}
4747
{...formatVariant(values.variants)}>

packages/docs/src/playground/Icon.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
let values = {
2424
size: 24,
2525
icon: mdiPlus,
26-
color: [],
26+
color: 'purple',
2727
};
2828
</script>
2929

packages/docs/src/playground/NavigationDrawer.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
let values = {
2020
mini: false,
2121
right: false,
22-
color: ['teal'],
22+
color: 'teal',
2323
};
2424
</script>
2525

packages/svelte-materialify/src/components/Icon/Icon.svelte

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
export let path = null;
1515
export let label = null;
1616
export let style = null;
17+
$: {
18+
width = size;
19+
height = size;
20+
}
1721
</script>
1822

1923
<style type="scss" src="./Icon.scss" global>

packages/svelte-materialify/src/components/ItemGroup/ItemGroup.svelte

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
// } else if (typeof (val) === '???') {
3737
// value = [val];
3838
} else value = val;
39+
//old:
3940
// } else if (typeof (val) === 'number') {
4041
// value = val;
4142
// } else value = [val];

0 commit comments

Comments
 (0)