@deriv-web-design/ui 0.1.4 → 0.1.6
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/block-registry.json +3237 -140
- package/components.manifest.json +2902 -0
- package/dist/award-leaf-left-HVAB5T5H.png +0 -0
- package/dist/award-leaf-right-WR5I37KI.png +0 -0
- package/dist/index.css +1941 -5
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +494 -13
- package/dist/index.d.ts +494 -13
- package/dist/index.js +1435 -19
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1420 -20
- package/dist/index.mjs.map +1 -1
- package/dist/share-facebook-3B3NOC5Q.png +0 -0
- package/dist/share-link-QGD6KIDA.png +0 -0
- package/dist/share-linkedin-UCIII3JU.png +0 -0
- package/dist/share-telegram-QRXGSHQT.png +0 -0
- package/dist/share-x-UTEBBL73.png +0 -0
- package/dist/trustpilot-rating-badge-D7JOW3KJ.png +0 -0
- package/package.json +21 -5
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as react from 'react';
|
|
3
|
-
import { ButtonHTMLAttributes, ReactNode, AnchorHTMLAttributes, HTMLAttributes, InputHTMLAttributes, MouseEvent, ComponentProps } from 'react';
|
|
3
|
+
import { ButtonHTMLAttributes, ReactNode, AnchorHTMLAttributes, HTMLAttributes, InputHTMLAttributes, MouseEvent, ChangeEvent, ComponentProps } from 'react';
|
|
4
4
|
import { DotLottieReact } from '@lottiefiles/dotlottie-react';
|
|
5
5
|
|
|
6
6
|
type ButtonColorScheme = "coral" | "black" | "white";
|
|
@@ -107,6 +107,10 @@ interface SearchFieldProps extends Omit<InputHTMLAttributes<HTMLInputElement>, "
|
|
|
107
107
|
variant?: SearchFieldVariant;
|
|
108
108
|
/** Visual validation state. Defaults to "neutral". */
|
|
109
109
|
status?: SearchFieldStatus;
|
|
110
|
+
/** Shows the leading search (magnifying-glass) icon. Defaults to `true`.
|
|
111
|
+
* Set to `false` for icon-less search bars (e.g. a Help Centre style
|
|
112
|
+
* search field where the placeholder text alone signals its purpose). */
|
|
113
|
+
showSearchIcon?: boolean;
|
|
110
114
|
/** Called when the clear (×) button is clicked.
|
|
111
115
|
* In controlled mode, update your value state here.
|
|
112
116
|
* In uncontrolled mode the input is cleared automatically. */
|
|
@@ -565,7 +569,7 @@ interface HeroProps extends HTMLAttributes<HTMLElement> {
|
|
|
565
569
|
|
|
566
570
|
declare const Hero: ({ variant, subtitle, title, description, primaryButton, secondaryButton, backgroundImageSrc, heroImage, productImage, floatingImage, className, ...props }: HeroProps) => react_jsx_runtime.JSX.Element;
|
|
567
571
|
|
|
568
|
-
type HeaderVariant = "visuals" | "minimal";
|
|
572
|
+
type HeaderVariant = "visuals" | "minimal" | "dark" | "dark-search";
|
|
569
573
|
interface HeaderButtonProps {
|
|
570
574
|
/** Button label text */
|
|
571
575
|
label: string;
|
|
@@ -574,13 +578,30 @@ interface HeaderButtonProps {
|
|
|
574
578
|
/** Link href — renders an anchor if provided */
|
|
575
579
|
href?: string;
|
|
576
580
|
}
|
|
581
|
+
interface HeaderSearchProps {
|
|
582
|
+
/** Placeholder text for the search input. Defaults to "Search". */
|
|
583
|
+
placeholder?: string;
|
|
584
|
+
/** Controlled input value */
|
|
585
|
+
value?: string;
|
|
586
|
+
/** Change handler for controlled usage */
|
|
587
|
+
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
588
|
+
/** Called when the clear (×) button is pressed */
|
|
589
|
+
onClear?: () => void;
|
|
590
|
+
/** Called on Enter keypress with the current input value */
|
|
591
|
+
onSubmit?: (value: string) => void;
|
|
592
|
+
}
|
|
577
593
|
interface HeaderProps extends HTMLAttributes<HTMLElement> {
|
|
578
594
|
/**
|
|
579
595
|
* Layout variant:
|
|
580
596
|
*
|
|
581
|
-
* - "visuals"
|
|
582
|
-
*
|
|
583
|
-
* - "minimal"
|
|
597
|
+
* - "visuals" — light grey bg + SVG grid, center-aligned text, floating visuals left & right,
|
|
598
|
+
* parallax scroll effect on visuals, min-height 540px
|
|
599
|
+
* - "minimal" — same as visuals but without the floating graphics
|
|
600
|
+
* - "dark" — dark navy bg + SVG grid, center-aligned text, no floating visuals,
|
|
601
|
+
* min-height 420px on mobile/tablet, 460px on desktop (shorter than
|
|
602
|
+
* the light variants)
|
|
603
|
+
* - "dark-search" — same as "dark" plus a search field below the text, for pages such as
|
|
604
|
+
* the Help Centre index
|
|
584
605
|
*/
|
|
585
606
|
variant: HeaderVariant;
|
|
586
607
|
/** Optional eyebrow / subtitle above the title */
|
|
@@ -591,27 +612,32 @@ interface HeaderProps extends HTMLAttributes<HTMLElement> {
|
|
|
591
612
|
description?: string;
|
|
592
613
|
/**
|
|
593
614
|
* Primary CTA button (coral).
|
|
594
|
-
* Shown on
|
|
615
|
+
* Shown on all variants.
|
|
595
616
|
*/
|
|
596
617
|
primaryButton?: HeaderButtonProps;
|
|
597
618
|
/**
|
|
598
619
|
* Secondary CTA button (white outline).
|
|
599
|
-
* Shown on
|
|
620
|
+
* Shown on all variants.
|
|
600
621
|
*/
|
|
601
622
|
secondaryButton?: HeaderButtonProps;
|
|
602
623
|
/**
|
|
603
|
-
* Left floating visual for the
|
|
624
|
+
* Left floating visual for the "visuals" variant.
|
|
604
625
|
* Accepts a ReactNode or image URL string.
|
|
605
626
|
*/
|
|
606
627
|
leftVisual?: ReactNode | string;
|
|
607
628
|
/**
|
|
608
|
-
* Right floating visual for the
|
|
629
|
+
* Right floating visual for the "visuals" variant.
|
|
609
630
|
* Accepts a ReactNode or image URL string.
|
|
610
631
|
*/
|
|
611
632
|
rightVisual?: ReactNode | string;
|
|
633
|
+
/**
|
|
634
|
+
* Search field configuration for the "dark-search" variant (e.g. Help Centre header).
|
|
635
|
+
* The field always renders for that variant; this prop only customises it.
|
|
636
|
+
*/
|
|
637
|
+
search?: HeaderSearchProps;
|
|
612
638
|
}
|
|
613
639
|
|
|
614
|
-
declare const Header: ({ variant, subtitle, title, description, primaryButton, secondaryButton, leftVisual, rightVisual, className, ...props }: HeaderProps) => react_jsx_runtime.JSX.Element;
|
|
640
|
+
declare const Header: ({ variant, subtitle, title, description, primaryButton, secondaryButton, leftVisual, rightVisual, search, className, ...props }: HeaderProps) => react_jsx_runtime.JSX.Element;
|
|
615
641
|
|
|
616
642
|
interface StatItem {
|
|
617
643
|
/** Numeric or short display value, e.g. "2.5M+" */
|
|
@@ -1239,17 +1265,43 @@ interface TestimonialItem {
|
|
|
1239
1265
|
authorLocation?: string;
|
|
1240
1266
|
/** Optional author avatar image URL */
|
|
1241
1267
|
avatarUrl?: string;
|
|
1268
|
+
/**
|
|
1269
|
+
* `trustpilot` variant only — star rating out of 5 shown on the card.
|
|
1270
|
+
* Supports halves (e.g. `4.5`). Defaults to `5`.
|
|
1271
|
+
*/
|
|
1272
|
+
rating?: number;
|
|
1273
|
+
/**
|
|
1274
|
+
* `trustpilot` variant only — link to the full review on Trustpilot.
|
|
1275
|
+
* When omitted, the card links to `trustpilotUrl` instead.
|
|
1276
|
+
*/
|
|
1277
|
+
reviewUrl?: string;
|
|
1242
1278
|
}
|
|
1243
1279
|
interface TestimonialProps {
|
|
1244
1280
|
/** Section heading */
|
|
1245
1281
|
title?: string;
|
|
1246
|
-
/** Array of testimonial items to display
|
|
1282
|
+
/** Array of testimonial items to display */
|
|
1247
1283
|
items: TestimonialItem[];
|
|
1248
1284
|
/** Optional CSS class name applied to the outer section */
|
|
1249
1285
|
className?: string;
|
|
1286
|
+
/**
|
|
1287
|
+
* Visual style.
|
|
1288
|
+
* - `default` (default): single-slide auto-advancing quote carousel with dot pagination.
|
|
1289
|
+
* - `trustpilot`: horizontally-scrollable row of star-rated review cards, a "Trustpilot"
|
|
1290
|
+
* rating badge, and prev/next controls — modeled after deriv.com's homepage
|
|
1291
|
+
* "What our customers say" section.
|
|
1292
|
+
*/
|
|
1293
|
+
variant?: "default" | "trustpilot";
|
|
1294
|
+
/**
|
|
1295
|
+
* `trustpilot` variant only — URL to the brand's Trustpilot profile page.
|
|
1296
|
+
* Used by the footer rating badge link, and as the fallback link for any
|
|
1297
|
+
* item without its own `reviewUrl`.
|
|
1298
|
+
*/
|
|
1299
|
+
trustpilotUrl?: string;
|
|
1300
|
+
/** `trustpilot` variant only — overall TrustScore shown in the footer badge (out of 5). */
|
|
1301
|
+
trustpilotScore?: number;
|
|
1250
1302
|
}
|
|
1251
1303
|
|
|
1252
|
-
declare const Testimonial: (
|
|
1304
|
+
declare const Testimonial: (props: TestimonialProps) => react_jsx_runtime.JSX.Element | null;
|
|
1253
1305
|
|
|
1254
1306
|
interface ArticleHeroArticle {
|
|
1255
1307
|
/** Article title */
|
|
@@ -1318,4 +1370,433 @@ interface ArticleSectionProps {
|
|
|
1318
1370
|
|
|
1319
1371
|
declare const ArticleSection: ({ variant, sectionTitle, linkText, onLinkClick, featured, articles, className, }: ArticleSectionProps) => react_jsx_runtime.JSX.Element;
|
|
1320
1372
|
|
|
1321
|
-
|
|
1373
|
+
interface CoralBannerButton {
|
|
1374
|
+
/** Button label */
|
|
1375
|
+
label: string;
|
|
1376
|
+
/** Link href — rendered as an `<a>` wrapping the button when provided */
|
|
1377
|
+
href?: string;
|
|
1378
|
+
/** Click handler (used when no `href` is provided) */
|
|
1379
|
+
onClick?: () => void;
|
|
1380
|
+
}
|
|
1381
|
+
interface CoralBannerSlide {
|
|
1382
|
+
/** Unique key for the slide (falls back to array index) */
|
|
1383
|
+
id?: string | number;
|
|
1384
|
+
/**
|
|
1385
|
+
* Headline. Use `"\n"` to force a manual line break
|
|
1386
|
+
* (matches the reference banner's two-line "Join 3M+ / global traders" layout).
|
|
1387
|
+
*/
|
|
1388
|
+
title: string;
|
|
1389
|
+
/** Supporting paragraph below the title */
|
|
1390
|
+
description?: string;
|
|
1391
|
+
/** Primary CTA — rendered as a solid black pill button */
|
|
1392
|
+
primaryButton?: CoralBannerButton;
|
|
1393
|
+
/** Optional secondary CTA — rendered as a white pill button */
|
|
1394
|
+
secondaryButton?: CoralBannerButton;
|
|
1395
|
+
}
|
|
1396
|
+
interface CoralBannerProps extends HTMLAttributes<HTMLElement> {
|
|
1397
|
+
/**
|
|
1398
|
+
* `static` — renders a single, non-interactive slide (no arrows/dots/autoplay).
|
|
1399
|
+
* `carousel` — renders `slides` in a swipeable, auto-advancing slider
|
|
1400
|
+
* (horizontal slide transition, dot pagination, prev/next arrows),
|
|
1401
|
+
* matching the banner used on deriv.com and deriv.com/markets/forex.
|
|
1402
|
+
*/
|
|
1403
|
+
variant?: "static" | "carousel";
|
|
1404
|
+
/** Slide content. `static` variant renders only `slides[0]`. */
|
|
1405
|
+
slides?: CoralBannerSlide[];
|
|
1406
|
+
/** Auto-advance slides (carousel only) */
|
|
1407
|
+
autoplay?: boolean;
|
|
1408
|
+
/** Milliseconds between auto-advances (carousel only). Reference site uses `2000`. */
|
|
1409
|
+
autoplayDelay?: number;
|
|
1410
|
+
/** Slide transition duration in ms. Reference site uses `330`. */
|
|
1411
|
+
transitionDuration?: number;
|
|
1412
|
+
/** Loop back to the first slide after the last (carousel only) */
|
|
1413
|
+
infinite?: boolean;
|
|
1414
|
+
/** Show the prev/next arrow controls (carousel only, 2+ slides) */
|
|
1415
|
+
showArrows?: boolean;
|
|
1416
|
+
/** Show the dot pagination (carousel only, 2+ slides) */
|
|
1417
|
+
showDots?: boolean;
|
|
1418
|
+
}
|
|
1419
|
+
|
|
1420
|
+
/**
|
|
1421
|
+
* Real deriv.com copy, exported for consumers who want to reproduce the
|
|
1422
|
+
* exact reference banner (deriv.com homepage / deriv.com/markets/forex footer promo).
|
|
1423
|
+
*/
|
|
1424
|
+
declare const CORAL_BANNER_DERIV_SLIDES: CoralBannerSlide[];
|
|
1425
|
+
declare const CoralBanner: ({ variant, slides, autoplay, autoplayDelay, transitionDuration, infinite, showArrows, showDots, className, ...props }: CoralBannerProps) => react_jsx_runtime.JSX.Element;
|
|
1426
|
+
|
|
1427
|
+
interface AwardItem {
|
|
1428
|
+
/** Main award name, e.g. "Best Trade Execution Award (MEA)" */
|
|
1429
|
+
title: string;
|
|
1430
|
+
/** Issuing body and year, e.g. "UF Awards 2025" */
|
|
1431
|
+
subtitle: string;
|
|
1432
|
+
}
|
|
1433
|
+
interface FeatureAwardsProps extends HTMLAttributes<HTMLElement> {
|
|
1434
|
+
/** Section heading. Defaults to "Our awards". */
|
|
1435
|
+
title?: string;
|
|
1436
|
+
/** Ordered list of awards to display. Defaults to `DEFAULT_AWARDS`. */
|
|
1437
|
+
awards?: AwardItem[];
|
|
1438
|
+
/**
|
|
1439
|
+
* Seconds for one full auto-scroll loop on mobile (< 768px) —
|
|
1440
|
+
* lower is faster. Mobile always auto-scrolls; this only tunes
|
|
1441
|
+
* the speed. Defaults to `32`.
|
|
1442
|
+
*/
|
|
1443
|
+
autoScrollDuration?: number;
|
|
1444
|
+
/** Extra class name merged onto the root `<section>`. */
|
|
1445
|
+
className?: string;
|
|
1446
|
+
}
|
|
1447
|
+
|
|
1448
|
+
declare const FEATURE_AWARDS_TEXT_CONTENT: {
|
|
1449
|
+
title: string;
|
|
1450
|
+
};
|
|
1451
|
+
declare const DEFAULT_AWARDS: AwardItem[];
|
|
1452
|
+
declare const FeatureAwards: ({ title, awards, autoScrollDuration, className, ...props }: FeatureAwardsProps) => react_jsx_runtime.JSX.Element | null;
|
|
1453
|
+
|
|
1454
|
+
interface FeatureBlogPost {
|
|
1455
|
+
/** Post headline */
|
|
1456
|
+
title: string;
|
|
1457
|
+
/** Post summary / dek text */
|
|
1458
|
+
summary: string;
|
|
1459
|
+
/** Card thumbnail image */
|
|
1460
|
+
thumbnail: string;
|
|
1461
|
+
thumbnailAlt?: string;
|
|
1462
|
+
/** Publish date label, e.g. "July 24, 2026" */
|
|
1463
|
+
date?: string;
|
|
1464
|
+
/** Category label, e.g. "Company" */
|
|
1465
|
+
category?: string;
|
|
1466
|
+
/** Link target — wraps the card in an anchor when set */
|
|
1467
|
+
href?: string;
|
|
1468
|
+
/** Click handler — used when `href` is not set */
|
|
1469
|
+
onClick?: () => void;
|
|
1470
|
+
}
|
|
1471
|
+
interface FeatureBlogProps extends HTMLAttributes<HTMLElement> {
|
|
1472
|
+
/** Section heading. Defaults to "Deriv press releases". */
|
|
1473
|
+
title?: string;
|
|
1474
|
+
/** Posts rendered as a responsive card grid. */
|
|
1475
|
+
posts: FeatureBlogPost[];
|
|
1476
|
+
/** Show the "See all" link below the grid (default: true) */
|
|
1477
|
+
showLink?: boolean;
|
|
1478
|
+
/** Label for the "See all" link (default: "See all press releases") */
|
|
1479
|
+
linkText?: string;
|
|
1480
|
+
/** Href for the "See all" link */
|
|
1481
|
+
linkHref?: string;
|
|
1482
|
+
onLinkClick?: () => void;
|
|
1483
|
+
/** Extra class name merged onto the root `<section>`. */
|
|
1484
|
+
className?: string;
|
|
1485
|
+
}
|
|
1486
|
+
|
|
1487
|
+
declare const FEATURE_BLOG_TEXT_CONTENT: {
|
|
1488
|
+
title: string;
|
|
1489
|
+
linkText: string;
|
|
1490
|
+
};
|
|
1491
|
+
declare const FeatureBlog: ({ title, posts, showLink, linkText, linkHref, onLinkClick, className, ...props }: FeatureBlogProps) => react_jsx_runtime.JSX.Element | null;
|
|
1492
|
+
|
|
1493
|
+
interface FeatureBlogCategoryTab {
|
|
1494
|
+
/** Stable identifier — must match `FeatureBlogCategoryPost.category` for filtering to work. CMS-managed. */
|
|
1495
|
+
id: string;
|
|
1496
|
+
/** Tab label shown in the pill row. CMS-managed. */
|
|
1497
|
+
label: string;
|
|
1498
|
+
}
|
|
1499
|
+
interface FeatureBlogCategoryPost {
|
|
1500
|
+
/** Post headline */
|
|
1501
|
+
title: string;
|
|
1502
|
+
/** Post summary / dek text */
|
|
1503
|
+
summary: string;
|
|
1504
|
+
/** Card thumbnail image */
|
|
1505
|
+
thumbnail: string;
|
|
1506
|
+
thumbnailAlt?: string;
|
|
1507
|
+
/** Publish date label, e.g. "July 24, 2026" */
|
|
1508
|
+
date?: string;
|
|
1509
|
+
/** Category tab id this post belongs to (matches a `categories[].id`). Posts also always match the "all" tab. */
|
|
1510
|
+
category: string;
|
|
1511
|
+
/** Category chip label shown on the card. Defaults to the matching tab's `label` when omitted. */
|
|
1512
|
+
categoryLabel?: string;
|
|
1513
|
+
/**
|
|
1514
|
+
* Destination URL. Absolute `http(s)://` URLs are treated as external and
|
|
1515
|
+
* open in a new tab (`target="_blank" rel="noopener noreferrer"`);
|
|
1516
|
+
* relative/internal paths (e.g. "/newsroom/my-article") navigate as a
|
|
1517
|
+
* normal same-tab inner-page link.
|
|
1518
|
+
*/
|
|
1519
|
+
href?: string;
|
|
1520
|
+
/** Click handler — used when `href` is not set (renders a `<button>`) */
|
|
1521
|
+
onClick?: () => void;
|
|
1522
|
+
}
|
|
1523
|
+
interface FeatureBlogCategoriesProps extends HTMLAttributes<HTMLElement> {
|
|
1524
|
+
/** Section heading. Defaults to "Deriv press releases". */
|
|
1525
|
+
title?: string;
|
|
1526
|
+
/** Category tabs, CMS-managed. An "all" tab is always prepended automatically. */
|
|
1527
|
+
categories: FeatureBlogCategoryTab[];
|
|
1528
|
+
/** Id used internally for the auto-prepended "show everything" tab (default: "all") */
|
|
1529
|
+
allCategoryId?: string;
|
|
1530
|
+
/** Label for the auto-prepended "show everything" tab (default: "View all") */
|
|
1531
|
+
allCategoryLabel?: string;
|
|
1532
|
+
/** Controlled active category tab id */
|
|
1533
|
+
activeCategoryId?: string;
|
|
1534
|
+
/** Initial active tab id for uncontrolled usage (default: `allCategoryId`) */
|
|
1535
|
+
defaultActiveCategoryId?: string;
|
|
1536
|
+
/** Called whenever a different tab is selected */
|
|
1537
|
+
onCategoryChange?: (id: string) => void;
|
|
1538
|
+
/** All posts — filtered client-side by the active tab and search query */
|
|
1539
|
+
posts: FeatureBlogCategoryPost[];
|
|
1540
|
+
/** Placeholder text for the search field (default: "Search") */
|
|
1541
|
+
searchPlaceholder?: string;
|
|
1542
|
+
/** Accessible label for the search field (defaults to `searchPlaceholder`) */
|
|
1543
|
+
searchAriaLabel?: string;
|
|
1544
|
+
/** Called on every keystroke in the search field with the current value */
|
|
1545
|
+
onSearchChange?: (value: string) => void;
|
|
1546
|
+
/** Message shown when no posts match the active tab + search query */
|
|
1547
|
+
emptyStateText?: string;
|
|
1548
|
+
/** Extra class name merged onto the root `<section>`. */
|
|
1549
|
+
className?: string;
|
|
1550
|
+
}
|
|
1551
|
+
|
|
1552
|
+
declare const FEATURE_BLOG_CATEGORIES_TEXT_CONTENT: {
|
|
1553
|
+
title: string;
|
|
1554
|
+
allCategoryId: string;
|
|
1555
|
+
allCategoryLabel: string;
|
|
1556
|
+
searchPlaceholder: string;
|
|
1557
|
+
emptyStateText: string;
|
|
1558
|
+
};
|
|
1559
|
+
declare const FeatureBlogCategories: ({ title, categories, allCategoryId, allCategoryLabel, activeCategoryId, defaultActiveCategoryId, onCategoryChange, posts, searchPlaceholder, searchAriaLabel, onSearchChange, emptyStateText, className, ...props }: FeatureBlogCategoriesProps) => react_jsx_runtime.JSX.Element;
|
|
1560
|
+
|
|
1561
|
+
interface HelpCentreCategoryItem {
|
|
1562
|
+
/** Stable identifier for the category (e.g. used for anchors or filtering) */
|
|
1563
|
+
id?: string;
|
|
1564
|
+
/** Category label shown under the icon */
|
|
1565
|
+
title: string;
|
|
1566
|
+
/** Icon shown above the title — an image URL or a custom ReactNode (e.g. inline SVG) */
|
|
1567
|
+
icon?: string | ReactNode;
|
|
1568
|
+
/** Alt text when `icon` is an image URL (default: "") */
|
|
1569
|
+
iconAlt?: string;
|
|
1570
|
+
/** Destination URL — renders the tile as a link */
|
|
1571
|
+
href?: string;
|
|
1572
|
+
/** Click handler — renders the tile as a button when no `href` is given */
|
|
1573
|
+
onClick?: () => void;
|
|
1574
|
+
}
|
|
1575
|
+
interface HelpCentreCategoriesProps {
|
|
1576
|
+
/** Optional H2 heading above the grid */
|
|
1577
|
+
sectionTitle?: string;
|
|
1578
|
+
/** Optional copy under the heading */
|
|
1579
|
+
sectionDescription?: string;
|
|
1580
|
+
/** Category tiles */
|
|
1581
|
+
categories: HelpCentreCategoryItem[];
|
|
1582
|
+
}
|
|
1583
|
+
|
|
1584
|
+
declare const HelpCentreCategories: ({ sectionTitle, sectionDescription, categories, }: HelpCentreCategoriesProps) => react_jsx_runtime.JSX.Element;
|
|
1585
|
+
|
|
1586
|
+
interface HelpCentreSubCategoryItem {
|
|
1587
|
+
/** Stable identifier for the question (e.g. used as the React key) */
|
|
1588
|
+
id?: string;
|
|
1589
|
+
/** The FAQ question shown on the card */
|
|
1590
|
+
question: string;
|
|
1591
|
+
/** Destination URL — renders the card as a link */
|
|
1592
|
+
href?: string;
|
|
1593
|
+
/** Click handler — renders the card as a button when no `href` is given */
|
|
1594
|
+
onClick?: () => void;
|
|
1595
|
+
}
|
|
1596
|
+
interface HelpCentreSubCategoriesProps {
|
|
1597
|
+
/** Large H1 category title shown above the search field (e.g. "Account") */
|
|
1598
|
+
title: string;
|
|
1599
|
+
/** Placeholder text for the search field (default: "Search") */
|
|
1600
|
+
searchPlaceholder?: string;
|
|
1601
|
+
/** Accessible label for the search field (default: matches `searchPlaceholder`) */
|
|
1602
|
+
searchAriaLabel?: string;
|
|
1603
|
+
/** FAQ question cards for this category (at least 1 item) */
|
|
1604
|
+
items: HelpCentreSubCategoryItem[];
|
|
1605
|
+
/**
|
|
1606
|
+
* Message shown when a search query matches no items. `{query}` is
|
|
1607
|
+
* replaced with the current search text. Default: `No results found for "{query}"`
|
|
1608
|
+
*/
|
|
1609
|
+
noResultsText?: string;
|
|
1610
|
+
/** Called whenever the search input value changes */
|
|
1611
|
+
onSearchChange?: (value: string) => void;
|
|
1612
|
+
}
|
|
1613
|
+
|
|
1614
|
+
declare const HelpCentreSubCategories: ({ title, searchPlaceholder, searchAriaLabel, items, noResultsText, onSearchChange, }: HelpCentreSubCategoriesProps) => react_jsx_runtime.JSX.Element;
|
|
1615
|
+
|
|
1616
|
+
type HelpCenterContentBlockType = "heading" | "paragraph" | "list";
|
|
1617
|
+
interface HelpCenterContentBlock {
|
|
1618
|
+
/** Block kind — "heading" and "paragraph" use `text`, "list" uses `items` */
|
|
1619
|
+
type: HelpCenterContentBlockType;
|
|
1620
|
+
/** Text content for "heading" / "paragraph" blocks */
|
|
1621
|
+
text?: string;
|
|
1622
|
+
/** Heading level for "heading" blocks (default: 2 — the page title itself is always the `<h1>`) */
|
|
1623
|
+
level?: 2 | 3;
|
|
1624
|
+
/** List entries for "list" blocks */
|
|
1625
|
+
items?: string[];
|
|
1626
|
+
/** Render a "list" block as `<ol>` instead of `<ul>` (default: false) */
|
|
1627
|
+
ordered?: boolean;
|
|
1628
|
+
}
|
|
1629
|
+
interface HelpCenterQuestionItem {
|
|
1630
|
+
/** Stable identifier for the question — used as the React key and for active-state matching */
|
|
1631
|
+
id: string;
|
|
1632
|
+
/** The FAQ question shown in the sidebar table / mobile sheet */
|
|
1633
|
+
question: string;
|
|
1634
|
+
/** Destination URL — renders the row as a link (real multi-page navigation) */
|
|
1635
|
+
href?: string;
|
|
1636
|
+
/** Click handler, called in addition to selecting the row */
|
|
1637
|
+
onClick?: () => void;
|
|
1638
|
+
/** Optional per-question title, used to swap the main content column in-place when no `href` is given */
|
|
1639
|
+
contentTitle?: string;
|
|
1640
|
+
/** Optional per-question content blocks, used to swap the main content column in-place when no `href` is given */
|
|
1641
|
+
content?: HelpCenterContentBlock[];
|
|
1642
|
+
}
|
|
1643
|
+
interface HelpCenterPageProps {
|
|
1644
|
+
/** Category name shown above the question table and on the mobile dropdown trigger (e.g. "Account") */
|
|
1645
|
+
categoryTitle: string;
|
|
1646
|
+
/** Every question belonging to this category, rendered as a single-select table/list */
|
|
1647
|
+
questions: HelpCenterQuestionItem[];
|
|
1648
|
+
/** Controlled id of the currently selected/highlighted question */
|
|
1649
|
+
activeQuestionId?: string;
|
|
1650
|
+
/** Initial selected question id for uncontrolled usage (default: first item in `questions`) */
|
|
1651
|
+
defaultActiveQuestionId?: string;
|
|
1652
|
+
/** Called whenever a different question is selected (click on a row without `href`, or via keyboard) */
|
|
1653
|
+
onQuestionSelect?: (id: string) => void;
|
|
1654
|
+
/** Main content column heading (CMS-supplied answer title, rendered as the page's `<h1>`) */
|
|
1655
|
+
contentTitle: string;
|
|
1656
|
+
/** Main content column body (CMS-supplied rich content, rendered from plain data blocks) */
|
|
1657
|
+
content: HelpCenterContentBlock[];
|
|
1658
|
+
/** Placeholder text for the top search field (default: "Search") */
|
|
1659
|
+
searchPlaceholder?: string;
|
|
1660
|
+
/** Accessible label for the search field (defaults to `searchPlaceholder`) */
|
|
1661
|
+
searchAriaLabel?: string;
|
|
1662
|
+
/** Called on every keystroke in the search field with the current value */
|
|
1663
|
+
onSearchChange?: (value: string) => void;
|
|
1664
|
+
/**
|
|
1665
|
+
* Message shown when a search query matches no questions. `{query}` is
|
|
1666
|
+
* replaced with the current search text. Default: `No results found for "{query}"`
|
|
1667
|
+
*/
|
|
1668
|
+
searchNoResultsText?: string;
|
|
1669
|
+
/** Title of the mobile "browse questions" bottom sheet (default: "Articles in this section") */
|
|
1670
|
+
articlesSheetTitle?: string;
|
|
1671
|
+
/** Additional CSS class on the outer section */
|
|
1672
|
+
className?: string;
|
|
1673
|
+
}
|
|
1674
|
+
|
|
1675
|
+
declare const HelpCenterPage: ({ categoryTitle, questions, activeQuestionId, defaultActiveQuestionId, onQuestionSelect, contentTitle, content, searchPlaceholder, searchAriaLabel, onSearchChange, searchNoResultsText, articlesSheetTitle, className, }: HelpCenterPageProps) => react_jsx_runtime.JSX.Element;
|
|
1676
|
+
|
|
1677
|
+
type FeatureBlogContentBlockType = "heading" | "paragraph" | "list" | "quote" | "image";
|
|
1678
|
+
interface FeatureBlogContentBlock {
|
|
1679
|
+
/** Block kind — "heading"/"paragraph"/"quote" use `text`, "list" uses `items`, "image" uses `image` */
|
|
1680
|
+
type: FeatureBlogContentBlockType;
|
|
1681
|
+
/** Text content for "heading" / "paragraph" / "quote" blocks */
|
|
1682
|
+
text?: string;
|
|
1683
|
+
/**
|
|
1684
|
+
* Heading level for "heading" blocks (default: 2). Only level-2 headings
|
|
1685
|
+
* are collected into the table of contents — level-3 headings render
|
|
1686
|
+
* inline as sub-sections but are not listed.
|
|
1687
|
+
*/
|
|
1688
|
+
level?: 2 | 3;
|
|
1689
|
+
/** Stable anchor id for a "heading" block; auto-generated (slugified) from `text` when omitted */
|
|
1690
|
+
id?: string;
|
|
1691
|
+
/** List entries for "list" blocks */
|
|
1692
|
+
items?: string[];
|
|
1693
|
+
/** Render a "list" block as `<ol>` instead of `<ul>` (default: false) */
|
|
1694
|
+
ordered?: boolean;
|
|
1695
|
+
/** Citation / source line for "quote" blocks */
|
|
1696
|
+
cite?: string;
|
|
1697
|
+
/** Image source for "image" blocks */
|
|
1698
|
+
image?: string;
|
|
1699
|
+
imageAlt?: string;
|
|
1700
|
+
/** Optional caption rendered below an "image" block */
|
|
1701
|
+
caption?: string;
|
|
1702
|
+
}
|
|
1703
|
+
type FeatureBlogSharePlatform = "facebook" | "twitter" | "linkedin" | "telegram";
|
|
1704
|
+
interface FeatureBlogAuthor {
|
|
1705
|
+
/** Author display name */
|
|
1706
|
+
name: string;
|
|
1707
|
+
/** Author avatar image */
|
|
1708
|
+
avatar?: string;
|
|
1709
|
+
avatarAlt?: string;
|
|
1710
|
+
}
|
|
1711
|
+
interface FeatureBlogPageProps {
|
|
1712
|
+
/** Small category label rendered above the title (e.g. "Press releases") */
|
|
1713
|
+
category?: string;
|
|
1714
|
+
/** Article headline, rendered as the page's `<h1>` (required) */
|
|
1715
|
+
title: string;
|
|
1716
|
+
/** Publish date label shown in the meta row (e.g. "July 24, 2026") */
|
|
1717
|
+
publishDate?: string;
|
|
1718
|
+
/** Article author, shown in the meta row next to the publish date */
|
|
1719
|
+
author?: FeatureBlogAuthor;
|
|
1720
|
+
/** Hero image rendered below the title / meta row */
|
|
1721
|
+
heroImage?: string;
|
|
1722
|
+
heroImageAlt?: string;
|
|
1723
|
+
/** Main article body, rendered from plain data blocks (required, at least 1 item) */
|
|
1724
|
+
content: FeatureBlogContentBlock[];
|
|
1725
|
+
/** Table of contents card heading (default: "Contents") */
|
|
1726
|
+
tocTitle?: string;
|
|
1727
|
+
/** Whether the table of contents starts expanded (default: true) */
|
|
1728
|
+
tocDefaultOpen?: boolean;
|
|
1729
|
+
/** Hide the table of contents entirely (default: false) — e.g. for very short articles with no level-2 headings */
|
|
1730
|
+
hideToc?: boolean;
|
|
1731
|
+
/** "Share article" label above the share icons (default: "Share article") */
|
|
1732
|
+
shareTitle?: string;
|
|
1733
|
+
/** Canonical URL used to build every share link and for "copy link"; sharing is hidden when omitted */
|
|
1734
|
+
shareUrl?: string;
|
|
1735
|
+
/** Text passed to platforms that accept share text (X/Twitter, Telegram); defaults to `title` */
|
|
1736
|
+
shareText?: string;
|
|
1737
|
+
/** Which social platforms to show, in order (default: all four) */
|
|
1738
|
+
sharePlatforms?: FeatureBlogSharePlatform[];
|
|
1739
|
+
/** Hide the share row entirely (default: false) */
|
|
1740
|
+
hideShare?: boolean;
|
|
1741
|
+
/** Fired whenever a share icon (including "copy link") is activated */
|
|
1742
|
+
onShare?: (platform: FeatureBlogSharePlatform | "copy") => void;
|
|
1743
|
+
/** Label shown briefly after "copy link" succeeds (default: "Copied!") */
|
|
1744
|
+
copiedLabel?: string;
|
|
1745
|
+
/** Additional CSS class on the outer `<section>` */
|
|
1746
|
+
className?: string;
|
|
1747
|
+
}
|
|
1748
|
+
|
|
1749
|
+
declare const FeatureBlogPage: ({ category, title, publishDate, author, heroImage, heroImageAlt, content, tocTitle, tocDefaultOpen, hideToc, shareTitle, shareUrl, shareText, sharePlatforms, hideShare, onShare, copiedLabel, className, }: FeatureBlogPageProps) => react_jsx_runtime.JSX.Element;
|
|
1750
|
+
|
|
1751
|
+
interface ParallaxBannerCultureCard {
|
|
1752
|
+
/** Card heading, e.g. "Integrity" */
|
|
1753
|
+
title: string;
|
|
1754
|
+
/** Supporting copy beneath the title */
|
|
1755
|
+
description: string;
|
|
1756
|
+
}
|
|
1757
|
+
interface ParallaxBannerProps extends HTMLAttributes<HTMLElement> {
|
|
1758
|
+
/**
|
|
1759
|
+
* Layout variant.
|
|
1760
|
+
* - `"default"`: banner card plus a grid of culture/value cards beneath it.
|
|
1761
|
+
* - `"banner-only"`: just the banner card — no cards grid.
|
|
1762
|
+
*/
|
|
1763
|
+
variant?: "default" | "banner-only";
|
|
1764
|
+
/** Banner headline. Defaults to "Our culture". */
|
|
1765
|
+
title?: string;
|
|
1766
|
+
/** Supporting copy beneath the headline */
|
|
1767
|
+
description?: string;
|
|
1768
|
+
/** CTA link label. Defaults to "Culture at Deriv". */
|
|
1769
|
+
ctaLabel?: string;
|
|
1770
|
+
/** CTA link href */
|
|
1771
|
+
ctaHref?: string;
|
|
1772
|
+
/** Callback fired when the CTA link is clicked */
|
|
1773
|
+
onCtaClick?: () => void;
|
|
1774
|
+
/** URL of the photo shown in the banner's image panel */
|
|
1775
|
+
imageUrl?: string;
|
|
1776
|
+
/** Accessible alt text for the banner photo */
|
|
1777
|
+
imageAlt?: string;
|
|
1778
|
+
/**
|
|
1779
|
+
* Four (or more) short value/culture cards rendered in a grid below the
|
|
1780
|
+
* banner. Ignored when `variant` is `"banner-only"`. Defaults to
|
|
1781
|
+
* `DEFAULT_CULTURE_CARDS`.
|
|
1782
|
+
*/
|
|
1783
|
+
cards?: ParallaxBannerCultureCard[];
|
|
1784
|
+
/**
|
|
1785
|
+
* Enables the subtle scroll-linked parallax on the banner photo.
|
|
1786
|
+
* Automatically disabled when the user has `prefers-reduced-motion` set.
|
|
1787
|
+
* Defaults to `true`.
|
|
1788
|
+
*/
|
|
1789
|
+
enableParallax?: boolean;
|
|
1790
|
+
/** Extra class name merged onto the root `<section>` */
|
|
1791
|
+
className?: string;
|
|
1792
|
+
}
|
|
1793
|
+
|
|
1794
|
+
declare const PARALLAX_BANNER_TEXT_CONTENT: {
|
|
1795
|
+
title: string;
|
|
1796
|
+
description: string;
|
|
1797
|
+
ctaLabel: string;
|
|
1798
|
+
};
|
|
1799
|
+
declare const DEFAULT_CULTURE_CARDS: ParallaxBannerCultureCard[];
|
|
1800
|
+
declare const ParallaxBanner: ({ variant, title, description, ctaLabel, ctaHref, onCtaClick, imageUrl, imageAlt, cards, enableParallax, className, ...props }: ParallaxBannerProps) => react_jsx_runtime.JSX.Element;
|
|
1801
|
+
|
|
1802
|
+
export { AVATAR_DATA, Accordion, type AccordionProps, ArticleHero, type ArticleHeroArticle, type ArticleHeroColumn, type ArticleHeroProps, ArticleSection, type ArticleSectionItem, type ArticleSectionProps, type ArticleSectionVariant, AvatarGrid, type AvatarGridProps, type AvatarItem, type AvatarPosition, type AwardItem, BottomSheet, type BottomSheetAction, type BottomSheetProps, Breadcrumb, type BreadcrumbItem, type BreadcrumbProps, type BreadcrumbSize, Button, type ButtonColorScheme, type ButtonIconPosition, type ButtonProps, type ButtonVariant, COL_ONE_LOGOS, COL_TWO_LOGOS, CORAL_BANNER_DERIV_SLIDES, CTABanner, type CTABannerProps, Card, type CardPrimaryStyle, type CardProps, type CardTag, type CardThumbnailType, Chip, ChipDropdown, type ChipDropdownOption, type ChipDropdownProps, type ChipProps, type ChipSize, CoralBanner, type CoralBannerButton, type CoralBannerProps, type CoralBannerSlide, DEFAULT_AWARDS, DEFAULT_CULTURE_CARDS, DayNightTransition, type DayNightTransitionProps, DotLottieInView, type DotLottieInViewProps, DownloadBadge, type DownloadBadgeColorScheme, type DownloadBadgePlatform, type DownloadBadgeProps, DownloadBanner, type DownloadBannerProps, type DownloadBannerStyle, FEATURE_AWARDS_TEXT_CONTENT, FEATURE_BLOG_CATEGORIES_TEXT_CONTENT, FEATURE_BLOG_TEXT_CONTENT, FEATURE_SCROLL_DATA, FaqAccordion, type FaqAccordionColorScheme, type FaqAccordionProps, type FaqItem, FeatureAwards, type FeatureAwardsProps, FeatureBlog, type FeatureBlogAuthor, FeatureBlogCategories, type FeatureBlogCategoriesProps, type FeatureBlogCategoryPost, type FeatureBlogCategoryTab, type FeatureBlogContentBlock, type FeatureBlogContentBlockType, FeatureBlogPage, type FeatureBlogPageProps, type FeatureBlogPost, type FeatureBlogProps, type FeatureBlogSharePlatform, FeatureBullets, type FeatureBulletsProps, type FeatureCardIconItem, type FeatureCardItem, FeatureCards, FeatureCardsIcon, type FeatureCardsIconProps, type FeatureCardsProps, FeatureScroll, type FeatureScrollItem, type FeatureScrollProps, FeatureSplit, type FeatureSplitImagePosition, type FeatureSplitProps, Footer, type FooterAiSummaryItem, type FooterAiSummaryProps, type FooterAppBadge, type FooterDerivGoProps, type FooterLinkItem, type FooterNavSection, type FooterProps, type FooterSocialLink, Header, type HeaderButtonProps, type HeaderProps, type HeaderVariant, type HelpCenterContentBlock, type HelpCenterContentBlockType, HelpCenterPage, type HelpCenterPageProps, type HelpCenterQuestionItem, HelpCentreCategories, type HelpCentreCategoriesProps, type HelpCentreCategoryItem, HelpCentreSubCategories, type HelpCentreSubCategoriesProps, type HelpCentreSubCategoryItem, Hero, type HeroButtonProps, type HeroProps, type HeroVariant, ImageBanner, type ImageBannerProps, type LanguageItem, type LeaderItem, Leaders, type LeadersProps, Link, type LinkColorScheme, type LinkProps, type LogoItem, LogoMarquee, type LogoMarqueeProps, type NavDropdownColumn, type NavDropdownFeature, type NavDropdownItem, type NavItem, Navbar, type NavbarProps, PARALLAX_BANNER_TEXT_CONTENT, Pagination, type PaginationProps, ParallaxBanner, type ParallaxBannerCultureCard, type ParallaxBannerProps, PeopleGrid, type PeopleGridProps, type PersonItem, STEPS_DATA, SearchField, type SearchFieldProps, type SearchFieldStatus, type StatItem, Stats, type StatsAward, type StatsProps, StatsSimple, type StatsSimpleProps, type StepItem, Steps, type StepsImagePosition, type StepsProps, type StickyCardItem, type StickyCardTheme, type StickyMarketCardItem, type StickyMarketCardTheme, StickyMarketCards, type StickyMarketCardsProps, StickyStackedCards, type StickyStackedCardsProps, TEXT_CONTENT, type TabItem, Table, type TableColumnDef, type TableColumnWidth, type TableProps, type TableRowData, Tabs, type TabsProps, Tag, type TagFontWeight, type TagProps, type TagSize, type TagVariant, Testimonial, type TestimonialItem, type TestimonialProps, TextField, type TextFieldProps, type TextFieldStatus, type TextFieldVariant, TextScroll, type TextScrollProps, dayNightTransitionV2Preset };
|