CHORE REFACTOR upgrading plugin to handle a unique monopackage bundler
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
67e84ca08f
commit
5dc6ea260d
24
plugins/carhop-blocks/acf-blocks/team-carhop/block.json
Normal file
24
plugins/carhop-blocks/acf-blocks/team-carhop/block.json
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
{
|
||||
"name": "acf/team-carhop",
|
||||
"title": "Équipe Carhop",
|
||||
"category": "carhop-blocks",
|
||||
"multiple": true,
|
||||
"icon": {
|
||||
"foreground": "#136f63",
|
||||
"src": "universal-access-alt"
|
||||
},
|
||||
"keywords": [
|
||||
"équipe",
|
||||
"carhop"
|
||||
],
|
||||
"supports": {
|
||||
"align": [
|
||||
"full"
|
||||
]
|
||||
},
|
||||
"acf": {
|
||||
"mode": "auto",
|
||||
"renderTemplate": "team-carhop.php"
|
||||
},
|
||||
"align": "full"
|
||||
}
|
||||
70
plugins/carhop-blocks/acf-blocks/team-carhop/team-carhop.php
Normal file
70
plugins/carhop-blocks/acf-blocks/team-carhop/team-carhop.php
Normal file
|
|
@ -0,0 +1,70 @@
|
|||
<?php
|
||||
|
||||
$teamMembers = get_posts(array(
|
||||
'post_type' => 'equipe',
|
||||
'posts_per_page' => -1,
|
||||
));
|
||||
|
||||
|
||||
$placeholder_thumbnail_counter = 0;
|
||||
$personnalized_order = get_field('personnalized_order');
|
||||
$members_manually_sorted = get_field('members_manually_sorted');
|
||||
|
||||
|
||||
if ($personnalized_order) {
|
||||
$teamMembers = $members_manually_sorted;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<section class="team-authors content-section" <?php echo get_block_wrapper_attributes(); ?>>
|
||||
<div class="container">
|
||||
<ul class="comity-type__list">
|
||||
<?php foreach ($teamMembers as $member) : ?>
|
||||
<?php
|
||||
|
||||
$member_thumbnail = get_field('profile_thumbnail', $member->ID);
|
||||
$member_description = get_field('description', $member->ID);
|
||||
$member_email = get_field('email', $member->ID);
|
||||
|
||||
$is_director = $member->ID === 476 ? true : false;
|
||||
|
||||
?>
|
||||
<li class="comity-type__item author-card <?php echo $is_director ? 'author-card--director' : ''; ?>">
|
||||
<div class="author-card__profile-picture">
|
||||
<?php if ($member_thumbnail) : ?>
|
||||
<a href="<?php echo get_the_permalink($author->ID); ?>">
|
||||
<img src="<?php echo $member_thumbnail['url']; ?>" alt="<?php echo $member_thumbnail['alt']; ?>">
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<a href="<?php echo get_the_permalink($member->ID); ?>">
|
||||
<div class="author-card__profile-picture-placeholder author-card__profile-picture-placeholder--<?php echo $placeholder_thumbnail_counter % 3 + 1; ?>n">
|
||||
<!-- <img class="" src="<?php echo get_template_directory_uri(); ?>/assets/images/placeholder-author.png" alt="Placeholder author"> -->
|
||||
</div>
|
||||
</a>
|
||||
<?php $placeholder_thumbnail_counter++; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<h4 class="author-card__name">
|
||||
<a href="<?php echo get_the_permalink($member->ID); ?>"> <?php echo $member->post_title; ?></a>
|
||||
</h4>
|
||||
|
||||
<p class="author-card__bio"><?php echo $member_description; ?></p>
|
||||
<?php if ($member_email) : ?>
|
||||
<a href="mailto:<?php echo $member_email; ?>" class="author-card__email cta cta--classic cta--rounded cta--has-icon cta--mailing">
|
||||
<div class="cta__icon">
|
||||
<?php $mail_svg_path = get_template_directory() . '/resources/img/icons/carhop-mail.svg';
|
||||
if (file_exists($mail_svg_path)) {
|
||||
echo file_get_contents($mail_svg_path);
|
||||
} ?>
|
||||
</div>
|
||||
Envoyer un email
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</li>
|
||||
|
||||
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -1,152 +0,0 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* Plugin Name: Audio Player
|
||||
* Description: Example block scaffolded with Create Block tool.
|
||||
* Version: 0.1.0
|
||||
* Requires at least: 6.7
|
||||
* Requires PHP: 7.4
|
||||
* Author: The WordPress Contributors
|
||||
* License: GPL-2.0-or-later
|
||||
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||
* Text Domain: audio-player
|
||||
*
|
||||
* @package CreateBlock
|
||||
*/
|
||||
|
||||
if (! defined('ABSPATH')) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
/**
|
||||
* Register Plyr library assets
|
||||
* Assets are copied from node_modules to assets/plyr for production deployment
|
||||
*/
|
||||
function create_block_audio_player_register_plyr()
|
||||
{
|
||||
// Register Plyr CSS
|
||||
wp_register_style(
|
||||
'plyr',
|
||||
plugins_url('assets/plyr/plyr.css', __FILE__),
|
||||
array(),
|
||||
'3.8.3'
|
||||
);
|
||||
|
||||
// Register Plyr JS
|
||||
wp_register_script(
|
||||
'plyr',
|
||||
plugins_url('assets/plyr/plyr.min.js', __FILE__),
|
||||
array(),
|
||||
'3.8.3',
|
||||
true
|
||||
);
|
||||
}
|
||||
add_action('init', 'create_block_audio_player_register_plyr');
|
||||
|
||||
/**
|
||||
* Enqueue Plyr in the block editor
|
||||
*/
|
||||
function create_block_audio_player_enqueue_editor_assets()
|
||||
{
|
||||
wp_enqueue_style('plyr');
|
||||
wp_enqueue_script('plyr');
|
||||
}
|
||||
add_action('enqueue_block_editor_assets', 'create_block_audio_player_enqueue_editor_assets');
|
||||
|
||||
/**
|
||||
* Enqueue Plyr assets when the block is used
|
||||
*/
|
||||
function create_block_audio_player_enqueue_assets($block_content, $block)
|
||||
{
|
||||
if ('carhop-blocks/audio-player' === $block['blockName']) {
|
||||
wp_enqueue_style('plyr');
|
||||
wp_enqueue_script('plyr');
|
||||
}
|
||||
return $block_content;
|
||||
}
|
||||
add_filter('render_block', 'create_block_audio_player_enqueue_assets', 10, 2);
|
||||
|
||||
/**
|
||||
* Registers the block using a `blocks-manifest.php` file, which improves the performance of block type registration.
|
||||
* Behind the scenes, it also registers all assets so they can be enqueued
|
||||
* through the block editor in the corresponding context.
|
||||
*
|
||||
* @see https://make.wordpress.org/core/2025/03/13/more-efficient-block-type-registration-in-6-8/
|
||||
* @see https://make.wordpress.org/core/2024/10/17/new-block-type-registration-apis-to-improve-performance-in-wordpress-6-7/
|
||||
*/
|
||||
function create_block_audio_player_block_init()
|
||||
{
|
||||
/**
|
||||
* Registers the block(s) metadata from the `blocks-manifest.php` and registers the block type(s)
|
||||
* based on the registered block metadata.
|
||||
* Added in WordPress 6.8 to simplify the block metadata registration process added in WordPress 6.7.
|
||||
*
|
||||
* @see https://make.wordpress.org/core/2025/03/13/more-efficient-block-type-registration-in-6-8/
|
||||
*/
|
||||
if (function_exists('wp_register_block_types_from_metadata_collection')) {
|
||||
wp_register_block_types_from_metadata_collection(__DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php');
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers the block(s) metadata from the `blocks-manifest.php` file.
|
||||
* Added to WordPress 6.7 to improve the performance of block type registration.
|
||||
*
|
||||
* @see https://make.wordpress.org/core/2024/10/17/new-block-type-registration-apis-to-improve-performance-in-wordpress-6-7/
|
||||
*/
|
||||
if (function_exists('wp_register_block_metadata_collection')) {
|
||||
wp_register_block_metadata_collection(__DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php');
|
||||
}
|
||||
/**
|
||||
* Registers the block type(s) in the `blocks-manifest.php` file.
|
||||
*
|
||||
* @see https://developer.wordpress.org/reference/functions/register_block_type/
|
||||
*/
|
||||
$manifest_data = require __DIR__ . '/build/blocks-manifest.php';
|
||||
foreach (array_keys($manifest_data) as $block_type) {
|
||||
register_block_type(__DIR__ . "/build/{$block_type}");
|
||||
}
|
||||
}
|
||||
add_action('init', 'create_block_audio_player_block_init');
|
||||
|
||||
|
||||
|
||||
/* ############## DISALLOW BLOCKS ############## */
|
||||
|
||||
/**
|
||||
* Désactive le bloc audio natif pour les utilisateurs non administrateurs pour éviter toute confusio
|
||||
*
|
||||
*/
|
||||
function carhop_blocks_disallow_block_types($allowed_block_types, $block_editor_context)
|
||||
{
|
||||
|
||||
|
||||
|
||||
$disallowed_blocks = array(
|
||||
'core/audio',
|
||||
);
|
||||
|
||||
// Get all registered blocks if $allowed_block_types is not already set.
|
||||
if (! is_array($allowed_block_types) || empty($allowed_block_types)) {
|
||||
$registered_blocks = WP_Block_Type_Registry::get_instance()->get_all_registered();
|
||||
$allowed_block_types = array_keys($registered_blocks);
|
||||
}
|
||||
|
||||
// Create a new array for the allowed blocks.
|
||||
$filtered_blocks = array();
|
||||
|
||||
// Loop through each block in the allowed blocks list.
|
||||
foreach ($allowed_block_types as $block) {
|
||||
|
||||
// Check if the block is not in the disallowed blocks list.
|
||||
if (! in_array($block, $disallowed_blocks, true)) {
|
||||
|
||||
// If it's not disallowed, add it to the filtered list.
|
||||
$filtered_blocks[] = $block;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Return the filtered list of allowed blocks
|
||||
return $filtered_blocks;
|
||||
}
|
||||
add_filter('allowed_block_types_all', 'carhop_blocks_disallow_block_types', 10, 2);
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"audio-player/index.css","mappings":";;;AAAA;;EAAA;AAIC;EACC;EACA;EACA;AAAF;AAGE;EACC;AADH,C","sources":["webpack://audio-player/./src/audio-player/editor.scss"],"sourcesContent":["/**\n * Styles for the block editor\n */\n.wp-block-create-block-audio-player {\n\t.audio-player-preview {\n\t\tpadding: 16px;\n\t\tbackground: #f0f0f0;\n\t\tborder-radius: 8px;\n\t\t\n\t\t// Ensure Plyr player has appropriate styling in the editor\n\t\t.plyr {\n\t\t\tmax-width: 100%;\n\t\t}\n\t}\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"audio-player/style-index.css","mappings":";;;AAAA;;;EAAA;AAMC;EACC;AADF;AADA;EAIC;EACA;EACA;EAGA;EACA;EAGA;;GAAA;EAGA;EACA;AAJD;AAMC;;EAEC;EACA;EACA;AAJF;AAOC;EACC;AALF;AAQC;EACC;EACA;EACA;EACA;EACA;AANF;AAUE;EACC;EACA;AARH,C","sources":["webpack://audio-player/./src/audio-player/style.scss"],"sourcesContent":["/**\n * Styles for Plyr audio player block\n * These styles are applied both in the editor and on the front-end\n */\n\n.wp-block-carhop-blocks-audio-player {\n\t.plyr__controls {\n\t\tpadding: 2rem 0 !important;\n\t}\n\t--plyr-color-main: var(--wp--preset--color--primary);\n\t--plyr-menu-border-color: var(--wp--preset--color--carhop-green);\n\t--plyr-menu-border-shadow-color: var(--wp--preset--color--carhop-green);\n\t// --plyr-control-radius: 50%;\n\n\t--plyr-control-icon-size: 20px;\n\t--plyr-audio-control-color: var(--wp--preset--color--primary);\n\t// Utiliser la couleur directement depuis tailwind.config.js ligne 32\n\t// --plyr-audio-range-track-background: #9df2de;\n\t--plyr-audio-range-track-background: var(\n\t\t--wp--preset--color--carhop-green--200\n\t);\n\tborder: 1px solid var(--wp--preset--color--primary);\n\tpadding: 2rem;\n\n\tbutton[data-plyr=\"play\"],\n\tbutton[data-plyr=\"mute\"] {\n\t\tborder-radius: 50%;\n\t\tborder: 1px solid var(--wp--preset--color--primary);\n\t\tpadding: 2rem;\n\t}\n\n\tbutton[data-plyr=\"mute\"] {\n\t\tpadding: 1rem;\n\t}\n\n\t.audio-player__title {\n\t\ttext-transform: uppercase;\n\t\tfont-size: 1.5rem;\n\t\tfont-weight: 600;\n\t\tcolor: var(--wp--preset--color--primary);\n\t\tmargin: 0;\n\t}\n\n\t.audio-player__details {\n\t\t&__label {\n\t\t\tmargin-right: 0.5rem;\n\t\t\ttext-transform: uppercase;\n\t\t}\n\t}\n\n\t// Plyr container styles\n\t// .plyr {\n\t// \tborder-radius: 8px;\n\t// }\n\n\t// // Customize Plyr colors if needed\n\t// .plyr--audio .plyr__control.plyr__tab-focus,\n\t// .plyr--audio .plyr__control:hover,\n\t// .plyr--audio .plyr__control[aria-expanded=\"true\"] {\n\t// \tbackground: #21759b;\n\t// }\n\n\t// .plyr__control--overlaid {\n\t// \tbackground: rgba(33, 117, 155, 0.8);\n\t// }\n}\n\n// .plyr--full-ui input[type=\"range\"] {\n// \tcolor: red;\n// }\n\n// .plyr__control--overlaid {\n// \tbackground: rgba(red, 0.8);\n// }\n\n// .plyr--video .plyr__control.plyr__tab-focus,\n// .plyr--video .plyr__control:hover,\n// .plyr--video .plyr__control[aria-expanded=\"true\"] {\n// \tbackground: red;\n// }\n\n// .plyr__control.plyr__tab-focus {\n// \tbox-shadow: 0 0 0 5px rgba(red, 0.5);\n// }\n\n// .plyr__menu__container\n// \t.plyr__control[role=\"menuitemradio\"][aria-checked=\"true\"]::before {\n// \tbackground: red;\n// }\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"audio-player/view.js","mappings":";;;;AAAA;AACA;AACA;AACA;;AAEA;AACAA,QAAQ,CAACC,gBAAgB,CAAC,kBAAkB,EAAE,MAAM;EACnD;EACA,IAAI,OAAOC,IAAI,KAAK,WAAW,EAAE;IAChC;IACAC,OAAO,CAACC,KAAK,CAAC,yBAAyB,CAAC;IACxC;IACA;EACD;EAEA,MAAMC,OAAO,GAAGC,KAAK,CAACC,IAAI,CAACP,QAAQ,CAACQ,gBAAgB,CAAC,UAAU,CAAC,CAAC,CAACC,GAAG,CACnEC,OAAO,IACP,IAAIR,IAAI,CAACQ,OAAO,EAAE;IACjBC,QAAQ,EAAE,CACT,YAAY,EACZ,MAAM,EACN,UAAU,EACV,cAAc,EACd,UAAU,EACV,MAAM,EACN,QAAQ,EACR,UAAU,CACV;IACDC,QAAQ,EAAE,CAAC,OAAO,CAAC;IACnBC,KAAK,EAAE;MAAEC,QAAQ,EAAE,CAAC;MAAEC,OAAO,EAAE,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC;IAAE;EAC7D,CAAC,CACH,CAAC;;EAED;EACA,IAAIV,OAAO,CAACW,MAAM,GAAG,CAAC,EAAE;IACvB;IACAb,OAAO,CAACc,GAAG,CAAC,iCAAiC,EAAEZ,OAAO,CAACW,MAAM,CAAC;IAC9D;EACD;AACD,CAAC,CAAC,C","sources":["webpack://audio-player/./src/audio-player/view.js"],"sourcesContent":["/**\n * Initializes Plyr audio player on the front-end\n * Note: Plyr is loaded as a dependency via PHP (see audio-player.php)\n */\n\n// Initialize Plyr on all audio elements with the js-plyr class\ndocument.addEventListener(\"DOMContentLoaded\", () => {\n\t// Check if Plyr is available (loaded via PHP)\n\tif (typeof Plyr === \"undefined\") {\n\t\t/* eslint-disable no-console */\n\t\tconsole.error(\"Plyr library not loaded\");\n\t\t/* eslint-enable no-console */\n\t\treturn;\n\t}\n\n\tconst players = Array.from(document.querySelectorAll(\".js-plyr\")).map(\n\t\t(element) =>\n\t\t\tnew Plyr(element, {\n\t\t\t\tcontrols: [\n\t\t\t\t\t\"play-large\",\n\t\t\t\t\t\"play\",\n\t\t\t\t\t\"progress\",\n\t\t\t\t\t\"current-time\",\n\t\t\t\t\t\"duration\",\n\t\t\t\t\t\"mute\",\n\t\t\t\t\t\"volume\",\n\t\t\t\t\t\"settings\",\n\t\t\t\t],\n\t\t\t\tsettings: [\"speed\"],\n\t\t\t\tspeed: { selected: 1, options: [0.5, 0.75, 1, 1.25, 1.5, 2] },\n\t\t\t})\n\t);\n\n\t// Optional: Log players for debugging\n\tif (players.length > 0) {\n\t\t/* eslint-disable no-console */\n\t\tconsole.log(\"Plyr audio players initialized:\", players.length);\n\t\t/* eslint-enable no-console */\n\t}\n});\n"],"names":["document","addEventListener","Plyr","console","error","players","Array","from","querySelectorAll","map","element","controls","settings","speed","selected","options","length","log"],"sourceRoot":""}
|
||||
|
|
@ -1,55 +0,0 @@
|
|||
<?php
|
||||
// This file is generated. Do not modify it manually.
|
||||
return array(
|
||||
'audio-player' => array(
|
||||
'$schema' => 'https://schemas.wp.org/trunk/block.json',
|
||||
'apiVersion' => 3,
|
||||
'name' => 'carhop-blocks/audio-player',
|
||||
'version' => '0.1.0',
|
||||
'title' => 'Lecteur audio',
|
||||
'category' => 'carhop-blocks',
|
||||
'icon' => array(
|
||||
'src' => 'format-audio',
|
||||
'foreground' => '#136f63'
|
||||
),
|
||||
'description' => 'Lecteur audio pour intégrer un fichier audio dans votre contenu',
|
||||
'example' => array(
|
||||
|
||||
),
|
||||
'attributes' => array(
|
||||
'audioUrl' => array(
|
||||
'type' => 'string',
|
||||
'default' => ''
|
||||
),
|
||||
'audioId' => array(
|
||||
'type' => 'number',
|
||||
'default' => 0
|
||||
),
|
||||
'title' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'Titre du bloc audio'
|
||||
),
|
||||
'description' => array(
|
||||
'type' => 'string',
|
||||
'default' => ''
|
||||
),
|
||||
'caption' => array(
|
||||
'type' => 'string',
|
||||
'default' => ''
|
||||
)
|
||||
),
|
||||
'supports' => array(
|
||||
'html' => false
|
||||
),
|
||||
'keywords' => array(
|
||||
'audio',
|
||||
'player',
|
||||
'lecteur audio'
|
||||
),
|
||||
'textdomain' => 'carhop-blocks',
|
||||
'editorScript' => 'file:./index.js',
|
||||
'editorStyle' => 'file:./index.css',
|
||||
'style' => 'file:./style-index.css',
|
||||
'viewScript' => 'file:./view.js'
|
||||
)
|
||||
);
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"index.css","mappings":";;;AACC;EACC;AAAF;AAGC;EAGC;EACA;AAHF;AAKC;EAIC;AANF;AAQC;EAIC;AATF;AAWC;EAIC;AAZF;AAcC;EAIC;AAfF;;AAoBA;EACC;EACA;EACA;AAjBD;;AAoBA;EACC;EACA;EACA;EACA;AAjBD,C","sources":["webpack://front-header/./src/editor.scss"],"sourcesContent":[".card-grid {\n\t&__innerblocks {\n\t\tdisplay: block;\n\t}\n\n\t.card-grid__innerblocks\n\t\t> .block-editor-inner-blocks\n\t\t> .block-editor-block-list__layout {\n\t\tdisplay: grid;\n\t\tgap: 1rem;\n\t}\n\t&--columns-2\n\t\t.card-grid__innerblocks\n\t\t> .block-editor-inner-blocks\n\t\t> .block-editor-block-list__layout {\n\t\tgrid-template-columns: repeat(2, 1fr);\n\t}\n\t&--columns-3\n\t\t.card-grid__innerblocks\n\t\t> .block-editor-inner-blocks\n\t\t> .block-editor-block-list__layout {\n\t\tgrid-template-columns: repeat(3, 1fr);\n\t}\n\t&--columns-4\n\t\t.card-grid__innerblocks\n\t\t> .block-editor-inner-blocks\n\t\t> .block-editor-block-list__layout {\n\t\tgrid-template-columns: repeat(4, 1fr);\n\t}\n\t&--columns-5\n\t\t.card-grid__innerblocks\n\t\t> .block-editor-inner-blocks\n\t\t> .block-editor-block-list__layout {\n\t\tgrid-template-columns: repeat(5, 1fr);\n\t}\n}\n\n// Styles pour les alignements dans l'éditeur\n.card-grid.alignwide {\n\tmax-width: var(--wp--style--global--wide-size, 1200px);\n\tmargin-left: auto;\n\tmargin-right: auto;\n}\n\n.card-grid.alignfull {\n\tmax-width: none;\n\tmargin-left: 0;\n\tmargin-right: 0;\n\twidth: 100%;\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"./style-index.css","mappings":";;;AACC;EACC;EACA;AAAF;AAIE;EACC;EACA;AAFH;AAME;EACC;AAJH;;AAUA;EACC;EACA;EACA;AAPD;;AAUA;EACC;EACA;EACA;EACA;AAPD,C","sources":["webpack://front-header/./src/style.scss"],"sourcesContent":[".card-grid {\r\n\t&__innerblocks {\r\n\t\tdisplay: grid;\r\n\t\tgap: 1rem;\r\n\t}\r\n\r\n\t&--cards-with-border {\r\n\t\t.content-card {\r\n\t\t\tborder: 1px solid var(--wp--preset--color--primary);\r\n\t\t\tpadding: 2rem;\r\n\t\t}\r\n\t}\r\n\t&--cards-without-border {\r\n\t\t.content-card {\r\n\t\t\tborder: none;\r\n\t\t}\r\n\t}\r\n}\r\n\r\n// Styles pour les alignements\r\n.card-grid.alignwide {\r\n\tmax-width: var(--wp--style--global--wide-size, 1200px);\r\n\tmargin-left: auto;\r\n\tmargin-right: auto;\r\n}\r\n\r\n.card-grid.alignfull {\r\n\tmax-width: none;\r\n\tmargin-left: 0;\r\n\tmargin-right: 0;\r\n\twidth: 100%;\r\n}\r\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '9618df91ea3d5989c295');
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
/******/ (() => { // webpackBootstrap
|
||||
/*!*********************!*\
|
||||
!*** ./src/view.js ***!
|
||||
\*********************/
|
||||
|
||||
/******/ })()
|
||||
;
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{
|
||||
"name": "front-header",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.12.0"
|
||||
},
|
||||
"packageManager": "pnpm@9.11.0+sha512.0a203ffaed5a3f63242cd064c8fb5892366c103e328079318f78062f24ea8c9d50bc6a47aa3567cabefd824d170e78fa2745ed1f16b132e16436146b7688f19b"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
30
plugins/carhop-blocks/blocks/chapo/.gitignore
vendored
30
plugins/carhop-blocks/blocks/chapo/.gitignore
vendored
|
|
@ -1,30 +0,0 @@
|
|||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Output of `npm pack`
|
||||
*.tgz
|
||||
|
||||
# Output of `wp-scripts plugin-zip`
|
||||
*.zip
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
|
|
@ -1,37 +0,0 @@
|
|||
<?php
|
||||
// This file is generated. Do not modify it manually.
|
||||
return array(
|
||||
'chapo' => array(
|
||||
'$schema' => 'https://schemas.wp.org/trunk/block.json',
|
||||
'apiVersion' => 3,
|
||||
'name' => 'carhop-blocks/chapo',
|
||||
'version' => '0.1.0',
|
||||
'title' => 'Chapo',
|
||||
'category' => 'carhop-blocks',
|
||||
'icon' => 'smiley',
|
||||
'description' => 'Chapo pour la mise en forme supérieure d\'éléments de contenu',
|
||||
'example' => array(
|
||||
|
||||
),
|
||||
'supports' => array(
|
||||
'html' => false,
|
||||
'color' => array(
|
||||
'text' => true,
|
||||
'background' => false,
|
||||
'link' => false
|
||||
)
|
||||
),
|
||||
'textdomain' => 'chapo',
|
||||
'editorScript' => 'file:./index.js',
|
||||
'editorStyle' => 'file:./index.css',
|
||||
'style' => 'file:./style-index.css',
|
||||
'viewScript' => 'file:./view.js',
|
||||
'attributes' => array(
|
||||
'content' => array(
|
||||
'type' => 'string',
|
||||
'source' => 'html',
|
||||
'selector' => 'p'
|
||||
)
|
||||
)
|
||||
)
|
||||
);
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-i18n'), 'version' => '8a790796af9d3dfea9e4');
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"chapo/index.css","mappings":";;;AAAA;;;;EAAA;AAMA;EACC;AAAD,C","sources":["webpack://chapo/./src/chapo/editor.scss"],"sourcesContent":["/**\n * The following styles get applied inside the editor only.\n *\n * Replace them with your own styles or remove the file completely.\n */\n\n.wp-block-create-block-chapo {\n\tborder: 1px dotted #f00;\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"chapo/style-index.css","mappings":";;;AAAA;;;;;EAAA;AAOA;EACC;EACA;EACA;AAAD,C","sources":["webpack://chapo/./src/chapo/style.scss"],"sourcesContent":["/**\n * The following styles get applied both on the front of your site\n * and in the editor.\n *\n * Replace them with your own styles or remove the file completely.\n */\n\n.wp-block-create-block-chapo {\n\tbackground-color: #21759b;\n\tcolor: #fff;\n\tpadding: 2px;\n}\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"chapo/view.js","mappings":";;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACAA,OAAO,CAACC,GAAG,CAAE,8CAA+C,CAAC;AAC7D,8B","sources":["webpack://chapo/./src/chapo/view.js"],"sourcesContent":["/**\n * Use this file for JavaScript code that you want to run in the front-end\n * on posts/pages that contain this block.\n *\n * When this file is defined as the value of the `viewScript` property\n * in `block.json` it will be enqueued on the front end of the site.\n *\n * Example:\n *\n * ```js\n * {\n * \"viewScript\": \"file:./view.js\"\n * }\n * ```\n *\n * If you're not making any changes to this file because your project doesn't need any\n * JavaScript running in the front-end, then you should delete this file and remove\n * the `viewScript` property from `block.json`.\n *\n * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-metadata/#view-script\n */\n\n/* eslint-disable no-console */\nconsole.log( 'Hello World! (from create-block-chapo block)' );\n/* eslint-enable no-console */\n"],"names":["console","log"],"sourceRoot":""}
|
||||
|
|
@ -1,59 +0,0 @@
|
|||
<?php
|
||||
/**
|
||||
* Plugin Name: Chapo
|
||||
* Description: Example block scaffolded with Create Block tool.
|
||||
* Version: 0.1.0
|
||||
* Requires at least: 6.7
|
||||
* Requires PHP: 7.4
|
||||
* Author: The WordPress Contributors
|
||||
* License: GPL-2.0-or-later
|
||||
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||
* Text Domain: chapo
|
||||
*
|
||||
* @package CreateBlock
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
/**
|
||||
* Registers the block using a `blocks-manifest.php` file, which improves the performance of block type registration.
|
||||
* Behind the scenes, it also registers all assets so they can be enqueued
|
||||
* through the block editor in the corresponding context.
|
||||
*
|
||||
* @see https://make.wordpress.org/core/2025/03/13/more-efficient-block-type-registration-in-6-8/
|
||||
* @see https://make.wordpress.org/core/2024/10/17/new-block-type-registration-apis-to-improve-performance-in-wordpress-6-7/
|
||||
*/
|
||||
function create_block_chapo_block_init() {
|
||||
/**
|
||||
* Registers the block(s) metadata from the `blocks-manifest.php` and registers the block type(s)
|
||||
* based on the registered block metadata.
|
||||
* Added in WordPress 6.8 to simplify the block metadata registration process added in WordPress 6.7.
|
||||
*
|
||||
* @see https://make.wordpress.org/core/2025/03/13/more-efficient-block-type-registration-in-6-8/
|
||||
*/
|
||||
if ( function_exists( 'wp_register_block_types_from_metadata_collection' ) ) {
|
||||
wp_register_block_types_from_metadata_collection( __DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php' );
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers the block(s) metadata from the `blocks-manifest.php` file.
|
||||
* Added to WordPress 6.7 to improve the performance of block type registration.
|
||||
*
|
||||
* @see https://make.wordpress.org/core/2024/10/17/new-block-type-registration-apis-to-improve-performance-in-wordpress-6-7/
|
||||
*/
|
||||
if ( function_exists( 'wp_register_block_metadata_collection' ) ) {
|
||||
wp_register_block_metadata_collection( __DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php' );
|
||||
}
|
||||
/**
|
||||
* Registers the block type(s) in the `blocks-manifest.php` file.
|
||||
*
|
||||
* @see https://developer.wordpress.org/reference/functions/register_block_type/
|
||||
*/
|
||||
$manifest_data = require __DIR__ . '/build/blocks-manifest.php';
|
||||
foreach ( array_keys( $manifest_data ) as $block_type ) {
|
||||
register_block_type( __DIR__ . "/build/{$block_type}" );
|
||||
}
|
||||
}
|
||||
add_action( 'init', 'create_block_chapo_block_init' );
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{
|
||||
"name": "chapo",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build --blocks-manifest",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start --blocks-manifest"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.26.0"
|
||||
},
|
||||
"packageManager": "pnpm@10.10.0+sha512.d615db246fe70f25dcfea6d8d73dee782ce23e2245e3c4f6f888249fb568149318637dca73c2c5c8ef2a4ca0d5657fb9567188bfab47f566d1ee6ce987815c39"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,55 +0,0 @@
|
|||
=== Chapo ===
|
||||
Contributors: The WordPress Contributors
|
||||
Tags: block
|
||||
Tested up to: 6.7
|
||||
Stable tag: 0.1.0
|
||||
License: GPL-2.0-or-later
|
||||
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||
|
||||
Example block scaffolded with Create Block tool.
|
||||
|
||||
== Description ==
|
||||
|
||||
This is the long description. No limit, and you can use Markdown (as well as in the following sections).
|
||||
|
||||
For backwards compatibility, if this section is missing, the full length of the short description will be used, and
|
||||
Markdown parsed.
|
||||
|
||||
== Installation ==
|
||||
|
||||
This section describes how to install the plugin and get it working.
|
||||
|
||||
e.g.
|
||||
|
||||
1. Upload the plugin files to the `/wp-content/plugins/chapo` directory, or install the plugin through the WordPress plugins screen directly.
|
||||
1. Activate the plugin through the 'Plugins' screen in WordPress
|
||||
|
||||
|
||||
== Frequently Asked Questions ==
|
||||
|
||||
= A question that someone might have =
|
||||
|
||||
An answer to that question.
|
||||
|
||||
= What about foo bar? =
|
||||
|
||||
Answer to foo bar dilemma.
|
||||
|
||||
== Screenshots ==
|
||||
|
||||
1. This screen shot description corresponds to screenshot-1.(png|jpg|jpeg|gif). Note that the screenshot is taken from
|
||||
the /assets directory or the directory that contains the stable readme.txt (tags or trunk). Screenshots in the /assets
|
||||
directory take precedence. For example, `/assets/screenshot-1.png` would win over `/tags/4.3/screenshot-1.png`
|
||||
(or jpg, jpeg, gif).
|
||||
2. This is the second screen shot
|
||||
|
||||
== Changelog ==
|
||||
|
||||
= 0.1.0 =
|
||||
* Release
|
||||
|
||||
== Arbitrary section ==
|
||||
|
||||
You may provide arbitrary sections, in the same format as the ones above. This may be of use for extremely complicated
|
||||
plugins where more information needs to be conveyed that doesn't fit into the categories of "description" or
|
||||
"installation." Arbitrary sections will be shown below the built-in sections outlined above.
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
@ -1,30 +0,0 @@
|
|||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Output of `npm pack`
|
||||
*.tgz
|
||||
|
||||
# Output of `wp-scripts plugin-zip`
|
||||
*.zip
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"index.css","mappings":";;;AAAA;EACC;AACD,C","sources":["webpack://portfolio-header/./src/editor.scss"],"sourcesContent":[".wp-block-carhop-blocks-chapter-section {\n\tmargin: 2rem calc(50% - 50vw);\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1,6 +0,0 @@
|
|||
/*!*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
|
||||
\*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
.wp-block-carhop-blocks-chapter-section {
|
||||
margin: 2rem calc(50% - 50vw);
|
||||
}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
/*!*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
|
||||
\*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
.wp-block-carhop-blocks-chapter-section {
|
||||
margin: 2rem calc(50% - 50vw);
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=style-index.css.map*/
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"./style-index.css","mappings":";;;AAAA;EACC;AACD,C","sources":["webpack://portfolio-header/./src/style.scss"],"sourcesContent":[".wp-block-carhop-blocks-chapter-section {\r\n\tmargin: 2rem calc(50% - 50vw);\r\n}\r\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '9618df91ea3d5989c295');
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
/******/ (() => { // webpackBootstrap
|
||||
/*!*********************!*\
|
||||
!*** ./src/view.js ***!
|
||||
\*********************/
|
||||
|
||||
/******/ })()
|
||||
;
|
||||
|
|
@ -1,25 +0,0 @@
|
|||
{
|
||||
"name": "portfolio-header",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.9.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@wordpress/icons": "^10.16.0",
|
||||
"postcss-nested-ancestors": "^3.0.0"
|
||||
},
|
||||
"packageManager": "pnpm@10.6.2+sha512.47870716bea1572b53df34ad8647b42962bc790ce2bf4562ba0f643237d7302a3d6a8ecef9e4bdfc01d23af1969aa90485d4cebb0b9638fa5ef1daef656f6c1b"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
|
||||
\*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
.content-box a {
|
||||
color: var(--content-box-text-color) !important;
|
||||
}
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
|
||||
\*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
.content-box a {
|
||||
color: var(--content-box-text-color) !important;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=index.css.map*/
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"index.css","mappings":";;;AACC;EACC;AAAF,C","sources":["webpack://front-header/./src/editor.scss"],"sourcesContent":[".content-box {\n\ta {\n\t\tcolor: var(--content-box-text-color) !important;\n\t}\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1,4 +0,0 @@
|
|||
/*!******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
|
||||
\******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
/*!******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
|
||||
\******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '9618df91ea3d5989c295');
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
/******/ (() => { // webpackBootstrap
|
||||
/*!*********************!*\
|
||||
!*** ./src/view.js ***!
|
||||
\*********************/
|
||||
|
||||
/******/ })()
|
||||
;
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{
|
||||
"name": "front-header",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.12.0"
|
||||
},
|
||||
"packageManager": "pnpm@9.11.0+sha512.0a203ffaed5a3f63242cd064c8fb5892366c103e328079318f78062f24ea8c9d50bc6a47aa3567cabefd824d170e78fa2745ed1f16b132e16436146b7688f19b"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
|
||||
\*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0_webpack-cli@5.1.4_/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
|
||||
\*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"./style-index.css","mappings":";;;AAAA;EACC;AACD;AACC;;;;;;EAMC;EACA;EACA;EACA;EACA;EACA;AACF;AACC;;EAEC;AACF;AAEC;EACC;EACA;EACA;EACA;AAAF,C","sources":["webpack://front-header/./src/style.scss"],"sourcesContent":[".content-card {\r\n\tword-break: break-word;\r\n\r\n\th1.wp-block-heading,\r\n\th2.wp-block-heading,\r\n\th3.wp-block-heading,\r\n\th4.wp-block-heading,\r\n\th5.wp-block-heading,\r\n\th6.wp-block-heading {\r\n\t\tmargin-top: 0;\r\n\t\tmargin-bottom: 0;\r\n\t\tfont-size: 1.25rem;\r\n\t\ttext-transform: uppercase;\r\n\t\tfont-weight: 700;\r\n\t\tcolor: var(--content-card-text-color);\r\n\t}\r\n\t*,\r\n\tp {\r\n\t\tcolor: var(--content-card-text-color);\r\n\t}\r\n\r\n\tli {\r\n\t\tlist-style: disc;\r\n\t\tmargin-left: 1rem;\r\n\t\tmargin-bottom: 0.5rem;\r\n\t\tfont-weight: 300;\r\n\t}\r\n}\r\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '9618df91ea3d5989c295');
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
/******/ (() => { // webpackBootstrap
|
||||
/*!*********************!*\
|
||||
!*** ./src/view.js ***!
|
||||
\*********************/
|
||||
|
||||
/******/ })()
|
||||
;
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{
|
||||
"name": "front-header",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.12.0"
|
||||
},
|
||||
"packageManager": "pnpm@9.11.0+sha512.0a203ffaed5a3f63242cd064c8fb5892366c103e328079318f78062f24ea8c9d50bc6a47aa3567cabefd824d170e78fa2745ed1f16b132e16436146b7688f19b"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Binary file not shown.
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
@ -1,30 +0,0 @@
|
|||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Output of `npm pack`
|
||||
*.tgz
|
||||
|
||||
# Output of `wp-scripts plugin-zip`
|
||||
*.zip
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
|
|
@ -1,31 +0,0 @@
|
|||
<?php
|
||||
// This file is generated. Do not modify it manually.
|
||||
return array(
|
||||
'build' => array(
|
||||
'$schema' => 'https://schemas.wp.org/trunk/block.json',
|
||||
'apiVersion' => 3,
|
||||
'name' => 'carhop-blocks/cta-group',
|
||||
'version' => '0.1.0',
|
||||
'title' => 'Groupe de CTA',
|
||||
'category' => 'carhop-blocks',
|
||||
'icon' => 'smiley',
|
||||
'description' => 'Pour intégrer Un groupe de call to action',
|
||||
'example' => array(
|
||||
|
||||
),
|
||||
'supports' => array(
|
||||
'html' => false
|
||||
),
|
||||
'textdomain' => 'carhop-blocks',
|
||||
'editorScript' => 'file:./index.js',
|
||||
'editorStyle' => 'file:./index.css',
|
||||
'style' => 'file:./style-index.css',
|
||||
'viewScript' => 'file:./view.js',
|
||||
'attributes' => array(
|
||||
'align' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'left'
|
||||
)
|
||||
)
|
||||
)
|
||||
);
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-i18n'), 'version' => 'b2933cd3d9b6b2982428');
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"index.css","mappings":";;;AAAA;EACC;EAEA;EACA;EACA;EAAA;EACA;EACA;EACA;EACA;AAAD;AAGE;EACC;EACA;AADH;AAGE;;EAEC;AADH;AAKC;EACC;AAHF;AAKC;EACC;EACA;AAHF;AAKC;EACC;AAHF,C","sources":["webpack://cta/./src/editor.scss"],"sourcesContent":[".wp-block-carhop-blocks-cta {\n\tcolor: var(--cta-current-color);\n\n\tpadding: 2px;\n\tdisplay: block;\n\twidth: fit-content;\n\tdisplay: flex;\n\talign-items: center;\n\tgap: 10px;\n\tline-height: normal;\n\n\t.icon {\n\t\tsvg {\n\t\t\twidth: 30px;\n\t\t\theight: 30px;\n\t\t}\n\t\tsvg path,\n\t\tsvg circle {\n\t\t\tstroke: var(--cta-current-color);\n\t\t}\n\t}\n\n\t&.align--left {\n\t\tmargin-left: 0;\n\t}\n\t&.align--right {\n\t\tmargin-right: 0;\n\t\tmargin-left: auto;\n\t}\n\t&.align--center {\n\t\tmargin: 0 auto;\n\t}\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1,19 +0,0 @@
|
|||
/*!***************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
|
||||
\***************************************************************************************************************************************************************************************************************************************/
|
||||
.cta-group {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
gap: 2rem;
|
||||
}
|
||||
.cta-group--align-left {
|
||||
justify-content: flex-start;
|
||||
}
|
||||
.cta-group--align-center {
|
||||
justify-content: center;
|
||||
}
|
||||
.cta-group--align-right {
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
/*!***************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/style.scss ***!
|
||||
\***************************************************************************************************************************************************************************************************************************************/
|
||||
.cta-group {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
gap: 2rem;
|
||||
}
|
||||
.cta-group--align-left {
|
||||
justify-content: flex-start;
|
||||
}
|
||||
.cta-group--align-center {
|
||||
justify-content: center;
|
||||
}
|
||||
.cta-group--align-right {
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=style-index.css.map*/
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"./style-index.css","mappings":";;;AAAA;EACC;EACA;EACA;EACA;EACA;AACD;AACC;EACC;AACF;AAEC;EACC;AAAF;AAGC;EACC;AADF,C","sources":["webpack://cta/./src/style.scss"],"sourcesContent":[".cta-group {\n\tdisplay: flex;\n\tflex-wrap: wrap;\n\tjustify-content: center;\n\talign-items: center;\n\tgap: 2rem;\n\n\t&--align-left {\n\t\tjustify-content: flex-start;\n\t}\n\n\t&--align-center {\n\t\tjustify-content: center;\n\t}\n\n\t&--align-right {\n\t\tjustify-content: flex-end;\n\t}\n}\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '9618df91ea3d5989c295');
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
/******/ (() => { // webpackBootstrap
|
||||
/*!*********************!*\
|
||||
!*** ./src/view.js ***!
|
||||
\*********************/
|
||||
|
||||
/******/ })()
|
||||
;
|
||||
|
|
@ -1,39 +0,0 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* Plugin Name: Cta
|
||||
* Description: Example block scaffolded with Create Block tool.
|
||||
* Version: 0.1.0
|
||||
* Requires at least: 6.7
|
||||
* Requires PHP: 7.4
|
||||
* Author: The WordPress Contributors
|
||||
* License: GPL-2.0-or-later
|
||||
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||
* Text Domain: cta
|
||||
*
|
||||
* @package CreateBlock
|
||||
*/
|
||||
|
||||
if (! defined('ABSPATH')) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
|
||||
function create_block_cta_block_init()
|
||||
{
|
||||
|
||||
if (function_exists('wp_register_block_types_from_metadata_collection')) {
|
||||
wp_register_block_types_from_metadata_collection(__DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php');
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (function_exists('wp_register_block_metadata_collection')) {
|
||||
wp_register_block_metadata_collection(__DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php');
|
||||
}
|
||||
|
||||
$manifest_data = require __DIR__ . '/build/blocks-manifest.php';
|
||||
foreach (array_keys($manifest_data) as $block_type) {
|
||||
register_block_type(__DIR__ . "/build");
|
||||
}
|
||||
}
|
||||
add_action('init', 'create_block_cta_block_init');
|
||||
20255
plugins/carhop-blocks/blocks/cta-group/package-lock.json
generated
20255
plugins/carhop-blocks/blocks/cta-group/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -1,55 +0,0 @@
|
|||
=== Cta ===
|
||||
Contributors: The WordPress Contributors
|
||||
Tags: block
|
||||
Tested up to: 6.7
|
||||
Stable tag: 0.1.0
|
||||
License: GPL-2.0-or-later
|
||||
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||
|
||||
Example block scaffolded with Create Block tool.
|
||||
|
||||
== Description ==
|
||||
|
||||
This is the long description. No limit, and you can use Markdown (as well as in the following sections).
|
||||
|
||||
For backwards compatibility, if this section is missing, the full length of the short description will be used, and
|
||||
Markdown parsed.
|
||||
|
||||
== Installation ==
|
||||
|
||||
This section describes how to install the plugin and get it working.
|
||||
|
||||
e.g.
|
||||
|
||||
1. Upload the plugin files to the `/wp-content/plugins/cta` directory, or install the plugin through the WordPress plugins screen directly.
|
||||
1. Activate the plugin through the 'Plugins' screen in WordPress
|
||||
|
||||
|
||||
== Frequently Asked Questions ==
|
||||
|
||||
= A question that someone might have =
|
||||
|
||||
An answer to that question.
|
||||
|
||||
= What about foo bar? =
|
||||
|
||||
Answer to foo bar dilemma.
|
||||
|
||||
== Screenshots ==
|
||||
|
||||
1. This screen shot description corresponds to screenshot-1.(png|jpg|jpeg|gif). Note that the screenshot is taken from
|
||||
the /assets directory or the directory that contains the stable readme.txt (tags or trunk). Screenshots in the /assets
|
||||
directory take precedence. For example, `/assets/screenshot-1.png` would win over `/tags/4.3/screenshot-1.png`
|
||||
(or jpg, jpeg, gif).
|
||||
2. This is the second screen shot
|
||||
|
||||
== Changelog ==
|
||||
|
||||
= 0.1.0 =
|
||||
* Release
|
||||
|
||||
== Arbitrary section ==
|
||||
|
||||
You may provide arbitrary sections, in the same format as the ones above. This may be of use for extremely complicated
|
||||
plugins where more information needs to be conveyed that doesn't fit into the categories of "description" or
|
||||
"installation." Arbitrary sections will be shown below the built-in sections outlined above.
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
30
plugins/carhop-blocks/blocks/cta/.gitignore
vendored
30
plugins/carhop-blocks/blocks/cta/.gitignore
vendored
|
|
@ -1,30 +0,0 @@
|
|||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Output of `npm pack`
|
||||
*.tgz
|
||||
|
||||
# Output of `wp-scripts plugin-zip`
|
||||
*.zip
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
<?php
|
||||
// This file is generated. Do not modify it manually.
|
||||
return array(
|
||||
'cta' => array(
|
||||
'$schema' => 'https://schemas.wp.org/trunk/block.json',
|
||||
'apiVersion' => 3,
|
||||
'name' => 'carhop-blocks/cta',
|
||||
'version' => '0.1.0',
|
||||
'title' => 'Cta',
|
||||
'category' => 'carhop-blocks',
|
||||
'icon' => 'smiley',
|
||||
'description' => 'Un bouton de lien',
|
||||
'example' => array(
|
||||
|
||||
),
|
||||
'supports' => array(
|
||||
'html' => false
|
||||
),
|
||||
'textdomain' => 'carhop-blocks',
|
||||
'editorScript' => 'file:./index.js',
|
||||
'editorStyle' => 'file:./index.css',
|
||||
'style' => 'file:./style-index.css',
|
||||
'viewScript' => 'file:./view.js',
|
||||
'render' => 'file:./render.php',
|
||||
'attributes' => array(
|
||||
'text' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'Call to action'
|
||||
),
|
||||
'link' => array(
|
||||
'type' => 'object'
|
||||
),
|
||||
'align' => array(
|
||||
'type' => 'string',
|
||||
'default' => 'left'
|
||||
),
|
||||
'color' => array(
|
||||
'type' => 'string',
|
||||
'default' => null
|
||||
)
|
||||
)
|
||||
)
|
||||
);
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"cta/index.css","mappings":";;;AAAA;EACC;EAMA;EACA;EACA;EAAA;EACA;EACA;EACA;EACA;AAJD;AAPC;EACC;AASF;AAIE;EACC;EACA;AAFH;AAIE;;EAEC;AAFH;AAMC;EACC;AAJF;AAMC;EACC;EACA;AAJF;AAMC;EACC;AAJF,C","sources":["webpack://cta/./src/cta/editor.scss"],"sourcesContent":[".wp-block-carhop-blocks-cta {\n\tcolor: var(--cta-current-color);\n\ta {\n\t\tcolor: var(--cta-current-color) !important;\n\n\t\t&:after{}\n\t}\n\tpadding: 2px;\n\tdisplay: block;\n\twidth: fit-content;\n\tdisplay: flex;\n\talign-items: center;\n\tgap: 10px;\n\tline-height: normal;\n\n\t.icon {\n\t\tsvg {\n\t\t\twidth: 30px;\n\t\t\theight: 30px;\n\t\t}\n\t\tsvg path,\n\t\tsvg circle {\n\t\t\tstroke: var(--cta-current-color);\n\t\t}\n\t}\n\n\t&.align--left {\n\t\tmargin-left: 0;\n\t}\n\t&.align--right {\n\t\tmargin-right: 0;\n\t\tmargin-left: auto;\n\t}\n\t&.align--center {\n\t\tmargin: 0 auto;\n\t}\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"cta/style-index.css","mappings":";;;AAAA;EACC;EACA;EAEA;EACA;EACA;EAAA;EACA;EACA;EACA;EACA;EAEA;AADD;AAGC;EACC;AADF;AAIE;EACC;EACA;AAFH;AAIE;;EAEC;EACA;EACA;AAFH;AAMC;EACC;AAJF;AAMC;EACC;EACA;AAJF;AAMC;EACC;AAJF,C","sources":["webpack://cta/./src/cta/style.scss"],"sourcesContent":[".wp-block-carhop-blocks-cta {\n\tmargin-top: 20px;\n\tcolor: var(--cta-current-color, currentColor);\n\n\tpadding: 2px;\n\tdisplay: block;\n\twidth: fit-content;\n\tdisplay: flex;\n\talign-items: center;\n\tgap: 10px;\n\tline-height: normal;\n\n\tfont-weight: 600;\n\n\ta {\n\t\ttext-decoration: none;\n\t}\n\t.icon {\n\t\tsvg {\n\t\t\twidth: 30px;\n\t\t\theight: 30px;\n\t\t}\n\t\tsvg path,\n\t\tsvg circle {\n\t\t\tfill: transparent;\n\t\t\tstroke: var(--cta-current-color);\n\t\t\tstroke-width: 2;\n\t\t}\n\t}\n\n\t&.align--left {\n\t\tmargin-left: 0;\n\t}\n\t&.align--right {\n\t\tmargin-right: 0;\n\t\tmargin-left: auto;\n\t}\n\t&.align--center {\n\t\tmargin: 0 auto;\n\t}\n}\n"],"names":[],"sourceRoot":""}
|
||||
|
|
@ -1,37 +0,0 @@
|
|||
<?php
|
||||
/**
|
||||
* Plugin Name: Cta
|
||||
* Description: Example block scaffolded with Create Block tool.
|
||||
* Version: 0.1.0
|
||||
* Requires at least: 6.7
|
||||
* Requires PHP: 7.4
|
||||
* Author: The WordPress Contributors
|
||||
* License: GPL-2.0-or-later
|
||||
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||
* Text Domain: cta
|
||||
*
|
||||
* @package CreateBlock
|
||||
*/
|
||||
|
||||
if ( ! defined( 'ABSPATH' ) ) {
|
||||
exit; // Exit if accessed directly.
|
||||
}
|
||||
|
||||
function create_block_cta_block_init() {
|
||||
|
||||
if ( function_exists( 'wp_register_block_types_from_metadata_collection' ) ) {
|
||||
wp_register_block_types_from_metadata_collection( __DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php' );
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if ( function_exists( 'wp_register_block_metadata_collection' ) ) {
|
||||
wp_register_block_metadata_collection( __DIR__ . '/build', __DIR__ . '/build/blocks-manifest.php' );
|
||||
}
|
||||
|
||||
$manifest_data = require __DIR__ . '/build/blocks-manifest.php';
|
||||
foreach ( array_keys( $manifest_data ) as $block_type ) {
|
||||
register_block_type( __DIR__ . "/build/{$block_type}" );
|
||||
}
|
||||
}
|
||||
add_action( 'init', 'create_block_cta_block_init' );
|
||||
20255
plugins/carhop-blocks/blocks/cta/package-lock.json
generated
20255
plugins/carhop-blocks/blocks/cta/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
|
|
@ -1,24 +0,0 @@
|
|||
{
|
||||
"name": "cta",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build --blocks-manifest",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start --blocks-manifest"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.15.0"
|
||||
},
|
||||
"packageManager": "pnpm@10.10.0+sha512.d615db246fe70f25dcfea6d8d73dee782ce23e2245e3c4f6f888249fb568149318637dca73c2c5c8ef2a4ca0d5657fb9567188bfab47f566d1ee6ce987815c39",
|
||||
"dependencies": {
|
||||
"url-loader": "^4.1.1"
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,18 +0,0 @@
|
|||
# This file is for unifying the coding style for different editors and IDEs
|
||||
# editorconfig.org
|
||||
|
||||
# WordPress Coding Standards
|
||||
# https://make.wordpress.org/core/handbook/coding-standards/
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
trim_trailing_whitespace = true
|
||||
indent_style = tab
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
||||
|
|
@ -1,30 +0,0 @@
|
|||
# Logs
|
||||
logs
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Coverage directory used by tools like istanbul
|
||||
coverage
|
||||
|
||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
||||
build/Release
|
||||
|
||||
# Dependency directories
|
||||
node_modules/
|
||||
|
||||
# Optional npm cache directory
|
||||
.npm
|
||||
|
||||
# Optional eslint cache
|
||||
.eslintcache
|
||||
|
||||
# Output of `npm pack`
|
||||
*.tgz
|
||||
|
||||
# Output of `wp-scripts plugin-zip`
|
||||
*.zip
|
||||
|
||||
# dotenv environment variables file
|
||||
.env
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
/*!**********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
|
||||
\**********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
/**
|
||||
* The following styles get applied inside the editor only.
|
||||
*
|
||||
* Replace them with your own styles or remove the file completely.
|
||||
*/
|
||||
.wp-block-carhop-plugin-latest-news {
|
||||
border: 1px dotted #f00;
|
||||
}
|
||||
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-i18n'), 'version' => '6993245e9ec9cd7430a2');
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
/*!**********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
|
||||
!*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.98.0/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[4].use[1]!./node_modules/.pnpm/postcss-loader@6.2.1_postcss@8.5.3_webpack@5.98.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.5_sass@1.85.1_webpack@5.98.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/editor.scss ***!
|
||||
\**********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
|
||||
/**
|
||||
* The following styles get applied inside the editor only.
|
||||
*
|
||||
* Replace them with your own styles or remove the file completely.
|
||||
*/
|
||||
.wp-block-carhop-plugin-latest-news {
|
||||
border: 1px dotted #f00;
|
||||
}
|
||||
|
||||
/*# sourceMappingURL=index.css.map*/
|
||||
|
|
@ -1 +0,0 @@
|
|||
{"version":3,"file":"index.css","mappings":";;;AAAA;;;;EAAA;AAMA;EACC;AAAD,C","sources":["webpack://dbmob-grid/./src/editor.scss"],"sourcesContent":["/**\n * The following styles get applied inside the editor only.\n *\n * Replace them with your own styles or remove the file completely.\n */\n\n.wp-block-carhop-plugin-latest-news {\n\tborder: 1px dotted #f00;\n}\n"],"names":[],"sourceRoot":""}
|
||||
File diff suppressed because one or more lines are too long
|
|
@ -1 +0,0 @@
|
|||
<?php return array('dependencies' => array(), 'version' => '9618df91ea3d5989c295');
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
/******/ (() => { // webpackBootstrap
|
||||
/*!*********************!*\
|
||||
!*** ./src/view.js ***!
|
||||
\*********************/
|
||||
|
||||
/******/ })()
|
||||
;
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{
|
||||
"name": "dbmob-grid",
|
||||
"version": "0.1.0",
|
||||
"description": "Example block scaffolded with Create Block tool.",
|
||||
"author": "The WordPress Contributors",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
"build": "wp-scripts build --webpack-copy-php",
|
||||
"format": "wp-scripts format",
|
||||
"lint:css": "wp-scripts lint-style",
|
||||
"lint:js": "wp-scripts lint-js",
|
||||
"packages-update": "wp-scripts packages-update",
|
||||
"plugin-zip": "wp-scripts plugin-zip",
|
||||
"start": "wp-scripts start --webpack-copy-php"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@wordpress/scripts": "^30.12.0"
|
||||
},
|
||||
"packageManager": "pnpm@10.6.2+sha512.47870716bea1572b53df34ad8647b42962bc790ce2bf4562ba0f643237d7302a3d6a8ecef9e4bdfc01d23af1969aa90485d4cebb0b9638fa5ef1daef656f6c1b"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user