12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- <template>
- <view class="u-gap" :style="[gapStyle]"></view>
- </template>
- <script>
- export default {
- name: "u-gap",
- props: {
- bgColor: {
- type: String,
- default: 'transparent '
- },
-
- height: {
- type: [String, Number],
- default: 30
- },
-
- marginTop: {
- type: [String, Number],
- default: 0
- },
-
- marginBottom: {
- type: [String, Number],
- default: 0
- },
- },
- computed: {
- gapStyle() {
- return {
- backgroundColor: this.bgColor,
- height: this.height + 'rpx',
- marginTop: this.marginTop + 'rpx',
- marginBottom: this.marginBottom + 'rpx'
- };
- }
- }
- };
- </script>
- <style></style>
|