@tap-payments/os-micro-frontend-shared 0.0.228-test.19 → 0.0.228-test.21
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.
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { TableHeaderStatus } from '../../types/index.js';
|
|
3
3
|
import { AvailableStatus } from './type';
|
|
4
|
-
interface StatusBarProps {
|
|
5
|
-
status?:
|
|
6
|
-
availableStatuses?: AvailableStatus[];
|
|
4
|
+
interface StatusBarProps<IStatus extends TableHeaderStatus | TableHeaderStatus[] = undefined> {
|
|
5
|
+
status?: IStatus;
|
|
6
|
+
availableStatuses?: AvailableStatus<IStatus>[];
|
|
7
7
|
isFilteredIdsShown?: boolean;
|
|
8
|
-
onStatusChange?: (status:
|
|
8
|
+
onStatusChange?: (status: IStatus) => void;
|
|
9
9
|
}
|
|
10
|
-
declare function StatusBar({ isFilteredIdsShown, onStatusChange, availableStatuses, status, }: StatusBarProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare function StatusBar<IStatus extends TableHeaderStatus | TableHeaderStatus[] = undefined>({ isFilteredIdsShown, onStatusChange, availableStatuses, status, }: StatusBarProps<IStatus>): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
declare const _default: import("react").MemoExoticComponent<typeof StatusBar>;
|
|
12
12
|
export default _default;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { StatusButtonProps } from '../StatusButton';
|
|
3
3
|
import { TableHeaderStatus } from '../../types/index.js';
|
|
4
|
-
export type AvailableStatus<T = undefined> = StatusButtonProps & {
|
|
5
|
-
status: T
|
|
6
|
-
render?: (status:
|
|
4
|
+
export type AvailableStatus<T extends TableHeaderStatus | TableHeaderStatus[] = undefined> = StatusButtonProps & {
|
|
5
|
+
status: T;
|
|
6
|
+
render?: <IStatus extends T>(status: IStatus, onChange: (selected: AvailableStatus<T>['status']) => void) => React.ReactNode;
|
|
7
7
|
};
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tap-payments/os-micro-frontend-shared",
|
|
3
3
|
"description": "Shared components and utilities for Tap Payments micro frontends",
|
|
4
|
-
"version": "0.0.228-test.
|
|
5
|
-
"testVersion":
|
|
4
|
+
"version": "0.0.228-test.21",
|
|
5
|
+
"testVersion": 21,
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "build/index.js",
|
|
8
8
|
"module": "build/index.js",
|