Skip to content

Commit bad40fc

Browse files
committed
feat(list): remove bullet list item and fixes
1 parent 8ae3799 commit bad40fc

19 files changed

Lines changed: 10433 additions & 13225 deletions

File tree

scripts/convertDoczToKitchenSink.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ function removeUnused() {
4242
remove(tree, 'import');
4343
remove(tree, 'thematicBreak');
4444
remove(tree, 'paragraph');
45+
remove(tree, 'code');
4546

4647
const isNotH1 = node => node.type === 'heading' && node.depth !== 1;
4748
const isPropsTable = node =>

src/components/Badge/Badge.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,17 @@ import { BadgeStyles, GetBadgeStyles, getBadgeStyles } from './Badge.styles';
1111
export interface BadgeProps {
1212
children: React.ReactNode;
1313
/**
14-
* Color of badge
14+
* Color of the badge
1515
* @default neutral
1616
*/
1717
color?: FillColor;
1818
/**
19-
* Size of badge
19+
* Size of the badge
2020
* @default medium
2121
*/
2222
size?: ControlSize;
2323
/**
24-
* Shape of container
24+
* Shape of the container
2525
* @default rounded
2626
*/
2727
shape?: ContainerShape;

src/components/Box/Box.mdx

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,27 @@ import { Box } from '..';
99

1010
# Box
1111

12-
Box is a primitive component for convenient layout of components. All style properties are passed as props and has some convenient props such as `paddingHorizontal`, `marginVertical`, `shape` for styling
12+
Primitive component for convenient layout of components that accepts all `ViewStyle` properties
1313

1414
### Usage
1515

1616
<Playground>
1717
<Box
1818
// ...ViewStyle
19-
height={200}
20-
width={200}
21-
shape="rounded" // pill, circle or square (default)
19+
height={100}
20+
width={100}
21+
shape="rounded"
2222
elevation={5}
23-
backgroundColor="primaryDefault" // background colors or any custom color "#67c6bb"
23+
backgroundColor="primaryDefault"
2424
/>
2525
</Playground>
26+
27+
### Props
28+
29+
...extends `ViewStyle`
30+
31+
Modified or additional props
32+
33+
`shape` - 'circle' | 'pill' | 'rounded' | 'roundedBottom' | 'roundedLeft' | 'roundedRight' | 'roundedTop' | 'square'
34+
35+
`backgroundColor` - valid color string or from `theme.colors.background`

src/components/Box/Box.tsx

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,8 @@ import { View, ViewStyle } from 'react-native';
44
import { BackgroundColor, ContainerShape, Theme, useTheme } from '../../theme';
55

66
export interface BoxProps extends ViewStyle {
7-
style?: ViewStyle;
87
children?: React.ReactNode;
98

10-
elevation?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
11-
129
shape?: ContainerShape;
1310
}
1411

@@ -29,7 +26,7 @@ const propToFn = {
2926
};
3027

3128
export const Box = (props: BoxProps) => {
32-
const { children, style: propStyle, testID, ...viewStyles } = props;
29+
const { children, testID, ...viewStyles } = props;
3330
const theme = useTheme();
3431
const transformedStyles = [];
3532
const pureStyles = {};
@@ -52,7 +49,7 @@ export const Box = (props: BoxProps) => {
5249
}
5350

5451
return (
55-
<View testID={testID} style={[pureStyles, transformedStyles, propStyle]}>
52+
<View testID={testID} style={[pureStyles, transformedStyles]}>
5653
{children}
5754
</View>
5855
);

src/components/Button/Button.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ export interface ButtonProps extends AccessibilityProps {
2929
icon?: React.ReactNode;
3030

3131
/**
32-
* The intent of the button.
33-
* @default "primary"
32+
* The color of the button.
33+
* @default "default"
3434
*/
3535
color?: ButtonColor;
3636

@@ -106,7 +106,7 @@ export const Button = (props: ButtonProps) => {
106106
const {
107107
appearance = 'primary',
108108
title,
109-
color = 'primary',
109+
color = 'default',
110110
getStyles,
111111
icon,
112112
iconAfter,

0 commit comments

Comments
 (0)