Forum Replies Created

Viewing 1 replies (of 1 total)
  • Hi,

    I’m also pretty new to WordPress and stumbled on the same issue. It happens because style.css has a greater specificity than the inline styling. To work round the issue, go to <yoursite.com>/wp-admin/site-editor.php?postType=wp_template&postId=jadro%2F%2Ffront-page&canvas=edit, styles(top right) then click blocks bottom of the menu, select list(& list item) and change the link color to your site’s color.

    More details on specificity:

    Specificity in CSS determines what styling is given to different sections of your site and is determined on how closely a selector matches what’s on the page based on number of matches of (ID, CLASS, TYPE), read from left to right so (1, 0, 0) is more specific than (0,2,1) which is more specific than (0,1,1).

    Style.css(<yoursite.com>/wp-content/themes/jadro/style.css?ver=1.0.2), contains under the /* List / section: ul li a, ol li a, ... { color: inherit; text-decoration: inherit; }. Which matches the ol, li, a in a list item giving it a specificity of (0, 0, 3).

    This match is stronger than the inline style (light purple color and underline), which matches a:where(:not(.wp-element-button)with a specificity of (0, 0, 1) matching only the <a> tags as the :where keyword doesn’t increase specificity.

    So color and text-decoration for the whole list is inherited from the parent section, which is body var(--wp--preset--color--base), rather than the inline styling.

    • This reply was modified 1 year, 1 month ago by cabledelay. Reason: Mistake in directions of where to fix
Viewing 1 replies (of 1 total)