forked from forkanization/Proxmox-arm64
Merge remote-tracking branch 'upstream/main'
This commit is contained in:
@@ -1,18 +1,18 @@
|
||||
import { Category } from "./types";
|
||||
import type { Category } from "./types";
|
||||
|
||||
export const fetchCategories = async () => {
|
||||
export async function fetchCategories() {
|
||||
const response = await fetch("api/categories");
|
||||
if (!response.ok) {
|
||||
throw new Error(`Failed to fetch categories: ${response.statusText}`);
|
||||
}
|
||||
const categories: Category[] = await response.json();
|
||||
return categories;
|
||||
};
|
||||
}
|
||||
|
||||
export const fetchVersions = async () => {
|
||||
export async function fetchVersions() {
|
||||
const response = await fetch(`api/versions`);
|
||||
if (!response.ok) {
|
||||
throw new Error(`Failed to fetch versions: ${response.statusText}`);
|
||||
throw new Error(`Failed to fetch versions: ${response.statusText}`);
|
||||
}
|
||||
return response.json();
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { AlertColors } from "@/config/siteConfig";
|
||||
import type { AlertColors } from "@/config/site-config";
|
||||
|
||||
export type Script = {
|
||||
name: string;
|
||||
@@ -49,18 +49,18 @@ export type Metadata = {
|
||||
categories: Category[];
|
||||
};
|
||||
|
||||
export interface Version {
|
||||
export type Version = {
|
||||
name: string;
|
||||
slug: string;
|
||||
}
|
||||
};
|
||||
|
||||
export interface OperatingSystem {
|
||||
export type OperatingSystem = {
|
||||
name: string;
|
||||
versions: Version[];
|
||||
}
|
||||
};
|
||||
|
||||
export interface AppVersion {
|
||||
export type AppVersion = {
|
||||
name: string;
|
||||
version: string;
|
||||
date: Date;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import { clsx, type ClassValue } from "clsx";
|
||||
import type { ClassValue } from "clsx";
|
||||
|
||||
import { twMerge } from "tailwind-merge";
|
||||
import { clsx } from "clsx";
|
||||
|
||||
export function cn(...inputs: ClassValue[]) {
|
||||
return twMerge(clsx(inputs));
|
||||
|
||||
Reference in New Issue
Block a user