This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Sources: | |
https://stackoverflow.com/questions/8720931/can-css-detect-the-number-of-children-an-element-has | |
https://lea.verou.me/2011/01/styling-children-based-on-their-number-with-css3/ | |
https://gist.github.com/Zodiac1978/d3a857b0520db51e84c0939cab853ebb | |
https://die-netzialisten.de/responsiveness-spalten-block-anpassen/ | |
*/ | |
@media (min-width: 600px) and (max-width: 781px) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'init', function() { | |
register_block_pattern( | |
'ks-testimonial-pattern', | |
[ | |
'title' => __('Testimonials', 'ks-block-pattern'), | |
'description' => _x('Drei Testimonials', 'ks-block-pattern'), | |
'categories' => ['columns'], | |
'content' => ' | |
<!-- wp:group --> | |
<div class="wp-block-group ks-testimonials"><div class="wp-block-group__inner-container"><!-- wp:heading {"level":3} --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function removeCorePatternsCategories() { | |
unregister_block_pattern_category('buttons'); | |
unregister_block_pattern_category('columns'); | |
unregister_block_pattern_category('gallery'); | |
unregister_block_pattern_category('header'); | |
unregister_block_pattern_category('text'); | |
unregister_block_pattern_category('uncategorized'); | |
} | |
add_action('init', 'removeCorePatternsCategories'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function netzialisten_register_block_categories() { | |
if ( class_exists( 'WP_Block_Patterns_Registry' ) ) { | |
register_block_pattern_category( | |
'Netzialisten', | |
array( 'label' => _x( 'Patterns Netzialisten', 'Block pattern category', 'netzialisten' ) ) | |
); | |
} | |
} | |
add_action( 'init', 'netzialisten_register_block_categories' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*Resets*/ | |
.preistabelle .wp-block-column:not(:first-child) { | |
margin-left: 1em; | |
} | |
.preistabelle p{ | |
margin-top:0; | |
} | |
.preistabelle .wp-block-group{ | |
padding:1em 0.5em; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'init', function() { | |
register_block_pattern( | |
'ks-testimonial-pattern', | |
[ | |
'title' => __('Testimonials', 'ks-block-pattern'), | |
'description' => _x('Drei Testimonials', 'ks-block-pattern'), | |
'categories' => ['columns'], | |
'content' => ' | |
<!-- wp:group --> | |
<div class="wp-block-group ks-testimonials"><div class="wp-block-group__inner-container"><!-- wp:heading {"level":3} --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Kirstens Gutenberg Block Styles | |
* Plugin URI: https://die-netzialisten.de | |
* Description: Block Styles für Absatz-Block und Listen-Block | |
* Version: 1.0 | |
* Author: Kirsten Schelper | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*Paragraph Red Box*/ | |
.is-style-paragraph-red-box { | |
padding: 1em; | |
background-color: #dc143c; | |
color:white; | |
font-family: "fira_sansmedium"; | |
text-align: center; | |
border-radius:6px; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Paragraph Box | |
wp.blocks.registerBlockStyle( 'core/paragraph', { | |
name: 'paragraph-red-box', | |
label: 'Rote Box' | |
} ); | |
//List with checkmarks |
NewerOlder