@bitrise/bitkit 9.39.1 → 9.40.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/package.json
CHANGED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
2
|
+
import Image from './Image';
|
|
3
|
+
|
|
4
|
+
export default {
|
|
5
|
+
title: 'Components/Image',
|
|
6
|
+
component: Image,
|
|
7
|
+
} as ComponentMeta<typeof Image>;
|
|
8
|
+
|
|
9
|
+
const Template: ComponentStory<typeof Image> = (props) => <Image {...props} />;
|
|
10
|
+
|
|
11
|
+
export const WithProps = Template.bind({});
|
|
12
|
+
WithProps.args = {
|
|
13
|
+
alt: 'Bitrise office',
|
|
14
|
+
src: 'bitrise_office.jpg',
|
|
15
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Image as ChakraImage, ImageProps, forwardRef } from '@chakra-ui/react';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The Image component is used to display images with support for fallback. (Default callback not implemented yet)
|
|
5
|
+
*/
|
|
6
|
+
const Image = forwardRef<ImageProps, 'img'>((props, ref) => {
|
|
7
|
+
return <ChakraImage {...props} ref={ref} />;
|
|
8
|
+
});
|
|
9
|
+
|
|
10
|
+
export type { ImageProps };
|
|
11
|
+
|
|
12
|
+
export default Image;
|
package/src/index.ts
CHANGED
|
@@ -129,3 +129,6 @@ export { default as Radio } from './Components/Form/Radio/Radio';
|
|
|
129
129
|
|
|
130
130
|
export type { RadioGroupProps } from './Components/Form/Radio/RadioGroup';
|
|
131
131
|
export { default as RadioGroup } from './Components/Form/Radio/RadioGroup';
|
|
132
|
+
|
|
133
|
+
export type { ImageProps } from './Components/Image/Image';
|
|
134
|
+
export { default as Image } from './Components/Image/Image';
|
package/src/old.ts
CHANGED
|
@@ -79,9 +79,6 @@ export { default as Grid } from './Old/Grid/Grid';
|
|
|
79
79
|
export type { Props as HamburgerProps } from './Old/Hamburger/Hamburger';
|
|
80
80
|
export { default as Hamburger } from './Old/Hamburger/Hamburger';
|
|
81
81
|
|
|
82
|
-
export type { Props as ImageProps } from './Old/Image/Image';
|
|
83
|
-
export { default as Image } from './Old/Image/Image';
|
|
84
|
-
|
|
85
82
|
export type { Props as InputProps } from './Old/Input/Input';
|
|
86
83
|
export { default as Input } from './Old/Input/Input';
|
|
87
84
|
|