-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/Igorcbraz/Calculadora
- Loading branch information
Showing
5 changed files
with
132 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
export class Guide { | ||
#intro | ||
#config | ||
|
||
constructor() { | ||
this.#intro = introJs.tour() | ||
this.#config = { | ||
steps: [], | ||
dontShowAgain: true, | ||
dontShowAgainLabel: 'Não mostrar novamente', | ||
nextLabel: 'Próximo', | ||
prevLabel: 'Anterior', | ||
doneLabel: 'Finalizar', | ||
} | ||
} | ||
|
||
loadSteps() { | ||
this.#config.steps = [ | ||
{ | ||
title: 'Bem-vindo(a)!', | ||
intro: 'Este é um guia rápido para ajudar a configurar o aplicativo.', | ||
tooltipClass: 'custom-tooltip', | ||
highlightClass: 'custom-highlight' | ||
}, | ||
{ | ||
element: document.querySelector('#key-selector-container'), | ||
title: 'Temas favoritos', | ||
intro: 'É possível associar um tema a uma tecla do teclado. Clique em um dos temas abaixo e pressione uma tecla para associar.', | ||
position: 'right', | ||
tooltipClass: 'custom-tooltip', | ||
highlightClass: 'custom-highlight' | ||
}, | ||
{ | ||
element: document.querySelector('#reset-theme'), | ||
title: 'Voltar ao padrão', | ||
intro: 'Caso deseje voltar para configuração padrão, clique aqui.', | ||
tooltipClass: 'custom-tooltip', | ||
highlightClass: 'custom-highlight' | ||
}, | ||
{ | ||
element: document.querySelector('#btnTheme'), | ||
title: 'Escolher tema', | ||
intro: 'Altere o tema do aplicativo com um clique.', | ||
tooltipClass: 'custom-tooltip', | ||
highlightClass: 'custom-highlight' | ||
} | ||
] | ||
} | ||
|
||
loadConfig () { | ||
this.#intro.setOptions(this.#config) | ||
} | ||
|
||
start () { | ||
this.#intro.start() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters