How can the elements in the mobile fiexd scroll?

as shown in the figure
the parent element of the list is positioned with fixed, but the list is exceeded. How can it be slid?

<div class="commonClass" v-show="showCityList">
            <div class="" v-for="item in city_list" @click="getNewList(item.id)">{{item.name}}</div>
</div>
.commonClass{
  width: 100%;
  position: fixed;
  top: 90px;
  height: 100%;
  background: -sharpfff;
  overflow: scroll;
  bottom: 0;
}

CSS overflow learn about

https://developer.mozilla.org.

< hr >

this setting should be scrollable, and the question for the subject is why it was truncated under "Shandong". Just delete height: 100%; .

height: 100%; and No will calculate offsets such as fix , margin , so it is likely to use the height of the entire screen directly, so that the bottom 90px is actually squeezed out of the screen.

since absolute positioning is used, setting top and bottom at the same time is equivalent to setting height , so you don't need to set it again.

Menu