<?php
namespace NeoAnimateBeta\NeoDraw; if (!defined("ABSPATH")) { die("neoWP direct access not allowed"); }




\NeoAnimateBeta\NeoGlobal\add_action_hook("load-post.php",     function () { if (!\NeoAnimateBeta\NeoGlobal\current_user_can__neo_draw()) { return; } \NeoAnimateBeta\NeoGlobal\enqueue_css("neo-draw--pb-old-media-library-dialog.css"); });
\NeoAnimateBeta\NeoGlobal\add_action_hook("load-post-new.php", function () { if (!\NeoAnimateBeta\NeoGlobal\current_user_can__neo_draw()) { return; } \NeoAnimateBeta\NeoGlobal\enqueue_css("neo-draw--pb-old-media-library-dialog.css"); });


\NeoAnimateBeta\NeoGlobal\add_filter_hook("media_upload_tabs:200", function ($tabs) { if (!\NeoAnimateBeta\NeoGlobal\current_user_can__neo_draw()) { return $tabs; } return array_merge($tabs, ["neodraw" => \NeoAnimateBeta\NeoGlobal\neo__("Create with neoDraw", "Mit neoDraw erstellen")]); });
\NeoAnimateBeta\NeoGlobal\add_action_hook("media_upload_neodraw", function () {
    if (!\NeoAnimateBeta\NeoGlobal\current_user_can__neo_draw()) { return; }
    \NeoAnimateBeta\NeoGlobal\enqueue_js("neo-draw--pb-old-media-library-dialog.js");
    \NeoAnimateBeta\NeoGlobal\enqueue_css("neo-draw--pb-old-media-library-dialog.css");
    return wp_iframe(__NAMESPACE__ . "\\draw_pagebuilder_init");
});
