sensei
sensei copied to clipboard
Audit Learning mode Styles for specificity
We had an issue in 4.7.0 where some Learning Mode styles ended up being applied outside of Learning Mode. To fix it, we added some specificity to the rules in https://github.com/Automattic/sensei/pull/5903
However, @renatho also found some more rules that could potentially be applied globally:
https://github.com/Automattic/sensei/pull/5903#pullrequestreview-1138149312
body {
--sensei-primary-color: var(--sensei-primary-color-global, var(--sensei-course-theme-primary-color, var(--wp--preset--color--primary, #307771)));
--sensei-background-color: var(--sensei-background-color-global, var(--sensei-course-theme-background-color, var(--wp--preset--color--background, #ffffff)));
--sensei-primary-contrast-color: var(--sensei-background-color, #FFFFFF);
--sensei-text-color: var(--sensei-text-color-global, var(--sensei-course-theme-foreground-color, var(--wp--preset--color--text, var(--wp--preset--color--foreground, #1E1E1E))));
--border-color: rgba(125, 125, 125, 0.3);
background-color: var(--sensei-background-color);
color: var(--sensei-text-color);
}
.wp-block-site-logo .custom-logo-link {
margin: 0;
}
.wp-site-blocks {
display: block;
}
.entry-content img {
max-width: 100%;
height: auto;
}
.entry-content embed,
.entry-content iframe,
.entry-content object {
max-width: 100%;
}
We should make sure to check these rules and that they only apply where intended.