Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
S
sidekick
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Privat - Marco Schmiedel
sidekick
Commits
d3e301af
Commit
d3e301af
authored
Jul 22, 2022
by
Kevin Yumang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
SERV-2286 - bar chart element configuration WIP
parent
b1e2d700
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
108 additions
and
258 deletions
+108
-258
barchart.init.js
src/Views/Limitless/Barchart/Attachments/barchart.init.js
+85
-233
BarChart.blade.php
src/Views/Limitless/Barchart/BarChart.blade.php
+4
-8
Config.php
src/Views/Limitless/Barchart/Config.php
+3
-7
Index.blade.php
src/Views/Limitless/Barchart/Documentation/Index.blade.php
+15
-9
Index.blade.php
src/Views/Limitless/Linechart/Documentation/Index.blade.php
+1
-1
No files found.
src/Views/Limitless/Barchart/Attachments/barchart.init.js
View file @
d3e301af
This diff is collapsed.
Click to expand it.
src/Views/Limitless/Barchart/BarChart.blade.php
View file @
d3e301af
<div
class=
"chart-container"
>
<div
class=
"chart-container"
>
<div
class=
"chart has-fixed-height LimitlessLineChart"
<div
class=
"chart has-fixed-height LimitlessBarChart"
charts=
"{{ $charts }}"
title=
"{{ $title }}"
titles=
"{{ json_encode($titles) }}"
colors=
"{{ json_encode($colors) }}"
colors=
"{{ json_encode($colors) }}"
point-values=
"{{ $pointValues }}"
bar-values=
"{{ $barValues }}"
boundary-gap=
"{{ $boundaryGap }}"
inverted=
"{{ $inverted }}"
inverted=
"{{ $inverted }}"
data-zoom=
"{{ $dataZoom }}"
stacked=
"{{ $stacked }}"
stacked=
"{{ $stacked }}"
is-area=
"{{ $isArea }}"
animation-duration=
"{{ $animationDuration }}"
animation-duration=
"{{ $animationDuration }}"
@
if
($
yAxisLabelValueFormat
!=
null
)
y-axis-label-value-format=
"{{ $yAxisLabelValueFormat }}"
@
endif
@
if
($
yAxisLabelValueFormat
!=
null
)
y-axis-label-value-format=
"{{ $yAxisLabelValueFormat }}"
@
endif
@
if
($
markLine
!=
null
)
mark-line=
"{{ $markLine }}"
@
endif
@
if
($
markLine
!=
null
)
mark-line=
"{{ $markLine }}"
@
endif
categories=
"{{ json_encode($categories) }}"
categories=
"{{ json_encode($categories) }}"
series=
"{{ json_encode($series) }}"
series=
"{{ json_encode($series) }}"
raw=
"{{
$raw
}}"
raw=
"{{
json_encode(json_decode($raw))
}}"
>
>
</div>
</div>
</div>
</div>
\ No newline at end of file
src/Views/Limitless/Barchart/Config.php
View file @
d3e301af
...
@@ -63,16 +63,12 @@
...
@@ -63,16 +63,12 @@
*/
*/
public
function
barChart
(
$parameters
)
public
function
barChart
(
$parameters
)
{
{
return
View
(
'Limitless::Barchart.barChart'
)
return
View
(
'Limitless::Barchart.BarChart'
)
->
withCharts
(
$parameters
[
'charts'
]
??
1
)
->
withTitle
(
$parameters
[
'title'
]
??
null
)
->
withTitles
(
$parameters
[
'titles'
]
??
null
)
->
withColors
(
$parameters
[
'colors'
]
??
null
)
->
withColors
(
$parameters
[
'colors'
]
??
null
)
->
withPointValues
(
$parameters
[
'point-values'
]
??
false
)
->
withBarValues
(
$parameters
[
'bar-values'
]
??
false
)
->
withBoundaryGap
(
$parameters
[
'boundary-gap'
]
??
true
)
->
withInverted
(
$parameters
[
'inverted'
]
??
false
)
->
withInverted
(
$parameters
[
'inverted'
]
??
false
)
->
withDataZoom
(
$parameters
[
'data-zoom'
]
??
false
)
->
withStacked
(
$parameters
[
'stacked'
]
??
false
)
->
withStacked
(
$parameters
[
'stacked'
]
??
false
)
->
withIsArea
(
$parameters
[
'is-area'
]
??
false
)
->
withAnimationDuration
(
$parameters
[
'animation-duration'
]
??
750
)
->
withAnimationDuration
(
$parameters
[
'animation-duration'
]
??
750
)
->
withYAxisLabelValueFormat
(
$parameters
[
'y-axis-label-value-format'
]
??
null
)
->
withYAxisLabelValueFormat
(
$parameters
[
'y-axis-label-value-format'
]
??
null
)
->
withMarkLine
(
$parameters
[
'mark-line'
]
??
null
)
->
withMarkLine
(
$parameters
[
'mark-line'
]
??
null
)
...
...
src/Views/Limitless/Barchart/Documentation/Index.blade.php
View file @
d3e301af
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
// sample backend data
// sample backend data
$categories
=
[
'Jan'
,
'Feb'
,
'Mar'
,
'Apr'
,
'May'
,
'Jun'
,
'July'
,
'Aug'
,
'Sep'
,
'Oct'
,
'Nov'
,
'Dec'
];
$categories
=
[
'Jan'
,
'Feb'
,
'Mar'
,
'Apr'
,
'May'
,
'Jun'
,
'July'
,
'Aug'
,
'Sep'
,
'Oct'
,
'Nov'
,
'Dec'
];
$series
=
[
'ONC'
,
'APR'
,
'
SPR'
,
'PHX'
,
'SIG'
,
'BRG'
,
'MNT'
,
'SDK'
,
'OCT
'
];
$series
=
[
'ONC'
,
'APR'
,
'
PHX'
,
'BRG
'
];
$seriesData
=
[];
$seriesData
=
[];
foreach
(
$series
as
$s
)
{
foreach
(
$series
as
$s
)
{
...
@@ -43,21 +43,27 @@
...
@@ -43,21 +43,27 @@
@
endphp
@
endphp
@
Limitless
::
CardStart
([
'title'
=>
"Basic Setup"
,
'icon'
=>
'icon-info22'
]
)
@
Limitless
::
CardStart
([
'title'
=>
"Basic Setup"
,
'icon'
=>
'icon-info22'
]
)
@
Limitless
::
LineChart
([
@
Limitless
::
BarChart
([
'mark-line'
=>
'average'
,
'categories'
=>
$categories
,
'categories'
=>
$categories
,
'series'
=>
$seriesData
,
'series'
=>
$seriesData
,
])
])
@
Limitless
::
CardStop
@
Limitless
::
CardStop
@
Limitless
::
CardStart
([
'title'
=>
"Chart 2 (raw)"
,
'icon'
=>
'icon-info22'
]
)
@
Limitless
::
CardStart
([
'title'
=>
"Stacked Setup"
,
'icon'
=>
'icon-info22'
]
)
@
Limitless
::
LineChart
([
@
Limitless
::
BarChart
([
'raw'
=>
$rawData
'stacked'
=>
true
,
'categories'
=>
$categories
,
'series'
=>
$seriesData
,
])
])
@
Limitless
::
CardStop
@
Limitless
::
CardStop
{{
--
@
Limitless
::
CardStart
([
'title'
=>
"Chart 3"
,
'icon'
=>
'icon-info22'
]
)
--
}}
@
Limitless
::
CardStart
([
'title'
=>
"Stacked Setup"
,
'icon'
=>
'icon-info22'
]
)
{{
--
@
Limitless
::
LineChartStart
--
}}
@
Limitless
::
BarChart
([
{{
--
@
Limitless
::
LineChartStop
--
}}
'stacked'
=>
true
,
{{
--
@
Limitless
::
CardStop
--
}}
'categories'
=>
$categories
,
'series'
=>
$seriesData
,
])
@
Limitless
::
CardStop
@
stop
@
stop
src/Views/Limitless/Linechart/Documentation/Index.blade.php
View file @
d3e301af
...
@@ -144,7 +144,7 @@
...
@@ -144,7 +144,7 @@
])
])
@
Limitless
::
CardStop
@
Limitless
::
CardStop
@
Limitless
::
CardStart
([
'title'
=>
"Area Setup"
,
'icon'
=>
'icon-info22'
]
)
@
Limitless
::
CardStart
([
'title'
=>
"
Stacked
Area Setup"
,
'icon'
=>
'icon-info22'
]
)
@
Limitless
::
LineChart
([
@
Limitless
::
LineChart
([
'is-area'
=>
true
,
'is-area'
=>
true
,
'stacked'
=>
true
,
'stacked'
=>
true
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment