Skip to content

Commit

Permalink
Release v0.11.0
Browse files Browse the repository at this point in the history
  • Loading branch information
compose-sdk-release-bot committed Sep 28, 2023
1 parent 94b672f commit 4e405c9
Show file tree
Hide file tree
Showing 154 changed files with 8,103 additions and 654 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,6 @@ lerna-debug.log*
docs/
docs-internal/
e2e/results.xml

# generated from storybook build
storybook-static/
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Changelog

## [0.11.0] - 2023-09-28

### Added

- Add component `TreemapChart`
and support Treemap chart type in components `Chart`, `ChartWidget`, and `DashboardWidget`
- Add component `DrilldownWidget`, which allows adding drilldown functionality to any type of chart

### Changed
- Refactor `HttpClient` to return raw response – in addition to JSON
- Support internationalization for numbers and improve tooltip consistency
- Make `dataSource` optional in `ChartWidgetProps` and `TableWidgetProps`
- Extend component `ExecuteQueryByWidgetId` and hook `useExecuteQueryByWidgetId`
to support `filters`, `highlights`, and `filtersMergeStrategy`
- Extend hook `useExecuteQuery` to support boolean flag `enabled`
- Extend component `DashboardWidget` to support `filtersMergeStrategy`
- Move `markers`, `navigator`, `xAxis`, `yAxis`, and `yAxis2` out of `BaseStyleOptions`
and into `BaseAxisStyleOptions`
- Bump `sisense-charts` version after fixing chart freeze on navigator update
- Improve styling of the Drilldown Breadcrumbs

## [0.10.0] - 2023-09-15

### Added
Expand Down
Binary file added docs-md/sdk/img/treemap-chart-example-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Drill-down capability is enabled.
breakBy: [],
}}
drilldownOptions={{
drilldownCategories: [DM.Commerce.AgeRange, DM.Commerce.Gender, DM.Commerce.Condition],
drilldownDimensions: [DM.Commerce.AgeRange, DM.Commerce.Gender, DM.Commerce.Condition],
}}
/>
```
Expand Down
17 changes: 17 additions & 0 deletions docs-md/sdk/modules/sdk-ui/functions/function.ContextMenu.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
title: ContextMenu
---

# Function ContextMenu

> **ContextMenu**(`__namedParameters`): `Element`
## Parameters

| Parameter | Type |
| :------ | :------ |
| `__namedParameters` | [`ContextMenuProps`](../type-aliases/type-alias.ContextMenuProps.md) |

## Returns

`Element`
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
title: DrilldownBreadcrumbs
---

# Function DrilldownBreadcrumbs

> **DrilldownBreadcrumbs**(`props`, `context`?): `null` \| `ReactElement`\< `any`, `any` \>
## Parameters

| Parameter | Type |
| :------ | :------ |
| `props` | [`DrilldownBreadcrumbsProps`](../type-aliases/type-alias.DrilldownBreadcrumbsProps.md) |
| `context`? | `any` |

## Returns

`null` \| `ReactElement`\< `any`, `any` \>
63 changes: 63 additions & 0 deletions docs-md/sdk/modules/sdk-ui/functions/function.DrilldownWidget.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
---
title: DrilldownWidget
---

# Function DrilldownWidget

> **DrilldownWidget**(`props`): `Element`
React component designed to add drilldown functionality to any type of chart

It acts as a wrapper around a given chart component, enhancing it with drilldown capabilities

The widget offers several features including:
- A context menu for initiating drilldown actions (can be provided as a custom component)
- Breadcrumbs that not only allow for drilldown selection slicing but also
provide an option to clear the selection (can be provided as a custom component)
- Filters specifically created for drilldown operation
- An option to navigate to the next drilldown dimension

When an `initialDimension` is specified, the `drilldownDimension` will automatically inherit its value,
even before any points on the chart are selected.
This allows for complete control over the chart's dimensions to be handed over to the DrilldownWidget

## Parameters

| Parameter | Type | Description |
| :------ | :------ | :------ |
| `props` | [`DrilldownWidgetProps`](../type-aliases/type-alias.DrilldownWidgetProps.md) | DrilldownWidget properties |

## Returns

`Element`

DrilldownWidget wrapper component

## Example

Example of using the `DrilldownWidget` component to
plot a custom React component that uses the `ExecuteQuery` component to
query the `Sample ECommerce` data source hosted in a Sisense instance.
```ts
<DrilldownWidget
drilldownDimensions={[DM.Commerce.AgeRange, DM.Commerce.Gender, DM.Commerce.Condition]}
initialDimension={DM.Category.Category}
>
{({ drilldownFilters, drilldownDimension, onDataPointsSelected, onContextMenu }) => (
<ExecuteQuery
dataSource={DM.DataSource}
dimensions={[drilldownDimension]}
measures={measure.sum(DM.Commerce.Revenue)}
filters={drilldownFilters}
>
{(data) => (
<MyCustomChart
rawData={data}
onContextMenu={onContextMenu}
onDataPointsSelected={onDataPointsSelected}
/>
)}
</ExecuteQuery>
)}
</DrilldownWidget>
```
49 changes: 49 additions & 0 deletions docs-md/sdk/modules/sdk-ui/functions/function.TreemapChart.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
---
title: TreemapChart
---

# Function TreemapChart

> **TreemapChart**(`props`, `context`?): `null` \| `ReactElement`\< `any`, `any` \>
A React component displaying hierarchical data in the form of nested rectangles.
This type of chart can be used in different scenarios, for example,
instead of a column chart if you have to compare too many categories and sub-categories.
See [Treemap Chart](https://docs.sisense.com/main/SisenseLinux/treemap.htm) for more information.

## Parameters

| Parameter | Type | Description |
| :------ | :------ | :------ |
| `props` | [`TreemapChartProps`](../interfaces/interface.TreemapChartProps.md) | Treemap chart properties |
| `context`? | `any` | - |

## Returns

`null` \| `ReactElement`\< `any`, `any` \>

Treemap Chart component

## Example

An example of using the component to visualize the `Sample ECommerce` data source:
```ts
<TreemapChart
dataSet={DM.DataSource}
dataOptions={{
category: [
{
column: DM.Commerceondition,
isColored: true,
},
DM.Commerce.Date.Years
],
value: [measures.sum(DM.Commerce.Quantity)],
}}
onDataPointClick= {(point, nativeEvent) => {
console.log('clicked', point, nativeEvent);
}}
/>
```
###
<img src="../../../img/treemap-chart-example-1.png" width="600px" />
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This approach, which offers an alternative to [ExecuteQueryByWidgetId](function.

| Parameter | Type | Description |
| :------ | :------ | :------ |
| `params` | [`ExecuteQueryByWidgetIdParams`](../type-aliases/type-alias.ExecuteQueryByWidgetIdParams.md) | Parameters to identify the target widget |
| `params` | [`ExecuteQueryByWidgetIdParams`](../interfaces/interface.ExecuteQueryByWidgetIdParams.md) | Parameters to identify the target widget |

## Returns

Expand Down
4 changes: 4 additions & 0 deletions docs-md/sdk/modules/sdk-ui/functions/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,11 @@ title: Functions
- [Chart](function.Chart.md)
- [ChartWidget](function.ChartWidget.md)
- [ColumnChart](function.ColumnChart.md)
- [ContextMenu](function.ContextMenu.md)
- [DashboardWidget](function.DashboardWidget.md)
- [DateRangeFilterTile](function.DateRangeFilterTile.md)
- [DrilldownBreadcrumbs](function.DrilldownBreadcrumbs.md)
- [DrilldownWidget](function.DrilldownWidget.md)
- [ExecuteQuery](function.ExecuteQuery.md)
- [ExecuteQueryByWidgetId](function.ExecuteQueryByWidgetId.md)
- [FunnelChart](function.FunnelChart.md)
Expand All @@ -23,5 +26,6 @@ title: Functions
- [SisenseContextProvider](function.SisenseContextProvider.md)
- [Table](function.Table.md)
- [ThemeProvider](function.ThemeProvider.md)
- [TreemapChart](function.TreemapChart.md)
- [useExecuteQuery](function.useExecuteQuery.md)
- [useExecuteQueryByWidgetId](function.useExecuteQueryByWidgetId.md)
13 changes: 12 additions & 1 deletion docs-md/sdk/modules/sdk-ui/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ title: sdk-ui
- [DashboardWidgetProps](interfaces/interface.DashboardWidgetProps.md)
- [DataLimits](interfaces/interface.DataLimits.md)
- [DateRangeFilterTileProps](interfaces/interface.DateRangeFilterTileProps.md)
- [ExecuteQueryByWidgetIdParams](interfaces/interface.ExecuteQueryByWidgetIdParams.md)
- [ExecuteQueryByWidgetIdProps](interfaces/interface.ExecuteQueryByWidgetIdProps.md)
- [ExecuteQueryProps](interfaces/interface.ExecuteQueryProps.md)
- [FunnelChartProps](interfaces/interface.FunnelChartProps.md)
Expand Down Expand Up @@ -44,6 +45,8 @@ title: sdk-ui
- [TableProps](interfaces/interface.TableProps.md)
- [TableStyleOptions](interfaces/interface.TableStyleOptions.md)
- [ThemeSettings](interfaces/interface.ThemeSettings.md)
- [TreemapChartProps](interfaces/interface.TreemapChartProps.md)
- [TreemapStyleOptions](interfaces/interface.TreemapStyleOptions.md)
- [WidgetStyleOptions](interfaces/interface.WidgetStyleOptions.md)

## Type Aliases
Expand All @@ -59,7 +62,9 @@ title: sdk-ui
- [Color](type-aliases/type-alias.Color.md)
- [ColorPaletteTheme](type-aliases/type-alias.ColorPaletteTheme.md)
- [ConditionalDataColorOptions](type-aliases/type-alias.ConditionalDataColorOptions.md)
- [ContextMenuProps](type-aliases/type-alias.ContextMenuProps.md)
- [Convolution](type-aliases/type-alias.Convolution.md)
- [CustomDrilldownResult](type-aliases/type-alias.CustomDrilldownResult.md)
- [DataColorCondition](type-aliases/type-alias.DataColorCondition.md)
- [DataColorOptions](type-aliases/type-alias.DataColorOptions.md)
- [DataPoint](type-aliases/type-alias.DataPoint.md)
Expand All @@ -69,9 +74,10 @@ title: sdk-ui
- [DateLevel](type-aliases/type-alias.DateLevel.md)
- [DayOfWeek](type-aliases/type-alias.DayOfWeek.md)
- [DecimalScale](type-aliases/type-alias.DecimalScale.md)
- [DrilldownBreadcrumbsProps](type-aliases/type-alias.DrilldownBreadcrumbsProps.md)
- [DrilldownOptions](type-aliases/type-alias.DrilldownOptions.md)
- [DrilldownSelection](type-aliases/type-alias.DrilldownSelection.md)
- [ExecuteQueryByWidgetIdParams](type-aliases/type-alias.ExecuteQueryByWidgetIdParams.md)
- [DrilldownWidgetProps](type-aliases/type-alias.DrilldownWidgetProps.md)
- [ExecuteQueryParams](type-aliases/type-alias.ExecuteQueryParams.md)
- [IndicatorChartType](type-aliases/type-alias.IndicatorChartType.md)
- [IndicatorComponents](type-aliases/type-alias.IndicatorComponents.md)
Expand All @@ -82,6 +88,7 @@ title: sdk-ui
- [LineWidth](type-aliases/type-alias.LineWidth.md)
- [Markers](type-aliases/type-alias.Markers.md)
- [MenuItemSection](type-aliases/type-alias.MenuItemSection.md)
- [MenuPosition](type-aliases/type-alias.MenuPosition.md)
- [MonthOfYear](type-aliases/type-alias.MonthOfYear.md)
- [Navigator](type-aliases/type-alias.Navigator.md)
- [NumberFormatConfig](type-aliases/type-alias.NumberFormatConfig.md)
Expand Down Expand Up @@ -115,8 +122,11 @@ title: sdk-ui
- [Chart](functions/function.Chart.md)
- [ChartWidget](functions/function.ChartWidget.md)
- [ColumnChart](functions/function.ColumnChart.md)
- [ContextMenu](functions/function.ContextMenu.md)
- [DashboardWidget](functions/function.DashboardWidget.md)
- [DateRangeFilterTile](functions/function.DateRangeFilterTile.md)
- [DrilldownBreadcrumbs](functions/function.DrilldownBreadcrumbs.md)
- [DrilldownWidget](functions/function.DrilldownWidget.md)
- [ExecuteQuery](functions/function.ExecuteQuery.md)
- [ExecuteQueryByWidgetId](functions/function.ExecuteQueryByWidgetId.md)
- [FunnelChart](functions/function.FunnelChart.md)
Expand All @@ -129,5 +139,6 @@ title: sdk-ui
- [SisenseContextProvider](functions/function.SisenseContextProvider.md)
- [Table](functions/function.Table.md)
- [ThemeProvider](functions/function.ThemeProvider.md)
- [TreemapChart](functions/function.TreemapChart.md)
- [useExecuteQuery](functions/function.useExecuteQuery.md)
- [useExecuteQueryByWidgetId](functions/function.useExecuteQueryByWidgetId.md)
3 changes: 3 additions & 0 deletions docs-md/sdk/modules/sdk-ui/interfaces/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ title: Interfaces
- [DashboardWidgetProps](interface.DashboardWidgetProps.md)
- [DataLimits](interface.DataLimits.md)
- [DateRangeFilterTileProps](interface.DateRangeFilterTileProps.md)
- [ExecuteQueryByWidgetIdParams](interface.ExecuteQueryByWidgetIdParams.md)
- [ExecuteQueryByWidgetIdProps](interface.ExecuteQueryByWidgetIdProps.md)
- [ExecuteQueryProps](interface.ExecuteQueryProps.md)
- [FunnelChartProps](interface.FunnelChartProps.md)
Expand Down Expand Up @@ -42,4 +43,6 @@ title: Interfaces
- [TableProps](interface.TableProps.md)
- [TableStyleOptions](interface.TableStyleOptions.md)
- [ThemeSettings](interface.ThemeSettings.md)
- [TreemapChartProps](interface.TreemapChartProps.md)
- [TreemapStyleOptions](interface.TreemapStyleOptions.md)
- [WidgetStyleOptions](interface.WidgetStyleOptions.md)
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Configuration options that define functional style of the various elements of [A

## Extends

- `BaseStyleOptions`
- `BaseStyleOptions`.`BaseAxisStyleOptions`

## Properties

Expand Down Expand Up @@ -68,7 +68,7 @@ Configuration for markers - symbols or data points that highlight specific value

#### Inherited from

BaseStyleOptions.markers
BaseAxisStyleOptions.markers

***

Expand All @@ -80,7 +80,7 @@ Configuration for navigator - zoom/pan tool for large datasets in a chart

#### Inherited from

BaseStyleOptions.navigator
BaseAxisStyleOptions.navigator

***

Expand Down Expand Up @@ -116,7 +116,7 @@ Configuration for X axis

#### Inherited from

BaseStyleOptions.xAxis
BaseAxisStyleOptions.xAxis

***

Expand All @@ -128,7 +128,7 @@ Configuration for second Y axis

#### Inherited from

BaseStyleOptions.y2Axis
BaseAxisStyleOptions.y2Axis

***

Expand All @@ -140,4 +140,4 @@ Configuration for Y axis

#### Inherited from

BaseStyleOptions.yAxis
BaseAxisStyleOptions.yAxis
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Props for the [ChartWidget](../functions/function.ChartWidget.md) component

#### dataSource

> **dataSource**: `string`
> **dataSource**?: `string`
Data source the query is run against - e.g. `Sample ECommerce`

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,20 @@ Omit.filters

***

#### filtersMergeStrategy

> **filtersMergeStrategy**?: `"widgetFirst"` \| `"codeFirst"` \| `"codeOnly"`
Strategy for merging the existing widget filters with the filters provided via the `filters` prop:

- `widgetFirst` - prioritizes the widget filters over the provided filters in case of filter conflicts by certain attributes.
- `codeFirst` - prioritizes the provided filters over the widget filters in case of filter conflicts by certain attributes.
- `codeOnly` - applies only the provided filters and completely ignores the widget filters.

If not specified, the default strategy is `widgetFirst`.

***

#### highlights

> **highlights**?: [`Filter`](../../sdk-data/interfaces/interface.Filter.md)[]
Expand Down
Loading

0 comments on commit 4e405c9

Please sign in to comment.