feat: adapter-level Divi release lock, content-create and site status
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -6,6 +6,7 @@ namespace LIT\MCP\Integrations\Core;
|
||||
|
||||
use LIT\MCP\Integrations\Divi\DiviCompatibility;
|
||||
use LIT\MCP\Integrations\Divi\Release\DiviEnvironment;
|
||||
use LIT\MCP\Integrations\Divi\Release\ReleaseGate;
|
||||
|
||||
defined('ABSPATH') || exit;
|
||||
|
||||
@@ -19,7 +20,10 @@ class EnvironmentProbe
|
||||
{
|
||||
}
|
||||
|
||||
/** @return list<array{id: string, active: bool, version: ?string, problems: list<string>}> */
|
||||
/**
|
||||
* @return list<array{id: string, active: bool, version: ?string, problems: list<string>,
|
||||
* release: ?array<string, mixed>}>
|
||||
*/
|
||||
public function components(): array
|
||||
{
|
||||
$diviVersion = DiviEnvironment::version();
|
||||
@@ -33,18 +37,21 @@ class EnvironmentProbe
|
||||
'active' => $isDivi,
|
||||
'version' => $diviVersion,
|
||||
'problems' => $isDivi ? ($this->divi ?? new DiviCompatibility())->problems() : [],
|
||||
'release' => $isDivi ? ReleaseGate::status()->toArray() : null,
|
||||
],
|
||||
[
|
||||
'id' => 'pods',
|
||||
'active' => defined('PODS_VERSION'),
|
||||
'version' => defined('PODS_VERSION') ? (string) PODS_VERSION : null,
|
||||
'problems' => [],
|
||||
'release' => null,
|
||||
],
|
||||
[
|
||||
'id' => 'the-events-calendar',
|
||||
'active' => $tecActive,
|
||||
'version' => $tecActive ? (string) constant('Tribe__Events__Main::VERSION') : null,
|
||||
'problems' => [],
|
||||
'release' => null,
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
@@ -31,7 +31,8 @@ final class SiteStatusAbility implements Ability
|
||||
{
|
||||
return 'Überblick: Website, WordPress-Version, eigener Benutzer und Rollen, '
|
||||
. 'erkannte Integrationen (Divi, Pods, The Events Calendar). '
|
||||
. 'Bei Divi nennt problems Divi-Funktionen, die nach einem Update fehlen.';
|
||||
. 'Bei Divi nennt problems Divi-Stellen, die nach einem Update fehlen oder sich geändert haben, und '
|
||||
. 'release, ob LIT MCP mit dieser Divi-Version schreiben darf (released, untested, incompatible).';
|
||||
}
|
||||
|
||||
public function inputSchema(): array
|
||||
|
||||
Reference in New Issue
Block a user