update to 1.1.0 #1

Merged
crimsen merged 24 commits from develop into main 2024-10-08 13:27:05 +00:00
1 changed files with 7 additions and 5 deletions
Showing only changes of commit 131063dae8 - Show all commits

12
types/plugin.d.ts vendored
View File

@ -1,13 +1,17 @@
import type { RouteLocationRaw, RouteRecordRaw, RouteRecordName } from 'vue-router';
import type { Component } from '@vue/runtime-core';
/* This is some sort of PEP440 subset */
type Join<T extends unknown[], D extends string> =
T extends [] ? '' :
T extends [string | number | boolean | bigint] ? `${T[0]}` :
T extends [string | number | boolean | bigint, ...infer U] ? `${T[0]}${D}${Join<U, D>}` :
string;
type BVersion = Join<[number, number], '.'> | Join<[number, number, number], '.'>
type Version = BVersion | Join<[BVersion, string], '-'>
type BaseVersion = Join<[number, number], '.'> | Join<[number, number, number], '.'>
type PreRelease = Join<[["a"|"b"|"rc"], number], ".">
type PRVersion = BaseVersion | `${BaseVersion}${PreRelease}`
/** A PEP440 subset used to describe backend module versions */
export type PEP440Version = PRVersion | `${PRVersion}.dev${number}`
export namespace FG_Plugin {
/**
@ -22,10 +26,8 @@ export namespace FG_Plugin {
version: string;
/** Widgets provided by this plugin */
widgets: Widget[];
/** Other frontend modules needed for this plugin to work correctly */
requiredModules: [string, Version?][];
/** Backend modules needed for this plugin to work correctly */
requiredBackendModules: [string, Version?][];
requiredModules: [string, PEP440Version?][];
/** Menu entries for authenticated users */
innerRoutes?: MenuRoute[];
/** Public menu entries (without authentification) */