组件 点赞/反应按钮 点赞/反应按钮组件

点赞/反应按钮组件

用 HTML 和 Tailwind CSS 编写的点赞/反应按钮组件,采用粗犷主义设计,地球色调配色方案和适度复杂性,适用于电子商务。包括响应式设计和暗模式支持。

预览

HTML 代码

<div class="flex flex-col items-center p-4 bg-stone-200 dark:bg-stone-800 font-mono">

  <!-- Like Button -->
  <button class="flex items-center justify-center px-6 py-3 mb-4 text-lg font-bold text-stone-900 uppercase bg-stone-400 border-t-4 border-l-4 border-b-0 border-r-0 border-stone-900 dark:text-stone-100 dark:bg-stone-700 dark:border-stone-100">
    <svg class="w-6 h-6 mr-2" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14 10h4v6m0 0l-4 4m4-4L8 4m7 10l-2 2m0 0l-2-2m2 2l2 2"></path></svg>
    Like (120)
  </button>

  <!-- Reactions -->
  <div class="flex space-x-4">
    <button class="p-3 text-xl bg-stone-500 border-t-2 border-l-2 border-b-0 border-r-0 border-stone-900 dark:bg-stone-600 dark:border-stone-100">👍 50</button>
    <button class="p-3 text-xl bg-stone-500 border-t-2 border-l-2 border-b-0 border-r-0 border-stone-900 dark:bg-stone-600 dark:border-stone-100">😂 30</button>
    <button class="p-3 text-xl bg-stone-500 border-t-2 border-l-2 border-b-0 border-r-0 border-stone-900 dark:bg-stone-600 dark:border-stone-100">😢 10</button>
    <button class="p-3 text-xl bg-stone-500 border-t-2 border-l-2 border-b-0 border-r-0 border-stone-900 dark:bg-stone-600 dark:border-stone-100">😍 25</button>
  </div>

</div>

相关组件

点赞/反应按钮

带有粗野主义设计、大地色调、复杂交互、响应式、深色主题支持的点赞/反应按钮组件..没有 JS,纯 HTML 和 Tailwind。

打开

点赞/反应按钮

具有 Retro/Vintage 设计的 Like/Reaction Buttons 组件

打开

拟物化反应按钮

一组具有拟物设计风格的点赞和反应按钮,支持响应式布局和暗模式。这些按钮完全使用HTML和Tailwind CSS实现,无需JavaScript。暗模式通过CSS类处理。占位符图像用于头像。

打开