PluginProbe ʕ •ᴥ•ʔ
Kubio AI Page Builder / 1.7.0
Kubio AI Page Builder v1.7.0
2.8.1 trunk 1.0.0 1.0.1 1.1.0 1.2.0 1.2.1 1.2.2 1.2.3 1.3.0 1.3.1 1.3.2 1.4.0 1.4.1 1.4.2 1.4.3 1.5.0 1.6.0 1.6.1 1.6.2 1.6.3 1.6.4 1.7.0 1.7.1 1.7.2 1.7.3 1.8.0 1.8.1 1.8.2 1.9.0 2.0.0 2.1.1 2.1.2 2.1.3 2.2.0 2.2.3 2.2.4 2.2.5 2.3.0 2.3.1 2.3.3 2.3.4 2.4.0 2.4.1 2.4.2 2.4.3 2.4.5 2.5.0 2.5.1 2.5.2 2.5.3 2.6.0 2.6.1 2.6.2 2.6.3 2.6.5 2.6.6 2.6.7 2.7.0 2.7.1 2.7.2 2.7.3 2.8.0
kubio / lib / init.php
kubio / lib Last commit date
admin-pages 3 years ago api 3 years ago blog 3 years ago customizer 3 years ago filters 3 years ago full-site-editing 3 years ago importer 4 years ago integrations 3 years ago menu 3 years ago polyfills 3 years ago preview 3 years ago shapes 4 years ago shortcodes 3 years ago src 3 years ago add-edit-in-kubio.php 3 years ago editor-assets.php 3 years ago env.php 3 years ago filters.php 3 years ago frontend.php 4 years ago global-data.php 3 years ago init.php 4 years ago kubio-block-library.php 4 years ago kubio-editor.php 3 years ago load.php 3 years ago
init.php
46 lines
1 <?php
2
3 function kubio_plugin_activated() {
4 $experimental_options = get_option( 'gutenberg-experiments', array() );
5 if ( ! is_array( $experimental_options ) ) {
6 $experimental_options = array( $experimental_options );
7 }
8 $experimental_options['gutenberg-navigation'] = 1;
9 $experimental_options['gutenberg-widget-experiments'] = 1;
10
11 update_option( 'gutenberg-experiments', $experimental_options );
12 do_action( 'kubio/plugin_activated' );
13 }
14
15 function kubio_plugin_deactivated() {
16
17 $active_plugins = get_option( 'active_plugins' );
18 $pro_builder_is_active = in_array( 'kubio-pro/plugin.php', $active_plugins );
19
20 if ( ! kubio_is_pro() && $pro_builder_is_active ) {
21 return;
22 }
23
24 do_action( 'kubio/plugin_deactivated' );
25 }
26
27 function kubio_enable_block_support() {
28 add_theme_support( 'block-templates' );
29
30 if(!current_theme_supports( 'align-wide' )) {
31 add_theme_support( 'align-wide' );
32 }
33
34 }
35
36 function kubio_plugin_init() {
37 require_once plugin_dir_path( __FILE__ ) . '/load.php';
38 add_filter( 'kubio_is_enabled', '__return_true' );
39
40 register_activation_hook( KUBIO_ENTRY_FILE, 'kubio_plugin_activated' );
41 register_deactivation_hook( KUBIO_ENTRY_FILE, 'kubio_plugin_deactivated' );
42 add_action( 'after_setup_theme', 'kubio_enable_block_support', 500 );
43 }
44
45 kubio_plugin_init();
46