Use current view state for new periods

Resolves #1368
This commit is contained in:
Hans5958 2023-03-19 11:55:56 +07:00
parent 0c1f8f6d11
commit 5479d1d9b0

View file

@ -747,7 +747,7 @@ function initDraw() {
} else {
document.getElementById("offcanvasDrawLabel").textContent = "New Entry"
pathWithPeriods.push([defaultPeriod, []])
pathWithPeriods.push([formatPeriod(currentPeriod, currentPeriod, currentVariation), []])
// Builds multi-input list
addWebsiteFields("", 0, [0])
@ -778,7 +778,7 @@ function initDraw() {
})
periodsAdd.addEventListener('click', () => {
pathWithPeriods.push([defaultPeriod, []])
pathWithPeriods.push([formatPeriod(currentPeriod, currentPeriod, currentVariation), []])
initPeriodGroups()
})