Skip to content

languages in journal headings #405

Closed Answered by Benjaneer
Benjaneer asked this question in Q&A
Discussion options

You must be logged in to vote

ok, got half of it :D, I think I can manage from here

  1. edit ~/foundryvtt/resources/app/templates/sidebar/journal-directory.html (add a third curly brace to line 25)

{{{this.name}}}

  1. add another hook to polyglot module logic.js
    Hooks.on("changeSidebarTab", this.uglyEverything.bind(this));

  2. add a function for that event to map to:

uglyEverything(object) {
	if (game.user.isGM) return;
	else {
		const spans = document.querySelectorAll("span.polyglot-journal");
		spans.forEach((e) => {
			const lang = e.dataset.language;
			if (!lang) return;
			let conditions = !this._isTruespeech(lang)
				&& !this.known_languages.has(this.comprehendLanguages)
				&& !currentLanguageProvider.conditions(l…

Replies: 4 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@Benjaneer
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by Benjaneer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant