Skip to content

Commit

Permalink
Bump version to 1.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Shmew committed Sep 21, 2020
1 parent bb6edec commit 215bc53
Show file tree
Hide file tree
Showing 23 changed files with 264 additions and 167 deletions.
1 change: 1 addition & 0 deletions Feliz.Plotly.sln
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,7 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Candlestick", "Candlestick", "{3052EA28-E449-4B96-8DE6-D6029C1B28FF}"
ProjectSection(SolutionItems) = preProject
public\Plotly\Examples\Financial\Candlestick\Basic.md = public\Plotly\Examples\Financial\Candlestick\Basic.md
public\Plotly\Examples\Financial\Candlestick\RangeBreaks.md = public\Plotly\Examples\Financial\Candlestick\RangeBreaks.md
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Funnel", "Funnel", "{003801FD-8747-498B-8AF8-4AC182E68ECA}"
Expand Down
3 changes: 3 additions & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
### 1.4.1 - Sunday, September 20th, 2020
* Fix issue with axis rangebreaks

### 1.4.0 - Monday, September 15th, 2020
* Update for react-plotly.js 2.5.0 release

Expand Down
5 changes: 4 additions & 1 deletion docs/App.fs
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,8 @@ let samples =

let financialExamples =
let candlestick =
[ "plotly-chart-candlestick-basic", Samples.Candlestick.Basic.chart() ]
[ "plotly-chart-candlestick-basic", Samples.Candlestick.Basic.chart()
"plotly-chart-candlestick-rangebreaks", Samples.Candlestick.RangeBreaks.chart() ]

let funnel =
[ "plotly-chart-funnel-basic", Samples.Funnel.Basic.chart()
Expand Down Expand Up @@ -916,6 +917,7 @@ let allItems = React.functionComponent(fun (input: {| state: State; dispatch: Ms
]
subNestedMenuList "Candlestick" [ Urls.Candlestick ] [
nestedMenuItem "Basic" [ Urls.Basic ]
nestedMenuItem "Range Breaks" [ Urls.RangeBreaks ]
]
subNestedMenuList "Funnel" [ Urls.Funnel ] [
nestedMenuItem "Basic" [ Urls.Basic ]
Expand Down Expand Up @@ -1343,6 +1345,7 @@ let financialExamples (currentPath: string list) =
| Urls.Candlestick :: rest ->
match rest with
| [ Urls.Basic ] -> [ "Basic.md" ]
| [ Urls.RangeBreaks ] -> [ "RangeBreaks.md" ]
| _ -> []
|> List.append [ Urls.Candlestick ]
| Urls.Funnel :: rest ->
Expand Down
1 change: 1 addition & 0 deletions docs/App.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
<Compile Include="Plotly\Examples\Maps\FilledArea.fs" />
<Compile Include="Plotly\Examples\Maps\Choropleth.fs" />
<Compile Include="Plotly\Examples\Financial\Candlestick\Basic.fs" />
<Compile Include="Plotly\Examples\Financial\Candlestick\RangeBreaks.fs" />
<Compile Include="Plotly\Examples\Financial\Funnel\Basic.fs" />
<Compile Include="Plotly\Examples\Financial\Funnel\FunnelArea.fs" />
<Compile Include="Plotly\Examples\Financial\Indicators\Showcase.fs" />
Expand Down
97 changes: 97 additions & 0 deletions docs/Plotly/Examples/Financial/Candlestick/RangeBreaks.fs
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
[<RequireQualifiedAccess>]
module Samples.Candlestick.RangeBreaks

open Feliz
open Feliz.Plotly
open System

let xData =
let startDate = DateTime(2017, 1, 3)

List.unfold (fun d ->
if (d - startDate).TotalDays >= 43. then None
else Some (d.AddDays(1.), d.AddDays(1.))
) startDate

let closeData =
[ 116.019997; 116.610001; 117.910004; 118.989998; 119.110001; 119.75; 119.25; 119.040001
120.; 119.989998; 119.779999; 120.; 120.080002; 119.970001; 121.879997; 121.940002
121.949997; 121.629997; 121.349998; 128.75; 128.529999; 129.080002; 130.289993; 131.529999
132.039993; 132.419998; 132.119995; 133.289993; 135.020004; 135.509995 ]

let highData =
[ 116.510002; 116.860001; 118.160004; 119.43; 119.379997; 119.93; 119.300003; 119.620003
120.239998; 120.5; 120.089996; 120.449997; 120.809998; 120.099998; 122.099998; 122.440002
122.349998; 121.629997; 121.389999; 130.490005; 129.389999; 129.190002; 130.5; 132.089996
132.220001; 132.449997; 132.940002; 133.820007; 135.089996; 136.270004 ]

let lowData =
[ 115.75; 115.809998; 116.470001; 117.940002; 118.300003; 118.599998; 118.209999; 118.809998
118.220001; 119.709999; 119.370003; 119.730003; 119.769997; 119.5; 120.279999; 121.599998
121.599998; 120.660004; 120.620003; 127.010002; 127.779999; 128.160004; 128.899994
130.449997; 131.220001; 131.119995; 132.050003; 132.75; 133.25; 134.619995 ]

let openData =
[ 115.849998; 115.919998; 116.779999; 117.949997; 118.769997; 118.739998; 118.900002
119.110001; 118.339996; 120.; 119.400002; 120.449997; 120.; 119.550003; 120.419998;
121.669998; 122.139999; 120.93; 121.150002; 127.029999; 127.980003; 128.309998; 129.130005
130.539993; 131.350006; 131.649994; 132.460007; 133.080002; 133.470001; 135.520004 ]

let chart () =
Plotly.plot [
plot.traces [
traces.candlestick [
candlestick.x xData
candlestick.close closeData
candlestick.high highData
candlestick.low lowData
candlestick.open' openData
candlestick.decreasing [
decreasing.line [
line.color "#7F7F7F"
]
]
candlestick.increasing [
increasing.line [
line.color "#17BECF"
]
]
candlestick.line [
line.color (color.rgba(31, 119, 100, 1.))
]
candlestick.xaxis "x"
candlestick.yaxis "y"
]
]
plot.layout [
layout.dragmode.zoom
layout.margin [
margin.r 10
margin.t 25
margin.b 40
margin.l 60
]
layout.showlegend false
layout.xaxis [
xaxis.autorange.true'
xaxis.domain [ 0; 1 ]
xaxis.range [ DateTime(2017, 1, 3, 12, 0, 0); DateTime(2017, 2, 15, 12, 0, 0) ]
xaxis.rangebreaks [
rangebreaks.rangebreak [
rangebreak.bounds [ DayOfWeek.Saturday; DayOfWeek.Monday ]
rangebreak.pattern.dayOfWeek
]
]
xaxis.title [
title.text "Date"
]
xaxis.type'.date
]
layout.yaxis [
yaxis.autorange.true'
yaxis.domain [ 0; 1 ]
yaxis.range [ 114.609999778; 137.410004222 ]
yaxis.type'.linear
]
]
]
2 changes: 2 additions & 0 deletions docs/Urls.fs
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ let [<Literal>] SizeScaling = "SizeScaling"
// Candlestick Examples
let [<Literal>] Candlestick = "Candlestick"

let [<Literal>] RangeBreaks = "RangeBreaks"

// Carpet Examples
let [<Literal>] Carpet = "Carpet"

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "feliz.-plotly",
"version": "1.4.0",
"version": "1.4.1",
"description": "Fable bindings written in the Feliz-style for plotly.js",
"homepage": "https://github.com/Shmew/Feliz.Plotly",
"bugs": {
Expand Down
2 changes: 0 additions & 2 deletions public/0.bundle.6f5e8d9a30b38859e6ad.js

This file was deleted.

1 change: 0 additions & 1 deletion public/0.bundle.6f5e8d9a30b38859e6ad.js.map

This file was deleted.

113 changes: 0 additions & 113 deletions public/2.bundle.6f5e8d9a30b38859e6ad.js

This file was deleted.

1 change: 0 additions & 1 deletion public/2.bundle.6f5e8d9a30b38859e6ad.js.map

This file was deleted.

101 changes: 101 additions & 0 deletions public/Plotly/Examples/Financial/Candlestick/RangeBreaks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
# Feliz.Plotly - Candlestick Charts With Range Breaks

```fsharp:plotly-chart-candlestick-rangebreaks
[<RequireQualifiedAccess>]
module Samples.Candlestick.RangeBreaks
open Feliz
open Feliz.Plotly
open System
let xData =
let startDate = DateTime(2017, 1, 3)
List.unfold (fun d ->
if (d - startDate).TotalDays >= 43. then None
else Some (d.AddDays(1.), d.AddDays(1.))
) startDate
let closeData =
[ 116.019997; 116.610001; 117.910004; 118.989998; 119.110001; 119.75; 119.25; 119.040001
120.; 119.989998; 119.779999; 120.; 120.080002; 119.970001; 121.879997; 121.940002
121.949997; 121.629997; 121.349998; 128.75; 128.529999; 129.080002; 130.289993; 131.529999
132.039993; 132.419998; 132.119995; 133.289993; 135.020004; 135.509995 ]
let highData =
[ 116.510002; 116.860001; 118.160004; 119.43; 119.379997; 119.93; 119.300003; 119.620003
120.239998; 120.5; 120.089996; 120.449997; 120.809998; 120.099998; 122.099998; 122.440002
122.349998; 121.629997; 121.389999; 130.490005; 129.389999; 129.190002; 130.5; 132.089996
132.220001; 132.449997; 132.940002; 133.820007; 135.089996; 136.270004 ]
let lowData =
[ 115.75; 115.809998; 116.470001; 117.940002; 118.300003; 118.599998; 118.209999; 118.809998
118.220001; 119.709999; 119.370003; 119.730003; 119.769997; 119.5; 120.279999; 121.599998
121.599998; 120.660004; 120.620003; 127.010002; 127.779999; 128.160004; 128.899994
130.449997; 131.220001; 131.119995; 132.050003; 132.75; 133.25; 134.619995 ]
let openData =
[ 115.849998; 115.919998; 116.779999; 117.949997; 118.769997; 118.739998; 118.900002
119.110001; 118.339996; 120.; 119.400002; 120.449997; 120.; 119.550003; 120.419998;
121.669998; 122.139999; 120.93; 121.150002; 127.029999; 127.980003; 128.309998; 129.130005
130.539993; 131.350006; 131.649994; 132.460007; 133.080002; 133.470001; 135.520004 ]
let chart () =
Plotly.plot [
plot.traces [
traces.candlestick [
candlestick.x xData
candlestick.close closeData
candlestick.high highData
candlestick.low lowData
candlestick.open' openData
candlestick.decreasing [
decreasing.line [
line.color "#7F7F7F"
]
]
candlestick.increasing [
increasing.line [
line.color "#17BECF"
]
]
candlestick.line [
line.color (color.rgba(31, 119, 100, 1.))
]
candlestick.xaxis "x"
candlestick.yaxis "y"
]
]
plot.layout [
layout.dragmode.zoom
layout.margin [
margin.r 10
margin.t 25
margin.b 40
margin.l 60
]
layout.showlegend false
layout.xaxis [
xaxis.autorange.true'
xaxis.domain [ 0; 1 ]
xaxis.range [ DateTime(2017, 1, 3, 12, 0, 0); DateTime(2017, 2, 15, 12, 0, 0) ]
xaxis.rangebreaks [
rangebreaks.rangebreak [
rangebreak.bounds [ DayOfWeek.Saturday; DayOfWeek.Monday ]
rangebreak.pattern.dayOfWeek
]
]
xaxis.title [
title.text "Date"
]
xaxis.type'.date
]
layout.yaxis [
yaxis.autorange.true'
yaxis.domain [ 0; 1 ]
yaxis.range [ 114.609999778; 137.410004222 ]
yaxis.type'.linear
]
]
]
```
3 changes: 3 additions & 0 deletions public/Plotly/RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
### 1.4.1 - Sunday, September 20th, 2020
* Fix issue with axis rangebreaks

### 1.4.0 - Monday, September 15th, 2020
* Update for react-plotly.js 2.5.0 release

Expand Down
2 changes: 0 additions & 2 deletions public/bundle.6f5e8d9a30b38859e6ad.js

This file was deleted.

1 change: 0 additions & 1 deletion public/bundle.6f5e8d9a30b38859e6ad.js.map

This file was deleted.

2 changes: 1 addition & 1 deletion public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,5 @@
<div id="root">

</div>
<script type="text/javascript" src="bundle.6f5e8d9a30b38859e6ad.js"></script><script type="text/javascript" src="2.bundle.6f5e8d9a30b38859e6ad.js"></script><script type="text/javascript" src="0.bundle.6f5e8d9a30b38859e6ad.js"></script></body>
</body>
</html>
11 changes: 10 additions & 1 deletion src/Feliz.Generator.Plotly/ApiParser.fs
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ module ApiParser =
|> EnumPropOverload.setParamsCode paramsCode)
| ValType.EnumeratedWithCustom when v = "custom" && componentParent = "Line" && propName = "dash" ->
let valueCode, paramsCode =
[ ValType.intSeqResizeStr; ValType.floatSeqResizeStr ] |> List.unzip
[ ValType.intSeqStr; ValType.floatSeqStr ] |> List.unzip

paramsCode
|> List.map2
Expand Down Expand Up @@ -1017,6 +1017,15 @@ module ApiParser =
("(properties: #ITransformsProperty list)",
"(properties |> List.map (Bindings.getKV >> snd) |> Array.ofList)")
||> RegularPropOverload.create
] }
"rangebreaks",
fun (prop: Prop) ->
{ prop with
MethodName = "rangebreaks"
RegularOverloads = [
("(properties: #IRangebreaksProperty list)",
"(properties |> List.map (Bindings.getKV >> snd) |> Array.ofList)")
||> RegularPropOverload.create
] } ]
|> Map.ofList

Expand Down
8 changes: 4 additions & 4 deletions src/Feliz.Generator.Plotly/AssemblyInfo.fs
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ open System.Runtime.CompilerServices
[<assembly: AssemblyTitleAttribute("Feliz.Generator.Plotly")>]
[<assembly: AssemblyProductAttribute("Feliz.Plotly")>]
[<assembly: AssemblyDescriptionAttribute("Fable bindings written in the Feliz-style for plotly.js")>]
[<assembly: AssemblyVersionAttribute("1.4.0")>]
[<assembly: AssemblyFileVersionAttribute("1.4.0")>]
[<assembly: AssemblyVersionAttribute("1.4.1")>]
[<assembly: AssemblyFileVersionAttribute("1.4.1")>]
[<assembly: AssemblyConfigurationAttribute("Release")>]
[<assembly: InternalsVisibleToAttribute("Feliz.Generator.Plotly.Tests")>]
do ()
Expand All @@ -16,7 +16,7 @@ module internal AssemblyVersionInformation =
let [<Literal>] AssemblyTitle = "Feliz.Generator.Plotly"
let [<Literal>] AssemblyProduct = "Feliz.Plotly"
let [<Literal>] AssemblyDescription = "Fable bindings written in the Feliz-style for plotly.js"
let [<Literal>] AssemblyVersion = "1.4.0"
let [<Literal>] AssemblyFileVersion = "1.4.0"
let [<Literal>] AssemblyVersion = "1.4.1"
let [<Literal>] AssemblyFileVersion = "1.4.1"
let [<Literal>] AssemblyConfiguration = "Release"
let [<Literal>] InternalsVisibleTo = "Feliz.Generator.Plotly.Tests"
Loading

0 comments on commit 215bc53

Please sign in to comment.