-
Notifications
You must be signed in to change notification settings - Fork 2
/
group-chart-list-horizontal.jigx
139 lines (135 loc) · 4.41 KB
/
group-chart-list-horizontal.jigx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
title: Widget group
description: "size: 4x4, layout: horizontal"
type: jig.default
header:
type: component.jig-header
options:
height: medium
children:
type: component.image
options:
source:
uri: https://builder.jigx.com/assets/images/header.jpg
datasources:
transactions:
type: datasource.static
options:
data:
- amount: 607
company: DLT
date: 2022-03-17
description: Logistic application
positive: true
- amount: -384
company: McPen
date: 2022-04-15
description: Office supplies
positive: false
- amount: -531
company: Rock Cafe
date: 2022-06-10
description: Company party
positive: false
- amount: -427
company: Allianz
date: 2022-10-04
description: Car insurance for company cars
positive: false
- amount: 947
company: ATV Impex
date: 2022-10-18
description: DMS application
positive: true
- amount: -531
company: Rock Cafe
date: 2022-06-10
description: Company party
positive: false
- amount: -427
company: Allianz
date: 2022-10-04
description: Car insurance for company cars
positive: false
- amount: 947
company: ATV Impex
date: 2022-10-18
description: DMS application
positive: true
children:
- type: component.entity
options:
children:
- type: component.entity-field
options:
label: entity-field
value: Text
widgets:
"4x4":
type: widget.group
options:
split: horizontal
children:
- type: widget.chart
options:
chart:
type: component.line-chart
options:
chart:
isAnimated: true
yAxis:
min: 0
labels:
format:
numberStyle: currency
compactDisplay: short
notation: compact
tickAmount: 8
isFirstTickHidden: true
isFirstLabelHidden: true
xAxis:
categories:
- Q1
- Q2
- Q3
- Q4
series:
- data: =[{"x":"Q1/20", "y":25000, "color":"color2"}, {"x":"Q2/20", "y":32000, "color":"color2"}, {"x":"Q3/20", "y":45000, "color":"color2"}, {"x":"Q4/20", "y":86000, "color":"color2"}]
name: Year 2019
animation:
direction: left-to-right
layout: area-gradient
dataLabels:
- isEnabled: true
- data: =[{"x":"Q1/20", "y":12000, "color":"color3"}, {"x":"Q2/20", "y":48000, "color":"color3"}, {"x":"Q3/20", "y":36000, "color":"color3"}, {"x":"Q4/20", "y":120000, "color":"color3"}]
name: Year 2020
animation:
direction: left-to-right
layout: area-gradient
dataLabels:
- isEnabled: true
legend:
isHidden: false
- type: widget.list
options:
data: =@ctx.datasources.transactions
item:
type: component.list-item
options:
divider: solid
title: =@ctx.current.item.company
subtitle: =@ctx.current.item.description
description: =$fromMillis($toMillis(@ctx.current.item.date), '[M01]/[D01]/[Y01]')
label:
title: =@ctx.current.item.amount & '$'
isHidden: false
color:
- when: =(@ctx.current.item.positive = true)
color: color2
- when: =(@ctx.current.item.positive = false)
color: color4
leftElement:
element: icon
icon: =@ctx.current.item.positive = true ? 'up' :'down'
style:
isPositive: =@ctx.current.item.positive
isError: =@ctx.current.item.positive = false ? "true" :"false"