fix viewer background
This commit is contained in:
parent
62ac0f5f9c
commit
2bfa018e96
|
|
@ -81,7 +81,7 @@ const Viewer: React.FC<Props> = (props) => {
|
||||||
const [running, setRunning] = useState(false)
|
const [running, setRunning] = useState(false)
|
||||||
const [reset, setReset] = useState(0)
|
const [reset, setReset] = useState(0)
|
||||||
const [background, setBackground] = useState('#fff')
|
const [background, setBackground] = useState('#fff')
|
||||||
const [bgPicture, setBgPicture] = useState(0)
|
const [bgPicture, setBgPicture] = useState(-1)
|
||||||
|
|
||||||
const indicator = (() => {
|
const indicator = (() => {
|
||||||
const { skin, cape } = props
|
const { skin, cape } = props
|
||||||
|
|
@ -197,7 +197,7 @@ const Viewer: React.FC<Props> = (props) => {
|
||||||
const setNextPicture = () => {
|
const setNextPicture = () => {
|
||||||
let index = bgPicture
|
let index = bgPicture
|
||||||
if (bgPicture >= PICTURES_COUNT - 1) {
|
if (bgPicture >= PICTURES_COUNT - 1) {
|
||||||
index = 1
|
index = 0
|
||||||
} else {
|
} else {
|
||||||
index += 1
|
index += 1
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user