Skip to content

Commit 75625e5

Browse files
guerganachukarave
authored andcommitted
Fix indentation in Home Page (#803)
1 parent 39cb979 commit 75625e5

File tree

1 file changed

+43
-43
lines changed

1 file changed

+43
-43
lines changed

resources/js/Pages/Home.vue

Lines changed: 43 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -99,58 +99,58 @@
9999
</template>
100100

101101
<script setup lang="ts">
102-
import { Head as InertiaHead, usePage } from '@inertiajs/inertia-vue3';
103-
import { useStore } from '../store';
104-
import { CdxDialog, CdxButton, CdxIcon, CdxMessage } from "@wikimedia/codex";
105-
import { cdxIconDie, cdxIconInfo } from '@wikimedia/codex-icons';
106-
import ItemIdSearchTextarea from '../Components/ItemIdSearchTextarea.vue';
107-
import { ref, computed } from 'vue';
108-
import type { Ref } from 'vue';
109-
import { Inertia } from '@inertiajs/inertia';
110-
111-
interface ErrorMessages {
112-
[ key : string ] : string
113-
}
102+
import { Head as InertiaHead, usePage } from '@inertiajs/inertia-vue3';
103+
import { useStore } from '../store';
104+
import { CdxDialog, CdxButton, CdxIcon, CdxMessage } from "@wikimedia/codex";
105+
import { cdxIconDie, cdxIconInfo } from '@wikimedia/codex-icons';
106+
import ItemIdSearchTextarea from '../Components/ItemIdSearchTextarea.vue';
107+
import { ref, computed } from 'vue';
108+
import type { Ref } from 'vue';
109+
import { Inertia } from '@inertiajs/inertia';
110+
111+
interface ErrorMessages {
112+
[ key : string ] : string
113+
}
114114
115-
interface FlashMessages {
116-
errors : { [ key : string ] : string }
117-
}
115+
interface FlashMessages {
116+
errors : { [ key : string ] : string }
117+
}
118118
119-
const textarea = ref<InstanceType<typeof ItemIdSearchTextarea> | null>(null);
120-
const store = useStore();
121-
const page = usePage();
122-
const textareaInputValue: Ref<string> = ref(store.lastSearchedIds);
119+
const textarea = ref<InstanceType<typeof ItemIdSearchTextarea> | null>(null);
120+
const store = useStore();
121+
const page = usePage();
122+
const textareaInputValue: Ref<string> = ref(store.lastSearchedIds);
123+
const faqDialog = ref(false);
123124
124-
const faqDialog = ref(false);
125-
const serversideValidationError = computed<boolean>(() => {
126-
const errors = page.props.value.errors as ErrorMessages;
127-
return errors && Object.keys(errors).length > 0;
128-
});
125+
const serversideValidationError = computed<boolean>(() => {
126+
const errors = page.props.value.errors as ErrorMessages;
127+
return errors && Object.keys(errors).length > 0;
128+
});
129129
130-
const unexpectedError = computed<string>(() => {
131-
const flashMessages = page.props.value.flash as FlashMessages;
132-
return (flashMessages.errors && flashMessages.errors.unexpected);
133-
});
130+
const unexpectedError = computed<string>(() => {
131+
const flashMessages = page.props.value.flash as FlashMessages;
132+
return (flashMessages.errors && flashMessages.errors.unexpected);
133+
});
134134
135-
const loading = computed<boolean>(() => {
136-
return (store.loading);
137-
});
135+
const loading = computed<boolean>(() => {
136+
return (store.loading);
137+
});
138138
139-
function send(): void{
140-
(textarea as InstanceType<typeof ItemIdSearchTextarea>).value.validate();
139+
function send(): void{
140+
(textarea as InstanceType<typeof ItemIdSearchTextarea>).value.validate();
141141
142-
if((textarea as InstanceType<typeof ItemIdSearchTextarea>).value.validationError) {
143-
return;
144-
}
145-
store.saveSearchedIds( textareaInputValue.value );
146-
Inertia.get( '/results',
147-
{ ids: (textarea as InstanceType<typeof ItemIdSearchTextarea>).value.serializeInput() }
148-
);
142+
if((textarea as InstanceType<typeof ItemIdSearchTextarea>).value.validationError) {
143+
return;
149144
}
145+
store.saveSearchedIds( textareaInputValue.value );
146+
Inertia.get( '/results',
147+
{ ids: (textarea as InstanceType<typeof ItemIdSearchTextarea>).value.serializeInput() }
148+
);
149+
}
150150
151-
function showRandom(): void{
152-
Inertia.get( '/random' );
153-
}
151+
function showRandom(): void{
152+
Inertia.get( '/random' );
153+
}
154154
</script>
155155

156156
<style lang="scss">

0 commit comments

Comments
 (0)