12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- <template>
- <div class="title_diy">
- <h3>{{ heads }}</h3>
- </div>
- </template>
- <script>
- export default {
- data() {
- return {
- head: ''
- }
- },
- props: {
- //第二种方式
- heads: {
- type: String,
- default: function() {
- return ''
- }
- }
- },
- created() {
-
- },
- watch: {}
- }
- </script>
-
- <style>
- .title_diy {
- width: 100%;
- height: 6rem;
- line-height: 6rem;
- position: relative;
- }
- .title_diy::after {
- position: absolute;
- height: 1px;
- background-color: #f0f0f0;
- left: 0;
- right: 0;
- bottom: 0;
- margin-left: -1.5rem;
- margin-right: -1.5rem;
- }
- </style>
|