HTML Structure
Include the following HTML structure in your page:
<div class="ai-pipeline-section">
<div class="pipeline-container">
<button id="pipeline-prev" aria-label="Previous stage"><i class="fas fa-chevron-left"></i></button>
<div class="pipeline-track">
<div class="pipeline-stage">
<h3>Stage 1</h3>
<p>Stage content goes here</p>
</div>
</div>
<button id="pipeline-next" aria-label="Next stage"><i class="fas fa-chevron-right"></i></button>
</div>
</div>
JavaScript Initialization
Initialize the pipeline component by calling initPipeline()
when the DOM is loaded:
document.addEventListener('DOMContentLoaded', function() {
const pipelineSection = document.querySelector('.ai-pipeline-section');
if (pipelineSection) initPipeline();
});
Required CSS
Include the following CSS in your stylesheet:
.ai-pipeline-section {
--pipeline-bg: rgba(18, 32, 42, 0.6);
--pipeline-border: rgba(155, 240, 255, 0.1);
--pipeline-accent: #9bf0ff;
--pipeline-progress: linear-gradient(90deg, #4bcaff, #8a2be2);
--pipeline-text: #ffffff;
--pipeline-radius: 12px;
--pipeline-transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}