Skip to content

Commit

Permalink
Fix type-checks
Browse files Browse the repository at this point in the history
Ref: coreui/coreui-vue#295

Signed-off-by: Aurélien Bompard <[email protected]>
  • Loading branch information
abompard authored and renovate[bot] committed Oct 14, 2024
1 parent 379b03f commit 57651d8
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
4 changes: 2 additions & 2 deletions frontend/src/components/AdminSubHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ import { CNav, CNavItem } from "@coreui/vue";
<template>
<h1 class="border-bottom mb-5 pb-2">Admin Dashboard</h1>
<CNav variant="tabs" class="mb-2">
<CNavItem>
<CNavItem as="li">
<router-link to="/admin/disabled-rules" class="nav-link"
>Disabled Rules List</router-link
>
</CNavItem>
<CNavItem>
<CNavItem as="li">
<router-link to="/admin/user-rules" class="nav-link"
>User Rules</router-link
>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/LoginButton.vue
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ SPDX-License-Identifier: MIT
<CDropdownItem @click="doLogout()">{{ t("logout") }}</CDropdownItem>
</CDropdownMenu>
</CDropdown>
<CNavItem v-else>
<CNavItem as="li" v-else>
<CButton
@click.prevent="doLogin()"
component="a"
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/forms/MultiSelectAsyncDefaultInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ function handleChange(value: Option[]) {
:key="slotName"
v-slot:[slotName]="slotParams"
>
<component :is="slot" v-bind="slotParams" />
<!-- Not sure how to type slotParams properly -->
<component :is="slot" v-bind="slotParams as any" />
</template>
</Multiselect>
</template>
Expand Down
9 changes: 7 additions & 2 deletions frontend/src/forms/MultiSelectInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,11 @@ const props = defineProps<{ context: FormKitFrameworkContext }>();
const bindableProps = computed(() => getBindableProps(props.context));
const slots = computed(
() => props.context.slots as Partial<Multiselect["$slots"]>,
() =>
props.context.slots as Omit<
Partial<Multiselect["$slots"]>,
"multiplelabel" | "singlelabel"
>,
);
function handleChange(value: string) {
Expand All @@ -31,7 +35,8 @@ function handleChange(value: string) {
:key="slotName"
v-slot:[slotName]="slotParams"
>
<component :is="slot" v-bind="slotParams" />
<!-- Not sure how to type slotParams properly -->
<component :is="slot" v-bind="slotParams as any" />
</template>
</Multiselect>
</template>
Expand Down

0 comments on commit 57651d8

Please sign in to comment.