Improve fictioneer_page_background()

This commit is contained in:
Tetrakern 2024-06-14 00:34:18 +02:00
parent c00356da92
commit af187a4ff6

View File

@ -2062,11 +2062,13 @@ function fictioneer_get_story_changelog( $story_id ) {
function fictioneer_page_background( $context = null ) {
// Setup
$background = '<div class="main__background polygon polygon--main background-texture"></div>';
// Chapter?
if ( $context === 'chapter' ) {
$background = '<div class="main__background chapter__background polygon polygon--main background-texture"></div>';
switch ( $context ) {
case 'chapter':
$background = '<div class="main__background chapter__background polygon polygon--main background-texture"></div>';
break;
default:
$background = '<div class="main__background polygon polygon--main background-texture"></div>';
break;
}
// Render