mirror of
https://github.com/johndoe6345789/metabuilder.git
synced 2026-04-28 15:54:56 +00:00
Fix remaining level-types imports and create missing type files
Co-authored-by: johndoe6345789 <224850594+johndoe6345789@users.noreply.github.com>
This commit is contained in:
18
frontends/nextjs/src/lib/db/components/types.ts
Normal file
18
frontends/nextjs/src/lib/db/components/types.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
export interface ComponentConfig {
|
||||
id: string
|
||||
componentId: string
|
||||
props: Record<string, unknown>
|
||||
styles: Record<string, unknown>
|
||||
}
|
||||
|
||||
export interface ComponentNode {
|
||||
id: string
|
||||
name: string
|
||||
type: string
|
||||
}
|
||||
|
||||
export interface ComponentHierarchy {
|
||||
id: string
|
||||
parentId?: string | null
|
||||
childrenIds?: string[]
|
||||
}
|
||||
12
frontends/nextjs/src/lib/db/css-classes/types.ts
Normal file
12
frontends/nextjs/src/lib/db/css-classes/types.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
export interface CssCategory {
|
||||
id?: string
|
||||
name: string
|
||||
description?: string | null
|
||||
}
|
||||
|
||||
export interface CssClass {
|
||||
id?: string
|
||||
categoryId: string
|
||||
name: string
|
||||
className: string
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { AppConfiguration } from '../../../types/level-types'
|
||||
import type { AppConfiguration } from '@/lib/types/level-types'
|
||||
|
||||
export const buildDefaultAppConfig = (): AppConfiguration => ({
|
||||
id: 'app_001',
|
||||
|
||||
6
frontends/nextjs/src/lib/db/dropdown-configs/types.ts
Normal file
6
frontends/nextjs/src/lib/db/dropdown-configs/types.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
export interface DropdownConfig {
|
||||
id: string
|
||||
name: string
|
||||
options: Array<{ label: string; value: string }>
|
||||
defaultValue?: string | null
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
* Retrieves the application configuration from database
|
||||
*/
|
||||
|
||||
import type { AppConfiguration } from '../../../types/level-types'
|
||||
import type { AppConfiguration } from '@/lib/types/level-types'
|
||||
import { prisma } from '../../prisma'
|
||||
|
||||
/**
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Saves the application configuration to database
|
||||
*/
|
||||
|
||||
import type { AppConfiguration } from '../../../types/level-types'
|
||||
import type { AppConfiguration } from '@/lib/types/level-types'
|
||||
import { prisma } from '../../prisma'
|
||||
|
||||
/**
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Adds a new comment to database
|
||||
*/
|
||||
|
||||
import type { Comment } from '../../../types/level-types'
|
||||
import type { Comment } from '@/lib/types/level-types'
|
||||
import { prisma } from '../../prisma'
|
||||
|
||||
/**
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Retrieves all comments from database
|
||||
*/
|
||||
|
||||
import type { Comment } from '../../../types/level-types'
|
||||
import type { Comment } from '@/lib/types/level-types'
|
||||
import { prisma } from '../../prisma'
|
||||
|
||||
/**
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Replaces all comments in database
|
||||
*/
|
||||
|
||||
import type { Comment } from '../../../types/level-types'
|
||||
import type { Comment } from '@/lib/types/level-types'
|
||||
import { prisma } from '../../prisma'
|
||||
|
||||
/**
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Updates an existing comment
|
||||
*/
|
||||
|
||||
import type { Comment } from '../../../types/level-types'
|
||||
import type { Comment } from '@/lib/types/level-types'
|
||||
import { prisma } from '../../prisma'
|
||||
|
||||
type CommentUpdateData = {
|
||||
|
||||
Reference in New Issue
Block a user