@hyvor/design 2.1.14 → 2.1.16
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/dist/components/ButtonGroup/ButtonGroup.svelte +5 -4
- package/dist/components/ButtonGroup/ButtonGroup.svelte.d.ts +1 -0
- package/dist/components/DetailCard/DetailCard.svelte +2 -1
- package/dist/components/Dropdown/DropdownContent.svelte +22 -6
- package/dist/marketing/AllFeaturesAccordion/AllFeaturesAccordion.svelte +30 -0
- package/dist/marketing/AllFeaturesAccordion/AllFeaturesAccordionFeature.svelte +15 -2
- package/dist/marketing/Footer/Footer.svelte +28 -1
- package/dist/marketing/Footer/FooterLinkList.svelte +5 -1
- package/dist/marketing/Header/Header.svelte +21 -4
- package/dist/marketing/Header/HeaderLanguageToggle.svelte +50 -29
- package/dist/marketing/Header/HeaderMobileSection.svelte +108 -0
- package/dist/marketing/Header/HeaderMobileSection.svelte.d.ts +12 -0
- package/dist/marketing/Header/HeaderNavMenu.svelte +54 -0
- package/dist/marketing/Header/HeaderNavMenu.svelte.d.ts +12 -0
- package/dist/marketing/Header/breakpoint.d.ts +1 -0
- package/dist/marketing/Header/breakpoint.js +2 -0
- package/dist/marketing/LogoStrip/LogoStrip.svelte +48 -24
- package/dist/marketing/Testimonials/Testimonials.svelte +320 -160
- package/dist/marketing/Testimonials/Testimonials.svelte.d.ts +7 -0
- package/dist/marketing/index.d.ts +1 -0
- package/dist/marketing/index.js +1 -0
- package/package.json +1 -1
|
@@ -26,8 +26,15 @@
|
|
|
26
26
|
speed = 34
|
|
27
27
|
}: Props = $props();
|
|
28
28
|
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
let containerWidth = $state(0);
|
|
30
|
+
let setWidths = $state<number[]>([]);
|
|
31
|
+
const setWidth = $derived(setWidths[0] ?? 0);
|
|
32
|
+
|
|
33
|
+
const copies = $derived.by(() => {
|
|
34
|
+
if (!setWidth || !containerWidth) return 2;
|
|
35
|
+
const needed = Math.ceil((containerWidth * 2) / setWidth);
|
|
36
|
+
return Math.min(20, Math.max(2, needed % 2 === 0 ? needed : needed + 1));
|
|
37
|
+
});
|
|
31
38
|
</script>
|
|
32
39
|
|
|
33
40
|
{#snippet logoImg(logo: Logo, hidden = false)}
|
|
@@ -65,23 +72,27 @@
|
|
|
65
72
|
</div>
|
|
66
73
|
|
|
67
74
|
{#if marquee}
|
|
68
|
-
<div class="marquee hds-container-max">
|
|
69
|
-
<div class="marquee-track">
|
|
70
|
-
{#each
|
|
71
|
-
{@const hidden =
|
|
72
|
-
{
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
75
|
+
<div class="marquee hds-container-max" bind:clientWidth={containerWidth}>
|
|
76
|
+
<div class="marquee-track" style:--ls-copies={copies}>
|
|
77
|
+
{#each Array.from({ length: copies }) as _, setIndex (setIndex)}
|
|
78
|
+
{@const hidden = setIndex > 0}
|
|
79
|
+
<div class="marquee-set" bind:clientWidth={setWidths[setIndex]} aria-hidden={hidden}>
|
|
80
|
+
{#each logos as logo}
|
|
81
|
+
{#if logo.href}
|
|
82
|
+
<a
|
|
83
|
+
href={logo.href}
|
|
84
|
+
target="_blank"
|
|
85
|
+
rel="noopener"
|
|
86
|
+
class="logo-link"
|
|
87
|
+
tabindex={hidden ? -1 : undefined}
|
|
88
|
+
>
|
|
89
|
+
{@render logoImg(logo, hidden)}
|
|
90
|
+
</a>
|
|
91
|
+
{:else}
|
|
92
|
+
{@render logoImg(logo, hidden)}
|
|
93
|
+
{/if}
|
|
94
|
+
{/each}
|
|
95
|
+
</div>
|
|
85
96
|
{/each}
|
|
86
97
|
</div>
|
|
87
98
|
</div>
|
|
@@ -134,9 +145,18 @@
|
|
|
134
145
|
.marquee-track {
|
|
135
146
|
display: flex;
|
|
136
147
|
align-items: center;
|
|
137
|
-
gap: 52px;
|
|
138
148
|
width: max-content;
|
|
139
|
-
|
|
149
|
+
/* keep a constant per-set speed regardless of how many sets we repeat */
|
|
150
|
+
animation: marquee-scroll calc(var(--ls-speed) * var(--ls-copies, 2) / 2) linear infinite;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
.marquee-set {
|
|
154
|
+
display: flex;
|
|
155
|
+
align-items: center;
|
|
156
|
+
flex: none;
|
|
157
|
+
gap: 52px;
|
|
158
|
+
/* trailing gap so every set is an identical width and -50% lands cleanly */
|
|
159
|
+
padding-right: 52px;
|
|
140
160
|
}
|
|
141
161
|
|
|
142
162
|
.marquee:hover .marquee-track {
|
|
@@ -148,7 +168,6 @@
|
|
|
148
168
|
transform: translateX(0);
|
|
149
169
|
}
|
|
150
170
|
to {
|
|
151
|
-
/* one full set-width, since the track is two identical sets back to back */
|
|
152
171
|
transform: translateX(-50%);
|
|
153
172
|
}
|
|
154
173
|
}
|
|
@@ -186,13 +205,18 @@
|
|
|
186
205
|
|
|
187
206
|
.marquee-track {
|
|
188
207
|
animation: none;
|
|
208
|
+
width: 100%;
|
|
209
|
+
padding: 0 15px;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.marquee-set {
|
|
189
213
|
flex-wrap: wrap;
|
|
190
214
|
justify-content: center;
|
|
191
215
|
width: 100%;
|
|
192
|
-
padding: 0
|
|
216
|
+
padding-right: 0;
|
|
193
217
|
}
|
|
194
218
|
|
|
195
|
-
.marquee-
|
|
219
|
+
.marquee-set:not(:first-child) {
|
|
196
220
|
display: none;
|
|
197
221
|
}
|
|
198
222
|
}
|