gantri-components 1.57.0 → 1.60.0
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.constants.d.ts +0 -3
- package/dist/components/image/image.styles.d.ts +1 -0
- package/dist/components/image/image.types.d.ts +10 -1
- package/dist/index.cjs.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { ResolutionAwareProp } from '../../types/resolution-aware-prop.type';
|
|
2
2
|
import { ImageTransformationsVariant, Transformations } from './image.types';
|
|
3
3
|
import { Optional } from '../../types/common';
|
|
4
|
-
export declare const FULL_WIDTH_TRANSFORMATIONS: Optional<ResolutionAwareProp<Transformations>>;
|
|
5
|
-
export declare const HALF_WIDTH_TRANSFORMATIONS: Optional<ResolutionAwareProp<Transformations>>;
|
|
6
|
-
export declare const QUARTER_WIDTH_TRANSFORMATIONS: Optional<ResolutionAwareProp<Transformations>>;
|
|
7
4
|
export declare const TRANSFORMATION_VARIANTS_MAP: Record<ImageTransformationsVariant, Optional<ResolutionAwareProp<Transformations>>>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import { StyledImageContainerProps, StyledImageProps } from './image.types';
|
|
2
2
|
export declare const StyledImageContainer: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, StyledImageContainerProps, never>;
|
|
3
3
|
export declare const StyledImage: import("styled-components").StyledComponent<"img", import("styled-components").DefaultTheme, StyledImageProps, never>;
|
|
4
|
+
export declare const StyledContent: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
@@ -2,7 +2,7 @@ import { Property } from 'csstype';
|
|
|
2
2
|
import { ResolutionAwareProp } from '../../types/resolution-aware-prop.type';
|
|
3
3
|
import { Color } from '../../styles';
|
|
4
4
|
import { Optional } from '../../types/common';
|
|
5
|
-
export declare type ImageTransformationsVariant = '
|
|
5
|
+
export declare type ImageTransformationsVariant = 'f' | 'h' | 'q' | 'ffh' | 'hff' | 'hhf';
|
|
6
6
|
export interface ImageProps {
|
|
7
7
|
alt: string;
|
|
8
8
|
aspectRatio?: Optional<ResolutionAwareProp<string>>;
|
|
@@ -23,6 +23,15 @@ export interface ImageProps {
|
|
|
23
23
|
source?: Optional<ImageSource>;
|
|
24
24
|
src: ResolutionAwareProp<string>;
|
|
25
25
|
transformations?: Optional<ResolutionAwareProp<Transformations>>;
|
|
26
|
+
/**
|
|
27
|
+
* Used to define common transformation for images.
|
|
28
|
+
* f => full width
|
|
29
|
+
* h => half width
|
|
30
|
+
* q => quarter width
|
|
31
|
+
* ffh => desktop full width, tablet full width, mobile half width
|
|
32
|
+
* hff => desktop half width, tablet full width, mobile full width
|
|
33
|
+
* hhf => desktop half width, tablet half width, mobile full width
|
|
34
|
+
*/
|
|
26
35
|
transformationsVariant?: Optional<ImageTransformationsVariant>;
|
|
27
36
|
width?: Optional<ResolutionAwareProp<string | number>>;
|
|
28
37
|
}
|