Documentation
¶
Index ¶
- Variables
- func InitOverridesConfig()
- type Categories
- type Category
- type IconExtra
- type IconSource
- type IconURL
- type Item
- type ItemConfig
- type OverrideConfig
- func (c *OverrideConfig) GetOverride(item *Item) *Item
- func (c *OverrideConfig) HideItems(keys ...string)
- func (c *OverrideConfig) OverrideItem(alias string, override *ItemConfig)
- func (c *OverrideConfig) OverrideItems(items map[string]*ItemConfig)
- func (c *OverrideConfig) SetCategoryOrder(key string, value int)
- func (c *OverrideConfig) UnhideItems(keys ...string)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidIconURL = E.New("invalid icon url")
View Source
var PredefinedCategories = map[string]string{
"sonarr": "Torrenting",
"radarr": "Torrenting",
"bazarr": "Torrenting",
"lidarr": "Torrenting",
"readarr": "Torrenting",
"prowlarr": "Torrenting",
"watcharr": "Torrenting",
"qbittorrent": "Torrenting",
"qbit": "Torrenting",
"qbt": "Torrenting",
"transmission": "Torrenting",
"jellyfin": "Media",
"jellyseerr": "Media",
"emby": "Media",
"plex": "Media",
"navidrome": "Media",
"immich": "Media",
"tautulli": "Media",
"nextcloud": "Media",
"invidious": "Media",
"uptime": "Monitoring",
"uptime-kuma": "Monitoring",
"prometheus": "Monitoring",
"grafana": "Monitoring",
"netdata": "Monitoring",
"changedetection.io": "Monitoring",
"changedetection": "Monitoring",
"influxdb": "Monitoring",
"influx": "Monitoring",
"adguardhome": "Networking",
"adgh": "Networking",
"adg": "Networking",
"pihole": "Networking",
"flaresolverr": "Networking",
"homebridge": "Home Automation",
"home-assistant": "Home Automation",
"dockge": "Container Management",
"portainer-ce": "Container Management",
"portainer-be": "Container Management",
"logs": "Container Management",
"dozzle": "Container Management",
"rss": "RSS",
"rsshub": "RSS",
"rss-bridge": "RSS",
"miniflux": "RSS",
"freshrss": "RSS",
"paperless": "Documents",
"paperless-ngx": "Documents",
"s-pdf": "Documents",
"stirling-pdf": "Documents",
"minio": "Storage",
"filebrowser": "Storage",
"rclone": "Storage",
}
PredefinedCategories by alias or docker image name.
Functions ¶
func InitOverridesConfig ¶
func InitOverridesConfig()
Types ¶
type Categories ¶
func NewHomePageConfig ¶
func NewHomePageConfig() Categories
func (Categories) Add ¶
func (c Categories) Add(item *Item)
func (*Categories) Clear ¶
func (c *Categories) Clear()
type IconSource ¶
type IconSource int
const ( IconSourceAbsolute IconSource = iota IconSourceRelative IconSourceWalkXCode IconSourceSelfhSt )
type IconURL ¶
type IconURL struct { Value string `json:"value"` FullValue string `json:"full_value"` IconSource `json:"source"` Extra *IconExtra `json:"extra"` }
func NewSelfhStIconURL ¶
func NewWalkXCodeIconURL ¶
func (*IconURL) HasIcon ¶
HasIcon checks if the icon referenced by the IconURL exists in the cache based on its source. Returns false if the icon does not exist for IconSourceSelfhSt or IconSourceWalkXCode, otherwise returns true.
func (*IconURL) MarshalText ¶
func (*IconURL) UnmarshalText ¶
UnmarshalText implements encoding.TextUnmarshaler.
type Item ¶
type Item struct { *ItemConfig Alias string `json:"alias"` // proxy alias SourceType string `json:"source_type"` AltURL string `json:"alt_url"` // original proxy target Provider string `json:"provider"` IsUnset bool `json:"-"` }
func (*Item) GetOverride ¶
type ItemConfig ¶
type ItemConfig struct { Show bool `json:"show"` Name string `json:"name"` // display name Icon *IconURL `json:"icon"` Category string `json:"category"` Description string `json:"description" aliases:"desc"` SortOrder int `json:"sort_order"` WidgetConfig map[string]any `json:"widget_config" aliases:"widget"` URL string `json:"url"` // alias + domain }
type OverrideConfig ¶
type OverrideConfig struct { ItemOverrides map[string]*ItemConfig `json:"item_overrides"` DisplayOrder map[string]int `json:"display_order"` // TODO: implement this CategoryOrder map[string]int `json:"category_order"` // TODO: implement this ItemVisibility map[string]bool `json:"item_visibility"` // contains filtered or unexported fields }
func GetOverrideConfig ¶
func GetOverrideConfig() *OverrideConfig
func (*OverrideConfig) GetOverride ¶
func (c *OverrideConfig) GetOverride(item *Item) *Item
func (*OverrideConfig) HideItems ¶
func (c *OverrideConfig) HideItems(keys ...string)
func (*OverrideConfig) OverrideItem ¶
func (c *OverrideConfig) OverrideItem(alias string, override *ItemConfig)
func (*OverrideConfig) OverrideItems ¶
func (c *OverrideConfig) OverrideItems(items map[string]*ItemConfig)
func (*OverrideConfig) SetCategoryOrder ¶
func (c *OverrideConfig) SetCategoryOrder(key string, value int)
func (*OverrideConfig) UnhideItems ¶
func (c *OverrideConfig) UnhideItems(keys ...string)
Click to show internal directories.
Click to hide internal directories.