Gratis
Demo
Elyra Demo
A demo block extracted from the Elyra template, available in Tailwind CSS.
0
6
A demo block extracted from the Elyra template, available in Tailwind CSS.
Descarga gratis · hasta 5 bloques al día. Ilimitado con All-Access
<!DOCTYPE html>
<html lang="en">
<head>
<script>
window.FontAwesomeConfig = { autoReplaceSvg: 'nest' };
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/js/all.min.js" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Elyra Demo | Tailwind CSS UI Block</title>
<meta name="description" content="A demo block extracted from the Elyra template, available in Tailwind CSS.">
<meta name="keywords" content="Elyra, Tailwind CSS template, HTML website template, ecommerce template, audio store, speakers, headphones, hi-fi, product page, shopping cart">
<meta name="author" content="Let's templates">
<link rel="canonical" href="">
<meta property="og:type" content="product">
<meta property="og:site_name" content="Let's templates">
<meta property="og:locale" content="en_US">
<meta property="og:url" content="">
<meta property="og:title" content="Elyra | Tailwind CSS E-commerce Template">
<meta property="og:description" content="A dark, refined Tailwind CSS home audio store template with finish swatches, a room tuner, product pages and a working cart.">
<meta property="og:image" content="">
<meta property="og:image:alt" content="Elyra template preview">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:url" content="">
<meta name="twitter:title" content="Elyra | Tailwind CSS E-commerce Template">
<meta name="twitter:description" content="A dark, refined Tailwind CSS home audio store template with finish swatches, a room tuner, product pages and a working cart.">
<meta name="twitter:image" content="">
<meta name="twitter:image:alt" content="Elyra template preview">
<script src="https://cdn.tailwindcss.com/3.4.17"></script>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link href="https://fonts.googleapis.com/css2?family=Bodoni+Moda:ital,opsz,wght@0,6..96,400;1,6..96,400&family=Manrope:wght@300;400;500;600&display=swap" rel="stylesheet">
<script>
tailwind.config = {
theme: {
extend: {
colors: { char: { DEFAULT: '#1d1d1d', soft: '#262626' }, ink: '#111111', bone: '#efe9e1', copper: { DEFAULT: '#c08a63', deep: '#a06e4a' }, stone: '#8c8781' },
fontFamily: { serif: ['"Bodoni Moda"', 'serif'], sans: ['Manrope', 'sans-serif'] }
}
}
}
</script>
<style>
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: 180ms ease-out both page-fade-out; }
::view-transition-new(root) { animation: 220ms ease-in both page-fade-in; }
@keyframes page-fade-out { to { opacity: 0; } }
@keyframes page-fade-in { from { opacity: 0; } }
@keyframes ripple { from { transform: scale(.4); opacity: .8; } to { transform: scale(1.6); opacity: 0; } }
html { scroll-behavior: smooth; }
[hidden] { display: none !important; }
.wave { transform-origin: center; transform-box: fill-box; animation: ripple 2.4s ease-out infinite; }
.wave.delay { animation-delay: 1.2s; }
.reveal-ready [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; transition-delay: var(--reveal-delay, 0ms); }
.reveal-ready [data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
html { scroll-behavior: auto; }
.wave { animation: none; opacity: .4; }
::view-transition-old(root), ::view-transition-new(root) { animation: none; }
}
</style>
</head>
<body class="bg-char font-sans font-light text-bone antialiased">
<!-- block:start demo -->
<section id="tuner" class="mx-auto max-w-6xl px-5 py-24 md:px-10 md:py-32" data-tuner>
<div class="grid gap-12 lg:grid-cols-[1fr_1.1fr] lg:items-center">
<div>
<p class="text-xs uppercase tracking-[.4em] text-copper">Room tuner</p>
<h2 class="mt-5 font-serif text-4xl md:text-6xl">Tell us about the room</h2>
<p class="mt-5 max-w-md text-bone/70">Size and use decide more than the speaker does. Move the slider and pick how you listen; we will suggest a setup and where to put it.</p>
<label class="mt-10 grid gap-3"><span class="flex justify-between text-sm uppercase tracking-[.2em]">Room size <output class="font-serif text-2xl normal-case tracking-normal text-copper" data-tuner-size-out>24 m²</output></span><input type="range" min="8" max="60" value="24" class="accent-[#c08a63]" data-tuner-size></label>
<fieldset class="mt-8">
<legend class="text-sm uppercase tracking-[.2em]">How you listen</legend>
<div class="mt-3 flex flex-wrap gap-2">
<label class="cursor-pointer"><input type="radio" name="style" value="background" class="peer sr-only" data-tuner-style><span class="block rounded-full border border-bone/25 px-4 py-2 text-sm transition hover:border-bone peer-checked:border-copper peer-checked:bg-copper peer-checked:text-ink peer-focus-visible:ring-2 peer-focus-visible:ring-bone">Background</span></label>
<label class="cursor-pointer"><input type="radio" name="style" value="focused" class="peer sr-only" checked data-tuner-style><span class="block rounded-full border border-bone/25 px-4 py-2 text-sm transition hover:border-bone peer-checked:border-copper peer-checked:bg-copper peer-checked:text-ink peer-focus-visible:ring-2 peer-focus-visible:ring-bone">Focused</span></label>
<label class="cursor-pointer"><input type="radio" name="style" value="films" class="peer sr-only" data-tuner-style><span class="block rounded-full border border-bone/25 px-4 py-2 text-sm transition hover:border-bone peer-checked:border-copper peer-checked:bg-copper peer-checked:text-ink peer-focus-visible:ring-2 peer-focus-visible:ring-bone">Films & games</span></label>
</div>
</fieldset>
</div>
<div class="rounded-[2rem] border border-bone/10 bg-ink p-6 md:p-8">
<svg viewBox="0 0 400 260" class="w-full" role="img" aria-label="Floor plan showing suggested speaker placement" data-tuner-plan>
<rect x="10" y="10" width="380" height="240" rx="16" fill="none" stroke="#efe9e1" stroke-opacity=".2" stroke-dasharray="6 6" data-tuner-room/>
<rect x="150" y="170" width="100" height="40" rx="10" fill="#262626"/><text x="200" y="195" text-anchor="middle" font-size="11" fill="#8c8781">sofa</text>
<g data-tuner-speaker="left"><circle cx="110" cy="70" r="34" fill="none" stroke="#c08a63" stroke-opacity=".6" class="wave"/><circle cx="110" cy="70" r="34" fill="none" stroke="#c08a63" stroke-opacity=".6" class="wave delay"/><rect x="101" y="56" width="18" height="28" rx="6" fill="#c08a63"/></g>
<g data-tuner-speaker="right"><circle cx="290" cy="70" r="34" fill="none" stroke="#c08a63" stroke-opacity=".6" class="wave"/><circle cx="290" cy="70" r="34" fill="none" stroke="#c08a63" stroke-opacity=".6" class="wave delay"/><rect x="281" y="56" width="18" height="28" rx="6" fill="#c08a63"/></g>
<g data-tuner-sub hidden><rect x="186" y="222" width="28" height="20" rx="4" fill="#efe9e1"/><text x="200" y="236" text-anchor="middle" font-size="9" fill="#111">sub</text></g>
</svg>
<div class="mt-6 flex flex-wrap items-end justify-between gap-4 border-t border-bone/10 pt-6" aria-live="polite">
<div><p class="text-xs uppercase tracking-[.2em] text-bone/50">Suggested setup</p><p class="mt-1 font-serif text-3xl" data-tuner-setup>Aria Column ×2</p><p class="mt-1 text-sm text-bone/60" data-tuner-tip>Either side of the sofa, angled in 10°.</p></div>
<p class="font-serif text-3xl text-copper" data-tuner-price>$2,580</p>
</div>
</div>
</div>
<script type="application/json" data-tuner-data>{"small":["Duet Bookshelf","A pair on the shelf, 1.5 m apart.",890],"medium":["Aria Column ×2","Either side of the sofa, angled in 10°.",2580],"large":["Aria Column ×2 + Orbit Sub","Columns at the corners, sub behind the sofa.",3320]}</script>
</section>
<!-- block:end demo -->
<script>
const reducedMotion = matchMedia('(prefers-reduced-motion: reduce)').matches;
const watchMotion = !reducedMotion && !navigator.webdriver && 'IntersectionObserver' in window;
document.querySelectorAll('[data-menu-toggle]').forEach((button) => {
const menu = document.getElementById(button.getAttribute('aria-controls'));
button.addEventListener('click', () => {
const open = button.getAttribute('aria-expanded') === 'true';
button.setAttribute('aria-expanded', String(!open));
menu.classList.toggle('hidden', open);
});
});
document.querySelectorAll('[data-pill]').forEach((pill) => {
const update = () => pill.toggleAttribute('data-shrunk', scrollY > 80);
addEventListener('scroll', update, { passive: true });
update();
});
document.querySelectorAll('[data-rooms]').forEach((root) => {
const buttons = [...root.querySelectorAll('[data-room]')];
let current = 0;
const show = (index) => {
current = index;
buttons.forEach((button, i) => button.setAttribute('aria-pressed', String(i === index)));
root.querySelectorAll('[data-room-photo]').forEach((img) => { img.hidden = Number(img.dataset.roomPhoto) !== index; });
root.querySelectorAll('[data-room-copy]').forEach((copy) => { copy.hidden = Number(copy.dataset.roomCopy) !== index; });
root.querySelector('[data-room-index]').textContent = String(index + 1).padStart(2, '0');
};
buttons.forEach((button, i) => button.addEventListener('click', () => show(i)));
if (!reducedMotion && !navigator.webdriver) setInterval(() => { if (!root.matches(':hover')) show((current + 1) % buttons.length); }, 6000);
});
document.querySelectorAll('[data-finishes]').forEach((root) => {
root.querySelectorAll('[data-product]').forEach((card) => {
const swatches = [...card.querySelectorAll('[data-finish]')];
swatches.forEach((swatch) => swatch.addEventListener('click', () => {
swatches.forEach((other) => other.setAttribute('aria-pressed', String(other === swatch)));
card.querySelectorAll('[data-finish-art]').forEach((art) => { art.hidden = art.dataset.finishArt !== swatch.dataset.finish; });
card.querySelector('[data-finish-name]').textContent = swatch.getAttribute('aria-label');
}));
});
});
document.querySelectorAll('[data-tuner]').forEach((root) => {
const setups = JSON.parse(root.querySelector('[data-tuner-data]').textContent);
const size = root.querySelector('[data-tuner-size]');
const update = () => {
const area = Number(size.value);
const style = root.querySelector('[data-tuner-style]:checked').value;
let key = area < 18 ? 'small' : area < 38 ? 'medium' : 'large';
if (style === 'films' && key === 'medium') key = 'large';
if (style === 'background' && key === 'large') key = 'medium';
const setup = setups[key];
root.querySelector('[data-tuner-size-out]').textContent = `${area} m²`;
root.querySelector('[data-tuner-setup]').textContent = setup[0];
root.querySelector('[data-tuner-tip]').textContent = setup[1];
root.querySelector('[data-tuner-price]').textContent = `$${setup[2].toLocaleString('en-US')}`;
root.querySelector('[data-tuner-sub]').toggleAttribute('hidden', key !== 'large');
const scale = 0.55 + (area - 8) / 52 * 0.45;
const room = root.querySelector('[data-tuner-room]');
room.setAttribute('width', Math.round(380 * scale)); room.setAttribute('x', Math.round(200 - 190 * scale));
};
size.addEventListener('input', update);
root.querySelectorAll('[data-tuner-style]').forEach((input) => input.addEventListener('change', update));
update();
});
document.querySelectorAll('[data-listen-form]').forEach((form) => {
const status = form.parentElement.querySelector('[data-form-status]');
form.addEventListener('submit', (event) => {
event.preventDefault();
const email = form.querySelector('[name="email"]');
if (!email.value.trim() || !email.checkValidity()) { status.textContent = 'Please enter a valid email address.'; email.focus(); return; }
status.textContent = `Thank you. We will email ${email.value} with open slots this week.`;
form.reset();
});
});
if (watchMotion) {
document.documentElement.classList.add('reveal-ready');
const observer = new IntersectionObserver((entries) => entries.forEach((entry) => {
if (entry.isIntersecting) { entry.target.classList.add('is-visible'); observer.unobserve(entry.target); }
}), { threshold: 0.15 });
document.querySelectorAll('[data-reveal]').forEach((el) => observer.observe(el));
document.querySelectorAll('[data-ring]').forEach((ring) => { ring.style.strokeDashoffset = '326.7'; });
const rings = new IntersectionObserver((entries) => entries.forEach((entry) => {
if (!entry.isIntersecting) return;
entry.target.querySelectorAll('[data-ring]').forEach((ring) => { ring.style.strokeDashoffset = ring.dataset.ring; });
rings.unobserve(entry.target);
}), { threshold: 0.3 });
document.querySelectorAll('[data-rings]').forEach((el) => rings.observe(el));
}
</script>
<!-- Optional credit — delete this block if you prefer a clean footer -->
<p class="lt-built-with" style="margin:0;padding:12px 16px;text-align:center;font:500 11px/1.4 system-ui,-apple-system,sans-serif;color:#9ca3af;">Built with <a href="https://letstemplates.com" style="color:#059669;text-decoration:none;">Let's templates</a></p>
</body>
</html>
Premium
Tienda online
Desbloquea toda la biblioteca de plantillas y bloques premium. Se renueva automáticamente, cancela cuando quieras.