fansunited-frontend-components 0.0.1-RC5 → 0.0.1-RC6
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/classic-quiz-play.es.js +4 -4
- package/classic-quiz-play.umd.js +1 -1
- package/package.json +1 -1
- package/src/components/ClassicQuizNotFound.d.ts +2 -1
- package/src/components/ClassicQuizPlay.d.ts +3 -2
- package/src/components/Leads/CollectLead.d.ts +2 -1
- package/src/components/Leads/LeadAgreementCheckbox.d.ts +3 -2
- package/src/components/Leads/LeadForm.d.ts +2 -1
- package/src/components/Shared/Answers/Answers.d.ts +3 -2
- package/src/components/Shared/Answers/Option.d.ts +3 -2
- package/src/components/Shared/Button.d.ts +2 -1
- package/src/components/Shared/MainCard.d.ts +2 -1
- package/src/components/Shared/Pagination.d.ts +3 -2
- package/src/components/Shared/PresentedBy.d.ts +2 -1
- package/src/components/Shared/ScoreStateWrapper.d.ts +4 -3
- package/src/components/Shared/Stepper.d.ts +3 -2
- package/src/components/Shared/Stopwatch.d.ts +2 -1
- package/src/components/Variants/Overlay/AuthError/OverlayAuthError.d.ts +3 -2
- package/src/components/Variants/Overlay/AuthError/OverlayAuthError.styles.d.ts +3 -2
- package/src/components/Variants/Overlay/OverlayVariant.d.ts +3 -2
- package/src/components/Variants/Overlay/OverlayVariant.styles.d.ts +4 -3
- package/src/components/Variants/Overlay/ScoreState/OverlayScoreState.d.ts +4 -3
- package/src/components/Variants/Overlay/ScoreState/OverlayScoreState.styles.d.ts +4 -3
- package/src/components/Variants/Split/AuthError/SplitAuthError.d.ts +3 -2
- package/src/components/Variants/Split/AuthError/SplitAuthError.styles.d.ts +3 -2
- package/src/components/Variants/Split/ScoreState/SplitScoreState.d.ts +4 -3
- package/src/components/Variants/Split/ScoreState/SplitScoreState.styles.d.ts +4 -3
- package/src/components/Variants/Split/SplitVariant.d.ts +3 -2
- package/src/components/Variants/Split/SplitVariant.styles.d.ts +4 -3
- package/src/components/Variants/Standard/AuthError/StandardAuthError.d.ts +3 -2
- package/src/components/Variants/Standard/AuthError/StandardAuthError.styles.d.ts +4 -3
- package/src/components/Variants/Standard/ScoreState/StandardScoreState.d.ts +4 -3
- package/src/components/Variants/Standard/ScoreState/StandardScoreState.styles.d.ts +4 -3
- package/src/components/Variants/Standard/StandardVariant.d.ts +4 -3
- package/src/components/Variants/Standard/StandardVariant.styles.d.ts +4 -3
- package/src/constants/constants.d.ts +2 -1
- package/src/hooks/useClassicQuizById.d.ts +2 -1
- package/src/hooks/useEmbedCodeContainer.d.ts +1 -1
- package/src/hooks/useMyParticipation.d.ts +2 -1
- package/src/hooks/useScoreStateHelpers.d.ts +3 -2
- package/src/index.d.ts +2 -1
- package/src/main.d.ts +3 -2
- package/src/main.d.ts.map +1 -1
- package/src/types/types.d.ts +3 -2
- package/src/components/ClassicQuizNotFound.js +0 -55
- package/src/components/ClassicQuizPlay.js +0 -321
- package/src/components/Leads/CollectLead.js +0 -20
- package/src/components/Leads/LeadAgreementCheckbox.js +0 -45
- package/src/components/Leads/LeadForm.js +0 -289
- package/src/components/Shared/AlertMessage.js +0 -37
- package/src/components/Shared/Answers/Answers.js +0 -31
- package/src/components/Shared/Answers/Option.js +0 -118
- package/src/components/Shared/Button.js +0 -43
- package/src/components/Shared/MainCard.js +0 -24
- package/src/components/Shared/Pagination.js +0 -118
- package/src/components/Shared/PresentedBy.js +0 -51
- package/src/components/Shared/ScoreStateWrapper.js +0 -254
- package/src/components/Shared/Stepper.js +0 -75
- package/src/components/Shared/Stopwatch.js +0 -103
- package/src/components/Variants/Overlay/AuthError/OverlayAuthError.js +0 -68
- package/src/components/Variants/Overlay/AuthError/OverlayAuthError.styles.js +0 -103
- package/src/components/Variants/Overlay/OverlayVariant.js +0 -100
- package/src/components/Variants/Overlay/OverlayVariant.styles.js +0 -266
- package/src/components/Variants/Overlay/ScoreState/OverlayScoreState.js +0 -90
- package/src/components/Variants/Overlay/ScoreState/OverlayScoreState.styles.js +0 -374
- package/src/components/Variants/Split/AuthError/SplitAuthError.js +0 -44
- package/src/components/Variants/Split/AuthError/SplitAuthError.styles.js +0 -95
- package/src/components/Variants/Split/ScoreState/SplitScoreState.js +0 -84
- package/src/components/Variants/Split/ScoreState/SplitScoreState.styles.js +0 -400
- package/src/components/Variants/Split/SplitVariant.js +0 -79
- package/src/components/Variants/Split/SplitVariant.styles.js +0 -216
- package/src/components/Variants/Standard/AuthError/StandardAuthError.js +0 -43
- package/src/components/Variants/Standard/AuthError/StandardAuthError.styles.js +0 -201
- package/src/components/Variants/Standard/ScoreState/StandardScoreState.js +0 -78
- package/src/components/Variants/Standard/ScoreState/StandardScoreState.styles.js +0 -349
- package/src/components/Variants/Standard/StandardVariant.js +0 -82
- package/src/components/Variants/Standard/StandardVariant.styles.js +0 -373
- package/src/constants/constants.js +0 -446
- package/src/hooks/useClassicQuizById.js +0 -20
- package/src/hooks/useEmbedCodeContainer.js +0 -38
- package/src/hooks/useMyParticipation.js +0 -22
- package/src/hooks/useScoreStateHelpers.js +0 -156
- package/src/index.js +0 -2
- package/src/main.js +0 -53
- package/src/services/service.js +0 -1
- package/src/styles/form.styles.js +0 -18
- package/src/types/types.js +0 -1
- package/tsconfig.tsbuildinfo +0 -1
package/package.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { ClassicQuizPlayProps } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ClassicQuizPlayProps } from '../../../common/src';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
3
4
|
declare const ClassicQuizPlay: React.FC<ClassicQuizPlayProps>;
|
|
4
5
|
export default ClassicQuizPlay;
|
|
5
6
|
//# sourceMappingURL=ClassicQuizPlay.d.ts.map
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BrandingColorsModel, BrandingUrlsModel, FansUnitedSDKModel } from
|
|
1
|
+
import { BrandingColorsModel, BrandingUrlsModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
|
|
2
3
|
export type LeadField = "fullName" | "firstName" | "lastName" | "email" | "gender" | "country" | "phoneCountryCode" | "phoneNumber";
|
|
3
4
|
interface CollectLeadProps {
|
|
4
5
|
sdk: FansUnitedSDKModel;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { BrandingUrlsModel } from
|
|
2
|
-
import React from
|
|
1
|
+
import { BrandingUrlsModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
3
4
|
type LeadAgreementCheckboxProps = {
|
|
4
5
|
primaryColor: string | undefined;
|
|
5
6
|
brandingUrls: BrandingUrlsModel | undefined;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BrandingColorsModel, BrandingUrlsModel, FansUnitedSDKModel } from
|
|
1
|
+
import { BrandingColorsModel, BrandingUrlsModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
|
|
2
3
|
interface LeadFormProps {
|
|
3
4
|
sdk: FansUnitedSDKModel;
|
|
4
5
|
brandingColors?: BrandingColorsModel;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { BrandingColorsModel, ClassicQuizOptionModel } from
|
|
2
|
-
import React from
|
|
1
|
+
import { BrandingColorsModel, ClassicQuizOptionModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
3
4
|
type AnswersProps = {
|
|
4
5
|
options: ClassicQuizOptionModel[];
|
|
5
6
|
selectedOption: number | null;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { BrandingColorsModel, ClassicQuizOptionModel } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { BrandingColorsModel, ClassicQuizOptionModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
type OptionProps = {
|
|
4
5
|
option: ClassicQuizOptionModel;
|
|
5
6
|
showAnswer: boolean;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { ClassicQuizFullModel, ClassicQuizParticipationBodyModel } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ClassicQuizFullModel, ClassicQuizParticipationBodyModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
type PaginationProps = {
|
|
4
5
|
classicQuiz: ClassicQuizFullModel;
|
|
5
6
|
currentQuestion: number;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import React,
|
|
2
|
-
import { BrandingColorsModel, ClassicQuizParticipationQuestionModel, ClassicQuizQuestionModel } from
|
|
3
|
-
import { SxProps } from
|
|
1
|
+
import { default as React, PropsWithChildren } from 'react';
|
|
2
|
+
import { BrandingColorsModel, ClassicQuizParticipationQuestionModel, ClassicQuizQuestionModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { SxProps } from '@mui/material';
|
|
4
|
+
|
|
4
5
|
type ScoreStateWrapperProps = {
|
|
5
6
|
questions: ClassicQuizQuestionModel[];
|
|
6
7
|
userParticipation: ClassicQuizParticipationQuestionModel[];
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { ClassicQuizFullModel, ClassicQuizParticipationBodyModel } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ClassicQuizFullModel, ClassicQuizParticipationBodyModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
type StepperProps = {
|
|
4
5
|
classicQuiz: ClassicQuizFullModel;
|
|
5
6
|
currentQuestion: number;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { ClassicQuizFullModel } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ClassicQuizFullModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
type OverlayAuthErrorProps = {
|
|
4
5
|
classicQuiz: ClassicQuizFullModel;
|
|
5
6
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { CustomSpacingScale } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
1
|
+
import { CustomSpacingScale } from '../../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
interface StyleProps {
|
|
4
5
|
spacingScale: CustomSpacingScale;
|
|
5
6
|
brandingColors: BrandingColorsModel | null;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { MainLayoutProps } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { MainLayoutProps } from '../../../types/types';
|
|
3
|
+
|
|
3
4
|
declare const OverlayVariant: React.FC<MainLayoutProps>;
|
|
4
5
|
export default OverlayVariant;
|
|
5
6
|
//# sourceMappingURL=OverlayVariant.d.ts.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomSpacingScale } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomSpacingScale } from '../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
spacingScale: CustomSpacingScale;
|
|
6
7
|
brandingColors: BrandingColorsModel | null;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel, FansUnitedSDKModel } from
|
|
2
|
-
import React from
|
|
3
|
-
import { LeadsOptions } from
|
|
1
|
+
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
import { LeadsOptions } from '../../../../../../common/src';
|
|
4
|
+
|
|
4
5
|
type OverlayScoreState = {
|
|
5
6
|
summary: ClassicQuizUserParticipationModel;
|
|
6
7
|
totalTime: number;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomSpacingScale } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomSpacingScale } from '../../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
spacingScale: CustomSpacingScale;
|
|
6
7
|
brandingColors: BrandingColorsModel | null;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { ClassicQuizFullModel } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ClassicQuizFullModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
type SplitAuthErrorProps = {
|
|
4
5
|
classicQuiz: ClassicQuizFullModel;
|
|
5
6
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { CustomSpacingScale, CustomBorderRadius } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
1
|
+
import { CustomSpacingScale, CustomBorderRadius } from '../../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
interface StyleProps {
|
|
4
5
|
quizImage: string | null;
|
|
5
6
|
imagePlaceholder: string;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel, FansUnitedSDKModel } from
|
|
2
|
-
import React from
|
|
3
|
-
import { LeadsOptions } from
|
|
1
|
+
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
import { LeadsOptions } from '../../../../../../common/src';
|
|
4
|
+
|
|
4
5
|
type StandardScoreStateProps = {
|
|
5
6
|
summary: ClassicQuizUserParticipationModel;
|
|
6
7
|
totalTime: number;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomSpacingScale, CustomBorderRadius } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomSpacingScale, CustomBorderRadius } from '../../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
quizImage: string | null;
|
|
6
7
|
imagePlaceholder: string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { MainLayoutProps } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { MainLayoutProps } from '../../../types/types';
|
|
3
|
+
|
|
3
4
|
declare const SplitVariant: React.FC<MainLayoutProps>;
|
|
4
5
|
export default SplitVariant;
|
|
5
6
|
//# sourceMappingURL=SplitVariant.d.ts.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomSpacingScale, CustomBorderRadius } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomSpacingScale, CustomBorderRadius } from '../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
quizImage: string | null;
|
|
6
7
|
questionImage: string | null;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { ClassicQuizFullModel } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ClassicQuizFullModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
3
4
|
type StandardAuthErrorProps = {
|
|
4
5
|
classicQuiz: ClassicQuizFullModel;
|
|
5
6
|
imagePosition?: "left" | "right";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomBorderRadius, CustomSpacingScale } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomBorderRadius, CustomSpacingScale } from '../../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
quizImage: string | null;
|
|
6
7
|
spacingScale: CustomSpacingScale;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel, FansUnitedSDKModel } from
|
|
2
|
-
import React from
|
|
3
|
-
import { LeadsOptions } from
|
|
1
|
+
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
import { LeadsOptions } from '../../../../../../common/src';
|
|
4
|
+
|
|
4
5
|
type StandardScoreStateProps = {
|
|
5
6
|
imagePosition?: "left" | "right";
|
|
6
7
|
summary: ClassicQuizUserParticipationModel;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomSpacingScale, CustomBorderRadius } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomSpacingScale, CustomBorderRadius } from '../../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
quizImage: string | null;
|
|
6
7
|
spacingScale: CustomSpacingScale;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import React from
|
|
2
|
-
import { ClassicQuizParticipationBodyModel } from
|
|
3
|
-
import { MainLayoutProps } from
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ClassicQuizParticipationBodyModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { MainLayoutProps } from '../../../types/types';
|
|
4
|
+
|
|
4
5
|
type StandardVariantProps = MainLayoutProps & {
|
|
5
6
|
imagePosition?: "left" | "right";
|
|
6
7
|
userParticipation?: ClassicQuizParticipationBodyModel[];
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { CustomSpacingScale, CustomBorderRadius } from
|
|
2
|
-
import { BrandingColorsModel } from
|
|
3
|
-
import { CSSProperties } from
|
|
1
|
+
import { CustomSpacingScale, CustomBorderRadius } from '../../../../../common/src';
|
|
2
|
+
import { BrandingColorsModel } from 'fansunited-sdk-esm';
|
|
3
|
+
import { CSSProperties } from 'react';
|
|
4
|
+
|
|
4
5
|
interface StyleProps {
|
|
5
6
|
quizImage: string | null;
|
|
6
7
|
questionImage: string | null;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import { ClassicQuizFullModel, FansUnitedSDKModel } from
|
|
1
|
+
import { ClassicQuizFullModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
|
|
2
3
|
export declare const useClassicQuizById: (id: string, sdk: FansUnitedSDKModel) => ClassicQuizFullModel | null;
|
|
3
4
|
//# sourceMappingURL=useClassicQuizById.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const useEmbedCode: (embedCode: string, applyFilterScreen: boolean) => import(
|
|
1
|
+
export declare const useEmbedCode: (embedCode: string, applyFilterScreen: boolean) => import('react').RefObject<HTMLDivElement>;
|
|
2
2
|
//# sourceMappingURL=useEmbedCodeContainer.d.ts.map
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import { ClassicQuizUserParticipationModel, FansUnitedSDKModel } from
|
|
1
|
+
import { ClassicQuizUserParticipationModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
2
|
+
|
|
2
3
|
export declare const useMyParticipation: (id: string, sdk: FansUnitedSDKModel) => ClassicQuizUserParticipationModel[] | null;
|
|
3
4
|
//# sourceMappingURL=useMyParticipation.d.ts.map
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel } from
|
|
2
|
-
import { WidgetTemplate } from
|
|
1
|
+
import { ClassicQuizUserParticipationModel, ClassicQuizFullModel } from 'fansunited-sdk-esm';
|
|
2
|
+
import { WidgetTemplate } from '../../../common/src';
|
|
3
|
+
|
|
3
4
|
interface UseQuizScoreLogicProps {
|
|
4
5
|
summary: ClassicQuizUserParticipationModel;
|
|
5
6
|
totalTime: number;
|
package/src/index.d.ts
CHANGED
package/src/main.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { ClassicQuizPlayProps } from
|
|
2
|
-
import React from
|
|
1
|
+
import { ClassicQuizPlayProps } from '../../common/src';
|
|
2
|
+
import { default as React } from 'react';
|
|
3
|
+
|
|
3
4
|
declare const Main: React.FC<ClassicQuizPlayProps>;
|
|
4
5
|
export default Main;
|
|
5
6
|
//# sourceMappingURL=main.d.ts.map
|
package/src/main.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/main.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,oBAAoB,EAIrB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,QAAA,MAAM,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,
|
|
1
|
+
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../src/main.tsx"],"names":[],"mappings":"AAEA,OAAO,EACL,oBAAoB,EAIrB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,QAAA,MAAM,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAyFxC,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
package/src/types/types.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { LeadsOptions } from
|
|
2
|
-
import { ClassicQuizFullModel, ClassicQuizQuestionModel, FansUnitedSDKModel } from
|
|
1
|
+
import { LeadsOptions } from '../../../common/src';
|
|
2
|
+
import { ClassicQuizFullModel, ClassicQuizQuestionModel, FansUnitedSDKModel } from 'fansunited-sdk-esm';
|
|
3
|
+
|
|
3
4
|
/**
|
|
4
5
|
* Used as a general props for different widget state variants.
|
|
5
6
|
*/
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { Box, Typography } from "@mui/joy";
|
|
3
|
-
import { useBorderSize, useColors, useCornerRadius, useFontFamily, useSpacingScale, } from "@fansunited/common";
|
|
4
|
-
import { useTranslation } from "react-i18next";
|
|
5
|
-
const ClassicQuizNotFound = () => {
|
|
6
|
-
const { t } = useTranslation();
|
|
7
|
-
const mdBorderRadius = useCornerRadius().md;
|
|
8
|
-
const borderColor = useColors().secondaryContainer;
|
|
9
|
-
const surfaceColor = useColors().surface;
|
|
10
|
-
const borderSize = useBorderSize().size;
|
|
11
|
-
const border = borderSize + " solid " + borderColor;
|
|
12
|
-
const dangerColor = useColors().palette?.danger?.plainColor;
|
|
13
|
-
const textSecondary = useColors().textSecondary;
|
|
14
|
-
const spacingScale = useSpacingScale();
|
|
15
|
-
const primaryFontFamily = useFontFamily().primary;
|
|
16
|
-
const secondaryFontFamily = useFontFamily().secondary;
|
|
17
|
-
return (_jsxs(Box, { sx: {
|
|
18
|
-
display: "flex",
|
|
19
|
-
flexDirection: "column",
|
|
20
|
-
justifyContent: "center",
|
|
21
|
-
alignItems: "center",
|
|
22
|
-
width: "100%",
|
|
23
|
-
borderRadius: mdBorderRadius,
|
|
24
|
-
boxShadow: "md",
|
|
25
|
-
border,
|
|
26
|
-
background: surfaceColor,
|
|
27
|
-
minHeight: "300px",
|
|
28
|
-
padding: "32px 24px",
|
|
29
|
-
textAlign: "center",
|
|
30
|
-
}, children: [_jsx(Box, { sx: {
|
|
31
|
-
width: "80px",
|
|
32
|
-
height: "80px",
|
|
33
|
-
borderRadius: "50%",
|
|
34
|
-
backgroundColor: `${dangerColor}15`, // 15% opacity
|
|
35
|
-
display: "flex",
|
|
36
|
-
alignItems: "center",
|
|
37
|
-
justifyContent: "center",
|
|
38
|
-
marginBottom: "24px",
|
|
39
|
-
}, children: _jsx(Box, { sx: {
|
|
40
|
-
fontSize: "32px",
|
|
41
|
-
color: dangerColor,
|
|
42
|
-
fontWeight: "bold",
|
|
43
|
-
fontFamily: primaryFontFamily,
|
|
44
|
-
}, children: "?" }) }), _jsx(Typography, { level: "h4", sx: {
|
|
45
|
-
color: dangerColor,
|
|
46
|
-
marginBottom: spacingScale.xs,
|
|
47
|
-
fontWeight: "600",
|
|
48
|
-
fontFamily: primaryFontFamily,
|
|
49
|
-
}, children: t("classicQuiz.quizNotFound") }), _jsx(Typography, { level: "body-md", sx: {
|
|
50
|
-
color: textSecondary,
|
|
51
|
-
lineHeight: 1.5,
|
|
52
|
-
fontFamily: secondaryFontFamily,
|
|
53
|
-
}, children: t("classicQuiz.quizNotFoundDescription") })] }));
|
|
54
|
-
};
|
|
55
|
-
export default ClassicQuizNotFound;
|