View Source Luminous.Panel behaviour (luminous v2.0.0)
A panel represents a single visual element (chart) in a dashboard that can contain many queries.
Link to this section Summary
Callbacks
Define the panel type's supported data attributes These will be used to parse, validate and populate the client's input
Define custom attributes according to the panel type These will be used to parse, validate and populate the client's input
transform a query result to view data acc. to the panel type
Functions
Define a panel Verifies all supplied options both generic (@attributes) and the concrete panel's attributes Will raise if the validation fails
Refresh all panel queries.
Link to this section Types
@type t() :: map()
Link to this section Callbacks
@callback data_attributes() :: NimbleOptions.schema()
Define the panel type's supported data attributes These will be used to parse, validate and populate the client's input
@callback panel_attributes() :: NimbleOptions.schema()
Define custom attributes according to the panel type These will be used to parse, validate and populate the client's input
@callback transform(Luminous.Query.result(), t()) :: any()
transform a query result to view data acc. to the panel type
Link to this section Functions
Define a panel Verifies all supplied options both generic (@attributes) and the concrete panel's attributes Will raise if the validation fails
@spec refresh(t(), [Luminous.Variable.t()], Luminous.TimeRange.t()) :: any()
Refresh all panel queries.