@invopop/popui 0.1.59 → 0.1.60

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.
@@ -9,6 +9,7 @@
9
9
  label = '',
10
10
  value = '',
11
11
  monospaced = false,
12
+ vertical = false,
12
13
  children,
13
14
  onCopy,
14
15
  onLink
@@ -35,20 +36,30 @@
35
36
  }
36
37
  </script>
37
38
 
38
- <div class="flex gap-6 items-center group">
39
- <div class="text-foreground-default-secondary text-base min-w-[125px]">
39
+ <div
40
+ class={clsx('flex group', {
41
+ 'flex-col gap-1.5': vertical,
42
+ 'gap-6 items-center': !vertical
43
+ })}
44
+ >
45
+ <div
46
+ class={clsx('text-foreground-default-secondary text-base', {
47
+ 'pl-2': vertical,
48
+ 'min-w-[125px]': !vertical
49
+ })}
50
+ >
40
51
  {label}
41
52
  </div>
42
53
  <!-- svelte-ignore a11y_click_events_have_key_events -->
43
54
  <!-- svelte-ignore a11y_no_static_element_interactions -->
44
55
  <div
45
56
  class={clsx(
46
- 'flex flex-1 gap-1 items-center group-hover:bg-background-default-secondary py-1 pl-2 pr-1 rounded-md min-w-0',
57
+ 'flex flex-1 gap-1 items-center group-hover:bg-background-default-secondary py-1 pl-2 pr-1 rounded-md min-w-0 h-8',
47
58
  { 'cursor-pointer': clickAction }
48
59
  )}
49
60
  onclick={clickAction ? handleAreaClick : undefined}
50
61
  >
51
- <div class="flex-1 min-w-0 h-8">
62
+ <div class="flex-1 min-w-0">
52
63
  <div class={valueStyles}>
53
64
  {#if children}
54
65
  {@render children()}
@@ -59,6 +70,7 @@
59
70
  </div>
60
71
  {#if onCopy}
61
72
  <BaseButton
73
+ size="sm"
62
74
  variant="outline"
63
75
  icon={Duplicate}
64
76
  onclick={async () => {
@@ -70,6 +82,7 @@
70
82
  {/if}
71
83
  {#if onLink}
72
84
  <BaseButton
85
+ size="sm"
73
86
  variant="outline"
74
87
  icon={ExternalLink}
75
88
  onclick={onLink}
package/dist/types.d.ts CHANGED
@@ -308,7 +308,7 @@ export interface DataListItemProps {
308
308
  label?: string;
309
309
  value?: string;
310
310
  monospaced?: boolean;
311
- fullWidth?: boolean;
311
+ vertical?: boolean;
312
312
  children?: Snippet;
313
313
  onCopy?: () => void;
314
314
  onLink?: () => void;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@invopop/popui",
3
3
  "license": "MIT",
4
- "version": "0.1.59",
4
+ "version": "0.1.60",
5
5
  "repository": {
6
6
  "url": "https://github.com/invopop/popui"
7
7
  },