PluginProbe ʕ •ᴥ•ʔ
Kubio AI Page Builder / trunk
Kubio AI Page Builder vtrunk
2.9.0 2.8.6 2.8.5 2.8.4 2.8.3 2.8.2 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 11 months ago admin-pages 1 month ago api 1 month ago blog 1 year ago customizer 1 year ago filters 1 week ago full-site-editing 3 months ago importer 1 year ago integrations 1 week ago menu 1 year ago polyfills 1 year ago preview 9 months ago recommendations 3 months ago shapes 2 years ago shortcodes 1 year ago src 1 week ago add-edit-in-kubio.php 1 year ago editor-assets.php 1 week ago filters.php 1 year ago frontend.php 1 year ago global-data.php 1 year ago init.php 1 year ago kubio-block-library.php 3 months ago kubio-editor.php 1 week ago load.php 3 months ago
init.php
48 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 $run_deactivation = apply_filters( 'kubio/run_deactivation_hooks', false );
18
19 if ( ! $run_deactivation ) {
20 return;
21 }
22
23 do_action( 'kubio/plugin_deactivated' );
24 }
25
26 function kubio_enable_block_support() {
27 add_theme_support( 'block-templates' );
28
29 if ( ! current_theme_supports( 'align-wide' ) ) {
30 add_theme_support( 'align-wide' );
31 }
32
33 if ( ! current_theme_supports( 'align-full' ) ) {
34 add_theme_support( 'align-full' );
35 }
36 }
37
38 function kubio_plugin_init() {
39 require_once plugin_dir_path( __FILE__ ) . '/load.php';
40 add_filter( 'kubio_is_enabled', '__return_true' );
41
42 register_activation_hook( KUBIO_ENTRY_FILE, 'kubio_plugin_activated' );
43 register_deactivation_hook( KUBIO_ENTRY_FILE, 'kubio_plugin_deactivated' );
44 add_action( 'after_setup_theme', 'kubio_enable_block_support', 500 );
45 }
46
47 kubio_plugin_init();
48