Commit inicial - WordPress Análisis de Precios Unitarios

- WordPress core y plugins
- Tema Twenty Twenty-Four configurado
- Plugin allow-unfiltered-html.php simplificado
- .gitignore configurado para excluir wp-config.php y uploads

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
root
2025-11-03 21:04:30 -06:00
commit a22573bf0b
24068 changed files with 4993111 additions and 0 deletions

View File

@@ -0,0 +1,137 @@
<?php
$animationClasses = [];
foreach ( array_keys( $this->_animations ) as $animation ) {
$animationClasses [] = 'tve_lb_anim_' . $animation;
}
$animationClasses = implode( ' ', $animationClasses );
/* adding <script type="text/javascript"> just for editor autocompletion */
?>
<script type="text/javascript">
function (trigger, action, config) {
function getBrowserScrollSize() {
var $ = jQuery;
var css = {
"border": "none",
"height": "200px",
"margin": "0",
"padding": "0",
"width": "200px"
};
var inner = $("<div>").css($.extend({}, css));
var outer = $("<div>").css($.extend({
"left": "-1000px",
"overflow": "scroll",
"position": "absolute",
"top": "-1000px"
}, css)).append(inner).appendTo("body")
.scrollLeft(1000)
.scrollTop(1000);
var scrollSize = {
"height": (outer.offset().top - inner.offset().top) || 0,
"width": (outer.offset().left - inner.offset().left) || 0
};
outer.remove();
return scrollSize;
}
var $target = jQuery("#tve_thrive_lightbox_" + config.l_id).css('display', ''),
animation = config.l_anim ? config.l_anim : "instant",
$body = jQuery('body'),
$html = jQuery('html'),
overflow_hidden = 'tve-o-hidden tve-l-open tve-hide-overflow',
scroll_width = getBrowserScrollSize().width,
oPadding = parseInt($body.css('padding-right'));
function close_it($lightbox, skip_body_scroll) {
$lightbox.find('.thrv_responsive_video iframe, .thrv_responsive_video video').each(function () {
var $this = jQuery(this);
$this.attr('data-src', $this.attr('src'));
$this.attr('src', '');
});
$lightbox.removeClass('tve_lb_open tve_lb_opening').addClass('tve_lb_closing');
if (typeof skip_body_scroll === 'undefined') {
$body.removeClass(overflow_hidden).css('padding-right', '');
$html.removeClass(overflow_hidden)
}
setTimeout(function () {
$lightbox.attr('class', '').css('display', 'none').find('tve_p_lb_content').trigger('tve.lightbox-close');
}, 300);
}
$target.off().on("click", ".tve_p_lb_close", function () {
close_it($target);
});
$body.off('keyup.tve_lb_close').on('keyup.tve_lb_close', function (e) {
if (e.which == 27) {
close_it($target);
}
});
$target.children('.tve_p_lb_overlay').off('click.tve_lb_close').on('click.tve_lb_close', function () {
close_it($target);
});
/* close any other opened lightboxes */
close_it(jQuery('.tve_p_lb_background.tve_lb_open'), true);
$target.addClass('tve_p_lb_background tve_lb_anim_' + animation);
$body.addClass(overflow_hidden);
$html.addClass(overflow_hidden);
var wHeight = jQuery(window).height(),
page_has_scroll = wHeight < jQuery(document).height();
if (page_has_scroll) {
$body.css('padding-right', (oPadding + scroll_width) + 'px');
}
$target.find('.thrv_responsive_video iframe, .thrv_responsive_video video').each(function () {
var $this = jQuery(this);
if ($this.attr('data-src')) {
$this.attr('src', $this.attr('data-src'));
}
});
setTimeout(function () {
$target.addClass('tve_lb_opening');
/* reload any iframe that might be in there, this was causing issues with google maps embeds in hidden tabs */
$target.find('iframe').each(function () {
var $this = jQuery(this);
if ($this.data('tve_ifr_loaded')) {
return;
}
$this.data('tve_ifr_loaded', 1).attr('src', $this.attr('src'));
});
setTimeout(function () {
var $lContent = $target.find('.tve_p_lb_content'),
cHeight = $lContent.outerHeight(true),
top = (wHeight - cHeight) / 2;
$target.find('.tve_p_lb_overlay').css({
height: (cHeight + 80) + 'px',
'min-height': wHeight + 'px'
});
$lContent.css('top', (top < 40 ? 40 : top) + 'px');
if (cHeight + 40 > wHeight) {
$target.addClass('tve-scroll');
}
}, 0);
}, 20);
setTimeout(function () {
$target.removeClass('tve_lb_opening').addClass('tve_lb_open').find('.tve_p_lb_content').trigger('tve.lightbox-open');
}, 300);
return false;
}
;
</script>

View File

@@ -0,0 +1,29 @@
<script type="text/javascript">
(function ($) {
/* Chrome has a stupid bug in which it triggers almost simultaneously "mouseenter" "mouseleave" "mouseenter" if the following applies:
- at page load, the cursor is outside the html element
- the user moves the cursor over the html element
*/
var chrome_fix_id = 0,
me = function (e) { /* mouse enter */
clearTimeout(chrome_fix_id);
},
ml = function (e) {
if (e.clientY <= config.s) {
chrome_fix_id = setTimeout(function () {
$(document).trigger('tve-page-event-exit');
}, 50);
}
},
config = { // we can adjust this and the code below to allow users to tweak settings
s: 20 // sensitivity
};
$(function () {
$(document).on('mouseleave.exit_intent', ml)
.on('mouseenter.exit_intent', me);
});
})(jQuery);
</script>

View File

@@ -0,0 +1,88 @@
<script type="text/javascript">
( function ( $ ) {
var $window = $( window ),
trigger_elements = function ( elements ) {
elements.each( function () {
var $elem = $( this ),
lb_content = $elem.parents( '.tve_p_lb_content' ),
ajax_content = $elem.parents( '.ajax-content' ),
inViewport = TCB_Front.isInViewport( $elem ) || isOutsideBody( $elem ) || isAtTheBottomOfThePage( $elem );
if ( lb_content.length ) {
lb_content.on( 'tve.lightbox-open', function () {
if ( ! $elem.hasClass( 'tve-viewport-triggered' ) ) {
$elem.trigger( 'tve-viewport' ).addClass( 'tve-viewport-triggered' );
}
} );
return;
}
if ( ajax_content.length ) {
ajax_content.on( 'content-inserted.tcb', function () {
if ( inViewport && ! $elem.hasClass( 'tve-viewport-triggered' ) ) {
$elem.trigger( 'tve-viewport' ).addClass( 'tve-viewport-triggered' );
}
} );
return;
}
if ( inViewport ) {
$elem.trigger( 'tve-viewport' ).addClass( 'tve-viewport-triggered' );
}
} );
},
trigger_exit = function ( elements ) {
elements.each( function () {
var $elem = $( this );
if ( ! ( TCB_Front.isInViewport( $elem ) || isOutsideBody( $elem ) ) ) {
$elem.trigger( 'tve-viewport-leave' ).removeClass( 'tve-viewport-triggered' );
}
} );
},
/**
* Returns true if the element is located at the bottom of the page and the element is in viewport
*/
isAtTheBottomOfThePage = function ( $elem ) {
return TCB_Front.isInViewport( $elem, 0 ) && $window.scrollTop() >= parseInt( $elem.offset().top + $elem.outerHeight() - window.innerHeight );
},
/**
* Check if element is always outside of the viewport, is above the top scroll
* @param element
* @returns {boolean}
*/
isOutsideBody = function ( element ) {
if ( element.jquery ) {
element = element[ 0 ];
}
var rect = element.getBoundingClientRect();
/* we've scrolled maximum to the top, but the element is above */
return window.scrollY + rect.bottom < 0;
/* leaving this commented, can be added if more bugs appear. it checks for bottom elements
var $window = ThriveGlobal.$j( window ),
scrolledToBottom = $window.scrollTop() + $window.height() === ThriveGlobal.$j( document ).height();
return ( scrolledToBottom && rect.top > ( window.innerHeight - delta ) );
*/
};
$( document ).ready( function () {
window.tar_trigger_viewport = trigger_elements;
window.tar_trigger_exit_viewport = trigger_exit;
let $to_test = $( '.tve_et_tve-viewport' ).removeClass('tve-viewport-triggered');
$window.scroll( function () {
$to_test = $( '.tve_et_tve-viewport' );
trigger_elements( $to_test.filter( ':not(.tve-viewport-triggered)' ) );
trigger_exit( $to_test.filter( '.tve-viewport-triggered' ) );
} );
setTimeout( function () {
trigger_elements( $to_test.filter( ':not(.tve-viewport-triggered)' ) );
}, 200 );
} );
} )
( jQuery );
</script>