123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449 |
- <!-- eslint-disable vue/multi-word-component-names -->
- <template>
- <!-- 基准的列表模块,通过不同的 type 展示不同的样式 -->
- <div class="list flex items-center" :class="`list_${type}`">
- <!-- 部分类型的列表需要加一张图片 -->
- <div :class="`list__image_${type}`"></div>
- <!-- 剩下的部分填充剩余宽度 -->
- <div class="flex-grow h-full" :class="`list__wrapper_${type}`">
- <div v-for="(item, i) in listConfig" :key="`vvhccdcl${i}`" :class="`list-item_${type}`">
- <!-- 列表项前面的图标 -->
- <div :class="`list-item__title_${type}`">{{ item.title }}</div>
- <!-- 列表项的具体内容填充剩余宽度 -->
- <div v-for="(ctx, j) in item.contents" :key="`vvhccdclc${j}`" :class="`list-item__content_${type}`">
- <div class="list-item__label">{{ ctx.label }}</div>
- <div class="list-item__info" :class="`list-item__info_${ctx.color}`">{{ ctx.info }}</div>
- <div class="list-item__value" :class="`list-item__value_${ctx.color} list-item__value_${type}`">{{ ctx.value }}</div>
- </div>
- </div>
- </div>
- </div>
- </template>
- <script lang="ts" setup>
- withDefaults(
- defineProps<{
- listConfig: {
- title: string;
- contents: {
- value: string;
- color: string;
- label: string;
- info: string;
- }[];
- }[];
- /** A B */
- type: string;
- }>(),
- {
- listConfig: () => [],
- type: 'A',
- }
- );
- // defineEmits(['click']);
- </script>
- <style lang="less" scoped>
- @import '@/design/theme.less';
- @import '@/design/theme.less';
- /* Timeline 相关的样式 */
- @{theme-deepblue} {
- .list {
- --image-img-3: url(/@/assets/images/themify/deepblue/home-container/configurable/firehome/img-3.png);
- --image-img-7: url(/@/assets/images/themify/deepblue/home-container/configurable/firehome/img-7.png);
- --image-img-8: url(/@/assets/images/themify/deepblue/home-container/configurable/firehome/img-8.png);
- --image-img-9: url(/@/assets/images/themify/deepblue/home-container/configurable/firehome/img-9.png);
- --image-list_bg_1: url(/@/assets/images/themify/deepblue/home-container/configurable/dusthome/list_bg_1.png);
- }
- }
- .list {
- --image-img-3: url(/@/assets/images/home-container/configurable/firehome/img-3.png);
- --image-img-7: url(/@/assets/images/home-container/configurable/firehome/img-7.png);
- --image-img-8: url(/@/assets/images/home-container/configurable/firehome/img-8.png);
- --image-img-9: url(/@/assets/images/home-container/configurable/firehome/img-9.png);
- --image-list_bg_1: url(/@/assets/images/home-container/configurable/dusthome/list_bg_1.png);
- padding: 5px 20px;
- position: relative;
- width: 100%;
- height: 100%;
- }
- .list-item_A {
- position: relative;
- height: 140px;
- background-repeat: no-repeat;
- background-image: var(--image-img-3);
- background-size: auto 100%;
- background-position: center;
- }
- .list-item__title_A {
- position: absolute;
- left: 41%;
- // font-size: 14px;
- top: 15px;
- }
- // .list-item__content_A {
- // position: absolute;
- // left: 35%;
- // top: 55px;
- // display: flex;
- // justify-content: space-evenly;
- // }
- .list-item__content_A:nth-of-type(2) {
- position: absolute;
- top: 15px;
- left: 14%;
- width: 22%;
- text-align: center;
- display: block;
- .list-item__label {
- font-size: 18px;
- margin-bottom: 25px;
- }
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 24px;
- }
- }
- .list-item__content_A:nth-of-type(3) {
- position: absolute;
- left: 41%;
- top: 55px;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 20px;
- }
- }
- .list-item__content_A:nth-of-type(4) {
- position: absolute;
- left: 66%;
- top: 55px;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 20px;
- }
- }
- .list-item__content_A:nth-of-type(5) {
- position: absolute;
- left: 35%;
- bottom: 10px;
- display: flex;
- align-items: center;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 20px;
- margin-left: 5px;
- }
- }
- .list-item_B {
- // height: 155px;
- background-repeat: no-repeat;
- // background-size: 100% 100%;
- // background-size: auto 100%;
- background-size: 87% auto;
- background-position: center;
- background-image: var(--image-img-7);
- display: flex;
- align-items: center;
- justify-content: space-between;
- text-align: center;
- padding: 0 10%;
- margin-top: 5px;
- height: 33px;
- .list-item__label {
- font-size: 11px;
- }
- .list-item__value {
- font-size: 18px;
- margin-left: 5px;
- }
- .list-item__content_B {
- height: 100%;
- display: flex;
- align-items: center;
- flex-basis: 100px;
- flex-grow: 1;
- }
- .list-item__title_B {
- width: 40px;
- text-align: center;
- margin-right: 50px
- // height: 30px;
- // background-size: auto 80%;
- // background-position: center;
- // background-repeat: no-repeat;
- }
- .list-item__info {
- display: none;
- }
- }
- .list_C {
- padding: 5px 10px;
- }
- .list__wrapper_C {
- display: flex;
- justify-content: space-between;
- flex-wrap: wrap;
- }
- .list-item_C {
- position: relative;
- height: 140px;
- width: 200px;
- background-repeat: no-repeat;
- background-image: var(--image-img-8);
- background-size: 100% 100%;
- background-position: left center;
- }
- .list-item__title_C {
- position: absolute;
- left: 99px;
- // font-size: 14px;
- top: 15px;
- }
- .list-item__content_C:nth-of-type(2) {
- position: absolute;
- top: 15px;
- left: 19px;
- width: 30%;
- text-align: center;
- display: block;
- .list-item__label {
- // font-size: 18px;
- margin-bottom: 25px;
- }
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 18px;
- }
- }
- .list-item__content_C:nth-of-type(3) {
- position: absolute;
- left: 99px;
- top: 55px;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 18px;
- }
- }
- .list_D {
- padding: 5px 10px;
- }
- .list__wrapper_D {
- display: flex;
- justify-content: space-between;
- flex-wrap: wrap;
- }
- .list-item_D {
- position: relative;
- height: 110px;
- width: 200px;
- background-repeat: no-repeat;
- background-image: var(--image-img-9);
- background-size: 100% auto;
- background-position: center top;
- text-align: center;
- margin-bottom: 20px;
- }
- .list-item__title_D {
- position: absolute;
- width: 100%;
- bottom: 0;
- font-size: 16px;
- font-weight: bold;
- }
- .list-item__content_D:nth-of-type(2) {
- position: absolute;
- top: 10%;
- left: 10%;
- width: 30%;
- text-align: center;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 18px;
- }
- }
- .list-item__content_D:nth-of-type(3) {
- position: absolute;
- top: 10%;
- right: 10%;
- width: 30%;
- text-align: center;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 18px;
- }
- }
- .list_E {
- padding: 5px 10px;
- }
- .list__wrapper_E {
- display: flex;
- justify-content: space-between;
- flex-wrap: wrap;
- padding: 0 10px;
- }
- .list-item_E {
- position: relative;
- height: 104px;
- width: 188px;
- background-repeat: no-repeat;
- background-image: var(--image-list_bg_1);
- background-size: 100% auto;
- background-position: center top;
- text-align: center;
- margin-bottom: 20px;
- }
- .list-item__title_E {
- // position: absolute;
- width: 100%;
- // top: 0;
- font-size: 16px;
- font-weight: bold;
- margin-top: 10px;
- }
- .list-item__content_E:nth-of-type(2) {
- position: absolute;
- top: 40%;
- left: 5%;
- text-align: left;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 16px;
- }
- }
- .list-item__content_E:nth-of-type(3) {
- position: absolute;
- top: 40%;
- right: 5%;
- text-align: right;
- .list-item__info {
- display: none;
- }
- .list-item__value {
- font-size: 16px;
- }
- }
- .list-item_F {
- // height: 155px;
- background-repeat: no-repeat;
- background-size: 100% 100%;
- // background-size: auto 100%;
- background-position: center;
- background-image: @vent-gas-list-item-bg-img;
- display: flex;
- align-items: center;
- // justify-content: space-between;
- // text-align: center;
- padding: 0 5%;
- margin-top: 5px;
- height: 50px;
- .list-item__title_F {
- flex-basis: 25%;
- }
- .list-item__content_F {
- flex-basis: 25%;
- }
- .list-item__label::after {
- content: ':';
- }
- .list-item__value {
- font-size: 18px;
- margin-left: 5px;
- font-weight: bold;
- }
- .list-item__content_F {
- display: flex;
- align-items: center;
- }
- .list-item__info {
- display: none;
- }
- }
- // .list-item__title_B_O2 {
- // background-image: url(/@/assets/images/home-container/configurable/firehome/O₂.png);
- // }
- // .list-item__title_B_CH4 {
- // background-image: url(/@/assets/images/home-container/configurable/firehome/CH₄.png);
- // }
- // .list-item__title_B_CO {
- // background-image: url(/@/assets/images/home-container/configurable/firehome/CO.png);
- // }
- // .list-item__title_B_CO2 {
- // background-image: url(/@/assets/images/home-container/configurable/firehome/CO₂.png);
- // }
- // .list-item__label {
- // flex-basis: 55%;
- // }
- // .list-item__info {
- // flex-grow: 1;
- // }
- // .list-item__value {
- // flex-basis: 30%;
- // }
- .list-item__value_red {
- color: red;
- }
- .list-item__value_orange {
- color: orange;
- }
- .list-item__value_yellow {
- color: yellow;
- }
- .list-item__value_green {
- color: yellowgreen;
- }
- .list-item__value_blue {
- color: @vent-table-action-link;
- }
- .list-item__value_white {
- color: white;
- }
- .gallery-item__value_lightblue {
- color: @vent-configurable-home-light-border;
- }
- </style>
|