tenara-ui-components 0.3.6 → 0.3.7
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/molecules/primax/HalfColumn/HalfColumn.d.ts +12 -19
- package/dist/components/molecules/primax/HalfColumn/HalfColumn.d.ts.map +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { MediaBlockProps } from '../MediaBlock';
|
|
2
3
|
import { HeadingProps } from '@/components/atoms/Heading';
|
|
3
4
|
import { BulletItem } from '@/components/atoms/BulletList';
|
|
4
5
|
import { ButtonProps } from '@/components/atoms/Button';
|
|
6
|
+
import { ButtonLinkProps } from '@/components/atoms/ButtonLink';
|
|
5
7
|
import { DividerProps } from '@/components/atoms/Divider';
|
|
6
8
|
import './HalfColumn.scss';
|
|
7
9
|
export type HalfColumnVariant = 'sparkle' | 'video' | 'media';
|
|
@@ -24,14 +26,16 @@ export interface HalfColumnContentProps {
|
|
|
24
26
|
bulletIcon?: React.ReactNode;
|
|
25
27
|
/** Button label */
|
|
26
28
|
buttonLabel?: string;
|
|
27
|
-
/** Button props
|
|
28
|
-
buttonProps?: Omit<ButtonProps, 'children' | 'darkMode'>;
|
|
29
|
+
/** Button or link props — pass `href` to render a ButtonLink, omit it to render a Button */
|
|
30
|
+
buttonProps?: Omit<ButtonProps, 'children' | 'darkMode'> | Omit<ButtonLinkProps, 'children' | 'darkMode'>;
|
|
29
31
|
}
|
|
30
32
|
export interface HalfColumnRow extends HalfColumnContentProps {
|
|
31
33
|
/** Text/content side — rendered opposite the media (overrides prop-based content) */
|
|
32
34
|
content?: React.ReactNode;
|
|
33
35
|
/** Override the variant for this specific row */
|
|
34
36
|
variant?: HalfColumnVariant;
|
|
37
|
+
/** Override media props for this specific row */
|
|
38
|
+
mediaProps?: Omit<MediaBlockProps, 'className'>;
|
|
35
39
|
/** Which side the media appears on */
|
|
36
40
|
mediaPosition?: HalfColumnMediaPosition;
|
|
37
41
|
/** Vertical alignment of columns */
|
|
@@ -40,22 +44,8 @@ export interface HalfColumnRow extends HalfColumnContentProps {
|
|
|
40
44
|
export interface HalfColumnProps extends DividerProps, HalfColumnContentProps {
|
|
41
45
|
/** Visual variant controlling the media block style */
|
|
42
46
|
variant?: HalfColumnVariant;
|
|
43
|
-
/**
|
|
44
|
-
|
|
45
|
-
/** Alt text for the media */
|
|
46
|
-
alt?: string;
|
|
47
|
-
/** Wistia media ID (video variant) */
|
|
48
|
-
wistiaId?: string;
|
|
49
|
-
/** Custom play button element (video variant) */
|
|
50
|
-
playIcon?: React.ReactNode;
|
|
51
|
-
/** Show overlay on video thumbnail */
|
|
52
|
-
overlay?: boolean;
|
|
53
|
-
/** Show the L-shaped accent border (media & video variants) */
|
|
54
|
-
accentBorder?: boolean;
|
|
55
|
-
/** Show decorative sparkle overlay (media & video variants) */
|
|
56
|
-
sparkle?: boolean;
|
|
57
|
-
/** Mirror decorative elements */
|
|
58
|
-
mirror?: boolean;
|
|
47
|
+
/** Props passed directly to MediaBlock (thumbnail, src, wistiaId, accentBorder, sparkle, etc.) */
|
|
48
|
+
mediaProps?: Omit<MediaBlockProps, 'className'>;
|
|
59
49
|
/** Which side the media appears on (single-row shorthand) */
|
|
60
50
|
mediaPosition?: HalfColumnMediaPosition;
|
|
61
51
|
/** Text/content for the non-media column (overrides prop-based content) */
|
|
@@ -78,7 +68,10 @@ export interface HalfColumnProps extends DividerProps, HalfColumnContentProps {
|
|
|
78
68
|
* Supports two content modes:
|
|
79
69
|
* 1. **Prop-based** (recommended): Pass `heading`, `paragraph`, `bulletItems`, and `buttonLabel`
|
|
80
70
|
* directly as props for a streamlined API.
|
|
81
|
-
* 2. **
|
|
71
|
+
* 2. **RichText**: Pass an HTML string via `richText` for CMS-driven content.
|
|
72
|
+
* 3. **Custom content**: Pass a `content` ReactNode for full control over the text column.
|
|
73
|
+
*
|
|
74
|
+
* Media is configured via `mediaProps` which accepts all MediaBlock props directly.
|
|
82
75
|
*
|
|
83
76
|
* Variants:
|
|
84
77
|
* - `sparkle` — cropped spark media block (no video)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HalfColumn.d.ts","sourceRoot":"","sources":["../../../../../src/components/molecules/primax/HalfColumn/HalfColumn.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"HalfColumn.d.ts","sourceRoot":"","sources":["../../../../../src/components/molecules/primax/HalfColumn/HalfColumn.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAc,eAAe,EAAE,MAAM,eAAe,CAAC;AAC5D,OAAO,EAAW,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAEnE,OAAO,EAAc,UAAU,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,EAAU,WAAW,EAAE,MAAM,2BAA2B,CAAC;AAChE,OAAO,EAAc,eAAe,EAAE,MAAM,+BAA+B,CAAC;AAE5E,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,mBAAmB,CAAC;AAE3B,MAAM,MAAM,iBAAiB,GAAG,SAAS,GAAG,OAAO,GAAG,OAAO,CAAC;AAE9D,MAAM,MAAM,uBAAuB,GAAG,MAAM,GAAG,OAAO,CAAC;AAEvD,8DAA8D;AAC9D,MAAM,WAAW,sBAAsB;IACrC,oGAAoG;IACpG,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,mBAAmB;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,oCAAoC;IACpC,YAAY,CAAC,EAAE,YAAY,CAAC,OAAO,CAAC,CAAC;IACrC,kDAAkD;IAClD,cAAc,CAAC,EAAE,YAAY,CAAC,SAAS,CAAC,CAAC;IACzC,qBAAqB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