From ce0a020739dd4f7703fab8c157398b929a89e271 Mon Sep 17 00:00:00 2001 From: Eddie Dover Date: Thu, 13 Jun 2024 07:01:35 -0700 Subject: [PATCH 1/2] feat: added new discord link --- src/lang/en.json | 3 ++- src/lang/es.json | 3 ++- src/module/app/party-sheet.js | 9 +++++++++ src/templates/party-sheet.hbs | 3 +++ 4 files changed, 16 insertions(+), 2 deletions(-) diff --git a/src/lang/en.json b/src/lang/en.json index a24447e..e1383e5 100644 --- a/src/lang/en.json +++ b/src/lang/en.json @@ -9,7 +9,8 @@ "no-players": "No players are currently logged in.", "no-systems": "You do not have any json files for this system in your data/partysheets folder. Please add some to enable this feature.", "bugreport": "File a Bug Report", - "feedback": "Send Feedback" + "feedback": "Send Feedback", + "discord": "Discord" }, "hide-sheet": { "button": "Configure Hidden Characters", diff --git a/src/lang/es.json b/src/lang/es.json index 6b24f16..c0a3ad0 100644 --- a/src/lang/es.json +++ b/src/lang/es.json @@ -9,7 +9,8 @@ "no-players": "Ningún jugador ha iniciado sesión actualmente.", "no-systems": "La carpeta data/partysheets no contiene archivos JSON para este sistema. Necesitas agregar algunos para activar esta funcionalidad.", "bugreport": "Dar retroalimentación", - "feedback": "Reportar un fallo" + "feedback": "Reportar un fallo", + "discord": "Discord" }, "hide-sheet": { "button": "Configurar personajes ocultos", diff --git a/src/module/app/party-sheet.js b/src/module/app/party-sheet.js index 1f9d8b5..394d404 100644 --- a/src/module/app/party-sheet.js +++ b/src/module/app/party-sheet.js @@ -14,6 +14,7 @@ import { HiddenCharactersSettings } from "./hidden-characters-settings.js"; const FEEDBACK_URL = "https://github.com/EddieDover/fvtt-party-sheet/issues/new/choose"; const BUGREPORT_URL = "https://github.com/EddieDover/fvtt-party-sheet/issues/new?assignees=EddieDover&labels=bug&projects=&template=bug_report.yml&title=%5BBug%5D%3A+"; +const DISCORD_URL = "https://discord.gg/mvMdc7bH2d"; const DEFAULT_EXCLUDES = ["npc"]; @@ -739,6 +740,8 @@ export class PartySheetForm extends FormApplication { // @ts-ignore $('button[name="bugreport"]', html).click(this.onBugReport.bind(this)); // @ts-ignore + $('button[name="discord"]', html).click(this.onDiscord.bind(this)); + // @ts-ignore $('select[class="fvtt-party-sheet-dropdown"]', html).change((event) => { const dropdownSection = event.currentTarget.dataset.dropdownsection; const dropdownValue = event.currentTarget.value; @@ -762,4 +765,10 @@ export class PartySheetForm extends FormApplication { const newWindow = window.open(BUGREPORT_URL, "_blank", "noopener,noreferrer"); if (newWindow) newWindow.opener = undefined; } + + onDiscord(event) { + event.preventDefault(); + const newWindow = window.open(DISCORD_URL, "_blank", "noopener,noreferrer"); + if (newWindow) newWindow.opener = undefined; + } } diff --git a/src/templates/party-sheet.hbs b/src/templates/party-sheet.hbs index 02fce15..c96e745 100644 --- a/src/templates/party-sheet.hbs +++ b/src/templates/party-sheet.hbs @@ -11,6 +11,9 @@ + {{/unless}} {{#if applicableSystems.length}} From 24911d56f796b58d40e331ac5fc399a630243eee Mon Sep 17 00:00:00 2001 From: Eddie Dover Date: Thu, 13 Jun 2024 07:10:08 -0700 Subject: [PATCH 2/2] v2.5.1 prep --- CHANGELOG.md | 7 +++++++ package.json | 2 +- src/module.json | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3bb69e6..c98e38a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,11 @@ +## [2.5.1](https://github.com/EddieDover/fvtt-party-sheet/compare/v2.5.0...v2.5.1) (2024-06-13) + + +### Features + +* added new discord link ([ce0a020](https://github.com/EddieDover/fvtt-party-sheet/commit/ce0a020739dd4f7703fab8c157398b929a89e271)) + ## [2.5.0](https://github.com/EddieDover/fvtt-party-sheet/compare/v2.4.1...v2.5.0) (2024-06-09) diff --git a/package.json b/package.json index 8f409ba..87ea693 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fvtt-party-sheet", - "version": "2.5.0", + "version": "2.5.1", "description": "A FoundryVTT module that adds a customizable Party Sheet window.", "main": "index.js", "author": { diff --git a/src/module.json b/src/module.json index 0c39986..b2e1a21 100644 --- a/src/module.json +++ b/src/module.json @@ -37,7 +37,7 @@ "url": "https://github.com/eddiedover/" } ], - "version": "2.5.0", + "version": "2.5.1", "compatibility": { "minimum": "11", "verified": "12"