@deriv-web-design/ui 0.1.26 → 0.1.28
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 +41 -9
- package/components.manifest.json +17 -1
- package/dist/index.css +116 -0
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +26 -3
- package/dist/index.d.ts +26 -3
- package/dist/index.js +122 -21
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +195 -94
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1241,16 +1241,34 @@ declare const TextScroll: ({ text, className }: TextScrollProps) => react_jsx_ru
|
|
|
1241
1241
|
|
|
1242
1242
|
/** Visual colour theme for each card — matches the Figma palette. */
|
|
1243
1243
|
type StickyMarketCardTheme = "light" | "coral" | "dark";
|
|
1244
|
+
/**
|
|
1245
|
+
* Section layout variant.
|
|
1246
|
+
* - `default` — background image + title | description columns (image overlay)
|
|
1247
|
+
* - `lottie` — solid theme card with a manual-play Lottie panel + stacked copy
|
|
1248
|
+
* (matches live `option_card … is-tactical` on tactical indices)
|
|
1249
|
+
*/
|
|
1250
|
+
type StickyMarketCardsVariant = "default" | "lottie";
|
|
1244
1251
|
interface StickyMarketCardItem {
|
|
1245
1252
|
/** Card heading */
|
|
1246
1253
|
title: string;
|
|
1247
1254
|
/** Body copy below the title */
|
|
1248
1255
|
description: string;
|
|
1249
1256
|
/**
|
|
1250
|
-
* URL of the card's hero image.
|
|
1257
|
+
* URL of the card's hero image (default variant).
|
|
1258
|
+
* Ignored when the section `variant` is `"lottie"`.
|
|
1251
1259
|
* @default — placeholder used in stories when omitted
|
|
1252
1260
|
*/
|
|
1253
1261
|
imageUrl?: string;
|
|
1262
|
+
/**
|
|
1263
|
+
* `.lottie` (or animation-hosting `.json`) URL for the card media panel.
|
|
1264
|
+
* Used when the section `variant` is `"lottie"`.
|
|
1265
|
+
*/
|
|
1266
|
+
lottieSrc?: string;
|
|
1267
|
+
/**
|
|
1268
|
+
* Optional still frame shown while the Lottie is paused / loading
|
|
1269
|
+
* (`variant: "lottie"` only).
|
|
1270
|
+
*/
|
|
1271
|
+
lottiePosterUrl?: string;
|
|
1254
1272
|
/**
|
|
1255
1273
|
* Background / text colour theme.
|
|
1256
1274
|
* light → slate-75 bg + dark text
|
|
@@ -1265,13 +1283,18 @@ interface StickyMarketCardsProps extends HTMLAttributes<HTMLElement> {
|
|
|
1265
1283
|
sectionTitle: string;
|
|
1266
1284
|
/** Optional section description */
|
|
1267
1285
|
sectionDescription?: string;
|
|
1286
|
+
/**
|
|
1287
|
+
* Card layout mode.
|
|
1288
|
+
* @default "default"
|
|
1289
|
+
*/
|
|
1290
|
+
variant?: StickyMarketCardsVariant;
|
|
1268
1291
|
/**
|
|
1269
1292
|
* Ordered list of cards (first item = back of stack, last = front).
|
|
1270
1293
|
*/
|
|
1271
1294
|
items: StickyMarketCardItem[];
|
|
1272
1295
|
}
|
|
1273
1296
|
|
|
1274
|
-
declare const StickyMarketCards: ({ sectionTitle, sectionDescription, items, className, ...props }: StickyMarketCardsProps) => react_jsx_runtime.JSX.Element;
|
|
1297
|
+
declare const StickyMarketCards: ({ sectionTitle, sectionDescription, variant, items, className, ...props }: StickyMarketCardsProps) => react_jsx_runtime.JSX.Element;
|
|
1275
1298
|
|
|
1276
1299
|
/** Column width variant */
|
|
1277
1300
|
type TableColumnWidth = "main" | "normal" | "big";
|
|
@@ -2826,4 +2849,4 @@ interface AffiliatesSliderProps extends HTMLAttributes<HTMLElement> {
|
|
|
2826
2849
|
|
|
2827
2850
|
declare const AffiliatesSlider: ({ title, description, min, max, step, defaultValue, value, onValueChange, referralsLabel, incomeLabel, incomePerReferral, currencySymbol, tickValues, disclaimer, disclaimerIconSrc, disclaimerIconAlt, sliderLabel, className, ...props }: AffiliatesSliderProps) => react_jsx_runtime.JSX.Element;
|
|
2828
2851
|
|
|
2829
|
-
export { AVATAR_DATA, Accordion, type AccordionProps, AffiliatesSlider, type AffiliatesSliderProps, 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, type CalculationToken, 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, CountryLinkGrid, type CountryLinkGridHeadingLevel, type CountryLinkGridItem, type CountryLinkGridProps, DEFAULT_AWARDS, DEFAULT_CULTURE_CARDS, DEFAULT_EXCHANGE_RATE_WS_URL, DEFAULT_SYMBOLS_ENDPOINT, DayNightTransition, type DayNightTransitionProps, DocumentChips, type DocumentChipsDocument, type DocumentChipsGroup, type DocumentChipsHeadingLevel, type DocumentChipsLanguageLink, type DocumentChipsProps, type DocumentChipsVariant, DotLottieInView, type DotLottieInViewProps, DownloadBadge, type DownloadBadgeColorScheme, type DownloadBadgePlatform, type DownloadBadgeProps, DownloadBanner, type DownloadBannerProps, type DownloadBannerStyle, DynamicTable, type DynamicTableColumnDef, type DynamicTableProps, type DynamicTableRowData, type DynamicTableVariant, EntityInfoSection, type EntityInfoSectionHeadingLevel, type EntityInfoSectionLink, type EntityInfoSectionProps, FEATURE_AWARDS_TEXT_CONTENT, FEATURE_BLOG_CATEGORIES_TEXT_CONTENT, FEATURE_BLOG_TEXT_CONTENT, FEATURE_OFFICES_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, type FeatureOffice, type FeatureOfficeRegion, FeatureOffices, type FeatureOfficesProps, 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, type FormulaBlock, 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, IMAGE_BANNER_CHIPS_DEFAULT_IMAGE, ImageBanner, type ImageBannerProps, type ImageBannerVariant, type LanguageItem, LanguageSelectModal, type LanguageSelectModalOption, type LanguageSelectModalProps, type LeaderItem, Leaders, type LeadersProps, Link, type LinkColorScheme, LinkModal, type LinkModalProps, type LinkProps, type LogoItem, LogoMarquee, type LogoMarqueeProps, MasterPartner, type MasterPartnerNote, type MasterPartnerProps, type MasterPartnerStep, type NavDropdownColumn, type NavDropdownFeature, type NavDropdownItem, type NavItem, Navbar, type NavbarProps, OPTIONS_TYPES_ACCUMULATOR_CONTENT, OPTIONS_TYPES_DIGITAL_CONTENT, OPTIONS_TYPES_EU_MULTIPLIERS_CONTENT, OPTIONS_TYPES_MULTIPLIERS_CONTENT, OPTIONS_TYPES_PLACEHOLDER_ITEMS, OPTIONS_TYPES_TURBO_CONTENT, OPTIONS_TYPES_VANILLA_CONTENT, OptionsTypes, type OptionsTypesAnimation, type OptionsTypesIcon, type OptionsTypesItem, type OptionsTypesMetaItem, type OptionsTypesProps, type OptionsTypesVariant, PARALLAX_BANNER_TEXT_CONTENT, Pagination, type PaginationProps, ParallaxBanner, type ParallaxBannerCultureCard, type ParallaxBannerProps, type PartnerPayoutItem, PartnersPayout, type PartnersPayoutProps, PeopleGrid, type PeopleGridProps, type PersonItem, RESOURCE_BANNER_DERIV_CONTENT, ResourceBanner, type ResourceBannerHeadingLevel, type ResourceBannerLink, type ResourceBannerProps, 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, type SwapCalculationMode, 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, type TierAccent, type TierItem, Tiers, type TiersProps, TradingCalculator, TradingCalculatorHowTo, type TradingCalculatorHowToProps, type TradingCalculatorHowToVariant, type TradingCalculatorProps, type TradingCalculatorResults, type TradingCalculatorVariant, type TradingSymbolSpec, dayNightTransitionV2Preset, isLottieSrc };
|
|
2852
|
+
export { AVATAR_DATA, Accordion, type AccordionProps, AffiliatesSlider, type AffiliatesSliderProps, 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, type CalculationToken, 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, CountryLinkGrid, type CountryLinkGridHeadingLevel, type CountryLinkGridItem, type CountryLinkGridProps, DEFAULT_AWARDS, DEFAULT_CULTURE_CARDS, DEFAULT_EXCHANGE_RATE_WS_URL, DEFAULT_SYMBOLS_ENDPOINT, DayNightTransition, type DayNightTransitionProps, DocumentChips, type DocumentChipsDocument, type DocumentChipsGroup, type DocumentChipsHeadingLevel, type DocumentChipsLanguageLink, type DocumentChipsProps, type DocumentChipsVariant, DotLottieInView, type DotLottieInViewProps, DownloadBadge, type DownloadBadgeColorScheme, type DownloadBadgePlatform, type DownloadBadgeProps, DownloadBanner, type DownloadBannerProps, type DownloadBannerStyle, DynamicTable, type DynamicTableColumnDef, type DynamicTableProps, type DynamicTableRowData, type DynamicTableVariant, EntityInfoSection, type EntityInfoSectionHeadingLevel, type EntityInfoSectionLink, type EntityInfoSectionProps, FEATURE_AWARDS_TEXT_CONTENT, FEATURE_BLOG_CATEGORIES_TEXT_CONTENT, FEATURE_BLOG_TEXT_CONTENT, FEATURE_OFFICES_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, type FeatureOffice, type FeatureOfficeRegion, FeatureOffices, type FeatureOfficesProps, 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, type FormulaBlock, 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, IMAGE_BANNER_CHIPS_DEFAULT_IMAGE, ImageBanner, type ImageBannerProps, type ImageBannerVariant, type LanguageItem, LanguageSelectModal, type LanguageSelectModalOption, type LanguageSelectModalProps, type LeaderItem, Leaders, type LeadersProps, Link, type LinkColorScheme, LinkModal, type LinkModalProps, type LinkProps, type LogoItem, LogoMarquee, type LogoMarqueeProps, MasterPartner, type MasterPartnerNote, type MasterPartnerProps, type MasterPartnerStep, type NavDropdownColumn, type NavDropdownFeature, type NavDropdownItem, type NavItem, Navbar, type NavbarProps, OPTIONS_TYPES_ACCUMULATOR_CONTENT, OPTIONS_TYPES_DIGITAL_CONTENT, OPTIONS_TYPES_EU_MULTIPLIERS_CONTENT, OPTIONS_TYPES_MULTIPLIERS_CONTENT, OPTIONS_TYPES_PLACEHOLDER_ITEMS, OPTIONS_TYPES_TURBO_CONTENT, OPTIONS_TYPES_VANILLA_CONTENT, OptionsTypes, type OptionsTypesAnimation, type OptionsTypesIcon, type OptionsTypesItem, type OptionsTypesMetaItem, type OptionsTypesProps, type OptionsTypesVariant, PARALLAX_BANNER_TEXT_CONTENT, Pagination, type PaginationProps, ParallaxBanner, type ParallaxBannerCultureCard, type ParallaxBannerProps, type PartnerPayoutItem, PartnersPayout, type PartnersPayoutProps, PeopleGrid, type PeopleGridProps, type PersonItem, RESOURCE_BANNER_DERIV_CONTENT, ResourceBanner, type ResourceBannerHeadingLevel, type ResourceBannerLink, type ResourceBannerProps, 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, type StickyMarketCardsVariant, StickyStackedCards, type StickyStackedCardsProps, type SwapCalculationMode, 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, type TierAccent, type TierItem, Tiers, type TiersProps, TradingCalculator, TradingCalculatorHowTo, type TradingCalculatorHowToProps, type TradingCalculatorHowToVariant, type TradingCalculatorProps, type TradingCalculatorResults, type TradingCalculatorVariant, type TradingSymbolSpec, dayNightTransitionV2Preset, isLottieSrc };
|
package/dist/index.d.ts
CHANGED
|
@@ -1241,16 +1241,34 @@ declare const TextScroll: ({ text, className }: TextScrollProps) => react_jsx_ru
|
|
|
1241
1241
|
|
|
1242
1242
|
/** Visual colour theme for each card — matches the Figma palette. */
|
|
1243
1243
|
type StickyMarketCardTheme = "light" | "coral" | "dark";
|
|
1244
|
+
/**
|
|
1245
|
+
* Section layout variant.
|
|
1246
|
+
* - `default` — background image + title | description columns (image overlay)
|
|
1247
|
+
* - `lottie` — solid theme card with a manual-play Lottie panel + stacked copy
|
|
1248
|
+
* (matches live `option_card … is-tactical` on tactical indices)
|
|
1249
|
+
*/
|
|
1250
|
+
type StickyMarketCardsVariant = "default" | "lottie";
|
|
1244
1251
|
interface StickyMarketCardItem {
|
|
1245
1252
|
/** Card heading */
|
|
1246
1253
|
title: string;
|
|
1247
1254
|
/** Body copy below the title */
|
|
1248
1255
|
description: string;
|
|
1249
1256
|
/**
|
|
1250
|
-
* URL of the card's hero image.
|
|
1257
|
+
* URL of the card's hero image (default variant).
|
|
1258
|
+
* Ignored when the section `variant` is `"lottie"`.
|
|
1251
1259
|
* @default — placeholder used in stories when omitted
|
|
1252
1260
|
*/
|
|
1253
1261
|
imageUrl?: string;
|
|
1262
|
+
/**
|
|
1263
|
+
* `.lottie` (or animation-hosting `.json`) URL for the card media panel.
|
|
1264
|
+
* Used when the section `variant` is `"lottie"`.
|
|
1265
|
+
*/
|
|
1266
|
+
lottieSrc?: string;
|
|
1267
|
+
/**
|
|
1268
|
+
* Optional still frame shown while the Lottie is paused / loading
|
|
1269
|
+
* (`variant: "lottie"` only).
|
|
1270
|
+
*/
|
|
1271
|
+
lottiePosterUrl?: string;
|
|
1254
1272
|
/**
|
|
1255
1273
|
* Background / text colour theme.
|
|
1256
1274
|
* light → slate-75 bg + dark text
|
|
@@ -1265,13 +1283,18 @@ interface StickyMarketCardsProps extends HTMLAttributes<HTMLElement> {
|
|
|
1265
1283
|
sectionTitle: string;
|
|
1266
1284
|
/** Optional section description */
|
|
1267
1285
|
sectionDescription?: string;
|
|
1286
|
+
/**
|
|
1287
|
+
* Card layout mode.
|
|
1288
|
+
* @default "default"
|
|
1289
|
+
*/
|
|
1290
|
+
variant?: StickyMarketCardsVariant;
|
|
1268
1291
|
/**
|
|
1269
1292
|
* Ordered list of cards (first item = back of stack, last = front).
|
|
1270
1293
|
*/
|
|
1271
1294
|
items: StickyMarketCardItem[];
|
|
1272
1295
|
}
|
|
1273
1296
|
|
|
1274
|
-
declare const StickyMarketCards: ({ sectionTitle, sectionDescription, items, className, ...props }: StickyMarketCardsProps) => react_jsx_runtime.JSX.Element;
|
|
1297
|
+
declare const StickyMarketCards: ({ sectionTitle, sectionDescription, variant, items, className, ...props }: StickyMarketCardsProps) => react_jsx_runtime.JSX.Element;
|
|
1275
1298
|
|
|
1276
1299
|
/** Column width variant */
|
|
1277
1300
|
type TableColumnWidth = "main" | "normal" | "big";
|
|
@@ -2826,4 +2849,4 @@ interface AffiliatesSliderProps extends HTMLAttributes<HTMLElement> {
|
|
|
2826
2849
|
|
|
2827
2850
|
declare const AffiliatesSlider: ({ title, description, min, max, step, defaultValue, value, onValueChange, referralsLabel, incomeLabel, incomePerReferral, currencySymbol, tickValues, disclaimer, disclaimerIconSrc, disclaimerIconAlt, sliderLabel, className, ...props }: AffiliatesSliderProps) => react_jsx_runtime.JSX.Element;
|
|
2828
2851
|
|
|
2829
|
-
export { AVATAR_DATA, Accordion, type AccordionProps, AffiliatesSlider, type AffiliatesSliderProps, 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, type CalculationToken, 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, CountryLinkGrid, type CountryLinkGridHeadingLevel, type CountryLinkGridItem, type CountryLinkGridProps, DEFAULT_AWARDS, DEFAULT_CULTURE_CARDS, DEFAULT_EXCHANGE_RATE_WS_URL, DEFAULT_SYMBOLS_ENDPOINT, DayNightTransition, type DayNightTransitionProps, DocumentChips, type DocumentChipsDocument, type DocumentChipsGroup, type DocumentChipsHeadingLevel, type DocumentChipsLanguageLink, type DocumentChipsProps, type DocumentChipsVariant, DotLottieInView, type DotLottieInViewProps, DownloadBadge, type DownloadBadgeColorScheme, type DownloadBadgePlatform, type DownloadBadgeProps, DownloadBanner, type DownloadBannerProps, type DownloadBannerStyle, DynamicTable, type DynamicTableColumnDef, type DynamicTableProps, type DynamicTableRowData, type DynamicTableVariant, EntityInfoSection, type EntityInfoSectionHeadingLevel, type EntityInfoSectionLink, type EntityInfoSectionProps, FEATURE_AWARDS_TEXT_CONTENT, FEATURE_BLOG_CATEGORIES_TEXT_CONTENT, FEATURE_BLOG_TEXT_CONTENT, FEATURE_OFFICES_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, type FeatureOffice, type FeatureOfficeRegion, FeatureOffices, type FeatureOfficesProps, 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, type FormulaBlock, 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, IMAGE_BANNER_CHIPS_DEFAULT_IMAGE, ImageBanner, type ImageBannerProps, type ImageBannerVariant, type LanguageItem, LanguageSelectModal, type LanguageSelectModalOption, type LanguageSelectModalProps, type LeaderItem, Leaders, type LeadersProps, Link, type LinkColorScheme, LinkModal, type LinkModalProps, type LinkProps, type LogoItem, LogoMarquee, type LogoMarqueeProps, MasterPartner, type MasterPartnerNote, type MasterPartnerProps, type MasterPartnerStep, type NavDropdownColumn, type NavDropdownFeature, type NavDropdownItem, type NavItem, Navbar, type NavbarProps, OPTIONS_TYPES_ACCUMULATOR_CONTENT, OPTIONS_TYPES_DIGITAL_CONTENT, OPTIONS_TYPES_EU_MULTIPLIERS_CONTENT, OPTIONS_TYPES_MULTIPLIERS_CONTENT, OPTIONS_TYPES_PLACEHOLDER_ITEMS, OPTIONS_TYPES_TURBO_CONTENT, OPTIONS_TYPES_VANILLA_CONTENT, OptionsTypes, type OptionsTypesAnimation, type OptionsTypesIcon, type OptionsTypesItem, type OptionsTypesMetaItem, type OptionsTypesProps, type OptionsTypesVariant, PARALLAX_BANNER_TEXT_CONTENT, Pagination, type PaginationProps, ParallaxBanner, type ParallaxBannerCultureCard, type ParallaxBannerProps, type PartnerPayoutItem, PartnersPayout, type PartnersPayoutProps, PeopleGrid, type PeopleGridProps, type PersonItem, RESOURCE_BANNER_DERIV_CONTENT, ResourceBanner, type ResourceBannerHeadingLevel, type ResourceBannerLink, type ResourceBannerProps, 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, type SwapCalculationMode, 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, type TierAccent, type TierItem, Tiers, type TiersProps, TradingCalculator, TradingCalculatorHowTo, type TradingCalculatorHowToProps, type TradingCalculatorHowToVariant, type TradingCalculatorProps, type TradingCalculatorResults, type TradingCalculatorVariant, type TradingSymbolSpec, dayNightTransitionV2Preset, isLottieSrc };
|
|
2852
|
+
export { AVATAR_DATA, Accordion, type AccordionProps, AffiliatesSlider, type AffiliatesSliderProps, 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, type CalculationToken, 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, CountryLinkGrid, type CountryLinkGridHeadingLevel, type CountryLinkGridItem, type CountryLinkGridProps, DEFAULT_AWARDS, DEFAULT_CULTURE_CARDS, DEFAULT_EXCHANGE_RATE_WS_URL, DEFAULT_SYMBOLS_ENDPOINT, DayNightTransition, type DayNightTransitionProps, DocumentChips, type DocumentChipsDocument, type DocumentChipsGroup, type DocumentChipsHeadingLevel, type DocumentChipsLanguageLink, type DocumentChipsProps, type DocumentChipsVariant, DotLottieInView, type DotLottieInViewProps, DownloadBadge, type DownloadBadgeColorScheme, type DownloadBadgePlatform, type DownloadBadgeProps, DownloadBanner, type DownloadBannerProps, type DownloadBannerStyle, DynamicTable, type DynamicTableColumnDef, type DynamicTableProps, type DynamicTableRowData, type DynamicTableVariant, EntityInfoSection, type EntityInfoSectionHeadingLevel, type EntityInfoSectionLink, type EntityInfoSectionProps, FEATURE_AWARDS_TEXT_CONTENT, FEATURE_BLOG_CATEGORIES_TEXT_CONTENT, FEATURE_BLOG_TEXT_CONTENT, FEATURE_OFFICES_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, type FeatureOffice, type FeatureOfficeRegion, FeatureOffices, type FeatureOfficesProps, 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, type FormulaBlock, 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, IMAGE_BANNER_CHIPS_DEFAULT_IMAGE, ImageBanner, type ImageBannerProps, type ImageBannerVariant, type LanguageItem, LanguageSelectModal, type LanguageSelectModalOption, type LanguageSelectModalProps, type LeaderItem, Leaders, type LeadersProps, Link, type LinkColorScheme, LinkModal, type LinkModalProps, type LinkProps, type LogoItem, LogoMarquee, type LogoMarqueeProps, MasterPartner, type MasterPartnerNote, type MasterPartnerProps, type MasterPartnerStep, type NavDropdownColumn, type NavDropdownFeature, type NavDropdownItem, type NavItem, Navbar, type NavbarProps, OPTIONS_TYPES_ACCUMULATOR_CONTENT, OPTIONS_TYPES_DIGITAL_CONTENT, OPTIONS_TYPES_EU_MULTIPLIERS_CONTENT, OPTIONS_TYPES_MULTIPLIERS_CONTENT, OPTIONS_TYPES_PLACEHOLDER_ITEMS, OPTIONS_TYPES_TURBO_CONTENT, OPTIONS_TYPES_VANILLA_CONTENT, OptionsTypes, type OptionsTypesAnimation, type OptionsTypesIcon, type OptionsTypesItem, type OptionsTypesMetaItem, type OptionsTypesProps, type OptionsTypesVariant, PARALLAX_BANNER_TEXT_CONTENT, Pagination, type PaginationProps, ParallaxBanner, type ParallaxBannerCultureCard, type ParallaxBannerProps, type PartnerPayoutItem, PartnersPayout, type PartnersPayoutProps, PeopleGrid, type PeopleGridProps, type PersonItem, RESOURCE_BANNER_DERIV_CONTENT, ResourceBanner, type ResourceBannerHeadingLevel, type ResourceBannerLink, type ResourceBannerProps, 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, type StickyMarketCardsVariant, StickyStackedCards, type StickyStackedCardsProps, type SwapCalculationMode, 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, type TierAccent, type TierItem, Tiers, type TiersProps, TradingCalculator, TradingCalculatorHowTo, type TradingCalculatorHowToProps, type TradingCalculatorHowToVariant, type TradingCalculatorProps, type TradingCalculatorResults, type TradingCalculatorVariant, type TradingSymbolSpec, dayNightTransitionV2Preset, isLottieSrc };
|
package/dist/index.js
CHANGED
|
@@ -1291,7 +1291,7 @@ var FaqAccordion = ({
|
|
|
1291
1291
|
open: openIndex === index,
|
|
1292
1292
|
onToggle: handleToggle(index),
|
|
1293
1293
|
showTopDivider: false,
|
|
1294
|
-
showBottomDivider:
|
|
1294
|
+
showBottomDivider: index < items.length - 1,
|
|
1295
1295
|
children: item.answer
|
|
1296
1296
|
},
|
|
1297
1297
|
`${item.question}-${index}`
|
|
@@ -5053,15 +5053,89 @@ var TextScroll = ({ text, className }) => {
|
|
|
5053
5053
|
var import_react21 = require("react");
|
|
5054
5054
|
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
5055
5055
|
var PLACEHOLDER_IMAGE3 = "https://cdn.prod.website-files.com/68da5c86c91c54f39c86c28a/69b9309379ac08e59ca8210a_1f3f555da9a5cbb13a6fe1bf0d5fe1b6_placeholder-image.webp";
|
|
5056
|
+
function safeHref(value) {
|
|
5057
|
+
if (!value) return null;
|
|
5058
|
+
if (value.startsWith("/") && !value.startsWith("//")) return value;
|
|
5059
|
+
try {
|
|
5060
|
+
const url = new URL(value);
|
|
5061
|
+
return url.protocol === "https:" ? value : null;
|
|
5062
|
+
} catch {
|
|
5063
|
+
return null;
|
|
5064
|
+
}
|
|
5065
|
+
}
|
|
5066
|
+
function safeLottieSrc(value) {
|
|
5067
|
+
const href = safeHref(value);
|
|
5068
|
+
if (!href || !isLottieSrc(href)) return null;
|
|
5069
|
+
return href;
|
|
5070
|
+
}
|
|
5071
|
+
function PlaybackGlyph({ playing }) {
|
|
5072
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("svg", { className: "smc__control-icon", viewBox: "0 0 64 64", "aria-hidden": "true", children: [
|
|
5073
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("circle", { className: "smc__control-disc", cx: "32", cy: "32", r: "32" }),
|
|
5074
|
+
playing ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_jsx_runtime39.Fragment, { children: [
|
|
5075
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("rect", { className: "smc__control-glyph", x: "23", y: "21", width: "6", height: "22", rx: "2" }),
|
|
5076
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("rect", { className: "smc__control-glyph", x: "35", y: "21", width: "6", height: "22", rx: "2" })
|
|
5077
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5078
|
+
"path",
|
|
5079
|
+
{
|
|
5080
|
+
className: "smc__control-glyph",
|
|
5081
|
+
d: "M26.5058 19.9527L42.7058 29.8527C43.4933 30.359 43.9996 31.259 43.9996 32.159C43.9996 33.1152 43.4933 34.0152 42.7058 34.4652L26.5058 44.3652C25.6621 44.8715 24.5933 44.9277 23.7496 44.4215C22.9058 43.9715 22.3996 43.0715 22.3996 42.059V22.259C22.3996 21.3027 22.9058 20.4027 23.7496 19.9527C24.5933 19.4465 25.6621 19.4465 26.5058 19.9527Z"
|
|
5082
|
+
}
|
|
5083
|
+
)
|
|
5084
|
+
] });
|
|
5085
|
+
}
|
|
5086
|
+
function LottiePanel({ item, index, playing, onToggle }) {
|
|
5087
|
+
const src = safeLottieSrc(item.lottieSrc);
|
|
5088
|
+
const posterSrc = safeHref(item.lottiePosterUrl);
|
|
5089
|
+
const controlId = `smc-lottie-${index}-${item.title}`.replace(/[^a-zA-Z0-9_-]/g, "-").slice(0, 80);
|
|
5090
|
+
return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "smc__lottie", children: [
|
|
5091
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { id: controlId, className: "smc__lottie-media", "aria-hidden": "true", children: src ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5092
|
+
DotLottieInView,
|
|
5093
|
+
{
|
|
5094
|
+
src,
|
|
5095
|
+
enabled: playing,
|
|
5096
|
+
loop: true,
|
|
5097
|
+
className: "smc__lottie-player",
|
|
5098
|
+
style: { alignItems: "stretch", justifyContent: "stretch" },
|
|
5099
|
+
poster: posterSrc ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("img", { src: posterSrc, alt: "", loading: "lazy", decoding: "async" }) : void 0
|
|
5100
|
+
}
|
|
5101
|
+
) : null }),
|
|
5102
|
+
posterSrc && !playing ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5103
|
+
"img",
|
|
5104
|
+
{
|
|
5105
|
+
className: "smc__lottie-poster",
|
|
5106
|
+
src: posterSrc,
|
|
5107
|
+
alt: "",
|
|
5108
|
+
"aria-hidden": "true",
|
|
5109
|
+
loading: "lazy",
|
|
5110
|
+
decoding: "async"
|
|
5111
|
+
}
|
|
5112
|
+
) : null,
|
|
5113
|
+
src ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5114
|
+
"button",
|
|
5115
|
+
{
|
|
5116
|
+
type: "button",
|
|
5117
|
+
className: `smc__playback-toggle${playing ? " smc__playback-toggle--playing" : ""}`,
|
|
5118
|
+
"aria-controls": controlId,
|
|
5119
|
+
"aria-pressed": playing,
|
|
5120
|
+
"aria-label": `${playing ? "Pause" : "Play"} ${item.title} animation`,
|
|
5121
|
+
onClick: onToggle,
|
|
5122
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(PlaybackGlyph, { playing })
|
|
5123
|
+
}
|
|
5124
|
+
) : null
|
|
5125
|
+
] });
|
|
5126
|
+
}
|
|
5056
5127
|
var StickyMarketCards = ({
|
|
5057
5128
|
sectionTitle,
|
|
5058
5129
|
sectionDescription,
|
|
5130
|
+
variant = "default",
|
|
5059
5131
|
items,
|
|
5060
5132
|
className,
|
|
5061
5133
|
...props
|
|
5062
5134
|
}) => {
|
|
5063
5135
|
const cardRefs = (0, import_react21.useRef)([]);
|
|
5064
5136
|
const cardInnerRefs = (0, import_react21.useRef)([]);
|
|
5137
|
+
const [playing, setPlaying] = (0, import_react21.useState)({});
|
|
5138
|
+
const isLottie = variant === "lottie";
|
|
5065
5139
|
(0, import_react21.useEffect)(() => {
|
|
5066
5140
|
if (typeof window === "undefined") return;
|
|
5067
5141
|
let rafId = 0;
|
|
@@ -5128,14 +5202,14 @@ var StickyMarketCards = ({
|
|
|
5128
5202
|
return () => {
|
|
5129
5203
|
window.removeEventListener("resize", syncHeights);
|
|
5130
5204
|
};
|
|
5131
|
-
}, [items.length]);
|
|
5205
|
+
}, [items.length, variant]);
|
|
5132
5206
|
const n = items.length;
|
|
5133
5207
|
const maxStack = 4;
|
|
5134
5208
|
const baseIndex = Math.max(0, n - maxStack);
|
|
5135
5209
|
return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5136
5210
|
"section",
|
|
5137
5211
|
{
|
|
5138
|
-
className: ["smc", className].filter(Boolean).join(" "),
|
|
5212
|
+
className: ["smc", isLottie ? "smc--lottie" : null, className].filter(Boolean).join(" "),
|
|
5139
5213
|
...props,
|
|
5140
5214
|
children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "smc__inner", children: [
|
|
5141
5215
|
/* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "smc__header-wrap", children: [
|
|
@@ -5164,10 +5238,11 @@ var StickyMarketCards = ({
|
|
|
5164
5238
|
},
|
|
5165
5239
|
className: [
|
|
5166
5240
|
"smc__card-inner",
|
|
5167
|
-
`smc__card-inner--${theme}
|
|
5168
|
-
|
|
5241
|
+
`smc__card-inner--${theme}`,
|
|
5242
|
+
isLottie ? "smc__card-inner--lottie" : null
|
|
5243
|
+
].filter(Boolean).join(" "),
|
|
5169
5244
|
children: [
|
|
5170
|
-
/* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "smc__card-bg", children: [
|
|
5245
|
+
!isLottie ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "smc__card-bg", children: [
|
|
5171
5246
|
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5172
5247
|
"img",
|
|
5173
5248
|
{
|
|
@@ -5186,11 +5261,37 @@ var StickyMarketCards = ({
|
|
|
5186
5261
|
].join(" ")
|
|
5187
5262
|
}
|
|
5188
5263
|
)
|
|
5189
|
-
] }),
|
|
5190
|
-
/* @__PURE__ */ (0, import_jsx_runtime39.
|
|
5191
|
-
|
|
5192
|
-
|
|
5193
|
-
|
|
5264
|
+
] }) : null,
|
|
5265
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5266
|
+
"div",
|
|
5267
|
+
{
|
|
5268
|
+
className: [
|
|
5269
|
+
"smc__card-content",
|
|
5270
|
+
isLottie ? "smc__card-content--lottie" : null
|
|
5271
|
+
].filter(Boolean).join(" "),
|
|
5272
|
+
children: isLottie ? /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_jsx_runtime39.Fragment, { children: [
|
|
5273
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
|
|
5274
|
+
LottiePanel,
|
|
5275
|
+
{
|
|
5276
|
+
item,
|
|
5277
|
+
index: i,
|
|
5278
|
+
playing: Boolean(playing[i]),
|
|
5279
|
+
onToggle: () => setPlaying((prev) => ({
|
|
5280
|
+
...prev,
|
|
5281
|
+
[i]: !prev[i]
|
|
5282
|
+
}))
|
|
5283
|
+
}
|
|
5284
|
+
),
|
|
5285
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("div", { className: "smc__card-text", children: [
|
|
5286
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("h3", { className: "smc__card-title", children: item.title }),
|
|
5287
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("p", { className: "smc__card-desc", children: item.description })
|
|
5288
|
+
] })
|
|
5289
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(import_jsx_runtime39.Fragment, { children: [
|
|
5290
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "smc__card-title-wrap", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("h3", { className: "smc__card-title", children: item.title }) }),
|
|
5291
|
+
/* @__PURE__ */ (0, import_jsx_runtime39.jsx)("div", { className: "smc__card-desc-wrap", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("p", { className: "smc__card-desc", children: item.description }) })
|
|
5292
|
+
] })
|
|
5293
|
+
}
|
|
5294
|
+
)
|
|
5194
5295
|
]
|
|
5195
5296
|
}
|
|
5196
5297
|
)
|
|
@@ -8600,7 +8701,7 @@ var OPTIONS_TYPES_PLACEHOLDER_ITEMS = [
|
|
|
8600
8701
|
platforms: [{ label: "Platform" }]
|
|
8601
8702
|
}
|
|
8602
8703
|
];
|
|
8603
|
-
function
|
|
8704
|
+
function safeHref2(value) {
|
|
8604
8705
|
if (!value) return null;
|
|
8605
8706
|
if (value.startsWith("/") && !value.startsWith("//")) return value;
|
|
8606
8707
|
try {
|
|
@@ -8610,8 +8711,8 @@ function safeHref(value) {
|
|
|
8610
8711
|
return null;
|
|
8611
8712
|
}
|
|
8612
8713
|
}
|
|
8613
|
-
function
|
|
8614
|
-
const href =
|
|
8714
|
+
function safeLottieSrc2(value) {
|
|
8715
|
+
const href = safeHref2(value);
|
|
8615
8716
|
if (!href) return null;
|
|
8616
8717
|
try {
|
|
8617
8718
|
const pathname = href.startsWith("/") ? href : new URL(href).pathname;
|
|
@@ -8643,7 +8744,7 @@ var iconPaths = {
|
|
|
8643
8744
|
]
|
|
8644
8745
|
};
|
|
8645
8746
|
function MetaIcon({ icon, iconUrl }) {
|
|
8646
|
-
const imageSrc =
|
|
8747
|
+
const imageSrc = safeHref2(iconUrl);
|
|
8647
8748
|
if (imageSrc) {
|
|
8648
8749
|
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
8649
8750
|
"img",
|
|
@@ -8667,7 +8768,7 @@ function MetaIcon({ icon, iconUrl }) {
|
|
|
8667
8768
|
}
|
|
8668
8769
|
function MetaList({ items = [] }) {
|
|
8669
8770
|
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("ul", { className: "ot__meta-list", children: items.map((item, index) => {
|
|
8670
|
-
const href =
|
|
8771
|
+
const href = safeHref2(item.href);
|
|
8671
8772
|
const content = /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(import_jsx_runtime63.Fragment, { children: [
|
|
8672
8773
|
/* @__PURE__ */ (0, import_jsx_runtime63.jsx)(MetaIcon, { icon: item.icon, iconUrl: item.iconUrl }),
|
|
8673
8774
|
/* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { children: item.label })
|
|
@@ -8675,7 +8776,7 @@ function MetaList({ items = [] }) {
|
|
|
8675
8776
|
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("li", { children: href ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("a", { href, children: content }) : /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { children: content }) }, `${item.label}-${index}`);
|
|
8676
8777
|
}) });
|
|
8677
8778
|
}
|
|
8678
|
-
function
|
|
8779
|
+
function PlaybackGlyph2({ playing }) {
|
|
8679
8780
|
return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("svg", { className: "ot__control-icon", viewBox: "0 0 64 64", "aria-hidden": "true", children: [
|
|
8680
8781
|
/* @__PURE__ */ (0, import_jsx_runtime63.jsx)("circle", { className: "ot__control-disc", cx: "32", cy: "32", r: "32" }),
|
|
8681
8782
|
playing ? /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(import_jsx_runtime63.Fragment, { children: [
|
|
@@ -8696,8 +8797,8 @@ function AnimationCard({
|
|
|
8696
8797
|
playing,
|
|
8697
8798
|
onToggle
|
|
8698
8799
|
}) {
|
|
8699
|
-
const src =
|
|
8700
|
-
const posterSrc =
|
|
8800
|
+
const src = safeLottieSrc2(animation.src);
|
|
8801
|
+
const posterSrc = safeHref2(animation.posterUrl);
|
|
8701
8802
|
const controlId = `ot-animation-${itemId}-${animation.id ?? animation.label}`.replace(/[^a-zA-Z0-9_-]/g, "-");
|
|
8702
8803
|
return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "ot__animation-card", children: [
|
|
8703
8804
|
/* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { id: controlId, className: "ot__animation-media", "aria-hidden": "true", children: src ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
@@ -8729,7 +8830,7 @@ function AnimationCard({
|
|
|
8729
8830
|
"aria-pressed": playing,
|
|
8730
8831
|
"aria-label": `${playing ? "Pause" : "Play"} ${animation.label} animation`,
|
|
8731
8832
|
onClick: onToggle,
|
|
8732
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
8833
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(PlaybackGlyph2, { playing })
|
|
8733
8834
|
}
|
|
8734
8835
|
) : null
|
|
8735
8836
|
] });
|
|
@@ -8858,7 +8959,7 @@ function TogglePanel({
|
|
|
8858
8959
|
onKeyDown: onSwitchKeyDown,
|
|
8859
8960
|
children: animations.map((animation, index) => {
|
|
8860
8961
|
const isActive = index === safeIndex;
|
|
8861
|
-
const iconUrl =
|
|
8962
|
+
const iconUrl = safeHref2(animation.iconUrl);
|
|
8862
8963
|
return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
|
|
8863
8964
|
"button",
|
|
8864
8965
|
{
|