<template> <view style="flex-grow: 1;"> <view> <text>margin: 25px</text> <view style="width: 250px;height: 250px;background-color: gray;"> <view class="common" style="background-color: red;"></view> <view class="common" style="margin: 25px;"></view> <view class="common" style="background-color: blue;"></view> </view> </view> <view> <text>margin: 10%</text> <view style="width: 250px;height: 250px;background-color: gray;"> <view class="common" style="background-color: red;"></view> <view class="common" style="margin: 10%;"></view> <view class="common" style="background-color: blue;"></view> </view> </view> </view> </template> <script> </script> <style> .common { height: 50px; background-color: green; } </style>