PluginProbe
Elementor Website Builder – more than just a page builder / 4.2.0
Elementor Website Builder – more than just a page builder v4.2.0
4.3.0-beta2 4.3.0-beta1 4.2.4 4.2.3 4.2.2 4.2.1 4.2.0 4.1.5 4.2.0-beta2 4.2.0-dev2 4.2.0-beta1 4.1.4 4.1.3 4.1.2 4.1.1 4.1.0 4.1.0-beta3 4.1.0-dev3 4.0.9 4.1.0-beta2 4.1.0-dev2 4.0.8 4.1.0-beta1 4.1.0-dev1 4.0.7 All 451 releases
elementor / modules / apps / module.php

module.php in Elementor Website Builder – more than just a page builder 4.2.0, at modules/apps/module.php

52 lines 1.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 namespace Elementor\Modules\Apps;
3
4 use Elementor\Core\Base\Module as BaseModule;
5
6 if ( ! defined( 'ABSPATH' ) ) {
7 exit; // Exit if accessed directly.
8 }
9
10 class Module extends BaseModule {
11
12 const PAGE_ID = 'elementor-apps';
13
14 public function get_name() {
15 return 'apps';
16 }
17
18 public function __construct() {
19 parent::__construct();
20
21 Admin_Pointer::add_hooks();
22
23 add_filter( 'elementor/finder/categories', function( array $categories ) {
24 $categories['site']['items']['apps'] = [
25 'title' => esc_html__( 'Add-ons', 'elementor' ),
26 'url' => admin_url( 'admin.php?page=' . static::PAGE_ID ),
27 'icon' => 'apps',
28 'keywords' => [ 'apps', 'addon', 'plugin', 'extension', 'integration' ],
29 ];
30
31 return $categories;
32 } );
33 }
34
35 public function enqueue_assets() {
36 add_filter( 'admin_body_class', [ $this, 'body_status_classes' ] );
37
38 wp_enqueue_style(
39 'elementor-apps',
40 $this->get_css_assets_url( 'modules/apps/admin' ),
41 [],
42 ELEMENTOR_VERSION
43 );
44 }
45
46 public function body_status_classes( $admin_body_classes ) {
47 $admin_body_classes .= ' elementor-apps-page';
48
49 return $admin_body_classes;
50 }
51 }
52