style: 证书页下载按钮放右上,编号放在图片上方
This commit is contained in:
@@ -3,6 +3,9 @@
|
||||
<header class="subpage-bar">
|
||||
<button type="button" class="subpage-back" @click="back">{{ t('chain.txBack') }}</button>
|
||||
<h1>{{ t('chain.certificateView') }}</h1>
|
||||
<button v-if="certificateRecord" type="button" class="des-download" @click="certificateSheet?.download()">
|
||||
{{ t('chain.certificateDownload') }}
|
||||
</button>
|
||||
</header>
|
||||
<div class="subpage-body">
|
||||
<p v-if="preview" class="subpage-note">{{ t('chain.certificatePreview') }}</p>
|
||||
@@ -12,11 +15,6 @@
|
||||
{{ t('chain.certificateCheckAgain') }}
|
||||
</button>
|
||||
<template v-else-if="certificateRecord">
|
||||
<div ref="stage" class="cert-stage" :style="{ height: `${720 * scale}px` }">
|
||||
<div class="cert-fit" :style="{ transform: `scale(${scale})` }">
|
||||
<trace-certificate-sheet ref="certificateSheet" :record="certificateRecord" />
|
||||
</div>
|
||||
</div>
|
||||
<section class="prove-des">
|
||||
<h2 class="des-title">
|
||||
{{ t('chain.certificateChainId') }}
|
||||
@@ -34,8 +32,12 @@
|
||||
</button>
|
||||
</h2>
|
||||
<p class="des-digest">{{ certificateRecord.digest }}</p>
|
||||
<button type="button" class="des-download" @click="certificateSheet?.download()">{{ t('chain.certificateDownload') }}</button>
|
||||
</section>
|
||||
<div ref="stage" class="cert-stage" :style="{ height: `${720 * scale}px` }">
|
||||
<div class="cert-fit" :style="{ transform: `scale(${scale})` }">
|
||||
<trace-certificate-sheet ref="certificateSheet" :record="certificateRecord" />
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<div v-else class="subpage-wait">
|
||||
<div class="certificate-spinner" aria-hidden="true" />
|
||||
@@ -160,12 +162,11 @@ onUnmounted(() => {
|
||||
|
||||
<style scoped>
|
||||
.subpage { max-width: 560px; margin: 0 auto; min-height: 100vh; background: var(--bg); }
|
||||
.subpage-bar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 12px; background: var(--card-bg); border-bottom: 1px solid var(--border); }
|
||||
.subpage-bar h1 { flex: 1; min-width: 0; margin: 0; font-size: 16px; font-weight: 600; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
||||
.subpage-bar { flex-wrap: wrap; }
|
||||
.subpage-bar { position: sticky; top: 0; z-index: 8; display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 12px; background: var(--card-bg); border-bottom: 1px solid var(--border); flex-wrap: nowrap; }
|
||||
.prove-des { margin: 4px 0 16px; text-align: left; color: #333; }
|
||||
.subpage-back, .subpage-action { border: 0; background: transparent; color: var(--brand-2); font: inherit; font-size: 14px; cursor: pointer; padding: 6px 0; }
|
||||
.subpage-action { background: var(--brand); color: #fff; border-radius: 6px; padding: 8px 12px; }
|
||||
.prove-des { margin-top: 20px; text-align: left; color: #333; }
|
||||
.subpage-bar h1 { flex: 1; min-width: 0; margin: 0; font-size: 16px; font-weight: 600; text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
||||
.des-title { display: flex; align-items: center; margin: 20px 0 12px; padding: 0 8px; border-left: 3px solid #2977f0; font-family: PingFang-SC-Bold, 'PingFang SC', 'Microsoft YaHei', sans-serif; font-size: 14px; font-weight: 700; line-height: 20px; color: #333; letter-spacing: 0.14px; }
|
||||
.des-title:first-child { margin-top: 0; }
|
||||
.des-tip { position: relative; display: inline-flex; margin-left: 4px; padding: 0; border: 0; background: transparent; color: #333; cursor: pointer; }
|
||||
@@ -177,7 +178,7 @@ onUnmounted(() => {
|
||||
.des-hash, .des-digest { margin: 0 0 20px; font-family: PingFangSC-Regular, 'PingFang SC', 'Microsoft YaHei', sans-serif; font-size: 14px; font-weight: 400; line-height: normal; letter-spacing: 0.14px; text-align: left; word-break: break-all; }
|
||||
.des-hash { margin-bottom: 0; color: #2977f0; }
|
||||
.des-digest { color: #666; word-break: break-word; }
|
||||
.des-download { min-width: 112px; height: 36px; padding: 6px 16px; border: 1px solid #2977f0; border-radius: 4px; background: #fff; color: #2977f0; font-family: PingFangSC-Regular, 'PingFang SC', 'Microsoft YaHei', sans-serif; font-size: 14px; font-weight: 500; line-height: 14px; cursor: pointer; }
|
||||
.des-download { flex: none; min-width: 112px; height: 36px; padding: 6px 16px; border: 1px solid #2977f0; border-radius: 4px; background: #fff; color: #2977f0; font-family: PingFangSC-Regular, 'PingFang SC', 'Microsoft YaHei', sans-serif; font-size: 14px; font-weight: 500; line-height: 14px; cursor: pointer; }
|
||||
.des-download:hover { background: rgba(41, 119, 240, 0.06); }
|
||||
@media (max-width: 420px) {
|
||||
.des-pop { left: 0; top: calc(100% + 6px); transform: none; }
|
||||
|
||||
Reference in New Issue
Block a user