Grafana 11, context breaking changes, and importing JS modules in Business Text 5.0.0
We're excited to announce the release of the Business Text panel 5.0.0. This release includes the following updates:
- Plugin rebranding, the new name is the Business Text panel.
- Replaced the External Resource->Scripts (external JavaScript) with importing via the code. Breaking change.
- Non
context
code parameters are retired. Please update the parameter reference the use thecontext
. Breaking change. - Added support of the Grafana Standard Options and Overrides (Units and Decimals).
- Required Grafana 10 and Grafana 11. Breaking change.
The plugin was updated in the Grafana Plugins catalog on June 6, 2024.
Business Text panel
The Business Text panel joins the Business Suite for Grafana and with that gets an elevated name. Now, the same amazing open source plugin is called the Business Text panel.
Please welcome the new name for the same functionality!
Downloads
The Business Text plugin took off in May of this year and now the total downloads are close to the soaring 7,000,000!
External JavaScript replaced with Import
This is a breaking change. However, note, that you still can use external JavaScript code. Find details below.
Since in Grafana 11, the functionality of external JavaScript resources is deprecated, we removed the External Resource->Scripts parameter. You can import the JavaScript library directly in the code.
Our documentation has many examples of how to use external JavaScript libraries moving forward.
Context
migration guide
Starting from this release, ensure to reference the Grafana parameter using the context
Previously | Starting from version 5.0.0 |
---|---|
data | context.data |
dataFrame | context.dataFrame |
eventBus | context.grafana.eventBus |
getLocale | context.grafana.getLocale |
handlebars | context.handlebars |
locationService | context.grafana.locationService |
panelData | context.panelData |
replaceVariables | context.grafana.replaceVariables |
timeRange | context.grafana.timeRange |
timezone | context.grafana.timezone |
Standard Options and Overrides
The Grafana Standard Options impact all retrieved data columns, whereas Override allows the application of the same configuration only for a limited set of columns.
Starting from this release, the Business Text panel supports two parameters (Units and Decimals) from both Standard Options and Overrides categories.
Below is an example with various Units configurations.
Each of them is configured similarly. An example of one such configuration is below. For simplicity, the data is specified right on the Grafana dashboard using the Business Input data source.
The numbers for configuration have a String
type. One override is created for the Value
column to format it using the Newtons (N) template.
Content code to copy:
{{!-- Return --}}
{{Text}}: {{Value}}
Grafana 10 and Grafana 11
Grafana 9 is not supported.
Our plugins always follow the latest Grafana versions and stay compatible with the most recent releases. That means, however, that we have to sunset the support of obsolete releases.
The latest Business Text panel 5.0.0 fully supports Grafana 10 and 11 releases.
Getting Started
You can install the Business Text panel from the Grafana Plugins catalog or using the Grafana command line tool.
For the latter, please use the following command:
grafana cli plugins install marcusolsson-dynamictext-panel
Tutorial
The video reviews the major latest release including the data flow, predefined helpers and numerous examples of the external JavaScript libraries.
We have many other tutorials that you can find helpful. You can review all related to this plugin tutorials here.
Release Notes
- Requires Grafana 10 and Grafana 11.
- Removed external scripts deprecated in Grafana 11. Use import instead.
- Removed non-context code parameters. Please update parameters to use
context
.
- Requires Grafana 9.2 and Grafana 10
Code parameters migration guide
- data -> context.data
- dataFrame -> context.dataFrame
- eventBus -> context.grafana.eventBus
- getLocale -> context.grafana.getLocale
- handlebars -> context.handlebars
- locationService -> context.grafana.locationService
- panelData -> context.panelData
- replaceVariables -> context.grafana.replaceVariables
- timeRange -> context.grafana.timeRange
- timezone -> context.grafana.timezone
Features / Enhancements in 5.0.0
- Added plugin e2e tests and remove cypress (#301)
- Updated name to Business Text panel (#304)
- Prepared for Grafana 11 (#304)
- Added ES6 Modules Support (#312)
- Added Units and Decimal in panel options (#311)
- Updated to Grafana 11.0 and dependencies (#315)
Features / Enhancements in 4.5.0
- Add Info message if sanitize enabled (#290)
- Update CSS styles responsive and supporting themes (#281)
- Update to Grafana 10.4.0 (#291)
Features / Enhancements in 4.4.0
- Update context parameter (#270)
- Added theme object, notifySuccess & notifyError (#270)
- Update dependencies and Actions (#271)
- Replace custom code parameters with Code Parameters Builder (#285)
- Update CSS class for the panel instead of a Row (#272)
- Update Editor auto height from fixed value (#278)
- Disable unitScale and fieldMinMax standard panel options (#286)
Bug fixes in 4.4.0
- Fix statusColor for Row (#280)
Always happy to hear from you
- Ask a question, request a new feature, or report an issue at GitHub issues.
- Subscribe to our YouTube Channel and leave your comments.
- Become a Business Suite sponsor.