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

178
Views
Problem: resize of elements with "onclick" function at certain screen width

I would need some help regarding media queries applied to javascript. Is it possible to resize an object starting from the javascript code with a screen width other than the "default" one?

Example: I have a button, and when I click on it, it opens me a div with a height of 600px. the screen here is 1600px wide. can I make sure that when the screen is for example at 1000px wide, the div that is shown has a height of 800px? And if it is possible, can this happen several times, that is, that the condition does not disappear once this div is closed and then repoened?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

the easiest way to do this is probably with css media queries

@media (max-width: 1000px) {
   div {
      height: 800px;
   }
}
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!