Skip to content

Commit

Permalink
Merge pull request #20 from snowom/develop
Browse files Browse the repository at this point in the history
Hotfix Release 1.4.3
  • Loading branch information
snowom authored Feb 22, 2024
2 parents 94d23b0 + c9c9376 commit 8eace60
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/main/resources/templates/pagResolucaoLivro.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,16 @@
"authorization": token
}
}).then((resp) => {
console.log(resp);

if(!resp.data.hasOwnProperty("lightSolution")){
throw new Error("Falha ao obter objeto \"lightSolution\"")
}
if(!resp.data.hasOwnProperty("lightAnswer")){
throw new Error("Falha ao obter objeto \"lightAnswer\"")
}
if(!resp.data.hasOwnProperty("lightBody")){
throw new Error("Falha ao obter objeto \"lightBody\"")
}

const STYLE_H2 = 'color: rgb(54, 170, 173); font-size: 1.5em; font-family: "Droid Serif", serif; margin: 0; font-weight: inherit; outline: none; box-sizing: border-box; font-size: 1.2em;';
const STYLE_DIV_RESPOSTA = 'border-left: 4px solid rgb(54, 170, 173); padding: 20px; font-size: 1.2em;';
Expand All @@ -64,6 +66,11 @@
let htmlResponse = "<div style='flex: 1 1 0%; align-self: center; background-color: white; width: 100%'>";
htmlResponse += "<div style='padding: 0px 30px;'>";

htmlResponse += `<div style="${STYLE_FONT_STEPS} margin: 60px 0px;">`;
htmlResponse += `<h2 style="${STYLE_H2}">Enunciado</h2>`;
htmlResponse += `<div style='margin: 30px 0px; 60px;'>${resp.data.lightBody}</div>`
htmlResponse += `</div>`;

resp.data.lightSolution.forEach((step, index) => {
let currentStep = index += 1;
htmlResponse += `<div style="${STYLE_FONT_STEPS} margin: 60px 0px;">`;
Expand Down

0 comments on commit 8eace60

Please sign in to comment.