Skip to content

Commit

Permalink
replace domain name
Browse files Browse the repository at this point in the history
  • Loading branch information
vanaigr committed Mar 9, 2024
1 parent 52d0e5d commit 570b5ea
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion calendar.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
<a class="link no-select" href="./index.html" target="_blank">Создать расписание</a>
<a class="link no-select" href="./fix.html" target="_blank">Расписание из текста</a>
<a class="link no-select" href="./help-page.html" target="_blank">Помощь</a>
<a class="link no-select" href="https://github.com/VanaIgr/ScheduleRenderingJs" target="_blank">GitHub</a>
<a class="link no-select" href="https://github.com/GroupTimetable/GroupTimetable.github.io" target="_blank">GitHub</a>
</div>
</div>
</body>
Expand Down
16 changes: 8 additions & 8 deletions calendar.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const warningText = document.querySelector('.warning-text');

const params = (_ => {
const params = (_ => {
try {
const prmstr = window.location.search.split("=");
const sid = prmstr[1];
Expand Down Expand Up @@ -91,7 +91,7 @@ function scheduleToICS(schedule, dates, scheme, firstWeekIsFirst/*first calendar

line('BEGIN:VCALENDAR')
line('VERSION:2.0')
line('PRODID:-//Bob//vanaigr.github.io//EN')
line('PRODID:-//Bob//grouptimetable.github.io//EN')
line('CALSCALE:GREGORIAN')
line('METHOD:PUBLISH')
//some of these will hopefully work
Expand All @@ -107,12 +107,12 @@ function scheduleToICS(schedule, dates, scheme, firstWeekIsFirst/*first calendar
until0.setSeconds(59)
const until = dateToICS(until0)

const dow0 = 'MOTUWETHFRSASU'
const dow0 = 'MOTUWETHFRSASU'
const startDOW = new Date(dates[0]).getUTCDay()

function addLesson(startMins, endMins, dayOfWeek, interval, firstWeek, uid, summary) {
if(!warn && summary.match(warnRegex)) warn = true;
const start = new Date(dates[0])
const start = new Date(dates[0])
const currentDay = start.getUTCDay();
const distance = (dayOfWeek+1 + 7 - currentDay) % 7;
start.setUTCDate(start.getUTCDate() + distance);
Expand All @@ -134,7 +134,7 @@ function scheduleToICS(schedule, dates, scheme, firstWeekIsFirst/*first calendar
line(`RRULE:FREQ=WEEKLY;WKST=SU;UNTIL=${until};INTERVAL=${interval};BYDAY=${dow}`)
line('CREATED:' + now)
line('DTSTAMP:' + now)
line('UID:' + uid + '@vanaigr.github.io')
line('UID:' + uid + '@grouptimetable.github.io')
line('SEQUENCE:0')
line('STATUS:CONFIRMED')
line('SUMMARY:' + summary)
Expand All @@ -155,18 +155,18 @@ function scheduleToICS(schedule, dates, scheme, firstWeekIsFirst/*first calendar
const l1 = lesson.lessons[lessonOff]
const l2 = lesson.lessons[lessonOff + 2]
if(l1 === l2 && l1.trim() !== '') addLesson(
lesson.sTime, lesson.eTime,
lesson.sTime, lesson.eTime,
dayI, 1, undefined, 'D'+dayI+'L'+j+'G'+(isFirstGroup ? 1 : 2)+'T'+0,
l1
)
else {
if(l1.trim() !== '') addLesson(
lesson.sTime, lesson.eTime,
lesson.sTime, lesson.eTime,
dayI, 2, true, 'D'+dayI+'L'+j+'G'+(isFirstGroup ? 1 : 2)+'T'+1,
l1
)
if(l2.trim() !== '') addLesson(
lesson.sTime, lesson.eTime,
lesson.sTime, lesson.eTime,
dayI, 2, false, 'D'+dayI+'L'+j+'G'+(isFirstGroup ? 1 : 2)+'T'+2,
l2
)
Expand Down
2 changes: 1 addition & 1 deletion fix.html
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
<div id="footer">
<a class="link no-select" href="./index.html" target="_blank">Создать расписание</a>
<a class="link no-select" href="./help-page.html" target="_blank">Помощь</a>
<a class="link no-select" href="https://github.com/VanaIgr/ScheduleRenderingJs" target="_blank">GitHub</a>
<a class="link no-select" href="https://github.com/GroupTimetable/GroupTimetable.github.io" target="_blank">GitHub</a>
</div>
</div>
</body>
Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@
<div id="footer">
<a class="link no-select" href="./fix.html" target="_blank">Расписание из текста</a>
<a class="link no-select" href="./help-page.html" target="_blank">Помощь</a>
<a class="link no-select" href="https://github.com/VanaIgr/ScheduleRenderingJs" target="_blank">GitHub</a>
<a class="link no-select" href="https://github.com/GroupTimetable/GroupTimetable.github.io" target="_blank">GitHub</a>
</div>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion schedule.js
Original file line number Diff line number Diff line change
Expand Up @@ -803,7 +803,7 @@ async function renderSchedule(renderer, schedule, origPattern, rowRatio, borderF
renderer.finalizeRects()
}

const signText = 'vanaigr.github.io';
const signText = 'groupTimeTable.github.io';
var signX, signY, signFontSize;
/*calc signature size*/ {
const maxWidth = colWidth*0.8;
Expand Down

0 comments on commit 570b5ea

Please sign in to comment.