github.com/Theta-Dev/Talon@v0.0.0-20211018130634-ff179e19fa9a/ui/menu/src/util/types.ts (about)

     1  export interface TalonData {
     2  	root_path: string
     3  	current_page: string | null
     4  	current_version: string
     5  	versions: {[key: string]: TalonVersion}
     6  	pages: {[key: string]: TalonPage}
     7  }
     8  
     9  export interface TalonPage {
    10  	name: string
    11  	path: string
    12  	color: string
    13  	visibility: TalonVisibility
    14  	image: string | undefined
    15  	source: TalonLink | undefined
    16  }
    17  
    18  export enum TalonVisibility {
    19  	FEATURED = "featured",
    20  	SEARCHABLE = "searchable",
    21  	HIDDEN = "hidden",
    22  }
    23  
    24  export interface TalonLink {
    25  	url: string
    26  	type: TalonLinkType
    27  }
    28  
    29  export enum TalonLinkType {
    30  	LINK = "link",
    31  	GIT = "git",
    32  	GITHUB = "github",
    33  	GITLAB = "gitlab",
    34  	GITEA = "gitea",
    35  	BITBUCKET = "bitbucket",
    36  }
    37  
    38  export interface TalonVersion {
    39  	date: string
    40  	name: string | undefined
    41  	user: string
    42  	tags: {[key: string]: string} | undefined
    43  }
    44  
    45  export interface Focusable {
    46  	focus(): void
    47  	blur(): void
    48  }
    49  
    50  export interface SvelteActionRes {
    51  	// eslint-disable-next-line @typescript-eslint/no-explicit-any
    52  	update?: (parameters: any) => void
    53  	destroy?: () => void
    54  }