1(function ($) { 2 "use strict"; 3 var ELFINANCE = ELFINANCE || {}; 4 5 ELFINANCE.general = function () { 6 $('.penci-fncrypto-table').each(function() { 7 var t = $(this), 8 id = t.attr('id'); 9 10 if ( ! $.fn.dataTable.isDataTable( '#' + id ) ) { 11 t.DataTable({ 12 paging: false, 13 searching: false, 14 columnDefs: [{ width: '10px', targets: 0 },{ width: '120px', targets: 1 }] 15 }); 16 } 17 }); 18 $('.pcfic-chart').each(function() { 19 // Check if the custom class "chart-loaded" is already added 20 if (!$(this).hasClass('chart-loaded')) { 21 const ctx = $(this)[0].getContext('2d'); 22 23 // Extract the chart data from the data-chart attribute 24 const chartData = $(this).data('chart').split(',').map(Number); // Convert the string data to an array of numbers 25 const chartBackgroundColor = getComputedStyle(this).getPropertyValue('--upbdcl').trim(); 26 const bgColor = getComputedStyle(this).getPropertyValue('--upbgcl').trim(); 27 28 // Generate the Chart.js chart 29 const myChart = new Chart(ctx, { 30 type: 'line', 31 data: { 32 labels: chartData.map((_, index) => `Label ${index + 1}`), // Create labels for each data point 33 datasets: [{ 34 data: chartData, // Use the extracted data 35 backgroundColor: bgColor, // Area under the line 36 borderColor: chartBackgroundColor, // Line color 37 borderWidth: 2, 38 fill: true, 39 pointRadius: 0 // No points on the line 40 }] 41 }, 42 options: { 43 plugins: { 44 legend: { 45 display: false // No legend 46 }, 47 tooltip: { 48 enabled: false // No tooltip 49 } 50 }, 51 scales: { 52 x: { 53 display: false // No X axis 54 }, 55 y: { 56 display: false // No Y axis 57 } 58 }, 59 elements: { 60 line: { 61 tension: 0.4 // Smooth curve 62 } 63 }, 64 maintainAspectRatio: false, // Allow the chart to resize with the container 65 responsive: true // Make the chart responsive 66 } 67 }); 68 69 // Once the chart is fully loaded, add the custom class 70 $(this).addClass('chart-loaded'); 71 } 72 }); 73 74 $('.marquee3k').each( function(){ 75 var t = $(this); 76 77 if ( ! t.find('.js-marquee-wrapper').length ) { 78 t.marquee({ 79 speed: 50, 80 gap: 30, 81 delayBeforeStart: 0, 82 direction: $('body').hasClass('rtl') ? 'right' : 'left', 83 duplicated: true, 84 pauseOnHover: true, 85 startVisible: true, 86 }); 87 } 88 }); 89 return false; 90 } 91 92 $(window).on('elementor/frontend/init', function () { 93 if ( window.elementorFrontend && window.elementorFrontend.isEditMode() ) { 94 95 elementorFrontend.hooks.addAction('frontend/element_ready/penci-finance-elementor-crypto.default', function ($scope) { 96 ELFINANCE.general(); 97 }); 98 99 elementorFrontend.hooks.addAction('frontend/element_ready/penci-finance-elementor.default', function ($scope) { 100 ELFINANCE.general(); 101 }); 102 103 } 104 }); 105 106 $(document).ready(function () { 107 ELFINANCE.general(); 108 }); 109 110})(jQuery); // EOF
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.