@@ -37,7 +37,7 @@ To deprecate SCSS code, follow these steps:
3737
38381 . Remove the SCSS code that is no longer in use from the original file.
39392 . Add the removed SCSS code to the ` deprecated.scss ` file under the comment for the current version ` // Deprecated since Moodle X.Y. `
40- 3 . Add the ` deprecated-styles ` mixin to the removed SCSS code.
40+ 3 . Add the ` deprecated-styles ` mixin to the removed SCSS code, with the deprecated selector as parameter .
41414 . Add a comment to the removed SCSS code explaining why it has been deprecated.
4242
4343::: note
@@ -51,7 +51,7 @@ If there is no section for the current version in the `deprecated.scss` file, it
5151``` scss title="theme/boost/scss/moodle/deprecated.scss"
5252// The class ".foo" is deprecated. Use ".bar" instead.
5353.foo {
54- @include deprecated-styles ();
54+ @include deprecated-styles (" .foo " );
5555
5656 color : $pink ;
5757 @include border-right-radius (0 );
@@ -71,7 +71,7 @@ If there is no section for the current version in the `deprecated.scss` file, it
7171// The following styles are deprecated because they are no longer in use.
7272// Deprecating the parent selector that contains all the deprecated styles.
7373.path-course-view li .activity .foo {
74- @include deprecated-styles ();
74+ @include deprecated-styles (" .path-course-view li.activity .foo " );
7575}
7676.path-course-view li .activity .foo > a {
7777 text-decoration : none ;
@@ -115,5 +115,6 @@ Run optional tests:
115115If deprecated styles are being used, the test will fail with the following message:
116116
117117``` bash
118- Deprecated style in use (Exception)
118+ Deprecated styles found:
119+ .foo (found in: d-flex align-items-center foo)
119120```
0 commit comments