plugins

package module
v0.0.0-...-0c5cef1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2023 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Plugin

type Plugin struct {
	// Plugin Manifest
	Name        string `json:"name"`
	PackageID   string `json:"pkg"`
	Description string `json:"description"`
	Tags        string `json:"tags"`
	Author      string `json:"author"`
	Version     string `json:"version"`

	// Plugin Assets
	Assets *PluginAssets `json:"assets"`

	// Plugin Hooks
	Setup   func(p *Plugin, router gin.IRouter) `json:"-"`
	Migrate func(datasource *gorm.DB)           `json:"-"`
}

Plugin to description the plugin information and what to do and need what Also define some configuration settings for loader and web-injector to use

type PluginAssets

type PluginAssets struct {
	Locale map[string]any `json:"-"`

	Apps []WebApp `json:"-"`
}

type WebApp

type WebApp struct {
	RootElement        string           `json:"el"`
	DisplayOnDesktop   bool             `json:"shortcut"`
	DisplayOnLaunchpad bool             `json:"display"`
	ID                 string           `json:"id"`
	Icon               string           `json:"icon"`
	Name               string           `json:"name"`
	Descriptions       string           `json:"descriptions"`
	WindowOptions      WebWindowOptions `json:"window"`
	Uri                string           `json:"uri"`
	Authorized         bool             `json:"authorized"`
	Perms              []string         `json:"permissions"`
	Script             string           `json:"-"`
	Style              string           `json:"-"`
	PackageID          string           `json:"pkg"`
}

type WebWindowOptions

type WebWindowOptions struct {
	X         int            `json:"x"`
	Y         int            `json:"y"`
	Width     int            `json:"w"`
	Height    int            `json:"h"`
	MinWidth  int            `json:"minW"`
	MinHeight int            `json:"minH"`
	MaxWidth  int            `json:"maxW"`
	MaxHeight int            `json:"maxH"`
	Resizable bool           `json:"resizable"`
	Closeable bool           `json:"closeable"`
	Meta      map[string]any `json:"meta"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL