| 1 |
<?php |
| 2 |
/** |
| 3 |
* Plugin Name: Tableberg |
| 4 |
* Description: Tableberg: table builder Gutenberg block |
| 5 |
* Version: 0.0.2 |
| 6 |
* Requires at least: 6.1 |
| 7 |
* Requires PHP: 7.0 |
| 8 |
* Author: Dotcamp |
| 9 |
* License: GPL-2.0-or-later |
| 10 |
* License URI: https://www.gnu.org/licenses/gpl-2.0.html |
| 11 |
* Text Domain: tableberg |
| 12 |
* |
| 13 |
* @package Tableberg |
| 14 |
*/ |
| 15 |
|
| 16 |
if ( ! defined( 'ABSPATH' ) ) { |
| 17 |
exit; // Exit if accessed directly. |
| 18 |
} |
| 19 |
|
| 20 |
if ( ! defined( 'TABLEBERG_DIR_PATH' ) ) { |
| 21 |
define( 'TABLEBERG_DIR_PATH', plugin_dir_path( __FILE__ ) ); |
| 22 |
} |
| 23 |
|
| 24 |
if ( ! defined( 'TABLEBERG_URL' ) ) { |
| 25 |
define( 'TABLEBERG_URL', plugin_dir_url( __FILE__ ) ); |
| 26 |
} |
| 27 |
|
| 28 |
require_once __DIR__ . '/vendor/autoload.php'; |
| 29 |
|
| 30 |
if ( ! class_exists( 'Tableberg' ) ) { |
| 31 |
/** |
| 32 |
* External Query Block main class. |
| 33 |
*/ |
| 34 |
class Tableberg { |
| 35 |
|
| 36 |
|
| 37 |
/** |
| 38 |
* Constructor. |
| 39 |
* |
| 40 |
* @return void |
| 41 |
*/ |
| 42 |
public function __construct() { |
| 43 |
new Tableberg\Blocks\Button(); |
| 44 |
new Tableberg\Blocks\Image(); |
| 45 |
new Tableberg\Blocks\Table(); |
| 46 |
new Tableberg\Blocks\Cell(); |
| 47 |
new Tableberg\Blocks\Row(); |
| 48 |
} |
| 49 |
} |
| 50 |
|
| 51 |
new Tableberg(); |
| 52 |
} |
| 53 |
|