Skip to content

Commit e8c01e2

Browse files
committed
new sg layout
1 parent 85616e3 commit e8c01e2

10 files changed

Lines changed: 355 additions & 376 deletions

File tree

manifest-firefox.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"manifest_version": 3,
33
"name": "__MSG_appName__",
44
"description": "__MSG_appDesc__",
5-
"version": "3.15.3.1",
5+
"version": "3.15.3.2",
66
"default_locale": "nl",
77
"icons": {
88
"16": "icons/icon@16px.png",

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"manifest_version": 3,
33
"name": "__MSG_appName__",
44
"description": "__MSG_appDesc__",
5-
"version": "3.15.3.1",
5+
"version": "3.15.3.2",
66
"default_locale": "nl",
77
"icons": {
88
"16": "icons/icon@16px.png",

popup/public/settings.js

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -373,19 +373,6 @@ export default [
373373
subtitle: "Studiewijzers zullen worden gegroepeerd op vak.",
374374
default: true,
375375
},
376-
{
377-
id: "sw-cols",
378-
title: "Aantal kolommen",
379-
type: "Slider",
380-
default: 3,
381-
decimals: 0,
382-
min: 1,
383-
max: 5,
384-
step: 1,
385-
conditions: [
386-
{ settingId: 'sw-enabled', operator: 'equal', value: true }
387-
],
388-
},
389376
{
390377
id: "sw-period",
391378
title: "Periodenummers bij studiewijzers",

src/scripts/api.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,14 @@ class MagisterApi {
171171
studyguides() {
172172
return new MagisterApiRequestStudyguides().get();
173173
}
174+
175+
studyguide(studyguideId) {
176+
return new MagisterApiRequestStudyguide(studyguideId).get();
177+
}
178+
179+
studyguideItem(studyguideId, itemId) {
180+
return new MagisterApiRequestStudyguideItem(studyguideId, itemId).get();
181+
}
174182
}
175183

176184
class MagisterApiRequest {
@@ -564,4 +572,20 @@ class MagisterApiRequestStudyguides extends MagisterApiRequest {
564572
outputFormat = (res) => res.Items;
565573
}
566574

575+
class MagisterApiRequestStudyguide extends MagisterApiRequest {
576+
constructor(studyguideId) {
577+
super();
578+
this.identifier = `studyguide${studyguideId}`;
579+
this.path = `api/leerlingen/$USERID/studiewijzers/${studyguideId}`;
580+
}
581+
}
582+
583+
class MagisterApiRequestStudyguideItem extends MagisterApiRequest {
584+
constructor(studyguideId, itemId) {
585+
super();
586+
this.identifier = `studyguide${studyguideId}item${itemId}`;
587+
this.path = `api/leerlingen/$USERID/studiewijzers/${studyguideId}/items/${itemId}`;
588+
}
589+
}
590+
567591
const magisterApi = new MagisterApi();

src/scripts/grades/backup.js

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -156,13 +156,6 @@ class GradeBackupPane extends Pane {
156156
return;
157157
}
158158

159-
// this.close();
160-
161-
const aside = await awaitElement('aside'), container = await awaitElement('.container[id$=container]'), asideResizer = document.querySelector('#st-aside-resize');
162-
aside.setAttribute('style', 'display:none;width:0px;');
163-
container.style.paddingRight = '20px';
164-
if (asideResizer) asideResizer.setAttribute('style', `display:none`);
165-
166159
if (gradeTables.find(t => t.date?.getTime() === new Date(date).getTime())) {
167160
notify('snackbar', "Je hebt deze back-up al geïmporteerd.");
168161
return;

src/scripts/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ async function popstate() {
245245
element('meta', `st-${chrome.runtime.id.replace(/[^a-zA-Z0-9-_ ]/g, '')}`, document.head)
246246
setTimeout(upgradeAssistant, 200)
247247

248-
document.querySelectorAll('#st-aside-resize, *[id^="st-"][id$="-ghost"], *[id^="st-start"], *[id^="st-sg"], .k-animation-container, .st-tooltip').forEach(e => {
248+
document.querySelectorAll('*[id^="st-"][id$="-ghost"], *[id^="st-start"], *[id^="st-sg"], .k-animation-container, .st-tooltip').forEach(e => {
249249
e.remove()
250250
})
251251
document.querySelectorAll('.st-overlay').forEach(e => { if (e.open) e.close?.() })

0 commit comments

Comments
 (0)