Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,8 @@ Thumbs.db

# dotCover
*.dotCover

# nuget
!nuget/**/*
!/nuget/**/*
!/nuget/
21 changes: 21 additions & 0 deletions LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) Microsoft Corporation. All rights reserved.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE
7 changes: 7 additions & 0 deletions NuGet.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<add key="nugetLocal" value="nuget" />
<add key="supportmyget" value="https://www.myget.org/F/xamprojectci/api/v3/index.json" />
</packageSources>
</configuration>
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ For example, this sample app sets the Visual preference on the application `Shel
Visual="Material">
```

Any control may override this propogation by delcaring its own Visual preference:
Any control may override this propogation by declaring its own Visual preference:

```
<Button Visual="Default" ... />
Expand All @@ -51,3 +51,7 @@ Material is Google's modern design system that is popular not only on Android, b

For more information, visit [material.io](https://material.io/).

## Instructions on Updating your own project
- Install https://www.nuget.org/packages/Xamarin.Forms.Visual.Material/4.0.0.169046-pre5 into your ios project
- Add FormsMaterial.Init() after the Forms.Init() call in your AppDelegate on ios

5 changes: 3 additions & 2 deletions VisualChallenge/VisualChallenge.Android/MainActivity.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@ protected override void OnCreate(Bundle savedInstanceState)

base.OnCreate(savedInstanceState);

global::Xamarin.Forms.Forms.SetFlags("Shell_Experimental", "Visual_Experimental", "CollectionView_Experimental", "FastRenderers_Experimental");
global::Xamarin.Forms.Forms.SetFlags("Shell_Experimental", "CollectionView_Experimental", "FastRenderers_Experimental");
global::Xamarin.Forms.Forms.Init(this, savedInstanceState);
LoadApplication(new App());
global::Xamarin.Forms.FormsMaterial.Init(this, savedInstanceState);
LoadApplication(new App());
}
}
}
6,810 changes: 4,707 additions & 2,103 deletions VisualChallenge/VisualChallenge.Android/Resources/Resource.designer.cs

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
<AndroidManifest>Properties\AndroidManifest.xml</AndroidManifest>
<MonoAndroidResourcePrefix>Resources</MonoAndroidResourcePrefix>
<MonoAndroidAssetsPrefix>Assets</MonoAndroidAssetsPrefix>
<AndroidUseLatestPlatformSdk>false</AndroidUseLatestPlatformSdk>
<TargetFrameworkVersion>v9.0</TargetFrameworkVersion>
<AndroidHttpClientHandlerType>Xamarin.Android.Net.AndroidClientHandler</AndroidHttpClientHandlerType>
<NuGetPackageImportStamp>
Expand Down Expand Up @@ -49,9 +48,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Xamarin.Forms" Version="3.6.0.135200-pre1" />
<PackageReference Include="Xamarin.Forms" Version="4.0.0.293082-pre8" />
<PackageReference Include="Xamarin.Forms.Visual.Material">
<Version>3.6.0.135200-pre1</Version>
<Version>4.0.0.293082-pre8</Version>
</PackageReference>
</ItemGroup>
<ItemGroup>
Expand Down Expand Up @@ -90,7 +89,7 @@
<ItemGroup />
<ItemGroup>
<ProjectReference Include="..\VisualChallenge\VisualChallenge.csproj">
<Project>{97CAB2B1-D85C-442E-AEFA-06FF5138B907}</Project>
<Project>{DF343C5B-66F1-4EF5-B721-6246D8F1DC39}</Project>
<Name>VisualChallenge</Name>
</ProjectReference>
</ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,15 +132,15 @@
<Reference Include="Xamarin.iOS" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Xamarin.Forms" Version="3.6.0.135200-pre1" />
<PackageReference Include="Xamarin.Forms" Version="4.0.0.293082-pre8" />
<PackageReference Include="Xamarin.Forms.Visual.Material">
<Version>3.6.0.135200-pre1</Version>
<Version>4.0.0.293082-pre8</Version>
</PackageReference>
</ItemGroup>
<Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.CSharp.targets" />
<ItemGroup>
<ProjectReference Include="..\VisualChallenge\VisualChallenge.csproj">
<Project>{97CAB2B1-D85C-442E-AEFA-06FF5138B907}</Project>
<Project>{DF343C5B-66F1-4EF5-B721-6246D8F1DC39}</Project>
<Name>VisualChallenge</Name>
</ProjectReference>
</ItemGroup>
Expand Down
8 changes: 4 additions & 4 deletions VisualChallenge/VisualChallenge/AppShell.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@
</ResourceDictionary>
</Shell.Resources>

<ShellItem>
<ShellSection>
<FlyoutItem>
<Tab>
<ShellContent ContentTemplate="{DataTemplate local:VisualChallengePage}"/>
</ShellSection>
</ShellItem>
</Tab>
</FlyoutItem>

</Shell>
6 changes: 3 additions & 3 deletions VisualChallenge/VisualChallenge/VisualChallenge.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<Project Sdk="Microsoft.NET.Sdk">
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
Expand All @@ -11,8 +11,8 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Xamarin.Forms" Version="3.6.0.135200-pre1" />
<PackageReference Include="Xamarin.Forms.Visual.Material" Version="3.6.0.135200-pre1" />
<PackageReference Include="Xamarin.Forms" Version="4.0.0.293082-pre8" />
<PackageReference Include="Xamarin.Forms.Visual.Material" Version="4.0.0.293082-pre8" />
</ItemGroup>

<ItemGroup>
Expand Down
14 changes: 9 additions & 5 deletions VisualChallenge/VisualChallenge/VisualChallengePage.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,16 @@
Title="Visual Challenge"
>

<FlexLayout Margin="20" Direction="Column" AlignContent="Center" JustifyContent="SpaceAround">
<!-- If you decide to change out the flexlayout leave the scroll view here
Currently there's a bug in shell that will set margins wrong if the content is not in a scrollview
-->
<ScrollView>
<FlexLayout Margin="20" Direction="Column" AlignContent="Center" JustifyContent="SpaceAround">

<Label Text="Start Here" FontSize="24" HorizontalTextAlignment="Center"/>
<Label Text="Start Here" FontSize="24" HorizontalTextAlignment="Center"/>

<Button Text="Read More About Visual" Clicked="Button_Clicked" />
<Button Text="Read More About Visual" Clicked="Button_Clicked" />

</FlexLayout>
</FlexLayout>
</ScrollView>
</ContentPage>
Binary file added nuget/Xamarin.Forms.4.0.0.293082-pre8.nupkg
Binary file not shown.
Binary file not shown.
Binary file added nuget/Xamarin.Forms.Maps.4.0.0.293082-pre8.nupkg
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added nuget/Xamarin.Forms.Pages.4.0.0.293082-pre8.nupkg
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.