@livetiles/reach-components-react 0.4.3 → 0.4.6
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,9 +1,10 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
|
-
import { EventItem } from '@livetiles/reach/util/common';
|
|
2
|
+
import { EventItem, ItemResourceTypes } from '@livetiles/reach/util/common';
|
|
3
3
|
export interface EventsEditorDashboardProps {
|
|
4
4
|
groupId?: string;
|
|
5
5
|
className?: string;
|
|
6
6
|
onItemClick?: (item: EventItem) => unknown;
|
|
7
|
+
onCreateNewItemClick?: (itemResourceType: ItemResourceTypes, groupId: string) => unknown;
|
|
7
8
|
pageSize?: number;
|
|
8
9
|
hidePagination?: boolean;
|
|
9
10
|
}
|
|
@@ -4,15 +4,16 @@ import { PublishableItemFilterDefinition } from '@livetiles/reach/feature/conten
|
|
|
4
4
|
interface LibraryProps<TItem extends PublishableItem = PublishableItem> {
|
|
5
5
|
pageSize: number;
|
|
6
6
|
itemResourceType: ItemResourceTypes;
|
|
7
|
-
onItemClick: (item: TItem) => unknown;
|
|
8
7
|
onRenderContent: (item: TItem, title: string) => unknown;
|
|
9
8
|
initialGroupId?: string;
|
|
10
9
|
hidePagination?: boolean;
|
|
11
10
|
emptyMessageResources: string[];
|
|
12
11
|
emptyListSvg: ReactNode;
|
|
12
|
+
onItemClick?: (item: TItem) => unknown;
|
|
13
|
+
onCreateNewItemClick?: (itemResourceType: ItemResourceTypes, groupId: string) => unknown;
|
|
13
14
|
additionalFilterComponents?: ReactNode;
|
|
14
15
|
additionalFilters?: PublishableItemFilterDefinition;
|
|
15
16
|
className?: string;
|
|
16
17
|
}
|
|
17
|
-
export declare const PublishableItemEditorDashboard: <TItem extends PublishableItem>({ initialGroupId, itemResourceType,
|
|
18
|
+
export declare const PublishableItemEditorDashboard: <TItem extends PublishableItem>({ initialGroupId, itemResourceType, onRenderContent, pageSize, hidePagination, emptyMessageResources, emptyListSvg, onItemClick, onCreateNewItemClick, additionalFilterComponents, additionalFilters: incomingFilters, className, }: LibraryProps<TItem>) => JSX.Element;
|
|
18
19
|
export {};
|
|
@@ -3,5 +3,6 @@ import { ItemResourceTypes } from '@livetiles/reach/util/common';
|
|
|
3
3
|
export declare const NewPublishableItemButton: FC<{
|
|
4
4
|
itemResourceType: ItemResourceTypes;
|
|
5
5
|
groupId?: string;
|
|
6
|
+
onCreateNewItemClick?: (itemResourceType: ItemResourceTypes, groupId: string) => unknown;
|
|
6
7
|
className?: string;
|
|
7
8
|
}>;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
|
-
import { NewsItem } from '@livetiles/reach/util/common';
|
|
2
|
+
import { ItemResourceTypes, NewsItem } from '@livetiles/reach/util/common';
|
|
3
3
|
export interface NewsEditorDashboardProps {
|
|
4
4
|
groupId?: string;
|
|
5
5
|
className?: string;
|
|
6
6
|
onItemClick?: (item: NewsItem) => unknown;
|
|
7
|
+
onCreateNewItemClick?: (itemResourceType: ItemResourceTypes, groupId: string) => unknown;
|
|
7
8
|
pageSize?: number;
|
|
8
9
|
hidePagination?: boolean;
|
|
9
10
|
}
|
package/index.d.ts
CHANGED
|
@@ -896,7 +896,7 @@ interface BeforePublishingDateFilterDefinition extends IndexableFilterDefinition
|
|
|
896
896
|
beforeDate?: string;
|
|
897
897
|
}
|
|
898
898
|
|
|
899
|
-
interface PublishableItemFilterDefinition extends IndexableFilterDefinition, BaseFilterDefinition, BeforePublishingDateFilterDefinition, OwnerFilterDefinition, SourceFilterDefinition, KeywordsFilterDefinition {
|
|
899
|
+
interface PublishableItemFilterDefinition extends IndexableFilterDefinition, BaseFilterDefinition, BeforePublishingDateFilterDefinition, OwnerFilterDefinition, SourceFilterDefinition, KeywordsFilterDefinition, ItemIdsFilterDefinition {
|
|
900
900
|
}
|
|
901
901
|
interface BaseFilterDefinition {
|
|
902
902
|
search?: string;
|
|
@@ -904,6 +904,9 @@ interface BaseFilterDefinition {
|
|
|
904
904
|
pageSize?: string | number;
|
|
905
905
|
groupId?: string;
|
|
906
906
|
}
|
|
907
|
+
interface ItemIdsFilterDefinition {
|
|
908
|
+
itemIds?: string;
|
|
909
|
+
}
|
|
907
910
|
interface IndexableFilterDefinition {
|
|
908
911
|
[key: string]: any;
|
|
909
912
|
}
|
|
@@ -1113,6 +1116,7 @@ interface NewsEditorDashboardProps {
|
|
|
1113
1116
|
groupId?: string;
|
|
1114
1117
|
className?: string;
|
|
1115
1118
|
onItemClick?: (item: NewsItem) => unknown;
|
|
1119
|
+
onCreateNewItemClick?: (itemResourceType: ItemResourceTypes, groupId: string) => unknown;
|
|
1116
1120
|
pageSize?: number;
|
|
1117
1121
|
hidePagination?: boolean;
|
|
1118
1122
|
}
|
|
@@ -1122,6 +1126,7 @@ interface EventsEditorDashboardProps {
|
|
|
1122
1126
|
groupId?: string;
|
|
1123
1127
|
className?: string;
|
|
1124
1128
|
onItemClick?: (item: EventItem) => unknown;
|
|
1129
|
+
onCreateNewItemClick?: (itemResourceType: ItemResourceTypes, groupId: string) => unknown;
|
|
1125
1130
|
pageSize?: number;
|
|
1126
1131
|
hidePagination?: boolean;
|
|
1127
1132
|
}
|