Refactor app architecture and clean local artifacts
This commit is contained in:
@@ -0,0 +1,153 @@
|
||||
<script setup lang="ts">
|
||||
import HomeAccountAndPrivacyModals from './HomeAccountAndPrivacyModals.vue'
|
||||
import HomeArchiveModal from './HomeArchiveModal.vue'
|
||||
import HomeInteractionModal from './HomeInteractionModal.vue'
|
||||
import type {
|
||||
HomeArchiveYearItem,
|
||||
HomeCategoryListItem,
|
||||
HomeNomineeListItem,
|
||||
HomeSelectedArchive,
|
||||
HomeSelectionOption,
|
||||
} from './homeModalTypes'
|
||||
|
||||
defineProps<{
|
||||
modalOpen: boolean
|
||||
submitted: boolean
|
||||
notSubmitted: boolean
|
||||
formError: string
|
||||
successTitle: string
|
||||
successText: string
|
||||
closeModal: () => void
|
||||
stop: (event: Event) => void
|
||||
isShow: boolean
|
||||
isPicker: boolean
|
||||
isVote: boolean
|
||||
isClip: boolean
|
||||
nominationPhase: boolean
|
||||
publicStreamUrl: string
|
||||
formatShowDate: () => string
|
||||
submitReminder: () => void
|
||||
pickerTitle: string
|
||||
pickerSubtitle: string
|
||||
catList: HomeCategoryListItem[]
|
||||
activeCatName: string
|
||||
noms: HomeNomineeListItem[]
|
||||
voteCount: number
|
||||
totalCats: number
|
||||
canSubmitVote: boolean
|
||||
submitVote: () => Promise<void> | void
|
||||
submitNomination: () => Promise<void> | void
|
||||
submitting: boolean
|
||||
onClipCatChange: (event: Event) => void
|
||||
catOptions: HomeSelectionOption[]
|
||||
clipNomOptions: HomeSelectionOption[]
|
||||
clipDsgvo: boolean
|
||||
clipDsgvoChange: () => void
|
||||
onOpenPrivacy: () => void
|
||||
canSubmitClip: boolean
|
||||
clipSubmitStyle: string
|
||||
submitClip: () => Promise<void> | void
|
||||
archiveModalOpen: boolean
|
||||
archiveYears: HomeArchiveYearItem[]
|
||||
selectedArchive: HomeSelectedArchive
|
||||
onCloseArchive: () => void
|
||||
archiveModalStop: (event: Event) => void
|
||||
setArchiveYear: (year: number) => Promise<void>
|
||||
archiveYearButtonStyle: (active: boolean) => string
|
||||
winnerPlatformStyle: (url: string) => string
|
||||
winnerPlatformKey: (url: string) => string
|
||||
winnerPlatformLabel: (url: string) => string
|
||||
privacyModalOpen: boolean
|
||||
privacyContentBlocks: string[]
|
||||
onClosePrivacy: () => void
|
||||
privacyModalStop: (event: Event) => void
|
||||
accountModalOpen: boolean
|
||||
twitchUser: string
|
||||
role: string
|
||||
deleteNotConfirm: boolean
|
||||
deleteConfirm: boolean
|
||||
accountActionError: string
|
||||
authLoading: boolean
|
||||
onCloseAccount: () => void
|
||||
accountModalStop: (event: Event) => void
|
||||
onLogout: () => Promise<void> | void
|
||||
onRequestDelete: () => void
|
||||
onCancelDelete: () => void
|
||||
onConfirmDelete: () => Promise<void> | void
|
||||
}>()
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<HomeInteractionModal
|
||||
:modal-open="modalOpen"
|
||||
:submitted="submitted"
|
||||
:not-submitted="notSubmitted"
|
||||
:form-error="formError"
|
||||
:success-title="successTitle"
|
||||
:success-text="successText"
|
||||
:close-modal="closeModal"
|
||||
:stop="stop"
|
||||
:is-show="isShow"
|
||||
:is-picker="isPicker"
|
||||
:is-vote="isVote"
|
||||
:is-clip="isClip"
|
||||
:nomination-phase="nominationPhase"
|
||||
:public-stream-url="publicStreamUrl"
|
||||
:format-show-date="formatShowDate"
|
||||
:submit-reminder="submitReminder"
|
||||
:picker-title="pickerTitle"
|
||||
:picker-subtitle="pickerSubtitle"
|
||||
:cat-list="catList"
|
||||
:active-cat-name="activeCatName"
|
||||
:noms="noms"
|
||||
:vote-count="voteCount"
|
||||
:total-cats="totalCats"
|
||||
:can-submit-vote="canSubmitVote"
|
||||
:submit-vote="submitVote"
|
||||
:submit-nomination="submitNomination"
|
||||
:submitting="submitting"
|
||||
:on-clip-cat-change="onClipCatChange"
|
||||
:cat-options="catOptions"
|
||||
:clip-nom-options="clipNomOptions"
|
||||
:clip-dsgvo="clipDsgvo"
|
||||
:clip-dsgvo-change="clipDsgvoChange"
|
||||
:on-open-privacy="onOpenPrivacy"
|
||||
:can-submit-clip="canSubmitClip"
|
||||
:clip-submit-style="clipSubmitStyle"
|
||||
:submit-clip="submitClip"
|
||||
/>
|
||||
|
||||
<HomeArchiveModal
|
||||
:archive-modal-open="archiveModalOpen"
|
||||
:archive-years="archiveYears"
|
||||
:selected-archive="selectedArchive"
|
||||
:on-close-archive="onCloseArchive"
|
||||
:archive-modal-stop="archiveModalStop"
|
||||
:set-archive-year="setArchiveYear"
|
||||
:archive-year-button-style="archiveYearButtonStyle"
|
||||
:winner-platform-style="winnerPlatformStyle"
|
||||
:winner-platform-key="winnerPlatformKey"
|
||||
:winner-platform-label="winnerPlatformLabel"
|
||||
/>
|
||||
|
||||
<HomeAccountAndPrivacyModals
|
||||
:privacy-modal-open="privacyModalOpen"
|
||||
:privacy-content-blocks="privacyContentBlocks"
|
||||
:on-close-privacy="onClosePrivacy"
|
||||
:privacy-modal-stop="privacyModalStop"
|
||||
:account-modal-open="accountModalOpen"
|
||||
:twitch-user="twitchUser"
|
||||
:role="role"
|
||||
:delete-not-confirm="deleteNotConfirm"
|
||||
:delete-confirm="deleteConfirm"
|
||||
:account-action-error="accountActionError"
|
||||
:auth-loading="authLoading"
|
||||
:on-close-account="onCloseAccount"
|
||||
:account-modal-stop="accountModalStop"
|
||||
:on-open-privacy="onOpenPrivacy"
|
||||
:on-logout="onLogout"
|
||||
:on-request-delete="onRequestDelete"
|
||||
:on-cancel-delete="onCancelDelete"
|
||||
:on-confirm-delete="onConfirmDelete"
|
||||
/>
|
||||
</template>
|
||||
Reference in New Issue
Block a user