Skip to content

Conversation

dabrt
Copy link
Contributor

@dabrt dabrt commented Oct 16, 2025

Question Answer
JIRA Ticket IBX-10163
Versions 4.6, 5.0
Edition all

Document the integrated help LTS update

TODO:

  1. Move code samples to relevant external files
  2. Replace mockuos with actual screenshots

Checklist

  • Text renders correctly
  • Text has been checked with vale
  • Description metadata is up to date
  • PHP code samples have been fixed with PHP CS fixer
  • Added link to this PR in relevant JIRA ticket or code PR

Copy link

@dabrt dabrt requested a review from wiewiurdp October 16, 2025 15:27
Copy link

code_samples/ change report

Before (on target branch)After (in current PR)

code_samples/back_office/menu/menu_item/src/EventSubscriber/HelpMenuSubscriber.php


code_samples/back_office/menu/menu_item/src/EventSubscriber/HelpMenuSubscriber.php

docs/administration/back_office/customize_integrated_help.md@72:``` php
docs/administration/back_office/customize_integrated_help.md@73:[[= include_file('code_samples/back_office/menu/menu_item/src/EventSubscriber/HelpMenuSubscriber.php') =]]
docs/administration/back_office/customize_integrated_help.md@74:```

001⫶<?php
002⫶
003⫶declare(strict_types=1);
004⫶
005⫶namespace App\EventSubscriber;
006⫶
007⫶use Symfony\Component\EventDispatcher\EventSubscriberInterface;
008⫶use Symfony\Contracts\EventDispatcher\Event;
009⫶
010⫶final class HelpMenuSubscriber implements EventSubscriberInterface
011⫶{
012⫶ public function __construct(
013⫶ private readonly bool $kernelDebug
014⫶ ) {}
015⫶
016⫶ public static function getSubscribedEvents(): array
017⫶ {
018⫶ return [
019⫶ 'ibexa_integrated_help.menu_configure.help_menu' => 'onHelpMenuConfigure',
020⫶ ];
021⫶ }
022⫶
023⫶ public function onHelpMenuConfigure(Event $event): void
024⫶ {
025⫶ $menu = $event->getMenu();
026⫶
027⫶ // Remove roadmap menu item
028⫶ if ($menu->getChild('help__general')) {
029⫶ $generalSection = $menu->getChild('help__general');
030⫶ if ($generalSection->getChild('help__product_roadmap')) {
031⫶ $generalSection->removeChild('help__product_roadmap');
032⫶ }
033⫶ }
034⫶
035⫶ // Add videos tab, shown only in production
036⫶ if ($this->kernelDebug === false) {
037⫶ $resourcesSection = $menu->addChild('help__videos', [
038⫶ 'label' => 'Product videos',
039⫶ ]);
040⫶
041⫶ $resourcesSection->addChild('help__webinar_v5', [
042⫶ 'label' => 'Webinar: Introducing Ibexa DXP v5',
043⫶ 'uri' => 'https://www.youtube.com/watch?v=qWaBHG2LRm8',
044⫶ 'extras' => [
045⫶ 'isHighlighted' => false,
046⫶ 'icon' => 'https://doc.ibexa.co/en/5.0/templating/twig_function_reference/img/icons/video.svg.png',
047⫶ 'description' => 'Discover new features and improvements brought by Ibexa DXP v5.',
048⫶ ],
049⫶ ]);
050⫶ }
051⫶ }
052⫶}

Download colorized diff

@dabrt dabrt requested a review from AnnaKaih October 17, 2025 08:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants