</> ConvertAtlas Developer Tools
Bootstrap 5 · Intermediate

Invoice with Donut

An invoice card with a cost-breakdown donut, via ApexCharts.

Requires Bootstrap 5, ApexCharts. Add the CDN tags below to your page (styles in <head>, scripts before </body>). The downloaded file already includes them.
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/apexcharts@3.49.1/dist/apexcharts.min.js"></script>
<div class="card border-0 shadow-sm" style="width:400px;max-width:100%"><div class="card-body">
  <div class="d-flex justify-content-between mb-2"><h6 class="fw-bold mb-0">Invoice #2041</h6><span class="badge text-bg-success">Paid</span></div>
  <div id="ivChart"></div>
  <table class="table table-sm small mt-2 mb-0"><tr><td>Design</td><td class="text-end">$1,200</td></tr><tr><td>Development</td><td class="text-end">$2,400</td></tr><tr class="fw-bold"><td>Total</td><td class="text-end">$3,600</td></tr></table>
</div></div>
new ApexCharts(document.getElementById('ivChart'),{chart:{type:'donut',height:150},series:[1200,2400],labels:['Design','Development'],colors:['#0d6efd','#16a34a'],legend:{position:'bottom'},dataLabels:{enabled:false}}).render();
Free to use.This component uses Bootstrap 5, ApexCharts (linked above). Copy any file, or download a ready-to-open .html page with the CDN links already included.