Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

169
Views
i want to add this tailwind style ( active:border-b-2 active:border-blue-500) in next.js but this doesn't work

this is the tailwind style which i want to add

import React from 'react'

function HeaderIcon({Icon}) {
  return (
    <div
      className="flex
      items-center
      cursor-pointer
      md:px-10
      sm:h-14
      md:hover:bg-gray-100
      rounded-xl
      active:border-b-2
      active:border-blue-500"
    >
      <Icon className="h-5" />
    </div>
  )
}

export default HeaderIcon

------here i want to add tailwind style-----------------------------

<div className="flex justify-center flex-grow">
  <div className="flex space-x-6 md:space-2">
    <HeaderIcon Icon={HomeIcon} />
    <HeaderIcon Icon={FlagIcon} />
    <HeaderIcon Icon={PlayIcon} />
    <HeaderIcon Icon={ShoppingCartIcon} />
    <HeaderIcon Icon={UserGroupIcon} />
  </div>
</div>
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

You have to modify the Tailwind settings to enable the active status.

Documentation

// tailwind.config.js
module.exports = {
  // ...
  variants: {
    extend: {
      backgroundColor: ['active'],
    }
  },
}
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!