Opened 3 years ago
Closed 3 years ago
#55291 closed defect (bug) (wontfix)
Can't access Custom CSS with theme Twenty Twenty-Two
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 5.9 |
Component: | Themes | Keywords: | |
Focuses: | Cc: |
Description
The TT2 theme hides the customizer because the block theme replicates (most) of the functionality, however, if I switch from an existing theme to TT2 I lose access to all my Custom CSS that I previously had in Customizer.
Change History (4)
#3
@
3 years ago
- Keywords close added
Hi @DeveloperWil, welcome to Trac!
@audrasjb is correct.
- Additional CSS is theme-specific.
- If you add Additional CSS to Twenty Eleven then switch to Twenty Twelve, the Additional CSS that you added will not be available.
- If you switch back to Twenty Eleven, the Additional CSS that you added will be available again.
For block themes, if you do not wish to create a child theme and add your custom CSS there, you can access some styling options in the Editor by clicking the Styles icon at the top right of the Editor.
If you are using a block theme and you still want access to Additional CSS via the Customizer:
- Create a folder called
enable-customizer
inwp-content/plugins
. - Inside this folder, create a new file called
enable-customizer.php
. - Paste the following code into the file and save.
<?php /** * Plugin Name: Enable Customizer * Description: Enables the Customizer. * Author: WordPress Contributors * Author URI: https://www.wordpress.org * License: GPLv2 or later * Version: 1.0.0 */ add_action( 'customize_register', '__return_true' );
- In the WordPress Admin, navigate to
Plugins > Installed Plugins
and activate the Enable Customizer plugin.
You should now be able to navigate to Appearance > Customize
and access the Additional CSS panel.
This doesn't appear to be a valid bug, but is actually the intended behaviour of the Additional CSS panel.
I'll add the close
keyword for now, pending reporter-feedback
.
#4
@
3 years ago
- Keywords reporter-feedback close removed
- Milestone Awaiting Review deleted
- Resolution set to wontfix
- Status changed from new to closed
This doesn't appear to be a valid bug, but is actually the intended behaviour of the Additional CSS panel.
Agreed that this is intentional behavior and is unrelated to the Customizer being hidden when a block-based theme is active. Closing out.
Hello and welcome back to WordPress Core Trac @DeveloperWil,
I'm not sure I completely understand your point, but as far as I know (and even before block themes appeared), you always loose Custom CSS added with the customizer when you switch theme.