fansunited-management-components 1.25.0 → 1.26.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fansunited-management-components",
3
- "version": "1.25.0",
3
+ "version": "1.26.1",
4
4
  "main": "index.es.js",
5
5
  "author": "Fans United",
6
6
  "description": "",
@@ -8,6 +8,7 @@ type NumberInputProps = {
8
8
  onChange: (value: number) => void;
9
9
  isAllowed?: (values: NumberFormatValues) => boolean;
10
10
  sx?: SxProps;
11
+ size?: 'sm' | 'md' | 'lg';
11
12
  };
12
13
  declare const NumberInput: React.FC<NumberInputProps>;
13
14
  export default NumberInput;
@@ -1,11 +1,11 @@
1
1
  import { default as React } from 'react';
2
- import { RelatedEntityOption } from '../../../models/related/RelatedEntityRelationship';
2
+ import { EntityRelationship, RelatedEntityOption } from '../../../models/related/RelatedEntityRelationship';
3
3
 
4
4
  type RelatedEntityCardProps = {
5
5
  entity: RelatedEntityOption;
6
6
  relationshipLabel: string;
7
7
  deleteLabel: string;
8
- onDelete: (id: string) => void;
8
+ onDelete: (id: string, relationship: EntityRelationship) => void;
9
9
  };
10
10
  declare const RelatedEntityCard: React.FC<RelatedEntityCardProps>;
11
11
  export default RelatedEntityCard;
@@ -1,6 +1,3 @@
1
1
  import { EntityType, RelatedEntityOption } from '../models/related/RelatedEntityRelationship';
2
2
 
3
- export declare const useRelatedEntityOptions: (entityType: EntityType | null, toggleToast: () => void) => {
4
- relatedEntityOptions: RelatedEntityOption[] | null;
5
- setRelatedEntityOptions: import('react').Dispatch<import('react').SetStateAction<RelatedEntityOption[] | null>>;
6
- };
3
+ export declare const useRelatedEntityOptions: (entityType: EntityType | null, toggleToast: () => void) => RelatedEntityOption[] | null;
@@ -0,0 +1,28 @@
1
+ export interface IBranding {
2
+ colors: IBrandingColors;
3
+ urls: IBrandingUrls;
4
+ images: IBrandingImages;
5
+ }
6
+ interface IBrandingColors {
7
+ primary_color: string;
8
+ secondary_color: string;
9
+ content_color: string;
10
+ background_color: string;
11
+ border_color: string;
12
+ additional_color: string;
13
+ }
14
+ interface IBrandingUrls {
15
+ primary_url: string;
16
+ secondary_url: string;
17
+ privacy_policy_url: string;
18
+ terms_and_conditions_url: string;
19
+ additional_url: string;
20
+ }
21
+ interface IBrandingImages {
22
+ main_logo: string;
23
+ mobile_logo: string;
24
+ background_image: string;
25
+ mobile_background_image: string;
26
+ additional_image: string;
27
+ }
28
+ export {};
@@ -1,34 +1,8 @@
1
1
  import { default as ImagesModel } from 'fansunited-sdk-esm/Core/Global/Models/Images/ImagesModel';
2
2
  import { default as ContextModel } from 'fansunited-sdk-esm/Core/Namespaces/Activity/Models/RequestBody/Context/ContextModel';
3
3
  import { default as MiniGameImages } from 'fansunited-sdk-esm/Core/Namespaces/MiniGames/Models/MiniGameImages';
4
+ import { IBranding } from '../../IBranding';
4
5
 
5
- interface IBranding {
6
- colors: IBrandingColors;
7
- urls: IBrandingUrls;
8
- images: IBrandingImages;
9
- }
10
- interface IBrandingColors {
11
- primary_color: string;
12
- secondary_color: string;
13
- content_color: string;
14
- background_color: string;
15
- border_color: string;
16
- additional_color: string;
17
- }
18
- interface IBrandingUrls {
19
- primary_url: string;
20
- secondary_url: string;
21
- privacy_policy_url: string;
22
- terms_and_conditions_url: string;
23
- additional_url: string;
24
- }
25
- interface IBrandingImages {
26
- main_logo: string;
27
- mobile_logo: string;
28
- background_image: string;
29
- mobile_background_image: string;
30
- additional_image: string;
31
- }
32
6
  interface IQuestionsRequest {
33
7
  question: string;
34
8
  images: MiniGameImages;
@@ -0,0 +1,37 @@
1
+ import { default as ImagesModel } from 'fansunited-sdk-esm/Core/Global/Models/Images/ImagesModel';
2
+ import { default as ContextModel } from 'fansunited-sdk-esm/Core/Namespaces/Activity/Models/RequestBody/Context/ContextModel';
3
+ import { default as MiniGameImages } from 'fansunited-sdk-esm/Core/Namespaces/MiniGames/Models/MiniGameImages';
4
+ import { IBranding } from '../../IBranding';
5
+
6
+ export interface IEitherOrPoints {
7
+ correct_steps: number;
8
+ score: number;
9
+ }
10
+ export interface IEitherOrOption {
11
+ id: string;
12
+ label: string;
13
+ images: MiniGameImages;
14
+ value: number;
15
+ }
16
+ export default class EitherOrRequestBody {
17
+ id: string;
18
+ title: string;
19
+ alternative_title: string;
20
+ description: string;
21
+ auth_requirement: string;
22
+ type: string;
23
+ winning_condition: string;
24
+ lives: number;
25
+ time: number;
26
+ points: IEitherOrPoints[];
27
+ rules: string;
28
+ ad_content: string;
29
+ branding: IBranding | null;
30
+ labels: Object;
31
+ custom_fields: Object;
32
+ images: ImagesModel | null;
33
+ status: string;
34
+ flags: string[];
35
+ options: IEitherOrOption[];
36
+ context: ContextModel | null;
37
+ }
@@ -5,6 +5,7 @@ export interface RelatedEntityOption {
5
5
  name: string;
6
6
  type: EntityType;
7
7
  status: string;
8
+ relationship: EntityRelationship;
8
9
  }
9
10
  export default class RelatedRelationshipRequest {
10
11
  entity_id: string;
@@ -1,34 +1,8 @@
1
1
  import { PollOptionModel } from 'fansunited-sdk-esm';
2
2
  import { default as ImagesModel } from 'fansunited-sdk-esm/Core/Global/Models/Images/ImagesModel';
3
3
  import { default as ContextModel } from 'fansunited-sdk-esm/Core/Namespaces/Activity/Models/RequestBody/Context/ContextModel';
4
+ import { IBranding } from '../IBranding';
4
5
 
5
- export interface IBranding {
6
- colors: IBrandingColors;
7
- urls: IBrandingUrls;
8
- images: IBrandingImages;
9
- }
10
- export interface IBrandingColors {
11
- primary_color: string;
12
- secondary_color: string;
13
- content_color: string;
14
- background_color: string;
15
- border_color: string;
16
- additional_color: string;
17
- }
18
- export interface IBrandingUrls {
19
- primary_url: string;
20
- secondary_url: string;
21
- privacy_policy_url: string;
22
- terms_and_conditions_url: string;
23
- additional_url: string;
24
- }
25
- export interface IBrandingImages {
26
- main_logo: string;
27
- mobile_logo: string;
28
- background_image: string;
29
- mobile_background_image: string;
30
- additional_image: string;
31
- }
32
6
  export default class PollRequestBody {
33
7
  id: string;
34
8
  title: string;
@@ -7,6 +7,7 @@ import { default as ClassicQuizRequestBody } from '../../models/minigames/classi
7
7
  import { default as ListRequestBody } from '../../models/lists/ListRequestBody';
8
8
  import { default as LanguageRequestBody } from '../../models/config/LanguageRequestBody';
9
9
  import { default as PollRequestBody } from '../../models/voting/PollRequestBody';
10
+ import { default as EitherOrRequestBody } from '../../models/minigames/eitherors/EitherOrRequestBody';
10
11
  import { default as BracketGameRequestBody } from '../../models/games/bracket/BracketGameRequestBody';
11
12
 
12
13
  export default class HttpsService extends Https {
@@ -37,10 +38,13 @@ export default class HttpsService extends Https {
37
38
  exportUsers: (requestBody: any) => Promise<Response>;
38
39
  getClassicQuizParticipations: (classicQuizId: string, fromDate: string, toDate: string, groupBy: string) => Promise<Response>;
39
40
  getEntityParticipations: (entityId: string, fromDate: string, toDate: string) => Promise<Response>;
40
- getPollById: (pollId: string) => Promise<Response>;
41
41
  createPoll: (requestBody: PollRequestBody) => Promise<Response>;
42
42
  updatePoll: (id: string, requestBody: PollRequestBody) => Promise<Response>;
43
43
  deletePoll: (pollId: string) => Promise<Response>;
44
+ getEitherOrById: (id: string) => Promise<Response>;
45
+ createEitherOr: (requestBody: EitherOrRequestBody) => Promise<Response>;
46
+ updateEitherOr: (id: string, requestBody: EitherOrRequestBody) => Promise<Response>;
47
+ deleteEitherOr: (eitherOrId: string) => Promise<Response>;
44
48
  getLists: (limit: number, startAfter: string, sortOrder?: "ASC" | "DESC") => Promise<Response>;
45
49
  getListById: (listId: string) => Promise<Response>;
46
50
  getListContent: (listId: string, limit: number, sortOrder?: "ASC" | "DESC", page?: number) => Promise<Response>;