All Questions
Tagged with gutenberg-blocks wordpress-theming
24 questions
0
votes
1
answer
190
views
Need help in fixing/debugging wordpress to know why my block is not visible in my theme's block editor
I am new to WordPress development but have decent experience with Javascript.
So I've tried out this tutorial on Udemy (https://www.udemy.com/course/become-a-wordpress-developer-php-javascript/) and ...
2
votes
0
answers
149
views
How to add multiple custom blocks in custom Wordpress theme using create-block?
I want to add multiple custom blocks to my custom wordpress theme using create-block package.
In my root folder I initiated package.json by running npm init -y and added wp-scripts as a dev dependency....
1
vote
0
answers
104
views
How do you change a wordpress theme body colour in the theme.json file?
From what I've understood, Wordpress is encouraging using the theme.json file to style up a theme rather than using css files to target specific classes. I've figured out how to style buttons and ...
2
votes
1
answer
130
views
Support for gradient colors in Gutenberg richText inline highlight option
I want to add the support for the gradient colors in highlight option against any selected text. For reference please see this comment.
I have seen this stackOverflow thread as well. It provides ...
1
vote
0
answers
121
views
Cannot use saved attribute to the core/template-part block in Gutenberg in front end ( WP 6.2)
I'm building a block theme in Wordpress.
I'm trying to use a saved custom attribute to modify an existing core block using the blocks.getSaveContent.extraProps hook. Specifically, I'm trying to apply ...
2
votes
2
answers
2k
views
Gutenberg block CSS does not apply to preview in template parts editor
I'm trying to add support for template parts to my WordPress theme.
I have a block with a stylesheet and a script and everything works fine. However, in the template part editor (Design -> Template ...
3
votes
2
answers
2k
views
Enqueue styles and scripts for WordPress Gutenberg block
what are the best or the recommended way to Enqueue styles and scripts for WordPress Gutenberg block ?
i see some developers recommend enqueue_block_assets hook and others recommend init hook with ...
1
vote
1
answer
456
views
Is it possible to concatenate css classes using WordPress Gutenberg's block editor?
I have registered some new core/image block styles in my theme's editor.js file:
wp.blocks.registerBlockStyle('core/image', [
{
name: 'default',
label: 'Default',
isDefault: true,...
10
votes
2
answers
5k
views
Add custom block in a Wordpress block theme(Not with the plugin)
Basically I want to develop a wordpress block theme.For easy to customize I want to add some custom block in my theme.But I don't want to create a plugin for this.Custom block will be inside my theme....
1
vote
2
answers
3k
views
Use Gutenberg block in template with 'template_include'
I needed to override one of the theme TwentyTwentyTwo template from a custom plugin, and I wanted to use one of Gutenberg's blocks.
I see that in the templates files blocks are used by just writing ...
0
votes
1
answer
329
views
Rich Texts Not saved the Data
i got issues in Saving Data in Rich Texts .. I already make the setAttributes for each attribute and have no changes too !
it is my code
attributes
attributes :{
titleONEHOMEPorT: {
type: ...
0
votes
2
answers
2k
views
Blank WP starter theme compatible with Blocks and Bootstrap
I want to refine my wordpress theme development process which is:
To make a unique-creative design with Adobe XD or Figma.
To convert it to static HTML using VS Code with Bootstrap.
In wordpress, ...
0
votes
1
answer
546
views
How to disable “Transform to” option in Gutenberg custom blocks
I prepared some non-standard Gutenberg blocks.
They have a very specific purpose.
Therefore, I do not want them to have the Transform to option available.
What I found is the ability to use support: {}...
4
votes
0
answers
565
views
How to remove unwanted panels inside InspectorControls from core blocks in Gutenberg
If I want to extend the core block I can use Block Filters where I found a filter like editor.BlockEdit.
Example from doc:
const { createHigherOrderComponent } = wp.compose;
const { Fragment } = wp....
0
votes
1
answer
845
views
How to find Gutenberg block code and call it from template parts
I am trying to include a Gutenberg block - the Search widget - within a template part, so I thought looking at the code within the post_content field of the wp_posts table might help:
<!-- wp:...
0
votes
2
answers
138
views
How to enable block editor in "Traveler" wordpress theme?
I want to enable the " Gutenberg" editor. Currently, the theme is using " classic editor". I have installed the "Gutenbergenter image description here" plugin but it is ...
1
vote
1
answer
3k
views
Wordpress Gutenberg custom columns block
I'm trying to create a custom "columns" block for Gutenberg with ACF & Wordpress, so what I want is a easy to manage columns block, where user can input some number representating the ...
0
votes
1
answer
2k
views
How to change the default HTML output of a Gutenberg block in WordPress?
I'm trying to change the default HTML output of a Gutenberg block in WordPress 5.7. For example, the default output of a core/Group block with a paragraph inside is:
<div class="wp-block-group&...
0
votes
1
answer
7k
views
How to get a unique id with a simple custom gutenberg block in WordPress?
I'm trying get a unique id for each custom gutenberg block. I'm found useInstanceId. Is that possible to use with this syntax?
registerBlockType('custom/block', {
title: 'Custom',
edit() {...
0
votes
0
answers
103
views
Why might Gutenberg Block Manager be empty
I am trying hide Gutenberg blocks that are not currently needed. It seems the block manager is the right way to do that, but when I open it from the settings menu on my page, it is empty. I don't ...
0
votes
1
answer
2k
views
WordPress: Get Block ID in JavaScript
I created a custom Gutenberg block to display a slider.
I'm using the example from ACF: https://www.advancedcustomfields.com/blog/building-a-custom-slider-block-in-30-minutes-with-acf/
Everything ...
3
votes
1
answer
1k
views
Edit srcset and sizes attributes in Gutenberg image, cover and gallery - blocks
I am looking for a way to adress the responsive srcset and sizes attributes on Gutenberg image blocks - like image, cover and gallery.
Usually one would do this with the '...
0
votes
1
answer
660
views
Add Color Settings To Wordpress Gutenberg Headers
How do I add color settings to the Gutenberg Header block? I've added theme support for paragraphs with this...
function apache_theme_supported_features() {
add_theme_support( 'editor-color-...
2
votes
2
answers
1k
views
Gutenberg Templates: Core Block Attributes
The Gutenberg Handbook currently has a short entry for creating whole templates of blocks used e.g. for Custom Post Types or the like.
https://wordpress.org/gutenberg/handbook/templates/
It seems ...