diff --git a/frontend/src/lib/editor.svelte b/frontend/src/lib/editor.svelte index eda9e46..53d4cc4 100644 --- a/frontend/src/lib/editor.svelte +++ b/frontend/src/lib/editor.svelte @@ -11,8 +11,6 @@ import SettingsCard from '$lib/editor/settings-card.svelte'; import QuizCard from '$lib/editor/card.svelte'; import Spinner from './Spinner.svelte'; - import { elementSelection } from '$lib/stores.js'; - import ElementSelection from '$lib/editor/slides/element_selection.svelte'; let schemaInvalid = false; let yupErrorMessage = ''; @@ -189,7 +187,3 @@ {/await} - -{#if $elementSelection.data === null} - -{/if} diff --git a/frontend/src/lib/editor/card.svelte b/frontend/src/lib/editor/card.svelte index a79b74f..03b99ea 100644 --- a/frontend/src/lib/editor/card.svelte +++ b/frontend/src/lib/editor/card.svelte @@ -12,7 +12,6 @@ import Spinner from '../Spinner.svelte'; import { createTippy } from 'svelte-tippy'; import { getLocalization } from '$lib/i18n'; - import Slide from './slide.svelte'; const { t } = getLocalization(); @@ -52,9 +51,9 @@ */ -
+
-
+
- {#if data.questions[selected_question].time} -
-
- {#await import('$lib/inline-editor.svelte')} - - {:then c} -
- -
- {/await} -
- {#if data.questions[selected_question].image != undefined && data.questions[selected_question].image !== ''} -
- not available { - data.questions[selected_question].image = ''; - }} - /> -
- {:else if pow_data === undefined} - +
+ {#await import('$lib/inline-editor.svelte')} + + {:then c} +
- - - {:else} - {#await import('$lib/editor/uploader.svelte')} - - {:then c} - {/await} - {/if} -
-
- - - -
-
-
- -
-
- {#if data.questions[selected_question].type === QuizQuestionType.ABCD} - {#await import('$lib/editor/ABCDEditorPart.svelte')} - - {:then c} - - {/await} - {:else if data.questions[selected_question].type === QuizQuestionType.RANGE} - - {:else if data.questions[selected_question].type === QuizQuestionType.VOTING} - {#await import('$lib/editor/VotingEditorPart.svelte')} - - {:then c} - - {/await} - {/if} -
-

- {$t('editor_page.right_click_to_delete')} -

+ {/await}
- {:else} - - {/if} + {#if data.questions[selected_question].image != undefined && data.questions[selected_question].image !== ''} +
+ not available { + data.questions[selected_question].image = ''; + }} + /> +
+ {:else if pow_data === undefined} + + + + {:else} + {#await import('$lib/editor/uploader.svelte')} + + {:then c} + + {/await} + {/if} +
+
+ + + + +
+
+
+ +
+
+ {#if data.questions[selected_question].type === QuizQuestionType.ABCD} + {#await import('$lib/editor/ABCDEditorPart.svelte')} + + {:then c} + + {/await} + {:else if data.questions[selected_question].type === QuizQuestionType.RANGE} + + {:else if data.questions[selected_question].type === QuizQuestionType.VOTING} + {#await import('$lib/editor/VotingEditorPart.svelte')} + + {:then c} + + {/await} + {/if} +
+

{$t('editor_page.right_click_to_delete')}

+
diff --git a/frontend/src/lib/editor/sidebar.svelte b/frontend/src/lib/editor/sidebar.svelte index 0b0aa6f..c575606 100644 --- a/frontend/src/lib/editor/sidebar.svelte +++ b/frontend/src/lib/editor/sidebar.svelte @@ -242,7 +242,7 @@
{/each}
-
diff --git a/frontend/src/lib/editor/slide.svelte b/frontend/src/lib/editor/slide.svelte deleted file mode 100644 index 97063f1..0000000 --- a/frontend/src/lib/editor/slide.svelte +++ /dev/null @@ -1,205 +0,0 @@ - - - -
-
- {#each elements as el, i} -
- - - - - {#if el.type === ElementTypes.Text} -

Text

- - {:else if el.type === ElementTypes.Headline} -

Headline

- - {/if} -
- {/each} -
-
- {#each ghost_elements as el, i} -
- -
- {/each} -
-
diff --git a/frontend/src/lib/editor/slides/element_selection.svelte b/frontend/src/lib/editor/slides/element_selection.svelte deleted file mode 100644 index 2639ac5..0000000 --- a/frontend/src/lib/editor/slides/element_selection.svelte +++ /dev/null @@ -1,77 +0,0 @@ - - - -
-
-
-

Select the element you want to add

-
-
    - {#each element_list as el} -
  • { - elementSelection.set({ data: el.type }); - }} - > -
    -

    {el.name}

    -

    {el.description}

    -
    - {el.shortcut} -
  • - {/each} -
-
-
diff --git a/frontend/src/lib/editor/slides/types/headline.svelte b/frontend/src/lib/editor/slides/types/headline.svelte deleted file mode 100644 index 2272baf..0000000 --- a/frontend/src/lib/editor/slides/types/headline.svelte +++ /dev/null @@ -1,10 +0,0 @@ - - - - diff --git a/frontend/src/lib/editor/slides/types/text.svelte b/frontend/src/lib/editor/slides/types/text.svelte deleted file mode 100644 index 6990f86..0000000 --- a/frontend/src/lib/editor/slides/types/text.svelte +++ /dev/null @@ -1,16 +0,0 @@ - - - - - -