@xenterprises/nuxt-x-marketing 1.14.0 → 1.15.1
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
CHANGED
|
@@ -30,6 +30,31 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
30
30
|
section and its sample product data were dropped with them. Every other section of the
|
|
31
31
|
demo page is unchanged.
|
|
32
32
|
|
|
33
|
+
## [1.15.1] - 2026-10-18
|
|
34
|
+
|
|
35
|
+
### Fixed
|
|
36
|
+
|
|
37
|
+
- **`XMarkCTA` long button labels wrap on narrow screens** instead of being clipped (seen on
|
|
38
|
+
375/390px phones). UButton renders its label with `truncate` (nowrap) inside an `inline-flex`
|
|
39
|
+
button with no max width, so a long label pushed the button past the section edge. XMarkCTA now
|
|
40
|
+
passes `ui: { base: "max-w-full", label: "whitespace-normal break-words text-center" }`: the
|
|
41
|
+
button is capped at its row, the label wraps centered, and the button grows in height.
|
|
42
|
+
Short labels (every width) and desktop are pixel-identical to 1.15.0. XMarkHero and the
|
|
43
|
+
pre-footer section use the default slot (no `truncate`) and already wrapped; they are unchanged.
|
|
44
|
+
|
|
45
|
+
## [1.15.0] - 2026-10-13
|
|
46
|
+
|
|
47
|
+
HTML change, no visual change: screenshots at 1440 and 390 (default and `container="lg"`) are
|
|
48
|
+
pixel-identical to 1.14.0.
|
|
49
|
+
|
|
50
|
+
### Fixed (accessibility)
|
|
51
|
+
|
|
52
|
+
- **`XMarkBreadcrumb` now exposes a single navigation landmark.** The outer wrapper is a `<div>`
|
|
53
|
+
(same classes, `id` and other attributes still land on it); the only `<nav>` is UBreadcrumb's,
|
|
54
|
+
labelled `aria-label="Breadcrumb"`. 1.14.0 nested `nav "Breadcrumb"` > `nav "breadcrumb"`.
|
|
55
|
+
- **The current crumb has `aria-current="page"`** (last item of `items`, or `current` in the built
|
|
56
|
+
trail). Styling of the current crumb is unchanged.
|
|
57
|
+
|
|
33
58
|
## [1.14.0] - 2026-10-13
|
|
34
59
|
|
|
35
60
|
Opt-in; without `container`, XMarkBreadcrumb renders byte-identical to 1.13.0.
|
|
@@ -1,15 +1,23 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<
|
|
2
|
+
<div
|
|
3
3
|
v-if="container"
|
|
4
4
|
class="x-mark-breadcrumb"
|
|
5
5
|
:class="containerClasses"
|
|
6
|
-
aria-label="Breadcrumb"
|
|
7
6
|
>
|
|
8
|
-
<UBreadcrumb
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
</
|
|
7
|
+
<UBreadcrumb
|
|
8
|
+
:items="resolvedItems"
|
|
9
|
+
aria-label="Breadcrumb"
|
|
10
|
+
/>
|
|
11
|
+
</div>
|
|
12
|
+
<div
|
|
13
|
+
v-else
|
|
14
|
+
class="x-mark-breadcrumb"
|
|
15
|
+
>
|
|
16
|
+
<UBreadcrumb
|
|
17
|
+
:items="resolvedItems"
|
|
18
|
+
aria-label="Breadcrumb"
|
|
19
|
+
/>
|
|
20
|
+
</div>
|
|
13
21
|
</template>
|
|
14
22
|
|
|
15
23
|
<script setup>
|
|
@@ -17,6 +25,8 @@
|
|
|
17
25
|
* XMarkBreadcrumb — Docs/Academy article breadcrumbs (marketing page standard).
|
|
18
26
|
* Prefer section + current for the default Home > Docs|Academy > page trail.
|
|
19
27
|
* Pass items to fully override. Last item is the current page (no link).
|
|
28
|
+
* 1.15.0: one landmark. The wrapper is a plain div; UBreadcrumb renders the only
|
|
29
|
+
* <nav aria-label="Breadcrumb">, and the current crumb gets aria-current="page".
|
|
20
30
|
*/
|
|
21
31
|
const props = defineProps({
|
|
22
32
|
/** Full trail [{ label, to? }]. When set, overrides section/current builders. */
|
|
@@ -90,6 +100,7 @@ const resolvedItems = computed(() => {
|
|
|
90
100
|
return {
|
|
91
101
|
label: item.label,
|
|
92
102
|
...(isLast || !item.to ? {} : { to: item.to }),
|
|
103
|
+
...(isLast ? { active: true } : {}),
|
|
93
104
|
};
|
|
94
105
|
});
|
|
95
106
|
}
|
|
@@ -102,7 +113,7 @@ const resolvedItems = computed(() => {
|
|
|
102
113
|
return [
|
|
103
114
|
{ label: props.homeLabel, to: props.homeTo },
|
|
104
115
|
{ label: sectionLabel, to: sectionTo },
|
|
105
|
-
{ label: current },
|
|
116
|
+
{ label: current, active: true },
|
|
106
117
|
];
|
|
107
118
|
});
|
|
108
119
|
</script>
|
|
@@ -67,6 +67,7 @@
|
|
|
67
67
|
:icon="button.icon"
|
|
68
68
|
:size="size === 'lg' ? 'lg' : 'md'"
|
|
69
69
|
:class="getButtonClass(button, index)"
|
|
70
|
+
:ui="buttonUi"
|
|
70
71
|
/>
|
|
71
72
|
</div>
|
|
72
73
|
</div>
|
|
@@ -272,6 +273,19 @@ const buttonsClasses = computed(() => {
|
|
|
272
273
|
return layouts[props.variant];
|
|
273
274
|
});
|
|
274
275
|
|
|
276
|
+
/**
|
|
277
|
+
* 1.15.1: let long labels wrap on narrow screens. Nuxt UI's UButton puts `truncate`
|
|
278
|
+
* (white-space: nowrap; overflow: hidden; text-overflow: ellipsis) on the label and the
|
|
279
|
+
* button is inline-flex with no max width, so a long label is forced onto one line and the
|
|
280
|
+
* button runs past the section edge, where `overflow-hidden` clips it.
|
|
281
|
+
* max-w-full caps the button at its row; whitespace-normal lets the label wrap only when it
|
|
282
|
+
* no longer fits; text-center centres the wrapped lines. Labels that fit are unaffected.
|
|
283
|
+
*/
|
|
284
|
+
const buttonUi = {
|
|
285
|
+
base: "max-w-full",
|
|
286
|
+
label: "whitespace-normal break-words text-center",
|
|
287
|
+
};
|
|
288
|
+
|
|
275
289
|
const getButtonColor = (button, index) => {
|
|
276
290
|
// Allow explicit color override
|
|
277
291
|
if (button.color && button.color !== "white") return button.color;
|