justboil / admin-one-vue-tailwind

Free Vue.js 3.x Tailwind 3.x admin dashboard template with dark mode. Vite builds. Pinia state. Laravel integration available
https://justboil.github.io/admin-one-vue-tailwind/
MIT License
2.14k stars 402 forks source link

how to disable responsive for tables #11

Closed AhmedRamadan closed 2 years ago

syifeng commented 2 years ago

No description provided.

Did you get the solution?

vikdiesel commented 2 years ago

Set all lg modifiers as default in src/css/_table.css

table {
  @apply w-full;
}

thead {
  @apply table-header-group;
}

tr {
  @apply max-w-full block relative border-gray-100
    border-b-0 dark:border-slate-800;
}

tr:last-child {
  @apply border-b-0;
}

td:not(:first-child) {
  @apply border-l border-t-0 border-r-0 border-b-0 border-gray-100 dark:border-slate-700;
}

th {
  @apply text-left p-3;
}

td {
  @apply text-left p-3 align-middle;
}

td:last-child {
  @apply border-b-0;
}

tbody tr, tbody tr:nth-child(odd) {
  @apply hover:bg-gray-100 dark:hover:bg-slate-700/70;
}

tbody tr:nth-child(odd) {
  @apply bg-gray-50 dark:bg-slate-800;
}

Additionally, I'd recommend to wrap a table in container with overflow-x-scroll