ReviewOS

also looking at this

stacks/postline

Calendar view for the queue (#20)

#23
Merged glennmichael123 wants to merge feat/queue-calendar into main
2 files +166 -21
resources/views/index.stxmodified+12-0
Changes to resources/views/index.stx
@@ -973,9 +973,21 @@
973973 // Wait for the social module (a deferred `type=module` script) before the
974974 // first provider fetch so window.postlineSocial is guaranteed to exist.
975975 // Load the edit post only after connection so provider toggles resolve.
976 // /?schedule=YYYY-MM-DD (from the queue calendar) opens the schedule
977 // input pre-set to 09:00 local on that day.
978 const scheduleParam = new URLSearchParams(window.location.search).get('schedule')
979 const applyScheduleParam = () => {
980 if (!scheduleParam || !scheduleInput || !/^\d{4}-\d{2}-\d{2}$/.test(scheduleParam)) return
981 scheduleInput.value = `${scheduleParam}T09:00`
982 scheduleInput.classList.remove('hidden')
983 updatePublishLabel()
984 activeTextarea()?.focus()
985 }
986
976987 const start = async () => {
977988 await refreshConnection()
978989 if (editParam) await loadEditPost(editParam)
990 else applyScheduleParam()
979991 }
980992 if (document.readyState === 'loading') {
981993 document.addEventListener('DOMContentLoaded', () => void start(), { once: true })