generator-chisel 2.2.1 → 2.2.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 +4 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/assets/images/chisel.svg +9 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/inc/Helpers/ThemeHelpers.php +3 -3
- package/lib/commands/create/creators/app/chisel-starter-theme/inc/Helpers/WoocommerceHelpers.php +2 -2
- package/lib/commands/create/creators/app/chisel-starter-theme/inc/Plugins/Woocommerce.php +15 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/inc/WP/AjaxEndpoints.php +12 -6
- package/lib/commands/create/creators/app/chisel-starter-theme/inc/WP/Blocks.php +9 -1
- package/lib/commands/create/creators/app/chisel-starter-theme/inc/WP/Components.php +2 -2
- package/lib/commands/create/creators/app/chisel-starter-theme/patterns/cta.php +3 -5
- package/lib/commands/create/creators/app/chisel-starter-theme/patterns/features.php +42 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/patterns/hero.php +48 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/src/design/tools/_icon.scss +1 -1
- package/lib/commands/create/creators/app/chisel-starter-theme/src/scripts/editor/blocks-mods.js +1 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/src/scripts/editor/mods/core.js +57 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/src/styles/blocks/_core-group.scss +14 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/src/styles/blocks/_core-media-text.scss +6 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/src/styles/utilities/_spacing.scss +3 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/src/styles/woo/_product-item.scss +4 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/style.chisel-tpl.css +1 -1
- package/lib/commands/create/creators/app/chisel-starter-theme/views/components/no-results.twig +1 -0
- package/lib/commands/create/creators/app/chisel-starter-theme/views/index.twig +1 -1
- package/lib/commands/create/creators/app/chisel-starter-theme/views/woocommerce/linked-products.twig +1 -1
- package/lib/commands/create/packages-versions.js +1 -1
- package/package.json +2 -2
- package/lib/commands/create/creators/app/chisel-starter-theme/assets/images/chisel.png +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
<!-- INSERT-NEW-ENTRIES-HERE -->
|
|
4
4
|
|
|
5
|
+
## <small>2.2.2 (2025-11-07)</small>
|
|
6
|
+
|
|
7
|
+
- blocks adjustments, new patterns, fixes, block mods ([19f038f](https://github.com/xfiveco/generator-chisel/commit/19f038f))
|
|
8
|
+
|
|
5
9
|
## <small>2.2.1 (2025-11-05)</small>
|
|
6
10
|
|
|
7
11
|
- fixes and defaults adjustments, improvements ([8d0ceca](https://github.com/xfiveco/generator-chisel/commit/8d0ceca))
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<svg width="168" height="48" viewBox="0 0 168 48" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M38.6943 4.53418C38.2917 4.73999 37.9766 5.04969 37.7646 5.41406C37.1328 6.50071 36.7955 8.05967 35.6777 8.63086L35.0029 8.97559C20.158 16.5585 18.4387 13.1768 3.59375 20.7598L8.06348 29.5537C22.9084 21.9708 21.1892 18.5878 36.0342 11.0049L36.709 10.6602C37.8268 10.0893 39.283 10.733 40.5312 10.8594C40.9501 10.9017 41.3861 10.8279 41.7891 10.6221L47.8799 7.51074V48H0.308594L9.18457 43.4658C9.58753 43.26 9.90321 42.9505 10.1152 42.5859C10.7471 41.4992 11.0842 39.9402 12.2021 39.3691L12.877 39.0244C27.7219 31.4415 29.4412 34.8232 44.2861 27.2402L39.8164 18.4463C24.9715 26.0292 26.6905 29.4122 11.8457 36.9951L11.1709 37.3398C10.0529 37.9109 8.59607 37.2669 7.34766 37.1406C6.92896 37.0983 6.49365 37.1722 6.09082 37.3779L0 40.4883V0H47.5713L38.6943 4.53418ZM7.85254 24.1221L8.72559 27.5107L5.63086 21.4229L7.85254 24.1221ZM42.249 26.5771L40.0264 23.8779L39.1543 20.4893L42.249 26.5771Z" fill="#DD2424"/>
|
|
3
|
+
<path d="M117.469 2.86829C122.503 2.86829 126.584 6.93546 126.584 11.9868V15.5854H120.021V11.9868C120.021 10.5725 118.879 9.42588 117.469 9.42588C116.06 9.42588 114.917 10.5725 114.917 11.9868C114.918 16.4082 116.93 18.8032 119.791 21.6734C122.757 24.6503 126.584 28.7273 126.584 36.016C126.583 41.0666 122.502 45.1317 117.469 45.1317C112.436 45.1317 108.356 41.0666 108.355 36.016V32.4146H114.917V36.016C114.918 37.4296 116.06 38.577 117.469 38.577C118.878 38.577 120.02 37.4296 120.021 36.016C120.021 31.5942 118.008 29.1997 115.148 26.3295C112.182 23.3527 108.355 19.2755 108.355 11.9868C108.355 6.93547 112.435 2.86829 117.469 2.86829Z" fill="#050A18"/>
|
|
4
|
+
<path d="M82.5425 20.7073H87.6466V3.16098H94.209V44.839H87.6466V27.2927H82.5425V44.839H75.9801V3.16098H82.5425V20.7073Z" fill="#050A18"/>
|
|
5
|
+
<path d="M104.563 44.839H98.0007V3.16098H104.563V44.839Z" fill="#050A18"/>
|
|
6
|
+
<path d="M156.333 38.2683H168V44.839H149.771V3.16098H156.333V38.2683Z" fill="#050A18"/>
|
|
7
|
+
<path d="M63.949 2.86801C68.9827 2.86801 73.0634 6.96297 73.0634 12.0144V15.5839H66.501V12.0144C66.501 10.6 65.3584 9.45338 63.949 9.45338C62.5395 9.45338 61.3969 10.6 61.3969 12.0144V35.9856C61.3978 37.3992 62.5401 38.5466 63.949 38.5466C65.3578 38.5466 66.5001 37.3992 66.501 35.9856V32.4132H73.0634V35.9856C73.0625 41.0362 68.9822 45.132 63.949 45.132C58.9157 45.132 54.8354 41.0362 54.8345 35.9856V12.0144C54.8354 6.96376 58.9157 2.86801 63.949 2.86801Z" fill="#050A18"/>
|
|
8
|
+
<path d="M147.729 9.73171H136.063V20.7073H146.271V27.2927H136.063V38.2683H147.729V44.839H129.5V3.16098H147.729V9.73171Z" fill="#050A18"/>
|
|
9
|
+
</svg>
|
|
@@ -159,9 +159,9 @@ final class ThemeHelpers {
|
|
|
159
159
|
$logo_data = wp_get_attachment_image_src( $logo_id, 'medium' );
|
|
160
160
|
} else {
|
|
161
161
|
$logo_data = array(
|
|
162
|
-
ImageHelpers::get_image_url( 'chisel.
|
|
163
|
-
|
|
164
|
-
|
|
162
|
+
ImageHelpers::get_image_url( 'chisel.svg' ),
|
|
163
|
+
200,
|
|
164
|
+
60,
|
|
165
165
|
0,
|
|
166
166
|
);
|
|
167
167
|
}
|
|
@@ -61,6 +61,8 @@ final class Woocommerce implements InstanceInterface, HooksInterface {
|
|
|
61
61
|
add_action( 'woocommerce_before_shop_loop', array( $this, 'before_shop_loop_div_close' ), 31 );
|
|
62
62
|
|
|
63
63
|
add_action( 'customize_register', array( $this, 'modify_customizer' ), 20 );
|
|
64
|
+
|
|
65
|
+
add_action( 'pre_get_posts', array( $this, 'pre_get_posts' ) );
|
|
64
66
|
}
|
|
65
67
|
|
|
66
68
|
/**
|
|
@@ -143,6 +145,19 @@ final class Woocommerce implements InstanceInterface, HooksInterface {
|
|
|
143
145
|
}
|
|
144
146
|
}
|
|
145
147
|
|
|
148
|
+
/**
|
|
149
|
+
* Set woocommerce query to get orderby setting from customizer so that is consistent with ajax queries.
|
|
150
|
+
*
|
|
151
|
+
* @param \WP_Query $query
|
|
152
|
+
*
|
|
153
|
+
* @return void
|
|
154
|
+
*/
|
|
155
|
+
public function pre_get_posts( \WP_Query $query ): void {
|
|
156
|
+
if ( ! is_admin() && $query->is_main_query() && ( is_shop() || is_product_category() || is_product_tag() ) ) {
|
|
157
|
+
$query->set( 'orderby', get_option( 'woocommerce_default_catalog_orderby', 'menu_order' ) );
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
146
161
|
/**
|
|
147
162
|
* Register woocommerce sidebars.
|
|
148
163
|
*
|
|
@@ -32,14 +32,18 @@ final class AjaxEndpoints {
|
|
|
32
32
|
|
|
33
33
|
$response = '';
|
|
34
34
|
|
|
35
|
-
$
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
'paged' => $page,
|
|
40
|
-
)
|
|
35
|
+
$args = array(
|
|
36
|
+
'post_type' => $post_type,
|
|
37
|
+
'posts_per_page' => $per_page,
|
|
38
|
+
'paged' => $page,
|
|
41
39
|
);
|
|
42
40
|
|
|
41
|
+
$posts = Timber::get_posts( $args )->to_array();
|
|
42
|
+
|
|
43
|
+
if ( $post_type === 'product' ) {
|
|
44
|
+
$args['orderby'] = get_option( 'woocommerce_default_catalog_orderby', 'menu_order' );
|
|
45
|
+
}
|
|
46
|
+
|
|
43
47
|
$templates = array( 'components/' . $post_type . '-item.twig', 'components/post-item.twig' );
|
|
44
48
|
|
|
45
49
|
if ( $post_type === 'product' ) {
|
|
@@ -50,6 +54,8 @@ final class AjaxEndpoints {
|
|
|
50
54
|
foreach ( $posts as $post ) {
|
|
51
55
|
$response .= Timber::compile( $templates, array( 'post' => $post ), CacheHelpers::expiry() );
|
|
52
56
|
}
|
|
57
|
+
} else {
|
|
58
|
+
$response = Timber::compile( 'components/no-results.twig' );
|
|
53
59
|
}
|
|
54
60
|
|
|
55
61
|
return $this->success( $response );
|
|
@@ -77,10 +77,18 @@ final class Blocks implements InstanceInterface, HooksInterface {
|
|
|
77
77
|
public function set_properties(): void {
|
|
78
78
|
$this->blocks_category = 'chisel-blocks';
|
|
79
79
|
$this->block_patterns_categories = array(
|
|
80
|
-
'cta'
|
|
80
|
+
'cta' => array(
|
|
81
81
|
'label' => __( 'Call to Action', 'chisel' ),
|
|
82
82
|
'description' => __( 'Call to Action Sections.', 'chisel' ),
|
|
83
83
|
),
|
|
84
|
+
'features' => array(
|
|
85
|
+
'label' => __( 'Features', 'chisel' ),
|
|
86
|
+
'description' => __( 'Features Sections.', 'chisel' ),
|
|
87
|
+
),
|
|
88
|
+
'hero' => array(
|
|
89
|
+
'label' => __( 'Hero', 'chisel' ),
|
|
90
|
+
'description' => __( 'Hero Sections.', 'chisel' ),
|
|
91
|
+
),
|
|
84
92
|
);
|
|
85
93
|
}
|
|
86
94
|
|
|
@@ -111,7 +111,7 @@ final class Components {
|
|
|
111
111
|
$sidebar_name = 'chisel-sidebar-' . $sidebar_id;
|
|
112
112
|
} elseif ( is_singular( 'post' ) ) {
|
|
113
113
|
$sidebar_name = 'chisel-sidebar-blog';
|
|
114
|
-
} elseif ( function_exists( 'is_shop' ) && is_shop() ) {
|
|
114
|
+
} elseif ( function_exists( 'is_shop' ) && ( is_shop() || is_product_category() || is_product_tag() ) ) {
|
|
115
115
|
$sidebar_name = 'chisel-sidebar-woocommerce';
|
|
116
116
|
}
|
|
117
117
|
|
|
@@ -123,7 +123,7 @@ final class Components {
|
|
|
123
123
|
return self::$sidebar[ $sidebar_name ];
|
|
124
124
|
}
|
|
125
125
|
|
|
126
|
-
$sidebar_content = Timber::get_widgets( $sidebar_name );
|
|
126
|
+
$sidebar_content = apply_filters( 'chisel_sidebar_content', Timber::get_widgets( $sidebar_name ), $sidebar_name );
|
|
127
127
|
|
|
128
128
|
self::$sidebar[ $sidebar_name ] = array(
|
|
129
129
|
'id' => $sidebar_id,
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
<?php
|
|
2
2
|
/**
|
|
3
|
-
* Title: Call to Action
|
|
4
|
-
* Slug: chisel/cta
|
|
3
|
+
* Title: Call to Action 01
|
|
4
|
+
* Slug: chisel/cta-01
|
|
5
5
|
* Categories: chisel-patterns/cta
|
|
6
|
-
* Description: A CTA section pattern
|
|
6
|
+
* Description: A CTA section pattern 01
|
|
7
7
|
* Keywords: cta
|
|
8
|
-
* Post Types: post, page
|
|
9
|
-
* Template Types: post, page
|
|
10
8
|
*
|
|
11
9
|
* @package Chisel
|
|
12
10
|
*/
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
<?php
|
|
2
|
+
/**
|
|
3
|
+
* Title: Features 01
|
|
4
|
+
* Slug: chisel/features-01
|
|
5
|
+
* Categories: chisel-patterns/features
|
|
6
|
+
* Description: Features pattern 01
|
|
7
|
+
* Keywords: features
|
|
8
|
+
*
|
|
9
|
+
* @package Chisel
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
?>
|
|
13
|
+
|
|
14
|
+
<!-- wp:media-text {"mediaSizeSlug":"large","className":"u-no-margin-bottom","backgroundColor":"grey-100","disableBottomMargin":true} -->
|
|
15
|
+
<div class="wp-block-media-text is-stacked-on-mobile u-no-margin-bottom has-grey-100-background-color has-background"><figure class="wp-block-media-text__media"></figure><div class="wp-block-media-text__content"><!-- wp:heading {"level":3} -->
|
|
16
|
+
<h3 class="wp-block-heading">Feature 1</h3>
|
|
17
|
+
<!-- /wp:heading -->
|
|
18
|
+
|
|
19
|
+
<!-- wp:paragraph -->
|
|
20
|
+
<p>Feature description</p>
|
|
21
|
+
<!-- /wp:paragraph --></div></div>
|
|
22
|
+
<!-- /wp:media-text -->
|
|
23
|
+
|
|
24
|
+
<!-- wp:media-text {"mediaPosition":"right","mediaSizeSlug":"large","className":"u-no-margin-bottom","backgroundColor":"grey-100","disableBottomMargin":true} -->
|
|
25
|
+
<div class="wp-block-media-text has-media-on-the-right is-stacked-on-mobile u-no-margin-bottom has-grey-100-background-color has-background"><div class="wp-block-media-text__content"><!-- wp:heading {"level":3} -->
|
|
26
|
+
<h3 class="wp-block-heading">Feature 2</h3>
|
|
27
|
+
<!-- /wp:heading -->
|
|
28
|
+
|
|
29
|
+
<!-- wp:paragraph -->
|
|
30
|
+
<p>Feature description</p>
|
|
31
|
+
<!-- /wp:paragraph --></div><figure class="wp-block-media-text__media"></figure></div>
|
|
32
|
+
<!-- /wp:media-text -->
|
|
33
|
+
|
|
34
|
+
<!-- wp:media-text {"mediaSizeSlug":"large","backgroundColor":"grey-100"} -->
|
|
35
|
+
<div class="wp-block-media-text is-stacked-on-mobile has-grey-100-background-color has-background"><figure class="wp-block-media-text__media"></figure><div class="wp-block-media-text__content"><!-- wp:heading {"level":3} -->
|
|
36
|
+
<h3 class="wp-block-heading">Feature 3</h3>
|
|
37
|
+
<!-- /wp:heading -->
|
|
38
|
+
|
|
39
|
+
<!-- wp:paragraph -->
|
|
40
|
+
<p>Feature description</p>
|
|
41
|
+
<!-- /wp:paragraph --></div></div>
|
|
42
|
+
<!-- /wp:media-text -->
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
<?php
|
|
2
|
+
/**
|
|
3
|
+
* Title: Hero 01
|
|
4
|
+
* Slug: chisel/hero-01
|
|
5
|
+
* Categories: chisel-patterns/hero
|
|
6
|
+
* Description: A hero section pattern 01
|
|
7
|
+
* Keywords: hero, banner
|
|
8
|
+
*
|
|
9
|
+
* @package Chisel
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
?>
|
|
13
|
+
|
|
14
|
+
<!-- wp:cover {"overlayColor":"foreground","isUserOverlayColor":true,"align":"full","layout":{"type":"constrained","contentSize":"848px","wideSize":"1072px"}} -->
|
|
15
|
+
<div class="wp-block-cover alignfull"><span aria-hidden="true" class="wp-block-cover__background has-foreground-background-color has-background-dim-100 has-background-dim"></span><div class="wp-block-cover__inner-container"><!-- wp:spacer {"height":"auto","className":"is-style-big"} -->
|
|
16
|
+
<div style="height:auto" aria-hidden="true" class="wp-block-spacer is-style-big"></div>
|
|
17
|
+
<!-- /wp:spacer -->
|
|
18
|
+
|
|
19
|
+
<!-- wp:spacer {"height":"auto","className":"is-style-large"} -->
|
|
20
|
+
<div style="height:auto" aria-hidden="true" class="wp-block-spacer is-style-large"></div>
|
|
21
|
+
<!-- /wp:spacer -->
|
|
22
|
+
|
|
23
|
+
<!-- wp:heading {"textAlign":"center","level":1} -->
|
|
24
|
+
<h1 class="wp-block-heading has-text-align-center">A modern development framework for WordPress</h1>
|
|
25
|
+
<!-- /wp:heading -->
|
|
26
|
+
|
|
27
|
+
<!-- wp:paragraph {"align":"center","placeholder":"Write title…","fontSize":"large"} -->
|
|
28
|
+
<p class="has-text-align-center has-large-font-size">Craft <strong>fast</strong> and <strong>easy to maintain</strong> WordPress websites. Use the <strong>power</strong> and <strong>simplicity</strong> of Timber and Twig. Make your CSS <strong>scalable</strong> and <strong>maintainable</strong> with ITCSS. Get rid of tedious manual tasks with Chisel's <strong>modern development workflow</strong>.</p>
|
|
29
|
+
<!-- /wp:paragraph -->
|
|
30
|
+
|
|
31
|
+
<!-- wp:spacer {"height":"auto","className":"is-style-large"} -->
|
|
32
|
+
<div style="height:auto" aria-hidden="true" class="wp-block-spacer is-style-large"></div>
|
|
33
|
+
<!-- /wp:spacer -->
|
|
34
|
+
|
|
35
|
+
<!-- wp:buttons {"layout":{"type":"flex","justifyContent":"center"}} -->
|
|
36
|
+
<div class="wp-block-buttons"><!-- wp:button {"className":"is-style-primary has-icon has-icon-arrow-right","buttonIcon":"arrow-right"} -->
|
|
37
|
+
<div class="wp-block-button is-style-primary has-icon has-icon-arrow-right"><a class="wp-block-button__link wp-element-button" href="#">Get started</a></div>
|
|
38
|
+
<!-- /wp:button -->
|
|
39
|
+
|
|
40
|
+
<!-- wp:button {"className":"-right is-style-primary-outline"} -->
|
|
41
|
+
<div class="wp-block-button -right is-style-primary-outline"><a class="wp-block-button__link wp-element-button">Learn more</a></div>
|
|
42
|
+
<!-- /wp:button --></div>
|
|
43
|
+
<!-- /wp:buttons -->
|
|
44
|
+
|
|
45
|
+
<!-- wp:spacer {"height":"auto","className":"is-style-big"} -->
|
|
46
|
+
<div style="height:auto" aria-hidden="true" class="wp-block-spacer is-style-big"></div>
|
|
47
|
+
<!-- /wp:spacer --></div></div>
|
|
48
|
+
<!-- /wp:cover -->
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { __ } from '@wordpress/i18n';
|
|
2
|
+
import { addFilter } from '@wordpress/hooks';
|
|
3
|
+
import { createHigherOrderComponent } from '@wordpress/compose';
|
|
4
|
+
import { InspectorControls } from '@wordpress/blockEditor';
|
|
5
|
+
import { PanelBody, ToggleControl } from '@wordpress/components';
|
|
6
|
+
import { Fragment } from '@wordpress/element';
|
|
7
|
+
|
|
8
|
+
addFilter('blocks.registerBlockType', 'chisel/add-no-margin-attribute', (settings) => {
|
|
9
|
+
if (typeof settings.attributes !== 'undefined') {
|
|
10
|
+
settings.attributes = {
|
|
11
|
+
...settings.attributes,
|
|
12
|
+
disableBottomMargin: {
|
|
13
|
+
type: 'boolean',
|
|
14
|
+
default: false,
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
return settings;
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
const addNoMarginToggle = createHigherOrderComponent((BlockEdit) => {
|
|
22
|
+
return (props) => {
|
|
23
|
+
const { attributes, setAttributes, isSelected } = props;
|
|
24
|
+
const { disableBottomMargin = false, className = '' } = attributes;
|
|
25
|
+
|
|
26
|
+
const onToggle = (checked) => {
|
|
27
|
+
let newClassName = className.replace(/\bu-no-margin-bottom\b/, '').trim();
|
|
28
|
+
if (checked) {
|
|
29
|
+
newClassName = `${newClassName} u-no-margin-bottom`.trim();
|
|
30
|
+
}
|
|
31
|
+
setAttributes({
|
|
32
|
+
disableBottomMargin: checked,
|
|
33
|
+
className: newClassName,
|
|
34
|
+
});
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
return (
|
|
38
|
+
<Fragment>
|
|
39
|
+
<BlockEdit {...props} />
|
|
40
|
+
{isSelected && (
|
|
41
|
+
<InspectorControls>
|
|
42
|
+
<PanelBody title={__('Spacing', 'chisel')}>
|
|
43
|
+
<ToggleControl
|
|
44
|
+
label={__('Disable bottom spacing', 'chisel')}
|
|
45
|
+
help={__('Removes the bottom spacing', 'chisel')}
|
|
46
|
+
checked={!!disableBottomMargin}
|
|
47
|
+
onChange={onToggle}
|
|
48
|
+
/>
|
|
49
|
+
</PanelBody>
|
|
50
|
+
</InspectorControls>
|
|
51
|
+
)}
|
|
52
|
+
</Fragment>
|
|
53
|
+
);
|
|
54
|
+
};
|
|
55
|
+
}, 'addNoMarginToggle');
|
|
56
|
+
|
|
57
|
+
addFilter('editor.BlockEdit', 'chisel/add-no-margin-toggle', addNoMarginToggle);
|
package/lib/commands/create/creators/app/chisel-starter-theme/src/styles/blocks/_core-group.scss
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
@use '~design' as *;
|
|
2
|
+
|
|
3
|
+
.wp-block-group-is-layout-constrained {
|
|
4
|
+
> :where(:not(.alignleft):not(.alignright):not(.alignfull)) {
|
|
5
|
+
max-width: get-layout-size('content');
|
|
6
|
+
margin-left: auto !important;
|
|
7
|
+
margin-right: auto !important;
|
|
8
|
+
padding-inline: get-padding('normal');
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
:where(.wp-block-group.has-background.alignfull) {
|
|
13
|
+
padding: get-padding('small') 0;
|
|
14
|
+
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Theme URI: https://www.getchisel.co/
|
|
4
4
|
* Author: <%= app.author %>
|
|
5
5
|
* Description: Chisel Wordpress Starter Theme based on Timber library.
|
|
6
|
-
* Version: 2.2.
|
|
6
|
+
* Version: 2.2.2
|
|
7
7
|
* License: GNU General Public License v2 or later
|
|
8
8
|
* License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
|
9
9
|
* Tags: chisel, custom, starter, theme, WordPress
|
package/lib/commands/create/creators/app/chisel-starter-theme/views/components/no-results.twig
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<h2>{{ __('No posts found', 'chisel') }}</h2>
|
|
@@ -20,7 +20,7 @@ In order to covert back to a grid, add the following classes to the c-posts-item
|
|
|
20
20
|
{% include ['components/' ~ post.post_type ~ '-item.twig', 'components/post-item.twig'] with {post: post} only %}
|
|
21
21
|
{% endfor %}
|
|
22
22
|
{% else %}
|
|
23
|
-
|
|
23
|
+
{% include 'components/no-results.twig' %}
|
|
24
24
|
{% endif %}
|
|
25
25
|
</div>
|
|
26
26
|
|
package/lib/commands/create/creators/app/chisel-starter-theme/views/woocommerce/linked-products.twig
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
{% endif %}
|
|
7
7
|
|
|
8
8
|
<div class="{{ bem('o-layout__item', (sidebar.content ? '8' : '12') ~ '-large') }}">
|
|
9
|
-
<div class="c-product-linked__items {{ grid_classnames }}">
|
|
9
|
+
<div class="c-product-linked__items {{ grid_classnames|default(bem('o-grid', 'cols-1', 'cols-2-small', 'cols-3-medium')) }}">
|
|
10
10
|
{% for post in linked_products %}
|
|
11
11
|
{% include "woocommerce/content-product.twig" with {post: post} %}
|
|
12
12
|
{% endfor %}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "generator-chisel",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.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": "
|
|
40
|
+
"gitHead": "cf2dafab46be1d1598354db3420c3deb35ecd0bb"
|
|
41
41
|
}
|