mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Plugins: Unifying alpha state & options for all plugins (#16530)
* app pages * app pages * workign example * started alpha support * remove app stuff * show warning on alpha/beta panels * put app back on plugin file * fix go * add enum for PluginType and PluginIncludeType * Refactoring and moving settings to plugins section fixes #16529
This commit is contained in:
committed by
Torkel Ödegaard
parent
30dcf0f6c5
commit
3c21a121eb
@@ -1,10 +1,25 @@
|
||||
export enum PluginState {
|
||||
alpha = 'alpha', // Only included it `enable_alpha` is true
|
||||
beta = 'beta', // Will show a warning banner
|
||||
}
|
||||
|
||||
export enum PluginType {
|
||||
panel = 'panel',
|
||||
datasource = 'datasource',
|
||||
app = 'app',
|
||||
}
|
||||
|
||||
export interface PluginMeta {
|
||||
id: string;
|
||||
name: string;
|
||||
info: PluginMetaInfo;
|
||||
includes: PluginInclude[];
|
||||
module: string;
|
||||
baseUrl: string;
|
||||
includes?: PluginInclude[];
|
||||
baseUrl?: string;
|
||||
|
||||
type: PluginType;
|
||||
enabled?: boolean;
|
||||
state?: PluginState;
|
||||
|
||||
// Datasource-specific
|
||||
builtIn?: boolean;
|
||||
@@ -24,8 +39,17 @@ interface PluginMetaQueryOptions {
|
||||
minInterval?: boolean;
|
||||
}
|
||||
|
||||
export enum PluginIncludeType {
|
||||
dashboard = 'dashboard',
|
||||
page = 'page',
|
||||
|
||||
// Only valid for apps
|
||||
panel = 'panel',
|
||||
datasource = 'datasource',
|
||||
}
|
||||
|
||||
export interface PluginInclude {
|
||||
type: string;
|
||||
type: PluginIncludeType;
|
||||
name: string;
|
||||
path: string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user