Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pptist
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
viitto
pptist
Commits
e4629888
Commit
e4629888
authored
Dec 07, 2023
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复播放时,幻灯片竖版比例问题
parent
03ad1613
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
ScreenSlide.vue
src/views/Screen/ScreenSlide.vue
+4
-3
ScreenSlideList.vue
src/views/Screen/ScreenSlideList.vue
+3
-4
No files found.
src/views/Screen/ScreenSlide.vue
View file @
e4629888
<
template
>
<div
class=
"screen-slide"
style=
"overflow: hidden;"
:style=
"
{
width:
VIEWPORT_SIZE
+ 'px',
height:
VIEWPORT_SIZE
* viewportRatio + 'px',
width:
(viewportRatio
<1
?
VIEWPORT_SIZE:VIEWPORT_VER_SIZE
)
+
'
px
',
height:
(
viewportRatio
<1
?
VIEWPORT_SIZE:VIEWPORT_VER_SIZE
)
*
viewportRatio
+
'
px
',
transform:
`
scale
($
{scale})`,
}"
>
...
...
@@ -26,7 +27,7 @@ import { storeToRefs } from 'pinia'
import
{
useSlidesStore
}
from
'@/store'
import
type
{
Slide
}
from
'@/types/slides'
import
{
injectKeySlideId
}
from
'@/types/injectKey'
import
{
VIEWPORT_SIZE
}
from
'@/configs/canvas'
import
{
VIEWPORT_SIZE
,
VIEWPORT_VER_SIZE
}
from
'@/configs/canvas'
import
useSlideBackgroundStyle
from
'@/hooks/useSlideBackgroundStyle'
import
ScreenElement
from
'./ScreenElement.vue'
...
...
src/views/Screen/ScreenSlideList.vue
View file @
e4629888
...
...
@@ -39,7 +39,7 @@ import { computed, provide } from 'vue'
import
{
storeToRefs
}
from
'pinia'
import
{
useSlidesStore
}
from
'@/store'
import
{
injectKeySlideScale
}
from
'@/types/injectKey'
import
{
VIEWPORT_SIZE
}
from
'@/configs/canvas'
import
{
VIEWPORT_SIZE
,
VIEWPORT_VER_SIZE
}
from
'@/configs/canvas'
import
{
SLIDE_ANIMATIONS
}
from
'@/configs/animation'
import
ScreenSlide
from
'./ScreenSlide.vue'
...
...
@@ -52,7 +52,7 @@ const props = defineProps<{
manualExitFullscreen
:
()
=>
void
}
>
()
const
{
slides
,
slideIndex
}
=
storeToRefs
(
useSlidesStore
())
const
{
slides
,
slideIndex
,
viewportRatio
}
=
storeToRefs
(
useSlidesStore
())
const
slidesWithTurningMode
=
computed
(()
=>
{
return
slides
.
value
.
map
(
slide
=>
{
...
...
@@ -68,8 +68,7 @@ const slidesWithTurningMode = computed(() => {
}
})
})
const
scale
=
computed
(()
=>
props
.
slideWidth
/
VIEWPORT_SIZE
)
const
scale
=
computed
(()
=>
props
.
slideWidth
/
(
viewportRatio
.
value
<
1
?
VIEWPORT_SIZE
:
VIEWPORT_VER_SIZE
))
provide
(
injectKeySlideScale
,
scale
)
</
script
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment