In this article, let us see a Simple SharePoint tip to hide the Title Area of an Article Page in SharePoint Online. Usually when I create a page in the Modern Site, the title area will be shown as below. Even, If I delete the title, the section will be shown as below.
But, my requirement is, to hide them and there are possibilities through CSS. But a permanent solution will be, creating the Page using the layout “Home” instead of “Article”. By default, we were not able to create a layout with a defined layout in modern page. Hence, after creating, using the below PowerShell script, we can convert the layout and the Title Area will be automatically hided.
$SiteURL = "https://MYSite.sharepoint.com/sites/MySiteCollection/"
Connect-PnPOnline $SiteURL -Credential (Get-Credential)
Get-PnPListItem -List SitePages
Set-PnPListItem -List SitePages –Identity "5" -Values @{"PageLayoutType"="Home"}
After converting the page looks as below.
A small tip which will help to convert the page layout.
Happy Coding
Sathish Nadarajan
Leave a comment