digital-rabbit-cl 2.4.5 → 2.4.8
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/Image/Image.d.ts +40 -0
- package/dist/components/Image/Image.d.ts.map +1 -0
- package/dist/components/Image/index.d.ts +3 -0
- package/dist/components/Image/index.d.ts.map +1 -0
- package/dist/digital-rabbit-cl.es.js +1113 -1061
- package/dist/digital-rabbit-cl.umd.js +4 -4
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { BaseComponentProps, ElementSpecificProps } from '../../types/component-props';
|
|
3
|
+
export interface ImageProps extends Pick<BaseComponentProps, 'className' | 'style'> {
|
|
4
|
+
/**
|
|
5
|
+
* Image source URL
|
|
6
|
+
*/
|
|
7
|
+
src?: string | null;
|
|
8
|
+
/**
|
|
9
|
+
* Alt text for the image
|
|
10
|
+
*/
|
|
11
|
+
alt?: string;
|
|
12
|
+
/**
|
|
13
|
+
* CSS aspect-ratio value. Controls the height of the container.
|
|
14
|
+
* @default '1 / 1'
|
|
15
|
+
*/
|
|
16
|
+
aspectRatio?: string;
|
|
17
|
+
/**
|
|
18
|
+
* Explicitly show the skeleton — use when you don't have a src yet (e.g. mid-upload).
|
|
19
|
+
* The skeleton also shows automatically while the image loads from the network,
|
|
20
|
+
* but only after skeletonDelay ms have passed (to avoid flashing on fast loads).
|
|
21
|
+
*/
|
|
22
|
+
loading?: boolean;
|
|
23
|
+
/**
|
|
24
|
+
* How long to wait before showing the network-load skeleton (ms).
|
|
25
|
+
* @default 150
|
|
26
|
+
*/
|
|
27
|
+
skeletonDelay?: number;
|
|
28
|
+
/**
|
|
29
|
+
* Custom fallback element shown when src is missing or fails to load.
|
|
30
|
+
* Defaults to a plain placeholder background.
|
|
31
|
+
*/
|
|
32
|
+
fallback?: React.ReactNode;
|
|
33
|
+
/**
|
|
34
|
+
* HTML img element attributes (omits conflicting props)
|
|
35
|
+
*/
|
|
36
|
+
imgProps?: Omit<ElementSpecificProps<HTMLImageElement>, 'src' | 'alt' | 'style' | 'className'>;
|
|
37
|
+
}
|
|
38
|
+
declare const Image: React.FC<ImageProps>;
|
|
39
|
+
export default Image;
|
|
40
|
+
//# sourceMappingURL=Image.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["../../../src/components/Image/Image.tsx"],"names":[],"mappings":"AAEA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAInD,OAAO,KAAK,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAC;AAE5F,MAAM,WAAW,UAAW,SAAQ,IAAI,CAAC,kBAAkB,EAAE,WAAW,GAAG,OAAO,CAAC;IACjF;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEpB;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAElB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAE3B;;OAEG;IACH,QAAQ,CAAC,EAAE,IAAI,CAAC,oBAAoB,CAAC,gBAAgB,CAAC,EAAE,KAAK,GAAG,KAAK,GAAG,OAAO,GAAG,WAAW,CAAC,CAAC;CAChG;AAED,QAAA,MAAM,KAAK,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CA6D/B,CAAC;AAEF,eAAe,KAAK,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Image/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,cAAc,SAAS,CAAC"}
|