few fixes

This commit is contained in:
Antoine M 2024-07-04 10:13:22 +02:00
parent 9ec7cba8c9
commit 7522ebb9ea
6 changed files with 4 additions and 6 deletions

View File

@ -1 +1 @@
<?php return array('dependencies' => array('react', 'wp-block-editor', 'wp-blocks', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n'), 'version' => 'd735e42cab437d8c526f');
<?php return array('dependencies' => array('react', 'wp-block-editor', 'wp-blocks', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n'), 'version' => '9fc901c23a6f2db0e80d');

View File

@ -114,7 +114,6 @@ function Edit({
}
function buildTooltipWords() {
let newParsedTooltipWords = parseContentTooltips(currentPost.content);
console.log("qsdqsd", newParsedTooltipWords);
let newBlocksTooltipWords = parseBlocksTooltips(currentBlocks);
let allTooltipWords = [...newParsedTooltipWords, ...newBlocksTooltipWords];
const filteredTooltipWords = filterToolTipsArray(allTooltipWords);

File diff suppressed because one or more lines are too long

View File

@ -18,7 +18,7 @@ $thematique = get_the_terms($post->ID, 'thematiques')[0] ?? null;
<section id="vocabulaire-summary" class="homegrade-blocks-vocabulaire-summary">
<h2 className="homegrade-blocks-vocabulaire-summary__title">
<?php echo __("Vocabulaire", "homegrade-blocks") ?><?php echo $thematique->name ? " — " . $thematique->name : ""; ?>
<?php echo __("Vocabulaire", "homegrade-blocks") ?><?php echo $thematique && $thematique->name ? " — " . $thematique->name : ""; ?>
</h2>
<?php foreach ($tooltipWords as $word) : ?>

View File

@ -99,7 +99,6 @@ export default function Edit({ attributes, setAttributes }) {
}
function buildTooltipWords() {
let newParsedTooltipWords = parseContentTooltips(currentPost.content);
console.log("qsdqsd", newParsedTooltipWords);
let newBlocksTooltipWords = parseBlocksTooltips(currentBlocks);
let allTooltipWords = [...newParsedTooltipWords, ...newBlocksTooltipWords];
const filteredTooltipWords = filterToolTipsArray(allTooltipWords);

View File

@ -18,7 +18,7 @@ $thematique = get_the_terms($post->ID, 'thematiques')[0] ?? null;
<section id="vocabulaire-summary" class="homegrade-blocks-vocabulaire-summary">
<h2 className="homegrade-blocks-vocabulaire-summary__title">
<?php echo __("Vocabulaire", "homegrade-blocks") ?><?php echo $thematique->name ? " — " . $thematique->name : ""; ?>
<?php echo __("Vocabulaire", "homegrade-blocks") ?><?php echo $thematique && $thematique->name ? " — " . $thematique->name : ""; ?>
</h2>
<?php foreach ($tooltipWords as $word) : ?>