@almadar/ui 2.24.8 → 2.24.9

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.
@@ -0,0 +1,29 @@
1
+ import React from 'react';
2
+ export type GraphicAnimation = 'draw' | 'fill' | 'pulse' | 'morph';
3
+ export interface AnimatedGraphicProps extends React.HTMLAttributes<HTMLDivElement> {
4
+ /** URL to an SVG file. Fetched and inlined to enable stroke/fill animations. */
5
+ src?: string;
6
+ /** Inline SVG string. Takes precedence over src if both provided. */
7
+ svgContent?: string;
8
+ /** Animation type applied to SVG paths/shapes */
9
+ animation?: GraphicAnimation;
10
+ /** Whether to run the animation (default: false). Controlled externally or via AnimatedReveal. */
11
+ animate?: boolean;
12
+ /** Animation duration in ms (default: 1200) */
13
+ duration?: number;
14
+ /** Delay before animation starts in ms (default: 0) */
15
+ delay?: number;
16
+ /** Easing function (default: cubic-bezier(0.16, 1, 0.3, 1)) */
17
+ easing?: string;
18
+ /** Width of the graphic container */
19
+ width?: string | number;
20
+ /** Height of the graphic container */
21
+ height?: string | number;
22
+ /** Stroke color override for SVG paths */
23
+ strokeColor?: string;
24
+ /** Fill color for the 'fill' animation end state */
25
+ fillColor?: string;
26
+ /** Alt text for accessibility */
27
+ alt?: string;
28
+ }
29
+ export declare const AnimatedGraphic: React.ForwardRefExoticComponent<AnimatedGraphicProps & React.RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ export type RevealTrigger = 'scroll' | 'hover' | 'manual';
3
+ export type RevealAnimation = 'fade-up' | 'fade-down' | 'fade-in' | 'fade-left' | 'fade-right' | 'scale' | 'scale-up' | 'none';
4
+ export interface AnimatedRevealProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'children'> {
5
+ /** What triggers the animation */
6
+ trigger?: RevealTrigger;
7
+ /** Built-in animation preset */
8
+ animation?: RevealAnimation;
9
+ /** Animation duration in ms (default: 600) */
10
+ duration?: number;
11
+ /** Delay before animation starts in ms (default: 0) */
12
+ delay?: number;
13
+ /** How much of the element must be visible before triggering, 0-1 (default: 0.15) */
14
+ threshold?: number;
15
+ /** Animate only the first time the element enters the viewport (default: true) */
16
+ once?: boolean;
17
+ /** Manual control: when trigger='manual', set this to true to animate */
18
+ animate?: boolean;
19
+ /** Easing function (default: cubic-bezier(0.16, 1, 0.3, 1)) */
20
+ easing?: string;
21
+ /** Children: ReactNode or render function receiving animated state */
22
+ children: React.ReactNode | ((animated: boolean) => React.ReactNode);
23
+ }
24
+ export declare const AnimatedReveal: React.ForwardRefExoticComponent<AnimatedRevealProps & React.RefAttributes<HTMLDivElement>>;
@@ -38,4 +38,6 @@ export { SectionHeader, type SectionHeaderProps } from "./SectionHeader";
38
38
  export { MarketingStatCard, type StatCardProps as MarketingStatCardProps, type StatCardSize } from "./StatCard";
39
39
  export { ContentSection, type ContentSectionProps, type ContentSectionBackground, type ContentSectionPadding, } from "./ContentSection";
40
40
  export { PatternTile, getTileDimensions, type PatternTileProps, type PatternVariant } from "./PatternTile";
41
+ export { AnimatedReveal, type AnimatedRevealProps, type RevealTrigger, type RevealAnimation } from "./AnimatedReveal";
42
+ export { AnimatedGraphic, type AnimatedGraphicProps, type GraphicAnimation } from "./AnimatedGraphic";
41
43
  export * from "./game";