Make WordPress Core

Opened 3 weeks ago

Last modified 12 days ago

#62420 new defect (bug)

After upgrade to wordpress 6.7 theme CSS is not loading in wordpress admin panel

Reported by: tusharaddweb's profile tusharaddweb Owned by:
Milestone: Awaiting Review Priority: normal
Severity: major Version: 6.7
Component: Administration Keywords: needs-patch
Focuses: ui Cc:

Description

I am getting issue that when I am editing any page and using any block created the css of the same is not getting reflected in the page section. However if I use the same in template it works fine.
Attaching screenshot for the same.

Attachments (2)

Screenshot from 2024-11-14 10-38-15.png (182.4 KB) - added by tusharaddweb 3 weeks ago.
Screenshot from 2024-11-14 10-50-48.png (652.6 KB) - added by tusharaddweb 3 weeks ago.

Download all attachments as: .zip

Change History (7)

#1 @pkbhatt
3 weeks ago

  • Component changed from General to Administration
  • Focuses ui added
  • Keywords needs-patch added
  • Severity changed from blocker to major
  • Version set to 6.7

Yes I am also getting similar issue on fresh setup of wordpress 6.7.

Last edited 3 weeks ago by pkbhatt (previous) (diff)

This ticket was mentioned in Slack in #core by desrosj. View the logs.


2 weeks ago

#3 @desrosj
2 weeks ago

  • Keywords reporter-feedback added

Hi @tusharaddweb,

Thanks for this, and welcome to Trac!

Could you provide some more details so someone can reproduce this? What are some examples of the CSS you are adding? What theme are you using? Could you include a copy of your blocks? Have you tried disabling all plugins?

#4 @desrosj
2 weeks ago

  • Keywords close added; needs-patch removed

Just wanted to reach out again. @tusharaddweb are you still experiencing this?

Any more details that you can provide to help reproduce this would be appreciated. Going to mark as a close suggestion since this has not yet been reproduced. Will return next week and close out if additional details are not provided.

#5 @tusharaddweb
12 days ago

  • Keywords needs-patch added; reporter-feedback close removed

yes I am still facing this issue with custom block I have built. It works fine in previoius versions.

Attaching code below:

const { registerBlockType } = wp.blocks;
const { TextControl, CheckboxControl } = wp.components;

registerBlockType('custom-field/block', {
    title: 'Custom Field Block',
    description: 'A block to display a custom field value dynamically.',
    category: 'common',
    icon: 'admin-post',
    attributes: {
        fieldName: {
            type: 'string',
            default: 'my_custom_field',
        },
        displayAsImage: {
            type: 'boolean',
            default: false,
        },
    },
    edit: ({ attributes: { fieldName = 'my_custom_field', displayAsImage = false }, setAttributes }) => {
        return (
            <div>
                <TextControl
                    label="Custom Field Name"
                    value={fieldName}
                    onChange={(newFieldName) => setAttributes({ fieldName: newFieldName })}
                    help="Enter the custom field name (meta key) you want to display."
                />
                <CheckboxControl
                    label="Display as Image"
                    checked={displayAsImage}
                    onChange={(newDisplayAsImage) => setAttributes({ displayAsImage: newDisplayAsImage })}
                    help="Check to display the custom field value as an image."
                />
            </div>
        );
    },
    save: () => {
        return null; // Server-rendered block
    },
});
Note: See TracTickets for help on using tickets.