fansunited-management-components 1.0.0-RC1
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 +0 -0
- package/dev/App.d.ts +2 -0
- package/dev/main.d.ts +1 -0
- package/index.es.d.ts +3 -0
- package/index.es.js +58315 -0
- package/index.umd.js +3604 -0
- package/package.json +8 -0
- package/src/components/Accordion/Accordion.d.ts +6 -0
- package/src/components/Accordion/AccordionCard.d.ts +4 -0
- package/src/components/AdContent/AdContent.d.ts +9 -0
- package/src/components/BasicSelect/BasicSelect.d.ts +10 -0
- package/src/components/Branding/Branding.d.ts +9 -0
- package/src/components/Branding/BrandingImage.d.ts +11 -0
- package/src/components/Buttons/HeaderButtons.d.ts +8 -0
- package/src/components/Calendars/DatePicker.d.ts +8 -0
- package/src/components/Calendars/Duration.d.ts +11 -0
- package/src/components/Calendars/RangeCalendar.d.ts +11 -0
- package/src/components/Checkboxes/Checkboxes.d.ts +13 -0
- package/src/components/Common/Toast.d.ts +11 -0
- package/src/components/DynamicFields/DynamicFields.d.ts +9 -0
- package/src/components/Flags/Flags.d.ts +9 -0
- package/src/components/FloatingLabelInput/FloatingLabelInput.d.ts +4 -0
- package/src/components/Images/ImageCard.d.ts +11 -0
- package/src/components/Images/Images.d.ts +10 -0
- package/src/components/InformationInput/InformationInput.d.ts +11 -0
- package/src/components/Login/Login.d.ts +8 -0
- package/src/components/MainColumn/MainColumn.d.ts +4 -0
- package/src/components/MarketSelection/MarketSelection.d.ts +10 -0
- package/src/components/Match/Match.d.ts +9 -0
- package/src/components/Modals/CropImageModal.d.ts +12 -0
- package/src/components/Modals/PreviewImageModal.d.ts +10 -0
- package/src/components/Related/Related.d.ts +10 -0
- package/src/components/Related/RelatedGames.d.ts +10 -0
- package/src/components/Related/RelatedTemplates.d.ts +9 -0
- package/src/components/RichText/RichText.d.ts +11 -0
- package/src/components/Select/SearchSelect/CompetitionSearchSelect.d.ts +11 -0
- package/src/components/Select/SearchSelect/ProfileSearchSelect.d.ts +9 -0
- package/src/components/Spinner/Spinner.d.ts +7 -0
- package/src/components/Sportal365SearchImages/ImageGrid.d.ts +9 -0
- package/src/components/Sportal365SearchImages/Sportal365ImagesPagination.d.ts +11 -0
- package/src/components/Sportal365SearchImages/Sportal365SearchImagesCard.d.ts +19 -0
- package/src/components/Switch/BooleanSwitch.d.ts +9 -0
- package/src/components/Table/Table.d.ts +7 -0
- package/src/components/Utils/VisuallyHiddenInput.d.ts +2 -0
- package/src/components/Winners/Preview/PreviewWinners.d.ts +11 -0
- package/src/components/Winners/Tags/Tags.d.ts +9 -0
- package/src/components/Winners/WinnerForm.d.ts +12 -0
- package/src/components/Winners/Winners.d.ts +11 -0
- package/src/components/Winners/WinnersConfig.d.ts +16 -0
- package/src/components/Winners/WinnersLayout.d.ts +12 -0
- package/src/constants/components.d.ts +1 -0
- package/src/constants/placeholders.d.ts +1 -0
- package/src/context/ApiContext.d.ts +14 -0
- package/src/context/AuthContext.d.ts +9 -0
- package/src/context/ComponentContext.d.ts +9 -0
- package/src/firebase/firebase.d.ts +3 -0
- package/src/functions/helpers.d.ts +2 -0
- package/src/hooks/useAPIContext.d.ts +4 -0
- package/src/hooks/useComponentContext.d.ts +1 -0
- package/src/hooks/useLeaderboard.d.ts +8 -0
- package/src/hooks/useWinners.d.ts +4 -0
- package/src/index.d.ts +25 -0
- package/src/interfaces/interfaces.d.ts +3 -0
- package/src/models/ManagementWidgetConfiguration.d.ts +8 -0
- package/src/models/SignedInUrlRequestBody.d.ts +6 -0
- package/src/models/Winners/WinnersRequestBody.d.ts +8 -0
- package/src/models/Winners/WinnersUserList.d.ts +6 -0
- package/src/models/images/Images.d.ts +6 -0
- package/src/models/related/RelatedEntity.d.ts +4 -0
- package/src/models/select/EntitySelectOption.d.ts +7 -0
- package/src/models/select/ProfileSelectOption.d.ts +5 -0
- package/src/models/select/ReactSelectBaseOption.d.ts +8 -0
- package/src/models/sportal365/Sportal365Config.d.ts +4 -0
- package/src/models/sportal365/Sportal365SearchImagesFilters.d.ts +4 -0
- package/src/models/templates/TemplateRequestBody.d.ts +21 -0
- package/src/services/hash/HashService.d.ts +4 -0
- package/src/services/https/Https.d.ts +22 -0
- package/src/services/https/HttpsService.d.ts +15 -0
- package/src/types/types.d.ts +3 -0
- package/src/validators/WinnerValidator.d.ts +9 -0
- package/style.css +6 -0
package/package.json
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React, Dispatch, SetStateAction } from 'react';
|
|
2
|
+
|
|
3
|
+
type AdContentProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
defaultValue: string;
|
|
6
|
+
setValue: Dispatch<SetStateAction<string>>;
|
|
7
|
+
};
|
|
8
|
+
declare const AdContent: React.FC<AdContentProps>;
|
|
9
|
+
export default AdContent;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type BasicSelectProps = {
|
|
4
|
+
label: string;
|
|
5
|
+
defaultValue: string;
|
|
6
|
+
values: string[];
|
|
7
|
+
onChange: (value: string) => void;
|
|
8
|
+
};
|
|
9
|
+
declare const BasicSelect: React.FC<BasicSelectProps>;
|
|
10
|
+
export default BasicSelect;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type BrandingImageProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
title: string;
|
|
6
|
+
image: string;
|
|
7
|
+
onChangeImages: (url: string) => void;
|
|
8
|
+
clearImage: () => void;
|
|
9
|
+
};
|
|
10
|
+
declare const BrandingImage: React.FC<BrandingImageProps>;
|
|
11
|
+
export default BrandingImage;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type DurationProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
required: boolean;
|
|
6
|
+
defaultValue: string[];
|
|
7
|
+
onChangeFromDate: (date: string) => void;
|
|
8
|
+
onChangeToDate: (date: string) => void;
|
|
9
|
+
};
|
|
10
|
+
declare const Duration: React.FC<DurationProps>;
|
|
11
|
+
export default Duration;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { default as Sportal365SearchImagesFilters } from '../../models/sportal365/Sportal365SearchImagesFilters';
|
|
3
|
+
|
|
4
|
+
type RangeCalendarProps = {
|
|
5
|
+
label: string;
|
|
6
|
+
defaultValue: Sportal365SearchImagesFilters | null;
|
|
7
|
+
required: boolean;
|
|
8
|
+
onChange: (date: Sportal365SearchImagesFilters) => void;
|
|
9
|
+
};
|
|
10
|
+
declare const RangeCalendar: React.FC<RangeCalendarProps>;
|
|
11
|
+
export default RangeCalendar;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
type CheckboxesProps = {
|
|
3
|
+
label: string;
|
|
4
|
+
values: string[];
|
|
5
|
+
allValues: string[];
|
|
6
|
+
valuesMap: Record<string, string>;
|
|
7
|
+
showAll?: boolean;
|
|
8
|
+
showAllLabel?: string;
|
|
9
|
+
onChange: (values: string[]) => void;
|
|
10
|
+
toggleShowAll?: () => void;
|
|
11
|
+
};
|
|
12
|
+
declare const Checkboxes: React.FC<CheckboxesProps>;
|
|
13
|
+
export default Checkboxes;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ColorPaletteProp } from '@mui/joy';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
4
|
+
type ToastProps = {
|
|
5
|
+
showToast: boolean;
|
|
6
|
+
message: string;
|
|
7
|
+
color: ColorPaletteProp;
|
|
8
|
+
hideToast: () => void;
|
|
9
|
+
};
|
|
10
|
+
declare const Toast: React.FC<ToastProps>;
|
|
11
|
+
export default Toast;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type DynamicFieldsProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
defaultValue: Record<string, string> | null;
|
|
6
|
+
onChange: (value: Record<string, string>) => void;
|
|
7
|
+
};
|
|
8
|
+
declare const DynamicFields: React.FC<DynamicFieldsProps>;
|
|
9
|
+
export default DynamicFields;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type ImageCardProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
title: string;
|
|
6
|
+
image: string;
|
|
7
|
+
onChangeImages: (url: string) => void;
|
|
8
|
+
clearImage: () => void;
|
|
9
|
+
};
|
|
10
|
+
declare const ImageCard: React.FC<ImageCardProps>;
|
|
11
|
+
export default ImageCard;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { default as ImagesModel } from '../../models/images/Images';
|
|
3
|
+
|
|
4
|
+
type ImagesProps = {
|
|
5
|
+
labels: any;
|
|
6
|
+
defaultValue: ImagesModel | null;
|
|
7
|
+
onChange: (value: any) => void;
|
|
8
|
+
};
|
|
9
|
+
declare const Images: React.FC<ImagesProps>;
|
|
10
|
+
export default Images;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type InformationInputProps = {
|
|
4
|
+
label: string;
|
|
5
|
+
placeholder: string;
|
|
6
|
+
defaultValue: string;
|
|
7
|
+
required: boolean;
|
|
8
|
+
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
9
|
+
};
|
|
10
|
+
declare const InformationInput: React.FC<InformationInputProps>;
|
|
11
|
+
export default InformationInput;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type MarketSelectionProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
values: string[];
|
|
6
|
+
valuesMap: Record<string, string>;
|
|
7
|
+
onChange: (values: string[]) => void;
|
|
8
|
+
};
|
|
9
|
+
declare const MarketSelection: React.FC<MarketSelectionProps>;
|
|
10
|
+
export default MarketSelection;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as MatchBasicModel } from 'fansunited-sdk-esm/Core/Namespaces/Football/Models/Match/MatchBasicModel';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
4
|
+
type MatchProps = {
|
|
5
|
+
match: MatchBasicModel;
|
|
6
|
+
timeFormat: string;
|
|
7
|
+
};
|
|
8
|
+
declare const Match: React.FC<MatchProps>;
|
|
9
|
+
export default Match;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type CropImageModalProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
open: boolean;
|
|
6
|
+
imageSrc: string;
|
|
7
|
+
uploadImage: (image: File | null) => void;
|
|
8
|
+
resetDefaultImageUrl: () => void;
|
|
9
|
+
toggleModal: () => void;
|
|
10
|
+
};
|
|
11
|
+
declare const CropImageModal: React.FC<CropImageModalProps>;
|
|
12
|
+
export default CropImageModal;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { default as RelatedEntity } from '../../models/related/RelatedEntity';
|
|
3
|
+
|
|
4
|
+
type RelatedProps = {
|
|
5
|
+
labels: any;
|
|
6
|
+
related: RelatedEntity[];
|
|
7
|
+
onChange: (related: RelatedEntity[]) => void;
|
|
8
|
+
};
|
|
9
|
+
declare const Related: React.FC<RelatedProps>;
|
|
10
|
+
export default Related;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { default as RelatedEntity } from '../../models/related/RelatedEntity';
|
|
3
|
+
|
|
4
|
+
type RelatedGamesProps = {
|
|
5
|
+
label: string;
|
|
6
|
+
related: RelatedEntity[];
|
|
7
|
+
onChange: (related: RelatedEntity[]) => void;
|
|
8
|
+
};
|
|
9
|
+
declare const RelatedGames: React.FC<RelatedGamesProps>;
|
|
10
|
+
export default RelatedGames;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as RelatedEntity } from '../../models/related/RelatedEntity';
|
|
2
|
+
|
|
3
|
+
type RelatedTemplatesProps = {
|
|
4
|
+
label: string;
|
|
5
|
+
related: RelatedEntity[];
|
|
6
|
+
onChange: (related: RelatedEntity[]) => void;
|
|
7
|
+
};
|
|
8
|
+
declare const RelatedTemplates: React.FC<RelatedTemplatesProps>;
|
|
9
|
+
export default RelatedTemplates;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React, Dispatch, SetStateAction } from 'react';
|
|
2
|
+
|
|
3
|
+
type RichTextProps = {
|
|
4
|
+
label: string;
|
|
5
|
+
placeholder: string;
|
|
6
|
+
defaultValue: string;
|
|
7
|
+
property: 'description' | 'rules' | 'ad_content';
|
|
8
|
+
setValue: Dispatch<SetStateAction<string>>;
|
|
9
|
+
};
|
|
10
|
+
declare const RichText: React.FC<RichTextProps>;
|
|
11
|
+
export default RichText;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type CompetitionSearchSelectProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
label: string;
|
|
6
|
+
ids: string[];
|
|
7
|
+
required: boolean;
|
|
8
|
+
onChange: (ids: string[]) => void;
|
|
9
|
+
};
|
|
10
|
+
declare const CompetitionSearchSelect: React.FC<CompetitionSearchSelectProps>;
|
|
11
|
+
export default CompetitionSearchSelect;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
type ProfileSearchSelectProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
ids: string[];
|
|
6
|
+
onChange: (ids: string[] | null) => void;
|
|
7
|
+
};
|
|
8
|
+
declare const ProfileSearchSelect: React.FC<ProfileSearchSelectProps>;
|
|
9
|
+
export default ProfileSearchSelect;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ISearchImagesData } from './Sportal365SearchImagesCard';
|
|
2
|
+
|
|
3
|
+
type ImageGridProps = {
|
|
4
|
+
images: ISearchImagesData[];
|
|
5
|
+
isLoading: boolean;
|
|
6
|
+
onClick: (url: string) => void;
|
|
7
|
+
};
|
|
8
|
+
declare const ImageGrid: React.FC<ImageGridProps>;
|
|
9
|
+
export default ImageGrid;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ISearchImagesData } from './Sportal365SearchImagesCard';
|
|
2
|
+
|
|
3
|
+
type Sportal365ImagesPaginationProps = {
|
|
4
|
+
labels: any;
|
|
5
|
+
pageCount: number;
|
|
6
|
+
images: ISearchImagesData[] | null;
|
|
7
|
+
getPreviousPage: () => void;
|
|
8
|
+
getNextPage: () => void;
|
|
9
|
+
};
|
|
10
|
+
declare const Sportal365ImagesPagination: React.FC<Sportal365ImagesPaginationProps>;
|
|
11
|
+
export default Sportal365ImagesPagination;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
3
|
+
export interface ISearchImagesData {
|
|
4
|
+
id: string;
|
|
5
|
+
urls: {
|
|
6
|
+
uploaded: {
|
|
7
|
+
embed: string;
|
|
8
|
+
gallery: string;
|
|
9
|
+
original: string;
|
|
10
|
+
thumbnail: string;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
type Sportal365SearchImagesCardProps = {
|
|
15
|
+
labels: any;
|
|
16
|
+
onChangeImages: (url: string) => void;
|
|
17
|
+
};
|
|
18
|
+
declare const Sportal365SearchImagesCard: React.FC<Sportal365SearchImagesCardProps>;
|
|
19
|
+
export default Sportal365SearchImagesCard;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
declare const VisuallyHiddenInput: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/joy').Theme>, import('react').DetailedHTMLProps<import('react').InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, {}>;
|
|
2
|
+
export default VisuallyHiddenInput;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { default as ProfileModel } from 'fansunited-sdk-esm/Core/Namespaces/Profile/Models/ProfileModel';
|
|
3
|
+
import { default as WinnersRequestBody } from '../../../models/Winners/WinnersRequestBody';
|
|
4
|
+
|
|
5
|
+
type PreviewWinnersProps = {
|
|
6
|
+
labels: any;
|
|
7
|
+
winners: WinnersRequestBody;
|
|
8
|
+
profiles: ProfileModel[];
|
|
9
|
+
};
|
|
10
|
+
declare const PreviewWinners: React.FC<PreviewWinnersProps>;
|
|
11
|
+
export default PreviewWinners;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { default as LeaderboardModel } from 'fansunited-sdk-esm/Core/Namespaces/Loyalty/Models/Leaderboard/LeaderboardModel';
|
|
2
|
+
import { default as WinnersUserList } from '../../models/Winners/WinnersUserList';
|
|
3
|
+
|
|
4
|
+
type WinnerFormProps = {
|
|
5
|
+
winner: WinnersUserList;
|
|
6
|
+
profile: LeaderboardModel;
|
|
7
|
+
labels: any;
|
|
8
|
+
onChange: (property: string, value: string | string[]) => void;
|
|
9
|
+
onRemove: () => void;
|
|
10
|
+
};
|
|
11
|
+
declare const WinnerForm: React.FC<WinnerFormProps>;
|
|
12
|
+
export default WinnerForm;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { default as LeaderboardModel } from 'fansunited-sdk-esm/Core/Namespaces/Loyalty/Models/Leaderboard/LeaderboardModel';
|
|
2
|
+
import { default as WinnersUserList } from '../../models/Winners/WinnersUserList';
|
|
3
|
+
import { Dispatch, SetStateAction } from 'react';
|
|
4
|
+
import { default as WinnersRequestBody } from '../../models/Winners/WinnersRequestBody';
|
|
5
|
+
|
|
6
|
+
type WinnersConfigProps = {
|
|
7
|
+
labels: any;
|
|
8
|
+
winners: WinnersUserList[];
|
|
9
|
+
leaderboard: LeaderboardModel[] | null;
|
|
10
|
+
hasMoreParticipants: boolean;
|
|
11
|
+
isLoading: boolean;
|
|
12
|
+
setPage: Dispatch<SetStateAction<number>>;
|
|
13
|
+
setWinnersRequestBody: Dispatch<SetStateAction<WinnersRequestBody>>;
|
|
14
|
+
};
|
|
15
|
+
declare const WinnersConfig: React.FC<WinnersConfigProps>;
|
|
16
|
+
export default WinnersConfig;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { default as ContestWinners } from 'fansunited-sdk-esm/Core/Namespaces/TopX/Models/Games/Winners/ContestWinners';
|
|
3
|
+
import { default as WinnersRequestBody } from '../../models/Winners/WinnersRequestBody';
|
|
4
|
+
|
|
5
|
+
type WinnersLayoutProps = {
|
|
6
|
+
labels: any;
|
|
7
|
+
winners: ContestWinners | WinnersRequestBody;
|
|
8
|
+
entityId: string;
|
|
9
|
+
entityType: string;
|
|
10
|
+
};
|
|
11
|
+
declare const WinnersLayout: React.FC<WinnersLayoutProps>;
|
|
12
|
+
export default WinnersLayout;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const components: Record<string, React.FunctionComponent<any>>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const placeholders: any;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { default as FansUnitedSDKModel } from 'fansunited-sdk-esm/Core/Global/Models/FansUnitedSDKModel';
|
|
2
|
+
import { default as HttpsService } from '../services/https/HttpsService';
|
|
3
|
+
import { PropsWithChildren } from 'react';
|
|
4
|
+
|
|
5
|
+
type APIProviderProps = {
|
|
6
|
+
config: any;
|
|
7
|
+
};
|
|
8
|
+
type APIContextValueType = {
|
|
9
|
+
sdk: FansUnitedSDKModel;
|
|
10
|
+
https: HttpsService;
|
|
11
|
+
};
|
|
12
|
+
declare const APIContext: import('react').Context<APIContextValueType | null>;
|
|
13
|
+
declare const APIProvider: React.FC<APIProviderProps & PropsWithChildren>;
|
|
14
|
+
export { APIContext, APIProvider };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React, PropsWithChildren } from 'react';
|
|
2
|
+
import { default as firebase } from 'firebase/compat/app';
|
|
3
|
+
|
|
4
|
+
type AuthProviderProps = {
|
|
5
|
+
environment: string;
|
|
6
|
+
};
|
|
7
|
+
declare const AuthContext: React.Context<firebase.User | null>;
|
|
8
|
+
declare const AuthProvider: React.FC<AuthProviderProps & PropsWithChildren>;
|
|
9
|
+
export { AuthContext, AuthProvider };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { default as React, PropsWithChildren, ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
type ComponentProviderProps = {
|
|
4
|
+
config?: any;
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
};
|
|
7
|
+
declare const ComponentContext: React.Context<Record<string, React.FunctionComponent<any>> | null>;
|
|
8
|
+
declare const ComponentProvider: React.FC<ComponentProviderProps & PropsWithChildren>;
|
|
9
|
+
export { ComponentContext, ComponentProvider };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const useComponentContext: () => Record<string, import('react').FunctionComponent<any>>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as LeaderboardModel } from 'fansunited-sdk-esm/Core/Namespaces/Loyalty/Models/Leaderboard/LeaderboardModel';
|
|
2
|
+
import { ColorPaletteProp } from '@mui/joy';
|
|
3
|
+
|
|
4
|
+
export declare const useLeaderboard: (entityId: string, entityType: string, leaderboardErrorMessage: string, page: number, displayToast: (color: ColorPaletteProp, message: string) => void) => {
|
|
5
|
+
leaderboard: LeaderboardModel[] | null;
|
|
6
|
+
hasMoreParticipants: boolean;
|
|
7
|
+
isLeaderboardLoading: boolean;
|
|
8
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { default as ContestWinners } from 'fansunited-sdk-esm/Core/Namespaces/TopX/Models/Games/Winners/ContestWinners';
|
|
2
|
+
import { default as WinnersRequestBody } from '../models/Winners/WinnersRequestBody';
|
|
3
|
+
|
|
4
|
+
export declare const useWinners: (entityId: string, entityType: string, displayToast: () => void) => WinnersRequestBody | ContestWinners | null;
|
package/src/index.d.ts
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
APIProvider: import('react').FC<{
|
|
3
|
+
config: any;
|
|
4
|
+
} & {
|
|
5
|
+
children?: import('react').ReactNode | undefined;
|
|
6
|
+
}>;
|
|
7
|
+
AuthProvider: import('react').FC<{
|
|
8
|
+
environment: string;
|
|
9
|
+
} & {
|
|
10
|
+
children?: import('react').ReactNode | undefined;
|
|
11
|
+
}>;
|
|
12
|
+
AuthContext: import('react').Context<import("firebase/compat/app").default.User | null>;
|
|
13
|
+
ComponentProvider: import('react').FC<{
|
|
14
|
+
config?: any;
|
|
15
|
+
children?: import('react').ReactNode;
|
|
16
|
+
} & {
|
|
17
|
+
children?: import('react').ReactNode | undefined;
|
|
18
|
+
}>;
|
|
19
|
+
useComponentContext: () => Record<string, import('react').FunctionComponent<any>>;
|
|
20
|
+
useAPIContext: () => {
|
|
21
|
+
sdk: import('fansunited-sdk-esm/Core/Global/Models/FansUnitedSDKModel').default;
|
|
22
|
+
https: import('./services/https/HttpsService').default;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
export default _default;
|