generator-chisel 2.1.1 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,10 @@
2
2
 
3
3
  <!-- INSERT-NEW-ENTRIES-HERE -->
4
4
 
5
+ ## <small>2.1.2 (2025-09-30)</small>
6
+
7
+ - minor fixes and adjustments, disable xmlrpc ([0bf6f64](https://github.com/xfiveco/generator-chisel/commit/0bf6f64))
8
+
5
9
  ## <small>2.1.1 (2025-05-26)</small>
6
10
 
7
11
  - add woo hooks, get_blocks fixes, js slider adjustments ([8c02af7](https://github.com/xfiveco/generator-chisel/commit/8c02af7))
@@ -2,7 +2,7 @@
2
2
 
3
3
  namespace Chisel\Controllers;
4
4
 
5
- use Chisel\WP\AjaxEnpoints;
5
+ use Chisel\WP\AjaxEndpoints;
6
6
  use Chisel\Interfaces\InstanceInterface;
7
7
  use Chisel\Interfaces\HooksInterface;
8
8
  use Chisel\Traits\Singleton;
@@ -104,7 +104,7 @@ class AjaxController extends \WP_REST_Controller implements InstanceInterface, H
104
104
  */
105
105
  public function callback( $request ) {
106
106
  $callback = $this->get_callback_name( $request );
107
- $ajax_endpoints = new AjaxEnpoints();
107
+ $ajax_endpoints = new AjaxEndpoints();
108
108
 
109
109
  if ( method_exists( $ajax_endpoints, $callback ) ) {
110
110
  if ( ! defined( 'DOING_AJAX' ) ) {
@@ -10,7 +10,7 @@ use Chisel\Helper\CacheHelpers;
10
10
  *
11
11
  * @package Chisel
12
12
  */
13
- class AjaxEnpoints {
13
+ class AjaxEndpoints {
14
14
 
15
15
  /**
16
16
  * Ajax call for load more feature.
@@ -209,11 +209,22 @@ class Blocks implements InstanceInterface, HooksInterface {
209
209
  return $block_content;
210
210
  }
211
211
 
212
- $block_content = preg_replace( '/<([^>]+) class="([^"]+)">/', '<$1 class="$2 ' . $custom_classnames . '">', $block_content, 1 );
213
- $block_content = preg_replace( '/class="([^"]*) (is-layout-flow|is-layout-constrained) ([^"]*)"/', 'class="$1 $3"', $block_content ); // It overwrites margin styles. Let's get rid of it.
212
+ $processor = new \WP_HTML_Tag_Processor( $block_content );
214
213
 
215
- if ( $block['blockName'] === 'core/table' ) {
216
- $block_content = preg_replace( '/<([^>]+) class="([^"]+)">/', '<$1 class="$2 u-table-responsive">', $block_content, 1 );
214
+ if ( $processor->next_tag() ) {
215
+ $classes_to_remove = array( 'is-layout-flow', 'is-layout-constrained' );
216
+
217
+ $processor->add_class( $custom_classnames );
218
+
219
+ foreach ( $classes_to_remove as $class ) {
220
+ $processor->remove_class( $class );
221
+ }
222
+
223
+ if ( $block['blockName'] === 'core/table' ) {
224
+ $processor->add_class( 'u-table-responsive' );
225
+ }
226
+
227
+ $block_content = $processor->get_updated_html();
217
228
  }
218
229
 
219
230
  return $block_content;
@@ -37,7 +37,7 @@ class Cache implements InstanceInterface, HooksInterface {
37
37
  *
38
38
  * @var int
39
39
  */
40
- private $environment_cache = true;
40
+ private $environment_cache = false;
41
41
 
42
42
  /**
43
43
  * Class constructor.
@@ -72,6 +72,9 @@ class Theme implements InstanceInterface, HooksInterface {
72
72
  add_filter( 'wp_revisions_to_keep', array( $this, 'wp_revisions_to_keep' ), 99, 2 );
73
73
  add_filter( 'heartbeat_settings', array( $this, 'heartbeat_settings' ) );
74
74
  add_filter( 'jpeg_quality', array( $this, 'jpeg_quality' ) );
75
+
76
+ // Disable legacy support for XML-RPC.
77
+ add_filter( 'xmlrpc_enabled', '__return_false' );
75
78
  }
76
79
 
77
80
  /**
@@ -10,7 +10,7 @@
10
10
  {{ slides_html }}
11
11
 
12
12
  <div class="b-slider__slide swiper-slide" {% if has_thumbnails_nav %}data-thumbnail-url="{{ get_image(slide.acf_bs_image).src('medium') }}"{% endif %}>
13
- {{ get_responsive_image(slide.acf_bs_image, 'large', {fetchpriority: loop.first ? 'high' : 'auto'}) }}
13
+ {{ get_responsive_image(slide.acf_bs_image, (block.align == 'full' ? 'full' : 'large'), {fetchpriority: loop.first ? 'high' : 'auto'}) }}
14
14
  </div>
15
15
  {% endset %}
16
16
  {% endif %}
@@ -1,5 +1,6 @@
1
1
  @use '../tools/theme' as *;
2
2
 
3
+ $scrollbar-width: 15px;
3
4
  $root-font-size: 16px;
4
5
  $breakpoints: (
5
6
  small: 480px,
@@ -13,7 +13,6 @@
13
13
  }
14
14
  }
15
15
 
16
- .c-content__inner,
17
16
  .c-blog {
18
17
  padding-top: get-padding('large');
19
18
  }
@@ -14,4 +14,6 @@ html {
14
14
  overflow: hidden;
15
15
  }
16
16
  }
17
+
18
+ --scrollbar-width: #{settings.$scrollbar-width};
17
19
  }
@@ -1,5 +1,5 @@
1
1
  module.exports = {
2
2
  'chisel-scripts': '2.0.0-2.0.0-alpha.8.1',
3
3
  'chisel-shared-utils': '2.0.0-alpha.1',
4
- 'generator-chisel': '2.1.1',
4
+ 'generator-chisel': '2.1.2',
5
5
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "generator-chisel",
3
- "version": "2.1.1",
3
+ "version": "2.1.2",
4
4
  "description": "A generator for scaffolding front-end and WordPress projects",
5
5
  "bin": {
6
6
  "chisel": "bin/chisel.js"
@@ -37,5 +37,5 @@
37
37
  "tinyqueue": "^2.0.3",
38
38
  "update-notifier": "^4.1.0"
39
39
  },
40
- "gitHead": "5ce0d679d897e7cc1ed936bddf6d50aa9cab3ea1"
40
+ "gitHead": "7aabcf71d9f484090682199e93b3ab5328e511a9"
41
41
  }