Interface IPageWebPart
- Namespace
- PnP.Core.Model.SharePoint
- Assembly
- PnP.Core.dll
This class is used to instantiate modern web parts. Using this class you can instantiate a control and add it on a IPage.
public interface IPageWebPart : ICanvasControl
- Inherited Members
Properties
Description
Description of the web part
string Description { get; set; }
Property Value
DynamicDataPaths
DynamicDataPaths json node
JsonElement DynamicDataPaths { get; }
Property Value
DynamicDataValues
DynamicDataValues json node
JsonElement DynamicDataValues { get; }
Property Value
FlexibleLayoutPosition
Flexible layout position of the control
ControlFlexLayoutPosition FlexibleLayoutPosition { get; set; }
Property Value
HtmlProperties
Value of the "data-sp-htmlproperties" attribute
string HtmlProperties { get; }
Property Value
HtmlPropertiesData
Value of the "data-sp-htmlproperties" element
string HtmlPropertiesData { get; }
Property Value
IsHeaderControl
This control lives in the page header (not removable control)
bool IsHeaderControl { get; set; }
Property Value
JsonWebPartData
Value of the "data-sp-webpartdata" attribute
string JsonWebPartData { get; }
Property Value
Properties
Web properties as configurable JsonElement
JsonElement Properties { get; }
Property Value
PropertiesJson
Json serialized web part information. For 1st party web parts this ideally is the full JSON string fetch via workbench or via copying it from an existing page. It's important that the serverProcessedContent element is included here!
string PropertiesJson { get; set; }
Property Value
RichTextEditorInstanceId
If this webpart is used inline in a text editor then this property points to the editor using it
string RichTextEditorInstanceId { get; set; }
Property Value
ServerProcessedContent
ServerProcessedContent json node
JsonElement ServerProcessedContent { get; }
Property Value
SupportsFullBleed
Supports full bleed display experience
bool SupportsFullBleed { get; }
Property Value
Title
Title of the web part
string Title { get; set; }
Property Value
Type
Return Type of the client side web part
Type Type { get; }
Property Value
WebPartData
Value of the "data-sp-webpart" attribute
string WebPartData { get; }
Property Value
WebPartId
ID of the client side web part
string WebPartId { get; }
Property Value
WebPartPreviewImage
Preview image that can serve as page preview image when the page holding this web part is promoted to a news page
string WebPartPreviewImage { get; }
Property Value
Methods
BuildControlData(float)
Builds Control attributes based on current settings, also used by pnpframework
void BuildControlData(float controlIndex)
Parameters
controlIndexfloat