@lapismd/design-core 0.3.2 → 0.3.3
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.
- package/CHANGELOG.md +8 -0
- package/dist/shared/workspace/mobile/WorkspaceMobileDock.svelte +1 -1
- package/dist/shared/workspace/settings/CopyableValue.svelte +1 -1
- package/dist/shared/workspace/status-item/WorkspaceStatusItem.svelte +10 -2
- package/package.json +1 -1
- package/src/shared/workspace/mobile/WorkspaceMobileDock.svelte +1 -1
- package/src/shared/workspace/settings/CopyableValue.svelte +1 -1
- package/src/shared/workspace/status-item/WorkspaceStatusItem.svelte +10 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @lapismd/design-core
|
|
2
2
|
|
|
3
|
+
## 0.3.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#19](https://github.com/lapismd/design-core/pull/19) [`9732cad`](https://github.com/lapismd/design-core/commit/9732cad5a2c526ecf9b9e649a9964bc28ed08d8a) Thanks [@stevejuma](https://github.com/stevejuma)! - Keep the visible mobile tab count in the accessible action name without punctuation separating the count from its action.
|
|
8
|
+
|
|
9
|
+
- [#19](https://github.com/lapismd/design-core/pull/19) [`05ebff3`](https://github.com/lapismd/design-core/commit/05ebff382e0848f9ebcf8df0eaece3a88d3e8fde) Thanks [@stevejuma](https://github.com/stevejuma)! - Include visible status segments and shortened copyable values in their accessible names while retaining tooltip context and the full copy payload.
|
|
10
|
+
|
|
3
11
|
## 0.3.2
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
class={["ui-workspace-copyable-value", className].filter(Boolean).join(" ")}
|
|
61
61
|
variant="ghost"
|
|
62
62
|
size="xs"
|
|
63
|
-
aria-label={`Copy full ${label}: ${value}`}
|
|
63
|
+
aria-label={`Copy full ${label}: ${value}${displayValue !== value ? ` · ${displayValue}` : ""}`}
|
|
64
64
|
title={`Copy full ${label}`}
|
|
65
65
|
data-testid={testId}
|
|
66
66
|
data-copied={copied || undefined}
|
|
@@ -9,6 +9,14 @@
|
|
|
9
9
|
let { item }: { item: WorkspaceStatusItemModel } = $props();
|
|
10
10
|
let open = $state(false);
|
|
11
11
|
let menu = $state(new WorkspaceMenu());
|
|
12
|
+
const accessibleName = $derived.by(() => {
|
|
13
|
+
const context = item.tooltip ?? item.label ?? item.id;
|
|
14
|
+
const visible = item.segments?.join(" ") ?? item.label ?? "";
|
|
15
|
+
return visible &&
|
|
16
|
+
!context.toLocaleLowerCase().includes(visible.toLocaleLowerCase())
|
|
17
|
+
? `${context} · ${visible}`
|
|
18
|
+
: context;
|
|
19
|
+
});
|
|
12
20
|
|
|
13
21
|
function setOpen(next: boolean): void {
|
|
14
22
|
open = next;
|
|
@@ -50,7 +58,7 @@
|
|
|
50
58
|
data-ui-part="trigger"
|
|
51
59
|
disabled={item.disabled}
|
|
52
60
|
title={item.tooltip ?? item.label}
|
|
53
|
-
aria-label={
|
|
61
|
+
aria-label={accessibleName}
|
|
54
62
|
aria-busy={item.busy}
|
|
55
63
|
data-status-bar-item-id={item.id}
|
|
56
64
|
data-hint-target="status-action"
|
|
@@ -82,7 +90,7 @@
|
|
|
82
90
|
data-ui-part="button"
|
|
83
91
|
disabled={item.disabled}
|
|
84
92
|
title={item.tooltip ?? item.label}
|
|
85
|
-
aria-label={
|
|
93
|
+
aria-label={accessibleName}
|
|
86
94
|
aria-busy={item.busy}
|
|
87
95
|
data-status-bar-item-id={item.id}
|
|
88
96
|
data-hint-target="status-action"
|
package/package.json
CHANGED
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
class={["ui-workspace-copyable-value", className].filter(Boolean).join(" ")}
|
|
61
61
|
variant="ghost"
|
|
62
62
|
size="xs"
|
|
63
|
-
aria-label={`Copy full ${label}: ${value}`}
|
|
63
|
+
aria-label={`Copy full ${label}: ${value}${displayValue !== value ? ` · ${displayValue}` : ""}`}
|
|
64
64
|
title={`Copy full ${label}`}
|
|
65
65
|
data-testid={testId}
|
|
66
66
|
data-copied={copied || undefined}
|
|
@@ -9,6 +9,14 @@
|
|
|
9
9
|
let { item }: { item: WorkspaceStatusItemModel } = $props();
|
|
10
10
|
let open = $state(false);
|
|
11
11
|
let menu = $state(new WorkspaceMenu());
|
|
12
|
+
const accessibleName = $derived.by(() => {
|
|
13
|
+
const context = item.tooltip ?? item.label ?? item.id;
|
|
14
|
+
const visible = item.segments?.join(" ") ?? item.label ?? "";
|
|
15
|
+
return visible &&
|
|
16
|
+
!context.toLocaleLowerCase().includes(visible.toLocaleLowerCase())
|
|
17
|
+
? `${context} · ${visible}`
|
|
18
|
+
: context;
|
|
19
|
+
});
|
|
12
20
|
|
|
13
21
|
function setOpen(next: boolean): void {
|
|
14
22
|
open = next;
|
|
@@ -50,7 +58,7 @@
|
|
|
50
58
|
data-ui-part="trigger"
|
|
51
59
|
disabled={item.disabled}
|
|
52
60
|
title={item.tooltip ?? item.label}
|
|
53
|
-
aria-label={
|
|
61
|
+
aria-label={accessibleName}
|
|
54
62
|
aria-busy={item.busy}
|
|
55
63
|
data-status-bar-item-id={item.id}
|
|
56
64
|
data-hint-target="status-action"
|
|
@@ -82,7 +90,7 @@
|
|
|
82
90
|
data-ui-part="button"
|
|
83
91
|
disabled={item.disabled}
|
|
84
92
|
title={item.tooltip ?? item.label}
|
|
85
|
-
aria-label={
|
|
93
|
+
aria-label={accessibleName}
|
|
86
94
|
aria-busy={item.busy}
|
|
87
95
|
data-status-bar-item-id={item.id}
|
|
88
96
|
data-hint-target="status-action"
|