refactor: Remove legacy roi_get_option() calls from Inc/ files

- Clean Inc/adsense-delay.php
- Clean Inc/category-badge.php
- Clean Inc/enqueue-scripts.php
- Clean Inc/featured-image.php
- Clean Inc/social-share.php
- Clean sidebar.php - use roi_render_component('table-of-contents')
- Add roi_get_component_setting() helper to functions-addon.php

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
FrankZamora
2025-11-26 21:58:44 -06:00
parent 7a8daa72c6
commit 8878afe168
7 changed files with 117 additions and 120 deletions

View File

@@ -24,9 +24,9 @@ if (!defined('ABSPATH')) {
* @return string HTML del badge de categoría o string vacío
*/
function roi_get_category_badge() {
// Verificar si la función está habilitada en las opciones del tema
$enabled = roi_get_option('show_category_badge', true);
if (!$enabled) {
// Verificar si la función está habilitada (Clean Architecture)
$is_enabled = roi_get_component_setting('category-badge', 'visibility', 'is_enabled', true);
if (!$is_enabled) {
return '';
}