PnP Modern Search
11 TopicsWhat is the syntax for conditional formatting within PnP Modern Search WebPart template?
Hello, I am trying to figure out the syntax for the PnP Search WebPart so that I may apply conditional formatting. In this case, I would like to see if a column value is empty - then I would apply X CSS and if a column value's length is less than 2 , then apply this Y CSS. Conventionally, I would imagine it would be something like this if the value is empty : {{#if slot.item root.,slots.Title.value empty}} <div>..CSS here </div> {{/if}} AND something like this if the string length is greater than 2 : {{#if slot.item root.,slots.Title.value >len(2)}} <div>..CSS here </div> {{/if}} I would very much appreciate any assistance. Regards, Mike1.3KViews1like0CommentsToday query in SharePoint Search not working anymore
Has anyone else had an issue with a query like RefinableDateXX={Today} not work for them anymore as of a few days ago? I've had a query i've been using for a few years and all of a sudden the items from a SharePoint list with a date field linked to a RefinableDate managed property no longer returns results for {Today}. I've had to use {Today-1} or {Today+1} but even that has been hit or miss. Especially when using an AND or OR for multiple dates or date ranges. Just wondering if i missed an update MS made or if something is broken.1.9KViews1like2CommentsResult search query to exclude items without values in a managed property
Hi all, I am trying to configure a PnP Search Results WebPart to show all recently modified site pages that contain a value in a managed property, any value that isn't blank. For context, this is for a wiki SharePoint site where all users can make changes and submit for approval. After they are approved, I would like to show on the home page the most recently updated pages. What I would like the query to do: Search for all pages from the path below that contain any value in the RefinableString00 property. path:https://xxx.sharepoint.com/sites/wiki/ A refinement filter is also set in the WebPart so that results only show site pages: FileType:aspx Results are also sorted to show the most recently updated pages first, using the property: LastModifiedTime My issue is that there are pages that don't have a value in the managed property RefinableString00 showing. I would like for these pages to not show. The question being how would I achieve this? Any suggestions would be appreciated5.5KViews1like2Comments