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

107
Views
how to overlap divs on half

I'm working with Vue 3and Bootstrap 5.

I have a v-for where I want to show the last card on top and the other ones below. But now all are ordered above each other.

I want to have that the card over the card which is showed below is overlapping half of it.

I've tried to put the position on absolute but than all cards will be on top of each other.

Hopefully someone could help me out!

<div v-for="(item, index) in array" :key="item.id">
  <div v-if="index == (array.length - 1)">
    <div class="card p-1">
      <div class="row">
        <div>{{ item.id }}</div>
      </div>
      <div class="row">
        <div class="text-center">
          <h1><i :class="item.icon"></i></h1>
        </div>
      </div>
      <div class="row">
        <div style="text-align: right;">
          <div>{{ item.id }}</div>
        </div>
      </div>
    </div>
  </div>
  <div v-if="index != (array.length - 1)">
    <div class="card p-1">
      <div class="row">
        <div>Value</div>
      </div>
      <div class="row">
        <div class="text-center">
          <h3>ICON</h3>
        </div>
      </div>
      <div class="row">
        <div style="text-align: right;">
          <div>Value</div>
        </div>
      </div>
    </div>
  </div>
</div>
about 4 years ago · Juan Pablo Isaza
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!