parent
2bc8da6200
commit
60547644be
@ -1,12 +1,27 @@
|
||||
using CommunityToolkit.Maui.Views;
|
||||
using LivreLand.ViewModel;
|
||||
|
||||
namespace LivreLand.View.ContentViews;
|
||||
|
||||
public partial class PopupHomePlusButtonView : Popup
|
||||
{
|
||||
public PopupHomePlusButtonView()
|
||||
|
||||
#region Properties
|
||||
|
||||
public NavigatorVM Navigator { get; private set; }
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
#region Constructor
|
||||
|
||||
public PopupHomePlusButtonView(NavigatorVM navigatorVM)
|
||||
{
|
||||
InitializeComponent();
|
||||
Navigator = navigatorVM;
|
||||
InitializeComponent();
|
||||
Size = new Size(0.8 * (DeviceDisplay.Current.MainDisplayInfo.Width / DeviceDisplay.Current.MainDisplayInfo.Density), 0.5 * (DeviceDisplay.Current.MainDisplayInfo.Width / DeviceDisplay.Current.MainDisplayInfo.Density));
|
||||
}
|
||||
BindingContext = this;
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<toolkit:Popup xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
|
||||
xmlns:contentView="clr-namespace:LivreLand.View.ContentViews"
|
||||
xmlns:toolkit="http://schemas.microsoft.com/dotnet/2022/maui/toolkit"
|
||||
x:Class="LivreLand.View.ContentViews.PopupISBNView"
|
||||
HorizontalOptions="Center"
|
||||
VerticalOptions="Center"
|
||||
Color="Transparent">
|
||||
|
||||
<Border>
|
||||
<Grid BackgroundColor="{AppThemeBinding Light={StaticResource PopupBackground}, Dark={StaticResource Black}}">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="auto"/>
|
||||
<RowDefinition Height="auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<Grid Grid.Row="0"
|
||||
Margin="5">
|
||||
<Label Text="Saisir l'ISBN"
|
||||
Style="{StaticResource MasterStateBookText}"/>
|
||||
</Grid>
|
||||
|
||||
<Grid Grid.Row="1"
|
||||
Margin="5">
|
||||
<Entry />
|
||||
</Grid>
|
||||
</Grid>
|
||||
<Border.StrokeShape>
|
||||
<RoundRectangle CornerRadius="10" />
|
||||
</Border.StrokeShape>
|
||||
</Border>
|
||||
|
||||
</toolkit:Popup>
|
@ -0,0 +1,12 @@
|
||||
using CommunityToolkit.Maui.Views;
|
||||
|
||||
namespace LivreLand.View.ContentViews;
|
||||
|
||||
public partial class PopupISBNView : Popup
|
||||
{
|
||||
public PopupISBNView()
|
||||
{
|
||||
InitializeComponent();
|
||||
Size = new Size(0.8 * (DeviceDisplay.Current.MainDisplayInfo.Width / DeviceDisplay.Current.MainDisplayInfo.Density), 0.5 * (DeviceDisplay.Current.MainDisplayInfo.Width / DeviceDisplay.Current.MainDisplayInfo.Density));
|
||||
}
|
||||
}
|
@ -1,18 +1,30 @@
|
||||
using CommunityToolkit.Maui.Views;
|
||||
using LivreLand.View.ContentViews;
|
||||
using LivreLand.ViewModel;
|
||||
using System.Windows.Input;
|
||||
|
||||
namespace LivreLand.View;
|
||||
|
||||
public partial class HeaderHome : ContentView
|
||||
{
|
||||
public HeaderHome()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public void OnPlusClicked(object sender, EventArgs e)
|
||||
#region Properties
|
||||
|
||||
public NavigatorVM Navigator { get; private set; }
|
||||
|
||||
public static readonly BindableProperty ButtonTappedCommandProperty = BindableProperty.Create(nameof(ButtonTappedCommand), typeof(ICommand), typeof(HeaderPage));
|
||||
public ICommand ButtonTappedCommand
|
||||
{
|
||||
var plusPopup = new PopupHomePlusButtonView();
|
||||
App.Current.MainPage.ShowPopup(plusPopup);
|
||||
get { return (ICommand)GetValue(ButtonTappedCommandProperty); }
|
||||
set { SetValue(ButtonTappedCommandProperty, value); }
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constructor
|
||||
|
||||
public HeaderHome()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
@ -0,0 +1,9 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
</PropertyGroup>
|
||||
|
||||
</Project>
|
Loading…
Reference in new issue