PluginProbe ʕ •ᴥ•ʔ
Kubio AI Page Builder / 2.4.5
Kubio AI Page Builder v2.4.5
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
AI 1 year ago admin-pages 2 years ago api 1 year ago blog 3 years ago customizer 2 years ago filters 1 year ago full-site-editing 2 years ago importer 4 years ago integrations 1 year ago menu 3 years ago polyfills 3 years ago preview 2 years ago shapes 2 years ago shortcodes 1 year ago src 1 year ago add-edit-in-kubio.php 1 year ago editor-assets.php 1 year ago env.php 1 year ago filters.php 1 year ago frontend.php 4 years ago global-data.php 1 year ago init.php 2 years ago kubio-block-library.php 2 years ago kubio-editor.php 1 year ago load.php 1 year ago
init.php
50 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 if ( ! current_theme_supports( 'align-full' ) ) {
35 add_theme_support( 'align-full' );
36 }
37
38 }
39
40 function kubio_plugin_init() {
41 require_once plugin_dir_path( __FILE__ ) . '/load.php';
42 add_filter( 'kubio_is_enabled', '__return_true' );
43
44 register_activation_hook( KUBIO_ENTRY_FILE, 'kubio_plugin_activated' );
45 register_deactivation_hook( KUBIO_ENTRY_FILE, 'kubio_plugin_deactivated' );
46 add_action( 'after_setup_theme', 'kubio_enable_block_support', 500 );
47 }
48
49 kubio_plugin_init();
50