@r2digisolutions/components 0.21.5 → 0.21.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -72,7 +72,14 @@
72
72
 
73
73
  <div class={['w-full space-y-3', className]}>
74
74
  {#if type === 'bar'}
75
- <svg viewBox={`0 0 320 ${height}`} class="h-auto w-full" role="img" aria-label="Bar chart">
75
+ <svg
76
+ viewBox={`0 0 320 ${height}`}
77
+ preserveAspectRatio="none"
78
+ class="block w-full"
79
+ style:height={`${height}px`}
80
+ role="img"
81
+ aria-label="Bar chart"
82
+ >
76
83
  {#each data as d, i}
77
84
  {@const bw = Math.max(12, (320 - 32) / data.length - 8)}
78
85
  {@const x = 16 + i * ((320 - 32) / data.length)}
@@ -93,7 +100,14 @@
93
100
  {/each}
94
101
  </svg>
95
102
  {:else if type === 'line'}
96
- <svg viewBox={`0 0 320 ${height}`} class="h-auto w-full" role="img" aria-label="Line chart">
103
+ <svg
104
+ viewBox={`0 0 320 ${height}`}
105
+ preserveAspectRatio="none"
106
+ class="block w-full"
107
+ style:height={`${height}px`}
108
+ role="img"
109
+ aria-label="Line chart"
110
+ >
97
111
  <polyline
98
112
  points={linePoints}
99
113
  fill="none"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@r2digisolutions/components",
3
- "version": "0.21.5",
3
+ "version": "0.21.6",
4
4
  "private": false,
5
5
  "description": "R2DigiSolutions Svelte 5 component library — Atomic Design, Tailwind 4, Light/Dark mode",
6
6
  "license": "MIT",