Skip to content

Commit

Permalink
Musterlösung hinzugefügt
Browse files Browse the repository at this point in the history
  • Loading branch information
Richard Conrardy authored and Richard Conrardy committed Mar 15, 2024
1 parent 024acb1 commit abbea15
Show file tree
Hide file tree
Showing 27 changed files with 2,395 additions and 2,288 deletions.
Binary file modified .DS_Store
Binary file not shown.
Binary file modified .RData
Binary file not shown.
2 changes: 2 additions & 0 deletions .Rhistory
Original file line number Diff line number Diff line change
Expand Up @@ -119,3 +119,5 @@ install.packages("reticulate")
git add .
git add .
load("~/Quarto/Quarto_Kurse/.RData")
pip version
pip --version
2 changes: 1 addition & 1 deletion .Rproj.user/71E152F1/pcs/files-pane.pper
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
"ascending": true
}
],
"path": "~/Quarto/Quarto_Kurse/bibliographien"
"path": "~/Quarto/Quarto_Kurse/lerngelegenheiten/LG_verstehensorientiert_pruefen"
}
12 changes: 6 additions & 6 deletions .Rproj.user/71E152F1/pcs/windowlayoutstate.pper
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"left": {
"splitterpos": 183,
"splitterpos": 232,
"topwindowstate": "NORMAL",
"panelheight": 499,
"windowheight": 537
"panelheight": 657,
"windowheight": 671
},
"right": {
"splitterpos": 286,
"splitterpos": 360,
"topwindowstate": "MINIMIZE",
"panelheight": 502,
"windowheight": 540
"panelheight": 633,
"windowheight": 671
}
}
2 changes: 1 addition & 1 deletion .Rproj.user/71E152F1/pcs/workbench-pane.pper
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"TabSet1": 0,
"TabSet2": 5,
"TabSet2": 4,
"TabZoom": {}
}
2 changes: 2 additions & 0 deletions .Rproj.user/71E152F1/sources/prop/INDEX
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@
~%2FNextcloud%2FQuarto%2FQuarto_Medien_Informatik%2Findex.qmd="64D40733"
~%2FNextcloud%2FQuarto%2FTest-Dokumente%2FTest-Dokumente.qmd="05D375DD"
~%2FNextcloud%2FQuarto%2Ff%C3%BCr%20github%20kurse="C00AB026"
~%2FPython_KI_Math_FS24%2Fleandro_luethi_quatrate.py="87A77DD5"
~%2FPython_KI_Math_FS24%2Fpasswort.py="A804D349"
~%2FQuarto%2FPersonalzeug.Rmd="C58F261E"
~%2FQuarto%2FQuarto_Kurse%2F.gitignore="B73C8CBE"
Expand Down Expand Up @@ -185,6 +186,7 @@
~%2FQuarto%2FQuarto_other%2F_quarto.yml="85C20D6D"
~%2FQuarto%2FQuarto_other%2Fexcl_Spielwiese.qmd="5F934DEA"
~%2FQuarto%2FQuarto_other%2Fstyles.scss="E7C0712D"
~%2FQuarto%2Fvenn.svg="9380E400"
~%2FQuarto_Kurse%2F_publish.yml="F9AF19D2"
~%2FQuarto_Kurse%2F_quarto.yml="725C9E31"
~%2FQuarto_Kurse%2Fadd-custom-footer.html="1675B283"
Expand Down
2 changes: 0 additions & 2 deletions .Rproj.user/shared/notebooks/paths
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/Users/richardconrardy/Downloads/AufgabenPython.tex="BA6D01FC"
/Users/richardconrardy/Downloads/Exported Items.bib="EA067C79"
/Users/richardconrardy/Exported Items.bib="C04BA746"
/Users/richardconrardy/Python_KI_Math_FS24/passwort.py="212A6955"
/Users/richardconrardy/Quarto/Personalzeug.Rmd="3D570659"
Expand Down
22 changes: 22 additions & 0 deletions _extensions/andrie/gongtimer/_extension.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: gongtimer
script: [elapsed_time_bar.js]

title: gongtimer
author: Andrie de Vries
version: 0.1.0
quarto-required: ">=1.2.222"
contributes:
revealjs-plugins:
- name: gongtimer
script:
- elapsed_time_bar.js
config:
gongtimer:
# // - (required) your allotted time for presentation
allottedTime: 5
# // - (optional) height of page/time progress bar
progressBarHeight: 3
# // - (optional) bar color
barColor: 'rgb(200,0,0)'
# // - (optional) bar color when timer is paused
pausedBarColor: 'rgba(200,0,0,.6)'
161 changes: 161 additions & 0 deletions _extensions/andrie/gongtimer/elapsed_time_bar.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,161 @@
// MIT License
// tkrkt/reveal.js-elapsed-time-bar
// https://github.com/tkrkt/reveal.js-elapsed-time-bar
// with minor modifications by Andrie de Vries to support Quarto

var _gong = {
// default value
barColor: 'rgb(200,0,0)',
pausedBarColor: 'rgba(200,0,0,.6)',

isPaused: false,
isFinished: false,

allottedTime: null,
timeProgressBar: null,
startTime: null,
pauseTime: null,
pauseTimeDuration: 0,

/**
* initialize elements
*/
handleReady: function(config) {
// var config = Reveal.getConfig();

// activate this plugin if config.allottedTime exists.
if (!config.allottedTime) {
console.warn('Failed to start ElapsedTimeBar plugin. "allottedTime" property is required.');
return;
}

// set configurations
this.barColor = config.barColor || this.barColor;
this.pausedBarColor = config.pausedBarColor || this.pausedBarColor;

// calc barHeight from config.barHeight or page-progress container
var barHeight;
var pageProgressContainer = document.querySelector('.progress');
if (config.progressBarHeight) {
barHeight = parseInt(config.progressBarHeight, 10) + 'px';

// override height of page-progress container
pageProgressContainer && (pageProgressContainer.style.height = barHeight);
} else if (config.progress && pageProgressContainer) {
// get height from page-progress container
barHeight = pageProgressContainer.getBoundingClientRect().height + 'px';
} else {
// default
barHeight = '3px';
}

// create container of time-progress
var timeProgressContainer = document.createElement('div');
timeProgressContainer.classList.add('progress');
Object.entries({
display: 'block',
position: 'fixed',
bottom: config.progress ? barHeight : 0,
width: '100%',
height: barHeight
}).forEach(([k, v]) => {
timeProgressContainer.style[k] = v;
});
document.querySelector('.reveal').appendChild(timeProgressContainer);

// create content of time-progress
this.timeProgressBar = document.createElement('div');
Object.entries({
height: '100%',
willChange: 'width'
}).forEach(([k, v]) => {
this.timeProgressBar.style[k] = v;
});
timeProgressContainer.appendChild(this.timeProgressBar);

// start timer
this.start(config.allottedTime);
},

/**
* update repeatedly using requestAnimationFrame.
*/
loop() {
if (this.isPaused) return;
var now = +new Date();
var elapsedTime = now - this.startTime - this.pauseTimeDuration;
if (elapsedTime > this.allottedTime) {
this.timeProgressBar.style.width = '100%';
this.isFinished = true;
} else {
this.timeProgressBar.style.width = elapsedTime / this.allottedTime * 100 + '%';
requestAnimationFrame(this.loop.bind(this));
}
},

/**
* set color of progress bar
*/
setBarColor() {
if (this.isPaused) {
this.timeProgressBar.style.backgroundColor = this.pausedBarColor;
} else {
this.timeProgressBar.style.backgroundColor = this.barColor;
}
},

/**
* start(reset) timer with new allotted time.
* @param {number} allottedTime
* @param {number} [elapsedTime=0]
*/
start(allottedTime, elapsedTime = 0) {
this.isFinished = false;
this.isPaused = false;
this.allottedTime = allottedTime;
this.startTime = +new Date() - elapsedTime;
this.pauseTimeDuration = 0;
this.setBarColor();
this.loop();
},

reset() {
this.start(this.allottedTime);
},

pause() {
if (this.isPaused) return;
this.isPaused = true;
this.pauseTime = +new Date();
this.setBarColor();
},

resume() {
if (!this.isPaused) return;

// add paused time duration
this.isPaused = false;
this.pauseTimeDuration += new Date() - this.pauseTime;
this.pauseTime = null;
this.setBarColor();
this.loop();
}
};


const initGong = function(deck) {
const config = deck.getConfig();
const options = config.gongtimer || {};
options.allottedTime = options.allottedTime * 60 * 1000;
window.addEventListener('ready', () => _gong.handleReady(options));
}


window.gongtimer = window.gongtimer || function() {
return {
id: 'gongtimer',
init: (deck) => {
initGong(deck);
},
}
};
1 change: 1 addition & 0 deletions _publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
quarto-pub:
- id: 65a90d48-d9b0-4791-b6ed-3db7ab4cbc85
url: 'https://phbern-rconrardy.quarto.pub/seminare'

Loading

0 comments on commit abbea15

Please sign in to comment.