Commit 7ab3c5dd authored by Samantha Monty's avatar Samantha Monty

Merge branch 'master' into 274-quiz-studying-js-and-css

parents a34ba682 1d243bbe
......@@ -93,7 +93,35 @@ test:linux:
- .stack-work
needs:
- job: build:linux
artifacts: true
interruptible: true
test:mac:
stage: test
tags:
- mac
script:
- make test
cache:
key: stack_work
paths:
- .stack-work
needs:
- job: build:mac
interruptible: true
test:win:
tags:
- win
stage: test
script:
- "& stack test -j1"
cache:
key: test-win
paths:
- .stack-work
when: always
needs:
- job: build:win
interruptible: true
deploy:mac:
......@@ -144,6 +172,26 @@ deploy:linux:
interruptible: true
resource_group: deploy_linux
deploy:docker:
stage: deploy
tags:
- docker
image:
name: gcr.io/kaniko-project/executor:debug
entrypoint: [""]
script:
- echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
- /kaniko/executor --context=$CI_PROJECT_DIR --dockerfile=$CI_PROJECT_DIR/Dockerfile-prebuilt --verbosity=warn --destination=$CI_REGISTRY_IMAGE:latest
needs:
- job: build:linux
artifacts: true
rules:
- if: '$CI_COMMIT_REF_NAME == "master"'
when: always
- if: '$CI_COMMIT_REF_NAME =~ /^v\d\.\d\.\d-patching$/'
when: always
interruptible: true
deploy:win:
stage: deploy
image:
......
FROM ubuntu:focal as decker
#set the encoding on UTF-8, so the parser works correctly, german language is also added for umlaute
#source of fix: https://blog.mkowalski.net/2016/05/16/solving-locale-issues-with-docker-containers/
RUN apt-get update && apt-get install --reinstall -y locales && \
sed -i 's/# de_DE.UTF-8 UTF-8/de_DE.UTF-8 UTF-8/' /etc/locale.gen && \
locale-gen de_DE.UTF-8
ENV LANG de_DE.UTF-8
ENV LANGUAGE de_DE
ENV LC_ALL de_DE.UTF-8
RUN dpkg-reconfigure --frontend noninteractive locales
ENV DEBIAN_FRONTEND noninteractive
RUN apt-get -y install tzdata
RUN apt-get install -y \
graphviz \
gnuplot \
rsync \
unzip \
zip \
wget
RUN wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb && \
dpkg --unpack google-chrome-stable_current_amd64.deb && apt-get install -f -y
COPY decker /usr/bin/decker
WORKDIR /decker
ENTRYPOINT ["decker"]
......@@ -132,7 +132,9 @@ run = do
" (branch: " ++
deckerGitBranch ++
", commit: " ++
deckerGitCommitId ++ ", tag: " ++ deckerGitVersionTag ++ ")"
deckerGitCommitId ++
", tag: " ++
deckerGitVersionTag ++ ", build date: " ++ deckerBuildDate ++ ")"
putNormal $ "pandoc version " ++ Text.unpack pandocVersion
putNormal $ "pandoc-types version " ++ showVersion pandocTypesVersion
--
......@@ -155,8 +157,8 @@ run = do
getTargets >>= needSel decksPdf
--
phony "watch" $ do
need ["html"]
watchChangesAndRepeat
need ["html"]
--
phony "open" $ do
need ["html"]
......@@ -172,11 +174,11 @@ run = do
liftIO waitForYes
--
phony "fast" $ do
watchChangesAndRepeat
need ["support"]
runHttpServer serverPort Nothing
pages <- currentlyServedPages
need $ map (publicDir </>) pages
watchChangesAndRepeat
--
priority 3 $ do
publicDir <//> "*-deck.html" %> \out -> do
......@@ -196,7 +198,7 @@ run = do
putNormal $ "# chrome started ... (for " <> out <> ")"
result <- liftIO $ launchChrome url out
case result of
Right msg -> putNormal $ "# chrome finished (for " <> out <> ")"
Right _ -> putNormal $ "# chrome finished (for " <> out <> ")"
Left msg -> error msg
--
publicDir <//> "*-handout.html" %> \out -> do
......@@ -247,7 +249,7 @@ run = do
"**/*.gnuplot.svg" %> \out -> do
let src = dropExtension out
need [src]
gnuplot ["-e", "'set output \"" ++ out ++ "\"'", src]
gnuplot ["-e", "\"set output '" ++ out ++ "'\"", src]
--
"**/*.tex.svg" %> \out -> do
let src = dropExtension out
......
......@@ -13,4 +13,3 @@ exclude-directories:
- third-party
static-resource-dirs:
- test/static
\ No newline at end of file
cradle:
stack:
- path: "./src"
component: "decker:lib"
- path: "./src-win"
component: "decker:lib"
- path: "./src-unix"
component: "decker:lib"
- path: "./app/Decker.hs"
component: "decker:exe:decker"
- path: "./app/Paths_decker.hs"
component: "decker:exe:decker"
- path: "./test"
component: "decker:test:decker-test"
......@@ -3,7 +3,6 @@ bibliography: example.bib
chalkboard: 'example-deck.json'
controls: true
csl: 'chicago-author-date.csl'
history: true
menu: true
title: Decker Slide Tool Reference Guide
---
......
......@@ -3,7 +3,7 @@
* Mario's versions
*********************************************/
.white-on-blue {
.white-on-blue {
color: #ffffff;
background-color: #003366;
}
......@@ -33,7 +33,6 @@
}
.teaser-img {
margin: 20px auto;
height: 10%;
width: auto;
display: block;
img {
......@@ -41,12 +40,17 @@
// Center horizontally
display: block;
margin: auto;
// Make the image as max 250px high retaining aspect ratio
// Make the image as max 25vh high retaining aspect ratio
// Max height 25vh means the image will take at max one fourth of the title page viewport
object-fit: contain;
max-height: 250px;
max-height: 25vh;
max-width: 100%;
width: auto;
}
}
.date {
text-align: center;
}
.author {
margin: 0px;
font-weight: normal;
......@@ -56,7 +60,7 @@
}
.affiliation-logo img {
margin: 0px 0 0 0;
height: 70px;
height: 10vh;
width: auto;
object-fit: contain;
display: block;
......@@ -75,7 +79,7 @@
}
.valign-block:before {
content: '';
display: inline-block;
// display: inline-block;
height: 100%;
vertical-align: middle;
}
......
......@@ -1318,7 +1318,6 @@
.reveal .title-page .teaser-img {
margin: 20px auto;
height: 10%;
width: auto;
display: block;
}
......@@ -1328,10 +1327,15 @@
display: block;
margin: auto;
object-fit: contain;
max-height: 250px;
max-height: 25vh;
max-width: 100%;
width: auto;
}
.reveal .title-page .date {
text-align: center;
}
.reveal .title-page .author {
margin: 0px;
font-weight: normal;
......@@ -1342,7 +1346,7 @@
.reveal .title-page .affiliation-logo img {
margin: 0px 0 0 0;
height: 70px;
height: 10vh;
width: auto;
object-fit: contain;
display: block;
......@@ -1364,7 +1368,6 @@
.reveal .title-page .valign-block:before {
content: '';
display: inline-block;
height: 100%;
vertical-align: middle;
}
......@@ -1965,3 +1968,27 @@ dd {
color: var(--whiteboard-active-color);
background-color: rgba(255, 255, 255, 0.8);
}
/*********************************************
* MARIO: menu icon in top left corner
*********************************************/
.reveal .slide-menu-button {
position: fixed;
left: calc(var(--whiteboard-icon-size) * 0.25);
top: calc(var(--whiteboard-icon-size) * 0.25);
bottom: auto;
right: auto;
padding: 0;
margin: auto;
z-index: 40;
background: none;
font-size: var(--whiteboard-icon-size);
padding: calc(var(--whiteboard-icon-size) * 0.5);
opacity: 0.5;
color: var(--whiteboard-inactive-color);
}
.reveal .slide-menu-button:hover {
opacity: 1.0;
color: var(--whiteboard-active-color);
}
......@@ -441,4 +441,29 @@ dd {
opacity: 1.0;
color: var(--whiteboard-active-color);
background-color: rgba(255,255,255,0.8);
}
\ No newline at end of file
}
/*********************************************
* MARIO: menu icon in top left corner
*********************************************/
.reveal .slide-menu-button {
position: fixed;
left: calc(var(--whiteboard-icon-size) * 0.25);
top: calc(var(--whiteboard-icon-size) * 0.25);
bottom: auto;
right: auto;
padding: 0;
margin: auto;
z-index: 40;
background: none;
font-size: var(--whiteboard-icon-size);
padding: calc(var(--whiteboard-icon-size) * 0.5);
opacity: 0.5;
color: var(--whiteboard-inactive-color);
}
.reveal .slide-menu-button:hover {
opacity: 1.0;
color: var(--whiteboard-active-color);
}
/* Variables just for the panel */
div.q-panel {
--border-radius: 0.2em;
}
/* The opne button with the question mark */
div.open-button.checked {
visibility: hidden;
}
div.open-button:not(.checked) {
visibility: visible;
transition-delay: 0.4s;
}
div.open-button {
position: fixed;
top: 1vh;
right: 1vh;
z-index: 1000;
color: gray;
background-color: rgba(0, 0, 0, 0);
padding: 0;
margin: 0;
transition-property: visibility;
font-size: 3vh;
}
/* Badge for the open button*/
div.open-badge[data-count="0"] {
visibility: hidden;
}
div.open-badge {
position: absolute;
top: 0;
right: 0;
background-color: red;
color: white;
/* Scale the batch here, if desired */
font-size: 40%;
}
div.badge {
font-family: sans-serif;
font-weight: bold;
line-height: 1;
text-align: center;
vertical-align: baseline;
white-space: nowrap;
border-radius: 0.4em;
padding: 0.2em 0.4em;
}
div.q-panel.open {
transform: translateX(0);
}
div.q-panel:not(.open) {
transform: translateX(100%);
}
div.q-panel {
position: fixed;
top: 0;
bottom: 0;
left: 60%;
right: 0;
z-index: 100;
background-color: rgba(0, 0, 0, 0);
display: flex;
flex-flow: column nowrap;
align-items: stretch;
font-family: "Roboto", Helvetica, sans-serif;
font-size: 2.5vh;
font-weight: normal;
color: rgba(0, 0, 0, 1);
padding: 0;
transition: 0.3s ease-in-out;
border: none;
border-radius: var(--border-radius);
}
div.q-panel.authorized div.q-footer {
display: none;
}
div.q-panel div.q-header {
flex: 0 1 content;
display: flex;
flex-flow: row nowrap;
align-items: center;
background-color: rgba(0, 0, 0, 0.1);
padding: 0.3em;
}
div.q-panel div.q-header div.q-title {
flex: 0 1;
margin-right: 1em;
}
div.q-panel div.q-header div.counter[data-count="0"] {
visibility: hidden;
}
div.q-panel div.q-header div.counter {
flex: 0 1;
margin-right: 1em;
font-size: 0.9em;
background-color: red;
color: white;
}
div.q-panel div.q-header .hidden {
visibility: hidden;
}
div.q-panel div.q-header input {
font-family: "Roboto", Helvetica, sans-serif;
font-size: 0.8em;
}
div.q-panel div.q-header input[type="text"],
div.q-panel div.q-header input[type="password"] {
flex: 1 1;
min-width: 2em;
max-width: 100em;
background-color: rgba(255, 255, 255, 0.9);
border: none;
border-radius: var(--border-radius);
outline: none;
padding: 0.3em;
margin: 0;
}
div.q-panel div.q-header button {
padding-left: 0.4em;
}
div.q-panel div.q-header button.q-check {
flex: 0 1;
color: gray;
background-color: rgba(0, 0, 0, 0);
border: none;
border-radius: var(--border-radius);
outline: none;
}
div.q-panel div.q-header button.q-check.checked i.lock {
display: inline;
}
div.q-panel div.q-header button.q-check.checked i.unlock {
display: none;
}
div.q-panel div.q-header button.q-check:not(.checked) i.lock {
display: none;
}
div.q-panel div.q-header button.q-check:not(.checked) i.unlock {
display: inline;
}
div.q-panel div.q-header button.q-close {
flex: 0 1;
color: gray;
background-color: rgba(0, 0, 0, 0);
border: none;
border-radius: var(--border-radius);
outline: none;
}
div.q-panel div.q-list {
flex: 1 1;
background-color: rgba(0, 0, 0, 0.2);
padding: 0.3em;
font-size: 0.8em;
overflow-y: scroll;
}
div.q-panel div.q-list div.item {
background-color: rgba(255, 255, 255, 0.9);
font-family: "Roboto", Helvetica, sans-serif;
line-height: 125%;
border: none;
border-radius: var(--border-radius);
outline: none;
margin-bottom: 0.5em;
padding: 0.3em;
display: flex;
flex-flow: row nowrap;
align-items: center;
}
div.q-panel div.q-list div.item div.content {
flex: 1 1;
margin: 0;
padding: 0;
padding-right: 0.1em;
background-color: rgb(0, 0, 0, 0);
overflow: hidden;
}
div.q-panel div.content div.controls {
float: right;
margin-left: 0.5em;
}
div.q-panel button {
color: gray;
background-color: rgba(0, 0, 0, 0);
border: none;
margin: 0;
padding: 0;
margin-left: 0.2em;
font-size: 1em;
}
div.q-panel button:hover {
color: darkred;
}
div.q-panel button.cantvote {
color: lightgray;
}
div.q-panel button.cantvote:hover {
color: lightgray;
}
div.q-panel div.q-list div.item button {
flex: 0 1 content;
}
div.q-panel div.q-input {
flex: 0 1;
background-color: rgba(0, 0, 0, 0.2);
padding: 0.3em;
}
div.q-panel div.q-input textarea {
resize: none;
background-color: rgba(255, 255, 255, 0.9);
padding: 0.3em;
height: 6em;
width: calc(100% - 0.6em);
border: none;
border-radius: var(--border-radius);
outline: none;
font-size: 0.8em;
}
div.q-panel div.q-footer {
flex: 0 1 content;
display: flex;
flex-flow: row nowrap;
align-items: center;
background-color: rgba(0, 0, 0, 0.1);
padding: 0.3em;
}
div.q-panel div.q-footer div.credentials {
display: flex;
flex: 1 0;
}
div.q-panel div.q-footer div.credentials.visible {
visibility: visible;
}
div.q-panel div.q-footer div.credentials:not(.visible) {
visibility: hidden;
}
div.q-panel div.q-footer div.credentials input {