diff --git a/public/port-0.0.0-py3-none-any.whl b/public/port-0.0.0-py3-none-any.whl index 0e25e81a..4b6f4ac8 100644 Binary files a/public/port-0.0.0-py3-none-any.whl and b/public/port-0.0.0-py3-none-any.whl differ diff --git a/src/framework/processing/py/dist/port-0.0.0-py3-none-any.whl b/src/framework/processing/py/dist/port-0.0.0-py3-none-any.whl index 0e25e81a..4b6f4ac8 100644 Binary files a/src/framework/processing/py/dist/port-0.0.0-py3-none-any.whl and b/src/framework/processing/py/dist/port-0.0.0-py3-none-any.whl differ diff --git a/src/framework/processing/worker_engine.ts b/src/framework/processing/worker_engine.ts index 4dd3d25d..70f03dda 100755 --- a/src/framework/processing/worker_engine.ts +++ b/src/framework/processing/worker_engine.ts @@ -1,5 +1,5 @@ import { CommandHandler, ProcessingEngine } from '../types/modules' -import { CommandSystemDonate, CommandUIRender, isCommand, Response } from '../types/commands' +import { CommandSystemDonate, isCommand, Response } from '../types/commands' export default class WorkerProcessingEngine implements ProcessingEngine { sessionId: String @@ -60,9 +60,8 @@ export default class WorkerProcessingEngine implements ProcessingEngine { console.log('[WorkerProcessingEngine] started') const waitForInitialization: Promise = this.waitForInitialization() - const waitForSplashScreen: Promise = this.waitForSplashScreen() - Promise.all([waitForInitialization, waitForSplashScreen]).then( + waitForInitialization.then( () => { this.firstRunCycle() }, () => {} ) @@ -75,23 +74,6 @@ export default class WorkerProcessingEngine implements ProcessingEngine { }) } - async waitForSplashScreen (): Promise { - return await new Promise((resolve) => { - this.resolveContinue = resolve - this.renderSplashScreen() - }) - } - - renderSplashScreen (): void { - const command: CommandUIRender = { __type__: 'CommandUIRender', page: { __type__: 'PropsUIPageSplashScreen' } } - if (isCommand(command)) { - this.commandHandler.onCommand(command).then( - (_response) => this.resolveContinue(), - () => {} - ) - } - } - firstRunCycle (): void { this.worker.postMessage({ eventType: 'firstRunCycle', sessionId: this.sessionId }) } diff --git a/src/framework/types/pages.ts b/src/framework/types/pages.ts index d2107e7e..f89a8553 100644 --- a/src/framework/types/pages.ts +++ b/src/framework/types/pages.ts @@ -9,7 +9,6 @@ export type PropsUIPage = export function isPropsUIPage (arg: any): arg is PropsUIPage { return ( - isPropsUIPageSplashScreen(arg) || isPropsUIPageDonation(arg) || isPropsUIPageEnd(arg) ) @@ -18,9 +17,6 @@ export function isPropsUIPage (arg: any): arg is PropsUIPage { export interface PropsUIPageSplashScreen { __type__: 'PropsUIPageSplashScreen' } -export function isPropsUIPageSplashScreen (arg: any): arg is PropsUIPageSplashScreen { - return isInstanceOf(arg, 'PropsUIPageSplashScreen', []) -} export interface PropsUIPageDonation { __type__: 'PropsUIPageDonation' diff --git a/src/framework/visualisation/react/factory.tsx b/src/framework/visualisation/react/factory.tsx index b76d21d1..94591eca 100644 --- a/src/framework/visualisation/react/factory.tsx +++ b/src/framework/visualisation/react/factory.tsx @@ -1,9 +1,8 @@ import { EndPage } from './ui/pages/end_page' -import { isPropsUIPageEnd, isPropsUIPageDonation, PropsUIPage, isPropsUIPageSplashScreen } from '../../types/pages' +import { isPropsUIPageEnd, isPropsUIPageDonation, PropsUIPage } from '../../types/pages' import { DonationPage } from './ui/pages/donation_page' import { Payload } from '../../types/commands' -import { SplashScreen } from './ui/pages/splash_screen' export interface ReactFactoryContext { locale: string @@ -12,9 +11,6 @@ export interface ReactFactoryContext { export default class ReactFactory { createPage (page: PropsUIPage, context: ReactFactoryContext): JSX.Element { - if (isPropsUIPageSplashScreen(page)) { - return - } if (isPropsUIPageEnd(page)) { return } diff --git a/src/framework/visualisation/react/ui/pages/donation_page.tsx b/src/framework/visualisation/react/ui/pages/donation_page.tsx index f4f45cd0..becee83f 100644 --- a/src/framework/visualisation/react/ui/pages/donation_page.tsx +++ b/src/framework/visualisation/react/ui/pages/donation_page.tsx @@ -6,24 +6,18 @@ import { Translatable } from '../../../../types/elements' import { PropsUIPageDonation } from '../../../../types/pages' import { isPropsUIPromptConfirm, isPropsUIPromptConsentForm, isPropsUIPromptFileInput, isPropsUIPromptRadioInput } from '../../../../types/prompts' import { ReactFactoryContext } from '../../factory' -import { ForwardButton } from '../elements/button' import { Title1 } from '../elements/text' import { Confirm } from '../prompts/confirm' import { ConsentForm } from '../prompts/consent_form' import { FileInput } from '../prompts/file_input' import { RadioInput } from '../prompts/radio_input' -import { Footer } from './templates/footer' -import { Sidebar } from './templates/sidebar' -import LogoSvg from '../../../../../assets/images/logo.svg' import { Page } from './templates/page' -import { Progress } from '../elements/progress' -import { Instructions } from '../elements/instructions' type Props = Weak & ReactFactoryContext export const DonationPage = (props: Props): JSX.Element => { - const { title, forwardButton } = prepareCopy(props) - const { platform, locale, resolve } = props + const { title } = prepareCopy(props) + const { locale } = props function renderBody (props: Props): JSX.Element { const context = { locale: locale, resolve: props.resolve } @@ -43,31 +37,6 @@ export const DonationPage = (props: Props): JSX.Element => { throw new TypeError('Unknown body type') } - function handleSkip (): void { - resolve?.({ __type__: 'PayloadFalse', value: false }) - } - - const footer: JSX.Element = ( -