|
@@ -0,0 +1,275 @@
|
|
|
+<template>
|
|
|
+ <div class="certification-details-dialog" v-if="show">
|
|
|
+ <Dialog :show="show" :dialogName="dialogName">
|
|
|
+ <template #header>
|
|
|
+ <p class="title">{{ $t('signatures.certificateViewerDialog.title') }}</p>
|
|
|
+ <p class="desc">{{ $t('signatures.certificateViewerDialog.title') }}</p>
|
|
|
+ </template>
|
|
|
+
|
|
|
+ <div class="container">
|
|
|
+ <div class="left">
|
|
|
+ <p :class="{ 'highlighted': isHighlighted === 0 }" @focus="isHighlighted = 0" @blur="isHighlighted = -1" tabindex="-1">ComPDFKit 1</p>
|
|
|
+ <p :class="{ 'highlighted': isHighlighted === 1 }" @focus="isHighlighted = 1" @blur="isHighlighted = -1" tabindex="-1">ComPDFKit 2</p>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div class="right">
|
|
|
+ <div class="tabs">
|
|
|
+ <div @click="activePanel = 1" :class="{ active: activePanel === 1 }">{{ $t('signatures.certificateViewerDialog.abstracts') }}</div>
|
|
|
+ <div @click="activePanel = 2" :class="{ active: activePanel === 2 }">{{ $t('signatures.certificateViewerDialog.details') }}</div>
|
|
|
+ <div @click="activePanel = 3" :class="{ active: activePanel === 3 }">{{ $t('signatures.certificateViewerDialog.trust') }}</div>
|
|
|
+ </div>
|
|
|
+ <div class="panel">
|
|
|
+ <div class="summary">
|
|
|
+ <div class="title">
|
|
|
+ <div class="line-left"></div>
|
|
|
+ <span>{{ activePanel === 3 ? $t('signatures.certificateViewerDialog.trustedTo') : $t('signatures.certificateViewerDialog.summary') }}</span>
|
|
|
+ <div class="line-right"></div>
|
|
|
+ </div>
|
|
|
+ <div class="content">
|
|
|
+ <div v-show="activePanel === 1" class="abstracts">
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.issuedTo') }} <span>ComPDFKit<12341234@qq.com></span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.issuer') }} <span>ComPDFKit</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.validFrom') }} <span>2021/01/27 13:41:56 +08`00`</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.validTo') }} <span>Digital Signatures, Encrypted Documents, Key Agreements</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.intendedUsage') }} <span>Digital Signature, Non-Repudiation</span></p>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="activePanel === 2" class="details">
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.version') }} <span>1.9.0</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.algorithm') }} <span>SHA - 256 with RSA encryption (1.2.840.113549.1.11)</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.subject') }} <span>C=CN,O=ComPDFKit</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.issuer') }} <span>ComPDFKit</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.serialNumber') }} <span>3223484506630560670</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.validFrom') }} <span>2021/01/27 13:41:56 +08`00`</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.validTo') }} <span>2021/01/27 13:41:56 +08`00`</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.certificatePolicy') }} <span>Windows Certificate Policy</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.crlDistributionPoints') }} <span>/</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.issuerInfoAccess') }} <span>223384759660</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.issuerKeyIdentifier') }} <span>223384759660</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.subjectKeyIdentifier') }} <span>/</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.basicConstraints') }} <span>View Detailed Information</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.keyUsage') }} <span>/</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.publicKey') }} <span>256 bytes: D3 10 27 F7 23</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.X509') }} <span>Unspecified value</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.SHA1Digest') }} <span>/</span></p>
|
|
|
+ <p>{{ $t('signatures.certificateViewerDialog.MD5Digest') }} <span>50:28:38:22:09:34:63</span></p>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="activePanel === 3" class="trust">
|
|
|
+ <p><SuccessIcon /><span>Sign document or data</span></p>
|
|
|
+ <p><FailedIcon /><span>Certify document</span></p>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <div v-show="activePanel === 3" class="trust-button">
|
|
|
+ <div @click="">{{ $t('signatures.certificateViewerDialog.addToTrust') }}</div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <template #footer>
|
|
|
+ <div class="rect-button blue" @click="close">{{ $t('signatures.certificateViewerDialog.done') }}</div>
|
|
|
+ </template>
|
|
|
+ </Dialog>
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script setup>
|
|
|
+import { computed, ref } from 'vue'
|
|
|
+import { useViewerStore } from '@/stores/modules/viewer'
|
|
|
+
|
|
|
+const dialogName = 'certificateViewerDialog'
|
|
|
+
|
|
|
+const useViewer = useViewerStore()
|
|
|
+
|
|
|
+const show = computed(() => useViewer.isElementOpen(dialogName))
|
|
|
+
|
|
|
+const activePanel = ref(1)
|
|
|
+const isHighlighted = ref(-1)
|
|
|
+
|
|
|
+const close = () => {
|
|
|
+ useViewer.closeElement(dialogName)
|
|
|
+}
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss">
|
|
|
+.certification-details-dialog {
|
|
|
+
|
|
|
+ .dialog-container {
|
|
|
+ padding: 20px;
|
|
|
+ width: 1070px;
|
|
|
+ border-radius: 0;
|
|
|
+
|
|
|
+ header {
|
|
|
+
|
|
|
+ .title {
|
|
|
+ font-size: 16px;
|
|
|
+ line-height: 24px;
|
|
|
+ font-weight: 700;
|
|
|
+ color: var(--c-right-side-header-text);
|
|
|
+ }
|
|
|
+
|
|
|
+ .desc {
|
|
|
+ margin-top: 20px;
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 16px;
|
|
|
+ font-weight: 400;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ main {
|
|
|
+ margin: 32px 0;
|
|
|
+ }
|
|
|
+
|
|
|
+ footer {
|
|
|
+ .rect-button {
|
|
|
+ border-radius: 4px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .container {
|
|
|
+ display: flex;
|
|
|
+
|
|
|
+ .left {
|
|
|
+ margin-right: 32px;
|
|
|
+ padding: 2px;
|
|
|
+ width: 246px;
|
|
|
+ border: 1px solid var(--c-header-border);
|
|
|
+
|
|
|
+ p {
|
|
|
+ padding: 4px;
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 16px;
|
|
|
+ color: var(--c-black-text);
|
|
|
+ cursor: default;
|
|
|
+
|
|
|
+ &.highlighted {
|
|
|
+ background: #1460F3;
|
|
|
+ color: white;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .right {
|
|
|
+ flex: 1;
|
|
|
+ border: 1px solid var(--c-header-border);
|
|
|
+ height: 700px;
|
|
|
+
|
|
|
+ .tabs {
|
|
|
+ display: flex;
|
|
|
+ justify-content: center;
|
|
|
+ border-bottom: 1px solid var(--c-header-border);
|
|
|
+
|
|
|
+ > div {
|
|
|
+ margin: 10px 12px -1px 12px;
|
|
|
+ padding-bottom: 4px;
|
|
|
+ font-size: 16px;
|
|
|
+ line-height: 24px;
|
|
|
+ cursor: pointer;
|
|
|
+
|
|
|
+ &.active {
|
|
|
+ color: var(--c-right-side-header-text);
|
|
|
+ font-weight: 700;
|
|
|
+ border-bottom: 2px solid #4982E6;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .panel {
|
|
|
+ padding: 20px;
|
|
|
+
|
|
|
+ .summary {
|
|
|
+ margin-top: 10px;
|
|
|
+ border: 1px solid var(--c-header-border);
|
|
|
+ border-top-width: 0px;
|
|
|
+
|
|
|
+ .title {
|
|
|
+ display: flex;
|
|
|
+
|
|
|
+ span {
|
|
|
+ margin: -12px 4px 0 4px;
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 20px;
|
|
|
+ font-weight: 600;
|
|
|
+ color: var(--c-black-text);
|
|
|
+ }
|
|
|
+
|
|
|
+ .line-left {
|
|
|
+ width: 12px;
|
|
|
+ border-top: 1px solid var(--c-header-border);
|
|
|
+ }
|
|
|
+
|
|
|
+ .line-right {
|
|
|
+ flex: 1;
|
|
|
+ border-top: 1px solid var(--c-header-border);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .content {
|
|
|
+ margin: 20px 20px 16px;
|
|
|
+
|
|
|
+ p {
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 20px;
|
|
|
+
|
|
|
+ & + p {
|
|
|
+ margin-top: 12px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ span {
|
|
|
+ color: var(--c-side-annotation-text);
|
|
|
+ }
|
|
|
+
|
|
|
+ .details p {
|
|
|
+ color: var(--c-black-text);
|
|
|
+ }
|
|
|
+
|
|
|
+ .trust p {
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+
|
|
|
+ span {
|
|
|
+ color: var(--c-right-side-header-text);
|
|
|
+ }
|
|
|
+
|
|
|
+ svg {
|
|
|
+ max-width: 20px;
|
|
|
+ width: 20px;
|
|
|
+ height: 20px;
|
|
|
+ margin-right: 4px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .trust-button {
|
|
|
+ margin-top: 24px;
|
|
|
+ text-align: right;
|
|
|
+
|
|
|
+ > div {
|
|
|
+ padding: 0 12px;
|
|
|
+ display: inline-block;
|
|
|
+ height: 32px;
|
|
|
+ border: 1px solid var(--c-header-border);
|
|
|
+ border-radius: 1px;
|
|
|
+ background: var(--c-header-button-active);
|
|
|
+ cursor: pointer;
|
|
|
+ font-size: 14px;
|
|
|
+ line-height: 32px;
|
|
|
+ color: var(--c-right-side-header-text);
|
|
|
+
|
|
|
+ &:hover {
|
|
|
+ background: var(--c-popup-bg-hover);
|
|
|
+ color: white;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+</style>
|