XperienceCommunity.WidgetFilter 13.0.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package XperienceCommunity.WidgetFilter --version 13.0.1
NuGet\Install-Package XperienceCommunity.WidgetFilter -Version 13.0.1
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="XperienceCommunity.WidgetFilter" Version="13.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add XperienceCommunity.WidgetFilter --version 13.0.1
#r "nuget: XperienceCommunity.WidgetFilter, 13.0.1"
#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.
// Install XperienceCommunity.WidgetFilter as a Cake Addin
#addin nuget:?package=XperienceCommunity.WidgetFilter&version=13.0.1

// Install XperienceCommunity.WidgetFilter as a Cake Tool
#tool nuget:?package=XperienceCommunity.WidgetFilter&version=13.0.1

XperienceCommunity.WidgetFilter

Ability to have widgets designated to "Sets" as well as limit widgets based on user, role, or site.

Requirements

Kentico Xperience 13 on .Net core 3.1 or above

Installation

  1. On your Xperience MVC Site, install the XperienceCommunity.WidgetFilter nuget package.
  2. In your startup, call services.AddWidgetFilter()
  3. Add @addTagHelper *, XperienceCommunity.WidgetFilter to your _ViewImports.cshtml or whichever view you wish to get the tag helper.

Usage

Add [assembly: RegisterWidgetToSets] to any widget you wish to designate to a set. If a widget has no RegisterWidgetToSets attribute, it's considered a general widget. Add [assembly: RegisterWidgetPermissions] to any widget widget you wish to limit by User type, Role, or Site. If a widget has no RegisterWidgetPermissions attribute, then it will not get filtered out by permission.

There should be only one RegisterWidgetToSets and one RegisterWidgetPermissions per widget max.

Add widget-sets (along with optional include-general-widgets='true') to your <editable-area/> tag.

Example: <editable-area area-identifier="main" widget-sets="@(new string[] { SiteWidgetSets.BANNERS })" include-general-widgets=true />

By default, if you specify any widget sets, general widgets will be excluded unless you specifically call include-general-widgets=true, likewise if you do not specify any widget sets, general widgets are always shown.

Contributions

If you find a bug, please feel free to submit a pull request!

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp3.1 is compatible. 
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.

Version Downloads Last updated
13.0.2 8,838 5/31/2022
13.0.1 2,302 2/26/2022

Initial Release