agroptima-design-system 0.11.0 → 0.11.1
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/.storybook/main.ts +0 -7
- package/package.json +1 -1
- package/src/atoms/Alert.tsx +1 -1
- package/src/atoms/Badge.tsx +1 -1
- package/src/atoms/Button.tsx +1 -1
- package/src/atoms/CardsTable.tsx +1 -1
- package/src/atoms/CardsTableCell.tsx +1 -1
- package/src/atoms/CardsTableHeader.tsx +1 -1
- package/src/atoms/Checkbox.tsx +2 -2
- package/src/atoms/EmptyState.tsx +1 -1
- package/src/atoms/Icon.tsx +1 -1
- package/src/atoms/IconButton.tsx +1 -1
- package/src/atoms/Input.tsx +3 -3
- package/src/atoms/Modal.tsx +1 -1
- package/src/atoms/Multiselect.tsx +2 -2
- package/src/atoms/Select.tsx +2 -2
- package/src/atoms/TextArea.tsx +3 -3
- package/src/stories/Changelog.stories.mdx +5 -1
- package/src/stories/TextArea.stories.ts +1 -1
- package/tests/utils/{classNames.spec.tsx → classNames.spec.tx} +1 -1
package/.storybook/main.ts
CHANGED
package/package.json
CHANGED
package/src/atoms/Alert.tsx
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { IconButton, IconButtonProps } from './IconButton'
|
|
2
2
|
import { Icon } from './Icon'
|
|
3
3
|
import './Alert.scss'
|
|
4
|
-
import { classNames } from '
|
|
4
|
+
import { classNames } from '../utils/classNames'
|
|
5
5
|
|
|
6
6
|
export type Variant = 'info' | 'success' | 'warning' | 'error'
|
|
7
7
|
|
package/src/atoms/Badge.tsx
CHANGED
package/src/atoms/Button.tsx
CHANGED
package/src/atoms/CardsTable.tsx
CHANGED
package/src/atoms/Checkbox.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { classNames } from '
|
|
1
|
+
import { classNames } from '../utils/classNames'
|
|
2
2
|
import './Checkbox.scss'
|
|
3
3
|
|
|
4
4
|
export type Variant = 'primary'
|
|
@@ -7,7 +7,7 @@ export interface CheckboxProps extends React.ComponentPropsWithoutRef<'input'> {
|
|
|
7
7
|
label?: string
|
|
8
8
|
hideLabel?: boolean
|
|
9
9
|
variant?: Variant
|
|
10
|
-
id
|
|
10
|
+
id?: string
|
|
11
11
|
accessibilityLabel: string
|
|
12
12
|
}
|
|
13
13
|
|
package/src/atoms/EmptyState.tsx
CHANGED
package/src/atoms/Icon.tsx
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import './Icon.scss'
|
|
2
2
|
|
|
3
3
|
import * as icons from '../icons'
|
|
4
|
-
import { classNames } from '
|
|
4
|
+
import { classNames } from '../utils/classNames'
|
|
5
5
|
export type IconType = keyof typeof icons
|
|
6
6
|
|
|
7
7
|
export interface IconProps extends React.SVGAttributes<HTMLOrSVGElement> {
|
package/src/atoms/IconButton.tsx
CHANGED
package/src/atoms/Input.tsx
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { useState } from 'react'
|
|
2
2
|
import { Icon, IconType } from './Icon'
|
|
3
|
-
import { classNames } from '
|
|
3
|
+
import { classNames } from '../utils/classNames'
|
|
4
|
+
import { buildHelpText } from '../utils/buildHelpText'
|
|
4
5
|
import './Input.scss'
|
|
5
|
-
import { buildHelpText } from '@/utils/buildHelpText'
|
|
6
6
|
|
|
7
7
|
export type InputVariant = 'primary'
|
|
8
8
|
|
|
@@ -13,7 +13,7 @@ export interface InputProps extends React.ComponentPropsWithoutRef<'input'> {
|
|
|
13
13
|
icon?: IconType
|
|
14
14
|
helpText?: string
|
|
15
15
|
variant?: InputVariant
|
|
16
|
-
id
|
|
16
|
+
id?: string
|
|
17
17
|
errors?: string[]
|
|
18
18
|
}
|
|
19
19
|
|
package/src/atoms/Modal.tsx
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import './Multiselect.scss'
|
|
2
2
|
import React, { useState } from 'react'
|
|
3
3
|
import { Icon } from './Icon'
|
|
4
|
-
import { classNames } from '
|
|
5
|
-
import { buildHelpText } from '
|
|
4
|
+
import { classNames } from '../utils/classNames'
|
|
5
|
+
import { buildHelpText } from '../utils/buildHelpText'
|
|
6
6
|
|
|
7
7
|
export type Variant = 'primary'
|
|
8
8
|
export type Option = { id: string; label: string }
|
package/src/atoms/Select.tsx
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import './Select.scss'
|
|
2
2
|
import React, { useState } from 'react'
|
|
3
3
|
import { Icon } from './Icon'
|
|
4
|
-
import { classNames } from '
|
|
5
|
-
import { buildHelpText } from '
|
|
4
|
+
import { classNames } from '../utils/classNames'
|
|
5
|
+
import { buildHelpText } from '../utils/buildHelpText'
|
|
6
6
|
|
|
7
7
|
export type Variant = 'primary'
|
|
8
8
|
export type Option = { id: string; label: string }
|
package/src/atoms/TextArea.tsx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { classNames } from '
|
|
2
|
-
import { buildHelpText } from '
|
|
1
|
+
import { classNames } from '../utils/classNames'
|
|
2
|
+
import { buildHelpText } from '../utils/buildHelpText'
|
|
3
3
|
import './Input.scss'
|
|
4
4
|
|
|
5
5
|
export type TextAreaVariant = 'primary'
|
|
@@ -15,7 +15,7 @@ export interface TextAreaProps
|
|
|
15
15
|
errors?: string[]
|
|
16
16
|
}
|
|
17
17
|
|
|
18
|
-
export
|
|
18
|
+
export function TextArea({
|
|
19
19
|
id,
|
|
20
20
|
label,
|
|
21
21
|
className,
|
|
@@ -3,9 +3,13 @@ import { Meta } from "@storybook/addon-docs";
|
|
|
3
3
|
<Meta title="Changelog" />
|
|
4
4
|
# Changelog
|
|
5
5
|
|
|
6
|
+
## 0.11.1
|
|
7
|
+
- Input and Checkbox components `id` prop now it's optional.
|
|
8
|
+
- Fixed TextArea export component.
|
|
9
|
+
|
|
6
10
|
## 0.11.0
|
|
7
11
|
- Added TextArea component to Storybook.
|
|
8
|
-
-
|
|
12
|
+
- Input, Checkbox and TextArea components `id` prop now is obtained from `id` or `name`.
|
|
9
13
|
|
|
10
14
|
## 0.10.0
|
|
11
15
|
|