Merge pull request #200 from bra1n/develop

v2.15.2
This commit is contained in:
Steffen 2021-07-14 14:02:29 +02:00 committed by GitHub
commit 2824972d0a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 877 additions and 778 deletions

View File

@ -1,7 +1,15 @@
# Release Notes # Release Notes
### Version 2.15.2
- added mobile web application support
- show correct number of leaves on roles with global reminders
- fixed a bug with traveler list showing up when assigning demon bluffs
- fixed a bug with homebrew scripts that contained negative night order positions
---
### Version 2.15.1 ### Version 2.15.1
- fix Mephit not showing up on scripts - fix Mephit not showing up on scripts, futureproof Mephit name change
- add Boomdandy to list of available characters - add Boomdandy to list of available characters
--- ---

View File

@ -90,7 +90,8 @@ For base game characters, it is sufficient to only provide the ID, similar to wh
_Note_: custom images will only be visible after enabling them in the Grimoire menu! _Note_: custom images will only be visible after enabling them in the Grimoire menu!
- **edition**: the ID of the edition for this character. can be left blank or "custom" - **edition**: the ID of the edition for this character. can be left blank or "custom"
- **firstNight** / **otherNight**: the position that this character acts on the first / other nights, compared to all - **firstNight** / **otherNight**: the position that this character acts on the first / other nights, compared to all
other characters other characters<br>
_Note_: must be a positive number or zero, with zero being treated as "does not act during the night"
- **firstNightReminder** / **otherNightReminder**: reminder text for first / other nights - **firstNightReminder** / **otherNightReminder**: reminder text for first / other nights
- **reminders**: reminder tokens, should be an empty array `[]` if none - **reminders**: reminder tokens, should be an empty array `[]` if none
- **remindersGlobal**: global reminder tokens that will always be available, no matter if the character is assigned to a player or not - **remindersGlobal**: global reminder tokens that will always be available, no matter if the character is assigned to a player or not

1620
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
{ {
"name": "townsquare", "name": "townsquare",
"version": "2.15.1", "version": "2.15.2",
"description": "Blood on the Clocktower Town Square", "description": "Blood on the Clocktower Town Square",
"author": "Steffen Baumgart", "author": "Steffen Baumgart",
"scripts": { "scripts": {

View File

@ -5,6 +5,8 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0"> <meta name="viewport" content="width=device-width,initial-scale=1.0">
<meta name="mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-capable" content="yes">
<title>Blood on the Clocktower Town Square</title> <title>Blood on the Clocktower Town Square</title>
<link rel="apple-touch-icon" sizes="57x57" href="static/apple-icon-57x57.png"> <link rel="apple-touch-icon" sizes="57x57" href="static/apple-icon-57x57.png">
<link rel="apple-touch-icon" sizes="60x60" href="static/apple-icon-60x60.png"> <link rel="apple-touch-icon" sizes="60x60" href="static/apple-icon-60x60.png">

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

View File

@ -19,10 +19,7 @@
class="leaf-right" class="leaf-right"
v-if="role.otherNight || role.otherNightReminder" v-if="role.otherNight || role.otherNightReminder"
></span> ></span>
<span <span v-if="reminderLeaves" :class="['leaf-top' + reminderLeaves]"></span>
v-if="role.reminders && role.reminders.length"
:class="['leaf-top' + role.reminders.length]"
></span>
<span class="leaf-orange" v-if="role.setup"></span> <span class="leaf-orange" v-if="role.setup"></span>
<svg viewBox="0 0 150 150" class="name"> <svg viewBox="0 0 150 150" class="name">
<path <path
@ -61,6 +58,12 @@ export default {
} }
}, },
computed: { computed: {
reminderLeaves: function() {
return (
(this.role.reminders || []).length +
(this.role.remindersGlobal || []).length
);
},
...mapState(["grimoire"]) ...mapState(["grimoire"])
}, },
data() { data() {

View File

@ -100,6 +100,7 @@ export default {
value: role value: role
}); });
} }
this.tab = "editionRoles";
this.$store.commit("toggleModal", "role"); this.$store.commit("toggleModal", "role");
}, },
close() { close() {

View File

@ -214,7 +214,7 @@ export default new Vuex.Store({
state.roles.get(role.id) || state.roles.get(role.id) ||
Object.assign({}, customRole, role) Object.assign({}, customRole, role)
) )
// default empty icons and placeholders // default empty icons and placeholders, clean up firstNight / otherNight
.map(role => { .map(role => {
if (rolesJSONbyId.get(role.id)) return role; if (rolesJSONbyId.get(role.id)) return role;
role.imageAlt = // map team to generic icon role.imageAlt = // map team to generic icon
@ -225,6 +225,8 @@ export default new Vuex.Store({
demon: "evil", demon: "evil",
fabled: "fabled" fabled: "fabled"
}[role.team] || "custom"; }[role.team] || "custom";
role.firstNight = Math.abs(role.firstNight);
role.otherNight = Math.abs(role.otherNight);
return role; return role;
}) })
// filter out roles that don't match an existing role and also don't have name/ability/team // filter out roles that don't match an existing role and also don't have name/ability/team