Skip to content

Commit

Permalink
Ran eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
noremacskich committed Oct 23, 2024
1 parent e348e5b commit 094f052
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
5 changes: 2 additions & 3 deletions client/src/components/expressions/CreateExpressionSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -82,14 +82,13 @@ const onSubmit = handleSubmit((values) => {
</script>

<template>

<div class="m-2">
<form @submit="onSubmit">
<InputTextWrapper v-model="name" field-name="Name" :error-text="errors.name" />
<EditorWrapper v-model="content" field-name="Content" :error-text="errors.content" />
<DropdownWrapper
v-model="sectionType" option-label="name" :options="sectionTypeOptions" field-name="Section Types" :show-skeleton="showOptionLoader"
:error-text="errors.sectionType"
v-model="sectionType" option-label="name" :options="sectionTypeOptions" field-name="Section Types" :show-skeleton="showOptionLoader"
:error-text="errors.sectionType"
/>
<div class="flex">
<div class="col-flex flex-grow-1">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ const deleteExpression = (event) => {
<div class="mb-2" v-html="props.sectionInfo.content" />
</div>
<div v-if="showCreate && showEdit">
<CreateExpressionSection :parent-id="props.sectionInfo.id" @cancel-event="toggleCreate" @added-section="passThroughAddedSection()"></CreateExpressionSection>
<CreateExpressionSection :parent-id="props.sectionInfo.id" @cancel-event="toggleCreate" @added-section="passThroughAddedSection()" />
</div>
</template>

Expand Down
4 changes: 2 additions & 2 deletions client/src/components/expressions/ExpressionBase.vue
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,10 @@ onBeforeRouteUpdate(async (to, from) => {
</template>
<template #content>
<article id="expression-body">
<ExpressionSection :sections="sections" :current-level="1" :show-skeleton="isLoading" :show-edit="showEdit" @refresh-list="fetchData(route.params.name)"/>
<ExpressionSection :sections="sections" :current-level="1" :show-skeleton="isLoading" :show-edit="showEdit" @refresh-list="fetchData(route.params.name)" />
<Button v-if="showEdit" label="Add Section" class="m-2" @click="toggleCreate" />
<div v-if="showCreate">
<CreateExpressionSection @cancel-event="toggleCreate" @added-section="fetchData(route.params.name)"></CreateExpressionSection>
<CreateExpressionSection @cancel-event="toggleCreate" @added-section="fetchData(route.params.name)" />
</div>
</article>
</template>
Expand Down
7 changes: 5 additions & 2 deletions client/src/components/expressions/ExpressionSection.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,12 @@ const props = defineProps({

<template>
<div v-for="(value) in props.sections" :key="value.id">
<EditExpressionSection :section-info="value" :current-level="currentLevel" :show-skeleton="showSkeleton" :show-edit="showEdit" @refresh-list="passThroughAddedSection"/>
<EditExpressionSection :section-info="value" :current-level="currentLevel" :show-skeleton="showSkeleton" :show-edit="showEdit" @refresh-list="passThroughAddedSection" />
<div>
<ExpressionSection v-if="value.subSections" :sections="value.subSections" :current-level="props.currentLevel + 1" :show-skeleton="showSkeleton" :show-edit="showEdit" @refresh-list="passThroughAddedSection"/>
<ExpressionSection
v-if="value.subSections" :sections="value.subSections" :current-level="props.currentLevel + 1" :show-skeleton="showSkeleton" :show-edit="showEdit"
@refresh-list="passThroughAddedSection"
/>
</div>
</div>
</template>

0 comments on commit 094f052

Please sign in to comment.