HEX
Server: Apache
System: Linux ecngx285.inmotionhosting.com 4.18.0-553.79.1.lve.el8.x86_64 #1 SMP Wed Oct 15 17:59:35 UTC 2025 x86_64
User: zeusxp5 (3862)
PHP: 8.3.28
Disabled: NONE
Upload Files
File: /home/zeusxp5/tour.kamille.us/wp-content/themes/solace/js/dokan.js
jQuery(document).ready(function($){
    $('#dokan-content .products a.button.product_type_simple, .dokan-store-name .products a.button.product_type_simple').addClass('dokan-btn-theme');
	$('body.dokan-theme-solace a.button.product_type_simple.add_to_cart_button.ajax_add_to_cart').addClass('alt');
    var buttonStyles = getComputedStyle(document.querySelector('.dokan-btn-theme'));

    var color = buttonStyles.color;
    var backgroundColor = buttonStyles.backgroundColor; 
    var borderColor = buttonStyles.borderColor; 

    function rgbToHex(rgb) {
        const rgbArray = rgb.match(/\d+/g); 
        const hex = rgbArray.map(value => {
            const hexValue = parseInt(value).toString(16).padStart(2, '0'); 
            return hexValue;
        }).join('');
        return `#${hex.toUpperCase()}`; 
    }

    var hexColor = rgbToHex(color);
    var hexBackgroundColor = rgbToHex(backgroundColor);
    var hexBorderColor = rgbToHex(borderColor);

    $('.button.product_type_simple.dokan-btn-theme').each(function() {
        $(this).css({
            'color': hexColor, 
            'background-color': hexBackgroundColor, 
            'border-color': hexBorderColor 
        });

        console.log('Applied Color:', hexColor);
        console.log('Applied Background Color:', hexBackgroundColor);
        console.log('Applied Border Color:', hexBorderColor);
    });

    $(this).hover(
        function() {
            $(this).css({
                'color': hexColor, 
                'background-color': hexBorderColor,
                'border-color': hexBackgroundColor 
            });
        },
        function() {
            // Kembali ke gaya awal
            $(this).css({
                'color': hexColor,
                'background-color': hexBackgroundColor,
                'border-color': hexBorderColor
            });
        }
    );
});