From 6b1a2ba54e8613b5b0fcffbde71c89660e417a39 Mon Sep 17 00:00:00 2001 From: Antoine M Date: Thu, 4 Dec 2025 16:55:11 +0100 Subject: [PATCH] rebuilding --- .../carhop-blocks/build/blocks-manifest.php | 266 +++++++- .../build/chapter-section/index.asset.php | 2 +- .../build/chapter-section/index.js | 4 +- .../build/chapter-section/index.js.map | 2 +- .../build/company-timeline/block.json | 71 +++ .../build/company-timeline/index-rtl.css | 28 + .../build/company-timeline/index.asset.php | 1 + .../build/company-timeline/index.css | 30 + .../build/company-timeline/index.css.map | 1 + .../build/company-timeline/index.js | 603 ++++++++++++++++++ .../build/company-timeline/index.js.map | 1 + .../company-timeline/style-index-rtl.css | 172 +++++ .../build/company-timeline/style-index.css | 174 +++++ .../company-timeline/style-index.css.map | 1 + .../build/company-timeline/view.asset.php | 1 + .../build/company-timeline/view.js | 68 ++ .../build/company-timeline/view.js.map | 1 + .../build/content-box/index.asset.php | 2 +- .../carhop-blocks/build/content-box/index.js | 4 +- .../build/content-box/index.js.map | 2 +- .../build/heading/index.asset.php | 2 +- plugins/carhop-blocks/build/heading/index.js | 12 +- .../carhop-blocks/build/heading/index.js.map | 2 +- .../build/highlight-timeline-step/block.json | 28 + .../highlight-timeline-step/index-rtl.css | 4 + .../highlight-timeline-step/index.asset.php | 1 + .../build/highlight-timeline-step/index.css | 4 + .../build/highlight-timeline-step/index.js | 464 ++++++++++++++ .../highlight-timeline-step/index.js.map | 1 + .../style-index-rtl.css | 33 + .../highlight-timeline-step/style-index.css | 35 + .../style-index.css.map | 1 + .../highlight-timeline-step/view.asset.php | 1 + .../build/highlight-timeline-step/view.js | 7 + .../build/highlight-timeline/block.json | 20 + .../build/highlight-timeline/index-rtl.css | 4 + .../build/highlight-timeline/index.asset.php | 1 + .../build/highlight-timeline/index.css | 4 + .../build/highlight-timeline/index.js | 374 +++++++++++ .../build/highlight-timeline/index.js.map | 1 + .../build/highlight-timeline/render.php | 33 + .../highlight-timeline/style-index-rtl.css | 15 + .../build/highlight-timeline/style-index.css | 17 + .../highlight-timeline/style-index.css.map | 1 + .../build/highlight-timeline/view.asset.php | 1 + .../build/highlight-timeline/view.js | 62 ++ .../build/highlight-timeline/view.js.map | 1 + .../build/image-stack/block.json | 65 ++ .../build/image-stack/index-rtl.css | 51 ++ .../build/image-stack/index.asset.php | 1 + .../carhop-blocks/build/image-stack/index.css | 53 ++ .../build/image-stack/index.css.map | 1 + .../carhop-blocks/build/image-stack/index.js | 602 +++++++++++++++++ .../build/image-stack/index.js.map | 1 + .../build/image-stack/style-index-rtl.css | 22 + .../build/image-stack/style-index.css | 24 + .../build/image-stack/style-index.css.map | 1 + .../build/narrative-card/block.json | 16 + .../build/narrative-card/index.asset.php | 2 +- .../build/narrative-card/index.js | 60 +- .../build/narrative-card/index.js.map | 2 +- .../build/scroll-story-block/block.json | 8 +- .../build/scroll-story-block/index.asset.php | 2 +- .../build/scroll-story-block/index.js | 50 +- .../build/scroll-story-block/index.js.map | 2 +- .../build/story-timeline-step/block.json | 28 + .../build/story-timeline-step/index-rtl.css | 4 + .../build/story-timeline-step/index.asset.php | 1 + .../build/story-timeline-step/index.css | 4 + .../build/story-timeline-step/index.js | 408 ++++++++++++ .../build/story-timeline-step/index.js.map | 1 + .../story-timeline-step/style-index-rtl.css | 4 + .../build/story-timeline-step/style-index.css | 4 + .../build/story-timeline-step/view.asset.php | 1 + .../build/story-timeline-step/view.js | 7 + .../build/story-timeline/block.json | 20 + .../build/story-timeline/index-rtl.css | 4 + .../build/story-timeline/index.asset.php | 1 + .../build/story-timeline/index.css | 4 + .../build/story-timeline/index.js | 385 +++++++++++ .../build/story-timeline/index.js.map | 1 + .../build/story-timeline/render.php | 28 + .../build/story-timeline/style-index-rtl.css | 4 + .../build/story-timeline/style-index.css | 4 + .../build/story-timeline/view.asset.php | 1 + .../build/story-timeline/view.js | 58 ++ .../build/story-timeline/view.js.map | 1 + 87 files changed, 4460 insertions(+), 39 deletions(-) create mode 100644 plugins/carhop-blocks/build/company-timeline/block.json create mode 100644 plugins/carhop-blocks/build/company-timeline/index-rtl.css create mode 100644 plugins/carhop-blocks/build/company-timeline/index.asset.php create mode 100644 plugins/carhop-blocks/build/company-timeline/index.css create mode 100644 plugins/carhop-blocks/build/company-timeline/index.css.map create mode 100644 plugins/carhop-blocks/build/company-timeline/index.js create mode 100644 plugins/carhop-blocks/build/company-timeline/index.js.map create mode 100644 plugins/carhop-blocks/build/company-timeline/style-index-rtl.css create mode 100644 plugins/carhop-blocks/build/company-timeline/style-index.css create mode 100644 plugins/carhop-blocks/build/company-timeline/style-index.css.map create mode 100644 plugins/carhop-blocks/build/company-timeline/view.asset.php create mode 100644 plugins/carhop-blocks/build/company-timeline/view.js create mode 100644 plugins/carhop-blocks/build/company-timeline/view.js.map create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/block.json create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/index-rtl.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/index.asset.php create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/index.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/index.js create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/index.js.map create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/style-index-rtl.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/style-index.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/style-index.css.map create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/view.asset.php create mode 100644 plugins/carhop-blocks/build/highlight-timeline-step/view.js create mode 100644 plugins/carhop-blocks/build/highlight-timeline/block.json create mode 100644 plugins/carhop-blocks/build/highlight-timeline/index-rtl.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline/index.asset.php create mode 100644 plugins/carhop-blocks/build/highlight-timeline/index.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline/index.js create mode 100644 plugins/carhop-blocks/build/highlight-timeline/index.js.map create mode 100644 plugins/carhop-blocks/build/highlight-timeline/render.php create mode 100644 plugins/carhop-blocks/build/highlight-timeline/style-index-rtl.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline/style-index.css create mode 100644 plugins/carhop-blocks/build/highlight-timeline/style-index.css.map create mode 100644 plugins/carhop-blocks/build/highlight-timeline/view.asset.php create mode 100644 plugins/carhop-blocks/build/highlight-timeline/view.js create mode 100644 plugins/carhop-blocks/build/highlight-timeline/view.js.map create mode 100644 plugins/carhop-blocks/build/image-stack/block.json create mode 100644 plugins/carhop-blocks/build/image-stack/index-rtl.css create mode 100644 plugins/carhop-blocks/build/image-stack/index.asset.php create mode 100644 plugins/carhop-blocks/build/image-stack/index.css create mode 100644 plugins/carhop-blocks/build/image-stack/index.css.map create mode 100644 plugins/carhop-blocks/build/image-stack/index.js create mode 100644 plugins/carhop-blocks/build/image-stack/index.js.map create mode 100644 plugins/carhop-blocks/build/image-stack/style-index-rtl.css create mode 100644 plugins/carhop-blocks/build/image-stack/style-index.css create mode 100644 plugins/carhop-blocks/build/image-stack/style-index.css.map create mode 100644 plugins/carhop-blocks/build/story-timeline-step/block.json create mode 100644 plugins/carhop-blocks/build/story-timeline-step/index-rtl.css create mode 100644 plugins/carhop-blocks/build/story-timeline-step/index.asset.php create mode 100644 plugins/carhop-blocks/build/story-timeline-step/index.css create mode 100644 plugins/carhop-blocks/build/story-timeline-step/index.js create mode 100644 plugins/carhop-blocks/build/story-timeline-step/index.js.map create mode 100644 plugins/carhop-blocks/build/story-timeline-step/style-index-rtl.css create mode 100644 plugins/carhop-blocks/build/story-timeline-step/style-index.css create mode 100644 plugins/carhop-blocks/build/story-timeline-step/view.asset.php create mode 100644 plugins/carhop-blocks/build/story-timeline-step/view.js create mode 100644 plugins/carhop-blocks/build/story-timeline/block.json create mode 100644 plugins/carhop-blocks/build/story-timeline/index-rtl.css create mode 100644 plugins/carhop-blocks/build/story-timeline/index.asset.php create mode 100644 plugins/carhop-blocks/build/story-timeline/index.css create mode 100644 plugins/carhop-blocks/build/story-timeline/index.js create mode 100644 plugins/carhop-blocks/build/story-timeline/index.js.map create mode 100644 plugins/carhop-blocks/build/story-timeline/render.php create mode 100644 plugins/carhop-blocks/build/story-timeline/style-index-rtl.css create mode 100644 plugins/carhop-blocks/build/story-timeline/style-index.css create mode 100644 plugins/carhop-blocks/build/story-timeline/view.asset.php create mode 100644 plugins/carhop-blocks/build/story-timeline/view.js create mode 100644 plugins/carhop-blocks/build/story-timeline/view.js.map diff --git a/plugins/carhop-blocks/build/blocks-manifest.php b/plugins/carhop-blocks/build/blocks-manifest.php index e363344..653da7b 100644 --- a/plugins/carhop-blocks/build/blocks-manifest.php +++ b/plugins/carhop-blocks/build/blocks-manifest.php @@ -242,6 +242,77 @@ return array( 'postId' ) ), + 'company-timeline' => array( + '$schema' => 'https://schemas.wp.org/trunk/block.json', + 'apiVersion' => 3, + 'name' => 'telex/block-company-timeline', + 'version' => '0.1.0', + 'title' => 'Company Timeline', + 'category' => 'design', + 'icon' => 'calendar-alt', + 'description' => 'Display company milestones with a fixed sidebar navigation and scroll-based highlighting', + 'keywords' => array( + 'timeline', + 'history', + 'milestones', + 'chronology', + 'events' + ), + 'attributes' => array( + 'entries' => array( + 'type' => 'array', + 'default' => array( + array( + 'year' => '2020', + 'title' => 'Company Founded', + 'description' => 'Our journey began with a vision to make a difference.', + 'imageUrl' => '', + 'imageId' => 0 + ) + ) + ) + ), + 'example' => array( + 'attributes' => array( + 'entries' => array( + array( + 'year' => '2010', + 'title' => 'The Beginning', + 'description' => 'Founded with a mission to innovate.', + 'imageUrl' => '', + 'imageId' => 0 + ), + array( + 'year' => '2015', + 'title' => 'Major Milestone', + 'description' => 'Reached 1 million customers worldwide.', + 'imageUrl' => '', + 'imageId' => 0 + ), + array( + 'year' => '2020', + 'title' => 'Global Expansion', + 'description' => 'Opened offices in 25 countries.', + 'imageUrl' => '', + 'imageId' => 0 + ) + ) + ) + ), + 'supports' => array( + 'html' => false, + 'anchor' => true, + 'align' => array( + 'wide', + 'full' + ) + ), + 'textdomain' => 'company-timeline', + 'editorScript' => 'file:./index.js', + 'editorStyle' => 'file:./index.css', + 'style' => 'file:./style-index.css', + 'viewScript' => 'file:./view.js' + ), 'content-box' => array( '$schema' => 'https://schemas.wp.org/trunk/block.json', 'apiVersion' => 3, @@ -528,6 +599,125 @@ return array( ) ) ), + 'highlight-timeline' => array( + '$schema' => 'https://schemas.wp.org/trunk/block.json', + 'apiVersion' => 3, + 'name' => 'carhop-blocks/highlight-timeline', + 'version' => '0.1.0', + 'title' => 'Highlight Timeline', + 'category' => 'carhop-blocks', + 'icon' => 'smiley', + 'description' => 'Highlight Timeline pour la mise en forme d\'une timeline avec des éléments en surbrillance', + 'example' => array( + + ), + 'supports' => array( + 'html' => false + ), + 'textdomain' => 'highlight-timeline', + 'editorScript' => 'file:./index.js', + 'editorStyle' => 'file:./index.css', + 'style' => 'file:./style-index.css', + 'viewScript' => 'file:./view.js', + 'render' => 'file:./render.php' + ), + 'highlight-timeline-step' => array( + '$schema' => 'https://schemas.wp.org/trunk/block.json', + 'apiVersion' => 3, + 'name' => 'carhop-blocks/highlight-timeline-step', + 'version' => '0.1.0', + 'title' => 'Étape de timeline', + 'category' => 'carhop-blocks', + 'icon' => 'calendar', + 'description' => 'Étape de timeline pour la mise en forme d\'une étape de timeline', + 'example' => array( + + ), + 'parent' => array( + 'carhop-blocks/highlight-timeline' + ), + '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( + 'year' => array( + 'type' => 'number', + 'default' => 2025 + ) + ) + ), + 'image-stack' => array( + '$schema' => 'https://schemas.wp.org/trunk/block.json', + 'apiVersion' => 3, + 'name' => 'carhop-blocks/image-stack', + 'version' => '0.1.0', + 'title' => 'Image Stack (Focal Point)', + 'category' => 'carhop-blocks', + 'icon' => 'images-alt2', + 'description' => 'Layer multiple images with individual focal point positioning.', + 'example' => array( + 'attributes' => array( + 'images' => array( + array( + 'id' => 1, + 'url' => 'https://images.unsplash.com/photo-1506905925346-21bda4d32df4', + 'alt' => 'Mountain landscape', + 'focalPoint' => array( + 'x' => 0.5, + 'y' => 0.3 + ), + 'scale' => 0.8 + ), + array( + 'id' => 2, + 'url' => 'https://images.unsplash.com/photo-1511884642898-4c92249e20b6', + 'alt' => 'Forest scene', + 'focalPoint' => array( + 'x' => 0.7, + 'y' => 0.6 + ), + 'scale' => 0.6 + ) + ), + 'height' => 400 + ) + ), + 'attributes' => array( + 'images' => array( + 'type' => 'array', + 'default' => array( + + ), + 'items' => array( + 'type' => 'object' + ) + ), + 'height' => array( + 'type' => 'number', + 'default' => 400 + ) + ), + 'supports' => array( + 'html' => false, + 'align' => array( + 'wide', + 'full' + ), + 'spacing' => array( + 'margin' => true, + 'padding' => true + ) + ), + 'textdomain' => 'image-stack', + 'editorScript' => 'file:./index.js', + 'editorStyle' => 'file:./index.css', + 'style' => 'file:./style-index.css' + ), 'latest-news' => array( '$schema' => 'https://schemas.wp.org/trunk/block.json', 'apiVersion' => 3, @@ -597,6 +787,22 @@ return array( 'type' => 'boolean', 'default' => true ), + 'aspectRatio' => array( + 'type' => 'string', + 'default' => 'auto', + 'enum' => array( + 'auto', + '1/1', + '4/3', + '3/4', + '3/2', + '2/3', + '16/9', + '21/9', + '9/16', + '9/21' + ) + ), 'coverPosition' => array( 'type' => 'string', 'default' => 'right', @@ -712,7 +918,65 @@ return array( 'editorScript' => 'file:./index.js', 'editorStyle' => 'file:./index.css', 'style' => 'file:./style-index.css', - 'viewScript' => 'file:./view.js' + 'viewScript' => 'file:./view.js', + 'attributes' => array( + 'hasNumbering' => array( + 'type' => 'boolean', + 'default' => false + ) + ) + ), + 'story-timeline' => array( + '$schema' => 'https://schemas.wp.org/trunk/block.json', + 'apiVersion' => 3, + 'name' => 'carhop-blocks/story-timeline', + 'version' => '0.1.0', + 'title' => 'Timeline', + 'category' => 'carhop-blocks', + 'icon' => 'calendar-alt', + 'description' => 'Boite de timeline pour la mise en forme d\'une timeline', + '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' + ), + 'story-timeline-step' => array( + '$schema' => 'https://schemas.wp.org/trunk/block.json', + 'apiVersion' => 3, + 'name' => 'carhop-blocks/story-timeline-step', + 'version' => '0.1.0', + 'title' => 'Étape de timeline', + 'category' => 'carhop-blocks', + 'icon' => 'calendar', + 'description' => 'Étape de timeline pour la mise en forme d\'une étape de timeline', + 'example' => array( + + ), + 'parent' => array( + 'carhop-blocks/story-timeline' + ), + '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( + 'year' => array( + 'type' => 'number', + 'default' => 2025 + ) + ) ), 'subscribe-infolettre' => array( '$schema' => 'https://schemas.wp.org/trunk/block.json', diff --git a/plugins/carhop-blocks/build/chapter-section/index.asset.php b/plugins/carhop-blocks/build/chapter-section/index.asset.php index e97b63f..dd2df70 100644 --- a/plugins/carhop-blocks/build/chapter-section/index.asset.php +++ b/plugins/carhop-blocks/build/chapter-section/index.asset.php @@ -1 +1 @@ - array('react', 'react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n', 'wp-primitives'), 'version' => '20310519f99c6d7fbfc4'); + array('react', 'react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n', 'wp-primitives'), 'version' => 'e29ac5fb21b7bc27f5c0'); diff --git a/plugins/carhop-blocks/build/chapter-section/index.js b/plugins/carhop-blocks/build/chapter-section/index.js index 15f997c..364ab46 100644 --- a/plugins/carhop-blocks/build/chapter-section/index.js +++ b/plugins/carhop-blocks/build/chapter-section/index.js @@ -390,7 +390,7 @@ function Edit({ placeholder: "Chapter Title", content: "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse augue augue, sagittis quis mauris in, consequat vehicula est. Aliquam quis nulla ante. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras bibendum eget lorem eget aliquet. Fusce vel consequat neque. " }]], - allowedBlocks: ["core/heading", "core/paragraph", "core/list", "core/button", "core/buttons", "carhop-blocks/cta", "carhop-blocks/heading"] + allowedBlocks: ["core/heading", "core/paragraph", "core/list", "core/button", "core/buttons", "carhop-blocks/heading", "carhop-blocks/cta", "carhop-blocks/cta-group"] }) }) }), coverUrl && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_8__.jsx)("img", { @@ -502,7 +502,7 @@ function save({ className: `deligraph-blocks-chapter-section chapter-section chapter-section--${disposition} chapter-section--${blockVariant} ${blockWidth === "full" ? "chapter-section--width-full" : "chapter-section--width-contained"} - ${hasLightBackground ? "chapter-section--bg-light" : "chapter-section--bg-dark"}`, + ${hasLightBackground ? "chapter-section--bg-light" : " "}`, style: { "--chapter-section-text-color": textColor ? textColor : "#136f63", "--cta-current-color": blockVariant === "backgrounded" ? "inherit" : "var(--wp--preset--color--primary) !important" diff --git a/plugins/carhop-blocks/build/chapter-section/index.js.map b/plugins/carhop-blocks/build/chapter-section/index.js.map index 77444a9..128cd23 100644 --- a/plugins/carhop-blocks/build/chapter-section/index.js.map +++ b/plugins/carhop-blocks/build/chapter-section/index.js.map @@ -1 +1 @@ -{"version":3,"file":"chapter-section/index.js","mappings":";;;;;;;;;;;;;;AAAA;AACO,SAASA,YAAYA,CAACC,KAAK,EAAE;EACnC;EACA,IAAI,CAACA,KAAK,EAAE,OAAO,IAAI;;EAEvB;EACA,IAAIC,GAAG,GAAGD,KAAK,CAACE,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC;EAChC,IAAID,GAAG,CAACE,MAAM,KAAK,CAAC,EAAE;IACrBF,GAAG,GAAG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A;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./_utilities/utilities.js","webpack://carhop-blocks/./node_modules/.pnpm/@wordpress+icons@11.2.0_react@18.3.1/node_modules/@wordpress/icons/build-module/library/trash.js","webpack://carhop-blocks/./src/chapter-section/edit.js","webpack://carhop-blocks/./src/chapter-section/editor.scss","webpack://carhop-blocks/./src/chapter-section/index.js","webpack://carhop-blocks/./src/chapter-section/save.js","webpack://carhop-blocks/./src/chapter-section/shapeA.jsx","webpack://carhop-blocks/./src/chapter-section/shapeB.jsx","webpack://carhop-blocks/./src/chapter-section/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window [\"wp\",\"primitives\"]","webpack://carhop-blocks/external window \"React\"","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["// Fonction pour déterminer si une couleur est claire ou sombre\r\nexport function isColorLight(color) {\r\n\t// Si pas de couleur, considérer comme claire\r\n\tif (!color) return true;\r\n\r\n\t// Convertir hex en RGB\r\n\tlet hex = color.replace(\"#\", \"\");\r\n\tif (hex.length === 3) {\r\n\t\thex = hex\r\n\t\t\t.split(\"\")\r\n\t\t\t.map((char) => char + char)\r\n\t\t\t.join(\"\");\r\n\t}\r\n\r\n\tconst r = parseInt(hex.substr(0, 2), 16);\r\n\tconst g = parseInt(hex.substr(2, 2), 16);\r\n\tconst b = parseInt(hex.substr(4, 2), 16);\r\n\r\n\t// Calculer la luminance relative (formule standard)\r\n\tconst luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;\r\n\r\n\t// Si luminance > 0.5, la couleur est claire\r\n\treturn luminance > 0.5;\r\n}\r\n","// packages/icons/src/library/trash.tsx\nimport { Path, SVG } from \"@wordpress/primitives\";\nimport { jsx } from \"react/jsx-runtime\";\nvar trash_default = /* @__PURE__ */ jsx(SVG, { xmlns: \"http://www.w3.org/2000/svg\", viewBox: \"0 0 24 24\", children: /* @__PURE__ */ jsx(\n Path,\n {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M12 5.5A2.25 2.25 0 0 0 9.878 7h4.244A2.251 2.251 0 0 0 12 5.5ZM12 4a3.751 3.751 0 0 0-3.675 3H5v1.5h1.27l.818 8.997a2.75 2.75 0 0 0 2.739 2.501h4.347a2.75 2.75 0 0 0 2.738-2.5L17.73 8.5H19V7h-3.325A3.751 3.751 0 0 0 12 4Zm4.224 4.5H7.776l.806 8.861a1.25 1.25 0 0 0 1.245 1.137h4.347a1.25 1.25 0 0 0 1.245-1.137l.805-8.861Z\"\n }\n) });\nexport {\n trash_default as default\n};\n//# sourceMappingURL=trash.js.map\n","import { __ } from \"@wordpress/i18n\";\nimport {\n\tInnerBlocks,\n\tuseBlockProps,\n\tInspectorControls,\n\tMediaReplaceFlow,\n\tMediaPlaceholder,\n\tuseSetting,\n} from \"@wordpress/block-editor\";\nimport shapeA from \"./shapeA.jsx\";\nimport shapeB from \"./shapeB.jsx\";\nimport { lock, trash } from \"@wordpress/icons\";\nimport { ColorPalette } from \"@wordpress/components\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n} from \"@wordpress/components\";\n\nimport \"./editor.scss\";\nimport { isColorLight } from \"../../_utilities/utilities\";\nimport ShapeA from \"./shapeA.jsx\";\nimport ShapeB from \"./shapeB.jsx\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst colors = useSetting(\"color.palette.theme\");\n\tconst {\n\t\thasLightBackground,\n\t\tdisposition,\n\t\tcoverType,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverId,\n\t\tcoverSize,\n\t\tbackgroundColor,\n\n\t\tblockWidth,\n\t\ttextColor,\n\t\tshapeType,\n\t\tblockVariant,\n\t\tborderColor,\n\t} = attributes;\n\n\tfunction onDispositionChange(disposition) {\n\t\tsetAttributes({ disposition });\n\t}\n\n\tfunction setCoverAttributes(cover) {\n\t\tsetAttributes({\n\t\t\tcoverId: cover.id,\n\t\t\tcoverAlt: cover.alt,\n\t\t\tcoverUrl: cover.url,\n\t\t});\n\t}\n\tfunction removeCoverAttributes() {\n\t\tsetAttributes({\n\t\t\tcoverId: null,\n\t\t\tcoverAlt: null,\n\t\t\tcoverUrl: null,\n\t\t});\n\t}\n\tfunction onBackgroundColorChange(value) {\n\t\tif (!value) return;\n\t\tsetAttributes({ backgroundColor: value });\n\t\tsetHasLightBackground(value);\n\t}\n\n\tfunction onCoverTypeChange(value) {\n\t\tsetAttributes({ coverType: value });\n\t}\n\n\tfunction onBlockVariantChange(value) {\n\t\tsetAttributes({ blockVariant: value });\n\n\t\tif (value === \"framed\" || value === \"nude\") {\n\t\t\tsetAttributes({ backgroundColor: \"#fff\" });\n\t\t\tsetAttributes({ hasLightBackground: true });\n\t\t}\n\t}\n\n\tfunction setHasLightBackground(backgroundColor) {\n\t\tif (!backgroundColor) return;\n\n\t\tconst isLightBackgroundColor = isColorLight(backgroundColor);\n\t\tsetAttributes({ hasLightBackground: isLightBackgroundColor });\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t{/* Largeur du bloc */}\n\t\t\t\t\t setAttributes({ blockWidth: value })}\n\t\t\t\t\t\tvalue={blockWidth}\n\t\t\t\t\t>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t{/* Modèle de bloc */}\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t{/* Disposition */}\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t{blockVariant === \"backgrounded\" && (\n\t\t\t\t\t\n\t\t\t\t\t\t setAttributes({ shapeType: value })}\n\t\t\t\t\t\t\tvalue={shapeType}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\t{blockVariant === \"framed\" && (\n\t\t\t\t\t\n\t\t\t\t\t\t setAttributes({ shapeType: value })}\n\t\t\t\t\t\t\tvalue={shapeType}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t setAttributes({ borderColor: value })}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\n\t\t\t\t)}\n\n\t\t\t\t\n\t\t\t\t\t{coverUrl && {coverAlt}}\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t\t{coverUrl && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t)}\n\t\t\t\t\t
\n\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\n\t\t\t\t\t setAttributes({ coverSize })}\n\t\t\t\t\t\tvalue={coverSize}\n\t\t\t\t\t>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t\n\t\t\t\t\t setAttributes({ textColor: value })}\n\t\t\t\t\t/>\n\t\t\t\t\n\t\t\t
\n\t\t\t\n\t\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t{coverUrl && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\t{!coverUrl && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t\tforeground: \"#136f63\",\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, RichText, InnerBlocks } from \"@wordpress/block-editor\";\nimport ShapeA from \"./shapeA.jsx\";\nimport ShapeB from \"./shapeB.jsx\";\nexport default function save({ attributes }) {\n\tconst {\n\t\thasLightBackground,\n\t\tdisposition,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverSize,\n\t\tcoverType,\n\t\tbackgroundColor,\n\t\tblockWidth,\n\t\ttextColor,\n\t\tshapeType,\n\t\tblockVariant,\n\t\tborderColor,\n\t} = attributes;\n\n\treturn (\n\t\t\n\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t\t{coverUrl && (\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n}\n","import React from \"react\";\r\n\r\nexport default function ShapeA({\r\n\tbackgroundOrientation,\r\n\tbackgroundColor,\r\n\tborderColor,\r\n}) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n","import React from \"react\";\r\n\r\nexport default function ShapeB({\r\n\tbackgroundOrientation,\r\n\tbackgroundColor,\r\n\tborderColor,\r\n}) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"wp\"][\"primitives\"];","module.exports = window[\"React\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"chapter-section/index\": 0,\n\t\"chapter-section/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"chapter-section/style-index\"], () => (__webpack_require__(\"./src/chapter-section/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["isColorLight","color","hex","replace","length","split","map","char","join","r","parseInt","substr","g","b","luminance","__","InnerBlocks","useBlockProps","InspectorControls","MediaReplaceFlow","MediaPlaceholder","useSetting","shapeA","shapeB","lock","trash","ColorPalette","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","ShapeA","ShapeB","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","colors","hasLightBackground","disposition","coverType","coverUrl","coverAlt","coverId","coverSize","backgroundColor","blockWidth","textColor","shapeType","blockVariant","borderColor","onDispositionChange","setCoverAttributes","cover","id","alt","url","removeCoverAttributes","onBackgroundColorChange","value","setHasLightBackground","onCoverTypeChange","onBlockVariantChange","isLightBackgroundColor","children","className","title","isBlock","label","onChange","initialOpen","src","mediaId","mediaUrl","allowedTypes","accept","onSelect","name","variant","icon","onClick","style","template","innerBlocks","content","placeholder","allowedBlocks","multiple","handleUpload","registerBlockType","save","metadata","xmlns","viewBox","d","foreground","edit","RichText","Content","React","backgroundOrientation","width","height","fill","preserveAspectRatio","vectorEffect","overflow","stroke","strokeWidth","strokeLinejoin"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"chapter-section/index.js","mappings":";;;;;;;;;;;;;;AAAA;AACO,SAASA,YAAYA,CAACC,KAAK,EAAE;EACnC;EACA,IAAI,CAACA,KAAK,EAAE,OAAO,IAAI;;EAEvB;EACA,IAAIC,GAAG,GAAGD,KAAK,CAACE,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC;EAChC,IAAID,GAAG,CAACE,MAAM,KAAK,CAAC,EAAE;IACrBF,GAAG,GAAGA,GAAG,CACPG,KAAK,CAAC,EAAE,CAAC,CACTC,GAAG,CAAEC,IAAI,IAAKA,IAAI,GAAGA,IAAI,CAAC,CAC1BC,IAAI,CAAC,EAAE,CAAC;EACX;EAEA,MAAMC,CAAC,GAAGC,QAAQ,CAACR,GAAG,CAACS,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;EACxC,MAAMC,CAAC,GAAGF,QAAQ,CAACR,GAAG,CAACS,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;EACxC,MAAME,CAAC,GAAGH,QAAQ,CAACR,GAAG,CAACS,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;;EAExC;EACA,MAAMG,SAAS,GAAG,CAAC,KAAK,GAA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A;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./_utilities/utilities.js","webpack://carhop-blocks/./node_modules/.pnpm/@wordpress+icons@11.2.0_react@18.3.1/node_modules/@wordpress/icons/build-module/library/trash.js","webpack://carhop-blocks/./src/chapter-section/edit.js","webpack://carhop-blocks/./src/chapter-section/editor.scss?4f3a","webpack://carhop-blocks/./src/chapter-section/index.js","webpack://carhop-blocks/./src/chapter-section/save.js","webpack://carhop-blocks/./src/chapter-section/shapeA.jsx","webpack://carhop-blocks/./src/chapter-section/shapeB.jsx","webpack://carhop-blocks/./src/chapter-section/style.scss?ef55","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window [\"wp\",\"primitives\"]","webpack://carhop-blocks/external window \"React\"","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["// Fonction pour déterminer si une couleur est claire ou sombre\r\nexport function isColorLight(color) {\r\n\t// Si pas de couleur, considérer comme claire\r\n\tif (!color) return true;\r\n\r\n\t// Convertir hex en RGB\r\n\tlet hex = color.replace(\"#\", \"\");\r\n\tif (hex.length === 3) {\r\n\t\thex = hex\r\n\t\t\t.split(\"\")\r\n\t\t\t.map((char) => char + char)\r\n\t\t\t.join(\"\");\r\n\t}\r\n\r\n\tconst r = parseInt(hex.substr(0, 2), 16);\r\n\tconst g = parseInt(hex.substr(2, 2), 16);\r\n\tconst b = parseInt(hex.substr(4, 2), 16);\r\n\r\n\t// Calculer la luminance relative (formule standard)\r\n\tconst luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;\r\n\r\n\t// Si luminance > 0.5, la couleur est claire\r\n\treturn luminance > 0.5;\r\n}\r\n","// packages/icons/src/library/trash.tsx\nimport { Path, SVG } from \"@wordpress/primitives\";\nimport { jsx } from \"react/jsx-runtime\";\nvar trash_default = /* @__PURE__ */ jsx(SVG, { xmlns: \"http://www.w3.org/2000/svg\", viewBox: \"0 0 24 24\", children: /* @__PURE__ */ jsx(\n Path,\n {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M12 5.5A2.25 2.25 0 0 0 9.878 7h4.244A2.251 2.251 0 0 0 12 5.5ZM12 4a3.751 3.751 0 0 0-3.675 3H5v1.5h1.27l.818 8.997a2.75 2.75 0 0 0 2.739 2.501h4.347a2.75 2.75 0 0 0 2.738-2.5L17.73 8.5H19V7h-3.325A3.751 3.751 0 0 0 12 4Zm4.224 4.5H7.776l.806 8.861a1.25 1.25 0 0 0 1.245 1.137h4.347a1.25 1.25 0 0 0 1.245-1.137l.805-8.861Z\"\n }\n) });\nexport {\n trash_default as default\n};\n//# sourceMappingURL=trash.js.map\n","import { __ } from \"@wordpress/i18n\";\nimport {\n\tInnerBlocks,\n\tuseBlockProps,\n\tInspectorControls,\n\tMediaReplaceFlow,\n\tMediaPlaceholder,\n\tuseSetting,\n} from \"@wordpress/block-editor\";\nimport shapeA from \"./shapeA.jsx\";\nimport shapeB from \"./shapeB.jsx\";\nimport { lock, trash } from \"@wordpress/icons\";\nimport { ColorPalette } from \"@wordpress/components\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n} from \"@wordpress/components\";\n\nimport \"./editor.scss\";\nimport { isColorLight } from \"../../_utilities/utilities\";\nimport ShapeA from \"./shapeA.jsx\";\nimport ShapeB from \"./shapeB.jsx\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst colors = useSetting(\"color.palette.theme\");\n\tconst {\n\t\thasLightBackground,\n\t\tdisposition,\n\t\tcoverType,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverId,\n\t\tcoverSize,\n\t\tbackgroundColor,\n\n\t\tblockWidth,\n\t\ttextColor,\n\t\tshapeType,\n\t\tblockVariant,\n\t\tborderColor,\n\t} = attributes;\n\n\tfunction onDispositionChange(disposition) {\n\t\tsetAttributes({ disposition });\n\t}\n\n\tfunction setCoverAttributes(cover) {\n\t\tsetAttributes({\n\t\t\tcoverId: cover.id,\n\t\t\tcoverAlt: cover.alt,\n\t\t\tcoverUrl: cover.url,\n\t\t});\n\t}\n\tfunction removeCoverAttributes() {\n\t\tsetAttributes({\n\t\t\tcoverId: null,\n\t\t\tcoverAlt: null,\n\t\t\tcoverUrl: null,\n\t\t});\n\t}\n\tfunction onBackgroundColorChange(value) {\n\t\tif (!value) return;\n\t\tsetAttributes({ backgroundColor: value });\n\t\tsetHasLightBackground(value);\n\t}\n\n\tfunction onCoverTypeChange(value) {\n\t\tsetAttributes({ coverType: value });\n\t}\n\n\tfunction onBlockVariantChange(value) {\n\t\tsetAttributes({ blockVariant: value });\n\n\t\tif (value === \"framed\" || value === \"nude\") {\n\t\t\tsetAttributes({ backgroundColor: \"#fff\" });\n\t\t\tsetAttributes({ hasLightBackground: true });\n\t\t}\n\t}\n\n\tfunction setHasLightBackground(backgroundColor) {\n\t\tif (!backgroundColor) return;\n\n\t\tconst isLightBackgroundColor = isColorLight(backgroundColor);\n\t\tsetAttributes({ hasLightBackground: isLightBackgroundColor });\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t{/* Largeur du bloc */}\n\t\t\t\t\t setAttributes({ blockWidth: value })}\n\t\t\t\t\t\tvalue={blockWidth}\n\t\t\t\t\t>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t{/* Modèle de bloc */}\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t{/* Disposition */}\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t{blockVariant === \"backgrounded\" && (\n\t\t\t\t\t\n\t\t\t\t\t\t setAttributes({ shapeType: value })}\n\t\t\t\t\t\t\tvalue={shapeType}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\t{blockVariant === \"framed\" && (\n\t\t\t\t\t\n\t\t\t\t\t\t setAttributes({ shapeType: value })}\n\t\t\t\t\t\t\tvalue={shapeType}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t setAttributes({ borderColor: value })}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\n\t\t\t\t)}\n\n\t\t\t\t\n\t\t\t\t\t{coverUrl && {coverAlt}}\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t\t{coverUrl && (\n\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t)}\n\t\t\t\t\t
\n\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\n\t\t\t\t\t setAttributes({ coverSize })}\n\t\t\t\t\t\tvalue={coverSize}\n\t\t\t\t\t>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t\n\t\t\t\t\t setAttributes({ textColor: value })}\n\t\t\t\t\t/>\n\t\t\t\t\n\t\t\t
\n\t\t\t\n\t\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\t\tbackgroundColor &&\n\t\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t)}\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t{coverUrl && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\t{!coverUrl && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t\tforeground: \"#136f63\",\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, RichText, InnerBlocks } from \"@wordpress/block-editor\";\nimport ShapeA from \"./shapeA.jsx\";\nimport ShapeB from \"./shapeB.jsx\";\nexport default function save({ attributes }) {\n\tconst {\n\t\thasLightBackground,\n\t\tdisposition,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverSize,\n\t\tcoverType,\n\t\tbackgroundColor,\n\t\tblockWidth,\n\t\ttextColor,\n\t\tshapeType,\n\t\tblockVariant,\n\t\tborderColor,\n\t} = attributes;\n\n\treturn (\n\t\t\n\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t{blockVariant === \"backgrounded\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationA\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t{blockVariant === \"framed\" &&\n\t\t\t\tbackgroundColor &&\n\t\t\t\tshapeType === \"variationB\" && (\n\t\t\t\t\t\n\t\t\t\t)}\n\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t\t{coverUrl && (\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n}\n","import React from \"react\";\r\n\r\nexport default function ShapeA({\r\n\tbackgroundOrientation,\r\n\tbackgroundColor,\r\n\tborderColor,\r\n}) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n","import React from \"react\";\r\n\r\nexport default function ShapeB({\r\n\tbackgroundOrientation,\r\n\tbackgroundColor,\r\n\tborderColor,\r\n}) {\r\n\treturn (\r\n\t\t\r\n\t\t\t\r\n\t\t\r\n\t);\r\n}\r\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"wp\"][\"primitives\"];","module.exports = window[\"React\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"chapter-section/index\": 0,\n\t\"chapter-section/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"chapter-section/style-index\"], () => (__webpack_require__(\"./src/chapter-section/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["isColorLight","color","hex","replace","length","split","map","char","join","r","parseInt","substr","g","b","luminance","__","InnerBlocks","useBlockProps","InspectorControls","MediaReplaceFlow","MediaPlaceholder","useSetting","shapeA","shapeB","lock","trash","ColorPalette","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","ShapeA","ShapeB","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","colors","hasLightBackground","disposition","coverType","coverUrl","coverAlt","coverId","coverSize","backgroundColor","blockWidth","textColor","shapeType","blockVariant","borderColor","onDispositionChange","setCoverAttributes","cover","id","alt","url","removeCoverAttributes","onBackgroundColorChange","value","setHasLightBackground","onCoverTypeChange","onBlockVariantChange","isLightBackgroundColor","children","className","title","isBlock","label","onChange","initialOpen","src","mediaId","mediaUrl","allowedTypes","accept","onSelect","name","variant","icon","onClick","style","template","innerBlocks","content","placeholder","allowedBlocks","multiple","handleUpload","registerBlockType","save","metadata","xmlns","viewBox","d","foreground","edit","RichText","Content","React","backgroundOrientation","width","height","fill","preserveAspectRatio","vectorEffect","overflow","stroke","strokeWidth","strokeLinejoin"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/block.json b/plugins/carhop-blocks/build/company-timeline/block.json new file mode 100644 index 0000000..ed70eac --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/block.json @@ -0,0 +1,71 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 3, + "name": "telex/block-company-timeline", + "version": "0.1.0", + "title": "Company Timeline", + "category": "design", + "icon": "calendar-alt", + "description": "Display company milestones with a fixed sidebar navigation and scroll-based highlighting", + "keywords": [ + "timeline", + "history", + "milestones", + "chronology", + "events" + ], + "attributes": { + "entries": { + "type": "array", + "default": [ + { + "year": "2020", + "title": "Company Founded", + "description": "Our journey began with a vision to make a difference.", + "imageUrl": "", + "imageId": 0 + } + ] + } + }, + "example": { + "attributes": { + "entries": [ + { + "year": "2010", + "title": "The Beginning", + "description": "Founded with a mission to innovate.", + "imageUrl": "", + "imageId": 0 + }, + { + "year": "2015", + "title": "Major Milestone", + "description": "Reached 1 million customers worldwide.", + "imageUrl": "", + "imageId": 0 + }, + { + "year": "2020", + "title": "Global Expansion", + "description": "Opened offices in 25 countries.", + "imageUrl": "", + "imageId": 0 + } + ] + } + }, + "supports": { + "html": false, + "anchor": true, + "align": [ + "wide", + "full" + ] + }, + "textdomain": "company-timeline", + "editorScript": "file:./index.js", + "editorStyle": "file:./index.css", + "style": "file:./style-index.css", + "viewScript": "file:./view.js" +} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/index-rtl.css b/plugins/carhop-blocks/build/company-timeline/index-rtl.css new file mode 100644 index 0000000..a979cba --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/index-rtl.css @@ -0,0 +1,28 @@ +/*!******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/company-timeline/editor.scss ***! + \******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied inside the editor only. + * + * Replace them with your own styles or remove the file completely. + */ +.wp-block-telex-company-timeline .timeline-entry-content .timeline-title:focus, +.wp-block-telex-company-timeline .timeline-entry-content .timeline-description:focus { + outline: 2px solid #3b82f6; + outline-offset: 2px; +} +.wp-block-telex-company-timeline .timeline-entry-content .timeline-media button { + margin-top: 12px; +} +.components-panel__body .components-card { + margin-bottom: 12px; +} +.components-panel__body .components-card .components-card__header { + border-bottom: 1px solid #e2e8f0; +} +.components-panel__body .components-card .components-card__body .components-base-control { + margin-bottom: 16px; +} +.components-panel__body .components-card .components-card__body .components-base-control:last-child { + margin-bottom: 0; +} diff --git a/plugins/carhop-blocks/build/company-timeline/index.asset.php b/plugins/carhop-blocks/build/company-timeline/index.asset.php new file mode 100644 index 0000000..1d79df4 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/index.asset.php @@ -0,0 +1 @@ + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n'), 'version' => '1101279c0fa28dd5a309'); diff --git a/plugins/carhop-blocks/build/company-timeline/index.css b/plugins/carhop-blocks/build/company-timeline/index.css new file mode 100644 index 0000000..d0c40d1 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/index.css @@ -0,0 +1,30 @@ +/*!******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/company-timeline/editor.scss ***! + \******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied inside the editor only. + * + * Replace them with your own styles or remove the file completely. + */ +.wp-block-telex-company-timeline .timeline-entry-content .timeline-title:focus, +.wp-block-telex-company-timeline .timeline-entry-content .timeline-description:focus { + outline: 2px solid #3b82f6; + outline-offset: 2px; +} +.wp-block-telex-company-timeline .timeline-entry-content .timeline-media button { + margin-top: 12px; +} +.components-panel__body .components-card { + margin-bottom: 12px; +} +.components-panel__body .components-card .components-card__header { + border-bottom: 1px solid #e2e8f0; +} +.components-panel__body .components-card .components-card__body .components-base-control { + margin-bottom: 16px; +} +.components-panel__body .components-card .components-card__body .components-base-control:last-child { + margin-bottom: 0; +} + +/*# sourceMappingURL=index.css.map*/ \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/index.css.map b/plugins/carhop-blocks/build/company-timeline/index.css.map new file mode 100644 index 0000000..64e04ce --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/index.css.map @@ -0,0 +1 @@ +{"version":3,"file":"company-timeline/index.css","mappings":";;;AAAA;;;;EAAA;AAUG;;EACC;EACA;AAHJ;AAQG;EACC;AANJ;AAaC;EACC;AAVF;AAYE;EACC;AAVH;AAcG;EACC;AAZJ;AAcI;EACC;AAZL,C","sources":["webpack://carhop-blocks/./src/company-timeline/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-telex-company-timeline {\n\t.timeline-entry-content {\n\t\t.timeline-title,\n\t\t.timeline-description {\n\t\t\t&:focus {\n\t\t\t\toutline: 2px solid #3b82f6;\n\t\t\t\toutline-offset: 2px;\n\t\t\t}\n\t\t}\n\n\t\t.timeline-media {\n\t\t\tbutton {\n\t\t\t\tmargin-top: 12px;\n\t\t\t}\n\t\t}\n\t}\n}\n\n.components-panel__body {\n\t.components-card {\n\t\tmargin-bottom: 12px;\n\n\t\t.components-card__header {\n\t\t\tborder-bottom: 1px solid #e2e8f0;\n\t\t}\n\n\t\t.components-card__body {\n\t\t\t.components-base-control {\n\t\t\t\tmargin-bottom: 16px;\n\n\t\t\t\t&:last-child {\n\t\t\t\t\tmargin-bottom: 0;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n"],"names":[],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/index.js b/plugins/carhop-blocks/build/company-timeline/index.js new file mode 100644 index 0000000..7c1d6da --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/index.js @@ -0,0 +1,603 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./src/company-timeline/block.json": +/*!*****************************************!*\ + !*** ./src/company-timeline/block.json ***! + \*****************************************/ +/***/ ((module) => { + +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"telex/block-company-timeline","version":"0.1.0","title":"Company Timeline","category":"design","icon":"calendar-alt","description":"Display company milestones with a fixed sidebar navigation and scroll-based highlighting","keywords":["timeline","history","milestones","chronology","events"],"attributes":{"entries":{"type":"array","default":[{"year":"2020","title":"Company Founded","description":"Our journey began with a vision to make a difference.","imageUrl":"","imageId":0}]}},"example":{"attributes":{"entries":[{"year":"2010","title":"The Beginning","description":"Founded with a mission to innovate.","imageUrl":"","imageId":0},{"year":"2015","title":"Major Milestone","description":"Reached 1 million customers worldwide.","imageUrl":"","imageId":0},{"year":"2020","title":"Global Expansion","description":"Opened offices in 25 countries.","imageUrl":"","imageId":0}]}},"supports":{"html":false,"anchor":true,"align":["wide","full"]},"textdomain":"company-timeline","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js"}'); + +/***/ }), + +/***/ "./src/company-timeline/edit.js": +/*!**************************************!*\ + !*** ./src/company-timeline/edit.js ***! + \**************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Edit) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./editor.scss */ "./src/company-timeline/editor.scss"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + +function Edit({ + attributes, + setAttributes +}) { + const { + entries + } = attributes; + const [selectedYear, setSelectedYear] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(null); + const addEntry = () => { + const newEntries = [...entries, { + year: new Date().getFullYear().toString(), + title: "", + description: "", + imageUrl: "", + imageId: 0 + }]; + setAttributes({ + entries: newEntries + }); + }; + const updateEntry = (index, field, value) => { + const newEntries = [...entries]; + newEntries[index] = { + ...newEntries[index], + [field]: value + }; + setAttributes({ + entries: newEntries + }); + }; + const removeEntry = index => { + const newEntries = entries.filter((_, i) => i !== index); + setAttributes({ + entries: newEntries + }); + }; + const sortedEntries = [...entries].sort((a, b) => parseInt(a.year) - parseInt(b.year)); + const years = [...new Set(sortedEntries.map(entry => entry.year))]; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.Fragment, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InspectorControls, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.PanelBody, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Timeline Entries", "company-timeline"), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + variant: "primary", + onClick: addEntry, + style: { + marginBottom: "16px" + }, + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Add Timeline Entry", "company-timeline") + }), sortedEntries.map((entry, index) => { + const originalIndex = entries.findIndex(e => e.year === entry.year && e.title === entry.title && e.description === entry.description); + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Card, { + style: { + marginBottom: "12px" + }, + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.CardHeader, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("strong", { + children: entry.year || (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("New Entry", "company-timeline") + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.CardBody, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.TextControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Year", "company-timeline"), + value: entry.year, + onChange: value => updateEntry(originalIndex, "year", value), + type: "number" + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isDestructive: true, + onClick: () => removeEntry(originalIndex), + style: { + marginTop: "8px" + }, + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Remove Entry", "company-timeline") + })] + })] + }, index); + })] + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)(), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "wp-block-telex-company-timeline", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "timeline-sidebar", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "timeline-years", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("h3", { + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Timeline", "company-timeline") + }), years.map(year => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("button", { + className: `year-link ${selectedYear === year ? "active" : ""}`, + onClick: () => setSelectedYear(year), + children: year + }, year))] + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "timeline-content", + children: sortedEntries.map((entry, index) => { + const originalIndex = entries.findIndex(e => e.year === entry.year && e.title === entry.title && e.description === entry.description); + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "timeline-entry", + "data-year": entry.year, + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "timeline-year-marker", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("h2", { + children: entry.year + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "timeline-entry-content", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.RichText, { + tagName: "h3", + value: entry.title, + onChange: value => updateEntry(originalIndex, "title", value), + placeholder: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Enter milestone title...", "company-timeline"), + className: "timeline-title" + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.RichText, { + tagName: "p", + value: entry.description, + onChange: value => updateEntry(originalIndex, "description", value), + placeholder: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Enter milestone description...", "company-timeline"), + className: "timeline-description" + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.MediaUploadCheck, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.MediaUpload, { + onSelect: media => { + updateEntry(originalIndex, "imageUrl", media.url); + updateEntry(originalIndex, "imageId", media.id); + }, + allowedTypes: ["image"], + value: entry.imageId, + render: ({ + open + }) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "timeline-media", + children: entry.imageUrl ? /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.Fragment, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("img", { + src: entry.imageUrl, + alt: entry.title + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isDestructive: true, + onClick: () => { + updateEntry(originalIndex, "imageUrl", ""); + updateEntry(originalIndex, "imageId", 0); + }, + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Remove Image", "company-timeline") + })] + }) : /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + onClick: open, + variant: "secondary", + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Add Image", "company-timeline") + }) + }) + }) + })] + })] + }, index); + }) + })] + }) + })] + }); +} + +/***/ }), + +/***/ "./src/company-timeline/editor.scss": +/*!******************************************!*\ + !*** ./src/company-timeline/editor.scss ***! + \******************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/company-timeline/index.js": +/*!***************************************!*\ + !*** ./src/company-timeline/index.js ***! + \***************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/blocks */ "@wordpress/blocks"); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./style.scss */ "./src/company-timeline/style.scss"); +/* harmony import */ var _edit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./edit */ "./src/company-timeline/edit.js"); +/* harmony import */ var _save__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./save */ "./src/company-timeline/save.js"); +/* harmony import */ var _block_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./block.json */ "./src/company-timeline/block.json"); +/** + * Registers a new block provided a unique name and an object defining its behavior. + * + * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-registration/ + */ + + +/** + * Lets webpack process CSS, SASS or SCSS files referenced in JavaScript files. + * All files containing `style` keyword are bundled together. The code used + * gets applied both to the front of your site and to the editor. + * + * @see https://www.npmjs.com/package/@wordpress/scripts#using-css + */ + + +/** + * Internal dependencies + */ + + + + +/** + * Every block starts by registering a new block type definition. + * + * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-registration/ + */ +(0,_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__.registerBlockType)(_block_json__WEBPACK_IMPORTED_MODULE_4__.name, { + /** + * @see ./edit.js + */ + edit: _edit__WEBPACK_IMPORTED_MODULE_2__["default"], + /** + * @see ./save.js + */ + save: _save__WEBPACK_IMPORTED_MODULE_3__["default"] +}); + +/***/ }), + +/***/ "./src/company-timeline/save.js": +/*!**************************************!*\ + !*** ./src/company-timeline/save.js ***! + \**************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ save) +/* harmony export */ }); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__); +/** + * React hook that is used to mark the block wrapper element. + * It provides all the necessary props like the class name. + * + * @see https://developer.wordpress.org/block-editor/reference-guides/packages/packages-block-editor/#useblockprops + */ + + +/** + * The save function defines the way in which the different attributes should + * be combined into the final markup, which is then serialized by the block + * editor into `post_content`. + * + * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-edit-save/#save + * + * @param {Object} props Block properties + * @return {Element} Element to render. + */ + +function save({ + attributes +}) { + const { + entries + } = attributes; + const sortedEntries = [...entries].sort((a, b) => parseInt(a.year) - parseInt(b.year)); + const years = [...new Set(sortedEntries.map(entry => entry.year))]; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save(), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { + className: "wp-block-telex-company-timeline", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "timeline-sidebar", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { + className: "timeline-years", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("h3", { + children: "Timeline" + }), years.map(year => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("a", { + href: `#year-${year}`, + className: "year-link", + "data-year": year, + children: year + }, year))] + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "timeline-content", + children: sortedEntries.map((entry, index) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { + className: "timeline-entry", + id: `year-${entry.year}`, + "data-year": entry.year, + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "timeline-year-marker", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("h2", { + children: entry.year + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { + className: "timeline-entry-content", + children: [entry.title && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.RichText.Content, { + tagName: "h3", + value: entry.title, + className: "timeline-title" + }), entry.description && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.RichText.Content, { + tagName: "p", + value: entry.description, + className: "timeline-description" + }), entry.imageUrl && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "timeline-media", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("img", { + src: entry.imageUrl, + alt: entry.title || '' + }) + })] + })] + }, index)) + })] + }) + }); +} + +/***/ }), + +/***/ "./src/company-timeline/style.scss": +/*!*****************************************!*\ + !*** ./src/company-timeline/style.scss ***! + \*****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "@wordpress/block-editor": +/*!*************************************!*\ + !*** external ["wp","blockEditor"] ***! + \*************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blockEditor"]; + +/***/ }), + +/***/ "@wordpress/blocks": +/*!********************************!*\ + !*** external ["wp","blocks"] ***! + \********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blocks"]; + +/***/ }), + +/***/ "@wordpress/components": +/*!************************************!*\ + !*** external ["wp","components"] ***! + \************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["components"]; + +/***/ }), + +/***/ "@wordpress/element": +/*!*********************************!*\ + !*** external ["wp","element"] ***! + \*********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["element"]; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!******************************!*\ + !*** external ["wp","i18n"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["i18n"]; + +/***/ }), + +/***/ "react/jsx-runtime": +/*!**********************************!*\ + !*** external "ReactJSXRuntime" ***! + \**********************************/ +/***/ ((module) => { + +module.exports = window["ReactJSXRuntime"]; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/chunk loaded */ +/******/ (() => { +/******/ var deferred = []; +/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { +/******/ if(chunkIds) { +/******/ priority = priority || 0; +/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; +/******/ deferred[i] = [chunkIds, fn, priority]; +/******/ return; +/******/ } +/******/ var notFulfilled = Infinity; +/******/ for (var i = 0; i < deferred.length; i++) { +/******/ var [chunkIds, fn, priority] = deferred[i]; +/******/ var fulfilled = true; +/******/ for (var j = 0; j < chunkIds.length; j++) { +/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { +/******/ chunkIds.splice(j--, 1); +/******/ } else { +/******/ fulfilled = false; +/******/ if(priority < notFulfilled) notFulfilled = priority; +/******/ } +/******/ } +/******/ if(fulfilled) { +/******/ deferred.splice(i--, 1) +/******/ var r = fn(); +/******/ if (r !== undefined) result = r; +/******/ } +/******/ } +/******/ return result; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/jsonp chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded and loading chunks +/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched +/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded +/******/ var installedChunks = { +/******/ "company-timeline/index": 0, +/******/ "company-timeline/style-index": 0 +/******/ }; +/******/ +/******/ // no chunk on demand loading +/******/ +/******/ // no prefetching +/******/ +/******/ // no preloaded +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ +/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); +/******/ +/******/ // install a JSONP callback for chunk loading +/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { +/******/ var [chunkIds, moreModules, runtime] = data; +/******/ // add "moreModules" to the modules object, +/******/ // then flag all "chunkIds" as loaded and fire callback +/******/ var moduleId, chunkId, i = 0; +/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { +/******/ for(moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) var result = runtime(__webpack_require__); +/******/ } +/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); +/******/ for(;i < chunkIds.length; i++) { +/******/ chunkId = chunkIds[i]; +/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { +/******/ installedChunks[chunkId][0](); +/******/ } +/******/ installedChunks[chunkId] = 0; +/******/ } +/******/ return __webpack_require__.O(result); +/******/ } +/******/ +/******/ var chunkLoadingGlobal = globalThis["webpackChunkcarhop_blocks"] = globalThis["webpackChunkcarhop_blocks"] || []; +/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); +/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ // startup +/******/ // Load entry module and return exports +/******/ // This entry module depends on other loaded chunks and execution need to be delayed +/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["company-timeline/style-index"], () => (__webpack_require__("./src/company-timeline/index.js"))) +/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); +/******/ +/******/ })() +; +//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/index.js.map b/plugins/carhop-blocks/build/company-timeline/index.js.map new file mode 100644 index 0000000..fb98055 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"company-timeline/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AAQJ;AAUF;AAEe;AAEvB;AAAA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C;IAAA,CACF;EAAC,CACF,CAAC;AAER,C;;;;;;;;;;;ACvFA;;;;;;;;;;;ACAA,6C;;;;;;;;;;ACAA,wC;;;;;;;;;;ACAA,4C;;;;;;;;;;ACAA,yC;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,2C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/company-timeline/edit.js","webpack://carhop-blocks/./src/company-timeline/editor.scss?58d5","webpack://carhop-blocks/./src/company-timeline/index.js","webpack://carhop-blocks/./src/company-timeline/save.js","webpack://carhop-blocks/./src/company-timeline/style.scss?7b12","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"element\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\n\nimport {\n\tuseBlockProps,\n\tInspectorControls,\n\tMediaUpload,\n\tMediaUploadCheck,\n\tRichText,\n} from \"@wordpress/block-editor\";\n\nimport {\n\tPanelBody,\n\tButton,\n\tTextControl,\n\tCard,\n\tCardBody,\n\tCardHeader,\n\tIconButton,\n} from \"@wordpress/components\";\n\nimport { useState } from \"@wordpress/element\";\n\nimport \"./editor.scss\";\n\nexport default function Edit({ attributes, setAttributes }) {\n\tconst { entries } = attributes;\n\tconst [selectedYear, setSelectedYear] = useState(null);\n\n\tconst addEntry = () => {\n\t\tconst newEntries = [\n\t\t\t...entries,\n\t\t\t{\n\t\t\t\tyear: new Date().getFullYear().toString(),\n\t\t\t\ttitle: \"\",\n\t\t\t\tdescription: \"\",\n\t\t\t\timageUrl: \"\",\n\t\t\t\timageId: 0,\n\t\t\t},\n\t\t];\n\t\tsetAttributes({ entries: newEntries });\n\t};\n\n\tconst updateEntry = (index, field, value) => {\n\t\tconst newEntries = [...entries];\n\t\tnewEntries[index] = {\n\t\t\t...newEntries[index],\n\t\t\t[field]: value,\n\t\t};\n\t\tsetAttributes({ entries: newEntries });\n\t};\n\n\tconst removeEntry = (index) => {\n\t\tconst newEntries = entries.filter((_, i) => i !== index);\n\t\tsetAttributes({ entries: newEntries });\n\t};\n\n\tconst sortedEntries = [...entries].sort(\n\t\t(a, b) => parseInt(a.year) - parseInt(b.year)\n\t);\n\n\tconst years = [...new Set(sortedEntries.map((entry) => entry.year))];\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t{__(\"Add Timeline Entry\", \"company-timeline\")}\n\t\t\t\t\t\n\n\t\t\t\t\t{sortedEntries.map((entry, index) => {\n\t\t\t\t\t\tconst originalIndex = entries.findIndex(\n\t\t\t\t\t\t\t(e) =>\n\t\t\t\t\t\t\t\te.year === entry.year &&\n\t\t\t\t\t\t\t\te.title === entry.title &&\n\t\t\t\t\t\t\t\te.description === entry.description\n\t\t\t\t\t\t);\n\n\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t{entry.year || __(\"New Entry\", \"company-timeline\")}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"year\", value)\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\ttype=\"number\"\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t removeEntry(originalIndex)}\n\t\t\t\t\t\t\t\t\t\tstyle={{ marginTop: \"8px\" }}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{__(\"Remove Entry\", \"company-timeline\")}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t);\n\t\t\t\t\t})}\n\t\t\t\t\n\t\t\t\n\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

{__(\"Timeline\", \"company-timeline\")}

\n\t\t\t\t\t\t\t{years.map((year) => (\n\t\t\t\t\t\t\t\t setSelectedYear(year)}\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t{year}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\n\t\t\t\t\t
\n\t\t\t\t\t\t{sortedEntries.map((entry, index) => {\n\t\t\t\t\t\t\tconst originalIndex = entries.findIndex(\n\t\t\t\t\t\t\t\t(e) =>\n\t\t\t\t\t\t\t\t\te.year === entry.year &&\n\t\t\t\t\t\t\t\t\te.title === entry.title &&\n\t\t\t\t\t\t\t\t\te.description === entry.description\n\t\t\t\t\t\t\t);\n\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t

{entry.year}

\n\t\t\t\t\t\t\t\t\t
\n\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"title\", value)\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\tplaceholder={__(\n\t\t\t\t\t\t\t\t\t\t\t\t\"Enter milestone title...\",\n\t\t\t\t\t\t\t\t\t\t\t\t\"company-timeline\"\n\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\tclassName=\"timeline-title\"\n\t\t\t\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"description\", value)\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\tplaceholder={__(\n\t\t\t\t\t\t\t\t\t\t\t\t\"Enter milestone description...\",\n\t\t\t\t\t\t\t\t\t\t\t\t\"company-timeline\"\n\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\tclassName=\"timeline-description\"\n\t\t\t\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"imageUrl\", media.url);\n\t\t\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"imageId\", media.id);\n\t\t\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\t\t\tallowedTypes={[\"image\"]}\n\t\t\t\t\t\t\t\t\t\t\t\tvalue={entry.imageId}\n\t\t\t\t\t\t\t\t\t\t\t\trender={({ open }) => (\n\t\t\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t{entry.imageUrl ? (\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{entry.title}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"imageUrl\", \"\");\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tupdateEntry(originalIndex, \"imageId\", 0);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{__(\"Remove Image\", \"company-timeline\")}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t})}\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","/**\n * Registers a new block provided a unique name and an object defining its behavior.\n *\n * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-registration/\n */\nimport { registerBlockType } from '@wordpress/blocks';\n\n/**\n * Lets webpack process CSS, SASS or SCSS files referenced in JavaScript files.\n * All files containing `style` keyword are bundled together. The code used\n * gets applied both to the front of your site and to the editor.\n *\n * @see https://www.npmjs.com/package/@wordpress/scripts#using-css\n */\nimport './style.scss';\n\n/**\n * Internal dependencies\n */\nimport Edit from './edit';\nimport save from './save';\nimport metadata from './block.json';\n\n/**\n * Every block starts by registering a new block type definition.\n *\n * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-registration/\n */\nregisterBlockType( metadata.name, {\n\t/**\n\t * @see ./edit.js\n\t */\n\tedit: Edit,\n\n\t/**\n\t * @see ./save.js\n\t */\n\tsave,\n} );\n","/**\n * React hook that is used to mark the block wrapper element.\n * It provides all the necessary props like the class name.\n *\n * @see https://developer.wordpress.org/block-editor/reference-guides/packages/packages-block-editor/#useblockprops\n */\nimport { useBlockProps, RichText } from '@wordpress/block-editor';\n\n/**\n * The save function defines the way in which the different attributes should\n * be combined into the final markup, which is then serialized by the block\n * editor into `post_content`.\n *\n * @see https://developer.wordpress.org/block-editor/reference-guides/block-api/block-edit-save/#save\n *\n * @param {Object} props Block properties\n * @return {Element} Element to render.\n */\nexport default function save( { attributes } ) {\n\tconst { entries } = attributes;\n\t\n\tconst sortedEntries = [ ...entries ].sort( ( a, b ) => \n\t\tparseInt( a.year ) - parseInt( b.year )\n\t);\n\n\tconst years = [ ...new Set( sortedEntries.map( entry => entry.year ) ) ];\n\n\treturn (\n\t\t
\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t

Timeline

\n\t\t\t\t\t\t{ years.map( ( year ) => (\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{ year }\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t) ) }\n\t\t\t\t\t
\n\t\t\t\t
\n\n\t\t\t\t
\n\t\t\t\t\t{ sortedEntries.map( ( entry, index ) => (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t

{ entry.year }

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t{ entry.title && (\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{ entry.description && (\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{ entry.imageUrl && (\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t) ) }\n\t\t\t\t
\n\t\t\t
\n\t\t
\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"element\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"company-timeline/index\": 0,\n\t\"company-timeline/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"company-timeline/style-index\"], () => (__webpack_require__(\"./src/company-timeline/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InspectorControls","MediaUpload","MediaUploadCheck","RichText","PanelBody","Button","TextControl","Card","CardBody","CardHeader","IconButton","useState","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","entries","selectedYear","setSelectedYear","addEntry","newEntries","year","Date","getFullYear","toString","title","description","imageUrl","imageId","updateEntry","index","field","value","removeEntry","filter","_","i","sortedEntries","sort","a","b","parseInt","years","Set","map","entry","children","variant","onClick","style","marginBottom","originalIndex","findIndex","e","label","onChange","type","isDestructive","marginTop","className","tagName","placeholder","onSelect","media","url","id","allowedTypes","render","open","src","alt","registerBlockType","save","metadata","name","edit","href","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/style-index-rtl.css b/plugins/carhop-blocks/build/company-timeline/style-index-rtl.css new file mode 100644 index 0000000..41cde84 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/style-index-rtl.css @@ -0,0 +1,172 @@ +/*!*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/company-timeline/style.scss ***! + \*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied both on the front of your site + * and in the editor. + * + * Replace them with your own styles or remove the file completely. + */ +.wp-block-telex-company-timeline { + display: flex; + gap: 60px; + max-width: 1200px; + margin: 0 auto; + padding: 40px 20px; + position: relative; +} +.wp-block-telex-company-timeline .timeline-sidebar { + flex: 0 0 200px; + position: sticky; + top: 100px; + height: -moz-fit-content; + height: fit-content; + align-self: flex-start; +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years { + background: #f8f9fa; + border-radius: 8px; + padding: 24px; + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08); +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years h3 { + margin: 0 0 20px 0; + font-size: 18px; + font-weight: 700; + color: #1e293b; + border-bottom: 2px solid #e2e8f0; + padding-bottom: 12px; +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link { + display: block; + padding: 12px 16px; + margin-bottom: 8px; + text-decoration: none; + color: #64748b; + font-weight: 600; + font-size: 16px; + border-radius: 6px; + transition: all 0.3s ease; + cursor: pointer; + background: transparent; + border: none; + width: 100%; + text-align: right; +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link:hover { + background: #e2e8f0; + color: #1e293b; + transform: translateX(-4px); +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link.active { + background: #3b82f6; + color: white; + box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3); +} +.wp-block-telex-company-timeline .timeline-content { + flex: 1; + min-width: 0; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry { + margin-bottom: 80px; + scroll-margin-top: 100px; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry:last-child { + margin-bottom: 0; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker { + margin-bottom: 24px; + position: relative; + padding-right: 40px; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker::before { + content: ""; + position: absolute; + right: 0; + top: 50%; + transform: translateY(-50%); + width: 24px; + height: 24px; + background: #3b82f6; + border-radius: 50%; + box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2); +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker h2 { + margin: 0; + font-size: 32px; + font-weight: 800; + color: #1e293b; + line-height: 1; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content { + background: white; + border-radius: 12px; + padding: 32px; + box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1); + border-right: 4px solid #3b82f6; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-title { + margin: 0 0 16px 0; + font-size: 24px; + font-weight: 700; + color: #1e293b; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-description { + margin: 0 0 24px 0; + font-size: 16px; + line-height: 1.8; + color: #475569; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-media { + margin-top: 24px; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-media img { + width: 100%; + height: auto; + border-radius: 8px; + box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); +} +@media (max-width: 768px) { + .wp-block-telex-company-timeline { + flex-direction: column; + gap: 30px; + padding: 20px 15px; + } + .wp-block-telex-company-timeline .timeline-sidebar { + position: static; + flex: 1; + } + .wp-block-telex-company-timeline .timeline-sidebar .timeline-years { + padding: 16px; + } + .wp-block-telex-company-timeline .timeline-sidebar .timeline-years h3 { + font-size: 16px; + margin-bottom: 12px; + } + .wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link { + padding: 10px 12px; + font-size: 14px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry { + margin-bottom: 50px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker { + padding-right: 30px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker::before { + width: 18px; + height: 18px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker h2 { + font-size: 24px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content { + padding: 20px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-title { + font-size: 20px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-description { + font-size: 15px; + } +} diff --git a/plugins/carhop-blocks/build/company-timeline/style-index.css b/plugins/carhop-blocks/build/company-timeline/style-index.css new file mode 100644 index 0000000..9b5a672 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/style-index.css @@ -0,0 +1,174 @@ +/*!*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/company-timeline/style.scss ***! + \*****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied both on the front of your site + * and in the editor. + * + * Replace them with your own styles or remove the file completely. + */ +.wp-block-telex-company-timeline { + display: flex; + gap: 60px; + max-width: 1200px; + margin: 0 auto; + padding: 40px 20px; + position: relative; +} +.wp-block-telex-company-timeline .timeline-sidebar { + flex: 0 0 200px; + position: sticky; + top: 100px; + height: -moz-fit-content; + height: fit-content; + align-self: flex-start; +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years { + background: #f8f9fa; + border-radius: 8px; + padding: 24px; + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08); +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years h3 { + margin: 0 0 20px 0; + font-size: 18px; + font-weight: 700; + color: #1e293b; + border-bottom: 2px solid #e2e8f0; + padding-bottom: 12px; +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link { + display: block; + padding: 12px 16px; + margin-bottom: 8px; + text-decoration: none; + color: #64748b; + font-weight: 600; + font-size: 16px; + border-radius: 6px; + transition: all 0.3s ease; + cursor: pointer; + background: transparent; + border: none; + width: 100%; + text-align: left; +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link:hover { + background: #e2e8f0; + color: #1e293b; + transform: translateX(4px); +} +.wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link.active { + background: #3b82f6; + color: white; + box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3); +} +.wp-block-telex-company-timeline .timeline-content { + flex: 1; + min-width: 0; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry { + margin-bottom: 80px; + scroll-margin-top: 100px; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry:last-child { + margin-bottom: 0; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker { + margin-bottom: 24px; + position: relative; + padding-left: 40px; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker::before { + content: ""; + position: absolute; + left: 0; + top: 50%; + transform: translateY(-50%); + width: 24px; + height: 24px; + background: #3b82f6; + border-radius: 50%; + box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2); +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker h2 { + margin: 0; + font-size: 32px; + font-weight: 800; + color: #1e293b; + line-height: 1; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content { + background: white; + border-radius: 12px; + padding: 32px; + box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1); + border-left: 4px solid #3b82f6; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-title { + margin: 0 0 16px 0; + font-size: 24px; + font-weight: 700; + color: #1e293b; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-description { + margin: 0 0 24px 0; + font-size: 16px; + line-height: 1.8; + color: #475569; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-media { + margin-top: 24px; +} +.wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-media img { + width: 100%; + height: auto; + border-radius: 8px; + box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); +} +@media (max-width: 768px) { + .wp-block-telex-company-timeline { + flex-direction: column; + gap: 30px; + padding: 20px 15px; + } + .wp-block-telex-company-timeline .timeline-sidebar { + position: static; + flex: 1; + } + .wp-block-telex-company-timeline .timeline-sidebar .timeline-years { + padding: 16px; + } + .wp-block-telex-company-timeline .timeline-sidebar .timeline-years h3 { + font-size: 16px; + margin-bottom: 12px; + } + .wp-block-telex-company-timeline .timeline-sidebar .timeline-years .year-link { + padding: 10px 12px; + font-size: 14px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry { + margin-bottom: 50px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker { + padding-left: 30px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker::before { + width: 18px; + height: 18px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-year-marker h2 { + font-size: 24px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content { + padding: 20px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-title { + font-size: 20px; + } + .wp-block-telex-company-timeline .timeline-content .timeline-entry .timeline-entry-content .timeline-description { + font-size: 15px; + } +} + +/*# sourceMappingURL=style-index.css.map*/ \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/style-index.css.map b/plugins/carhop-blocks/build/company-timeline/style-index.css.map new file mode 100644 index 0000000..34ccd89 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/style-index.css.map @@ -0,0 +1 @@ +{"version":3,"file":"company-timeline/style-index.css","mappings":";;;AAAA;;;;;EAAA;AAOA;EACC;EACA;EACA;EACA;EACA;EACA;AAAD;AAEC;EACC;EACA;EACA;EACA;EAAA;EACA;AAAF;AAEE;EACC;EACA;EACA;EACA;AAAH;AAEG;EACC;EACA;EACA;EACA;EACA;EACA;AAAJ;AAGG;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;AADJ;AAGI;EACC;EACA;EACA;AADL;AAII;EACC;EACA;EACA;AAFL;AAQC;EACC;EACA;AANF;AAQE;EACC;EACA;AANH;AAQG;EACC;AANJ;AASG;EACC;EACA;EACA;AAPJ;AASI;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;AAPL;AAUI;EACC;EACA;EACA;EACA;EACA;AARL;AAYG;EACC;EACA;EACA;EACA;EACA;AAVJ;AAYI;EACC;EACA;EACA;EACA;AAVL;AAaI;EACC;EACA;EACA;EACA;AAXL;AAcI;EACC;AAZL;AAcK;EACC;EACA;EACA;EACA;AAZN;AAmBC;EAvID;IAwIE;IACA;IACA;EAhBA;EAkBA;IACC;IACA;EAhBD;EAkBC;IACC;EAhBF;EAkBE;IACC;IACA;EAhBH;EAmBE;IACC;IACA;EAjBH;EAuBC;IACC;EArBF;EAuBE;IACC;EArBH;EAuBG;IACC;IACA;EArBJ;EAwBG;IACC;EAtBJ;EA0BE;IACC;EAxBH;EA0BG;IACC;EAxBJ;EA2BG;IACC;EAzBJ;AACF,C","sources":["webpack://carhop-blocks/./src/company-timeline/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-telex-company-timeline {\n\tdisplay: flex;\n\tgap: 60px;\n\tmax-width: 1200px;\n\tmargin: 0 auto;\n\tpadding: 40px 20px;\n\tposition: relative;\n\n\t.timeline-sidebar {\n\t\tflex: 0 0 200px;\n\t\tposition: sticky;\n\t\ttop: 100px;\n\t\theight: fit-content;\n\t\talign-self: flex-start;\n\n\t\t.timeline-years {\n\t\t\tbackground: #f8f9fa;\n\t\t\tborder-radius: 8px;\n\t\t\tpadding: 24px;\n\t\t\tbox-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);\n\n\t\t\th3 {\n\t\t\t\tmargin: 0 0 20px 0;\n\t\t\t\tfont-size: 18px;\n\t\t\t\tfont-weight: 700;\n\t\t\t\tcolor: #1e293b;\n\t\t\t\tborder-bottom: 2px solid #e2e8f0;\n\t\t\t\tpadding-bottom: 12px;\n\t\t\t}\n\n\t\t\t.year-link {\n\t\t\t\tdisplay: block;\n\t\t\t\tpadding: 12px 16px;\n\t\t\t\tmargin-bottom: 8px;\n\t\t\t\ttext-decoration: none;\n\t\t\t\tcolor: #64748b;\n\t\t\t\tfont-weight: 600;\n\t\t\t\tfont-size: 16px;\n\t\t\t\tborder-radius: 6px;\n\t\t\t\ttransition: all 0.3s ease;\n\t\t\t\tcursor: pointer;\n\t\t\t\tbackground: transparent;\n\t\t\t\tborder: none;\n\t\t\t\twidth: 100%;\n\t\t\t\ttext-align: left;\n\n\t\t\t\t&:hover {\n\t\t\t\t\tbackground: #e2e8f0;\n\t\t\t\t\tcolor: #1e293b;\n\t\t\t\t\ttransform: translateX(4px);\n\t\t\t\t}\n\n\t\t\t\t&.active {\n\t\t\t\t\tbackground: #3b82f6;\n\t\t\t\t\tcolor: white;\n\t\t\t\t\tbox-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t.timeline-content {\n\t\tflex: 1;\n\t\tmin-width: 0;\n\n\t\t.timeline-entry {\n\t\t\tmargin-bottom: 80px;\n\t\t\tscroll-margin-top: 100px;\n\n\t\t\t&:last-child {\n\t\t\t\tmargin-bottom: 0;\n\t\t\t}\n\n\t\t\t.timeline-year-marker {\n\t\t\t\tmargin-bottom: 24px;\n\t\t\t\tposition: relative;\n\t\t\t\tpadding-left: 40px;\n\n\t\t\t\t&::before {\n\t\t\t\t\tcontent: '';\n\t\t\t\t\tposition: absolute;\n\t\t\t\t\tleft: 0;\n\t\t\t\t\ttop: 50%;\n\t\t\t\t\ttransform: translateY(-50%);\n\t\t\t\t\twidth: 24px;\n\t\t\t\t\theight: 24px;\n\t\t\t\t\tbackground: #3b82f6;\n\t\t\t\t\tborder-radius: 50%;\n\t\t\t\t\tbox-shadow: 0 0 0 4px rgba(59, 130, 246, 0.2);\n\t\t\t\t}\n\n\t\t\t\th2 {\n\t\t\t\t\tmargin: 0;\n\t\t\t\t\tfont-size: 32px;\n\t\t\t\t\tfont-weight: 800;\n\t\t\t\t\tcolor: #1e293b;\n\t\t\t\t\tline-height: 1;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t.timeline-entry-content {\n\t\t\t\tbackground: white;\n\t\t\t\tborder-radius: 12px;\n\t\t\t\tpadding: 32px;\n\t\t\t\tbox-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);\n\t\t\t\tborder-left: 4px solid #3b82f6;\n\n\t\t\t\t.timeline-title {\n\t\t\t\t\tmargin: 0 0 16px 0;\n\t\t\t\t\tfont-size: 24px;\n\t\t\t\t\tfont-weight: 700;\n\t\t\t\t\tcolor: #1e293b;\n\t\t\t\t}\n\n\t\t\t\t.timeline-description {\n\t\t\t\t\tmargin: 0 0 24px 0;\n\t\t\t\t\tfont-size: 16px;\n\t\t\t\t\tline-height: 1.8;\n\t\t\t\t\tcolor: #475569;\n\t\t\t\t}\n\n\t\t\t\t.timeline-media {\n\t\t\t\t\tmargin-top: 24px;\n\n\t\t\t\t\timg {\n\t\t\t\t\t\twidth: 100%;\n\t\t\t\t\t\theight: auto;\n\t\t\t\t\t\tborder-radius: 8px;\n\t\t\t\t\t\tbox-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t@media (max-width: 768px) {\n\t\tflex-direction: column;\n\t\tgap: 30px;\n\t\tpadding: 20px 15px;\n\n\t\t.timeline-sidebar {\n\t\t\tposition: static;\n\t\t\tflex: 1;\n\n\t\t\t.timeline-years {\n\t\t\t\tpadding: 16px;\n\n\t\t\t\th3 {\n\t\t\t\t\tfont-size: 16px;\n\t\t\t\t\tmargin-bottom: 12px;\n\t\t\t\t}\n\n\t\t\t\t.year-link {\n\t\t\t\t\tpadding: 10px 12px;\n\t\t\t\t\tfont-size: 14px;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t.timeline-content {\n\t\t\t.timeline-entry {\n\t\t\t\tmargin-bottom: 50px;\n\n\t\t\t\t.timeline-year-marker {\n\t\t\t\t\tpadding-left: 30px;\n\n\t\t\t\t\t&::before {\n\t\t\t\t\t\twidth: 18px;\n\t\t\t\t\t\theight: 18px;\n\t\t\t\t\t}\n\n\t\t\t\t\th2 {\n\t\t\t\t\t\tfont-size: 24px;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t.timeline-entry-content {\n\t\t\t\t\tpadding: 20px;\n\n\t\t\t\t\t.timeline-title {\n\t\t\t\t\t\tfont-size: 20px;\n\t\t\t\t\t}\n\n\t\t\t\t\t.timeline-description {\n\t\t\t\t\t\tfont-size: 15px;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n"],"names":[],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/view.asset.php b/plugins/carhop-blocks/build/company-timeline/view.asset.php new file mode 100644 index 0000000..c5f0b19 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/view.asset.php @@ -0,0 +1 @@ + array(), 'version' => '13a56f69d7eb73f33007'); diff --git a/plugins/carhop-blocks/build/company-timeline/view.js b/plugins/carhop-blocks/build/company-timeline/view.js new file mode 100644 index 0000000..c53217e --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/view.js @@ -0,0 +1,68 @@ +/******/ (() => { // webpackBootstrap +/*!**************************************!*\ + !*** ./src/company-timeline/view.js ***! + \**************************************/ +/** + * Use this file for JavaScript code that you want to run in the front-end + * on posts/pages that contain this block. + */ + +document.addEventListener('DOMContentLoaded', function () { + const timeline = document.querySelector('.wp-block-telex-company-timeline'); + if (!timeline) { + return; + } + const sidebar = timeline.querySelector('.timeline-sidebar'); + const yearLinks = timeline.querySelectorAll('.year-link'); + const entries = timeline.querySelectorAll('.timeline-entry'); + if (!sidebar || yearLinks.length === 0 || entries.length === 0) { + return; + } + + // Smooth scroll to year when clicking sidebar link + yearLinks.forEach(link => { + link.addEventListener('click', function (e) { + e.preventDefault(); + const year = this.getAttribute('data-year') || this.getAttribute('href').replace('#year-', ''); + const targetEntry = timeline.querySelector(`[data-year="${year}"]`); + if (targetEntry) { + targetEntry.scrollIntoView({ + behavior: 'smooth', + block: 'start' + }); + } + }); + }); + + // Update active year on scroll + const observerOptions = { + root: null, + rootMargin: '-20% 0px -70% 0px', + threshold: 0 + }; + const observerCallback = entries => { + entries.forEach(entry => { + if (entry.isIntersecting) { + const year = entry.target.getAttribute('data-year'); + + // Remove active class from all links + yearLinks.forEach(link => link.classList.remove('active')); + + // Add active class to current year + const activeLink = timeline.querySelector(`.year-link[data-year="${year}"]`); + if (activeLink) { + activeLink.classList.add('active'); + } + } + }); + }; + const observer = new IntersectionObserver(observerCallback, observerOptions); + + // Observe all timeline entries + entries.forEach(entry => { + observer.observe(entry); + }); +}); +/******/ })() +; +//# sourceMappingURL=view.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/company-timeline/view.js.map b/plugins/carhop-blocks/build/company-timeline/view.js.map new file mode 100644 index 0000000..ed24519 --- /dev/null +++ b/plugins/carhop-blocks/build/company-timeline/view.js.map @@ -0,0 +1 @@ +{"version":3,"file":"company-timeline/view.js","mappings":";;;;AAAA;AACA;AACA;AACA;;AAEAA,QAAQ,CAACC,gBAAgB,CAAE,kBAAkB,EAAE,YAAW;EACzD,MAAMC,QAAQ,GAAGF,QAA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YAAY,CAAE,WAAY,CAAC;;QAErD;QACAT,SAAS,CAACI,OAAO,CAAEC,IAAI,IAAIA,IAAI,CAACkB,SAAS,CAACC,MAAM,CAAE,QAAS,CAAE,CAAC;;QAE9D;QACA,MAAMC,UAAU,GAAG5B,QAAQ,CAACC,aAAa,CAAE,yBAA0BU,IAAI,IAAM,CAAC;QAChF,IAAKiB,UAAU,EAAG;UACjBA,UAAU,CAACF,SAAS,CAACG,GAAG,CAAE,QAAS,CAAC;QACrC;MACD;IACD,CAAE,CAAC;EACJ,CAAC;EAED,MAAMC,QAAQ,GAAG,IAAIC,oBAAoB,CAAET,gBAAgB,EAAEJ,eAAgB,CAAC;;EAE9E;EACAb,OAAO,CAACE,OAAO,CAAEgB,KAAK,IAAI;IACzBO,QAAQ,CAACE,OAAO,CAAET,KAAM,CAAC;EAC1B,CAAE,CAAC;AACJ,CAAE,CAAC,C","sources":["webpack://carhop-blocks/./src/company-timeline/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\ndocument.addEventListener( 'DOMContentLoaded', function() {\n\tconst timeline = document.querySelector( '.wp-block-telex-company-timeline' );\n\t\n\tif ( ! timeline ) {\n\t\treturn;\n\t}\n\n\tconst sidebar = timeline.querySelector( '.timeline-sidebar' );\n\tconst yearLinks = timeline.querySelectorAll( '.year-link' );\n\tconst entries = timeline.querySelectorAll( '.timeline-entry' );\n\n\tif ( ! sidebar || yearLinks.length === 0 || entries.length === 0 ) {\n\t\treturn;\n\t}\n\n\t// Smooth scroll to year when clicking sidebar link\n\tyearLinks.forEach( link => {\n\t\tlink.addEventListener( 'click', function( e ) {\n\t\t\te.preventDefault();\n\t\t\tconst year = this.getAttribute( 'data-year' ) || this.getAttribute( 'href' ).replace( '#year-', '' );\n\t\t\tconst targetEntry = timeline.querySelector( `[data-year=\"${ year }\"]` );\n\t\t\t\n\t\t\tif ( targetEntry ) {\n\t\t\t\ttargetEntry.scrollIntoView( { \n\t\t\t\t\tbehavior: 'smooth',\n\t\t\t\t\tblock: 'start'\n\t\t\t\t} );\n\t\t\t}\n\t\t} );\n\t} );\n\n\t// Update active year on scroll\n\tconst observerOptions = {\n\t\troot: null,\n\t\trootMargin: '-20% 0px -70% 0px',\n\t\tthreshold: 0\n\t};\n\n\tconst observerCallback = ( entries ) => {\n\t\tentries.forEach( entry => {\n\t\t\tif ( entry.isIntersecting ) {\n\t\t\t\tconst year = entry.target.getAttribute( 'data-year' );\n\t\t\t\t\n\t\t\t\t// Remove active class from all links\n\t\t\t\tyearLinks.forEach( link => link.classList.remove( 'active' ) );\n\t\t\t\t\n\t\t\t\t// Add active class to current year\n\t\t\t\tconst activeLink = timeline.querySelector( `.year-link[data-year=\"${ year }\"]` );\n\t\t\t\tif ( activeLink ) {\n\t\t\t\t\tactiveLink.classList.add( 'active' );\n\t\t\t\t}\n\t\t\t}\n\t\t} );\n\t};\n\n\tconst observer = new IntersectionObserver( observerCallback, observerOptions );\n\n\t// Observe all timeline entries\n\tentries.forEach( entry => {\n\t\tobserver.observe( entry );\n\t} );\n} );\n"],"names":["document","addEventListener","timeline","querySelector","sidebar","yearLinks","querySelectorAll","entries","length","forEach","link","e","preventDefault","year","getAttribute","replace","targetEntry","scrollIntoView","behavior","block","observerOptions","root","rootMargin","threshold","observerCallback","entry","isIntersecting","target","classList","remove","activeLink","add","observer","IntersectionObserver","observe"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/content-box/index.asset.php b/plugins/carhop-blocks/build/content-box/index.asset.php index d1481ca..b629e63 100644 --- a/plugins/carhop-blocks/build/content-box/index.asset.php +++ b/plugins/carhop-blocks/build/content-box/index.asset.php @@ -1 +1 @@ - array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-data', 'wp-i18n'), 'version' => '45f49839a2c1b3f6bfdc'); + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-data', 'wp-i18n'), 'version' => '2abc1cc8d49f9b6ba159'); diff --git a/plugins/carhop-blocks/build/content-box/index.js b/plugins/carhop-blocks/build/content-box/index.js index 8a3a194..17dd190 100644 --- a/plugins/carhop-blocks/build/content-box/index.js +++ b/plugins/carhop-blocks/build/content-box/index.js @@ -91,7 +91,7 @@ function Edit({ blockVariant, blockWidth } = attributes; - console.log(blockWidth); + // Détecter le type de post actuel const postType = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_3__.useSelect)(select => { return select("core/editor").getCurrentPostType(); @@ -232,7 +232,7 @@ function Edit({ template: [["core/paragraph", { placeholder: "Ajouter ici le texte" }]], - allowedBlocks: ["core/heading", "core/paragraph", "core/group", "core/list", "core/button", "core/image", "core/buttons", "core/columns", "core/post-title", "core/embed", "core/quote", "core/pullquote", "core/media-text", "core/table", "carhop-blocks/heading", "carhop-blocks/decorative-shapes", "carhop-blocks/scroll-story-block", "carhop-blocks/cta-group", "carhop-blocks/audio-player", "carhop-blocks/localisation-map", "carhop-blocks/notice-panel", "acf/statistics-datas", "ninja-forms/form", "gravityforms/form", "dynamiques-blocks/sitemap", "mailpoet/subscription-form-block", "shortcode"] + allowedBlocks: ["core/heading", "core/paragraph", "core/group", "core/list", "core/button", "core/image", "core/buttons", "core/columns", "core/post-title", "core/embed", "core/quote", "core/pullquote", "core/media-text", "core/table", "carhop-blocks/chapter-section", "carhop-blocks/heading", "carhop-blocks/decorative-shapes", "carhop-blocks/scroll-story-block", "carhop-blocks/cta", "carhop-blocks/cta-group", "carhop-blocks/audio-player", "carhop-blocks/localisation-map", "carhop-blocks/notice-panel", "carhop-blocks/story-timeline", "carhop-blocks/highlight-timeline", "acf/statistics-datas", "ninja-forms/form", "gravityforms/form", "dynamiques-blocks/sitemap", "mailpoet/subscription-form-block", "shortcode"] }) }) })] diff --git a/plugins/carhop-blocks/build/content-box/index.js.map b/plugins/carhop-blocks/build/content-box/index.js.map index 659c86f..3015a63 100644 --- a/plugins/carhop-blocks/build/content-box/index.js.map +++ b/pl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CNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./_utilities/utilities.js","webpack://carhop-blocks/./src/content-box/edit.js","webpack://carhop-blocks/./src/content-box/editor.scss","webpack://carhop-blocks/./src/content-box/index.js","webpack://carhop-blocks/./src/content-box/save.js","webpack://carhop-blocks/./src/content-box/style.scss","webpack://carhop-blocks/./src/content-box/utilities.js","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"data\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["// Fonction pour déterminer si une couleur est claire ou sombre\r\nexport function isColorLight(color) {\r\n\t// Si pas de couleur, considérer comme claire\r\n\tif (!color) return true;\r\n\r\n\t// Convertir hex en RGB\r\n\tlet hex = color.replace(\"#\", \"\");\r\n\tif (hex.length === 3) {\r\n\t\thex = hex\r\n\t\t\t.split(\"\")\r\n\t\t\t.map((char) => char + char)\r\n\t\t\t.join(\"\");\r\n\t}\r\n\r\n\tconst r = parseInt(hex.substr(0, 2), 16);\r\n\tconst g = parseInt(hex.substr(2, 2), 16);\r\n\tconst b = parseInt(hex.substr(4, 2), 16);\r\n\r\n\t// Calculer la luminance relative (formule standard)\r\n\tconst luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;\r\n\r\n\t// Si luminance > 0.5, la couleur est claire\r\n\treturn luminance > 0.5;\r\n}\r\n","import { __ } from \"@wordpress/i18n\";\nimport {\n\tuseBlockProps,\n\tInnerBlocks,\n\tuseSetting,\n\tInspectorControls,\n\tMediaReplaceFlow,\n\tMediaPlaceholder,\n} from \"@wordpress/block-editor\";\nimport {\n\tCard,\n\tCardHeader,\n\tCardBody,\n\tHeading,\n\tText,\n} from \"@wordpress/components\";\nimport { useSelect } from \"@wordpress/data\";\nimport \"./editor.scss\";\nimport { isColorLight } from \"../../_utilities/utilities\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n\tColorPalette,\n} from \"@wordpress/components\";\n\nimport { filterBgColors, filterTextColors } from \"./utilities\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst colors = useSetting(\"color.palette.theme\");\n\n\tconst {\n\t\thasBackgroundColor,\n\t\tbackgroundColor,\n\t\ttextColor,\n\t\thasLightBackground,\n\t\tblockVariant,\n\t\tblockWidth,\n\t} = attributes;\n\n\tconsole.log(blockWidth);\n\t// Détecter le type de post actuel\n\tconst postType = useSelect((select) => {\n\t\treturn select(\"core/editor\").getCurrentPostType();\n\t}, []);\n\n\tconst filteredBgColors = filterBgColors(colors, postType);\n\tconst filteredTextColors = filterTextColors(\n\t\tcolors,\n\t\tpostType,\n\t\tbackgroundColor\n\t);\n\n\tfunction onBackgroundColorChange(value) {\n\t\tif (value === undefined) {\n\t\t\tsetAttributes({ hasBackgroundColor: false });\n\t\t\tsetAttributes({ backgroundColor: \"transparent\" });\n\t\t}\n\t\tconst isLightBackgroundColor = isColorLight(value);\n\t\tsetAttributes({ hasLightBackground: isLightBackgroundColor });\n\t\tsetAttributes({ backgroundColor: value });\n\n\t\tif (!isLightBackgroundColor) {\n\t\t\tsetAttributes({ textColor: \"#fff\" });\n\t\t} else {\n\t\t\tsetAttributes({ textColor: \"inherit\" });\n\t\t}\n\t}\n\tfunction onHasBackgroundColorChange(value) {\n\t\tsetAttributes({ hasBackgroundColor: value });\n\t\tif (!value) {\n\t\t\tsetAttributes({ backgroundColor: null });\n\t\t}\n\t}\n\tfunction onTextColorChange(value) {\n\t\tsetAttributes({ textColor: value });\n\t}\n\tfunction onBlockVariantChange(value) {\n\t\tsetAttributes({ blockVariant: value });\n\n\t\tif (value === \"framed\" || value === \"nude\") {\n\t\t\tsetAttributes({ backgroundColor: \"#fff\" });\n\t\t\tsetAttributes({ hasLightBackground: true });\n\t\t}\n\t}\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t setAttributes({ blockWidth: value })}\n\t\t\t\t\t\tisBlock\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\n\t\t\t\t\t{blockVariant === \"backgrounded\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t

Couleur de fond

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\n\t\t\t\t\t{blockVariant === \"backgrounded\" && postType !== \"articles\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t

Couleur du texte

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\t\t\t\t
\n\t\t\t
\n\t\t\t\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport { isColorLight } from \"../../_utilities/utilities\";\n\nexport default function save({ attributes }) {\n\tconst {\n\t\tbackgroundColor,\n\t\ttextColor,\n\t\thasLightBackground,\n\t\thasBackgroundColor,\n\t\tblockVariant,\n\t\tblockWidth,\n\t} = attributes;\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { isColorLight } from \"../../_utilities/utilities\";\r\n\r\nexport const filterBgColors = (colors, postType) => {\r\n\tif (!postType) return colors || [];\r\n\r\n\tif (postType === \"articles\") {\r\n\t\treturn (\r\n\t\t\tcolors?.filter((color) => {\r\n\t\t\t\t// Garder seulement certaines couleurs pour les articles\r\n\t\t\t\tconst allowedColors = [\r\n\t\t\t\t\t\"carhop-green-light\",\r\n\t\t\t\t\t\"carhop-blue-light\",\r\n\t\t\t\t\t\"carhop-orange-light\",\r\n\t\t\t\t\t\"carhop-red-light\",\r\n\t\t\t\t\t\"carhop-purple-light\",\r\n\t\t\t\t];\r\n\t\t\t\treturn allowedColors.includes(color.slug);\r\n\t\t\t}) || []\r\n\t\t);\r\n\t}\r\n\r\n\treturn colors || [];\r\n};\r\n\r\nexport const filterTextColors = (colors, postType, backgroundColor) => {\r\n\tif (!postType) return colors || [];\r\n\tif (postType === \"page\" && !isColorLight(backgroundColor)) {\r\n\t\t// Retourner seulement du blanc pour les pages avec arrière-plan sombre\r\n\t\treturn [\r\n\t\t\t{\r\n\t\t\t\tname: \"White\",\r\n\t\t\t\tslug: \"white\",\r\n\t\t\t\tcolor: \"#ffffff\",\r\n\t\t\t},\r\n\t\t];\r\n\t}\r\n\r\n\treturn colors || [];\r\n};\r\n","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"data\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"content-box/index\": 0,\n\t\"content-box/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"content-box/style-index\"], () => (__webpack_require__(\"./src/content-box/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["isColorLight","color","hex","replace","length","split","map","char","join","r","parseInt","substr","g","b","luminance","__","useBlockProps","InnerBlocks","useSetting","InspectorControls","MediaReplaceFlow","MediaPlaceholder","Card","CardHeader","CardBody","Heading","Text","useSelect","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","ColorPalette","filterBgColors","filterTextColors","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","colors","hasBackgroundColor","backgroundColor","textColor","hasLightBackground","blockVariant","blockWidth","console","log","postType","select","getCurrentPostType","filteredBgColors","filteredTextColors","onBackgroundColorChange","value","undefined","isLightBackgroundColor","onHasBackgroundColorChange","onTextColorChange","onBlockVariantChange","children","title","label","onChange","isBlock","__nextHasNoMarginBottom","__next40pxDefaultSize","className","style","template","placeholder","allowedBlocks","registerBlockType","save","metadata","name","icon","foreground","src","width","height","viewBox","d","edit","Content","filter","allowedColors","includes","slug"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"content-box/index.js","mappings":";;;;;;;;;;;;;;AAAA;AACO,SAASA,YAAYA,CAACC,KAAK,EAAE;EACnC;EACA,IAAI,CAACA,KAAK,EAAE,OAAO,IAAI;;EAEvB;EACA,IAAIC,GAAG,GAAGD,KAAK,CAACE,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC;EAChC,IAAID,GAAG,CAACE,MAAM,KAAK,CAAC,EAAE;IACrBF,GAAG,GAAGA,GAAG,CACPG,KAAK,CAAC,EAAE,CAAC,CACTC,GAAG,CAAEC,IAAI,IAAKA,IAAI,GAAGA,IAAI,CAAC,CAC1BC,IAAI,CAAC,EAAE,CAAC;EACX;EAEA,MAAMC,CAAC,GAAGC,QAAQ,CAACR,GAAG,CAACS,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;EACxC,MAAMC,CAAC,GAAGF,QAAQ,CAACR,GAAG,CAACS,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;EACxC,MAAME,CAAC,GAAGH,QAAQ,CAACR,GAAG,CAACS,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC;;EAExC;EACA,MAAMG,SAAS,GAAG,CAAC,KAAK,GAAGL,CAAC,GAAG,KA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ACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./_utilities/utilities.js","webpack://carhop-blocks/./src/content-box/edit.js","webpack://carhop-blocks/./src/content-box/editor.scss","webpack://carhop-blocks/./src/content-box/index.js","webpack://carhop-blocks/./src/content-box/save.js","webpack://carhop-blocks/./src/content-box/style.scss","webpack://carhop-blocks/./src/content-box/utilities.js","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"data\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["// Fonction pour déterminer si une couleur est claire ou sombre\r\nexport function isColorLight(color) {\r\n\t// Si pas de couleur, considérer comme claire\r\n\tif (!color) return true;\r\n\r\n\t// Convertir hex en RGB\r\n\tlet hex = color.replace(\"#\", \"\");\r\n\tif (hex.length === 3) {\r\n\t\thex = hex\r\n\t\t\t.split(\"\")\r\n\t\t\t.map((char) => char + char)\r\n\t\t\t.join(\"\");\r\n\t}\r\n\r\n\tconst r = parseInt(hex.substr(0, 2), 16);\r\n\tconst g = parseInt(hex.substr(2, 2), 16);\r\n\tconst b = parseInt(hex.substr(4, 2), 16);\r\n\r\n\t// Calculer la luminance relative (formule standard)\r\n\tconst luminance = (0.299 * r + 0.587 * g + 0.114 * b) / 255;\r\n\r\n\t// Si luminance > 0.5, la couleur est claire\r\n\treturn luminance > 0.5;\r\n}\r\n","import { __ } from \"@wordpress/i18n\";\nimport {\n\tuseBlockProps,\n\tInnerBlocks,\n\tuseSetting,\n\tInspectorControls,\n\tMediaReplaceFlow,\n\tMediaPlaceholder,\n} from \"@wordpress/block-editor\";\nimport {\n\tCard,\n\tCardHeader,\n\tCardBody,\n\tHeading,\n\tText,\n} from \"@wordpress/components\";\nimport { useSelect } from \"@wordpress/data\";\nimport \"./editor.scss\";\nimport { isColorLight } from \"../../_utilities/utilities\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n\tColorPalette,\n} from \"@wordpress/components\";\n\nimport { filterBgColors, filterTextColors } from \"./utilities\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst colors = useSetting(\"color.palette.theme\");\n\n\tconst {\n\t\thasBackgroundColor,\n\t\tbackgroundColor,\n\t\ttextColor,\n\t\thasLightBackground,\n\t\tblockVariant,\n\t\tblockWidth,\n\t} = attributes;\n\n\t// Détecter le type de post actuel\n\tconst postType = useSelect((select) => {\n\t\treturn select(\"core/editor\").getCurrentPostType();\n\t}, []);\n\n\tconst filteredBgColors = filterBgColors(colors, postType);\n\tconst filteredTextColors = filterTextColors(\n\t\tcolors,\n\t\tpostType,\n\t\tbackgroundColor\n\t);\n\n\tfunction onBackgroundColorChange(value) {\n\t\tif (value === undefined) {\n\t\t\tsetAttributes({ hasBackgroundColor: false });\n\t\t\tsetAttributes({ backgroundColor: \"transparent\" });\n\t\t}\n\t\tconst isLightBackgroundColor = isColorLight(value);\n\t\tsetAttributes({ hasLightBackground: isLightBackgroundColor });\n\t\tsetAttributes({ backgroundColor: value });\n\n\t\tif (!isLightBackgroundColor) {\n\t\t\tsetAttributes({ textColor: \"#fff\" });\n\t\t} else {\n\t\t\tsetAttributes({ textColor: \"inherit\" });\n\t\t}\n\t}\n\tfunction onHasBackgroundColorChange(value) {\n\t\tsetAttributes({ hasBackgroundColor: value });\n\t\tif (!value) {\n\t\t\tsetAttributes({ backgroundColor: null });\n\t\t}\n\t}\n\tfunction onTextColorChange(value) {\n\t\tsetAttributes({ textColor: value });\n\t}\n\tfunction onBlockVariantChange(value) {\n\t\tsetAttributes({ blockVariant: value });\n\n\t\tif (value === \"framed\" || value === \"nude\") {\n\t\t\tsetAttributes({ backgroundColor: \"#fff\" });\n\t\t\tsetAttributes({ hasLightBackground: true });\n\t\t}\n\t}\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t setAttributes({ blockWidth: value })}\n\t\t\t\t\t\tisBlock\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t>\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\n\t\t\t\t\t{blockVariant === \"backgrounded\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t

Couleur de fond

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\n\t\t\t\t\t{blockVariant === \"backgrounded\" && postType !== \"articles\" && (\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t

Couleur du texte

\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\t\t\t\t
\n\t\t\t
\n\t\t\t\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport { isColorLight } from \"../../_utilities/utilities\";\n\nexport default function save({ attributes }) {\n\tconst {\n\t\tbackgroundColor,\n\t\ttextColor,\n\t\thasLightBackground,\n\t\thasBackgroundColor,\n\t\tblockVariant,\n\t\tblockWidth,\n\t} = attributes;\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { isColorLight } from \"../../_utilities/utilities\";\r\n\r\nexport const filterBgColors = (colors, postType) => {\r\n\tif (!postType) return colors || [];\r\n\r\n\tif (postType === \"articles\") {\r\n\t\treturn (\r\n\t\t\tcolors?.filter((color) => {\r\n\t\t\t\t// Garder seulement certaines couleurs pour les articles\r\n\t\t\t\tconst allowedColors = [\r\n\t\t\t\t\t\"carhop-green-light\",\r\n\t\t\t\t\t\"carhop-blue-light\",\r\n\t\t\t\t\t\"carhop-orange-light\",\r\n\t\t\t\t\t\"carhop-red-light\",\r\n\t\t\t\t\t\"carhop-purple-light\",\r\n\t\t\t\t];\r\n\t\t\t\treturn allowedColors.includes(color.slug);\r\n\t\t\t}) || []\r\n\t\t);\r\n\t}\r\n\r\n\treturn colors || [];\r\n};\r\n\r\nexport const filterTextColors = (colors, postType, backgroundColor) => {\r\n\tif (!postType) return colors || [];\r\n\tif (postType === \"page\" && !isColorLight(backgroundColor)) {\r\n\t\t// Retourner seulement du blanc pour les pages avec arrière-plan sombre\r\n\t\treturn [\r\n\t\t\t{\r\n\t\t\t\tname: \"White\",\r\n\t\t\t\tslug: \"white\",\r\n\t\t\t\tcolor: \"#ffffff\",\r\n\t\t\t},\r\n\t\t];\r\n\t}\r\n\r\n\treturn colors || [];\r\n};\r\n","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"data\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"content-box/index\": 0,\n\t\"content-box/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"content-box/style-index\"], () => (__webpack_require__(\"./src/content-box/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["isColorLight","color","hex","replace","length","split","map","char","join","r","parseInt","substr","g","b","luminance","__","useBlockProps","InnerBlocks","useSetting","InspectorControls","MediaReplaceFlow","MediaPlaceholder","Card","CardHeader","CardBody","Heading","Text","useSelect","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","ColorPalette","filterBgColors","filterTextColors","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","colors","hasBackgroundColor","backgroundColor","textColor","hasLightBackground","blockVariant","blockWidth","postType","select","getCurrentPostType","filteredBgColors","filteredTextColors","onBackgroundColorChange","value","undefined","isLightBackgroundColor","onHasBackgroundColorChange","onTextColorChange","onBlockVariantChange","children","title","label","onChange","isBlock","__nextHasNoMarginBottom","__next40pxDefaultSize","className","style","template","placeholder","allowedBlocks","registerBlockType","save","metadata","name","icon","foreground","src","width","height","viewBox","d","edit","Content","filter","allowedColors","includes","slug"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/heading/index.asset.php b/plugins/carhop-blocks/build/heading/index.asset.php index 3b5c7e3..51a7d90 100644 --- a/plugins/carhop-blocks/build/heading/index.asset.php +++ b/plugins/carhop-blocks/build/heading/index.asset.php @@ -1 +1 @@ - array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n'), 'version' => 'd4e1ebabc5dcdc5cce1d'); + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n'), 'version' => '893c2836c05b36d8f7ee'); diff --git a/plugins/carhop-blocks/build/heading/index.js b/plugins/carhop-blocks/build/heading/index.js index b550c94..9b95a4c 100644 --- a/plugins/carhop-blocks/build/heading/index.js +++ b/plugins/carhop-blocks/build/heading/index.js @@ -70,19 +70,19 @@ function Edit({ })] }) }) - }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("section", { + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("div", { ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)({ className: `carhop-heading carhop-heading--hierarchy-${hierarchy}` }), children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("div", { className: "carhop-heading__innerblocks", children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { - template: [["core/paragraph", { - placeholder: "Saisir le sous-titre supérieur", - content: "Sous-titre supérieur" - }], ["core/heading", { + template: [["core/heading", { placeholder: "Saisir le titre", content: "Titre" + }], ["core/paragraph", { + placeholder: "Saisir le sous-titre supérieur", + content: "Sous-titre" }]], allowedBlocks: ["core/heading", "core/paragraph", "core/post-title"] }) @@ -172,7 +172,7 @@ function save({ const { hierarchy } = attributes; - return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("section", { + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save({ className: `carhop-heading carhop-heading--hierarchy-${hierarchy}` }), diff --git a/plugins/carhop-blocks/build/heading/index.js.map b/plugins/carhop-blocks/build/heading/index.js.map index 95d1e4f..2b8deea 100644 --- a/plugins/carhop-blocks/build/heading/index.js.map +++ b/plugins/carhop-blocks/build/heading/index.js.map @@ -1 +1 @@ -{"version":3,"file":"heading/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/heading/edit.js","webpack://carhop-blocks/./src/heading/editor.scss","webpack://carhop-blocks/./src/heading/index.js","webpack://carhop-blocks/./src/heading/save.js","webpack://carhop-blocks/./src/heading/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n\tColorPalette,\n} from \"@wordpress/components\";\nimport { InspectorControls } from \"@wordpress/block-editor\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst { hierarchy } = attributes;\n\n\tfunction onHierarchyChange(value) {\n\t\tsetAttributes({ hierarchy: value });\n\t}\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst { hierarchy } = attributes;\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"heading/index\": 0,\n\t\"heading/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"heading/style-index\"], () => (__webpack_require__(\"./src/heading/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","ColorPalette","InspectorControls","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","hierarchy","onHierarchyChange","value","children","title","label","onChange","isBlock","__nextHasNoMarginBottom","__next40pxDefaultSize","className","template","placeholder","content","allowedBlocks","registerBlockType","save","metadata","name","icon","foreground","src","width","height","viewBox","stroke","id","class","d","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"heading/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AAC9C;AAQQ;AAC6B;AAAA;AAE7C,SAASkB,IAAIA,CAAC;EAAEC,UAAU;EAAEC,aAAa;EAAE,GAAGC;AAAM,CAAC,EAAE;EACrE,MAAM;IAAEC;EAAU,CAAC,GAAGH,UAAU;EAEhC,SAASI,iBAAiBA,CAACC,KAAK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AAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/heading/edit.js","webpack://carhop-blocks/./src/heading/editor.scss","webpack://carhop-blocks/./src/heading/index.js","webpack://carhop-blocks/./src/heading/save.js","webpack://carhop-blocks/./src/heading/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n\tColorPalette,\n} from \"@wordpress/components\";\nimport { InspectorControls } from \"@wordpress/block-editor\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst { hierarchy } = attributes;\n\n\tfunction onHierarchyChange(value) {\n\t\tsetAttributes({ hierarchy: value });\n\t}\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst { hierarchy } = attributes;\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"heading/index\": 0,\n\t\"heading/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"heading/style-index\"], () => (__webpack_require__(\"./src/heading/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","ColorPalette","InspectorControls","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","hierarchy","onHierarchyChange","value","children","title","label","onChange","isBlock","__nextHasNoMarginBottom","__next40pxDefaultSize","className","template","placeholder","content","allowedBlocks","registerBlockType","save","metadata","name","icon","foreground","src","width","height","viewBox","stroke","id","class","d","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/block.json b/plugins/carhop-blocks/build/highlight-timeline-step/block.json new file mode 100644 index 0000000..e78ced8 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/block.json @@ -0,0 +1,28 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 3, + "name": "carhop-blocks/highlight-timeline-step", + "version": "0.1.0", + "title": "Étape de timeline", + "category": "carhop-blocks", + "icon": "calendar", + "description": "Étape de timeline pour la mise en forme d'une étape de timeline", + "example": {}, + "parent": [ + "carhop-blocks/highlight-timeline" + ], + "supports": { + "html": false + }, + "textdomain": "carhop-blocks", + "editorScript": "file:./index.js", + "editorStyle": "file:./index.css", + "style": "file:./style-index.css", + "viewScript": "file:./view.js", + "attributes": { + "year": { + "type": "number", + "default": 2025 + } + } +} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/index-rtl.css b/plugins/carhop-blocks/build/highlight-timeline-step/index-rtl.css new file mode 100644 index 0000000..e7dc39c --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/index-rtl.css @@ -0,0 +1,4 @@ +/*!*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline-step/editor.scss ***! + \*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/index.asset.php b/plugins/carhop-blocks/build/highlight-timeline-step/index.asset.php new file mode 100644 index 0000000..077e505 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/index.asset.php @@ -0,0 +1 @@ + array('react', 'react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n'), 'version' => '06b28d02530a4fded8fe'); diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/index.css b/plugins/carhop-blocks/build/highlight-timeline-step/index.css new file mode 100644 index 0000000..e7dc39c --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/index.css @@ -0,0 +1,4 @@ +/*!*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline-step/editor.scss ***! + \*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/index.js b/plugins/carhop-blocks/build/highlight-timeline-step/index.js new file mode 100644 index 0000000..df54a1e --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/index.js @@ -0,0 +1,464 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./src/highlight-timeline-step/block.json": +/*!************************************************!*\ + !*** ./src/highlight-timeline-step/block.json ***! + \************************************************/ +/***/ ((module) => { + +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/highlight-timeline-step","version":"0.1.0","title":"Étape de timeline","category":"carhop-blocks","icon":"calendar","description":"Étape de timeline pour la mise en forme d\'une étape de timeline","example":{},"parent":["carhop-blocks/highlight-timeline"],"supports":{"html":false},"textdomain":"carhop-blocks","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js","attributes":{"year":{"type":"number","default":2025}}}'); + +/***/ }), + +/***/ "./src/highlight-timeline-step/edit.js": +/*!*********************************************!*\ + !*** ./src/highlight-timeline-step/edit.js ***! + \*********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Edit) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./editor.scss */ "./src/highlight-timeline-step/editor.scss"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _timelineYearBackground__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./timelineYearBackground */ "./src/highlight-timeline-step/timelineYearBackground.jsx"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + + + +function Edit({ + attributes, + setAttributes, + ...props +}) { + const { + year + } = attributes; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.Fragment, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InspectorControls, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__.PanelBody, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Étape de timeline", "carhop-blocks"), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__.__experimentalNumberControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Année", "carhop-blocks"), + value: year, + onChange: value => { + const n = parseInt(value, 10); + setAttributes({ + year: Number.isFinite(n) ? n : undefined + }); + } + }) + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)({ + className: `highlight-timeline-step`, + id: `year-${year}` + }), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "highlight-timeline-step__year", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("p", { + className: "highlight-timeline-step__year-text", + children: year + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_timelineYearBackground__WEBPACK_IMPORTED_MODULE_4__["default"], {})] + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "highlight-timeline-step__innerblocks", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { + allowedBlocks: ["core/heading", "core/paragraph", "core/group", "core/list", "core/button", "core/image", "core/buttons", "core/columns", "core/post-title", "core/embed", "core/quote", "core/pullquote", "core/media-text", "core/table", "carhop-blocks/image-stack", "carhop-blocks/heading", "carhop-blocks/decorative-shapes", "carhop-blocks/scroll-highlight-block", "carhop-blocks/cta-group", "carhop-blocks/audio-player", "carhop-blocks/localisation-map", "carhop-blocks/notice-panel", "acf/statistics-datas", "ninja-forms/form", "gravityforms/form", "dynamiques-blocks/sitemap", "mailpoet/subscription-form-block", "shortcode"] + }) + })] + })] + }); +} + +/***/ }), + +/***/ "./src/highlight-timeline-step/editor.scss": +/*!*************************************************!*\ + !*** ./src/highlight-timeline-step/editor.scss ***! + \*************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/highlight-timeline-step/index.js": +/*!**********************************************!*\ + !*** ./src/highlight-timeline-step/index.js ***! + \**********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/blocks */ "@wordpress/blocks"); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./style.scss */ "./src/highlight-timeline-step/style.scss"); +/* harmony import */ var _edit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./edit */ "./src/highlight-timeline-step/edit.js"); +/* harmony import */ var _save__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./save */ "./src/highlight-timeline-step/save.js"); +/* harmony import */ var _block_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./block.json */ "./src/highlight-timeline-step/block.json"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + +(0,_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__.registerBlockType)(_block_json__WEBPACK_IMPORTED_MODULE_4__.name, { + icon: { + foreground: "#136f63", + src: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("svg", { + width: "100", + height: "100", + viewBox: "0 0 100 100", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("g", { + stroke: "null", + id: "svg_10", + class: "fills", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("path", { + stroke: "null", + d: "m3.74998,19.74151c0,-8.82607 7.16546,-15.99153 15.99153,-15.99153l60.51698,0c8.82607,0 15.99153,7.16546 15.99153,15.99153l0,60.51698c0,8.82607 -7.16546,15.99153 -15.99153,15.99153l-60.51698,0c-8.82607,0 -15.99153,-7.16546 -15.99153,-15.99153l0,-60.51698zm22.57628,3.44915l0,53.61867l23.67374,-18.7148l23.67374,18.7148l0,-53.61867l-47.34748,0z" + }) + }) + }) + }, + edit: _edit__WEBPACK_IMPORTED_MODULE_2__["default"], + save: _save__WEBPACK_IMPORTED_MODULE_3__["default"] +}); + +/***/ }), + +/***/ "./src/highlight-timeline-step/save.js": +/*!*********************************************!*\ + !*** ./src/highlight-timeline-step/save.js ***! + \*********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ save) +/* harmony export */ }); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _timelineYearBackground__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./timelineYearBackground */ "./src/highlight-timeline-step/timelineYearBackground.jsx"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__); + + + +function save({ + attributes +}) { + const { + year + } = attributes; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsxs)("div", { + ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save({ + className: `highlight-timeline-step swiper-slide`, + id: `year-${year}` + }), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsxs)("div", { + className: "highlight-timeline-step__year", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)("p", { + className: "highlight-timeline-step__year-text", + children: year + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_timelineYearBackground__WEBPACK_IMPORTED_MODULE_1__["default"], {})] + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)("div", { + className: "highlight-timeline-step__innerblocks", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_2__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.InnerBlocks.Content, {}) + })] + }); +} + +/***/ }), + +/***/ "./src/highlight-timeline-step/style.scss": +/*!************************************************!*\ + !*** ./src/highlight-timeline-step/style.scss ***! + \************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/highlight-timeline-step/timelineYearBackground.jsx": +/*!****************************************************************!*\ + !*** ./src/highlight-timeline-step/timelineYearBackground.jsx ***! + \****************************************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ ShapeA) +/* harmony export */ }); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! react */ "react"); +/* harmony import */ var react__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(react__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__); + + +function ShapeA({}) { + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "highlight-timeline-step__year-background", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("svg", { + xmlns: "http://www.w3.org/2000/svg", + width: "772.1", + height: "653.3", + viewBox: "0 0 772.1 653.3", + preserveAspectRatio: "none", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("polygon", { + preserveAspectRatio: "none", + points: "14.2 10.6 762.1 53.5 757.9 642.7 10.1 599.8 14.2 10.6", + vectorEffect: "non-scaling-stroke" + }) + }) + }); +} + +/***/ }), + +/***/ "@wordpress/block-editor": +/*!*************************************!*\ + !*** external ["wp","blockEditor"] ***! + \*************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blockEditor"]; + +/***/ }), + +/***/ "@wordpress/blocks": +/*!********************************!*\ + !*** external ["wp","blocks"] ***! + \********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blocks"]; + +/***/ }), + +/***/ "@wordpress/components": +/*!************************************!*\ + !*** external ["wp","components"] ***! + \************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["components"]; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!******************************!*\ + !*** external ["wp","i18n"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["i18n"]; + +/***/ }), + +/***/ "react": +/*!************************!*\ + !*** external "React" ***! + \************************/ +/***/ ((module) => { + +module.exports = window["React"]; + +/***/ }), + +/***/ "react/jsx-runtime": +/*!**********************************!*\ + !*** external "ReactJSXRuntime" ***! + \**********************************/ +/***/ ((module) => { + +module.exports = window["ReactJSXRuntime"]; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/chunk loaded */ +/******/ (() => { +/******/ var deferred = []; +/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { +/******/ if(chunkIds) { +/******/ priority = priority || 0; +/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; +/******/ deferred[i] = [chunkIds, fn, priority]; +/******/ return; +/******/ } +/******/ var notFulfilled = Infinity; +/******/ for (var i = 0; i < deferred.length; i++) { +/******/ var [chunkIds, fn, priority] = deferred[i]; +/******/ var fulfilled = true; +/******/ for (var j = 0; j < chunkIds.length; j++) { +/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { +/******/ chunkIds.splice(j--, 1); +/******/ } else { +/******/ fulfilled = false; +/******/ if(priority < notFulfilled) notFulfilled = priority; +/******/ } +/******/ } +/******/ if(fulfilled) { +/******/ deferred.splice(i--, 1) +/******/ var r = fn(); +/******/ if (r !== undefined) result = r; +/******/ } +/******/ } +/******/ return result; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/jsonp chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded and loading chunks +/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched +/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded +/******/ var installedChunks = { +/******/ "highlight-timeline-step/index": 0, +/******/ "highlight-timeline-step/style-index": 0 +/******/ }; +/******/ +/******/ // no chunk on demand loading +/******/ +/******/ // no prefetching +/******/ +/******/ // no preloaded +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ +/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); +/******/ +/******/ // install a JSONP callback for chunk loading +/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { +/******/ var [chunkIds, moreModules, runtime] = data; +/******/ // add "moreModules" to the modules object, +/******/ // then flag all "chunkIds" as loaded and fire callback +/******/ var moduleId, chunkId, i = 0; +/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { +/******/ for(moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) var result = runtime(__webpack_require__); +/******/ } +/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); +/******/ for(;i < chunkIds.length; i++) { +/******/ chunkId = chunkIds[i]; +/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { +/******/ installedChunks[chunkId][0](); +/******/ } +/******/ installedChunks[chunkId] = 0; +/******/ } +/******/ return __webpack_require__.O(result); +/******/ } +/******/ +/******/ var chunkLoadingGlobal = globalThis["webpackChunkcarhop_blocks"] = globalThis["webpackChunkcarhop_blocks"] || []; +/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); +/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ // startup +/******/ // Load entry module and return exports +/******/ // This entry module depends on other loaded chunks and execution need to be delayed +/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["highlight-timeline-step/style-index"], () => (__webpack_require__("./src/highlight-timeline-step/index.js"))) +/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); +/******/ +/******/ })() +; +//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/index.js.map b/plugins/carhop-blocks/build/highlight-timeline-step/index.js.map new file mode 100644 index 0000000..e10bf2b --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"highlight-timeline-step/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AAC9C;AASQ;AAC6B;AAET;AACW;AAAA;AAC/C,SAASoB,IAAIA,CAAC;EAAEC,UAAU;EAAEC,aAAa;EAAE,GAAGC;AAAM,CAAC,EAAE;EACrE,MAAM;IAAEC;EAAK,CAAC,GAAGH,UAAU;EAE3B,oBACCJ,uDAAA,CAAAE,uDAAA;IAAAM,QAAA,gBACCV,sDAAA,CAACJ,sEAAiB;MAAAc,QAAA,eACjBV,sDAAA,CAACZ,4DAAS;QAACuB,KAAK,EAAE1B,mDAAE,CAAC,mBAAmB,EAAE,eAAe,CAAE;QAAAyB,QAAA,eAC1DV,sDAAA,CAACL,8EAAa;UACbiB,KAAK,EAAE3B,mDAAE,CAAC,OAAO,EAAE,eAAe,CAAE;UACpC4B,KAAK,EAAEJ,IAAK;UACZK,QAAQ,EAAGD,KAAK,IAAK;YACpB,MAAME,CAAC,GAAGC,QAAQ,CAACH,KAAK,EAAE,EAAE,CAAC;YAC7BN,aAAa,CAAC;cAAEE,IAAI,EAAEQ,MAAM,CAACC,QAAQ,CAACH,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AmB,EAAC,MAAM;MAAA/B,QAAA,eAE1BV,sDAAA;QACCyC,mBAAmB,EAAC,MAAM;QAC1BC,MAAM,EAAC,uDAAuD;QAC9DC,YAAY,EAAC;MAAoB,CACjC;IAAC,CACE;EAAC,CACF,CAAC;AAER,C;;;;;;;;;;ACpBA,6C;;;;;;;;;;ACAA,wC;;;;;;;;;;ACAA,4C;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,iC;;;;;;;;;;ACAA,2C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/highlight-timeline-step/edit.js","webpack://carhop-blocks/./src/highlight-timeline-step/editor.scss","webpack://carhop-blocks/./src/highlight-timeline-step/index.js","webpack://carhop-blocks/./src/highlight-timeline-step/save.js","webpack://carhop-blocks/./src/highlight-timeline-step/style.scss?109a","webpack://carhop-blocks/./src/highlight-timeline-step/timelineYearBackground.jsx","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"React\"","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\nimport {\n\tPanelBody,\n\tCard,\n\tCardBody,\n\tCardHeader,\n\tTextControl,\n\tButton,\n\t__experimentalNumberControl as NumberControl,\n} from \"@wordpress/components\";\nimport { InspectorControls } from \"@wordpress/block-editor\";\n\nimport { RichText } from \"@wordpress/block-editor\";\nimport TimelineYearBackground from \"./timelineYearBackground\";\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst { year } = attributes;\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t {\n\t\t\t\t\t\t\tconst n = parseInt(value, 10);\n\t\t\t\t\t\t\tsetAttributes({ year: Number.isFinite(n) ? n : undefined });\n\t\t\t\t\t\t}}\n\t\t\t\t\t/>\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t
\n\t\t\t\t\t

{year}

\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport TimelineYearBackground from \"./timelineYearBackground\";\nexport default function save({ attributes }) {\n\tconst { year } = attributes;\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t

{year}

\n\t\t\t\t\n\t\t\t
\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import React from \"react\";\r\n\r\nexport default function ShapeA({}) {\r\n\treturn (\r\n\t\t
\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t\r\n\t\t
\r\n\t);\r\n}\r\n","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"React\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"highlight-timeline-step/index\": 0,\n\t\"highlight-timeline-step/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"highlight-timeline-step/style-index\"], () => (__webpack_require__(\"./src/highlight-timeline-step/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","PanelBody","Card","CardBody","CardHeader","TextControl","Button","__experimentalNumberControl","NumberControl","InspectorControls","RichText","TimelineYearBackground","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","year","children","title","label","value","onChange","n","parseInt","Number","isFinite","undefined","className","id","allowedBlocks","registerBlockType","save","metadata","name","icon","foreground","src","width","height","viewBox","stroke","class","d","edit","Content","React","ShapeA","xmlns","preserveAspectRatio","points","vectorEffect"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/style-index-rtl.css b/plugins/carhop-blocks/build/highlight-timeline-step/style-index-rtl.css new file mode 100644 index 0000000..0f0b7c4 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/style-index-rtl.css @@ -0,0 +1,33 @@ +/*!************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline-step/style.scss ***! + \************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +.highlight-timeline-step__year { + position: relative; +} +.highlight-timeline-step__year > * { + z-index: 1; +} +.highlight-timeline-step__year .highlight-timeline-step__year-background { + position: absolute; + top: 10px; + left: 10px; + bottom: 10px; + right: 10px; + z-index: 0; + overflow: visible; +} +.highlight-timeline-step__year .highlight-timeline-step__year-background svg { + overflow: visible; + width: 100%; + height: 100%; +} +.highlight-timeline-step__year .highlight-timeline-step__year-background svg polygon { + overflow: visible; + fill: #efe8ff; + stroke: white; + stroke-width: 20px; + vector-effect: non-scaling-stroke; +} +.highlight-timeline-step__year .highlight-timeline-step__year-text { + line-height: 1 !important; +} diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/style-index.css b/plugins/carhop-blocks/build/highlight-timeline-step/style-index.css new file mode 100644 index 0000000..089b72b --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/style-index.css @@ -0,0 +1,35 @@ +/*!************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline-step/style.scss ***! + \************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +.highlight-timeline-step__year { + position: relative; +} +.highlight-timeline-step__year > * { + z-index: 1; +} +.highlight-timeline-step__year .highlight-timeline-step__year-background { + position: absolute; + top: 10px; + right: 10px; + bottom: 10px; + left: 10px; + z-index: 0; + overflow: visible; +} +.highlight-timeline-step__year .highlight-timeline-step__year-background svg { + overflow: visible; + width: 100%; + height: 100%; +} +.highlight-timeline-step__year .highlight-timeline-step__year-background svg polygon { + overflow: visible; + fill: #efe8ff; + stroke: white; + stroke-width: 20px; + vector-effect: non-scaling-stroke; +} +.highlight-timeline-step__year .highlight-timeline-step__year-text { + line-height: 1 !important; +} + +/*# sourceMappingURL=style-index.css.map*/ \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/style-index.css.map b/plugins/carhop-blocks/build/highlight-timeline-step/style-index.css.map new file mode 100644 index 0000000..ee0a210 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/style-index.css.map @@ -0,0 +1 @@ +{"version":3,"file":"highlight-timeline-step/style-index.css","mappings":";;;AAAA;EACC;AACD;AACC;EACC;AACF;AACC;EACC;EACA;EACA;EACA;EACA;EACA;EACA;AACF;AACE;EACC;EACA;EACA;AACH;AACG;EACC;EACA;EACA;EACA;EACA;AACJ;AAIC;EACC;AAFF,C","sources":["webpack://carhop-blocks/./src/highlight-timeline-step/style.scss"],"sourcesContent":[".highlight-timeline-step__year {\r\n\tposition: relative;\r\n\r\n\t> * {\r\n\t\tz-index: 1;\r\n\t}\r\n\t.highlight-timeline-step__year-background {\r\n\t\tposition: absolute;\r\n\t\ttop: 10px;\r\n\t\tright: 10px;\r\n\t\tbottom: 10px;\r\n\t\tleft: 10px;\r\n\t\tz-index: 0;\r\n\t\toverflow: visible;\r\n\r\n\t\tsvg {\r\n\t\t\toverflow: visible;\r\n\t\t\twidth: 100%;\r\n\t\t\theight: 100%;\r\n\r\n\t\t\tpolygon {\r\n\t\t\t\toverflow: visible;\r\n\t\t\t\tfill: #efe8ff;\r\n\t\t\t\tstroke: white;\r\n\t\t\t\tstroke-width: 20px;\r\n\t\t\t\tvector-effect: non-scaling-stroke;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\t.highlight-timeline-step__year-text {\r\n\t\tline-height: 1 !important;\r\n\t}\r\n}\r\n"],"names":[],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/view.asset.php b/plugins/carhop-blocks/build/highlight-timeline-step/view.asset.php new file mode 100644 index 0000000..4e2f9e6 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/view.asset.php @@ -0,0 +1 @@ + array(), 'version' => 'cd52b0854d10abf915ff'); diff --git a/plugins/carhop-blocks/build/highlight-timeline-step/view.js b/plugins/carhop-blocks/build/highlight-timeline-step/view.js new file mode 100644 index 0000000..022aa93 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline-step/view.js @@ -0,0 +1,7 @@ +/******/ (() => { // webpackBootstrap +/*!*********************************************!*\ + !*** ./src/highlight-timeline-step/view.js ***! + \*********************************************/ + +/******/ })() +; \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/block.json b/plugins/carhop-blocks/build/highlight-timeline/block.json new file mode 100644 index 0000000..84ff411 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/block.json @@ -0,0 +1,20 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 3, + "name": "carhop-blocks/highlight-timeline", + "version": "0.1.0", + "title": "Highlight Timeline", + "category": "carhop-blocks", + "icon": "smiley", + "description": "Highlight Timeline pour la mise en forme d'une timeline avec des éléments en surbrillance", + "example": {}, + "supports": { + "html": false + }, + "textdomain": "highlight-timeline", + "editorScript": "file:./index.js", + "editorStyle": "file:./index.css", + "style": "file:./style-index.css", + "viewScript": "file:./view.js", + "render": "file:./render.php" +} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/index-rtl.css b/plugins/carhop-blocks/build/highlight-timeline/index-rtl.css new file mode 100644 index 0000000..80ecff1 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/index-rtl.css @@ -0,0 +1,4 @@ +/*!********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline/editor.scss ***! + \********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/highlight-timeline/index.asset.php b/plugins/carhop-blocks/build/highlight-timeline/index.asset.php new file mode 100644 index 0000000..d392218 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/index.asset.php @@ -0,0 +1 @@ + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-data', 'wp-i18n'), 'version' => 'ad1daf65e602df22d6aa'); diff --git a/plugins/carhop-blocks/build/highlight-timeline/index.css b/plugins/carhop-blocks/build/highlight-timeline/index.css new file mode 100644 index 0000000..80ecff1 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/index.css @@ -0,0 +1,4 @@ +/*!********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline/editor.scss ***! + \********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/highlight-timeline/index.js b/plugins/carhop-blocks/build/highlight-timeline/index.js new file mode 100644 index 0000000..bc7ff6e --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/index.js @@ -0,0 +1,374 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./src/highlight-timeline/block.json": +/*!*******************************************!*\ + !*** ./src/highlight-timeline/block.json ***! + \*******************************************/ +/***/ ((module) => { + +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/highlight-timeline","version":"0.1.0","title":"Highlight Timeline","category":"carhop-blocks","icon":"smiley","description":"Highlight Timeline pour la mise en forme d\'une timeline avec des éléments en surbrillance","example":{},"supports":{"html":false},"textdomain":"highlight-timeline","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js","render":"file:./render.php"}'); + +/***/ }), + +/***/ "./src/highlight-timeline/edit.js": +/*!****************************************!*\ + !*** ./src/highlight-timeline/edit.js ***! + \****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Edit) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./editor.scss */ "./src/highlight-timeline/editor.scss"); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__); + + + + + +function Edit({ + attributes, + setAttributes, + ...props +}) { + const years = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_3__.useSelect)(select => { + const { + getBlocks + } = select("core/block-editor"); + const childBlocks = getBlocks(props.clientId) || []; + return childBlocks.filter(b => b.name === "carhop-blocks/highlight-timeline-step").map(b => b.attributes?.year).filter(y => y !== undefined && y !== null && y !== ""); + }, [props.clientId]); + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsxs)("div", { + ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)({ + className: "highlight-timeline" + }), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("div", { + className: "highlight-timeline__innerblocks", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { + allowedBlocks: ["carhop-blocks/highlight-timeline-step"] + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("ul", { + className: "highlight-timeline__years", + children: years.map((y, idx) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("li", { + className: "story-timeline__year", + children: y + }, idx)) + })] + }); +} + +/***/ }), + +/***/ "./src/highlight-timeline/editor.scss": +/*!********************************************!*\ + !*** ./src/highlight-timeline/editor.scss ***! + \********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/highlight-timeline/index.js": +/*!*****************************************!*\ + !*** ./src/highlight-timeline/index.js ***! + \*****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/blocks */ "@wordpress/blocks"); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./style.scss */ "./src/highlight-timeline/style.scss"); +/* harmony import */ var _edit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./edit */ "./src/highlight-timeline/edit.js"); +/* harmony import */ var _save__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./save */ "./src/highlight-timeline/save.js"); +/* harmony import */ var _block_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./block.json */ "./src/highlight-timeline/block.json"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + +(0,_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__.registerBlockType)(_block_json__WEBPACK_IMPORTED_MODULE_4__.name, { + icon: { + src: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("svg", { + width: "32", + height: "32", + viewBox: "0 0 32 32", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("path", { + d: "M16 24L8 16L16 8L24 16L16 24Z" + }) + }) + }, + edit: _edit__WEBPACK_IMPORTED_MODULE_2__["default"], + save: _save__WEBPACK_IMPORTED_MODULE_3__["default"] +}); + +/***/ }), + +/***/ "./src/highlight-timeline/save.js": +/*!****************************************!*\ + !*** ./src/highlight-timeline/save.js ***! + \****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ save) +/* harmony export */ }); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__); + + +function save({ + attributes +}) { + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.InnerBlocks.Content, {}); +} + +/***/ }), + +/***/ "./src/highlight-timeline/style.scss": +/*!*******************************************!*\ + !*** ./src/highlight-timeline/style.scss ***! + \*******************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "@wordpress/block-editor": +/*!*************************************!*\ + !*** external ["wp","blockEditor"] ***! + \*************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blockEditor"]; + +/***/ }), + +/***/ "@wordpress/blocks": +/*!********************************!*\ + !*** external ["wp","blocks"] ***! + \********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blocks"]; + +/***/ }), + +/***/ "@wordpress/data": +/*!******************************!*\ + !*** external ["wp","data"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["data"]; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!******************************!*\ + !*** external ["wp","i18n"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["i18n"]; + +/***/ }), + +/***/ "react/jsx-runtime": +/*!**********************************!*\ + !*** external "ReactJSXRuntime" ***! + \**********************************/ +/***/ ((module) => { + +module.exports = window["ReactJSXRuntime"]; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/chunk loaded */ +/******/ (() => { +/******/ var deferred = []; +/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { +/******/ if(chunkIds) { +/******/ priority = priority || 0; +/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; +/******/ deferred[i] = [chunkIds, fn, priority]; +/******/ return; +/******/ } +/******/ var notFulfilled = Infinity; +/******/ for (var i = 0; i < deferred.length; i++) { +/******/ var [chunkIds, fn, priority] = deferred[i]; +/******/ var fulfilled = true; +/******/ for (var j = 0; j < chunkIds.length; j++) { +/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { +/******/ chunkIds.splice(j--, 1); +/******/ } else { +/******/ fulfilled = false; +/******/ if(priority < notFulfilled) notFulfilled = priority; +/******/ } +/******/ } +/******/ if(fulfilled) { +/******/ deferred.splice(i--, 1) +/******/ var r = fn(); +/******/ if (r !== undefined) result = r; +/******/ } +/******/ } +/******/ return result; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/jsonp chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded and loading chunks +/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched +/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded +/******/ var installedChunks = { +/******/ "highlight-timeline/index": 0, +/******/ "highlight-timeline/style-index": 0 +/******/ }; +/******/ +/******/ // no chunk on demand loading +/******/ +/******/ // no prefetching +/******/ +/******/ // no preloaded +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ +/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); +/******/ +/******/ // install a JSONP callback for chunk loading +/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { +/******/ var [chunkIds, moreModules, runtime] = data; +/******/ // add "moreModules" to the modules object, +/******/ // then flag all "chunkIds" as loaded and fire callback +/******/ var moduleId, chunkId, i = 0; +/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { +/******/ for(moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) var result = runtime(__webpack_require__); +/******/ } +/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); +/******/ for(;i < chunkIds.length; i++) { +/******/ chunkId = chunkIds[i]; +/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { +/******/ installedChunks[chunkId][0](); +/******/ } +/******/ installedChunks[chunkId] = 0; +/******/ } +/******/ return __webpack_require__.O(result); +/******/ } +/******/ +/******/ var chunkLoadingGlobal = globalThis["webpackChunkcarhop_blocks"] = globalThis["webpackChunkcarhop_blocks"] || []; +/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); +/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ // startup +/******/ // Load entry module and return exports +/******/ // This entry module depends on other loaded chunks and execution need to be delayed +/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["highlight-timeline/style-index"], () => (__webpack_require__("./src/highlight-timeline/index.js"))) +/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); +/******/ +/******/ })() +; +//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/index.js.map b/plugins/carhop-blocks/build/highlight-timeline/index.js.map new file mode 100644 index 0000000..154c915 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"highlight-timeline/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AAC9C;AACqB;AAAA;AAE7B,SAASQ,IAAIA,CAAC;EAAEC,UAAU;EAAEC,aAAa;EAAE,GAAGC;AAAM,CAAC,EAAE;EACrE,MAAMC,KAAK,GAAGT,0DAAS,CACrBU,MAAM,IAAK;IACX,MAAM;MAAEC;IAAU,CAAC,GAAGD,MAAM,CAAC,mBAAmB,CAAC;IACjD,MAAME,WAAW,GAAGD,SAAS,CAACH,KAAK,CAACK,QAAQ,CAAC,IAAI,EAAE;IACnD,OAAOD,WAAW,CAChBE,MAAM,CAAEC,CAAC,IAAKA,CAAC,CAACC,IAAI,KAAK,uCAAuC,CAAC,CACjEC,GAAG,CAAEF,CAAC,IAAKA,CAAC,CAACT,UAAU,EAAEY,IAAI,CAAC,CAC9BJ,MAAM,CAAEK,CAAC,IAAKA,CAAC,KAAKC,SAAS,IAAID,CAAC,KAAK,IAAI,IAAIA,CAAC,KAAK,EAAE,CAAC;EAC3D,CAAC,EACD,CAACX,KAAK,CAACK,QAAQ,CAChB,CAAC;EAED,oBACCT,uDAAA;IAAA,GACKN,sEAAa,CAAC;MACjBuB,SAAS,EAAE;IACZ,CAAC,CAAC;IAAAC,QAAA,gBAEFpB,sDAAA;MAAKmB,SAAS,EAAC,iCAAiC;MAAAC,QAAA,eAC/CpB,sDAAA,CAACH,gEAAW;QACXwB,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A,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/highlight-timeline/edit.js","webpack://carhop-blocks/./src/highlight-timeline/editor.scss","webpack://carhop-blocks/./src/highlight-timeline/index.js","webpack://carhop-blocks/./src/highlight-timeline/save.js","webpack://carhop-blocks/./src/highlight-timeline/style.scss?c818","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"data\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\nimport { useSelect } from \"@wordpress/data\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst years = useSelect(\n\t\t(select) => {\n\t\t\tconst { getBlocks } = select(\"core/block-editor\");\n\t\t\tconst childBlocks = getBlocks(props.clientId) || [];\n\t\t\treturn childBlocks\n\t\t\t\t.filter((b) => b.name === \"carhop-blocks/highlight-timeline-step\")\n\t\t\t\t.map((b) => b.attributes?.year)\n\t\t\t\t.filter((y) => y !== undefined && y !== null && y !== \"\");\n\t\t},\n\t\t[props.clientId]\n\t);\n\n\treturn (\n\t\t\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\n\t\t\t
    \n\t\t\t\t{years.map((y, idx) => (\n\t\t\t\t\t
  • \n\t\t\t\t\t\t{y}\n\t\t\t\t\t
  • \n\t\t\t\t))}\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\treturn ;\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"data\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"highlight-timeline/index\": 0,\n\t\"highlight-timeline/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"highlight-timeline/style-index\"], () => (__webpack_require__(\"./src/highlight-timeline/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","useSelect","jsx","_jsx","jsxs","_jsxs","Edit","attributes","setAttributes","props","years","select","getBlocks","childBlocks","clientId","filter","b","name","map","year","y","undefined","className","children","allowedBlocks","idx","registerBlockType","save","metadata","icon","src","width","height","viewBox","d","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/render.php b/plugins/carhop-blocks/build/highlight-timeline/render.php new file mode 100644 index 0000000..fc8a60d --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/render.php @@ -0,0 +1,33 @@ + 'highlight-timeline')); + +$years = array(); +if (isset($block) && is_object($block) && ! empty($block->inner_blocks)) { + foreach ($block->inner_blocks as $inner_block) { + if (isset($inner_block->name) && $inner_block->name === 'carhop-blocks/highlight-timeline-step') { + $y = isset($inner_block->attributes['year']) ? $inner_block->attributes['year'] : null; + if ($y !== null && $y !== '') { + $years[] = $y; + } + } + } +} +?> + +
> + +
+
+ +
+
+ +
+ +
+
+
+
+ + +
\ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/style-index-rtl.css b/plugins/carhop-blocks/build/highlight-timeline/style-index-rtl.css new file mode 100644 index 0000000..d5be5ab --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/style-index-rtl.css @@ -0,0 +1,15 @@ +/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline/style.scss ***! + \*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +.highlight-timeline__years { + width: 100%; + display: flex; + gap: 20px; +} +.highlight-timeline__years li { + color: #fff; + flex-grow: 1; + text-align: center; + list-style: none !important; + border-bottom: 1px solid #fff; +} diff --git a/plugins/carhop-blocks/build/highlight-timeline/style-index.css b/plugins/carhop-blocks/build/highlight-timeline/style-index.css new file mode 100644 index 0000000..b98dd12 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/style-index.css @@ -0,0 +1,17 @@ +/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/highlight-timeline/style.scss ***! + \*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +.highlight-timeline__years { + width: 100%; + display: flex; + gap: 20px; +} +.highlight-timeline__years li { + color: #fff; + flex-grow: 1; + text-align: center; + list-style: none !important; + border-bottom: 1px solid #fff; +} + +/*# sourceMappingURL=style-index.css.map*/ \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/style-index.css.map b/plugins/carhop-blocks/build/highlight-timeline/style-index.css.map new file mode 100644 index 0000000..b69b788 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/style-index.css.map @@ -0,0 +1 @@ +{"version":3,"file":"highlight-timeline/style-index.css","mappings":";;;AACC;EACC;EAEA;EAEA;AAFF;AAGE;EACC;EACA;EACA;EACA;EACA;AADH,C","sources":["webpack://carhop-blocks/./src/highlight-timeline/style.scss"],"sourcesContent":[".highlight-timeline {\n\t&__years {\n\t\twidth: 100%;\n\n\t\tdisplay: flex;\n\n\t\tgap: 20px;\n\t\tli {\n\t\t\tcolor: #fff;\n\t\t\tflex-grow: 1;\n\t\t\ttext-align: center;\n\t\t\tlist-style: none !important;\n\t\t\tborder-bottom: 1px solid #fff;\n\t\t}\n\t}\n}\n"],"names":[],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/view.asset.php b/plugins/carhop-blocks/build/highlight-timeline/view.asset.php new file mode 100644 index 0000000..5b3a7ee --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/view.asset.php @@ -0,0 +1 @@ + array(), 'version' => 'a09fa316f558ee9dec16'); diff --git a/plugins/carhop-blocks/build/highlight-timeline/view.js b/plugins/carhop-blocks/build/highlight-timeline/view.js new file mode 100644 index 0000000..a21f0d7 --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/view.js @@ -0,0 +1,62 @@ +/******/ (() => { // webpackBootstrap +/*!****************************************!*\ + !*** ./src/highlight-timeline/view.js ***! + \****************************************/ +function initiateSwiper() { + const currentBlock = document.querySelector(".wp-block-carhop-blocks-highlight-timeline"); + if (!currentBlock) return; + + // const swiperFraction = currentBlock.querySelector( + // ".swiper-pagination-fraction" + // ); + const slides = currentBlock.querySelectorAll(".swiper-slide"); + const slideCount = slides.length; + const years = Array.from(slides).map(slide => { + const yearEl = slide.querySelector(".highlight-timeline-step__year"); + if (yearEl && yearEl.textContent) { + return yearEl.textContent.trim(); + } + const id = slide.id || ""; + const match = id.match(/^year-(.+)$/); + return match ? match[1] : ""; + }); + highlightTimelineSwiper = new Swiper(".highlight-timeline-swiper", { + slidesPerView: 1, + spaceBetween: 30, + loop: true, + grabCursor: true, + keyboard: { + enabled: true, + onlyInViewport: true + }, + navigation: { + nextEl: ".swiper-button-next", + prevEl: ".swiper-button-prev" + }, + mousewheel: { + enabled: true, + forceToAxis: true, + // Force le scroll dans l'axe du slider + sensitivity: 1, + // Sensibilité du scroll (1 = normal) + releaseOnEdges: false // Continue le scroll même aux bords + }, + pagination: { + el: ".swiper-pagination", + clickable: true, + renderBullet: function (index, className) { + var _years$index; + return ``; + } + } + }); +} +window.addEventListener("DOMContentLoaded", event => { + initiateSwiper(); + + // swiperCheckBreakpoints(); + // window.addEventListener("resize", swiperCheckBreakpoints); +}); +/******/ })() +; +//# sourceMappingURL=view.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/highlight-timeline/view.js.map b/plugins/carhop-blocks/build/highlight-timeline/view.js.map new file mode 100644 index 0000000..bf653aa --- /dev/null +++ b/plugins/carhop-blocks/build/highlight-timeline/view.js.map @@ -0,0 +1 @@ +{"version":3,"file":"highlight-timeline/view.js","mappings":";;;;AAAA,SAASA,cAAcA,CAAA,EAAG;EACzB,MAAMC,YAAY,GAAGC,QAAQ,CAACC,aAAa,CAC1C,4CACD,CAAC;EACD,IAAI,CAACF,YAAY,EAAE;;EAEnB;EACA;EACA;EACA,MAAMG,MAAM,GAAGH,YAAY,CAACI,gBAAgB,CAAC,eAAe,CAAC;EAC7D,MAAMC,UAAU,GAAGF,MAAM,CAACG,MAAM;EAChC,MAAMC,KAAK,GAAGC,KAAK,CAACC,IAAI,CAACN,MAAM,CAAC,CAACO,GAAG,CAAEC,KAAK,IAAK;IAC/C,MAAMC,MAAM,GAAGD,KAAK,CAACT,aAAa,CAAC,gCAAgC,CAAC;IACpE,IAAIU,MAAM,IAAIA,MAAM,CAACC,WAAW,EAAE;MACjC,OAAOD,MAAM,CAACC,WAAW,CAACC,IAAI,CAAC,CAAC;IACjC;IACA,MAAMC,EAAE,GAAGJ,KAAK,CAACI,EAAE,IAAI,EAAE;IACzB,MAAMC,KAAK,GAAGD,EAAE,CAACC,KAAK,CAAC,aAAa,CAAC;IACrC,OAAOA,KAAK,GAAGA,KAAK,CAAC,CAAC,CAAC,GAAG,EAAE;EAC7B,CAAC,CAAC;EAEFC,uBAAuB,GAAG,IAAIC,MAAM,CAAC,4BAA4B,EAAE;IAClEC,aAAa,EAAE,CAAC;IAChBC,YAAY,EAAE,EAAE;IAChBC,IAAI,EAAE,IAAI;IACVC,UAAU,EAAE,IAAI;IAChBC,QAAQ,EAAE;MACTC,OAAO,EAAE,IAAI;MACbC,cAAc,EAAE;IACjB,CAAC;IACDC,UAAU,EAAE;MACXC,MAAM,EAAE,qBAAqB;MAC7BC,MAAM,EAAE;IACT,CAAC;IACDC,UAAU,EAAE;MACXL,OAAO,EAAE,IAAI;MACbM,WAAW,EAAE,IAAI;MAAE;MACnBC,WAAW,EAAE,CAAC;MAAE;MAChBC,cAAc,EAAE,KAAK,CAAE;IACxB,CAAC;IACDC,UAAU,EAAE;MACXC,EAAE,EAAE,oBAAoB;MACxBC,SAAS,EAAE,IAAI;MACfC,YAAY,EAAE,SAAAA,CAAUC,KAAK,EAAEC,SAAS,EAAE;QAAA,IAAAC,YAAA;QACzC,OAAO,kBAAkBD,SAAS,MAAAC,YAAA,GAAKhC,KAAK,CAAC8B,KAAK,CAAC,cAAAE,YAAA,cAAAA,YAAA,GAAI,EAAE,WAAW;MACrE;IACD;EACD,CAAC,CAAC;AACH;AAEAC,MAAM,CAACC,gBAAgB,CAAC,kBAAkB,EAAGC,KAAK,IAAK;EACtD3C,cAAc,CAAC,CAAC;;EAEhB;EACA;AACD,CAAC,CAAC,C","sources":["webpack://carhop-blocks/./src/highlight-timeline/view.js"],"sourcesContent":["function initiateSwiper() {\n\tconst currentBlock = document.querySelector(\n\t\t\".wp-block-carhop-blocks-highlight-timeline\"\n\t);\n\tif (!currentBlock) return;\n\n\t// const swiperFraction = currentBlock.querySelector(\n\t// \t\".swiper-pagination-fraction\"\n\t// );\n\tconst slides = currentBlock.querySelectorAll(\".swiper-slide\");\n\tconst slideCount = slides.length;\n\tconst years = Array.from(slides).map((slide) => {\n\t\tconst yearEl = slide.querySelector(\".highlight-timeline-step__year\");\n\t\tif (yearEl && yearEl.textContent) {\n\t\t\treturn yearEl.textContent.trim();\n\t\t}\n\t\tconst id = slide.id || \"\";\n\t\tconst match = id.match(/^year-(.+)$/);\n\t\treturn match ? match[1] : \"\";\n\t});\n\n\thighlightTimelineSwiper = new Swiper(\".highlight-timeline-swiper\", {\n\t\tslidesPerView: 1,\n\t\tspaceBetween: 30,\n\t\tloop: true,\n\t\tgrabCursor: true,\n\t\tkeyboard: {\n\t\t\tenabled: true,\n\t\t\tonlyInViewport: true,\n\t\t},\n\t\tnavigation: {\n\t\t\tnextEl: \".swiper-button-next\",\n\t\t\tprevEl: \".swiper-button-prev\",\n\t\t},\n\t\tmousewheel: {\n\t\t\tenabled: true,\n\t\t\tforceToAxis: true, // Force le scroll dans l'axe du slider\n\t\t\tsensitivity: 1, // Sensibilité du scroll (1 = normal)\n\t\t\treleaseOnEdges: false, // Continue le scroll même aux bords\n\t\t},\n\t\tpagination: {\n\t\t\tel: \".swiper-pagination\",\n\t\t\tclickable: true,\n\t\t\trenderBullet: function (index, className) {\n\t\t\t\treturn ``;\n\t\t\t},\n\t\t},\n\t});\n}\n\nwindow.addEventListener(\"DOMContentLoaded\", (event) => {\n\tinitiateSwiper();\n\n\t// swiperCheckBreakpoints();\n\t// window.addEventListener(\"resize\", swiperCheckBreakpoints);\n});\n"],"names":["initiateSwiper","currentBlock","document","querySelector","slides","querySelectorAll","slideCount","length","years","Array","from","map","slide","yearEl","textContent","trim","id","match","highlightTimelineSwiper","Swiper","slidesPerView","spaceBetween","loop","grabCursor","keyboard","enabled","onlyInViewport","navigation","nextEl","prevEl","mousewheel","forceToAxis","sensitivity","releaseOnEdges","pagination","el","clickable","renderBullet","index","className","_years$index","window","addEventListener","event"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/block.json b/plugins/carhop-blocks/build/image-stack/block.json new file mode 100644 index 0000000..175ac23 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/block.json @@ -0,0 +1,65 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 3, + "name": "carhop-blocks/image-stack", + "version": "0.1.0", + "title": "Image Stack (Focal Point)", + "category": "carhop-blocks", + "icon": "images-alt2", + "description": "Layer multiple images with individual focal point positioning.", + "example": { + "attributes": { + "images": [ + { + "id": 1, + "url": "https://images.unsplash.com/photo-1506905925346-21bda4d32df4", + "alt": "Mountain landscape", + "focalPoint": { + "x": 0.5, + "y": 0.3 + }, + "scale": 0.8 + }, + { + "id": 2, + "url": "https://images.unsplash.com/photo-1511884642898-4c92249e20b6", + "alt": "Forest scene", + "focalPoint": { + "x": 0.7, + "y": 0.6 + }, + "scale": 0.6 + } + ], + "height": 400 + } + }, + "attributes": { + "images": { + "type": "array", + "default": [], + "items": { + "type": "object" + } + }, + "height": { + "type": "number", + "default": 400 + } + }, + "supports": { + "html": false, + "align": [ + "wide", + "full" + ], + "spacing": { + "margin": true, + "padding": true + } + }, + "textdomain": "image-stack", + "editorScript": "file:./index.js", + "editorStyle": "file:./index.css", + "style": "file:./style-index.css" +} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/index-rtl.css b/plugins/carhop-blocks/build/image-stack/index-rtl.css new file mode 100644 index 0000000..cb28655 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/index-rtl.css @@ -0,0 +1,51 @@ +/*!*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/image-stack/editor.scss ***! + \*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied inside the editor only. + */ +.wp-block-carhop-blocks-image-stack { + overflow: visible; +} +.wp-block-carhop-blocks-image-stack .image-stack-placeholder { + display: flex; + align-items: center; + justify-content: center; + width: 100%; + height: 100%; + background-color: rgba(240, 240, 240, 0.5); + background-color: red; + border: 2px dashed #ccc; +} +.wp-block-carhop-blocks-image-stack .image-stack-item { + cursor: pointer; + transition: opacity 0.2s ease; +} +.wp-block-carhop-blocks-image-stack .image-stack-item:hover { + opacity: 0.9; +} +.wp-block-carhop-blocks-image-stack .image-stack-item.is-selected { + outline: 3px solid #007cba; + outline-offset: -3px; + z-index: 10; +} +.image-stack-image-preview { + margin-bottom: 16px; +} +.image-stack-image-preview img { + width: 100%; + height: auto; + display: block; + border-radius: 4px; +} +.image-stack-image-controls { + display: flex; + gap: 8px; + margin-top: 16px; + flex-wrap: wrap; +} +.image-stack-image-controls .components-button { + flex: 1; + min-width: 80px; + justify-content: center; +} diff --git a/plugins/carhop-blocks/build/image-stack/index.asset.php b/plugins/carhop-blocks/build/image-stack/index.asset.php new file mode 100644 index 0000000..08720bd --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/index.asset.php @@ -0,0 +1 @@ + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n'), 'version' => '1eef85ae6d9945df487a'); diff --git a/plugins/carhop-blocks/build/image-stack/index.css b/plugins/carhop-blocks/build/image-stack/index.css new file mode 100644 index 0000000..4bc8374 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/index.css @@ -0,0 +1,53 @@ +/*!*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/image-stack/editor.scss ***! + \*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied inside the editor only. + */ +.wp-block-carhop-blocks-image-stack { + overflow: visible; +} +.wp-block-carhop-blocks-image-stack .image-stack-placeholder { + display: flex; + align-items: center; + justify-content: center; + width: 100%; + height: 100%; + background-color: rgba(240, 240, 240, 0.5); + background-color: red; + border: 2px dashed #ccc; +} +.wp-block-carhop-blocks-image-stack .image-stack-item { + cursor: pointer; + transition: opacity 0.2s ease; +} +.wp-block-carhop-blocks-image-stack .image-stack-item:hover { + opacity: 0.9; +} +.wp-block-carhop-blocks-image-stack .image-stack-item.is-selected { + outline: 3px solid #007cba; + outline-offset: -3px; + z-index: 10; +} +.image-stack-image-preview { + margin-bottom: 16px; +} +.image-stack-image-preview img { + width: 100%; + height: auto; + display: block; + border-radius: 4px; +} +.image-stack-image-controls { + display: flex; + gap: 8px; + margin-top: 16px; + flex-wrap: wrap; +} +.image-stack-image-controls .components-button { + flex: 1; + min-width: 80px; + justify-content: center; +} + +/*# sourceMappingURL=index.css.map*/ \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/index.css.map b/plugins/carhop-blocks/build/image-stack/index.css.map new file mode 100644 index 0000000..43802eb --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/index.css.map @@ -0,0 +1 @@ +{"version":3,"file":"image-stack/index.css","mappings":";;;AAAA;;EAAA;AAIA;EACC;AAAD;AACC;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;AACF;AAEC;EACC;EACA;AAAF;AAEE;EACC;AAAH;AAGE;EACC;EACA;EACA;AADH;AAMA;EACC;AAHD;AAKC;EACC;EACA;EACA;EACA;AAHF;AAOA;EACC;EACA;EACA;EACA;AAJD;AAMC;EACC;EACA;EACA;AAJF,C","sources":["webpack://carhop-blocks/./src/image-stack/editor.scss"],"sourcesContent":["/**\n * The following styles get applied inside the editor only.\n */\n\n.wp-block-carhop-blocks-image-stack {\n\toverflow: visible;\n\t.image-stack-placeholder {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tjustify-content: center;\n\t\twidth: 100%;\n\t\theight: 100%;\n\t\tbackground-color: rgba(240, 240, 240, 0.5);\n\t\tbackground-color: red;\n\t\tborder: 2px dashed #ccc;\n\t}\n\n\t.image-stack-item {\n\t\tcursor: pointer;\n\t\ttransition: opacity 0.2s ease;\n\n\t\t&:hover {\n\t\t\topacity: 0.9;\n\t\t}\n\n\t\t&.is-selected {\n\t\t\toutline: 3px solid #007cba;\n\t\t\toutline-offset: -3px;\n\t\t\tz-index: 10;\n\t\t}\n\t}\n}\n\n.image-stack-image-preview {\n\tmargin-bottom: 16px;\n\n\timg {\n\t\twidth: 100%;\n\t\theight: auto;\n\t\tdisplay: block;\n\t\tborder-radius: 4px;\n\t}\n}\n\n.image-stack-image-controls {\n\tdisplay: flex;\n\tgap: 8px;\n\tmargin-top: 16px;\n\tflex-wrap: wrap;\n\n\t.components-button {\n\t\tflex: 1;\n\t\tmin-width: 80px;\n\t\tjustify-content: center;\n\t}\n}\n"],"names":[],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/index.js b/plugins/carhop-blocks/build/image-stack/index.js new file mode 100644 index 0000000..fe8e1f8 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/index.js @@ -0,0 +1,602 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./src/image-stack/block.json": +/*!************************************!*\ + !*** ./src/image-stack/block.json ***! + \************************************/ +/***/ ((module) => { + +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/image-stack","version":"0.1.0","title":"Image Stack (Focal Point)","category":"carhop-blocks","icon":"images-alt2","description":"Layer multiple images with individual focal point positioning.","example":{"attributes":{"images":[{"id":1,"url":"https://images.unsplash.com/photo-1506905925346-21bda4d32df4","alt":"Mountain landscape","focalPoint":{"x":0.5,"y":0.3},"scale":0.8},{"id":2,"url":"https://images.unsplash.com/photo-1511884642898-4c92249e20b6","alt":"Forest scene","focalPoint":{"x":0.7,"y":0.6},"scale":0.6}],"height":400}},"attributes":{"images":{"type":"array","default":[],"items":{"type":"object"}},"height":{"type":"number","default":400}},"supports":{"html":false,"align":["wide","full"],"spacing":{"margin":true,"padding":true}},"textdomain":"image-stack","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css"}'); + +/***/ }), + +/***/ "./src/image-stack/edit.js": +/*!*********************************!*\ + !*** ./src/image-stack/edit.js ***! + \*********************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Edit) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/element */ "@wordpress/element"); +/* harmony import */ var _wordpress_element__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_element__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./editor.scss */ "./src/image-stack/editor.scss"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + + +function Edit({ + attributes, + setAttributes +}) { + const { + images, + height + } = attributes; + const [selectedImageIndex, setSelectedImageIndex] = (0,_wordpress_element__WEBPACK_IMPORTED_MODULE_3__.useState)(null); + const blockProps = (0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)(); + const onSelectImages = media => { + const newImages = media.map(img => ({ + id: img.id, + url: img.url, + alt: img.alt || "", + focalPoint: { + x: 0.5, + y: 0.5 + }, + scale: 0.8, + rotation: 0 + })); + setAttributes({ + images: [...images, ...newImages] + }); + }; + const updateImageFocalPoint = (index, focalPoint) => { + const newImages = [...images]; + newImages[index] = { + ...newImages[index], + focalPoint + }; + setAttributes({ + images: newImages + }); + }; + const updateImageScale = (index, scale) => { + const newImages = [...images]; + newImages[index] = { + ...newImages[index], + scale + }; + setAttributes({ + images: newImages + }); + }; + const updateImageRotation = (index, rotation) => { + const newImages = [...images]; + newImages[index] = { + ...newImages[index], + rotation + }; + setAttributes({ + images: newImages + }); + }; + const removeImage = index => { + const newImages = images.filter((_, i) => i !== index); + setAttributes({ + images: newImages + }); + if (selectedImageIndex === index) { + setSelectedImageIndex(null); + } + }; + const moveImage = (index, direction) => { + const newImages = [...images]; + const newIndex = index + direction; + if (newIndex >= 0 && newIndex < images.length) { + [newImages[index], newImages[newIndex]] = [newImages[newIndex], newImages[index]]; + setAttributes({ + images: newImages + }); + setSelectedImageIndex(newIndex); + } + }; + const getImageStyle = image => { + const focalPoint = image.focalPoint || { + x: 0.5, + y: 0.5 + }; + const scale = image.scale || 0.8; + const rotation = image.rotation || 0; + return { + left: `${focalPoint.x * 100}%`, + top: `${focalPoint.y * 100}%`, + transform: ` rotate(${rotation}deg) scale(${scale})` + }; + }; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.Fragment, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.BlockControls, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.ToolbarGroup, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.MediaUploadCheck, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.MediaUpload, { + onSelect: onSelectImages, + allowedTypes: ["image"], + multiple: true, + gallery: true, + value: images.map(img => img.id), + render: ({ + open + }) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.ToolbarButton, { + onClick: open, + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Add Images", "image-stack") + }) + }) + }) + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InspectorControls, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.PanelBody, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Container Settings", "image-stack"), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.RangeControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Container Height", "image-stack"), + value: height, + onChange: value => setAttributes({ + height: value + }), + min: 200, + max: 800, + step: 10 + }) + }), images.length > 0 && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.PanelBody, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Images", "image-stack"), + initialOpen: true, + children: images.map((image, index) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.PanelBody, { + title: `${(0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Image", "image-stack")} ${index + 1}`, + initialOpen: selectedImageIndex === index, + onToggle: () => setSelectedImageIndex(selectedImageIndex === index ? null : index), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "image-stack-image-preview", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("img", { + src: image.url, + alt: image.alt + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.FocalPointPicker, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Focal Point", "image-stack"), + url: image.url, + value: image.focalPoint || { + x: 0.5, + y: 0.5 + }, + onChange: focalPoint => updateImageFocalPoint(index, focalPoint) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.RangeControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Scale", "image-stack"), + value: image.scale || 0.8, + onChange: scale => updateImageScale(index, scale), + min: 0.1, + max: 3, + step: 0.05 + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.RangeControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Rotation (deg)", "image-stack"), + value: image.rotation || 0, + onChange: rotation => updateImageRotation(index, rotation), + min: -180, + max: 180, + step: 1 + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "image-stack-image-controls", + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isSecondary: true, + isSmall: true, + disabled: index === 0, + onClick: () => moveImage(index, -1), + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("↑ Move Up", "image-stack") + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isSecondary: true, + isSmall: true, + disabled: index === images.length - 1, + onClick: () => moveImage(index, 1), + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("↓ Move Down", "image-stack") + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + isDestructive: true, + isSmall: true, + onClick: () => removeImage(index), + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Remove", "image-stack") + })] + })] + }, image.id)) + })] + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + ...blockProps, + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsxs)("div", { + className: "image-stack-container", + style: { + height: `${height}px` + }, + children: [images.length === 0 && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: "image-stack-placeholder", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.MediaUploadCheck, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.MediaUpload, { + onSelect: onSelectImages, + allowedTypes: ["image"], + multiple: true, + gallery: true, + render: ({ + open + }) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.Button, { + variant: "primary", + onClick: open, + children: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Ajouter une Image", "image-stack") + }) + }) + }) + }), images.map((image, index) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("div", { + className: `image-stack-item ${selectedImageIndex === index ? "is-selected" : ""}`, + onClick: () => setSelectedImageIndex(index), + role: "button", + tabIndex: 0, + onKeyDown: e => { + if (e.key === "Enter" || e.key === " ") { + setSelectedImageIndex(index); + } + }, + style: getImageStyle(image), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("img", { + src: image.url, + alt: image.alt + }) + }, image.id))] + }) + })] + }); +} + +/***/ }), + +/***/ "./src/image-stack/editor.scss": +/*!*************************************!*\ + !*** ./src/image-stack/editor.scss ***! + \*************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/image-stack/index.js": +/*!**********************************!*\ + !*** ./src/image-stack/index.js ***! + \**********************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/blocks */ "@wordpress/blocks"); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./style.scss */ "./src/image-stack/style.scss"); +/* harmony import */ var _edit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./edit */ "./src/image-stack/edit.js"); +/* harmony import */ var _save__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./save */ "./src/image-stack/save.js"); +/* harmony import */ var _block_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./block.json */ "./src/image-stack/block.json"); + + + + + +(0,_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__.registerBlockType)(_block_json__WEBPACK_IMPORTED_MODULE_4__.name, { + edit: _edit__WEBPACK_IMPORTED_MODULE_2__["default"], + save: _save__WEBPACK_IMPORTED_MODULE_3__["default"] +}); + +/***/ }), + +/***/ "./src/image-stack/save.js": +/*!*********************************!*\ + !*** ./src/image-stack/save.js ***! + \*********************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ save) +/* harmony export */ }); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__); + + +function save({ + attributes +}) { + const { + images, + height + } = attributes; + const blockProps = _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save(); + const getImageStyle = image => { + const focalPoint = image.focalPoint || { + x: 0.5, + y: 0.5 + }; + const scale = image.scale || 0.8; + const rotation = image.rotation || 0; + return { + left: `${focalPoint.x * 100}%`, + top: `${focalPoint.y * 100}%`, + transform: `rotate(${rotation}deg) scale(${scale})` + }; + }; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + ...blockProps, + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "image-stack-container", + style: { + height: `${height}px` + }, + children: images.map(image => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "image-stack-item", + style: getImageStyle(image), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("img", { + src: image.url, + alt: image.alt + }) + }, image.id)) + }) + }); +} + +/***/ }), + +/***/ "./src/image-stack/style.scss": +/*!************************************!*\ + !*** ./src/image-stack/style.scss ***! + \************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "@wordpress/block-editor": +/*!*************************************!*\ + !*** external ["wp","blockEditor"] ***! + \*************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blockEditor"]; + +/***/ }), + +/***/ "@wordpress/blocks": +/*!********************************!*\ + !*** external ["wp","blocks"] ***! + \********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blocks"]; + +/***/ }), + +/***/ "@wordpress/components": +/*!************************************!*\ + !*** external ["wp","components"] ***! + \************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["components"]; + +/***/ }), + +/***/ "@wordpress/element": +/*!*********************************!*\ + !*** external ["wp","element"] ***! + \*********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["element"]; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!******************************!*\ + !*** external ["wp","i18n"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["i18n"]; + +/***/ }), + +/***/ "react/jsx-runtime": +/*!**********************************!*\ + !*** external "ReactJSXRuntime" ***! + \**********************************/ +/***/ ((module) => { + +module.exports = window["ReactJSXRuntime"]; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/chunk loaded */ +/******/ (() => { +/******/ var deferred = []; +/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { +/******/ if(chunkIds) { +/******/ priority = priority || 0; +/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; +/******/ deferred[i] = [chunkIds, fn, priority]; +/******/ return; +/******/ } +/******/ var notFulfilled = Infinity; +/******/ for (var i = 0; i < deferred.length; i++) { +/******/ var [chunkIds, fn, priority] = deferred[i]; +/******/ var fulfilled = true; +/******/ for (var j = 0; j < chunkIds.length; j++) { +/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { +/******/ chunkIds.splice(j--, 1); +/******/ } else { +/******/ fulfilled = false; +/******/ if(priority < notFulfilled) notFulfilled = priority; +/******/ } +/******/ } +/******/ if(fulfilled) { +/******/ deferred.splice(i--, 1) +/******/ var r = fn(); +/******/ if (r !== undefined) result = r; +/******/ } +/******/ } +/******/ return result; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/jsonp chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded and loading chunks +/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched +/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded +/******/ var installedChunks = { +/******/ "image-stack/index": 0, +/******/ "image-stack/style-index": 0 +/******/ }; +/******/ +/******/ // no chunk on demand loading +/******/ +/******/ // no prefetching +/******/ +/******/ // no preloaded +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ +/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); +/******/ +/******/ // install a JSONP callback for chunk loading +/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { +/******/ var [chunkIds, moreModules, runtime] = data; +/******/ // add "moreModules" to the modules object, +/******/ // then flag all "chunkIds" as loaded and fire callback +/******/ var moduleId, chunkId, i = 0; +/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { +/******/ for(moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) var result = runtime(__webpack_require__); +/******/ } +/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); +/******/ for(;i < chunkIds.length; i++) { +/******/ chunkId = chunkIds[i]; +/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { +/******/ installedChunks[chunkId][0](); +/******/ } +/******/ installedChunks[chunkId] = 0; +/******/ } +/******/ return __webpack_require__.O(result); +/******/ } +/******/ +/******/ var chunkLoadingGlobal = globalThis["webpackChunkcarhop_blocks"] = globalThis["webpackChunkcarhop_blocks"] || []; +/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); +/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ // startup +/******/ // Load entry module and return exports +/******/ // This entry module depends on other loaded chunks and execution need to be delayed +/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["image-stack/style-index"], () => (__webpack_require__("./src/image-stack/index.js"))) +/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); +/******/ +/******/ })() +; +//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/index.js.map b/plugins/carhop-blocks/build/image-stack/index.js.map new file mode 100644 index 0000000..826f716 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"image-stack/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AAMJ;AAQF;AACyB;AACV;AAEvB;AAAA;AAER,SAASmB,IAAIA,CAAC;EAAEC,UAAU;EAAEC;AAAc,CAAC,EAAE;EAC3D,MAAM;IAAEC,MAAM;IAAEC;EAAO,CAAC,GAAGH,UAAU;EACrC,MAAM,CAACI,kBAAkB,EAAEC,qBAAqB,CAAC,GAAGb,4DAAQ,CAAC,IAAI,CAAC;EAElE,MAAMc,UAAU,GAAGzB,sEAAa,CAAC,CAAC;EAElC,M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sDAAA;QAEC4D,SAAS,EAAC,kBAAkB;QAC5BM,KAAK,EAAE5B,aAAa,CAACC,KAAK,CAAE;QAAAI,QAAA,eAE5B3C,sDAAA;UAAK6D,GAAG,EAAEtB,KAAK,CAACpB,GAAI;UAACC,GAAG,EAAEmB,KAAK,CAACnB;QAAI,CAAE;MAAC,GAJlCmB,KAAK,CAACrB,EAKP,CACL;IAAC,CACE;EAAC,CACF,CAAC;AAER,C;;;;;;;;;;;AChCA;;;;;;;;;;;ACAA,6C;;;;;;;;;;ACAA,wC;;;;;;;;;;ACAA,4C;;;;;;;;;;ACAA,yC;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,2C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/image-stack/edit.js","webpack://carhop-blocks/./src/image-stack/editor.scss?5c70","webpack://carhop-blocks/./src/image-stack/index.js","webpack://carhop-blocks/./src/image-stack/save.js","webpack://carhop-blocks/./src/image-stack/style.scss?0ea7","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"element\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport {\n\tuseBlockProps,\n\tInspectorControls,\n\tMediaUpload,\n\tMediaUploadCheck,\n} from \"@wordpress/block-editor\";\nimport {\n\tPanelBody,\n\tButton,\n\tFocalPointPicker,\n\tRangeControl,\n\tToolbarGroup,\n\tToolbarButton,\n} from \"@wordpress/components\";\nimport { BlockControls } from \"@wordpress/block-editor\";\nimport { useState } from \"@wordpress/element\";\n\nimport \"./editor.scss\";\n\nexport default function Edit({ attributes, setAttributes }) {\n\tconst { images, height } = attributes;\n\tconst [selectedImageIndex, setSelectedImageIndex] = useState(null);\n\n\tconst blockProps = useBlockProps();\n\n\tconst onSelectImages = (media) => {\n\t\tconst newImages = media.map((img) => ({\n\t\t\tid: img.id,\n\t\t\turl: img.url,\n\t\t\talt: img.alt || \"\",\n\t\t\tfocalPoint: { x: 0.5, y: 0.5 },\n\t\t\tscale: 0.8,\n\t\t\trotation: 0,\n\t\t}));\n\t\tsetAttributes({ images: [...images, ...newImages] });\n\t};\n\n\tconst updateImageFocalPoint = (index, focalPoint) => {\n\t\tconst newImages = [...images];\n\t\tnewImages[index] = { ...newImages[index], focalPoint };\n\t\tsetAttributes({ images: newImages });\n\t};\n\n\tconst updateImageScale = (index, scale) => {\n\t\tconst newImages = [...images];\n\t\tnewImages[index] = { ...newImages[index], scale };\n\t\tsetAttributes({ images: newImages });\n\t};\n\n\tconst updateImageRotation = (index, rotation) => {\n\t\tconst newImages = [...images];\n\t\tnewImages[index] = { ...newImages[index], rotation };\n\t\tsetAttributes({ images: newImages });\n\t};\n\n\tconst removeImage = (index) => {\n\t\tconst newImages = images.filter((_, i) => i !== index);\n\t\tsetAttributes({ images: newImages });\n\t\tif (selectedImageIndex === index) {\n\t\t\tsetSelectedImageIndex(null);\n\t\t}\n\t};\n\n\tconst moveImage = (index, direction) => {\n\t\tconst newImages = [...images];\n\t\tconst newIndex = index + direction;\n\t\tif (newIndex >= 0 && newIndex < images.length) {\n\t\t\t[newImages[index], newImages[newIndex]] = [\n\t\t\t\tnewImages[newIndex],\n\t\t\t\tnewImages[index],\n\t\t\t];\n\t\t\tsetAttributes({ images: newImages });\n\t\t\tsetSelectedImageIndex(newIndex);\n\t\t}\n\t};\n\n\tconst getImageStyle = (image) => {\n\t\tconst focalPoint = image.focalPoint || { x: 0.5, y: 0.5 };\n\t\tconst scale = image.scale || 0.8;\n\t\tconst rotation = image.rotation || 0;\n\t\treturn {\n\t\t\tleft: `${focalPoint.x * 100}%`,\n\t\t\ttop: `${focalPoint.y * 100}%`,\n\t\t\ttransform: ` rotate(${rotation}deg) scale(${scale})`,\n\t\t};\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t img.id)}\n\t\t\t\t\t\t\trender={({ open }) => (\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t{__(\"Add Images\", \"image-stack\")}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t setAttributes({ height: value })}\n\t\t\t\t\t\tmin={200}\n\t\t\t\t\t\tmax={800}\n\t\t\t\t\t\tstep={10}\n\t\t\t\t\t/>\n\t\t\t\t\n\n\t\t\t\t{images.length > 0 && (\n\t\t\t\t\t\n\t\t\t\t\t\t{images.map((image, index) => (\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tsetSelectedImageIndex(\n\t\t\t\t\t\t\t\t\t\tselectedImageIndex === index ? null : index\n\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t{image.alt}\n\t\t\t\t\t\t\t\t
\n\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tupdateImageFocalPoint(index, focalPoint)\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t\t updateImageScale(index, scale)}\n\t\t\t\t\t\t\t\t\tmin={0.1}\n\t\t\t\t\t\t\t\t\tmax={3}\n\t\t\t\t\t\t\t\t\tstep={0.05}\n\t\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t\t updateImageRotation(index, rotation)}\n\t\t\t\t\t\t\t\t\tmin={-180}\n\t\t\t\t\t\t\t\t\tmax={180}\n\t\t\t\t\t\t\t\t\tstep={1}\n\t\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t moveImage(index, -1)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{__(\"↑ Move Up\", \"image-stack\")}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t moveImage(index, 1)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{__(\"↓ Move Down\", \"image-stack\")}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t removeImage(index)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{__(\"Remove\", \"image-stack\")}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t))}\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t
\n\n\t\t\t
\n\t\t\t\t\n\t\t\t\t\t{images.length === 0 && (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t (\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\n\t\t\t\t\t{images.map((image, index) => (\n\t\t\t\t\t\t setSelectedImageIndex(index)}\n\t\t\t\t\t\t\trole=\"button\"\n\t\t\t\t\t\t\ttabIndex={0}\n\t\t\t\t\t\t\tonKeyDown={(e) => {\n\t\t\t\t\t\t\t\tif (e.key === \"Enter\" || e.key === \" \") {\n\t\t\t\t\t\t\t\t\tsetSelectedImageIndex(index);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\tstyle={getImageStyle(image)}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{image.alt}\n\t\t\t\t\t\t
\n\t\t\t\t\t))}\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst { images, height } = attributes;\n\tconst blockProps = useBlockProps.save();\n\n\tconst getImageStyle = (image) => {\n\t\tconst focalPoint = image.focalPoint || { x: 0.5, y: 0.5 };\n\t\tconst scale = image.scale || 0.8;\n\t\tconst rotation = image.rotation || 0;\n\t\treturn {\n\t\t\tleft: `${focalPoint.x * 100}%`,\n\t\t\ttop: `${focalPoint.y * 100}%`,\n\t\t\ttransform: `rotate(${rotation}deg) scale(${scale})`,\n\t\t};\n\t};\n\n\treturn (\n\t\t
\n\t\t\t
\n\t\t\t\t{images.map((image) => (\n\t\t\t\t\t\n\t\t\t\t\t\t{image.alt}\n\t\t\t\t\t
\n\t\t\t\t))}\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"element\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"image-stack/index\": 0,\n\t\"image-stack/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"image-stack/style-index\"], () => (__webpack_require__(\"./src/image-stack/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InspectorControls","MediaUpload","MediaUploadCheck","PanelBody","Button","FocalPointPicker","RangeControl","ToolbarGroup","ToolbarButton","BlockControls","useState","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","images","height","selectedImageIndex","setSelectedImageIndex","blockProps","onSelectImages","media","newImages","map","img","id","url","alt","focalPoint","x","y","scale","rotation","updateImageFocalPoint","index","updateImageScale","updateImageRotation","removeImage","filter","_","i","moveImage","direction","newIndex","length","getImageStyle","image","left","top","transform","children","onSelect","allowedTypes","multiple","gallery","value","render","open","onClick","title","label","onChange","min","max","step","initialOpen","onToggle","className","src","isSecondary","isSmall","disabled","isDestructive","style","variant","role","tabIndex","onKeyDown","e","key","registerBlockType","save","metadata","name","edit"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/style-index-rtl.css b/plugins/carhop-blocks/build/image-stack/style-index-rtl.css new file mode 100644 index 0000000..e234a11 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/style-index-rtl.css @@ -0,0 +1,22 @@ +/*!************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/image-stack/style.scss ***! + \************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied both on the front of your site + * and in the editor. + */ +.wp-block-carhop-blocks-image-stack .image-stack-container { + position: relative; + width: 100%; + overflow: visible; +} +.wp-block-carhop-blocks-image-stack .image-stack-item { + position: absolute; +} +.wp-block-carhop-blocks-image-stack .image-stack-item img { + width: 100%; + height: 100%; + -o-object-fit: contain; + object-fit: contain; + display: block; +} diff --git a/plugins/carhop-blocks/build/image-stack/style-index.css b/plugins/carhop-blocks/build/image-stack/style-index.css new file mode 100644 index 0000000..4b955ff --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/style-index.css @@ -0,0 +1,24 @@ +/*!************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/image-stack/style.scss ***! + \************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ +/** + * The following styles get applied both on the front of your site + * and in the editor. + */ +.wp-block-carhop-blocks-image-stack .image-stack-container { + position: relative; + width: 100%; + overflow: visible; +} +.wp-block-carhop-blocks-image-stack .image-stack-item { + position: absolute; +} +.wp-block-carhop-blocks-image-stack .image-stack-item img { + width: 100%; + height: 100%; + -o-object-fit: contain; + object-fit: contain; + display: block; +} + +/*# sourceMappingURL=style-index.css.map*/ \ No newline at end of file diff --git a/plugins/carhop-blocks/build/image-stack/style-index.css.map b/plugins/carhop-blocks/build/image-stack/style-index.css.map new file mode 100644 index 0000000..5512a86 --- /dev/null +++ b/plugins/carhop-blocks/build/image-stack/style-index.css.map @@ -0,0 +1 @@ +{"version":3,"file":"image-stack/style-index.css","mappings":";;;AAAA;;;EAAA;AAMC;EACC;EACA;EACA;AADF;AAIC;EACC;AAFF;AAIE;EACC;EACA;EACA;KAAA;EACA;AAFH,C","sources":["webpack://carhop-blocks/./src/image-stack/style.scss"],"sourcesContent":["/**\n * The following styles get applied both on the front of your site\n * and in the editor.\n */\n\n.wp-block-carhop-blocks-image-stack {\n\t.image-stack-container {\n\t\tposition: relative;\n\t\twidth: 100%;\n\t\toverflow: visible;\n\t}\n\n\t.image-stack-item {\n\t\tposition: absolute;\n\n\t\timg {\n\t\t\twidth: 100%;\n\t\t\theight: 100%;\n\t\t\tobject-fit: contain;\n\t\t\tdisplay: block;\n\t\t}\n\t}\n}\n"],"names":[],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/narrative-card/block.json b/plugins/carhop-blocks/build/narrative-card/block.json index d7c13da..61f238a 100644 --- a/plugins/carhop-blocks/build/narrative-card/block.json +++ b/plugins/carhop-blocks/build/narrative-card/block.json @@ -21,6 +21,22 @@ "type": "boolean", "default": true }, + "aspectRatio": { + "type": "string", + "default": "auto", + "enum": [ + "auto", + "1/1", + "4/3", + "3/4", + "3/2", + "2/3", + "16/9", + "21/9", + "9/16", + "9/21" + ] + }, "coverPosition": { "type": "string", "default": "right", diff --git a/plugins/carhop-blocks/build/narrative-card/index.asset.php b/plugins/carhop-blocks/build/narrative-card/index.asset.php index 0c8697f..a5cbf02 100644 --- a/plugins/carhop-blocks/build/narrative-card/index.asset.php +++ b/plugins/carhop-blocks/build/narrative-card/index.asset.php @@ -1 +1 @@ - array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n', 'wp-primitives'), 'version' => '7c033a4fa34fcba29f78'); + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n', 'wp-primitives'), 'version' => 'e27954a03e2ef2284b17'); diff --git a/plugins/carhop-blocks/build/narrative-card/index.js b/plugins/carhop-blocks/build/narrative-card/index.js index 2285ac8..baedcd3 100644 --- a/plugins/carhop-blocks/build/narrative-card/index.js +++ b/plugins/carhop-blocks/build/narrative-card/index.js @@ -52,10 +52,12 @@ __webpack_require__.r(__webpack_exports__); function Cover({ coverUrl, coverAlt, - onSelect + onSelect, + aspectRatio }) { + const ratioClass = aspectRatio && aspectRatio !== "auto" ? ` narrative-card__cover--ratio-${String(aspectRatio).replace(/[/:]/g, "-")}` : ""; return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { - className: "narrative-card__cover", + className: `narrative-card__cover${ratioClass}`, children: [coverUrl && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("img", { src: coverUrl, alt: coverAlt @@ -77,7 +79,7 @@ function Cover({ \***************************************/ /***/ ((module) => { -module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/narrative-card","version":"0.1.0","title":"Carte narrative","category":"carhop-blocks","icon":"smiley","description":"Une carte narrative","example":{},"supports":{"html":false},"textdomain":"carhop-blocks","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js","attributes":{"hasCover":{"type":"boolean","default":true},"coverPosition":{"type":"string","default":"right","enum":["left","right"]},"coverId":{"type":"number"},"coverUrl":{"type":"string"},"coverAlt":{"type":"string"},"blackWhiteCoverFilter":{"type":"boolean","default":true}}}'); +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/narrative-card","version":"0.1.0","title":"Carte narrative","category":"carhop-blocks","icon":"smiley","description":"Une carte narrative","example":{},"supports":{"html":false},"textdomain":"carhop-blocks","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js","attributes":{"hasCover":{"type":"boolean","default":true},"aspectRatio":{"type":"string","default":"auto","enum":["auto","1/1","4/3","3/4","3/2","2/3","16/9","21/9","9/16","9/21"]},"coverPosition":{"type":"string","default":"right","enum":["left","right"]},"coverId":{"type":"number"},"coverUrl":{"type":"string"},"coverAlt":{"type":"string"},"blackWhiteCoverFilter":{"type":"boolean","default":true}}}'); /***/ }), @@ -119,7 +121,8 @@ function Edit({ coverAlt, coverPosition, hasCover, - blackWhiteCoverFilter + blackWhiteCoverFilter, + aspectRatio } = attributes; const colors = (0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useSetting)("color.palette.theme"); function setCoverAttributes(cover) { @@ -186,6 +189,44 @@ function Edit({ label: "Droite", value: "right" })] + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.SelectControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Proportion", "carhop-blocks"), + value: aspectRatio || "auto", + options: [{ + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Auto", "carhop-blocks"), + value: "auto" + }, { + label: "1:1", + value: "1/1" + }, { + label: "4:3", + value: "4/3" + }, { + label: "3:4", + value: "3/4" + }, { + label: "3:2", + value: "3/2" + }, { + label: "2:3", + value: "2/3" + }, { + label: "16:9", + value: "16/9" + }, { + label: "21:9", + value: "21/9" + }, { + label: "9:16", + value: "9/16" + }, { + label: "9:21", + value: "9/21" + }], + onChange: value => setAttributes({ + aspectRatio: value + }), + help: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Sélectionnez la proportion d'affichage de la carte.", "carhop-blocks") }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsxs)(_wordpress_components__WEBPACK_IMPORTED_MODULE_2__.__experimentalToggleGroupControl, { className: "deligraph-blocks__variant", isBlock: true, @@ -226,11 +267,12 @@ function Edit({ }), shouldShowCoverLeft && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsx)(_Cover__WEBPACK_IMPORTED_MODULE_5__["default"], { coverUrl: coverUrl, coverAlt: coverAlt, + aspectRatio: aspectRatio, onSelect: setCoverAttributes }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsx)("div", { className: "narrative-card__content", children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { - allowedBlocks: ["core/paragraph", "core/heading", "core/image"], + allowedBlocks: ["core/paragraph", "core/heading", "core/image", "carhop-blocks/cta", "carhop-blocks/cta-group"], template: [["core/heading", { content: "Lorem ipsum" }], ["core/paragraph", { @@ -240,6 +282,7 @@ function Edit({ }), shouldShowCoverRight && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_6__.jsx)(_Cover__WEBPACK_IMPORTED_MODULE_5__["default"], { coverUrl: coverUrl, coverAlt: coverAlt, + aspectRatio: aspectRatio, onSelect: setCoverAttributes })] })] @@ -323,7 +366,8 @@ function save({ coverUrl, coverAlt, coverPosition, - blackWhiteCoverFilter + blackWhiteCoverFilter, + aspectRatio } = attributes; return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save({ @@ -343,7 +387,7 @@ function save({ vectorEffect: "non-scaling-stroke" }) }), hasCover && coverPosition === "left" && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { - className: "narrative-card__cover", + className: `narrative-card__cover${aspectRatio && aspectRatio !== "auto" ? ` narrative-card__cover--ratio-${String(aspectRatio).replace(/[/:]/g, "-")}` : ""}`, children: hasCover && coverUrl && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("img", { src: coverUrl, alt: coverAlt @@ -352,7 +396,7 @@ function save({ className: "narrative-card__content", children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.InnerBlocks.Content, {}) }), hasCover && coverPosition === "right" && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { - className: "narrative-card__cover", + className: `narrative-card__cover${aspectRatio && aspectRatio !== "auto" ? ` narrative-card__cover--ratio-${String(aspectRatio).replace(/[/:]/g, "-")}` : ""}`, children: hasCover && coverUrl && /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("img", { src: coverUrl, alt: coverAlt diff --git a/plugins/carhop-blocks/build/narrative-card/index.js.map b/plugins/carhop-blocks/build/narrative-card/index.js.map index 2f12cf8..5f183af 100644 --- a/plugins/carhop-blocks/build/narrative-card/index.js.map +++ b/plugins/carhop-blocks/build/narrative-card/index.js.map @@ -1 +1 @@ -{"version":3,"file":"narrative-card/index.js","mappings":";;;;;;;;;;;;;;;;;;AAAA;AACkD;AACV;AACxC,oCAAoC,sDAAG,CAAC,sDAAG,IAAI,qFAAqF,sDAAG;AACvI,EAAE,uDAAI;AACN;AACA;AACA;AACA;AACA;AACA,GAAG;AAGD;AACF;;;;;;;;;;;;;;;;;;;ACd2D;AAAA;AAE5C,SAASK,KAAKA,CAAC;EAAEC,QAAQ;EAAEC,QAAQ;EAAEC;AAAS,CAAC,EAAE;EAC/D,oBACCJ,uDAAA;IAAKK,SAAS,EAAC,uBAAuB;IAAAC,QAAA,GACpCJ,QAAQ,iBAAIJ,sDAAA;MAAKS,GAAG,EAAEL,QAAS;MAACM,GAAG,EAAEL;IAAS,CAAE,CAAC,EACjD,CAACD,QAAQ,iBACTJ,sDAAA,CAACF,qEAAgB;MAChBa,MAAM,EAAC,SAAS;MAChBC,YAAY,EAAE,CAAC,OAAO,CAAE;MACxBN,QAAQ,EAAEA,QAAS;MACnBO,QAAQ,EAAE,KAAM;MAChBC,YAAY,EAAE;IAAK,CACnB,CACD;EAAA,CACG,CAAC;AAER,C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACjBqC;AAUJ;AAOF;AACR;AACwB;AACd;AAAA;AAElB,SAASsB,IAAIA,CAAC;EAAEC,UAAU;EAAEC;AAAc,CAAC,EAAE;EAC3D,MAAM;IACLC,OAAO;IACPnC,QAAQ;IACRC,QAAQ;IACRmC,a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wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./node_modules/.pnpm/@wordpress+icons@11.2.0_react@18.3.1/node_modules/@wordpress/icons/build-module/library/trash.js","webpack://carhop-blocks/./src/narrative-card/Cover.jsx","webpack://carhop-blocks/./src/narrative-card/edit.js","webpack://carhop-blocks/./src/narrative-card/editor.scss?240b","webpack://carhop-blocks/./src/narrative-card/index.js","webpack://carhop-blocks/./src/narrative-card/save.js","webpack://carhop-blocks/./src/narrative-card/style.scss?7d5f","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window [\"wp\",\"primitives\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["// packages/icons/src/library/trash.tsx\nimport { Path, SVG } from \"@wordpress/primitives\";\nimport { jsx } from \"react/jsx-runtime\";\nvar trash_default = /* @__PURE__ */ jsx(SVG, { xmlns: \"http://www.w3.org/2000/svg\", viewBox: \"0 0 24 24\", children: /* @__PURE__ */ jsx(\n Path,\n {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M12 5.5A2.25 2.25 0 0 0 9.878 7h4.244A2.251 2.251 0 0 0 12 5.5ZM12 4a3.751 3.751 0 0 0-3.675 3H5v1.5h1.27l.818 8.997a2.75 2.75 0 0 0 2.739 2.501h4.347a2.75 2.75 0 0 0 2.738-2.5L17.73 8.5H19V7h-3.325A3.751 3.751 0 0 0 12 4Zm4.224 4.5H7.776l.806 8.861a1.25 1.25 0 0 0 1.245 1.137h4.347a1.25 1.25 0 0 0 1.245-1.137l.805-8.861Z\"\n }\n) });\nexport {\n trash_default as default\n};\n//# sourceMappingURL=trash.js.map\n","import { MediaPlaceholder } from \"@wordpress/block-editor\";\r\n\r\nexport default function Cover({ coverUrl, coverAlt, onSelect }) {\r\n\treturn (\r\n\t\t
\r\n\t\t\t{coverUrl && {coverAlt}}\r\n\t\t\t{!coverUrl && (\r\n\t\t\t\t\r\n\t\t\t)}\r\n\t\t
\r\n\t);\r\n}\r\n","import { __ } from \"@wordpress/i18n\";\nimport {\n\tuseBlockProps,\n\tRichText,\n\tMediaReplaceFlow,\n\tInspectorControls,\n\t__experimentalLinkControl as LinkControl,\n\tuseSetting,\n\tInnerBlocks,\n\tMediaPlaceholder,\n} from \"@wordpress/block-editor\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n} from \"@wordpress/components\";\nimport \"./editor.scss\";\nimport { lock, trash } from \"@wordpress/icons\";\nimport CoverImage from \"./Cover\";\n\nexport default function Edit({ attributes, setAttributes }) {\n\tconst {\n\t\tcoverId,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverPosition,\n\t\thasCover,\n\t\tblackWhiteCoverFilter,\n\t} = attributes;\n\tconst colors = useSetting(\"color.palette.theme\");\n\n\tfunction setCoverAttributes(cover) {\n\t\tsetAttributes({\n\t\t\tcoverId: cover.id,\n\t\t\tcoverAlt: cover.alt,\n\t\t\tcoverUrl: cover.url,\n\t\t});\n\t}\n\tfunction removeCoverAttributes() {\n\t\tsetAttributes({\n\t\t\tcoverId: null,\n\t\t\tcoverAlt: null,\n\t\t\tcoverUrl: null,\n\t\t});\n\t}\n\n\t// Déterminer l'ordre des éléments basé sur la position\n\tconst shouldShowCoverLeft = hasCover && coverPosition === \"left\";\n\tconst shouldShowCoverRight = hasCover && coverPosition === \"right\";\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t setAttributes({ hasCover: value })}\n\t\t\t\t\t/>\n\t\t\t\t\t{coverUrl && {coverAlt}}\n\n\t\t\t\t\t{hasCover && (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t{coverUrl && (\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t)}\n\n\t\t\t\t\t\t\t setAttributes({ coverPosition: value })}\n\t\t\t\t\t\t\t\tvalue={coverPosition}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t\tsetAttributes({ blackWhiteCoverFilter: value === \"true\" });\n\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\tvalue={blackWhiteCoverFilter ? \"true\" : \"false\"}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\t\t\t\t\n\t\t\t
\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t{shouldShowCoverLeft && (\n\t\t\t\t\t\n\t\t\t\t)}\n\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\n\t\t\t\t{shouldShowCoverRight && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t\tforeground: \"#136f63\",\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps } from \"@wordpress/block-editor\";\nimport { InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst { hasCover, coverUrl, coverAlt, coverPosition, blackWhiteCoverFilter } =\n\t\tattributes;\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\n\t\t\t{hasCover && coverPosition === \"left\" && (\n\t\t\t\t
\n\t\t\t\t\t{hasCover && coverUrl && {coverAlt}}\n\t\t\t\t
\n\t\t\t)}\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\t{hasCover && coverPosition === \"right\" && (\n\t\t\t\t
\n\t\t\t\t\t{hasCover && coverUrl && {coverAlt}}\n\t\t\t\t
\n\t\t\t)}\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"wp\"][\"primitives\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"narrative-card/index\": 0,\n\t\"narrative-card/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"narrative-card/style-index\"], () => (__webpack_require__(\"./src/narrative-card/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["MediaPlaceholder","jsx","_jsx","jsxs","_jsxs","Cover","coverUrl","coverAlt","onSelect","className","children","src","alt","accept","allowedTypes","multiple","handleUpload","__","useBlockProps","RichText","MediaReplaceFlow","InspectorControls","__experimentalLinkControl","LinkControl","useSetting","InnerBlocks","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","lock","trash","CoverImage","Fragment","_Fragment","Edit","attributes","setAttributes","coverId","coverPosition","hasCover","blackWhiteCoverFilter","colors","setCoverAttributes","cover","id","url","removeCoverAttributes","shouldShowCoverLeft","shouldShowCoverRight","title","label","checked","onChange","value","mediaId","mediaUrl","name","variant","icon","onClick","isBlock","viewBox","fill","xmlns","preserveAspectRatio","d","stroke","strokeWidth","vectorEffect","allowedBlocks","template","content","registerBlockType","save","metadata","foreground","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"narrative-card/index.js","mappings":";;;;;;;;;;;;;;;;;;AAAA;AACkD;AACV;AACxC,oCAAoC,sDAAG,CAAC,sDAAG,IAAI,qFAAqF,sDAAG;AACvI,EAAE,uDAAI;AACN;AACA;AACA;AACA;AACA;AACA,GAAG;AAGD;AACF;;;;;;;;;;;;;;;;;;;ACd2D;AAAA;AAE5C,SAASK,KAAKA,CAAC;EAAEC,QAAQ;EAAEC,QAAQ;EAAEC,QAAQ;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ACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./node_modules/.pnpm/@wordpress+icons@11.2.0_react@18.3.1/node_modules/@wordpress/icons/build-module/library/trash.js","webpack://carhop-blocks/./src/narrative-card/Cover.jsx","webpack://carhop-blocks/./src/narrative-card/edit.js","webpack://carhop-blocks/./src/narrative-card/editor.scss","webpack://carhop-blocks/./src/narrative-card/index.js","webpack://carhop-blocks/./src/narrative-card/save.js","webpack://carhop-blocks/./src/narrative-card/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window [\"wp\",\"primitives\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["// packages/icons/src/library/trash.tsx\nimport { Path, SVG } from \"@wordpress/primitives\";\nimport { jsx } from \"react/jsx-runtime\";\nvar trash_default = /* @__PURE__ */ jsx(SVG, { xmlns: \"http://www.w3.org/2000/svg\", viewBox: \"0 0 24 24\", children: /* @__PURE__ */ jsx(\n Path,\n {\n fillRule: \"evenodd\",\n clipRule: \"evenodd\",\n d: \"M12 5.5A2.25 2.25 0 0 0 9.878 7h4.244A2.251 2.251 0 0 0 12 5.5ZM12 4a3.751 3.751 0 0 0-3.675 3H5v1.5h1.27l.818 8.997a2.75 2.75 0 0 0 2.739 2.501h4.347a2.75 2.75 0 0 0 2.738-2.5L17.73 8.5H19V7h-3.325A3.751 3.751 0 0 0 12 4Zm4.224 4.5H7.776l.806 8.861a1.25 1.25 0 0 0 1.245 1.137h4.347a1.25 1.25 0 0 0 1.245-1.137l.805-8.861Z\"\n }\n) });\nexport {\n trash_default as default\n};\n//# sourceMappingURL=trash.js.map\n","import { MediaPlaceholder } from \"@wordpress/block-editor\";\r\n\r\nexport default function Cover({ coverUrl, coverAlt, onSelect, aspectRatio }) {\r\n\tconst ratioClass =\r\n\t\taspectRatio && aspectRatio !== \"auto\"\r\n\t\t\t? ` narrative-card__cover--ratio-${String(aspectRatio).replace(\r\n\t\t\t\t\t/[/:]/g,\r\n\t\t\t\t\t\"-\"\r\n\t\t\t )}`\r\n\t\t\t: \"\";\r\n\treturn (\r\n\t\t
\r\n\t\t\t{coverUrl && {coverAlt}}\r\n\t\t\t{!coverUrl && (\r\n\t\t\t\t\r\n\t\t\t)}\r\n\t\t
\r\n\t);\r\n}\r\n","import { __ } from \"@wordpress/i18n\";\nimport {\n\tuseBlockProps,\n\tRichText,\n\tMediaReplaceFlow,\n\tInspectorControls,\n\t__experimentalLinkControl as LinkControl,\n\tuseSetting,\n\tInnerBlocks,\n\tMediaPlaceholder,\n} from \"@wordpress/block-editor\";\nimport {\n\tPanelBody,\n\t__experimentalToggleGroupControl as ToggleGroupControl,\n\t__experimentalToggleGroupControlOption as ToggleGroupControlOption,\n\tButton,\n\tCheckboxControl,\n\tSelectControl,\n} from \"@wordpress/components\";\nimport \"./editor.scss\";\nimport { lock, trash } from \"@wordpress/icons\";\nimport CoverImage from \"./Cover\";\n\nexport default function Edit({ attributes, setAttributes }) {\n\tconst {\n\t\tcoverId,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverPosition,\n\t\thasCover,\n\t\tblackWhiteCoverFilter,\n\t\taspectRatio,\n\t} = attributes;\n\tconst colors = useSetting(\"color.palette.theme\");\n\n\tfunction setCoverAttributes(cover) {\n\t\tsetAttributes({\n\t\t\tcoverId: cover.id,\n\t\t\tcoverAlt: cover.alt,\n\t\t\tcoverUrl: cover.url,\n\t\t});\n\t}\n\tfunction removeCoverAttributes() {\n\t\tsetAttributes({\n\t\t\tcoverId: null,\n\t\t\tcoverAlt: null,\n\t\t\tcoverUrl: null,\n\t\t});\n\t}\n\n\t// Déterminer l'ordre des éléments basé sur la position\n\tconst shouldShowCoverLeft = hasCover && coverPosition === \"left\";\n\tconst shouldShowCoverRight = hasCover && coverPosition === \"right\";\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t setAttributes({ hasCover: value })}\n\t\t\t\t\t/>\n\t\t\t\t\t{coverUrl && {coverAlt}}\n\n\t\t\t\t\t{hasCover && (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t{coverUrl && (\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t)}\n\n\t\t\t\t\t\t\t setAttributes({ coverPosition: value })}\n\t\t\t\t\t\t\t\tvalue={coverPosition}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t setAttributes({ aspectRatio: value })}\n\t\t\t\t\t\t\t\thelp={__(\n\t\t\t\t\t\t\t\t\t\"Sélectionnez la proportion d'affichage de la carte.\",\n\t\t\t\t\t\t\t\t\t\"carhop-blocks\"\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t/>\n\n\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t\tsetAttributes({ blackWhiteCoverFilter: value === \"true\" });\n\t\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t\t\tvalue={blackWhiteCoverFilter ? \"true\" : \"false\"}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\t\t\t\t\n\t\t\t
\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t{shouldShowCoverLeft && (\n\t\t\t\t\t\n\t\t\t\t)}\n\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\n\t\t\t\t{shouldShowCoverRight && (\n\t\t\t\t\t\n\t\t\t\t)}\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t\tforeground: \"#136f63\",\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps } from \"@wordpress/block-editor\";\nimport { InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst {\n\t\thasCover,\n\t\tcoverUrl,\n\t\tcoverAlt,\n\t\tcoverPosition,\n\t\tblackWhiteCoverFilter,\n\t\taspectRatio,\n\t} = attributes;\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\n\t\t\t{hasCover && coverPosition === \"left\" && (\n\t\t\t\t\n\t\t\t\t\t{hasCover && coverUrl && {coverAlt}}\n\t\t\t\t\n\t\t\t)}\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\t{hasCover && coverPosition === \"right\" && (\n\t\t\t\t\n\t\t\t\t\t{hasCover && coverUrl && {coverAlt}}\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"wp\"][\"primitives\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"narrative-card/index\": 0,\n\t\"narrative-card/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"narrative-card/style-index\"], () => (__webpack_require__(\"./src/narrative-card/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["MediaPlaceholder","jsx","_jsx","jsxs","_jsxs","Cover","coverUrl","coverAlt","onSelect","aspectRatio","ratioClass","String","replace","className","children","src","alt","accept","allowedTypes","multiple","handleUpload","__","useBlockProps","RichText","MediaReplaceFlow","InspectorControls","__experimentalLinkControl","LinkControl","useSetting","InnerBlocks","PanelBody","__experimentalToggleGroupControl","ToggleGroupControl","__experimentalToggleGroupControlOption","ToggleGroupControlOption","Button","CheckboxControl","SelectControl","lock","trash","CoverImage","Fragment","_Fragment","Edit","attributes","setAttributes","coverId","coverPosition","hasCover","blackWhiteCoverFilter","colors","setCoverAttributes","cover","id","url","removeCoverAttributes","shouldShowCoverLeft","shouldShowCoverRight","title","label","checked","onChange","value","mediaId","mediaUrl","name","variant","icon","onClick","isBlock","options","help","viewBox","fill","xmlns","preserveAspectRatio","d","stroke","strokeWidth","vectorEffect","allowedBlocks","template","content","registerBlockType","save","metadata","foreground","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/scroll-story-block/block.json b/plugins/carhop-blocks/build/scroll-story-block/block.json index cb6e9a3..8dcc4ba 100644 --- a/plugins/carhop-blocks/build/scroll-story-block/block.json +++ b/plugins/carhop-blocks/build/scroll-story-block/block.json @@ -15,5 +15,11 @@ "editorScript": "file:./index.js", "editorStyle": "file:./index.css", "style": "file:./style-index.css", - "viewScript": "file:./view.js" + "viewScript": "file:./view.js", + "attributes": { + "hasNumbering": { + "type": "boolean", + "default": false + } + } } \ No newline at end of file diff --git a/plugins/carhop-blocks/build/scroll-story-block/index.asset.php b/plugins/carhop-blocks/build/scroll-story-block/index.asset.php index af9bbf8..3a5a527 100644 --- a/plugins/carhop-blocks/build/scroll-story-block/index.asset.php +++ b/plugins/carhop-blocks/build/scroll-story-block/index.asset.php @@ -1 +1 @@ - array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-i18n'), 'version' => '1b195111f3319d0d1347'); + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n'), 'version' => '07616c19418f6093c2be'); diff --git a/plugins/carhop-blocks/build/scroll-story-block/index.js b/plugins/carhop-blocks/build/scroll-story-block/index.js index 9dcfd3e..4397fed 100644 --- a/plugins/carhop-blocks/build/scroll-story-block/index.js +++ b/plugins/carhop-blocks/build/scroll-story-block/index.js @@ -8,7 +8,7 @@ \*******************************************/ /***/ ((module) => { -module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/scroll-story-block","version":"0.1.0","title":"Section défilante animée","category":"carhop-blocks","icon":"format-quote","description":"Une section défilante animée","example":{},"supports":{"html":false},"textdomain":"carhop-blocks","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js"}'); +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/scroll-story-block","version":"0.1.0","title":"Section défilante animée","category":"carhop-blocks","icon":"format-quote","description":"Une section défilante animée","example":{},"supports":{"html":false},"textdomain":"carhop-blocks","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js","attributes":{"hasNumbering":{"type":"boolean","default":false}}}'); /***/ }), @@ -27,8 +27,12 @@ __webpack_require__.r(__webpack_exports__); /* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); /* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); /* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./editor.scss */ "./src/scroll-story-block/editor.scss"); -/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); -/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__); + + @@ -37,12 +41,27 @@ function Edit({ attributes, setAttributes }) { - return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.Fragment, { - children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)("div", { + const { + hasNumbering + } = attributes; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.Fragment, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InspectorControls, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__.PanelBody, { + className: "deligraph-blocks-components-image__panel-body", + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Numérotation", "deligraph-blocks"), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__.CheckboxControl, { + label: "Afficher la num\xE9rotation", + checked: hasNumbering, + onChange: value => setAttributes({ + hasNumbering: value + }) + }) + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("div", { ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)({ - className: `scroll-story-block` + className: `scroll-story-block ${hasNumbering ? "scroll-story-block--has-numbering" : ""}` }), - children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_3__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { allowedBlocks: ["carhop-blocks/narrative-card"], template: [["carhop-blocks/narrative-card", { hasCover: true, @@ -62,7 +81,7 @@ function Edit({ }]] }]] }) - }) + })] }); } @@ -138,9 +157,12 @@ __webpack_require__.r(__webpack_exports__); function save({ attributes }) { + const { + hasNumbering + } = attributes; return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save({ - className: "scroll-story-block" + className: `scroll-story-block ${hasNumbering ? "scroll-story-block--has-numbering" : ""}` }), children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.InnerBlocks.Content, {}) }); @@ -180,6 +202,16 @@ module.exports = window["wp"]["blocks"]; /***/ }), +/***/ "@wordpress/components": +/*!************************************!*\ + !*** external ["wp","components"] ***! + \************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["components"]; + +/***/ }), + /***/ "@wordpress/i18n": /*!******************************!*\ !*** external ["wp","i18n"] ***! diff --git a/plugins/carhop-blocks/build/scroll-story-block/index.js.map b/plugins/carhop-blocks/build/scroll-story-block/index.js.map index 91c59ed..4c7ed3c 100644 --- a/plugins/carhop-blocks/build/scroll-story-block/index.js.map +++ b/plugins/carhop-blocks/build/scroll-story-block/index.js.map @@ -1 +1 @@ -{"version":3,"file":"scroll-story-block/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AAC9C;AAAA;AAER,SAASO,IAAIA,CAAC;EAAEC,UAAU;EAAEC;AAAc,CAAC,EAAE;EAC3D,oBACCL,sDAAA,CAAAE,uDAAA;IAAAI,QAAA,eACCN,sDAAA;MAAA,GACKH,sEAAa,CAAC;QACjBU,SAAS,EAAE;MACZ,CAAC,CAAC;MAAAD,QAAA,eAEFN,sDAAA,CAACF,gEAAW;QACXU,aAAa,EAAE,CAAC,8BAA8B,CAAE;QAChDC,QAAQ,EAAE,CACT,CACC,8BAA8B,EAC9B;UACCC,QAAQ,EAAE,IAAI;UACdC,aAAa,EAAE,MAAM;UACrBC,WAAW,EAAE,CACZ,CAAC,cAAc,EAAE;YAAEC,OAA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ACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/scroll-story-block/edit.js","webpack://carhop-blocks/./src/scroll-story-block/editor.scss?f955","webpack://carhop-blocks/./src/scroll-story-block/index.js","webpack://carhop-blocks/./src/scroll-story-block/save.js","webpack://carhop-blocks/./src/scroll-story-block/style.scss?63b8","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\n\nexport default function Edit({ attributes, setAttributes }) {\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t\tforeground: \"#136f63\",\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\treturn (\n\t\t
\n\t\t\t\n\t\t
\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"scroll-story-block/index\": 0,\n\t\"scroll-story-block/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"scroll-story-block/style-index\"], () => (__webpack_require__(\"./src/scroll-story-block/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","jsx","_jsx","Fragment","_Fragment","Edit","attributes","setAttributes","children","className","allowedBlocks","template","hasCover","coverPosition","innerBlocks","content","registerBlockType","save","metadata","name","icon","src","viewBox","width","height","d","foreground","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"scroll-story-block/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AAC9C;AAC4C;AACP;AAAA;AAE7C,SAASY,IAAIA,CAAC;EAAEC,UAAU;EAAEC;AAAc,CAAC,EAAE;EAC3D,MAAM;IAAEC;EAAa,CAAC,GAAGF,UAAU;EACnC,oBACCF,uDAAA,CAAAF,uDAAA;IAAAO,QAAA,gBACCT,sDAAA,CAACF,sEAAiB;MAAAW,QAAA,eACjBT,sDAAA,CAACJ,4DAAS;QACTc,SAAS,EAAC,+CAA+C;QACzDC,KAAK,EAAElB,mDAAE,CAAC,cAAc,EAAE,kBAAkB,CAAE;QAAAgB,QAAA,eAE9CT,sDAAA,CAACH,kEAAe;UACfe,KAAK,EAAC,6BAA0B;UAChCC,OAAO,EAAEL,YAAa;UACtBM,QAAQ,EAAGC,KAAK,IAAKR,aAAa,CAAC;YAAEC,YAAY,EAAEO;UAAM,CAAC;QAAE,CAC5D;MAAC,CACQ;IAAC,CACM,CAAC,eACpBf,sDAAA;MAAA,GACKN,sEAAa,CAAC;QACjBgB,SAAS,EAAE,sBACVF,YAAY,GAAG,mCAAmC,GAAG,EAAE;MAEzD,CAAC,CAAC;MAAAC,QAAA,eAEFT,sDAAA,CAACL,gEAAW;QACXqB,aAAa,EAAE,CAAC,8BAA8B,CAAE;QAChDC,QAAQ,EAAE,CACT,CACC,8BAA8B,EAC9B;UACCC,QAAQ,EAAE,IAAI;UACdC,aAAa,EAAE,MAAM;UACrBC,WAAW,EAAE,CACZ,CAAC,cAAc,EA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;;;;;ACAA,4C;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,2C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/scroll-story-block/edit.js","webpack://carhop-blocks/./src/scroll-story-block/editor.scss","webpack://carhop-blocks/./src/scroll-story-block/index.js","webpack://carhop-blocks/./src/scroll-story-block/save.js","webpack://carhop-blocks/./src/scroll-story-block/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\nimport { PanelBody, CheckboxControl } from \"@wordpress/components\";\nimport { InspectorControls } from \"@wordpress/block-editor\";\n\nexport default function Edit({ attributes, setAttributes }) {\n\tconst { hasNumbering } = attributes;\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t setAttributes({ hasNumbering: value })}\n\t\t\t\t\t/>\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t\tforeground: \"#136f63\",\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst { hasNumbering } = attributes;\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"scroll-story-block/index\": 0,\n\t\"scroll-story-block/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"scroll-story-block/style-index\"], () => (__webpack_require__(\"./src/scroll-story-block/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","PanelBody","CheckboxControl","InspectorControls","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","Edit","attributes","setAttributes","hasNumbering","children","className","title","label","checked","onChange","value","allowedBlocks","template","hasCover","coverPosition","innerBlocks","content","registerBlockType","save","metadata","name","icon","src","viewBox","width","height","d","foreground","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline-step/block.json b/plugins/carhop-blocks/build/story-timeline-step/block.json new file mode 100644 index 0000000..c488437 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/block.json @@ -0,0 +1,28 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 3, + "name": "carhop-blocks/story-timeline-step", + "version": "0.1.0", + "title": "Étape de timeline", + "category": "carhop-blocks", + "icon": "calendar", + "description": "Étape de timeline pour la mise en forme d'une étape de timeline", + "example": {}, + "parent": [ + "carhop-blocks/story-timeline" + ], + "supports": { + "html": false + }, + "textdomain": "carhop-blocks", + "editorScript": "file:./index.js", + "editorStyle": "file:./index.css", + "style": "file:./style-index.css", + "viewScript": "file:./view.js", + "attributes": { + "year": { + "type": "number", + "default": 2025 + } + } +} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline-step/index-rtl.css b/plugins/carhop-blocks/build/story-timeline-step/index-rtl.css new file mode 100644 index 0000000..34e89fb --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/index-rtl.css @@ -0,0 +1,4 @@ +/*!*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline-step/editor.scss ***! + \*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline-step/index.asset.php b/plugins/carhop-blocks/build/story-timeline-step/index.asset.php new file mode 100644 index 0000000..b24461c --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/index.asset.php @@ -0,0 +1 @@ + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-i18n'), 'version' => '5d4b8617f61ccc7a9a8c'); diff --git a/plugins/carhop-blocks/build/story-timeline-step/index.css b/plugins/carhop-blocks/build/story-timeline-step/index.css new file mode 100644 index 0000000..34e89fb --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/index.css @@ -0,0 +1,4 @@ +/*!*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline-step/editor.scss ***! + \*********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline-step/index.js b/plugins/carhop-blocks/build/story-timeline-step/index.js new file mode 100644 index 0000000..504076e --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/index.js @@ -0,0 +1,408 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./src/story-timeline-step/block.json": +/*!********************************************!*\ + !*** ./src/story-timeline-step/block.json ***! + \********************************************/ +/***/ ((module) => { + +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/story-timeline-step","version":"0.1.0","title":"Étape de timeline","category":"carhop-blocks","icon":"calendar","description":"Étape de timeline pour la mise en forme d\'une étape de timeline","example":{},"parent":["carhop-blocks/story-timeline"],"supports":{"html":false},"textdomain":"carhop-blocks","editorScript":"file:./index.js","editorStyle":"file:./index.css","style":"file:./style-index.css","viewScript":"file:./view.js","attributes":{"year":{"type":"number","default":2025}}}'); + +/***/ }), + +/***/ "./src/story-timeline-step/edit.js": +/*!*****************************************!*\ + !*** ./src/story-timeline-step/edit.js ***! + \*****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Edit) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./editor.scss */ "./src/story-timeline-step/editor.scss"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @wordpress/components */ "@wordpress/components"); +/* harmony import */ var _wordpress_components__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__); + + + + + + + +function Edit({ + attributes, + setAttributes, + ...props +}) { + const { + year + } = attributes; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsxs)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.Fragment, { + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InspectorControls, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__.PanelBody, { + title: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Étape de timeline", "carhop-blocks"), + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_components__WEBPACK_IMPORTED_MODULE_3__.__experimentalNumberControl, { + label: (0,_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__.__)("Année", "carhop-blocks"), + value: year, + onChange: value => { + const n = parseInt(value, 10); + setAttributes({ + year: Number.isFinite(n) ? n : undefined + }); + } + }) + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsxs)("div", { + ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)({ + className: `story-timeline-step`, + id: `year-${year}` + }), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("p", { + className: "story-timeline-step__year", + children: year + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("div", { + className: "story-timeline-step__innerblocks", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { + allowedBlocks: ["core/heading", "core/paragraph", "core/group", "core/list", "core/button", "core/image", "core/buttons", "core/columns", "core/post-title", "core/embed", "core/quote", "core/pullquote", "core/media-text", "core/table", "carhop-blocks/image-stack", "carhop-blocks/heading", "carhop-blocks/decorative-shapes", "carhop-blocks/scroll-story-block", "carhop-blocks/cta-group", "carhop-blocks/audio-player", "carhop-blocks/localisation-map", "carhop-blocks/notice-panel", "acf/statistics-datas", "ninja-forms/form", "gravityforms/form", "dynamiques-blocks/sitemap", "mailpoet/subscription-form-block", "shortcode"] + }) + })] + })] + }); +} + +/***/ }), + +/***/ "./src/story-timeline-step/editor.scss": +/*!*********************************************!*\ + !*** ./src/story-timeline-step/editor.scss ***! + \*********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/story-timeline-step/index.js": +/*!******************************************!*\ + !*** ./src/story-timeline-step/index.js ***! + \******************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/blocks */ "@wordpress/blocks"); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./style.scss */ "./src/story-timeline-step/style.scss"); +/* harmony import */ var _edit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./edit */ "./src/story-timeline-step/edit.js"); +/* harmony import */ var _save__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./save */ "./src/story-timeline-step/save.js"); +/* harmony import */ var _block_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./block.json */ "./src/story-timeline-step/block.json"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + +(0,_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__.registerBlockType)(_block_json__WEBPACK_IMPORTED_MODULE_4__.name, { + icon: { + foreground: "#136f63", + src: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("svg", { + width: "100", + height: "100", + viewBox: "0 0 100 100", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("g", { + stroke: "null", + id: "svg_10", + class: "fills", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("path", { + stroke: "null", + d: "m3.74998,19.74151c0,-8.82607 7.16546,-15.99153 15.99153,-15.99153l60.51698,0c8.82607,0 15.99153,7.16546 15.99153,15.99153l0,60.51698c0,8.82607 -7.16546,15.99153 -15.99153,15.99153l-60.51698,0c-8.82607,0 -15.99153,-7.16546 -15.99153,-15.99153l0,-60.51698zm22.57628,3.44915l0,53.61867l23.67374,-18.7148l23.67374,18.7148l0,-53.61867l-47.34748,0z" + }) + }) + }) + }, + edit: _edit__WEBPACK_IMPORTED_MODULE_2__["default"], + save: _save__WEBPACK_IMPORTED_MODULE_3__["default"] +}); + +/***/ }), + +/***/ "./src/story-timeline-step/save.js": +/*!*****************************************!*\ + !*** ./src/story-timeline-step/save.js ***! + \*****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ save) +/* harmony export */ }); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__); + + +function save({ + attributes +}) { + const { + year + } = attributes; + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsxs)("div", { + ..._wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.useBlockProps.save({ + className: `story-timeline-step`, + id: `year-${year}` + }), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("p", { + className: "story-timeline-step__year", + children: year + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)("div", { + className: "story-timeline-step__innerblocks", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.InnerBlocks.Content, {}) + })] + }); +} + +/***/ }), + +/***/ "./src/story-timeline-step/style.scss": +/*!********************************************!*\ + !*** ./src/story-timeline-step/style.scss ***! + \********************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "@wordpress/block-editor": +/*!*************************************!*\ + !*** external ["wp","blockEditor"] ***! + \*************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blockEditor"]; + +/***/ }), + +/***/ "@wordpress/blocks": +/*!********************************!*\ + !*** external ["wp","blocks"] ***! + \********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blocks"]; + +/***/ }), + +/***/ "@wordpress/components": +/*!************************************!*\ + !*** external ["wp","components"] ***! + \************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["components"]; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!******************************!*\ + !*** external ["wp","i18n"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["i18n"]; + +/***/ }), + +/***/ "react/jsx-runtime": +/*!**********************************!*\ + !*** external "ReactJSXRuntime" ***! + \**********************************/ +/***/ ((module) => { + +module.exports = window["ReactJSXRuntime"]; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/chunk loaded */ +/******/ (() => { +/******/ var deferred = []; +/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { +/******/ if(chunkIds) { +/******/ priority = priority || 0; +/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; +/******/ deferred[i] = [chunkIds, fn, priority]; +/******/ return; +/******/ } +/******/ var notFulfilled = Infinity; +/******/ for (var i = 0; i < deferred.length; i++) { +/******/ var [chunkIds, fn, priority] = deferred[i]; +/******/ var fulfilled = true; +/******/ for (var j = 0; j < chunkIds.length; j++) { +/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { +/******/ chunkIds.splice(j--, 1); +/******/ } else { +/******/ fulfilled = false; +/******/ if(priority < notFulfilled) notFulfilled = priority; +/******/ } +/******/ } +/******/ if(fulfilled) { +/******/ deferred.splice(i--, 1) +/******/ var r = fn(); +/******/ if (r !== undefined) result = r; +/******/ } +/******/ } +/******/ return result; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/jsonp chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded and loading chunks +/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched +/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded +/******/ var installedChunks = { +/******/ "story-timeline-step/index": 0, +/******/ "story-timeline-step/style-index": 0 +/******/ }; +/******/ +/******/ // no chunk on demand loading +/******/ +/******/ // no prefetching +/******/ +/******/ // no preloaded +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ +/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); +/******/ +/******/ // install a JSONP callback for chunk loading +/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { +/******/ var [chunkIds, moreModules, runtime] = data; +/******/ // add "moreModules" to the modules object, +/******/ // then flag all "chunkIds" as loaded and fire callback +/******/ var moduleId, chunkId, i = 0; +/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { +/******/ for(moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) var result = runtime(__webpack_require__); +/******/ } +/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); +/******/ for(;i < chunkIds.length; i++) { +/******/ chunkId = chunkIds[i]; +/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { +/******/ installedChunks[chunkId][0](); +/******/ } +/******/ installedChunks[chunkId] = 0; +/******/ } +/******/ return __webpack_require__.O(result); +/******/ } +/******/ +/******/ var chunkLoadingGlobal = globalThis["webpackChunkcarhop_blocks"] = globalThis["webpackChunkcarhop_blocks"] || []; +/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); +/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ // startup +/******/ // Load entry module and return exports +/******/ // This entry module depends on other loaded chunks and execution need to be delayed +/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["story-timeline-step/style-index"], () => (__webpack_require__("./src/story-timeline-step/index.js"))) +/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); +/******/ +/******/ })() +; +//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline-step/index.js.map b/plugins/carhop-blocks/build/story-timeline-step/index.js.map new file mode 100644 index 0000000..272437b --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"story-timeline-step/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AAC9C;AASQ;AAC6B;AAET;AAAA;AAEpC,SAASmB,IAAIA,CAAC;EAAEC,UAAU;EAAEC,aAAa;EAAE,GAAGC;AAAM,CAAC,EAAE;EACrE,MAAM;IAAEC;EAAK,CAAC,GAAGH,UAAU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ACAA,wC;;;;;;;;;;ACAA,4C;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,2C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/story-timeline-step/edit.js","webpack://carhop-blocks/./src/story-timeline-step/editor.scss","webpack://carhop-blocks/./src/story-timeline-step/index.js","webpack://carhop-blocks/./src/story-timeline-step/save.js","webpack://carhop-blocks/./src/story-timeline-step/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"components\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport \"./editor.scss\";\nimport {\n\tPanelBody,\n\tCard,\n\tCardBody,\n\tCardHeader,\n\tTextControl,\n\tButton,\n\t__experimentalNumberControl as NumberControl,\n} from \"@wordpress/components\";\nimport { InspectorControls } from \"@wordpress/block-editor\";\n\nimport { RichText } from \"@wordpress/block-editor\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst { year } = attributes;\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t {\n\t\t\t\t\t\t\tconst n = parseInt(value, 10);\n\t\t\t\t\t\t\tsetAttributes({ year: Number.isFinite(n) ? n : undefined });\n\t\t\t\t\t\t}}\n\t\t\t\t\t/>\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t

{year}

\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\tconst { year } = attributes;\n\treturn (\n\t\t\n\t\t\t

{year}

\n\t\t\t
\n\t\t\t\t\n\t\t\t
\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"components\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"story-timeline-step/index\": 0,\n\t\"story-timeline-step/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"story-timeline-step/style-index\"], () => (__webpack_require__(\"./src/story-timeline-step/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","PanelBody","Card","CardBody","CardHeader","TextControl","Button","__experimentalNumberControl","NumberControl","InspectorControls","RichText","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","year","children","title","label","value","onChange","n","parseInt","Number","isFinite","undefined","className","id","allowedBlocks","registerBlockType","save","metadata","name","icon","foreground","src","width","height","viewBox","stroke","class","d","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline-step/style-index-rtl.css b/plugins/carhop-blocks/build/story-timeline-step/style-index-rtl.css new file mode 100644 index 0000000..98ebdc4 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/style-index-rtl.css @@ -0,0 +1,4 @@ +/*!********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline-step/style.scss ***! + \********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline-step/style-index.css b/plugins/carhop-blocks/build/story-timeline-step/style-index.css new file mode 100644 index 0000000..98ebdc4 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/style-index.css @@ -0,0 +1,4 @@ +/*!********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline-step/style.scss ***! + \********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline-step/view.asset.php b/plugins/carhop-blocks/build/story-timeline-step/view.asset.php new file mode 100644 index 0000000..ee9047e --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/view.asset.php @@ -0,0 +1 @@ + array(), 'version' => 'd2129832e5692d3e6ebe'); diff --git a/plugins/carhop-blocks/build/story-timeline-step/view.js b/plugins/carhop-blocks/build/story-timeline-step/view.js new file mode 100644 index 0000000..2b4464a --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline-step/view.js @@ -0,0 +1,7 @@ +/******/ (() => { // webpackBootstrap +/*!*****************************************!*\ + !*** ./src/story-timeline-step/view.js ***! + \*****************************************/ + +/******/ })() +; \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline/block.json b/plugins/carhop-blocks/build/story-timeline/block.json new file mode 100644 index 0000000..97b1f73 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/block.json @@ -0,0 +1,20 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 3, + "name": "carhop-blocks/story-timeline", + "version": "0.1.0", + "title": "Timeline", + "category": "carhop-blocks", + "icon": "calendar-alt", + "description": "Boite de timeline pour la mise en forme d'une timeline", + "example": {}, + "supports": { + "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" +} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline/index-rtl.css b/plugins/carhop-blocks/build/story-timeline/index-rtl.css new file mode 100644 index 0000000..392e106 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/index-rtl.css @@ -0,0 +1,4 @@ +/*!****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline/editor.scss ***! + \****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline/index.asset.php b/plugins/carhop-blocks/build/story-timeline/index.asset.php new file mode 100644 index 0000000..5938130 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/index.asset.php @@ -0,0 +1 @@ + array('react-jsx-runtime', 'wp-block-editor', 'wp-blocks', 'wp-data', 'wp-i18n'), 'version' => 'ff5d0394b779af2f225e'); diff --git a/plugins/carhop-blocks/build/story-timeline/index.css b/plugins/carhop-blocks/build/story-timeline/index.css new file mode 100644 index 0000000..392e106 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/index.css @@ -0,0 +1,4 @@ +/*!****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline/editor.scss ***! + \****************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline/index.js b/plugins/carhop-blocks/build/story-timeline/index.js new file mode 100644 index 0000000..6a524dd --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/index.js @@ -0,0 +1,385 @@ +/******/ (() => { // webpackBootstrap +/******/ "use strict"; +/******/ var __webpack_modules__ = ({ + +/***/ "./src/story-timeline/block.json": +/*!***************************************!*\ + !*** ./src/story-timeline/block.json ***! + \***************************************/ +/***/ ((module) => { + +module.exports = /*#__PURE__*/JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"carhop-blocks/story-timeline","version":"0.1.0","title":"Timeline","category":"carhop-blocks","icon":"calendar-alt","description":"Boite de timeline pour la mise en forme d\'une timeline","example":{},"supports":{"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"}'); + +/***/ }), + +/***/ "./src/story-timeline/edit.js": +/*!************************************!*\ + !*** ./src/story-timeline/edit.js ***! + \************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ Edit) +/* harmony export */ }); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n"); +/* harmony import */ var _wordpress_i18n__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_i18n__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @wordpress/data */ "@wordpress/data"); +/* harmony import */ var _wordpress_data__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_wordpress_data__WEBPACK_IMPORTED_MODULE_2__); +/* harmony import */ var _editor_scss__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./editor.scss */ "./src/story-timeline/editor.scss"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__); + + + + + +function Edit({ + attributes, + setAttributes, + ...props +}) { + const years = (0,_wordpress_data__WEBPACK_IMPORTED_MODULE_2__.useSelect)(select => { + const { + getBlocks + } = select("core/block-editor"); + const childBlocks = getBlocks(props.clientId) || []; + return childBlocks.filter(b => b.name === "carhop-blocks/story-timeline-step").map(b => b.attributes?.year).filter(y => y !== undefined && y !== null && y !== ""); + }, [props.clientId]); + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.Fragment, { + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsxs)("section", { + ...(0,_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.useBlockProps)({ + className: `story-timeline` + }), + children: [/*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("aside", { + className: "story-timeline__years", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("ul", { + children: years.map((y, idx) => /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("li", { + className: "story-timeline__year", + children: y + }, idx)) + }) + }), /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)("div", { + className: "story-timeline__innerblocks", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_4__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_1__.InnerBlocks, { + allowedBlocks: ["carhop-blocks/story-timeline-step"] + }) + })] + }) + }); +} + +/***/ }), + +/***/ "./src/story-timeline/editor.scss": +/*!****************************************!*\ + !*** ./src/story-timeline/editor.scss ***! + \****************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "./src/story-timeline/index.js": +/*!*************************************!*\ + !*** ./src/story-timeline/index.js ***! + \*************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/blocks */ "@wordpress/blocks"); +/* harmony import */ var _wordpress_blocks__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var _style_scss__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./style.scss */ "./src/story-timeline/style.scss"); +/* harmony import */ var _edit__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./edit */ "./src/story-timeline/edit.js"); +/* harmony import */ var _save__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./save */ "./src/story-timeline/save.js"); +/* harmony import */ var _block_json__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./block.json */ "./src/story-timeline/block.json"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__); + + + + + + +(0,_wordpress_blocks__WEBPACK_IMPORTED_MODULE_0__.registerBlockType)(_block_json__WEBPACK_IMPORTED_MODULE_4__.name, { + icon: { + foreground: "#136f63", + src: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("svg", { + width: "100", + height: "100", + viewBox: "0 0 100 100", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("g", { + stroke: "null", + id: "svg_10", + class: "fills", + children: /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_5__.jsx)("path", { + stroke: "null", + d: "m3.74998,19.74151c0,-8.82607 7.16546,-15.99153 15.99153,-15.99153l60.51698,0c8.82607,0 15.99153,7.16546 15.99153,15.99153l0,60.51698c0,8.82607 -7.16546,15.99153 -15.99153,15.99153l-60.51698,0c-8.82607,0 -15.99153,-7.16546 -15.99153,-15.99153l0,-60.51698zm22.57628,3.44915l0,53.61867l23.67374,-18.7148l23.67374,18.7148l0,-53.61867l-47.34748,0z" + }) + }) + }) + }, + edit: _edit__WEBPACK_IMPORTED_MODULE_2__["default"], + save: _save__WEBPACK_IMPORTED_MODULE_3__["default"] +}); + +/***/ }), + +/***/ "./src/story-timeline/save.js": +/*!************************************!*\ + !*** ./src/story-timeline/save.js ***! + \************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +/* harmony export */ __webpack_require__.d(__webpack_exports__, { +/* harmony export */ "default": () => (/* binding */ save) +/* harmony export */ }); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @wordpress/block-editor */ "@wordpress/block-editor"); +/* harmony import */ var _wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! react/jsx-runtime */ "react/jsx-runtime"); +/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__); + + +function save({ + attributes +}) { + return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_1__.jsx)(_wordpress_block_editor__WEBPACK_IMPORTED_MODULE_0__.InnerBlocks.Content, {}); +} + +/***/ }), + +/***/ "./src/story-timeline/style.scss": +/*!***************************************!*\ + !*** ./src/story-timeline/style.scss ***! + \***************************************/ +/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => { + +__webpack_require__.r(__webpack_exports__); +// extracted by mini-css-extract-plugin + + +/***/ }), + +/***/ "@wordpress/block-editor": +/*!*************************************!*\ + !*** external ["wp","blockEditor"] ***! + \*************************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blockEditor"]; + +/***/ }), + +/***/ "@wordpress/blocks": +/*!********************************!*\ + !*** external ["wp","blocks"] ***! + \********************************/ +/***/ ((module) => { + +module.exports = window["wp"]["blocks"]; + +/***/ }), + +/***/ "@wordpress/data": +/*!******************************!*\ + !*** external ["wp","data"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["data"]; + +/***/ }), + +/***/ "@wordpress/i18n": +/*!******************************!*\ + !*** external ["wp","i18n"] ***! + \******************************/ +/***/ ((module) => { + +module.exports = window["wp"]["i18n"]; + +/***/ }), + +/***/ "react/jsx-runtime": +/*!**********************************!*\ + !*** external "ReactJSXRuntime" ***! + \**********************************/ +/***/ ((module) => { + +module.exports = window["ReactJSXRuntime"]; + +/***/ }) + +/******/ }); +/************************************************************************/ +/******/ // The module cache +/******/ var __webpack_module_cache__ = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ // Check if module is in cache +/******/ var cachedModule = __webpack_module_cache__[moduleId]; +/******/ if (cachedModule !== undefined) { +/******/ return cachedModule.exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = __webpack_module_cache__[moduleId] = { +/******/ // no module.id needed +/******/ // no module.loaded needed +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__); +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = __webpack_modules__; +/******/ +/************************************************************************/ +/******/ /* webpack/runtime/chunk loaded */ +/******/ (() => { +/******/ var deferred = []; +/******/ __webpack_require__.O = (result, chunkIds, fn, priority) => { +/******/ if(chunkIds) { +/******/ priority = priority || 0; +/******/ for(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1]; +/******/ deferred[i] = [chunkIds, fn, priority]; +/******/ return; +/******/ } +/******/ var notFulfilled = Infinity; +/******/ for (var i = 0; i < deferred.length; i++) { +/******/ var [chunkIds, fn, priority] = deferred[i]; +/******/ var fulfilled = true; +/******/ for (var j = 0; j < chunkIds.length; j++) { +/******/ if ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) { +/******/ chunkIds.splice(j--, 1); +/******/ } else { +/******/ fulfilled = false; +/******/ if(priority < notFulfilled) notFulfilled = priority; +/******/ } +/******/ } +/******/ if(fulfilled) { +/******/ deferred.splice(i--, 1) +/******/ var r = fn(); +/******/ if (r !== undefined) result = r; +/******/ } +/******/ } +/******/ return result; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/compat get default export */ +/******/ (() => { +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = (module) => { +/******/ var getter = module && module.__esModule ? +/******/ () => (module['default']) : +/******/ () => (module); +/******/ __webpack_require__.d(getter, { a: getter }); +/******/ return getter; +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/define property getters */ +/******/ (() => { +/******/ // define getter functions for harmony exports +/******/ __webpack_require__.d = (exports, definition) => { +/******/ for(var key in definition) { +/******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) { +/******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] }); +/******/ } +/******/ } +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/hasOwnProperty shorthand */ +/******/ (() => { +/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop)) +/******/ })(); +/******/ +/******/ /* webpack/runtime/make namespace object */ +/******/ (() => { +/******/ // define __esModule on exports +/******/ __webpack_require__.r = (exports) => { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ })(); +/******/ +/******/ /* webpack/runtime/jsonp chunk loading */ +/******/ (() => { +/******/ // no baseURI +/******/ +/******/ // object to store loaded and loading chunks +/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched +/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded +/******/ var installedChunks = { +/******/ "story-timeline/index": 0, +/******/ "story-timeline/style-index": 0 +/******/ }; +/******/ +/******/ // no chunk on demand loading +/******/ +/******/ // no prefetching +/******/ +/******/ // no preloaded +/******/ +/******/ // no HMR +/******/ +/******/ // no HMR manifest +/******/ +/******/ __webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0); +/******/ +/******/ // install a JSONP callback for chunk loading +/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => { +/******/ var [chunkIds, moreModules, runtime] = data; +/******/ // add "moreModules" to the modules object, +/******/ // then flag all "chunkIds" as loaded and fire callback +/******/ var moduleId, chunkId, i = 0; +/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) { +/******/ for(moduleId in moreModules) { +/******/ if(__webpack_require__.o(moreModules, moduleId)) { +/******/ __webpack_require__.m[moduleId] = moreModules[moduleId]; +/******/ } +/******/ } +/******/ if(runtime) var result = runtime(__webpack_require__); +/******/ } +/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data); +/******/ for(;i < chunkIds.length; i++) { +/******/ chunkId = chunkIds[i]; +/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) { +/******/ installedChunks[chunkId][0](); +/******/ } +/******/ installedChunks[chunkId] = 0; +/******/ } +/******/ return __webpack_require__.O(result); +/******/ } +/******/ +/******/ var chunkLoadingGlobal = globalThis["webpackChunkcarhop_blocks"] = globalThis["webpackChunkcarhop_blocks"] || []; +/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0)); +/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal)); +/******/ })(); +/******/ +/************************************************************************/ +/******/ +/******/ // startup +/******/ // Load entry module and return exports +/******/ // This entry module depends on other loaded chunks and execution need to be delayed +/******/ var __webpack_exports__ = __webpack_require__.O(undefined, ["story-timeline/style-index"], () => (__webpack_require__("./src/story-timeline/index.js"))) +/******/ __webpack_exports__ = __webpack_require__.O(__webpack_exports__); +/******/ +/******/ })() +; +//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline/index.js.map b/plugins/carhop-blocks/build/story-timeline/index.js.map new file mode 100644 index 0000000..f6c55a8 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"story-timeline/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAqC;AACgC;AACzB;AACrB;AAAA;AAER,SAASU,IAAIA,CAAC;EAAEC,UAAU;EAAEC,aAAa;EAAE,GAAGC;AAAM,CAAC,EAAE;EACrE,MAAMC,KAAK,GAAGX,0DAAS,CACrBY,MAAM,IAAK;IACX,MAAM;MAAEC;IAAU,CAAC,GAAGD,MAAM,CAAC,mBAAmB,CAAC;IACjD,MAAME,WAAW,GAAGD,SAAS,CAACH,KAAK,CAACK,QAAQ,CAAC,IAAI,EAAE;IACnD,OAAOD,WAAW,CAChBE,MAAM,CAAEC,CAAC,IAAKA,CAAC,CAACC,IAAI,KAAK,mCAAmC,CAAC,CAC7DC,GAAG,CAAEF,CAAC,IAAKA,CAAC,CAACT,UAAU,EAAEY,IAAI,CAAC,CAC9BJ,MAAM,CAAEK,CAAC,IAAKA,CAA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EACVqB,IAAIA,+CAAAA;AACL,CAAC,CAAC,C;;;;;;;;;;;;;;;;;;ACvBmE;AAAA;AAEtD,SAASA,IAAIA,CAAC;EAAEpB;AAAW,CAAC,EAAE;EAC5C,oBAAON,sDAAA,CAACH,gEAAW,CAAC0C,OAAO,IAAE,CAAC;AAC/B,C;;;;;;;;;;;ACJA;;;;;;;;;;;ACAA,6C;;;;;;;;;;ACAA,wC;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,sC;;;;;;;;;;ACAA,2C;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;UAEA;UACA;;;;;WCzBA;WACA;WACA;WACA;WACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,E;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA,E;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA,E;;;;;WCPA,wF;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D,E;;;;;WCNA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,MAAM,qBAAqB;WAC3B;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA,4G;;;;;UEjDA;UACA;UACA;UACA;UACA","sources":["webpack://carhop-blocks/./src/story-timeline/edit.js","webpack://carhop-blocks/./src/story-timeline/editor.scss","webpack://carhop-blocks/./src/story-timeline/index.js","webpack://carhop-blocks/./src/story-timeline/save.js","webpack://carhop-blocks/./src/story-timeline/style.scss","webpack://carhop-blocks/external window [\"wp\",\"blockEditor\"]","webpack://carhop-blocks/external window [\"wp\",\"blocks\"]","webpack://carhop-blocks/external window [\"wp\",\"data\"]","webpack://carhop-blocks/external window [\"wp\",\"i18n\"]","webpack://carhop-blocks/external window \"ReactJSXRuntime\"","webpack://carhop-blocks/webpack/bootstrap","webpack://carhop-blocks/webpack/runtime/chunk loaded","webpack://carhop-blocks/webpack/runtime/compat get default export","webpack://carhop-blocks/webpack/runtime/define property getters","webpack://carhop-blocks/webpack/runtime/hasOwnProperty shorthand","webpack://carhop-blocks/webpack/runtime/make namespace object","webpack://carhop-blocks/webpack/runtime/jsonp chunk loading","webpack://carhop-blocks/webpack/before-startup","webpack://carhop-blocks/webpack/startup","webpack://carhop-blocks/webpack/after-startup"],"sourcesContent":["import { __ } from \"@wordpress/i18n\";\nimport { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\nimport { useSelect } from \"@wordpress/data\";\nimport \"./editor.scss\";\n\nexport default function Edit({ attributes, setAttributes, ...props }) {\n\tconst years = useSelect(\n\t\t(select) => {\n\t\t\tconst { getBlocks } = select(\"core/block-editor\");\n\t\t\tconst childBlocks = getBlocks(props.clientId) || [];\n\t\t\treturn childBlocks\n\t\t\t\t.filter((b) => b.name === \"carhop-blocks/story-timeline-step\")\n\t\t\t\t.map((b) => b.attributes?.year)\n\t\t\t\t.filter((y) => y !== undefined && y !== null && y !== \"\");\n\t\t},\n\t\t[props.clientId]\n\t);\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t\n\t\t\n\t);\n}\n","// extracted by mini-css-extract-plugin\nexport {};","import { registerBlockType } from \"@wordpress/blocks\";\nimport \"./style.scss\";\n\nimport Edit from \"./edit\";\nimport save from \"./save\";\nimport metadata from \"./block.json\";\n\nregisterBlockType(metadata.name, {\n\ticon: {\n\t\tforeground: \"#136f63\",\n\t\tsrc: (\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t),\n\t},\n\tedit: Edit,\n\tsave,\n});\n","import { useBlockProps, InnerBlocks } from \"@wordpress/block-editor\";\n\nexport default function save({ attributes }) {\n\treturn ;\n}\n","// extracted by mini-css-extract-plugin\nexport {};","module.exports = window[\"wp\"][\"blockEditor\"];","module.exports = window[\"wp\"][\"blocks\"];","module.exports = window[\"wp\"][\"data\"];","module.exports = window[\"wp\"][\"i18n\"];","module.exports = window[\"ReactJSXRuntime\"];","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (exports) => {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","// no baseURI\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t\"story-timeline/index\": 0,\n\t\"story-timeline/style-index\": 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = (chunkId) => (installedChunks[chunkId] === 0);\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = (parentChunkLoadingFunction, data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some((id) => (installedChunks[id] !== 0))) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = globalThis[\"webpackChunkcarhop_blocks\"] = globalThis[\"webpackChunkcarhop_blocks\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [\"story-timeline/style-index\"], () => (__webpack_require__(\"./src/story-timeline/index.js\")))\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n",""],"names":["__","useBlockProps","InnerBlocks","useSelect","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","Edit","attributes","setAttributes","props","years","select","getBlocks","childBlocks","clientId","filter","b","name","map","year","y","undefined","children","className","idx","allowedBlocks","registerBlockType","save","metadata","icon","foreground","src","width","height","viewBox","stroke","id","class","d","edit","Content"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline/render.php b/plugins/carhop-blocks/build/story-timeline/render.php new file mode 100644 index 0000000..73edd32 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/render.php @@ -0,0 +1,28 @@ + 'story-timeline')); + +$years = array(); +if (isset($block) && is_object($block) && ! empty($block->inner_blocks)) { + foreach ($block->inner_blocks as $inner_block) { + if (isset($inner_block->name) && $inner_block->name === 'carhop-blocks/story-timeline-step') { + $y = isset($inner_block->attributes['year']) ? $inner_block->attributes['year'] : null; + if ($y !== null && $y !== '') { + $years[] = $y; + } + } + } +} +?> + +
> + +
+ +
+
\ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline/style-index-rtl.css b/plugins/carhop-blocks/build/story-timeline/style-index-rtl.css new file mode 100644 index 0000000..a6b5ad6 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/style-index-rtl.css @@ -0,0 +1,4 @@ +/*!***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline/style.scss ***! + \***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline/style-index.css b/plugins/carhop-blocks/build/story-timeline/style-index.css new file mode 100644 index 0000000..a6b5ad6 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/style-index.css @@ -0,0 +1,4 @@ +/*!***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\ + !*** css ./node_modules/.pnpm/css-loader@6.11.0_webpack@5.103.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.6_webpack@5.103.0/node_modules/postcss-loader/dist/cjs.js??ruleSet[1].rules[4].use[2]!./node_modules/.pnpm/sass-loader@16.0.6_sass@1.94.1_webpack@5.103.0/node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[4].use[3]!./src/story-timeline/style.scss ***! + \***************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/ + diff --git a/plugins/carhop-blocks/build/story-timeline/view.asset.php b/plugins/carhop-blocks/build/story-timeline/view.asset.php new file mode 100644 index 0000000..166aee3 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/view.asset.php @@ -0,0 +1 @@ + array(), 'version' => 'a1583741b597107d2926'); diff --git a/plugins/carhop-blocks/build/story-timeline/view.js b/plugins/carhop-blocks/build/story-timeline/view.js new file mode 100644 index 0000000..e7bbac5 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/view.js @@ -0,0 +1,58 @@ +/******/ (() => { // webpackBootstrap +/*!************************************!*\ + !*** ./src/story-timeline/view.js ***! + \************************************/ +document.addEventListener("DOMContentLoaded", function () { + const timeline = document.querySelector(".wp-block-carhop-blocks-story-timeline"); + if (!timeline) return; + function initBlock() { + const years = timeline.querySelectorAll(".story-timeline__year"); + years.forEach((year, index) => { + year.setAttribute("data-active", index === 0 ? "true" : "false"); + }); + } + function removePreviousActiveLinkInSidebar() { + const activeSidebarLinks = document.querySelectorAll(`.story-timeline__years .story-timeline__year[data-active="true"]`); + activeSidebarLinks.forEach(sidebarLink => { + sidebarLink.setAttribute("data-active", "false"); + }); + } + const timelineStepsProgressionObserver = new IntersectionObserver(entries => { + // Ne pas traiter les entrées si l'observer est en pause (pendant un clic) + // const isIntersetionObserverPaused = getChapterObserverPausedState(); + // if (isIntersetionObserverPaused) return; + + entries.forEach(entry => { + const blockId = entry.target.getAttribute("id"); + const relatedStepLink = document.querySelector(`a[href="#${blockId}"]`); + console.log(relatedStepLink); + if (entry.isIntersecting) { + removePreviousActiveLinkInSidebar(); + // setActiveLinkInSidebar(); + + entry.target.setAttribute("active", "true"); + relatedStepLink?.parentElement?.setAttribute("data-active", "true"); + } + }); + }, { + rootMargin: "-10% 0px -50% 0px" + }); + const timelineSteps = document.querySelectorAll(".story-timeline__innerblocks .wp-block-carhop-blocks-story-timeline-step"); + console.log(timelineSteps); + timelineSteps.forEach(step => { + timelineStepsProgressionObserver.observe(step); + }); + initBlock(); +}); + +// Initialiser les écouteurs de liens +// observeChapterLinks(); + +// // Observer tous les titres h2 de l'article +// const titlesBlocks = document.querySelectorAll('.article-content h2'); +// titlesBlocks.forEach((block) => { +// chapterProgressionObserver.observe(block); +// }); +/******/ })() +; +//# sourceMappingURL=view.js.map \ No newline at end of file diff --git a/plugins/carhop-blocks/build/story-timeline/view.js.map b/plugins/carhop-blocks/build/story-timeline/view.js.map new file mode 100644 index 0000000..c804db8 --- /dev/null +++ b/plugins/carhop-blocks/build/story-timeline/view.js.map @@ -0,0 +1 @@ +{"version":3,"file":"story-timeline/view.js","mappings":";;;;AAAAA,QAAQ,CAACC,gBAAgB,CAAC,kBAAkB,EAAE,YAAY;EACzD,MAAMC,QAAQ,GAAGF,QAAQ,CAACG,aAAa,CACtC,wCACD,CAAC;EACD,IAAI,CAACD,QAAQ,EAAE;EAEf,SAASE,SAASA,CAAA,EAAG;IACpB,MAAMC,KAAK,GAAGH,QAAQ,CAACI,gBAAgB,CAAC,uBAAuB,CAAC;IAChED,KAAK,CAACE,OAAO,CAAC,CAACC,IAAI,EAAEC,KAAK,KAAK;MAC9BD,IAAI,CAACE,YAAY,CAAC,aAAa,EAAED,KAAK,KAAK,CAAC,GAAG,MAAM,GAAG,OAAO,CAAC;IACjE,CAAC,CAAC;EACH;EAEA,SAASE,iCAAiCA,CAAA,EAAG;IAC5C,MAAMC,kBAAkB,GAAGZ,QAAQ,CAACM,gBAAgB,CACnD,kEACD,CAAC;IAEDM,kBAAkB,CAACL,OAAO,CAAEM,WAAW,IAAK;MAC3CA,WAAW,CAACH,YAAY,CAAC,aAAa,EAAE,OAAO,CAAC;IACjD,CAAC,CAAC;EACH;EAEA,MAAMI,gCAAgC,GAAG,IAAIC,oBAAoB,CAC/DC,OAAO,IAAK;IACZ;IACA;IACA;;IAEAA,OAAO,CAACT,OAAO,CAAEU,KAAK,IAAK;MAC1B,MAAMC,OAAO,GAAGD,KAAK,CAACE,MAAM,CAACC,YAAY,CAAC,IAAI,CAAC;MAC/C,MAAMC,eAAe,GAAGrB,QAAQ,CAACG,aAAa,CAAC,YAAYe,OAAO,IAAI,CAAC;MACvEI,OAAO,CAACC,GAAG,CAACF,eAAe,CAAC;MAE5B,IAAIJ,KAAK,CAACO,cAAc,EAAE;QACzBb,iCAAiC,CAAC,CAAC;QACnC;;QAEAM,KAAK,CAACE,MAAM,CAACT,YAAY,CAAC,QAAQ,EAAE,MAAM,CAAC;QAC3CW,eAAe,EAAEI,aAAa,EAAEf,YAAY,CAAC,aAAa,EAAE,MAAM,CAAC;MACpE;IACD,CAAC,CAAC;EACH,CAAC,EACD;IACCgB,UAAU,EAAE;EACb,CACD,CAAC;EAED,MAAMC,aAAa,GAAG3B,QAAQ,CAACM,gBAAgB,CAC9C,0EACD,CAAC;EACDgB,OAAO,CAACC,GAAG,CAACI,aAAa,CAAC;EAC1BA,aAAa,CAACpB,OAAO,CAAEqB,IAAI,IAAK;IAC/Bd,gCAAgC,CAACe,OAAO,CAACD,IAAI,CAAC;EAC/C,CAAC,CAAC;EAEFxB,SAAS,CAAC,CAAC;AACZ,CAAC,CAAC;;AAEF;AACA;;AAEA;AACA;AACA;AACA;AACA,M","sources":["webpack://carhop-blocks/./src/story-timeline/view.js"],"sourcesContent":["document.addEventListener(\"DOMContentLoaded\", function () {\r\n\tconst timeline = document.querySelector(\r\n\t\t\".wp-block-carhop-blocks-story-timeline\"\r\n\t);\r\n\tif (!timeline) return;\r\n\r\n\tfunction initBlock() {\r\n\t\tconst years = timeline.querySelectorAll(\".story-timeline__year\");\r\n\t\tyears.forEach((year, index) => {\r\n\t\t\tyear.setAttribute(\"data-active\", index === 0 ? \"true\" : \"false\");\r\n\t\t});\r\n\t}\r\n\r\n\tfunction removePreviousActiveLinkInSidebar() {\r\n\t\tconst activeSidebarLinks = document.querySelectorAll(\r\n\t\t\t`.story-timeline__years .story-timeline__year[data-active=\"true\"]`\r\n\t\t);\r\n\r\n\t\tactiveSidebarLinks.forEach((sidebarLink) => {\r\n\t\t\tsidebarLink.setAttribute(\"data-active\", \"false\");\r\n\t\t});\r\n\t}\r\n\r\n\tconst timelineStepsProgressionObserver = new IntersectionObserver(\r\n\t\t(entries) => {\r\n\t\t\t// Ne pas traiter les entrées si l'observer est en pause (pendant un clic)\r\n\t\t\t// const isIntersetionObserverPaused = getChapterObserverPausedState();\r\n\t\t\t// if (isIntersetionObserverPaused) return;\r\n\r\n\t\t\tentries.forEach((entry) => {\r\n\t\t\t\tconst blockId = entry.target.getAttribute(\"id\");\r\n\t\t\t\tconst relatedStepLink = document.querySelector(`a[href=\"#${blockId}\"]`);\r\n\t\t\t\tconsole.log(relatedStepLink);\r\n\r\n\t\t\t\tif (entry.isIntersecting) {\r\n\t\t\t\t\tremovePreviousActiveLinkInSidebar();\r\n\t\t\t\t\t// setActiveLinkInSidebar();\r\n\r\n\t\t\t\t\tentry.target.setAttribute(\"active\", \"true\");\r\n\t\t\t\t\trelatedStepLink?.parentElement?.setAttribute(\"data-active\", \"true\");\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t},\r\n\t\t{\r\n\t\t\trootMargin: \"-10% 0px -50% 0px\",\r\n\t\t}\r\n\t);\r\n\r\n\tconst timelineSteps = document.querySelectorAll(\r\n\t\t\".story-timeline__innerblocks .wp-block-carhop-blocks-story-timeline-step\"\r\n\t);\r\n\tconsole.log(timelineSteps);\r\n\ttimelineSteps.forEach((step) => {\r\n\t\ttimelineStepsProgressionObserver.observe(step);\r\n\t});\r\n\r\n\tinitBlock();\r\n});\r\n\r\n// Initialiser les écouteurs de liens\r\n// observeChapterLinks();\r\n\r\n// // Observer tous les titres h2 de l'article\r\n// const titlesBlocks = document.querySelectorAll('.article-content h2');\r\n// titlesBlocks.forEach((block) => {\r\n// chapterProgressionObserver.observe(block);\r\n// });\r\n"],"names":["document","addEventListener","timeline","querySelector","initBlock","years","querySelectorAll","forEach","year","index","setAttribute","removePreviousActiveLinkInSidebar","activeSidebarLinks","sidebarLink","timelineStepsProgressionObserver","IntersectionObserver","entries","entry","blockId","target","getAttribute","relatedStepLink","console","log","isIntersecting","parentElement","rootMargin","timelineSteps","step","observe"],"ignoreList":[],"sourceRoot":""} \ No newline at end of file