@softwareone/spi-sv5-library 1.5.5 → 1.5.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.
@@ -19,7 +19,9 @@
19
19
  {#if column.type === ColumnType.Text}
20
20
  <h2>{column.label}</h2>
21
21
  <p>{column.value}</p>
22
- <p class="text-description">{column.description ?? ''}</p>
22
+ {#if column.description}
23
+ <p class="text-description">{column.description}</p>
24
+ {/if}
23
25
  {/if}
24
26
 
25
27
  {#if column.type === ColumnType.Status}
@@ -37,14 +39,27 @@
37
39
  {#if column.type === ColumnType.Image}
38
40
  {@const { content, iconType } = column}
39
41
  <h2>{column.label}</h2>
40
- {#if iconType === ImageType.Default}
41
- <img src={content} alt="icon" />
42
- {:else if iconType === ImageType.Avatar}
43
- <Avatar text={content} />
44
- {:else if iconType === ImageType.Material}
45
- <span class="material-icons">{content}</span>
46
- {/if}
47
- <p class="text-description">{column.description ?? ''}</p>
42
+
43
+ <figure class:text-right={column.alignTextRight}>
44
+ {#if iconType === ImageType.Default}
45
+ <img src={content} alt="icon" />
46
+ {:else if iconType === ImageType.Avatar}
47
+ <Avatar text={content} />
48
+ {:else if iconType === ImageType.Material}
49
+ <span class="material-icons">{content}</span>
50
+ {/if}
51
+
52
+ {#if column.value || column.description}
53
+ <div>
54
+ {#if column.value}
55
+ <p>{column.value}</p>
56
+ {/if}
57
+ {#if column.description}
58
+ <p class="text-description">{column.description}</p>
59
+ {/if}
60
+ </div>
61
+ {/if}
62
+ </figure>
48
63
  {/if}
49
64
  </div>
50
65
  {/each}
@@ -70,6 +85,7 @@
70
85
  }
71
86
 
72
87
  .text-description {
88
+ font-size: 12px;
73
89
  color: #6b7180;
74
90
  }
75
91
 
@@ -121,6 +137,16 @@
121
137
  border-radius: 9999px;
122
138
  }
123
139
 
140
+ .panel-element > figure {
141
+ display: flex;
142
+ flex-direction: column;
143
+ gap: 8px;
144
+ }
145
+
146
+ .panel-element > figure.text-right {
147
+ flex-direction: row;
148
+ }
149
+
124
150
  @media screen and (max-width: 700px) {
125
151
  .buttons-section {
126
152
  flex-direction: column;
@@ -26,6 +26,7 @@ type Icon = BaseColumn & {
26
26
  type: ColumnType.Image;
27
27
  iconType: ImageType;
28
28
  content: string;
29
+ alignTextRight?: boolean;
29
30
  };
30
31
  type Status = BaseColumn & {
31
32
  type: ColumnType.Status;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@softwareone/spi-sv5-library",
3
- "version": "1.5.5",
3
+ "version": "1.5.6",
4
4
  "description": "Svelte components",
5
5
  "keywords": [
6
6
  "svelte",