@true-engineering/true-react-common-ui-kit 3.54.0 → 3.55.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/README.md +7 -0
- package/dist/components/List/List.d.ts +1 -1
- package/dist/components/List/index.d.ts +2 -1
- package/dist/components/List/types.d.ts +4 -0
- package/dist/components/Select/index.d.ts +1 -1
- package/dist/true-react-common-ui-kit.js +6 -1
- package/dist/true-react-common-ui-kit.js.map +1 -1
- package/dist/true-react-common-ui-kit.umd.cjs +6 -1
- package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
- package/package.json +1 -1
- package/src/components/List/List.tsx +5 -2
- package/src/components/List/index.ts +2 -1
- package/src/components/List/types.ts +5 -0
- package/src/components/Select/index.ts +1 -1
package/package.json
CHANGED
|
@@ -8,7 +8,8 @@ import {
|
|
|
8
8
|
import { addDataAttributes } from '../../helpers';
|
|
9
9
|
import { ICommonProps } from '../../types';
|
|
10
10
|
import { WithPopup } from '../WithPopup';
|
|
11
|
-
import { IListItemProps,
|
|
11
|
+
import { IListItemProps, ListItem } from './components';
|
|
12
|
+
import { IListItem } from './types';
|
|
12
13
|
import { useStyles, IListStyles, withPopupStyles } from './List.styles';
|
|
13
14
|
|
|
14
15
|
export interface IListProps extends ICommonProps<IListStyles> {
|
|
@@ -29,9 +30,11 @@ export const List: FC<IListProps> = ({ items, testId, data, tweakStyles, onClick
|
|
|
29
30
|
}
|
|
30
31
|
};
|
|
31
32
|
|
|
33
|
+
const filteredItems = items.filter(({ isHidden }) => !isHidden);
|
|
34
|
+
|
|
32
35
|
return (
|
|
33
36
|
<div className={classes.root} {...addDataTestId(testId)} {...addDataAttributes(data)}>
|
|
34
|
-
{
|
|
37
|
+
{filteredItems.map((item, i) => {
|
|
35
38
|
const itemProps: IListItemProps = {
|
|
36
39
|
testId: getTestId(testId, `item-${i}`),
|
|
37
40
|
...item,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
export * from './List';
|
|
2
2
|
export type { IListStyles } from './List.styles';
|
|
3
|
-
export
|
|
3
|
+
export type { IListItem } from './types';
|
|
4
|
+
export { type IListItemStyles, type IListItemProps, ListItem } from './components';
|