Forum Discussion
Isaac Titlow
Jul 11, 2017Copper Contributor
Any ideas how to edit Highlighted content card templates?
Hi, I'm looking to remove the 'edited by' and 'date' part of the card view when using the Highlighted Content webpart on a modern page. I can't find what the name of the display template it uses woul...
Ryan Gardner
Copper Contributor
Insert this code as a modern script editor underneath the highlighted content to remove the modified section:
<style type="text/css">
.ms-DocumentCardTile .ms-DocumentCard:not(.ms-DocumentCard--compact) .ms-DocumentCardActivity {
Visibility:hidden !important;
}
</style>
JanetS
May 17, 2023Copper Contributor
Ryan Gardner - there is no Modern Script Editor webpart? Where would I need to get that?
- Ryan GardnerMay 17, 2023Copper ContributorMy apologies as I forgot this wasn't something out of the box. More information on SP_DEV-FX-WEBPARTS can be found here: https://adoption.microsoft.com/en-us/sample-solution-gallery/sample/pnp-sp-dev-spfx-web-parts-react-script-editor-onprem/
Technical information regarding this app is here:
https://github.com/pnp/sp-dev-fx-webparts/tree/main/samples/react-script-editor- JanetSMay 17, 2023Copper Contributor
Ryan Gardner Thank you for the information, unfortunately we are the government tenant so I will probably not be able to install.