File tree Expand file tree Collapse file tree 2 files changed +18
-11
lines changed Expand file tree Collapse file tree 2 files changed +18
-11
lines changed Original file line number Diff line number Diff line change @@ -194,10 +194,6 @@ dashboards embedded with the :ref:`Embedding SDK
194
194
dashboard.setAutoRefresh(true);
195
195
dashboard.setMaxDataAge(30);
196
196
197
- Use the following methods to set the theme and automatic
198
- refresh rate of the Dashboard instance returned by
199
- ``DashboardsEmbedSDK.createDashboard({ ... })``.
200
-
201
197
.. list-table::
202
198
:header-rows: 1
203
199
:widths: 50 50
@@ -230,6 +226,12 @@ dashboards embedded with the :ref:`Embedding SDK
230
226
your dashboard's background color has appropriate
231
227
contrast so that the information is visible.
232
228
229
+ * - ``getChart('<chartID>')``
230
+ - Retrieves a specific chart from the embedded dashboard
231
+ using the chart's ``chartId`` string. After calling this
232
+ method, you can :ref:`highlight elements <highlight-chart-elements>`
233
+ or :ref:`filter data <filter-embedded-sdk>` on the chart.
234
+
233
235
.. seealso::
234
236
235
237
- `Embedding SDK API Documentation
Original file line number Diff line number Diff line change @@ -14,13 +14,8 @@ Highlight Chart Elements
14
14
15
15
The Charts Embedding JavaScript SDK enables you to programmatically
16
16
highlight specific elements and :ref:`clicked events
17
- <handle-click-events>` on charts.
18
-
19
- .. note::
20
-
21
- You can highlight specific elements only on embedded charts. You
22
- can't highlight specific elements on charts within embedded
23
- dashboards.
17
+ <handle-click-events>` on embedded charts and charts within :ref:`embedded
18
+ dashboards <embedding-dashboards>`.
24
19
25
20
.. _highlight-chart-elements-prereqs:
26
21
@@ -42,6 +37,16 @@ has the following syntax:
42
37
43
38
charts.setHighlight(selectionFilter);
44
39
40
+ .. note::
41
+
42
+ If you want to highlight charts within an embedded dashboard,
43
+ first run the following method to retrieve a specific chart
44
+ from the Dashboard instance:
45
+
46
+ .. code-block:: javascript
47
+
48
+ dashboard.getChart('<chartID>');
49
+
45
50
The ``setHighlight`` method takes an :abbr:`MQL (MongoDB Query
46
51
Language` filter. You can provide the MQL filter directly to the
47
52
``setHighlight`` method as shown in the example below or through the
You can’t perform that action at this time.
0 commit comments