@bitrise/bitkit 10.33.0-alpha-chakra.2 → 10.33.0-alpha-chakra.3
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 +1 -1
- package/src/Components/ProgressBitbot/ProgressBitbot.stories.tsx +12 -0
- package/src/{Old/Progress → Components/ProgressBitbot}/ProgressBitbot.tsx +12 -12
- package/src/index.ts +3 -0
- package/src/old.ts +0 -3
- package/src/tsconfig.tsbuildinfo +1 -1
- package/src/Old/Progress/bitbot-0.svg +0 -13
- package/src/Old/Progress/bitbot-1.svg +0 -13
- package/src/Old/Progress/bitbot.sketch +0 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bitrise/bitkit",
|
|
3
3
|
"description": "Bitrise React component library",
|
|
4
|
-
"version": "10.33.0-alpha-chakra.
|
|
4
|
+
"version": "10.33.0-alpha-chakra.3",
|
|
5
5
|
"repository": "git@github.com:bitrise-io/bitkit.git",
|
|
6
6
|
"main": "src/index.ts",
|
|
7
7
|
"license": "UNLICENSED",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import Text from '
|
|
1
|
+
import { forwardRef } from '@chakra-ui/react';
|
|
2
|
+
import Box, { BoxProps } from '../Box/Box';
|
|
3
|
+
import Text from '../Text/Text';
|
|
4
4
|
|
|
5
|
-
export interface
|
|
5
|
+
export interface ProgressBitbotProps extends BoxProps {
|
|
6
6
|
/**
|
|
7
7
|
* Message that appears underneath Bitbot to help
|
|
8
8
|
* indicate what is progressing.
|
|
@@ -11,7 +11,7 @@ export interface Props extends BaseProps {
|
|
|
11
11
|
/**
|
|
12
12
|
* The size of the Bitbot progress indicator.
|
|
13
13
|
*/
|
|
14
|
-
size?:
|
|
14
|
+
size?: BoxProps['width'];
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
const alternate = (a: string, b: string, length: number) =>
|
|
@@ -58,12 +58,12 @@ const mouth = alternate(mouth0, mouth1, 7);
|
|
|
58
58
|
/**
|
|
59
59
|
* A playful indeterminate progress indicator.
|
|
60
60
|
*/
|
|
61
|
-
const ProgressBitbot
|
|
61
|
+
const ProgressBitbot = forwardRef<ProgressBitbotProps, 'div'>((props, ref) => {
|
|
62
62
|
const { content, size, ...rest } = props;
|
|
63
63
|
|
|
64
64
|
return (
|
|
65
|
-
<
|
|
66
|
-
<svg fill="currentColor" height={size} viewBox="0 0 24 24" width={size}>
|
|
65
|
+
<Box {...rest} ref={ref}>
|
|
66
|
+
<Box as="svg" fill="currentColor" height={size} viewBox="0 0 24 24" width={size} marginX="auto">
|
|
67
67
|
<g fill="currentColor" fillRule="evenodd" stroke="none" strokeWidth="1">
|
|
68
68
|
<path d={dot0}>
|
|
69
69
|
<animate
|
|
@@ -156,19 +156,19 @@ const ProgressBitbot: React.FunctionComponent<Props> = (props: Props) => {
|
|
|
156
156
|
/>
|
|
157
157
|
</path>
|
|
158
158
|
</g>
|
|
159
|
-
</
|
|
159
|
+
</Box>
|
|
160
160
|
|
|
161
161
|
{content && (
|
|
162
162
|
<Text textAlign="center" size="1" textTransform="uppercase">
|
|
163
163
|
{content}
|
|
164
164
|
</Text>
|
|
165
165
|
)}
|
|
166
|
-
</
|
|
166
|
+
</Box>
|
|
167
167
|
);
|
|
168
|
-
};
|
|
168
|
+
});
|
|
169
169
|
|
|
170
170
|
ProgressBitbot.defaultProps = {
|
|
171
|
-
size:
|
|
171
|
+
size: 64,
|
|
172
172
|
};
|
|
173
173
|
|
|
174
174
|
export default ProgressBitbot;
|
package/src/index.ts
CHANGED
|
@@ -216,3 +216,6 @@ export { default as SkeletonBox } from './Components/Skeleton/SkeletonBox';
|
|
|
216
216
|
|
|
217
217
|
export type { ProgressBarProps } from './Components/ProgressBar/ProgressBar';
|
|
218
218
|
export { default as ProgressBar } from './Components/ProgressBar/ProgressBar';
|
|
219
|
+
|
|
220
|
+
export type { ProgressBitbotProps } from './Components/ProgressBitbot/ProgressBitbot';
|
|
221
|
+
export { default as ProgressBitbot } from './Components/ProgressBitbot/ProgressBitbot';
|
package/src/old.ts
CHANGED
|
@@ -18,8 +18,5 @@ export { default as DatePicker } from './Old/DatePicker/DatePicker';
|
|
|
18
18
|
export type { Props as FlexProps } from './Old/Flex/Flex';
|
|
19
19
|
export { default as Flex } from './Old/Flex/Flex';
|
|
20
20
|
|
|
21
|
-
export type { Props as ProgressBitbotProps } from './Old/Progress/ProgressBitbot';
|
|
22
|
-
export { default as ProgressBitbot } from './Old/Progress/ProgressBitbot';
|
|
23
|
-
|
|
24
21
|
export type { Props as ProgressSpinnerProps } from './Old/Progress/ProgressSpinner';
|
|
25
22
|
export { default as ProgressSpinner } from './Old/Progress/ProgressSpinner';
|