avancement de la globalisation

master
Darius BERTRAND 3 years ago
parent 44ef4a1fa0
commit 0cc45226c8

@ -1,6 +1,6 @@
@page "/edit/{id:int}"
<h3>Modification</h3>
<h3>@Localizer["Modifications"]</h3>
<EditForm Model="@musiqueModele" OnValidSubmit="@HandleValidSubmit">
<DataAnnotationsValidator />
@ -8,31 +8,31 @@
<p>
<label for="titre">
Display titre:
@Localizer["Display titre"]:
<InputText id="titre" @bind-Value="musiqueModele.titre" />
</label>
</p>
<p>
<label for="autheur">
autheur:
@Localizer["autheur"]:
<InputText id="autheur" @bind-Value="musiqueModele.auteur" />
</label>
</p>
<p>
<label for="durée">
Stack durée:
@Localizer["durée"]:
<InputNumber id="durée" @bind-Value="musiqueModele.duree" />
</label>
</p>
<p>
<label>
Current Item image:
@Localizer["Current Item image"]:
<img src="data:image/png;base64, @(musiqueModele.ImageBase64)" class="img-thumbnail" style="min-width: 50px; max-width: 150px"/>
</label>
</p>
<p>
<label>
Item image:
@Localizer["Item image"]:
<InputFile OnChange="@LoadImage" accept=".png" />
</label>
</p>
@ -47,16 +47,16 @@
</figure>
<p>
<label>
Item song:
@Localizer["Item song"]:
<InputFile OnChange="@LoadSong" accept=".mp3" />
</label>
</p>
<p>
<label for="songName">
Name file song:
@Localizer["Name file song"]:
<InputText id="songName" @bind-Value="musiqueModele.songName" />
</label>
</p>
<button type="submit">Submit</button>
<button type="submit">@Localizer["Submit"]</button>
</EditForm>

@ -3,6 +3,8 @@ using ProjetBlazor.Services;
using ProjetBlazor.Modeles;
using Microsoft.AspNetCore.Components.Forms;
using ProjetBlazor.Factories;
using Microsoft.Extensions.Localization;
using ProjetBlazor.Shared;
namespace ProjetBlazor.Pages
{
@ -23,6 +25,8 @@ namespace ProjetBlazor.Pages
[Inject]
public IDataService DataService { get; set; }
[Inject]
public IStringLocalizer<NavMenu> Localizer { get; set; }
private async void HandleValidSubmit()
{

@ -0,0 +1,147 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="auteur" xml:space="preserve">
<value>Author</value>
</data>
<data name="Current Item image" xml:space="preserve">
<value>Current Music Image</value>
</data>
<data name="Display titre" xml:space="preserve">
<value>Displayed Title </value>
</data>
<data name="durée" xml:space="preserve">
<value>Duration</value>
</data>
<data name="Item image" xml:space="preserve">
<value>New Image</value>
</data>
<data name="Item song" xml:space="preserve">
<value>Song</value>
</data>
<data name="Modifications" xml:space="preserve">
<value>Modifications</value>
</data>
<data name="Name file song" xml:space="preserve">
<value>File Name</value>
</data>
<data name="Submit" xml:space="preserve">
<value>Submit</value>
</data>
</root>

@ -0,0 +1,147 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="auteur" xml:space="preserve">
<value>Auteur</value>
</data>
<data name="Current Item image" xml:space="preserve">
<value>Image de la Musique Utilise</value>
</data>
<data name="Display titre" xml:space="preserve">
<value>Titre Affiche</value>
</data>
<data name="durée" xml:space="preserve">
<value>Durée</value>
</data>
<data name="Item image" xml:space="preserve">
<value>Nouvelle Image</value>
</data>
<data name="Item song" xml:space="preserve">
<value>Son</value>
</data>
<data name="Modifications" xml:space="preserve">
<value>Modifications</value>
</data>
<data name="Name file song" xml:space="preserve">
<value>Nom du Fichier</value>
</data>
<data name="Submit" xml:space="preserve">
<value>Soumettre</value>
</data>
</root>

@ -117,7 +117,10 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="Edit" xml:space="preserve">
<value>Modifier</value>
<data name="Home" xml:space="preserve">
<value>Accueil</value>
</data>
<data name="Musiques Liste" xml:space="preserve">
<value>Playlist de Musiques</value>
</data>
</root>

@ -117,7 +117,10 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="Edit" xml:space="preserve">
<value>Edition</value>
<data name="Home" xml:space="preserve">
<value>Home</value>
</data>
<data name="Musiques Liste" xml:space="preserve">
<value>Music Playlist</value>
</data>
</root>

@ -11,12 +11,12 @@
<nav class="flex-column">
<div class="nav-item px-3">
<NavLink class="nav-link" href="" Match="NavLinkMatch.All">
<span class="oi oi-home" aria-hidden="true"></span> Home
<span class="oi oi-home" aria-hidden="true"></span> @Localizer["Home"]
</NavLink>
</div>
<div class="nav-item px-3">
<NavLink class="nav-link" href="MusiquesListe">
<span class="oi oi-plus" aria-hidden="true"></span> Musiques Liste
<span class="oi oi-plus" aria-hidden="true"></span> @Localizer["Musiques Liste"]
</NavLink>
</div>
<div class="nav-item px-3">

@ -8,5 +8,7 @@ namespace ProjetBlazor.Shared
{
[Inject]
public IStringLocalizer<NavMenu> Localizer { get; set; }
[Inject]
public NavigationManager NavigationManager { get; set; }
}
}

Loading…
Cancel
Save