diff --git a/Packages.targets b/Packages.targets index a0b3a1cef..d2759339e 100644 --- a/Packages.targets +++ b/Packages.targets @@ -2,9 +2,9 @@ - - - + + + diff --git a/docs/views-elements.md b/docs/views-elements.md index ae1140704..6e182abda 100644 --- a/docs/views-elements.md +++ b/docs/views-elements.md @@ -500,6 +500,74 @@ See also: * [Xamarin.Forms.Core.SearchBar](https://docs.microsoft.com/en-us/dotnet/api/xamarin.forms.searchbar?view=xamarin-forms) + +### CollectionView, CarouselView, Shell + +`CollectionView`, `CarouselView` and `Shell` are available in preview in Xamarin.Forms 3.5. +Please read the Xamarin.Forms documentation to check whether those controls are available for the platforms you target. + +Fabulous provides an initial but partial support for them. +We will fully support them once officially released. + +As they are experimental, each one of these controls requires a flag before they can be used. +- Shell = Shell_Experimental +- CollectionView/CarouselView = CollectionView_Experimental + +```fsharp + +// iOS +[] +type AppDelegate () = + inherit FormsApplicationDelegate () + + override this.FinishedLaunching (uiApp, options) = + Xamarin.Forms.Forms.SetFlags([|"Shell_Experimental"; "CollectionView_Experimental"|]); + (...) + +// Android +[] +type MainActivity() = + inherit FormsApplicationActivity() + + override this.OnCreate (bundle: Bundle) = + base.OnCreate (bundle) + global.Xamarin.Forms.Forms.SetFlags([|"Shell_Experimental"; "CollectionView_Experimental"|]) + (...) +``` + +Usage: +```fsharp +View.Shell(title = "TitleShell", + items = [ + View.ShellItem( + items = [ + View.ShellSection(items = [ + View.ShellContent(title = "Section 1", content = View.ContentPage(content = View.Button(text = "Button"))) + ]) + ]) + ]) + +View.CarouselView(itemsSource = [ + View.Label(text="Person1") + View.Label(text="Person2") + View.Label(text="Person3") + View.Label(text="Person4") + View.Label(text="Person5") + ]) + +View.CollectionView(items=[ + View.Label(text="Person1") + View.Label(text="Person2") + View.Label(text="Person3") + View.Label(text="Person4") + View.Label(text="Person5") + ]) +``` + +See also: + +* [Xamarin.Forms 4.0 Preview](https://devblogs.microsoft.com/xamarin/xamarin-forms-4-0-preview/) + Gestures ------------------- diff --git a/paket.dependencies b/paket.dependencies index e7a5d3d81..02cdf47a9 100644 --- a/paket.dependencies +++ b/paket.dependencies @@ -29,8 +29,8 @@ group neutral github fsprojects/FSharp.Compiler.PortaCode:master tests/PortaCodeTests.fs nuget FSharp.Core 4.5.2 - nuget Xamarin.Forms 3.4.0.1009999 - nuget Xamarin.Forms.Maps 3.4.0.1009999 + nuget Xamarin.Forms 3.5.0.129452 + nuget Xamarin.Forms.Maps 3.5.0.129452 nuget SkiaSharp nuget SkiaSharp.Views.Forms nuget OxyPlot.Xamarin.Forms 1.0.0 @@ -42,7 +42,7 @@ group androidapp framework: monoandroid71 source https://api.nuget.org/v3/index.json nuget FSharp.Core 4.5.2 - nuget Xamarin.Forms 3.4.0.1009999 + nuget Xamarin.Forms 3.5.0.129452 nuget Xamarin.Android.FSharp.ResourceProvider 1.0.0.25 nuget Xamarin.Android.Arch.Core.Common 1.0.0.1 nuget Xamarin.Android.Arch.Core.Runtime 1.0.0.1 @@ -73,7 +73,7 @@ group iosapp framework: monotouch source https://api.nuget.org/v3/index.json nuget FSharp.Core 4.5.2 - nuget Xamarin.Forms 3.4.0.1009999 + nuget Xamarin.Forms 3.5.0.129452 nuget Newtonsoft.Json 11.0.2 nuget FSharp.Data 3.0.0 @@ -81,7 +81,7 @@ group macosapp framework: xamarinmac20 source https://api.nuget.org/v3/index.json nuget FSharp.Core 4.5.2 - nuget Xamarin.Forms 3.4.0.1009999 + nuget Xamarin.Forms 3.5.0.129452 nuget Newtonsoft.Json 11.0.2 nuget FSharp.Data 3.0.0 @@ -89,16 +89,16 @@ group wpfapp framework: net472 source https://api.nuget.org/v3/index.json nuget FSharp.Core 4.5.2 - nuget Xamarin.Forms 3.4.0.1009999 + nuget Xamarin.Forms 3.5.0.129452 nuget Newtonsoft.Json 11.0.2 - nuget Xamarin.Forms.Platform.WPF 3.4.0.1009999 + nuget Xamarin.Forms.Platform.WPF 3.5.0.129452 nuget FSharp.Data 3.0.0 group gtkapp framework: net471 source https://api.nuget.org/v3/index.json nuget FSharp.Core 4.5.2 - nuget Xamarin.Forms 3.4.0.1009999 + nuget Xamarin.Forms 3.5.0.129452 nuget Newtonsoft.Json 11.0.2 - nuget Xamarin.Forms.Platform.GTK 3.4.0.1009999 + nuget Xamarin.Forms.Platform.GTK 3.5.0.129452 nuget FSharp.Data 3.0.0 \ No newline at end of file diff --git a/paket.lock b/paket.lock index 981d70953..39c37afa1 100644 --- a/paket.lock +++ b/paket.lock @@ -156,7 +156,7 @@ NUGET Xamarin.Android.Support.v7.Palette (27.0.2.1) Xamarin.Android.Support.v7.RecyclerView (27.0.2.1) Xamarin.Android.Support.Vector.Drawable (27.0.2.1) - Xamarin.Forms (3.4.0.1009999) + Xamarin.Forms (3.5.0.129452) GROUP fakebuild STORAGE: NONE @@ -797,9 +797,9 @@ NUGET FSharp.Data (3.0) FSharp.Core (>= 4.0.0.1) Newtonsoft.Json (11.0.2) - Xamarin.Forms (3.4.0.1009999) - Xamarin.Forms.Platform.GTK (3.4.0.1009999) - Xamarin.Forms (>= 3.4.0.1009999) + Xamarin.Forms (3.5.0.129452) + Xamarin.Forms.Platform.GTK (3.5.0.129452) + Xamarin.Forms (>= 3.5.0.129452) GROUP iosapp RESTRICTION: == monotouch @@ -936,7 +936,7 @@ NUGET System.Xml.ReaderWriter (4.3.1) System.Xml.XDocument (4.3) System.Xml.XmlDocument (4.3) - Xamarin.Forms (3.4.0.1009999) + Xamarin.Forms (3.5.0.129452) GROUP macosapp RESTRICTION: == xamarinmac @@ -1073,7 +1073,7 @@ NUGET System.Xml.ReaderWriter (4.3.1) System.Xml.XDocument (4.3) System.Xml.XmlDocument (4.3) - Xamarin.Forms (3.4.0.1009999) + Xamarin.Forms (3.5.0.129452) GROUP neutral RESTRICTION: == netstandard2.0 @@ -1089,9 +1089,9 @@ NUGET SkiaSharp.Views.Forms (1.68) SkiaSharp (>= 1.68) Xamarin.Forms (>= 3.3.0.912540) - Xamarin.Forms (3.4.0.1009999) - Xamarin.Forms.Maps (3.4.0.1009999) - Xamarin.Forms (>= 3.4.0.1009999) + Xamarin.Forms (3.5.0.129452) + Xamarin.Forms.Maps (3.5.0.129452) + Xamarin.Forms (>= 3.5.0.129452) GITHUB remote: fsprojects/FSharp.Compiler.PortaCode src/CodeModel.fs (0c6686bcc518246d879bb3d0e3cd4cdbbc72d5ad) @@ -1111,8 +1111,8 @@ NUGET OpenTK (3.0.1) OpenTK.GLControl (3.0.1) OpenTK (>= 3.0.1) - Xamarin.Forms (3.4.0.1009999) - Xamarin.Forms.Platform.WPF (3.4.0.1009999) + Xamarin.Forms (3.5.0.129452) + Xamarin.Forms.Platform.WPF (3.5.0.129452) OpenTK (>= 2.0) OpenTK.GLControl (>= 1.1.2349.61993) - Xamarin.Forms (>= 3.4.0.1009999) + Xamarin.Forms (>= 3.5.0.129452) diff --git a/samples/AllControls/AllControls/AllControls.fs b/samples/AllControls/AllControls/AllControls.fs index 7b18acff4..1de0117d2 100644 --- a/samples/AllControls/AllControls/AllControls.fs +++ b/samples/AllControls/AllControls/AllControls.fs @@ -19,6 +19,9 @@ type RootPageKind = | Animations | WebCall | ScrollView + | ShellView + | CollectionView + | CarouselView type Model = { RootPageKind: RootPageKind @@ -115,6 +118,8 @@ type Msg = | ScrollFabulous of float * float * AnimationKind | ScrollXamarinForms of float * float * AnimationKind | Scrolled of float * float + // For ShellView page demo + //| ShowShell [] module MyExtension = @@ -342,8 +347,8 @@ module App = [ yield View.ContentPage(useSafeArea=true, padding = new Thickness (10.0, 20.0, 10.0, 5.0), - content= View.StackLayout( - children=[ + content= View.ListView( + items=[ View.Button(text = "TabbedPage #1 (various controls)", command=(fun () -> dispatch (SetRootPageKind Tabbed1))) View.Button(text = "TabbedPage #2 (various controls)", command=(fun () -> dispatch (SetRootPageKind Tabbed2))) View.Button(text = "TabbedPage #3 (various controls)", command=(fun () -> dispatch (SetRootPageKind Tabbed3))) @@ -355,11 +360,14 @@ module App = View.Button(text = "Pop-up", command=(fun () -> dispatch ShowPopup)) View.Button(text = "WebRequest", command=(fun () -> dispatch (SetRootPageKind WebCall))) View.Button(text = "ScrollView", command=(fun () -> dispatch (SetRootPageKind ScrollView))) + View.Button(text = "Shell", command=(fun () -> dispatch (SetRootPageKind ShellView))) + View.Button(text = "CollectionView", command=(fun () -> dispatch (SetRootPageKind CollectionView))) + View.Button(text = "CarouselView", command=(fun () -> dispatch (SetRootPageKind CarouselView))) ])) - .ToolbarItems([View.ToolbarItem(text="About", command=(fun () -> dispatch (SetRootPageKind (Choice true))))] ) + .ToolbarItems([View.ToolbarItem(text="about", command=(fun () -> dispatch (SetRootPageKind (Choice true))))] ) .TitleView(View.StackLayout(orientation=StackOrientation.Horizontal, children=[ - View.Label(text="Fabulous", verticalOptions=LayoutOptions.Center) - View.Label(text="RootPage", verticalOptions=LayoutOptions.Center, horizontalOptions=LayoutOptions.CenterAndExpand) + View.Label(text="fabulous", verticalOptions=LayoutOptions.Center) + View.Label(text="rootpage", verticalOptions=LayoutOptions.Center, horizontalOptions=LayoutOptions.CenterAndExpand) ] )) @@ -910,7 +918,74 @@ module App = ) ] ) - ) + ) + | ShellView -> + + match Device.RuntimePlatform with + | Device.iOS | Device.Android -> + + View.Shell( title = "TitleShell", + items = [ + View.ShellItem( + items = [ + View.ShellSection(items = [ + View.ShellContent(content=View.ContentPage(content=MainPageButton, title="ContentpageTitle")) + ]) + ]) + ]) + | _ -> View.ContentPage(content = View.Label(text="Your Platform does not support Shell")) + + | CollectionView -> + match Device.RuntimePlatform with + | Device.iOS | Device.Android -> + View.ContentPage(content=View.StackLayout(children = [ + MainPageButton + // use Collectionview instead of listview + View.CollectionView(items= [ + View.Label(text="Person 1") + View.Label(text="Person2") + View.Label(text="Person3") + View.Label(text="Person4") + View.Label(text="Person5") + View.Label(text="Person6") + View.Label(text="Person7") + View.Label(text="Person8") + View.Label(text="Person9") + View.Label(text="Person11") + View.Label(text="Person12") + View.Label(text="Person13") + View.Label(text="Person14")] ) + ] + )) + + | _ -> View.ContentPage(content = View.Label(text="Your Platform does not support CollectionView")) + + | CarouselView -> + match Device.RuntimePlatform with + | Device.iOS | Device.Android -> + View.ContentPage(content= + View.StackLayout( + children = [ + MainPageButton + View.CarouselView(itemsSource = [ + View.Label(text="Person1") + View.Label(text="Person2") + View.Label(text="Person3") + View.Label(text="Person4") + View.Label(text="Person5") + View.Label(text="Person6") + View.Label(text="Person7") + View.Label(text="Person8") + View.Label(text="Person9") + View.Label(text="Person11") + View.Label(text="Person12") + View.Label(text="Person13") + View.Label(text="Person14") + ], margin=10.) + ] + )) + + | _ -> View.ContentPage(content = View.Label(text="Your Platform does not support CarouselView")) type App () as app = diff --git a/samples/AllControls/Droid/AllControls.Droid.fsproj b/samples/AllControls/Droid/AllControls.Droid.fsproj index 53208fa60..6724213b8 100644 --- a/samples/AllControls/Droid/AllControls.Droid.fsproj +++ b/samples/AllControls/Droid/AllControls.Droid.fsproj @@ -150,19 +150,19 @@ ../../../packages/androidapp/Xamarin.Android.Support.Vector.Drawable/lib/MonoAndroid81/Xamarin.Android.Support.Vector.Drawable.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Core.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Core.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/FormsViewGroup.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/FormsViewGroup.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.Android.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.Android.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Xaml.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Xaml.dll ../../../packages/androidapp/FSharp.Core/lib/netstandard1.6/FSharp.Core.dll diff --git a/samples/AllControls/Droid/MainActivity.fs b/samples/AllControls/Droid/MainActivity.fs index 68b32ee85..822fe3f1e 100644 --- a/samples/AllControls/Droid/MainActivity.fs +++ b/samples/AllControls/Droid/MainActivity.fs @@ -20,7 +20,8 @@ type MainActivity() = override this.OnCreate (bundle: Bundle) = base.OnCreate (bundle) - + global.Xamarin.Forms.Forms.SetFlags([|"Shell_Experimental"; "CollectionView_Experimental"; "Visual_Experimental"|]) + Xamarin.Forms.Forms.Init (this, bundle) let app = new AllControls.App() diff --git a/samples/AllControls/iOS/AppDelegate.fs b/samples/AllControls/iOS/AppDelegate.fs index 05db4acac..84e4ecfa6 100644 --- a/samples/AllControls/iOS/AppDelegate.fs +++ b/samples/AllControls/iOS/AppDelegate.fs @@ -15,6 +15,7 @@ type AppDelegate () = let mutable _app: AllControls.App option = None override this.FinishedLaunching (uiApp, options) = + Xamarin.Forms.Forms.SetFlags([|"Shell_Experimental"; "CollectionView_Experimental"; "Visual_Experimental"|]); Forms.Init() let app = new AllControls.App() this.LoadApplication (app) diff --git a/samples/Calculator/Droid/Calculator.Droid.fsproj b/samples/Calculator/Droid/Calculator.Droid.fsproj index c8444aa18..ef5bb267b 100644 --- a/samples/Calculator/Droid/Calculator.Droid.fsproj +++ b/samples/Calculator/Droid/Calculator.Droid.fsproj @@ -153,19 +153,19 @@ ../../../packages/androidapp/Xamarin.Android.Support.Vector.Drawable/lib/MonoAndroid81/Xamarin.Android.Support.Vector.Drawable.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Core.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Core.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.Android.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.Android.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/FormsViewGroup.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/FormsViewGroup.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Xaml.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Xaml.dll {B459AFAD-BB5B-43C3-BD86-609E8DB3E3FD} diff --git a/samples/CounterApp/Droid/CounterApp.Droid.fsproj b/samples/CounterApp/Droid/CounterApp.Droid.fsproj index 8b216e6e8..6f920def2 100644 --- a/samples/CounterApp/Droid/CounterApp.Droid.fsproj +++ b/samples/CounterApp/Droid/CounterApp.Droid.fsproj @@ -153,19 +153,19 @@ ../../../packages/androidapp/Xamarin.Android.Support.Vector.Drawable/lib/MonoAndroid81/Xamarin.Android.Support.Vector.Drawable.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Core.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Core.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.Android.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.Android.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/FormsViewGroup.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/FormsViewGroup.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Xaml.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Xaml.dll {AC36B11A-383D-45A3-8999-4F6475E9DD13} diff --git a/samples/StaticView/StaticViewCounterApp/Droid/StaticViewCounterApp.Droid.fsproj b/samples/StaticView/StaticViewCounterApp/Droid/StaticViewCounterApp.Droid.fsproj index ef44b565d..22ee89f15 100644 --- a/samples/StaticView/StaticViewCounterApp/Droid/StaticViewCounterApp.Droid.fsproj +++ b/samples/StaticView/StaticViewCounterApp/Droid/StaticViewCounterApp.Droid.fsproj @@ -148,19 +148,19 @@ ../../../../packages/androidapp/Xamarin.Android.Support.Vector.Drawable/lib/MonoAndroid81/Xamarin.Android.Support.Vector.Drawable.dll - ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Core.dll + ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Core.dll - ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.dll + ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.dll - ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.Android.dll + ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.Android.dll - ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/FormsViewGroup.dll + ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/FormsViewGroup.dll - ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Xaml.dll + ../../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Xaml.dll ../../../../packages/androidapp/FSharp.Core/lib/netstandard1.6/FSharp.Core.dll diff --git a/samples/TicTacToe/Droid/TicTacToe.Droid.fsproj b/samples/TicTacToe/Droid/TicTacToe.Droid.fsproj index d7453650f..82bf67a2c 100644 --- a/samples/TicTacToe/Droid/TicTacToe.Droid.fsproj +++ b/samples/TicTacToe/Droid/TicTacToe.Droid.fsproj @@ -161,19 +161,19 @@ ../../../packages/androidapp/Xamarin.Android.Support.Vector.Drawable/lib/MonoAndroid81/Xamarin.Android.Support.Vector.Drawable.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Core.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Core.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/FormsViewGroup.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/FormsViewGroup.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Platform.Android.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Platform.Android.dll - ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid10/Xamarin.Forms.Xaml.dll + ../../../packages/androidapp/Xamarin.Forms/lib/MonoAndroid81/Xamarin.Forms.Xaml.dll ../../../packages/androidapp/FSharp.Core/lib/netstandard1.6/FSharp.Core.dll diff --git a/samples/paket.dependencies b/samples/paket.dependencies new file mode 100644 index 000000000..f288f1ee5 --- /dev/null +++ b/samples/paket.dependencies @@ -0,0 +1 @@ +# This file is here to prevent `paket install` to try add dependencies to the samples \ No newline at end of file diff --git a/src/Fabulous.Cli/fscd.fs b/src/Fabulous.Cli/fscd.fs index 9f4a364db..51c9b52dd 100644 --- a/src/Fabulous.Cli/fscd.fs +++ b/src/Fabulous.Cli/fscd.fs @@ -33,6 +33,7 @@ module MockForms = member __.GetAssemblies() = [| |] // raise (NotImplementedException()) member __.GetUserStoreForApplication() = raise (NotImplementedException()) member __.QuitApplication() = raise (NotImplementedException()) + member __.GetNativeSize(view, widthConstraint, heightConstraint) = raise (NotImplementedException()) type MockDeserializer() = interface IDeserializer with diff --git a/src/Fabulous.Core/ViewConverters.fs b/src/Fabulous.Core/ViewConverters.fs index d8c7d14e7..a24569329 100644 --- a/src/Fabulous.Core/ViewConverters.fs +++ b/src/Fabulous.Core/ViewConverters.fs @@ -24,6 +24,11 @@ type IListElement = inherit INotifyPropertyChanged abstract Key : ViewElement +[] +type IItemListElement = + inherit INotifyPropertyChanged + abstract Key : ViewElement + /// A custom data element for the ListView view element [] type ListElementData(key) = @@ -40,6 +45,21 @@ type ListElementData(key) = data <- value ev.Trigger(x, PropertyChangedEventArgs "Key") +[] +type ItemListElementData(key) = + let ev = new Event<_,_>() + let mutable data = key + + interface IItemListElement with + member x.Key = data + [] member x.PropertyChanged = ev.Publish + + member x.Key + with get() = data + and set(value) = + data <- value + ev.Trigger(x, PropertyChangedEventArgs "Key") + /// A custom data element for the GroupedListView view element [] type ListGroupData(shortName: string, key, coll: ViewElement[]) = @@ -111,10 +131,59 @@ type ViewElementCell() = modelOpt <- None | None -> () +type ItemViewElementCell() = + inherit ContentView() + + let mutable listElementOpt : IItemListElement option = None + let mutable modelOpt : ViewElement option = None + + let createView (newModel: ViewElement) = + match newModel.Create () with + | :? View as v -> v + | x -> failwithf "The cells of a CollectionView must each be some kind of 'View' and not a '%A'" (x.GetType()) + + member x.OnDataPropertyChanged = PropertyChangedEventHandler(fun _ args -> + match args.PropertyName, listElementOpt, modelOpt with + | "Key", Some curr, Some prevModel -> + curr.Key.UpdateIncremental (prevModel, x.Content) + modelOpt <- Some curr.Key + | _ -> () + ) + + override x.OnBindingContextChanged () = + base.OnBindingContextChanged () + match x.BindingContext with + | :? IItemListElement as curr -> + let newModel = curr.Key + match listElementOpt with + | Some prev -> + prev.PropertyChanged.RemoveHandler x.OnDataPropertyChanged + curr.PropertyChanged.AddHandler x.OnDataPropertyChanged + newModel.UpdateIncremental (prev.Key, x.Content) + | None -> + curr.PropertyChanged.AddHandler x.OnDataPropertyChanged + x.Content <- createView newModel + + listElementOpt <- Some curr + modelOpt <- Some curr.Key + | _ -> + match listElementOpt with + | Some prev -> + prev.PropertyChanged.RemoveHandler x.OnDataPropertyChanged + listElementOpt <- None + modelOpt <- None + | None -> () + /// A custom control for the ListView view element type CustomListView() = inherit ListView(ItemTemplate=DataTemplate(typeof)) +type CustomCollectionListView() = + inherit CollectionView(ItemTemplate=DataTemplate(typeof)) + +type CustomCarouselView() = + inherit CarouselView(ItemTemplate=DataTemplate(typeof)) + /// A custom control for the ListViewGrouped view element type CustomGroupListView() = inherit ListView(ItemTemplate=DataTemplate(typeof), GroupHeaderTemplate=DataTemplate(typeof), IsGroupingEnabled=true) @@ -214,6 +283,19 @@ module Converters = f index ) + /// Converts a string or uri to a Xamarin.Forms ShellNavigation + let makeUri (v: obj) = + match v with + | :? string as path -> ShellNavigationState.op_Implicit path + | :? Uri as uri -> ShellNavigationState.op_Implicit uri + | _ -> failwithf "makeUri: invalid argument %O" v + + /// Converts a datatemplate to a Xamarin.Forms TemplatedPage + let makeTemplate (v: obj) = + match v with + | :? TemplatedPage as p -> ShellContent.op_Implicit p + | _ -> failwithf "makeTemplate: invalid argument %O" v + /// Checks whether two objects are reference-equal let identical (x: 'T) (y:'T) = System.Object.ReferenceEquals(x, y) @@ -368,6 +450,26 @@ module Converters = oc updateCollectionGeneric (ValueOption.map seqToArray prevCollOpt) (ValueOption.map seqToArray collOpt) targetColl ListElementData (fun _ _ _ -> ()) canReuseChild (fun _ curr target -> target.Key <- curr) + let internal updateCollectionViewItems (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.CollectionView) = + let targetColl = + match target.ItemsSource with + | :? ObservableCollection as oc -> oc + | _ -> + let oc = ObservableCollection() + target.ItemsSource <- oc + oc + updateCollectionGeneric (ValueOption.map seqToArray prevCollOpt) (ValueOption.map seqToArray collOpt) targetColl ItemListElementData (fun _ _ _ -> ()) canReuseChild (fun _ curr target -> target.Key <- curr) + + let internal updateCarouselViewItems (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.CarouselView) = + let targetColl = + match target.ItemsSource with + | :? ObservableCollection as oc -> oc + | _ -> + let oc = ObservableCollection() + target.ItemsSource <- oc + oc + updateCollectionGeneric (ValueOption.map seqToArray prevCollOpt) (ValueOption.map seqToArray collOpt) targetColl ItemListElementData (fun _ _ _ -> ()) canReuseChild (fun _ curr target -> target.Key <- curr) + let private updateListGroupData (_prevShortName: string, _prevKey, prevColl: ViewElement[]) (currShortName: string, currKey, currColl: ViewElement[]) (target: ListGroupData) = target.ShortName <- currShortName target.Key <- currKey @@ -654,6 +756,46 @@ module Converters = | _, ValueNone -> Xamarin.Forms.MenuItem.SetAccelerator(target, null) | _, ValueSome newVal -> Xamarin.Forms.MenuItem.SetAccelerator(target, makeAccelerator newVal) + let internal updateShellItems (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.Shell) = + let create (desc: ViewElement) = + desc.Create() :?> Xamarin.Forms.ShellItem + + let prevArray = ValueOption.map seqToArray prevCollOpt + let currArray = ValueOption.map seqToArray collOpt + updateCollectionGeneric prevArray currArray target.Items create (fun _ _ _ -> ()) (fun _ _ -> true) updateChild + + let internal updateMenuItemsShell (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.Shell) = + let create (desc: ViewElement) = + desc.Create() :?> Xamarin.Forms.MenuItem + + let prevArray = ValueOption.map seqToArray prevCollOpt + let currArray = ValueOption.map seqToArray collOpt + updateCollectionGeneric prevArray currArray target.MenuItems create (fun _ _ _ -> ()) (fun _ _ -> true) updateChild + + let internal updateMenuItemsShellContent (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.ShellContent) = + let create (desc: ViewElement) = + desc.Create() :?> Xamarin.Forms.MenuItem + + let prevArray = ValueOption.map seqToArray prevCollOpt + let currArray = ValueOption.map seqToArray collOpt + updateCollectionGeneric prevArray currArray target.MenuItems create (fun _ _ _ -> ()) (fun _ _ -> true) updateChild + + let internal updateShellItemItems (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.ShellItem) = + let create (desc: ViewElement) = + desc.Create() :?> Xamarin.Forms.ShellSection + + let prevArray = ValueOption.map seqToArray prevCollOpt + let currArray = ValueOption.map seqToArray collOpt + updateCollectionGeneric prevArray currArray target.Items create (fun _ _ _ -> ()) (fun _ _ -> true) updateChild + + let internal updateShellSectionItems (prevCollOpt: seq<'T> voption) (collOpt: seq<'T> voption) (target: Xamarin.Forms.ShellSection) = + let create (desc: ViewElement) = + desc.Create() :?> Xamarin.Forms.ShellContent + + let prevArray = ValueOption.map seqToArray prevCollOpt + let currArray = ValueOption.map seqToArray collOpt + updateCollectionGeneric prevArray currArray target.Items create (fun _ _ _ -> ()) (fun _ _ -> true) updateChild + /// Trigger ScrollView.ScrollToAsync if needed, given the current values let internal triggerScrollToAsync (currValue: (float * float * AnimationKind) voption) (target: Xamarin.Forms.ScrollView) = match currValue with @@ -665,6 +807,41 @@ module Converters = target.ScrollToAsync(x, y, animated) |> ignore | _ -> () + /// Trigger ItemsView.ScrollTo if needed, given the current values + let internal triggerScrollTo (currValue: (obj * obj * ScrollToPosition * AnimationKind) voption) (target: Xamarin.Forms.ItemsView) = + match currValue with + | ValueSome (x, y, scrollToPosition, animationKind) -> + let animated = + match animationKind with + | Animated -> true + | NotAnimated -> false + target.ScrollTo(x,y, scrollToPosition, animated) + | _ -> () + + /// Trigger Shell.GoToAsync if needed, given the current values + let internal triggerGoToAsync (currValue: (ShellNavigationState * AnimationKind) voption) (target: Xamarin.Forms.Shell) = + match currValue with + | ValueSome (navigationState, animationKind) -> + let animated = + match animationKind with + | Animated -> true + | NotAnimated -> false + target.GoToAsync(navigationState, animated) |> ignore + | _ -> () + + /// Trigger ShellSection.GoToAsync if needed, given the current values + let internal triggerSSGoToAsync (currValue: (string list * Map * AnimationKind) voption) (target: Xamarin.Forms.ShellSection) = + match currValue with + | ValueSome (routes, queryData, animationKind) -> + let animated = + match animationKind with + | Animated -> true + | NotAnimated -> false + let lst = ResizeArray() + lst.AddRange(routes) + target.GoToAsync(lst, queryData, animated) |> ignore + | _ -> () + /// Check if two LayoutOptions are equal let internal equalLayoutOptions (x:Xamarin.Forms.LayoutOptions) (y:Xamarin.Forms.LayoutOptions) = x.Alignment = y.Alignment && x.Expands = y.Expands diff --git a/templates/content/blank/.template.config/template.json b/templates/content/blank/.template.config/template.json index 740a720fb..2708ccdf1 100644 --- a/templates/content/blank/.template.config/template.json +++ b/templates/content/blank/.template.config/template.json @@ -149,7 +149,7 @@ "type": "parameter", "dataType": "string", "replaces": "XamarinFormsSdk", - "defaultValue": "3.4.0.1009999" + "defaultValue": "3.5.0.129452" }, "FabulousPkgsVersion": { "type": "parameter", diff --git a/templates/content/blank/NewApp.Android/NewApp.Android.fsproj b/templates/content/blank/NewApp.Android/NewApp.Android.fsproj index f9e7616be..c25d57dbd 100644 --- a/templates/content/blank/NewApp.Android/NewApp.Android.fsproj +++ b/templates/content/blank/NewApp.Android/NewApp.Android.fsproj @@ -157,19 +157,19 @@ ..\packages/Xamarin.Android.Support.Vector.Drawable.XamarinAndroidSdkVersion/lib/MonoAndroid81/Xamarin.Android.Support.Vector.Drawable.dll - ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid10/Xamarin.Forms.Core.dll + ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid81/Xamarin.Forms.Core.dll - ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid10/Xamarin.Forms.Platform.dll + ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid81/Xamarin.Forms.Platform.dll - ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid10/FormsViewGroup.dll + ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid81/FormsViewGroup.dll - ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid10/Xamarin.Forms.Platform.Android.dll + ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid81/Xamarin.Forms.Platform.Android.dll - ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid10/Xamarin.Forms.Xaml.dll + ..\packages/Xamarin.Forms.XamarinFormsSdk/lib/MonoAndroid81/Xamarin.Forms.Xaml.dll ..\packages/FSharp.Core.FSharpCorePkgVersion/lib/netstandard1.6/FSharp.Core.dll diff --git a/templates/paket.dependencies b/templates/paket.dependencies new file mode 100644 index 000000000..792dae169 --- /dev/null +++ b/templates/paket.dependencies @@ -0,0 +1 @@ +# This file is here to prevent `paket install` to try add dependencies to the templates \ No newline at end of file diff --git a/tests/Fabulous.Cli.Tests/Tests.fs b/tests/Fabulous.Cli.Tests/Tests.fs index c6ceb1cfb..3e8d7283c 100644 --- a/tests/Fabulous.Cli.Tests/Tests.fs +++ b/tests/Fabulous.Cli.Tests/Tests.fs @@ -6,7 +6,7 @@ open FsUnit open FSharp.Compiler.PortaCode.Tests.Basic// for TestHelpers module Versions = - let XamarinForms = "3.4.0.1009999" + let XamarinForms = "3.5.0.129452" let NewtonsoftJson = "11.0.2" [] diff --git a/tests/Generator.Tests/ResolverTests.fs b/tests/Generator.Tests/ResolverTests.fs index d4182b597..ddbee8d13 100644 --- a/tests/Generator.Tests/ResolverTests.fs +++ b/tests/Generator.Tests/ResolverTests.fs @@ -73,6 +73,7 @@ module ``Resolvers Tests`` = [| "Xamarin.Forms.Button" "Xamarin.Forms.View" "Xamarin.Forms.VisualElement" + "Xamarin.Forms.NavigableElement" "Xamarin.Forms.Element" "Xamarin.Forms.BindableObject" "System.Object" |] diff --git a/tools/Generator/Xamarin.Forms.Core.json b/tools/Generator/Xamarin.Forms.Core.json index 120ff01d7..09de19049 100644 --- a/tools/Generator/Xamarin.Forms.Core.json +++ b/tools/Generator/Xamarin.Forms.Core.json @@ -392,6 +392,10 @@ "defaultValue": "null", "inputType": "Xamarin.Forms.ScrolledEventArgs -> unit", "convToModel": "(fun f -> System.EventHandler(fun _sender args -> f args))" + }, + { + "name": "LayoutAreaOverride", + "defaultValue": "Xamarin.Forms.Rectangle.Zero" } ] }, @@ -625,6 +629,10 @@ "defaultValue": "null", "inputType": "Xamarin.Forms.ToggledEventArgs -> unit", "convToModel": "(fun f -> System.EventHandler(fun _sender args -> f args))" + }, + { + "name": "OnColor", + "defaultValue": "Xamarin.Forms.Color.Default" } ] }, @@ -1131,6 +1139,12 @@ { "name": "PlaceholderColor", "defaultValue": "Xamarin.Forms.Color.Default" + }, + { + "name": "IsTextPredictionEnabled", + "defaultValue": "false", + "inputType": "bool", + "modelType": "bool" } ] }, @@ -1893,6 +1907,18 @@ { "name": "SelectionMode", "defaultValue": "Xamarin.Forms.ListViewSelectionMode.Single" + }, + { + "name": "HorizontalScrollBarVisibility", + "defaultValue": "Xamarin.Forms.ScrollBarVisibility.Default" + }, + { + "name": "VerticalScrollBarVisibility", + "defaultValue": "Xamarin.Forms.ScrollBarVisibility.Default" + }, + { + "name": "RefreshControlColor", + "defaultValue": "Xamarin.Forms.Color.Default" } ] }, @@ -2002,6 +2028,416 @@ "defaultValue": "Xamarin.Forms.ListViewSelectionMode.Single" } ] + }, + { + "name": "Xamarin.Forms.BackButtonBehavior", + "members": [ + { + "name": "TextOverride", + "defaultValue": "null" + }, + { + "name": "Command", + "defaultValue": "null", + "inputType": "unit -> unit", + "convToModel": "makeCommand" + }, + { + "name": "CommandParameter", + "defaultValue": "null" + }, + { + "name": "IconOverride", + "inputType": "string", + "modelType": "string", + "convToValue": "makeFileImageSource", + "defaultValue": "null" + }, + { + "name": "IsEnabled", + "inputType": "bool", + "modelType": "bool", + "defaultValue": "true" + } + ] + }, + { + "name": "Xamarin.Forms.GridItemsLayout", + "members": [ + { + "name": "Span", + "defaultValue": "0", + "modelType": "int", + "inputType": "int" + } + ] + }, + { + "name": "Xamarin.Forms.ItemsView", + "members": [ + { + "name": "EmptyView", + "defaultValue": "null" + }, + { + "name": "ItemsLayout", + "defaultValue": "null" + }, + { + "name": "ItemsSource", + "defaultValue": "null" + }, + { + "name": "ScrollToRequested", + "defaultValue": "null", + "inputType": "Xamarin.Forms.ScrollToRequestEventArgs -> unit", + "convToModel": "(fun f -> System.EventHandler(fun _sender args -> f args))" + }, + { + "name": "ScrollTo", + "uniqueName": "iScrollTo", + "inputType": "obj * obj * Xamarin.Forms.ScrollToPosition * Fabulous.DynamicViews.AnimationKind", + "modelType": "obj * obj * Xamarin.Forms.ScrollToPosition * Fabulous.DynamicViews.AnimationKind", + "updateCode": "(fun _ curr target -> triggerScrollTo curr target)" + } + ] + }, + { + "name": "Xamarin.Forms.SearchHandler", + "members": [ + { + "name": "ClearIcon", + "inputType": "string", + "modelType": "string", + "convToValue": "makeImageSource", + "defaultValue": "null" + }, + { + "name": "ClearIconHelpText", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "ClearIconName", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "ClearPlaceholderCommand", + "defaultValue": "null", + "inputType": "unit -> unit", + "convToModel": "makeCommand" + }, + { + "name": "ClearPlaceholderCommandParameter", + "defaultValue": "null" + }, + { + "name": "ClearPlaceholderEnabled", + "inputType": "bool", + "modelType": "bool", + "defaultValue": "true" + }, + { + "name": "ClearPlaceholderHelpText", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "ClearPlaceholderIcon", + "inputType": "string", + "modelType": "string", + "convToValue": "makeImageSource", + "defaultValue": "null" + }, + { + "name": "ClearPlaceholderName", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "Command", + "defaultValue": "null", + "inputType": "unit -> unit", + "convToModel": "makeCommand" + }, + { + "name": "CommandParameter", + "defaultValue": "null" + }, + { + "name": "DisplayMemberName", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "IsSearchEnabled", + "defaultValue": "true" + }, + { + "name": "Placeholder", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "Query", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "QueryIcon", + "inputType": "string", + "modelType": "string", + "convToValue": "makeImageSource", + "defaultValue": "null" + }, + { + "name": "QueryIconHelpText", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "QueryIconName", + "defaultValue": "null", + "modelType": "string", + "inputType": "string" + }, + { + "name": "SearchBoxVisibility", + "defaultValue": "Xamarin.Forms.SearchBoxVisiblity.Hidden" + }, + { + "name": "ShowsResults", + "defaultValue": "true", + "inputType": "bool", + "modelType": "bool" + }, + { + "name": "ItemsSource", + "defaultValue": "null" + } + ] + }, + { + "name": "Xamarin.Forms.Shell", + "members": [ + { + "name": "Items", + "defaultValue": "null", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateShellItems" + }, + { + "name": "MenuItems", + "defaultValue": "null", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateMenuItemsShell" + }, + { + "name": "CurrentItem", + "defaultValue": "null" + }, + { + "name": "FlyoutBackgroundColor", + "defaultValue": "Xamarin.Forms.Color.Default" + }, + { + "name": "FlyoutBehavior", + "defaultValue": "Xamarin.Forms.FlyoutBehavior.Flyout" + }, + { + "name": "FlyoutHeader", + "defaultValue": "null" + }, + { + "name": "FlyoutHeaderBehavior", + "defaultValue": "Xamarin.Forms.FlyoutHeaderBehavior.Default" + }, + { + "name": "FlyoutIsPresented", + "defaultValue": "false" + }, + { + "name": "Route", + "defaultValue": "null" + }, + { + "name": "RouteHost", + "defaultValue": "null" + }, + { + "name": "RouteScheme", + "defaultValue": "null" + }, + { + "name": "Navigated", + "uniqueName": "OnNavigated", + "defaultValue": "null", + "inputType": "Xamarin.Forms.ShellNavigatedEventArgs -> unit", + "convToModel": "(fun f -> System.EventHandler(fun _sender args -> f args))" + }, + { + "name": "Navigating", + "uniqueName": "OnNavigating", + "defaultValue": "null", + "inputType": "Xamarin.Forms.ShellNavigatingEventArgs -> unit", + "convToModel": "(fun f -> System.EventHandler(fun _sender args -> f args))" + }, + { + "name": "GoToAsync", + "inputType": "Xamarin.Forms.ShellNavigationState * Fabulous.DynamicViews.AnimationKind", + "modelType": "Xamarin.Forms.ShellNavigationState * Fabulous.DynamicViews.AnimationKind", + "updateCode": "(fun _ curr target -> triggerGoToAsync curr target)" + } + ] + }, + { + "name": "Xamarin.Forms.ShellGroupItem", + "members": [ + { + "name": "FlyoutDisplayOptions", + "defaultValue": "Xamarin.Forms.FlyoutDisplayOptions.AsSingleItem" + } + ] + }, + { + "name": "Xamarin.Forms.SelectableItemsView", + "members": [ + { + "name": "SelectedItem", + "defaultValue": "null" + }, + { + "name": "SelectionChangedCommand", + "defaultValue": "null", + "inputType": "unit -> unit", + "convToModel": "makeCommand" + }, + { + "name": "SelectionChangedCommandParameter", + "defaultValue": "null" + }, + { + "name": "SelectionMode", + "uniqueName": "selectableItemsMode", + "defaultValue": "Xamarin.Forms.SelectionMode.None", + "inputType": "Xamarin.Forms.SelectionMode", + "modelType": "Xamarin.Forms.SelectionMode" + }, + { + "name": "SelectionChanged", + "defaultValue": "null", + "inputType": "Xamarin.Forms.SelectionChangedEventArgs -> unit", + "convToModel": "(fun f -> System.EventHandler(fun _sender args -> f args))" + } + ] + }, + { + "name": "Xamarin.Forms.ShellNavigationState", + "members": [ + { + "name": "Location", + "defaultValue": "null", + "inputType": "System.Uri", + "convToModel": "makeUri" + } + ] + }, + { + "name": "Xamarin.Forms.ShellContent", + "members": [ + { + "name": "Content", + "defaultValue": "null", + "inputType": "ViewElement" + }, + { + "name": "MenuItems", + "defaultValue": "null", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateMenuItemsShellContent" + } + ] + }, + { + "name": "Xamarin.Forms.ShellItem", + "members": [ + { + "name": "CurrentItem", + "defaultValue": "null", + "inputType": "ViewElement", + "modelType": "ViewElement" + }, + { + "name": "Items", + "defaultValue": "null", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateShellItemItems" + } + ] + }, + { + "name": "Xamarin.Forms.ShellSection", + "members": [ + { + "name": "CurrentItem", + "defaultValue": "null" + }, + { + "name": "GoToAsync", + "uniqueName": "ssGoToAsync", + "inputType": "string list * Map * Fabulous.DynamicViews.AnimationKind", + "modelType": "string list * Map * Fabulous.DynamicViews.AnimationKind", + "updateCode": "(fun _ curr target -> triggerSSGoToAsync curr target)" + }, + { + "name": "Items", + "defaultValue": "null", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateShellSectionItems" + } + ] + }, + { + "name": "Xamarin.Forms.CarouselView", + "customType": "Fabulous.DynamicViews.CustomCarouselView", + "members": [ + { + "name": "ItemsSource", + "uniqueName": "CarouselViewItems", + "shortName": "items", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateCarouselViewItems" + } + ] + }, + { + "name": "Xamarin.Forms.CollectionView", + "customType": "Fabulous.DynamicViews.CustomCollectionListView", + "members": [ + { + "name": "ItemsSource", + "uniqueName": "CollectionViewItems", + "shortName": "items", + "inputType": "seq", + "modelType": "seq", + "updateCode": "updateCollectionViewItems" + } + ] } ] } \ No newline at end of file