@kolkrabbi/kol-component 0.80.0 → 0.80.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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kolkrabbi/kol-component",
|
|
3
|
-
"version": "0.80.
|
|
3
|
+
"version": "0.80.1",
|
|
4
4
|
"description": "KOL design-system components — atoms through organisms, emitting canonical kol-* classes. Pairs with @kolkrabbi/kol-theme for styling.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -22,6 +22,20 @@ const HEIGHTS = {
|
|
|
22
22
|
md: 'h-[320px] md:h-[440px]',
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
+
/* The SPLIT variant's presets as LITERALS (SectionHeroSplitHeight, kol-website
|
|
26
|
+
* 2026-08-26). 0.76.0 rewrote HEIGHTS to min-h-* at runtime — a string no
|
|
27
|
+
* source file carries, so Tailwind's scanner never emitted it and every
|
|
28
|
+
* split preset was dead: the Studio hero rendered its text column's 175px.
|
|
29
|
+
* A class Tailwind cannot see is not a class. */
|
|
30
|
+
const SPLIT_HEIGHTS = {
|
|
31
|
+
full: 'min-h-dvh',
|
|
32
|
+
80: 'min-h-[70svh] md:min-h-[80vh]',
|
|
33
|
+
60: 'min-h-[50svh] md:min-h-[60vh]',
|
|
34
|
+
screen: 'min-h-dvh',
|
|
35
|
+
lg: 'min-h-dvh',
|
|
36
|
+
md: 'min-h-[50svh] md:min-h-[60vh]',
|
|
37
|
+
}
|
|
38
|
+
|
|
25
39
|
/**
|
|
26
40
|
* Background layer: a media descriptor becomes a cover-fit Image / HlsVideo /
|
|
27
41
|
* inert <video> (`.kol-full-bleed-hero-media` pins it absolute + object-cover
|
|
@@ -172,8 +186,10 @@ export default function SectionHero({
|
|
|
172
186
|
? <ContentMedia ratio={null} radius={false} fit="cover" className="h-full">{media}</ContentMedia>
|
|
173
187
|
: <MediaLayer media={media} />
|
|
174
188
|
return (
|
|
175
|
-
<section className={`kol-section-hero-split grid grid-cols-1 md:grid-cols-2 ${
|
|
176
|
-
|
|
189
|
+
<section className={`kol-section-hero-split grid grid-cols-1 md:grid-cols-2 ${SPLIT_HEIGHTS[height] || height} ${bleed} ${className}`.replace(/\s+/g, ' ').trim()}>
|
|
190
|
+
{/* the half sizes itself off the grid row (`h-full min-h-0`) so an
|
|
191
|
+
* absolute media node — the descriptor's cover-fit img — fills it */}
|
|
192
|
+
<div className={`relative h-full min-h-[50vh] overflow-hidden md:min-h-0 ${mediaFirst ? '' : 'md:order-2'}`.trim()}>{mediaNode}</div>
|
|
177
193
|
<div className={`flex items-center justify-center p-10 ${mediaFirst ? '' : 'md:order-1'}`.trim()}>
|
|
178
194
|
{/* BARE — the molecule's own voice; `headlineCase="upper"` is the
|
|
179
195
|
* split hero's one trait, a role on SectionText (SectionHeroNoOverrides) */}
|