This article explains how to use data attributes in Power Pages to apply custom CSS styles to specific pages or sections. By inspecting the page using browser developer tools, you can find the data attribute called "data-sitemap-state" on the body tag, which contains information about the current page and its parent page. You can use this data attribute to target specific pages or sections with CSS selectors. The article provides examples of CSS selectors for different pages and sections. Additionally, the article includes a bonus trick on how to use CSS pseudo-elements to add Font Awesome icons to list items.
Login now to access my digest by 365.Training