Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion docs/api/config/columnshape-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,6 @@ const table = new pivot.Pivot("#root", {
});
~~~

**Related samples:**
**Related samples**:
- [Pivot 2. Auto width. Sizing columns to content](https://snippet.dhtmlx.com/tn1yw14m)
- [Pivot 2. Set columns width](https://snippet.dhtmlx.com/ceu34kkn)
4 changes: 2 additions & 2 deletions docs/api/config/configpanel-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ const table = new pivot.Pivot("#root", {
});
~~~

**Related sample:** [Pivot 2.0: Toggle visibility of configuration panel](https://snippet.dhtmlx.com/1xq1x5bo)
**Related sample**: [Pivot 2.0: Toggle visibility of configuration panel](https://snippet.dhtmlx.com/1xq1x5bo)

**Related articles:**
**Related articles**:
- [`show-config-panel` event](api/events/show-config-panel-event.md)
- [`showConfigPanel()` method](api/methods/showconfigpanel-method.md)
- [Controlling visibility of Configuration panel](guides/configuration.md#controlling-visibility-of-configuration-panel)
2 changes: 1 addition & 1 deletion docs/api/config/fields-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,4 +109,4 @@ const table = new pivot.Pivot("#root", {
- [Number formatting](guides/localization.md#number-formatting)
- [Applying formats to fields](guides/working-with-data.md#applying-formats-to-fields)

**Related sample:** [Pivot 2. Defining fields formats](https://snippet.dhtmlx.com/77nc4j8v)
**Related sample**: [Pivot 2. Defining fields formats](https://snippet.dhtmlx.com/77nc4j8v)
2 changes: 1 addition & 1 deletion docs/api/config/limits-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,4 @@ const table = new pivot.Pivot("#root", {
});
~~~

**Related sample:** [Pivot 2. Data limits](https://snippet.dhtmlx.com/7ryns8oe)
**Related sample**: [Pivot 2. Data limits](https://snippet.dhtmlx.com/7ryns8oe)
2 changes: 1 addition & 1 deletion docs/api/config/methods-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,6 @@ const table = new pivot.Pivot("#root", {
});
~~~

**Related sample:** [Pivot 2. Custom maths methods](https://snippet.dhtmlx.com/lv90d8q2)
**Related sample**: [Pivot 2. Custom maths methods](https://snippet.dhtmlx.com/lv90d8q2)

**Related article**: [Applying maths methods](guides/working-with-data.md#applying-maths-methods)
2 changes: 1 addition & 1 deletion docs/api/config/readonly-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,4 @@ const table = new pivot.Pivot("#root", {
});
~~~

**Related sample:** [Pivot 2. Readonly mode](https://snippet.dhtmlx.com/0k0mvycv)
**Related sample**: [Pivot 2. Readonly mode](https://snippet.dhtmlx.com/0k0mvycv)
2 changes: 1 addition & 1 deletion docs/api/config/tableshape-property.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ const table = new pivot.Pivot("#root", {
});
~~~

**Related samples:**
**Related samples**:

- [Pivot 2. Tree mode](https://snippet.dhtmlx.com/6ylkoukn)
- [Pivot 2. Frozen (fixed) columns](https://snippet.dhtmlx.com/lahf729o)
Expand Down
4 changes: 2 additions & 2 deletions docs/api/events/render-table-event.md
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,6 @@ function closeAll() {

See also how to configure the split feature using the `render-table` event: [Freezing columns](guides/configuration.md#freezing-columns).

**Related article:** [pivot.template helper](api/helpers/template.md)
**Related article**: [pivot.template helper](api/helpers/template.md)

**Related sample:** [Pivot 2. Custom frozen (fixed) columns (your number)](https://snippet.dhtmlx.com/53erlmgp)
**Related sample**: [Pivot 2. Custom frozen (fixed) columns (your number)](https://snippet.dhtmlx.com/53erlmgp)
2 changes: 1 addition & 1 deletion docs/api/helpers/template.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ The snippet demonstrates how you can add icons to:
<iframe src="https://snippet.dhtmlx.com/4viq7cft?mode=result" frameborder="0" class="snippet_iframe" width="100%" height="600"></iframe>


**Related articles:**
**Related articles**:

- [`render-table`](api/events/render-table-event.md)
- [Applying templates to cells](guides/configuration.md#applying-templates-to-cells)
Expand Down
2 changes: 1 addition & 1 deletion docs/api/methods/gettable-method.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ exportButton.textContent = "Export";
document.body.appendChild(exportButton);
~~~

**Related articles:**:
**Related articles**:

- [`close-row`](api/table/close-row.md)
- [`export`](api/table/export.md)
Expand Down
6 changes: 3 additions & 3 deletions docs/api/table/export.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@ The `export` action of the Table widget has the next parameters that you can con
- `options` - an object with the export options; options differ depending on the format type
- `result` - the result of the exported Excel or CSV data (usually Blob or file depending on the `download` option)

**Common options for both formats ("csv" "xlsx" ):**
**Common options for both formats ("csv" "xlsx" )**:

- `format` (string) - (optional) the export format that can be "csv" or "xlsx"
- `fileName` (string) - (optional) a file name ("data" by default)
- `header` (boolean) - (optional) defines if a header should be exported (**true** by default)
- `footer` (boolean) - (optional) defines if a footer should be exported (**true** by default)
- `download` (boolean) - (optional) defines whether to download a file. **true** is set by default. If set to **false**, the file will not be downloaded, Excel or CSV data (Blob) will be available as `ev.result`

**Options specific for "xlsx" format:**
**Options specific for "xlsx" format**:

- `sheetName` (string) - a name of Excel sheet ( "data" by default)
- `styles` (boolean or object) - if set to **false**, grid will be exported without any styling; can be configured using a hash of style properties:
Expand All @@ -92,7 +92,7 @@ The `export` action of the Table widget has the next parameters that you can con
By default, for the "xlsx" format, date and number fields are exported as raw values with default format or the format defined via the [`fields`](api/config/fields-property.md) property. But if a template is defined for a field (see the [`tableShape`](api/config/tableshape-property.md) property), it exports the rendered value defined by that template. In case both the template and `format` are set, the template settings will override the format ones.
:::

**Options specific for "csv" format:**
**Options specific for "csv" format**:

- `rows` (string) - (optional) rows delimiter, "\n" by default
- `cols` (string) - (optional) columns delimiter, "\t" by default
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -732,7 +732,7 @@ The Configuration panel supports the following field operations:
- [`update-field`](api/events/update-field-event.md) — update a field's method or settings
- [`move-field`](api/events/move-field-event.md) — reorder fields within an area

**Related samples:**
**Related samples**:
- [Pivot 2. Adding text templates for table and header cells](https://snippet.dhtmlx.com/n9ylp6b2)
- [Pivot 2. Custom frozen (fixed) columns (your number)](https://snippet.dhtmlx.com/53erlmgp)
- [Pivot 2. Expand and collapse all rows](https://snippet.dhtmlx.com/i4mi6ejn)
Expand Down
10 changes: 2 additions & 8 deletions docs/guides/loading-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -159,15 +159,9 @@ Promise.all([
});
~~~

<<<<<<< sp-next-add-backend-guide
:::info
See [Working with server](/guides/working-with-server) for a full round-trip: loading rows, saving the layout, and storing aggregated results.
:::
Refer to the following topic for additional information: [Working with server](/guides/working-with-server)

## Loading CSV data
=======
## Load CSV data
>>>>>>> next

Pivot accepts CSV data after you convert it to JSON with an external JS parsing library. The converted data behaves the same as native JSON.

Expand Down Expand Up @@ -277,7 +271,7 @@ The snippet below loads JSON and CSV data:

<iframe src="https://snippet.dhtmlx.com/wo6w9hf9?mode=result" frameborder="0" class="snippet_iframe" width="100%" height="600"></iframe>

**Related samples:**
**Related samples**:
- [Pivot 2. Date format](https://snippet.dhtmlx.com/shn1l794)
- [Pivot 2. Different datasets](https://snippet.dhtmlx.com/6xtqge4i)
- [Pivot 2. Large dataset](https://snippet.dhtmlx.com/e6qwqrys)
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/working-with-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ The snippet below applies custom math operations:

<iframe src="https://snippet.dhtmlx.com/lv90d8q2?mode=result" frameborder="0" class="snippet_iframe" width="100%" height="600"></iframe>

**Related samples:**
**Related samples**:

- [Pivot 2. Dataset with aliases](https://snippet.dhtmlx.com/7vc68rqd)
- [Pivot 2. Defining fields formats](https://snippet.dhtmlx.com/77nc4j8v)
Expand Down
25 changes: 14 additions & 11 deletions docs/guides/working-with-server.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ Pivot runs entirely in the browser. The widget takes an array of raw rows plus a

A typical integration includes three parts:

1. **Load** raw, non-aggregated data from the server on init.
2. **Save the config** when the user changes the layout, so the session resumes later.
3. **Save the aggregated table** when the server needs a snapshot of the rolled-up result.
1. **Load** raw, non-aggregated data from the server on init
2. **Save the config** when the user changes the layout, so the session resumes later
3. **Save the aggregated table** when the server needs a snapshot of the rolled-up result

## Load raw data from the server

Expand Down Expand Up @@ -47,7 +47,9 @@ data.forEach(row => {
~~~

:::info
See also: [Loading data](/guides/loading-data), [Date formatting](/guides/localization#date-formatting).
**See also**:
- [Loading data](/guides/loading-data)
- [Date formatting](/guides/localization#date-formatting)
:::

## Save the user's layout to resume the session
Expand Down Expand Up @@ -154,16 +156,17 @@ Return `false` from the handler to prevent rendering. Use this when the server r

Pivot produces aggregated tables and does not display pre-aggregated ones. The [`data`](/api/config/data-property) property always takes raw rows. A snapshot saved from `render-table` therefore fits these cases:

- a downstream export pipeline (CSV, XLSX) on the server,
- a read-only view rendered by a plain data table from the saved `columns` and `data`,
- a cached report served to other users without re-running the aggregation.

---
- a downstream export pipeline (CSV, XLSX) on the server
- a read-only view rendered by a plain data table from the saved `columns` and `data`
- a cached report served to other users without re-running the aggregation

**Related articles**:

- [Loading data](/guides/loading-data)
- [Exporting data](/guides/exporting-data)

**Related API**:

- [`api.on()`](/api/internal/on-method)
- [`update-config` event](/api/events/update-config-event)
- [`render-table` event](/api/events/render-table-event)
- [`update-config`](/api/events/update-config-event)
- [`render-table`](/api/events/render-table-event)
22 changes: 19 additions & 3 deletions docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,17 @@ const onAfterDataTransformation = (data) => {

/** @type {import('@docusaurus/types').Config} */
const config = {
i18n: {
defaultLocale: 'en',
locales: ['en', 'de', 'ru', 'zh', 'ko'],
localeConfigs: {
en: { label: 'English', htmlLang: 'en-US' },
de: { label: 'Deutsch', htmlLang: 'de' },
ru: { label: 'Русский', htmlLang: 'ru' },
zh: { label: '简体中文', htmlLang: 'zh-CN' },
ko: { label: '한국어', htmlLang: 'ko' },
},
},
noIndex: false,
title: 'DHTMLX JavaScript Pivot Docs',
tagline: 'DHTMLX JavaScript Pivot Docs',
Expand All @@ -164,7 +175,7 @@ const config = {
({
docs: {
sidebarPath: require.resolve('./sidebars.js'),
editUrl: 'https://github.com/DHTMLX/docs-pivot/edit/master/',
// editUrl: 'https://github.com/DHTMLX/docs-pivot/edit/master/',
routeBasePath: '/',
},
theme: {
Expand Down Expand Up @@ -207,7 +218,8 @@ const config = {
highlightSearchTermsOnTargetPage: true,
removeDefaultStemmer: true,
removeDefaultStopWordFilter: true,
explicitSearchResultPath: true
explicitSearchResultPath: true,
language: ["en", "de", "ru", "zh"]
}
]
],
Expand Down Expand Up @@ -250,7 +262,11 @@ const config = {
"label": "Download",
"href": "https://dhtmlx.com/docs/products/dhtmlxPivot/download.shtml",
"position": "right"
}
},
{
type: 'localeDropdown',
position: 'right',
},
],
},
footer: {
Expand Down
Loading