From 44506ad0cc9afe73420f385953021fd32d10d3ed Mon Sep 17 00:00:00 2001 From: Manuel Odelain Date: Tue, 26 Mar 2024 10:45:12 +0100 Subject: [PATCH] feat: export interface for useRoadizBlock props --- composables/use-roadiz-block.ts | 12 +++++++++--- types/roadiz.d.ts | 8 -------- 2 files changed, 9 insertions(+), 11 deletions(-) delete mode 100644 types/roadiz.d.ts diff --git a/composables/use-roadiz-block.ts b/composables/use-roadiz-block.ts index c55a222..26b5459 100644 --- a/composables/use-roadiz-block.ts +++ b/composables/use-roadiz-block.ts @@ -1,8 +1,14 @@ -import type { RoadizNodesSources } from '@roadiz/types' -import type { RoadizBlockProps } from '~/types/roadiz' +import type { RoadizNodesSources, RoadizWalker } from '@roadiz/types' + +export interface UseRoadizBlockProps { + walker: RoadizWalker + index: number + blocks?: RoadizWalker[] + numBlocks?: number | string +} export interface UseRoadizBlockOptions { - props: RoadizBlockProps + props: UseRoadizBlockProps } export function useRoadizBlock({ props }: UseRoadizBlockOptions) { diff --git a/types/roadiz.d.ts b/types/roadiz.d.ts deleted file mode 100644 index 9887dfa..0000000 --- a/types/roadiz.d.ts +++ /dev/null @@ -1,8 +0,0 @@ -import type { RoadizWalker } from '@roadiz/types' - -interface RoadizBlockProps { - walker: RoadizWalker - index: number - blocks?: RoadizWalker[] - numBlocks?: number | string -}