Opss.DesignSystem.Frontend.Blazor.Components 0.43.0

There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package Opss.DesignSystem.Frontend.Blazor.Components --version 0.43.0
                    
NuGet\Install-Package Opss.DesignSystem.Frontend.Blazor.Components -Version 0.43.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Opss.DesignSystem.Frontend.Blazor.Components" Version="0.43.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Opss.DesignSystem.Frontend.Blazor.Components" Version="0.43.0" />
                    
Directory.Packages.props
<PackageReference Include="Opss.DesignSystem.Frontend.Blazor.Components" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Opss.DesignSystem.Frontend.Blazor.Components --version 0.43.0
                    
#r "nuget: Opss.DesignSystem.Frontend.Blazor.Components, 0.43.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Opss.DesignSystem.Frontend.Blazor.Components@0.43.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Opss.DesignSystem.Frontend.Blazor.Components&version=0.43.0
                    
Install as a Cake Addin
#tool nuget:?package=Opss.DesignSystem.Frontend.Blazor.Components&version=0.43.0
                    
Install as a Cake Tool

Opss.DesignSystem.Frontend.Blazor.Components

About

GOV.UK Blazor Frontend contains the components you need to start building a user interface for government platforms and services in Blazor.

It is based on:

Dependencies

Beyond the .NET dependencies (which you can find in the relevant section of the nuget page) this component also uses the following node packages (contained within):

  • govuk-frontend: 5.8.0
  • @ministryofjustice/frontend: 3.3.1

Usage

  1. Add the following namespace to your _Imports.razor file:

    @using Opss.DesignSystem.Frontend.Blazor.Components
    
  2. Add the following line to your Program.cs file to utilise the static assets embedded in the package:

    builder.WebHost.UseStaticWebAssets();
    
  3. Add references to the required CSS and JS files in your wwwroot/index.html (for Blazor WebAssembly) or Pages/_Host.cshtml (for Blazor Server) file:

    <link href="_content/Opss.DesignSystem.Frontend.Blazor.Components/css/govuk.css" rel="stylesheet" />
    <script src="_content/Opss.DesignSystem.Frontend.Blazor.Components/js/govuk.js"></script>
    <script src="_content/Opss.DesignSystem.Frontend.Blazor.Components/js/moj.js"></script>
    
  4. You can now use the components in your Blazor pages. For example:

    <GdsButton Text="Click me" />
    

Please refer to the showcase project for examples of how to use the components.

Components

For a full list of components please refer to the components project on Github.

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.