]> git.proxmox.com Git - extjs.git/blame - extjs/examples/kitchensink/classic/samples/view/charts/column3d/Negative.js
add extjs 6.0.1 sources
[extjs.git] / extjs / examples / kitchensink / classic / samples / view / charts / column3d / Negative.js
CommitLineData
6527f429
DM
1/**\r
2 * A 3D column chart with negative values.\r
3 * Tapping or hovering a column will highlight it.\r
4 */\r
5Ext.define('KitchenSink.view.charts.column3d.Negative', {\r
6 extend: 'Ext.Panel',\r
7 xtype: 'column-negative-3d',\r
8 requires: ['Ext.chart.theme.Muted'],\r
9 controller: 'column-negative-3d',\r
10 // <example>\r
11 // Content between example tags is omitted from code preview.\r
12 otherContent: [{\r
13 type: 'Controller',\r
14 path: 'classic/samples/view/charts/column3d/NegativeController.js'\r
15 }, {\r
16 type: 'Store',\r
17 path: 'classic/samples/store/Earnings.js'\r
18 }],\r
19 bodyStyle: 'background: transparent !important',\r
20 layout: 'fit',\r
21 // </example>\r
22\r
23 width: 650,\r
24 height: 500,\r
25\r
26 tbar: [\r
27 '->',\r
28 {\r
29 text: Ext.os.is.Desktop ? 'Download' : 'Preview',\r
30 handler: 'onDownload'\r
31 }\r
32 ],\r
33\r
34 items: {\r
35 xtype: 'cartesian',\r
36 reference: 'chart',\r
37 theme: 'muted',\r
38 store: {\r
39 type: 'earnings'\r
40 },\r
41 insetPadding: '40 40 40 20',\r
42 innerPadding: '0 3 0 0',\r
43 interactions: ['itemhighlight'],\r
44 animation: Ext.isIE8 ? false : {\r
45 easing: 'backOut',\r
46 duration: 500\r
47 },\r
48 axes: [{\r
49 type: 'numeric3d',\r
50 position: 'left',\r
51 fields: 'gaming',\r
52 grid: {\r
53 odd: {\r
54 fillStyle: 'rgba(255, 255, 255, 0.06)'\r
55 },\r
56 even: {\r
57 fillStyle: 'rgba(0, 0, 0, 0.05)'\r
58 }\r
59 }\r
60 }, {\r
61 type: 'category3d',\r
62 position: 'bottom',\r
63 fields: 'quarter',\r
64 grid: true,\r
65 label: {\r
66 rotate: {\r
67 degrees: -45\r
68 }\r
69 }\r
70 }],\r
71 series: [{\r
72 type: 'bar3d',\r
73 xField: 'quarter',\r
74 yField: 'gaming',\r
75 highlight: true,\r
76 renderer: 'onSeriesRender'\r
77 }],\r
78 sprites: [{\r
79 type: 'text',\r
80 text: 'Profits and Losses',\r
81 fontSize: 22,\r
82 width: 100,\r
83 height: 30,\r
84 x: 40, // the sprite x position\r
85 y: 20 // the sprite y position\r
86 }]\r
87 }\r
88\r
89});