mirror of
https://github.com/go-gitea/gitea
synced 2025-07-03 09:07:19 +00:00
Add support for 3D/CAD file formats preview (#34794)
Fix #34775 --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
@ -52,8 +52,7 @@ form.single-button-form.is-loading .button {
|
||||
}
|
||||
|
||||
.markup pre.is-loading,
|
||||
.editor-loading.is-loading,
|
||||
.pdf-content.is-loading {
|
||||
.editor-loading.is-loading {
|
||||
height: var(--height-loading);
|
||||
}
|
||||
|
||||
|
@ -183,42 +183,6 @@ td .commit-summary {
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.view-raw {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.view-raw > * {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.view-raw audio,
|
||||
.view-raw video,
|
||||
.view-raw img {
|
||||
margin: 1rem 0;
|
||||
border-radius: 0;
|
||||
object-fit: contain;
|
||||
}
|
||||
|
||||
.view-raw img[src$=".svg" i] {
|
||||
max-height: 600px !important;
|
||||
max-width: 600px !important;
|
||||
}
|
||||
|
||||
.pdf-content {
|
||||
width: 100%;
|
||||
height: 600px;
|
||||
border: none !important;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.pdf-content .pdf-fallback-button {
|
||||
margin: 50px auto;
|
||||
}
|
||||
|
||||
.repository.file.list .non-diff-file-content .plain-text {
|
||||
padding: 1em 2em;
|
||||
}
|
||||
@ -241,10 +205,6 @@ td .commit-summary {
|
||||
padding: 0 !important;
|
||||
}
|
||||
|
||||
.non-diff-file-content .pdfobject {
|
||||
border-radius: 0 0 var(--border-radius) var(--border-radius);
|
||||
}
|
||||
|
||||
.repo-editor-header {
|
||||
width: 100%;
|
||||
}
|
||||
|
@ -60,3 +60,33 @@
|
||||
.file-view.code-view .ui.button.code-line-button:hover {
|
||||
background: var(--color-secondary);
|
||||
}
|
||||
|
||||
.view-raw {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.view-raw > * {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.view-raw audio,
|
||||
.view-raw video,
|
||||
.view-raw img {
|
||||
margin: 1rem;
|
||||
border-radius: 0;
|
||||
object-fit: contain;
|
||||
}
|
||||
|
||||
.view-raw img[src$=".svg" i] {
|
||||
max-height: 600px !important;
|
||||
max-width: 600px !important;
|
||||
}
|
||||
|
||||
.file-view-render-container {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.file-view-render-container :last-child {
|
||||
border-radius: 0 0 var(--border-radius) var(--border-radius); /* to match the "ui segment" bottom radius */
|
||||
}
|
||||
|
Reference in New Issue
Block a user