fields
4 months ago
images
7 months ago
modules
1 day ago
DiviAmelia.php
5 years ago
DiviAmeliaWhiteLabelHelper.php
1 day ago
loader.php
1 day ago
DiviAmeliaWhiteLabelHelper.php
32 lines
| 1 | <?php |
| 2 | |
| 3 | use AmeliaBooking\Infrastructure\WP\ShortcodeService\ShortcodeAliasService; |
| 4 | |
| 5 | class DIVI_AmeliaWhiteLabelHelper |
| 6 | { |
| 7 | /** |
| 8 | * Resolve module picker titles. |
| 9 | * |
| 10 | * - No white label: "{pluginName} - Form" → "Amelia - Form". |
| 11 | * - White label + custom plugin name: "CustomName - Form". |
| 12 | * - White label without custom name: "Amelia - Form" (default). |
| 13 | * |
| 14 | * @param string $label |
| 15 | * |
| 16 | * @return string |
| 17 | */ |
| 18 | public static function label($label) |
| 19 | { |
| 20 | return str_replace( |
| 21 | '{pluginName}', |
| 22 | ShortcodeAliasService::getBuilderBrandName(), |
| 23 | $label |
| 24 | ); |
| 25 | } |
| 26 | |
| 27 | public static function shortcodeTag($view, $legacyTag) |
| 28 | { |
| 29 | return ShortcodeAliasService::activeShortcodeTag($view, $legacyTag); |
| 30 | } |
| 31 | } |
| 32 |