Skip to content

Commit 937e774

Browse files
committed
upgrade examples
1 parent 1e10e03 commit 937e774

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

examples/columns/src/index.js

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
import React from "react";
22
import ReactDOM from "react-dom";
33
import { Datagrid } from "@activewidgets/react";
4-
import * as data from "@activewidgets/examples/northwind";
4+
import { northwind } from "@activewidgets/examples/data";
55

66
const columns = [
7-
{header: 'Code', field: 'CustomerID', width: 80, style: 'background:#def', fixed: true},
8-
{header: 'Company Name', field: 'CompanyName', width: 160},
9-
{header: 'Contact', field: 'ContactName', width: 120},
10-
{header: 'Title', field: 'ContactTitle', width: 120},
11-
{header: 'Address', field: 'Address', width: 120},
12-
{header: 'City', field: 'City'},
13-
{header: 'Zip', field: 'PostalCode', align: 'right'},
14-
{header: 'Phone', field: 'Phone'},
15-
{header: 'Fax', field: 'Fax'},
16-
{header: 'Country', field: 'Country'}
7+
{header: 'Code', field: 'customerID', width: 80, style: 'background:#def', fixed: true},
8+
{header: 'Company Name', field: 'companyName', width: 160},
9+
{header: 'Contact', field: 'contactName', width: 120},
10+
{header: 'Title', field: 'contactTitle', width: 120},
11+
{header: 'Address', field: 'address', width: 120},
12+
{header: 'City', field: 'city'},
13+
{header: 'Zip', field: 'postalCode', align: 'right'},
14+
{header: 'Phone', field: 'phone'},
15+
{header: 'Fax', field: 'fax'},
16+
{header: 'Country', field: 'country'}
1717
];
1818

1919
const App = () => (
20-
<Datagrid columns={columns} rows={data.customers} />
20+
<Datagrid columns={columns} rows={northwind.customers} />
2121
);
2222

2323
ReactDOM.render(<App />, document.getElementById("app"));

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"react": "^16"
2525
},
2626
"devDependencies": {
27-
"@activewidgets/examples": "0.0.2",
27+
"@activewidgets/examples": "0.0.3",
2828
"@activewidgets/options": "0.0.10",
2929
"@activewidgets/puppeteer": "0.0.4",
3030
"@activewidgets/testing": "0.0.3",

0 commit comments

Comments
 (0)