@bitrise/bitkit 12.63.2 → 12.64.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
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bitrise/bitkit",
3
3
  "description": "Bitrise React component library",
4
- "version": "12.63.2",
4
+ "version": "12.64.0",
5
5
  "repository": "git@github.com:bitrise-io/bitkit.git",
6
6
  "main": "src/index.ts",
7
7
  "license": "UNLICENSED",
@@ -7,6 +7,9 @@ const baseStyle = defineStyle({
7
7
  border: '1px solid',
8
8
  borderColor: 'separator.primary',
9
9
  borderRadius: '8',
10
+ textWrap: 'wrap',
11
+ wordBreak: 'break-all',
12
+ overflowY: 'auto',
10
13
  });
11
14
 
12
15
  export default defineStyleConfig({
@@ -1,11 +1,15 @@
1
1
  import { ReactNode } from 'react';
2
- import { useStyleConfig } from '@chakra-ui/react';
2
+ import { BoxProps, useStyleConfig } from '@chakra-ui/react';
3
3
  import Box from '../Box/Box';
4
4
 
5
- const CodeBlock = ({ children }: { children: ReactNode }) => {
5
+ interface CodeBlockProps extends BoxProps {
6
+ children: ReactNode;
7
+ }
8
+
9
+ const CodeBlock = ({ children, ...props }: CodeBlockProps) => {
6
10
  const css = useStyleConfig('CodeBlock');
7
11
  return (
8
- <Box __css={css} as="pre">
12
+ <Box __css={css} as="pre" {...props}>
9
13
  {children}
10
14
  </Box>
11
15
  );