From 917bcd7056ce6ef70d22b5eee87b5a3ad6ee5806 Mon Sep 17 00:00:00 2001 From: IrkTheImp <41175833+IrkTheImp@users.noreply.github.com> Date: Thu, 29 May 2025 04:54:04 -0500 Subject: [PATCH 1/2] Update Community features. Remove bad abilty from Troubadour (#74) --- .../community_Highborne_8AcV556QwoIzkkea.json | 6 +++--- .../community_Loreborne_fgJHuCdoyXX4Q84O.json | 6 +++--- ...community_Orderborne_Cg39GoSa6lxhXndW.json | 6 +++--- ...community_Ridgeborne_DAQoNvVlc9w7NmZd.json | 6 +++--- .../community_Seaborne_ivrXToGxyuVdqZtG.json | 6 +++--- .../community_Slyborne_rwsUCLenOkE9CS7v.json | 6 +++--- ...community_Underborne_CXQN2zcQUIjUOx1i.json | 6 +++--- ...ommunity_Wanderborne_DHB5uSzbBeJCJuvC.json | 6 +++--- .../community_Wildborne_jUzXIVyBx0mlIFWa.json | 6 +++--- .../subclass_Troubadour_T1iBO8i0xRF5c8Q2.json | 21 +------------------ 10 files changed, 28 insertions(+), 47 deletions(-) diff --git a/src/packs/communities/community_Highborne_8AcV556QwoIzkkea.json b/src/packs/communities/community_Highborne_8AcV556QwoIzkkea.json index f37d81f5..cb8e9895 100644 --- a/src/packs/communities/community_Highborne_8AcV556QwoIzkkea.json +++ b/src/packs/communities/community_Highborne_8AcV556QwoIzkkea.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Privilege", - "uuid": "Compendium.world.community-features.Item.WoMZCTnDcK8GPSh1" + "uuid": "Compendium.daggerheart.community-features.Item.AgJiUvad5tgeam57" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940320728, - "modifiedTime": 1747990568291, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487208088, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!8AcV556QwoIzkkea" } diff --git a/src/packs/communities/community_Loreborne_fgJHuCdoyXX4Q84O.json b/src/packs/communities/community_Loreborne_fgJHuCdoyXX4Q84O.json index b6132b3f..998f186d 100644 --- a/src/packs/communities/community_Loreborne_fgJHuCdoyXX4Q84O.json +++ b/src/packs/communities/community_Loreborne_fgJHuCdoyXX4Q84O.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Well-Read", - "uuid": "Compendium.world.community-features.Item.MUfVlf8hoJ3HZidv" + "uuid": "Compendium.daggerheart.community-features.Item.n2RA9iZNiVbGlxco" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940300210, - "modifiedTime": 1747990671092, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487185921, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!fgJHuCdoyXX4Q84O" } diff --git a/src/packs/communities/community_Orderborne_Cg39GoSa6lxhXndW.json b/src/packs/communities/community_Orderborne_Cg39GoSa6lxhXndW.json index 01936248..ed94308e 100644 --- a/src/packs/communities/community_Orderborne_Cg39GoSa6lxhXndW.json +++ b/src/packs/communities/community_Orderborne_Cg39GoSa6lxhXndW.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Dedicated", - "uuid": "Compendium.world.community-features.Item.b7LmL7ti1gL5kfGq" + "uuid": "Compendium.daggerheart.community-features.Item.ZiBpJxtDSsh6wY3h" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940332147, - "modifiedTime": 1747990820386, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487117035, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!Cg39GoSa6lxhXndW" } diff --git a/src/packs/communities/community_Ridgeborne_DAQoNvVlc9w7NmZd.json b/src/packs/communities/community_Ridgeborne_DAQoNvVlc9w7NmZd.json index 39ef2693..4dfd104a 100644 --- a/src/packs/communities/community_Ridgeborne_DAQoNvVlc9w7NmZd.json +++ b/src/packs/communities/community_Ridgeborne_DAQoNvVlc9w7NmZd.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Steady", - "uuid": "Compendium.world.community-features.Item.hKGv54dst9crq3Sw" + "uuid": "Compendium.daggerheart.community-features.Item.Oky51ziMZp6bbuUQ" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940346633, - "modifiedTime": 1747990891669, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487238072, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!DAQoNvVlc9w7NmZd" } diff --git a/src/packs/communities/community_Seaborne_ivrXToGxyuVdqZtG.json b/src/packs/communities/community_Seaborne_ivrXToGxyuVdqZtG.json index a2c10f39..f7a25d5f 100644 --- a/src/packs/communities/community_Seaborne_ivrXToGxyuVdqZtG.json +++ b/src/packs/communities/community_Seaborne_ivrXToGxyuVdqZtG.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Know the Tide", - "uuid": "Compendium.world.community-features.Item.coBcBEFpXgtxD1Jt" + "uuid": "Compendium.daggerheart.community-features.Item.0mdoYz7uZNWCcK5Z" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940375520, - "modifiedTime": 1747990980804, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487248881, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!ivrXToGxyuVdqZtG" } diff --git a/src/packs/communities/community_Slyborne_rwsUCLenOkE9CS7v.json b/src/packs/communities/community_Slyborne_rwsUCLenOkE9CS7v.json index ae65ceed..fe4fbec7 100644 --- a/src/packs/communities/community_Slyborne_rwsUCLenOkE9CS7v.json +++ b/src/packs/communities/community_Slyborne_rwsUCLenOkE9CS7v.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Scoundrel", - "uuid": "Compendium.world.community-features.Item.p2PipVUiMt0Cy0ws" + "uuid": "Compendium.daggerheart.community-features.Item.5BUCiSPswsiB0RDW" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940388725, - "modifiedTime": 1747991089836, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487260950, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!rwsUCLenOkE9CS7v" } diff --git a/src/packs/communities/community_Underborne_CXQN2zcQUIjUOx1i.json b/src/packs/communities/community_Underborne_CXQN2zcQUIjUOx1i.json index ab2f3b19..bad3379a 100644 --- a/src/packs/communities/community_Underborne_CXQN2zcQUIjUOx1i.json +++ b/src/packs/communities/community_Underborne_CXQN2zcQUIjUOx1i.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Low-Light Living", - "uuid": "Compendium.world.community-features.Item.p12Le1M3DPWXa0vh" + "uuid": "Compendium.daggerheart.community-features.Item.hX85YvTQcMzc25hW" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940403160, - "modifiedTime": 1747991158174, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487269990, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!CXQN2zcQUIjUOx1i" } diff --git a/src/packs/communities/community_Wanderborne_DHB5uSzbBeJCJuvC.json b/src/packs/communities/community_Wanderborne_DHB5uSzbBeJCJuvC.json index 0e73f066..3a3f94f9 100644 --- a/src/packs/communities/community_Wanderborne_DHB5uSzbBeJCJuvC.json +++ b/src/packs/communities/community_Wanderborne_DHB5uSzbBeJCJuvC.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Nomadic Pack", - "uuid": "Compendium.world.community-features.Item.NeuBdFDpV0HTzOIM" + "uuid": "Compendium.daggerheart.community-features.Item.o3Q88Rws9Eb5ae5D" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940414913, - "modifiedTime": 1747991238462, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487280155, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!DHB5uSzbBeJCJuvC" } diff --git a/src/packs/communities/community_Wildborne_jUzXIVyBx0mlIFWa.json b/src/packs/communities/community_Wildborne_jUzXIVyBx0mlIFWa.json index a481b5a4..c6cda21b 100644 --- a/src/packs/communities/community_Wildborne_jUzXIVyBx0mlIFWa.json +++ b/src/packs/communities/community_Wildborne_jUzXIVyBx0mlIFWa.json @@ -9,7 +9,7 @@ { "img": "icons/svg/item-bag.svg", "name": "Lightfoot", - "uuid": "Compendium.world.community-features.Item.4VaugxNAouI7SKKz" + "uuid": "Compendium.daggerheart.community-features.Item.LY9c4DCgMcB1uEiv" } ] }, @@ -29,8 +29,8 @@ "systemId": "daggerheart", "systemVersion": "0.0.1", "createdTime": 1747940432585, - "modifiedTime": 1747991300734, - "lastModifiedBy": "NqO2eQGMjrvUO6v9" + "modifiedTime": 1748487285826, + "lastModifiedBy": "c3xaFsDtL56heKoi" }, "_key": "!items!jUzXIVyBx0mlIFWa" } diff --git a/src/packs/subclasses/subclass_Troubadour_T1iBO8i0xRF5c8Q2.json b/src/packs/subclasses/subclass_Troubadour_T1iBO8i0xRF5c8Q2.json index e32a615f..7fe389b1 100644 --- a/src/packs/subclasses/subclass_Troubadour_T1iBO8i0xRF5c8Q2.json +++ b/src/packs/subclasses/subclass_Troubadour_T1iBO8i0xRF5c8Q2.json @@ -8,26 +8,7 @@ "spellcastingTrait": "presence", "foundationFeature": { "description": "
Gifted Performer: Describe how you perform for others. You can play each song once per long rest:
• Relaxing Song: You and all allies within Close range clear a Hit Point.
• Epic Song: Make a target within Close range temporarily Vulnerable.
• Heartbreaking Song: You and all allies within Close range gain a Hope.
", - "abilities": [ - { - "actionType": "passive", - "featureType": { - "type": "normal", - "data": { - "property": "spellcastingTrait", - "max": 1, - "numbers": {} - } - }, - "refreshData": null, - "multiclass": null, - "disabled": false, - "description": "You are among the greatest of your craft and your skill is boundless. You can perform each of your “Gifted Performer” feature’s songs twice instead of once per long rest.
", - "effects": {}, - "actions": [], - "type": "subclass" - } - ] + "abilities": [] }, "specializationFeature": { "unlocked": false, From c34c923406f7d88411e2f0cc4eb083235cfaf2c2 Mon Sep 17 00:00:00 2001 From: Murilo Brito <91566541+moliloo@users.noreply.github.com> Date: Thu, 29 May 2025 07:07:09 -0300 Subject: [PATCH 2/2] enhance card items (#75) --- daggerheart.mjs | 3 +- lang/en.json | 11 +- module/applications/_module.mjs | 6 +- module/applications/sheets/ancestry.mjs | 122 ----------- module/applications/sheets/community.mjs | 122 ----------- module/applications/sheets/items/ancestry.mjs | 88 ++++++++ module/applications/sheets/items/armor.mjs | 2 +- .../applications/sheets/items/community.mjs | 88 ++++++++ .../applications/sheets/items/consumable.mjs | 2 +- .../sheets/{ => items}/domainCard.mjs | 93 ++++---- module/applications/sheets/items/feature.mjs | 4 +- .../sheets/items/miscellaneous.mjs | 24 +-- module/applications/sheets/items/weapon.mjs | 2 +- module/config/domainConfig.mjs | 6 +- styles/daggerheart.css | 203 +++++++++++++++--- styles/daggerheart.less | 4 + styles/less/global/feature-section.less | 51 +++++ styles/less/global/item-header.less | 99 +++++++++ styles/less/global/sheet.less | 1 - styles/less/global/tab-actions.less | 46 ++++ styles/less/items/domainCard.less | 12 ++ styles/less/items/feature.less | 42 ---- templates/sheets/ancestry.hbs | 11 - templates/sheets/community.hbs | 11 - templates/sheets/domainCard.hbs | 101 --------- .../global/partials/feature-section-item.hbs | 28 +++ .../tabs/tab-actions.hbs} | 0 .../sheets/global/tabs/tab-description.hbs | 1 + .../global/tabs/tab-feature-section.hbs | 14 ++ templates/sheets/items/ancestry/header.hbs | 9 + templates/sheets/items/community/header.hbs | 9 + templates/sheets/items/domainCard/header.hbs | 26 +++ .../sheets/items/domainCard/settings.hbs | 20 ++ 33 files changed, 727 insertions(+), 534 deletions(-) delete mode 100644 module/applications/sheets/ancestry.mjs delete mode 100644 module/applications/sheets/community.mjs create mode 100644 module/applications/sheets/items/ancestry.mjs create mode 100644 module/applications/sheets/items/community.mjs rename module/applications/sheets/{ => items}/domainCard.mjs (51%) create mode 100644 styles/less/global/feature-section.less create mode 100644 styles/less/global/tab-actions.less create mode 100644 styles/less/items/domainCard.less delete mode 100644 templates/sheets/ancestry.hbs delete mode 100644 templates/sheets/community.hbs delete mode 100644 templates/sheets/domainCard.hbs create mode 100644 templates/sheets/global/partials/feature-section-item.hbs rename templates/sheets/{items/feature/actions.hbs => global/tabs/tab-actions.hbs} (100%) mode change 100755 => 100644 create mode 100644 templates/sheets/global/tabs/tab-feature-section.hbs create mode 100644 templates/sheets/items/ancestry/header.hbs create mode 100644 templates/sheets/items/community/header.hbs create mode 100644 templates/sheets/items/domainCard/header.hbs create mode 100644 templates/sheets/items/domainCard/settings.hbs diff --git a/daggerheart.mjs b/daggerheart.mjs index 65084450..a431f058 100644 --- a/daggerheart.mjs +++ b/daggerheart.mjs @@ -284,6 +284,7 @@ const preloadHandlebarsTemplates = async function () { 'systems/daggerheart/templates/sheets/pc/parts/heritageCard.hbs', 'systems/daggerheart/templates/sheets/pc/parts/advancementCard.hbs', 'systems/daggerheart/templates/views/parts/level.hbs', - 'systems/daggerheart/templates/components/slider.hbs' + 'systems/daggerheart/templates/components/slider.hbs', + 'systems/daggerheart/templates/sheets/global/partials/feature-section-item.hbs' ]); }; diff --git a/lang/en.json b/lang/en.json index 85c98ba6..684fa06f 100755 --- a/lang/en.json +++ b/lang/en.json @@ -316,9 +316,9 @@ }, "Domain": { "CardTypes": { - "Ability": "Ability", - "Spell": "Spell", - "Grimoire": "Grimoire" + "ability": "Ability", + "spell": "Spell", + "grimoire": "Grimoire" } }, "LevelUp": { @@ -1105,6 +1105,11 @@ "Name": "Damage Roll" } } + }, + + "Tooltip": { + "openItemWorld": "Open Item World", + "delete": "Delete" } } } diff --git a/module/applications/_module.mjs b/module/applications/_module.mjs index cc1bc90e..21af5efb 100644 --- a/module/applications/_module.mjs +++ b/module/applications/_module.mjs @@ -3,9 +3,9 @@ export { default as DhpAdversarySheet } from './sheets/adversary.mjs'; export { default as DhpClassSheet } from './sheets/class.mjs'; export { default as DhpSubclass } from './sheets/subclass.mjs'; export { default as DhpFeatureSheet } from './sheets/items/feature.mjs'; -export { default as DhpDomainCardSheet } from './sheets/domainCard.mjs'; -export { default as DhpAncestry } from './sheets/ancestry.mjs'; -export { default as DhpCommunity } from './sheets/community.mjs'; +export { default as DhpDomainCardSheet } from './sheets/items/domainCard.mjs'; +export { default as DhpAncestry } from './sheets/items/ancestry.mjs'; +export { default as DhpCommunity } from './sheets/items/community.mjs'; export { default as DhpMiscellaneous } from './sheets/items/miscellaneous.mjs'; export { default as DhpConsumable } from './sheets/items/consumable.mjs'; export { default as DhpWeapon } from './sheets/items/weapon.mjs'; diff --git a/module/applications/sheets/ancestry.mjs b/module/applications/sheets/ancestry.mjs deleted file mode 100644 index 51962c9c..00000000 --- a/module/applications/sheets/ancestry.mjs +++ /dev/null @@ -1,122 +0,0 @@ -// import DhpApplicationMixin from '../daggerheart-sheet.mjs'; - -// export default class AncestrySheet extends DhpApplicationMixin(ItemSheet) { -// static documentType = "ancestry"; - -// constructor(options){ -// super(options); -// } - -// /** @override */ -// static get defaultOptions() { -// return foundry.utils.mergeObject(super.defaultOptions, { -// classes: ["daggerheart", "sheet", "heritage"], -// width: 600, -// height: 'auto', -// dragDrop: [{ dragSelector: null, dropSelector: null }], -// }); -// } - -// /** @override */ -// getData() { -// const context = super.getData(); - -// return context; -// } - -// async _handleAction(action, event, button) { -// switch(action){ -// case 'editAbility': -// this.editAbility(button); -// break; -// case 'deleteAbility': -// this.deleteAbility(event); -// break; -// } -// } - -// async editAbility(button){ -// const feature = await fromUuid(button.dataset.ability); -// feature.sheet.render(true); -// } - -// async deleteAbility(event){ -// event.preventDefault(); -// event.stopPropagation(); -// await this.item.update({ "system.abilities": this.item.system.abilities.filter(x => x.uuid !== event.currentTarget.dataset.ability) }) -// } - -// async _onDrop(event) { -// const data = TextEditor.getDragEventData(event); -// const item = await fromUuid(data.uuid); -// if(item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.ancestry.id) { -// await this.object.update({ "system.abilities": [...this.item.system.abilities, { img: item.img, name: item.name, uuid: item.uuid }] }); -// } -// } -// } - -import DaggerheartSheet from './daggerheart-sheet.mjs'; - -const { ItemSheetV2 } = foundry.applications.sheets; -export default class AncestrySheet extends DaggerheartSheet(ItemSheetV2) { - static DEFAULT_OPTIONS = { - tag: 'form', - classes: ['daggerheart', 'sheet', 'heritage'], - position: { width: 600 }, - actions: { - editAbility: this.editAbility, - deleteAbility: this.deleteAbility - }, - form: { - handler: this.updateForm, - submitOnChange: true, - closeOnSubmit: false - }, - dragDrop: [{ dragSelector: null, dropSelector: null }] - }; - - static PARTS = { - form: { - id: 'feature', - template: 'systems/daggerheart/templates/sheets/ancestry.hbs' - } - }; - - async _prepareContext(_options) { - const context = await super._prepareContext(_options); - context.document = this.document; - - return context; - } - - static async updateForm(event, _, formData) { - await this.document.update(formData.object); - this.render(); - } - - static async editAbility(_, button) { - const feature = await fromUuid(button.dataset.ability); - feature.sheet.render(true); - } - - static async deleteAbility(event, button) { - event.preventDefault(); - event.stopPropagation(); - await this.item.update({ - 'system.abilities': this.item.system.abilities.filter(x => x.uuid !== button.dataset.ability) - }); - } - - async _onDrop(event) { - const data = TextEditor.getDragEventData(event); - const item = await fromUuid(data.uuid); - if (item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.ancestry.id) { - await this.document.update({ - 'system.abilities': [ - ...this.document.system.abilities, - { img: item.img, name: item.name, uuid: item.uuid } - ] - }); - } - } -} diff --git a/module/applications/sheets/community.mjs b/module/applications/sheets/community.mjs deleted file mode 100644 index f2bdf1ff..00000000 --- a/module/applications/sheets/community.mjs +++ /dev/null @@ -1,122 +0,0 @@ -// import DhpApplicationMixin from '../daggerheart-sheet.mjs'; - -// export default class CommunitySheet extends DhpApplicationMixin(ItemSheet) { -// static documentType = "community"; - -// constructor(options){ -// super(options); -// } - -// /** @override */ -// static get defaultOptions() { -// return foundry.utils.mergeObject(super.defaultOptions, { -// classes: ["daggerheart", "sheet", "heritage"], -// width: 600, -// height: 'auto', -// dragDrop: [{ dragSelector: null, dropSelector: null }], -// }); -// } - -// /** @override */ -// getData() { -// const context = super.getData(); - -// return context; -// } - -// async _handleAction(action, event, button) { -// switch(action){ -// case 'editAbility': -// this.editAbility(button); -// break; -// case 'deleteAbility': -// this.deleteAbility(event); -// break; -// } -// } - -// async editAbility(button){ -// const feature = await fromUuid(button.dataset.ability); -// feature.sheet.render(true); -// } - -// async deleteAbility(event){ -// event.preventDefault(); -// event.stopPropagation(); -// await this.item.update({ "system.abilities": this.item.system.abilities.filter(x => x.uuid !== event.currentTarget.dataset.ability) }) -// } - -// async _onDrop(event) { -// const data = TextEditor.getDragEventData(event); -// const item = await fromUuid(data.uuid); -// if(item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.community.id) { -// await this.object.update({ "system.abilities": [...this.item.system.abilities, { img: item.img, name: item.name, uuid: item.uuid }] }); -// } -// } -// } - -import DaggerheartSheet from './daggerheart-sheet.mjs'; - -const { ItemSheetV2 } = foundry.applications.sheets; -export default class CommunitySheet extends DaggerheartSheet(ItemSheetV2) { - static DEFAULT_OPTIONS = { - tag: 'form', - classes: ['daggerheart', 'sheet', 'heritage'], - position: { width: 600 }, - actions: { - editAbility: this.editAbility, - deleteAbility: this.deleteAbility - }, - form: { - handler: this.updateForm, - submitOnChange: true, - closeOnSubmit: false - }, - dragDrop: [{ dragSelector: null, dropSelector: null }] - }; - - static PARTS = { - form: { - id: 'feature', - template: 'systems/daggerheart/templates/sheets/community.hbs' - } - }; - - async _prepareContext(_options) { - const context = await super._prepareContext(_options); - context.document = this.document; - - return context; - } - - static async updateForm(event, _, formData) { - await this.document.update(formData.object); - this.render(); - } - - static async editAbility(_, button) { - const feature = await fromUuid(button.dataset.ability); - feature.sheet.render(true); - } - - static async deleteAbility(event, button) { - event.preventDefault(); - event.stopPropagation(); - await this.item.update({ - 'system.abilities': this.item.system.abilities.filter(x => x.uuid !== button.dataset.ability) - }); - } - - async _onDrop(event) { - const data = TextEditor.getDragEventData(event); - const item = await fromUuid(data.uuid); - if (item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.community.id) { - await this.document.update({ - 'system.abilities': [ - ...this.document.system.abilities, - { img: item.img, name: item.name, uuid: item.uuid } - ] - }); - } - } -} diff --git a/module/applications/sheets/items/ancestry.mjs b/module/applications/sheets/items/ancestry.mjs new file mode 100644 index 00000000..e6a92e1e --- /dev/null +++ b/module/applications/sheets/items/ancestry.mjs @@ -0,0 +1,88 @@ +import DaggerheartSheet from '../daggerheart-sheet.mjs'; + +const { ItemSheetV2 } = foundry.applications.sheets; +export default class AncestrySheet extends DaggerheartSheet(ItemSheetV2) { + static DEFAULT_OPTIONS = { + tag: 'form', + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'ancestry'], + position: { width: 450, height: 700 }, + actions: { + editFeature: this.editFeature, + deleteFeature: this.deleteFeature + }, + form: { + handler: this.updateForm, + submitOnChange: true, + closeOnSubmit: false + }, + dragDrop: [{ dragSelector: null, dropSelector: null }] + }; + + static PARTS = { + header: { template: 'systems/daggerheart/templates/sheets/items/ancestry/header.hbs' }, + tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' }, + description: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-description.hbs' }, + features: { + template: 'systems/daggerheart/templates/sheets/global/tabs/tab-feature-section.hbs', + scrollable: ['.features'] + } + }; + + static TABS = { + description: { + active: true, + cssClass: '', + group: 'primary', + id: 'description', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Description' + }, + features: { + active: false, + cssClass: '', + group: 'primary', + id: 'features', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Features' + } + }; + + async _prepareContext(_options) { + const context = await super._prepareContext(_options); + context.document = this.document; + context.tabs = super._getTabs(this.constructor.TABS); + + return context; + } + + static async updateForm(event, _, formData) { + await this.document.update(formData.object); + this.render(); + } + + static async editFeature(_, target) { + const feature = await fromUuid(target.dataset.feature); + feature.sheet.render(true); + } + + static async deleteFeature(event, target) { + event.preventDefault(); + event.stopPropagation(); + await this.item.update({ + 'system.abilities': this.item.system.abilities.filter(x => x.uuid !== target.dataset.feature) + }); + } + + async _onDrop(event) { + const data = TextEditor.getDragEventData(event); + const item = await fromUuid(data.uuid); + if (item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.ancestry.id) { + await this.document.update({ + 'system.abilities': [ + ...this.document.system.abilities, + { img: item.img, name: item.name, uuid: item.uuid } + ] + }); + } + } +} diff --git a/module/applications/sheets/items/armor.mjs b/module/applications/sheets/items/armor.mjs index 25b2ddb5..b9759917 100644 --- a/module/applications/sheets/items/armor.mjs +++ b/module/applications/sheets/items/armor.mjs @@ -4,7 +4,7 @@ const { ItemSheetV2 } = foundry.applications.sheets; export default class ArmorSheet extends DaggerheartSheet(ItemSheetV2) { static DEFAULT_OPTIONS = { tag: 'form', - classes: ['daggerheart', 'sheet', 'dh-style', 'armor'], + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'armor'], position: { width: 600 }, form: { handler: this.updateForm, diff --git a/module/applications/sheets/items/community.mjs b/module/applications/sheets/items/community.mjs new file mode 100644 index 00000000..0c15e97e --- /dev/null +++ b/module/applications/sheets/items/community.mjs @@ -0,0 +1,88 @@ +import DaggerheartSheet from '../daggerheart-sheet.mjs'; + +const { ItemSheetV2 } = foundry.applications.sheets; +export default class CommunitySheet extends DaggerheartSheet(ItemSheetV2) { + static DEFAULT_OPTIONS = { + tag: 'form', + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'community'], + position: { width: 450, height: 700 }, + actions: { + editFeature: this.editFeature, + deleteFeature: this.deleteFeature + }, + form: { + handler: this.updateForm, + submitOnChange: true, + closeOnSubmit: false + }, + dragDrop: [{ dragSelector: null, dropSelector: null }] + }; + + static PARTS = { + header: { template: 'systems/daggerheart/templates/sheets/items/community/header.hbs' }, + tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' }, + description: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-description.hbs' }, + features: { + template: 'systems/daggerheart/templates/sheets/global/tabs/tab-feature-section.hbs', + scrollable: ['.features'] + } + }; + + static TABS = { + description: { + active: true, + cssClass: '', + group: 'primary', + id: 'description', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Description' + }, + features: { + active: false, + cssClass: '', + group: 'primary', + id: 'features', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Features' + } + }; + + async _prepareContext(_options) { + const context = await super._prepareContext(_options); + context.document = this.document; + context.tabs = super._getTabs(this.constructor.TABS); + + return context; + } + + static async updateForm(event, _, formData) { + await this.document.update(formData.object); + this.render(); + } + + static async editFeature(_, target) { + const feature = await fromUuid(target.dataset.feature); + feature.sheet.render(true); + } + + static async deleteFeature(event, target) { + event.preventDefault(); + event.stopPropagation(); + await this.item.update({ + 'system.abilities': this.item.system.abilities.filter(x => x.uuid !== target.dataset.feature) + }); + } + + async _onDrop(event) { + const data = TextEditor.getDragEventData(event); + const item = await fromUuid(data.uuid); + if (item.type === 'feature' && item.system.type === SYSTEM.ITEM.featureTypes.community.id) { + await this.document.update({ + 'system.abilities': [ + ...this.document.system.abilities, + { img: item.img, name: item.name, uuid: item.uuid } + ] + }); + } + } +} diff --git a/module/applications/sheets/items/consumable.mjs b/module/applications/sheets/items/consumable.mjs index eb0a3d6b..cc36bf97 100644 --- a/module/applications/sheets/items/consumable.mjs +++ b/module/applications/sheets/items/consumable.mjs @@ -4,7 +4,7 @@ const { ItemSheetV2 } = foundry.applications.sheets; export default class ConsumableSheet extends DaggerheartSheet(ItemSheetV2) { static DEFAULT_OPTIONS = { tag: 'form', - classes: ['daggerheart', 'sheet', 'dh-style', 'consumable'], + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'consumable'], position: { width: 550 }, form: { handler: this.updateForm, diff --git a/module/applications/sheets/domainCard.mjs b/module/applications/sheets/items/domainCard.mjs similarity index 51% rename from module/applications/sheets/domainCard.mjs rename to module/applications/sheets/items/domainCard.mjs index be9971d5..bd278311 100644 --- a/module/applications/sheets/domainCard.mjs +++ b/module/applications/sheets/items/domainCard.mjs @@ -1,45 +1,13 @@ -// import DhpApplicationMixin from '../daggerheart-sheet.mjs'; - -// export default class DomainCardSheet extends DhpApplicationMixin(ItemSheet) { -// static documentType = "domainCard"; - -// /** @override */ -// static get defaultOptions() { -// return foundry.utils.mergeObject(super.defaultOptions, { -// classes: ["daggerheart", "sheet", "domain-card"], -// width: 600, -// height: 600, -// tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "features" }] -// }); -// } - -// /** @override */ -// getData() { -// const context = super.getData(); -// context.config = CONFIG.daggerheart; - -// return context; -// } - -// async _handleAction(action, event, button) { -// switch(action){ -// case 'attributeRoll': - -// break; -// } -// } -// } - -import DaggerheartAction from '../../data/action.mjs'; -import DaggerheartActionConfig from '../config/Action.mjs'; -import DaggerheartSheet from './daggerheart-sheet.mjs'; +import DaggerheartAction from '../../../data/action.mjs'; +import DaggerheartActionConfig from '../../config/Action.mjs'; +import DaggerheartSheet from '../daggerheart-sheet.mjs'; const { ItemSheetV2 } = foundry.applications.sheets; export default class DomainCardSheet extends DaggerheartSheet(ItemSheetV2) { static DEFAULT_OPTIONS = { tag: 'form', - classes: ['daggerheart', 'sheet', 'domain-card'], - position: { width: 600, height: 600 }, + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'domain-card'], + position: { width: 450, height: 700 }, actions: { addAction: this.addAction, editAction: this.editAction, @@ -53,29 +21,50 @@ export default class DomainCardSheet extends DaggerheartSheet(ItemSheetV2) { }; static PARTS = { - form: { - id: 'feature', - template: 'systems/daggerheart/templates/sheets/domainCard.hbs' + header: { template: 'systems/daggerheart/templates/sheets/items/domainCard/header.hbs' }, + tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' }, + description: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-description.hbs' }, + actions: { + template: 'systems/daggerheart/templates/sheets/global/tabs/tab-actions.hbs', + scrollable: ['.actions'] + }, + settings: { + template: 'systems/daggerheart/templates/sheets/items/domainCard/settings.hbs', + scrollable: ['.settings'] } }; - _getTabs() { - const tabs = { - general: { active: true, cssClass: '', group: 'primary', id: 'general', icon: null, label: 'General' }, - actions: { active: false, cssClass: '', group: 'primary', id: 'actions', icon: null, label: 'Actions' } - }; - for (const v of Object.values(tabs)) { - v.active = this.tabGroups[v.group] ? this.tabGroups[v.group] === v.id : v.active; - v.cssClass = v.active ? 'active' : ''; + static TABS = { + description: { + active: true, + cssClass: '', + group: 'primary', + id: 'description', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Description' + }, + actions: { + active: false, + cssClass: '', + group: 'primary', + id: 'actions', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Actions' + }, + settings: { + active: false, + cssClass: '', + group: 'primary', + id: 'settings', + icon: null, + label: 'DAGGERHEART.Sheets.Feature.Tabs.Settings' } - - return tabs; - } + }; async _prepareContext(_options) { const context = await super._prepareContext(_options); context.config = CONFIG.daggerheart; - context.tabs = this._getTabs(); + context.tabs = super._getTabs(this.constructor.TABS); return context; } diff --git a/module/applications/sheets/items/feature.mjs b/module/applications/sheets/items/feature.mjs index 553b686d..25d37822 100644 --- a/module/applications/sheets/items/feature.mjs +++ b/module/applications/sheets/items/feature.mjs @@ -13,7 +13,7 @@ export default class FeatureSheet extends DaggerheartSheet(ItemSheetV2) { static DEFAULT_OPTIONS = { tag: 'form', id: 'daggerheart-feature', - classes: ['daggerheart', 'sheet', 'dh-style', 'feature'], + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'feature'], position: { width: 600, height: 600 }, window: { resizable: true }, actions: { @@ -35,7 +35,7 @@ export default class FeatureSheet extends DaggerheartSheet(ItemSheetV2) { tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' }, description: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-description.hbs' }, actions: { - template: 'systems/daggerheart/templates/sheets/items/feature/actions.hbs', + template: 'systems/daggerheart/templates/sheets/global/tabs/tab-actions.hbs', scrollable: ['.actions'] }, settings: { diff --git a/module/applications/sheets/items/miscellaneous.mjs b/module/applications/sheets/items/miscellaneous.mjs index cf4ba2c0..af43fa51 100644 --- a/module/applications/sheets/items/miscellaneous.mjs +++ b/module/applications/sheets/items/miscellaneous.mjs @@ -1,32 +1,10 @@ -// import DhpApplicationMixin from '../daggerheart-sheet.mjs'; - -// export default class MiscellaneousSheet extends DhpApplicationMixin(ItemSheet) { -// static documentType = "miscellaneous"; - -// /** @override */ -// static get defaultOptions() { -// return foundry.utils.mergeObject(super.defaultOptions, { -// classes: ["daggerheart", "sheet", "miscellaneous"], -// width: 400, -// height: 'auto', -// }); -// } - -// /** @override */ -// getData() { -// const context = super.getData(); - -// return context; -// } -// } - import DaggerheartSheet from '../daggerheart-sheet.mjs'; const { ItemSheetV2 } = foundry.applications.sheets; export default class MiscellaneousSheet extends DaggerheartSheet(ItemSheetV2) { static DEFAULT_OPTIONS = { tag: 'form', - classes: ['daggerheart', 'sheet', 'dh-style', 'miscellaneous'], + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'miscellaneous'], position: { width: 550 }, form: { handler: this.updateForm, diff --git a/module/applications/sheets/items/weapon.mjs b/module/applications/sheets/items/weapon.mjs index e12564df..90cde394 100644 --- a/module/applications/sheets/items/weapon.mjs +++ b/module/applications/sheets/items/weapon.mjs @@ -4,7 +4,7 @@ const { ItemSheetV2 } = foundry.applications.sheets; export default class WeaponSheet extends DaggerheartSheet(ItemSheetV2) { static DEFAULT_OPTIONS = { tag: 'form', - classes: ['daggerheart', 'sheet', 'dh-style', 'weapon'], + classes: ['daggerheart', 'sheet', 'item', 'dh-style', 'weapon'], position: { width: 600 }, form: { handler: this.updateForm, diff --git a/module/config/domainConfig.mjs b/module/config/domainConfig.mjs index a188ed43..394f6fb3 100644 --- a/module/config/domainConfig.mjs +++ b/module/config/domainConfig.mjs @@ -85,17 +85,17 @@ export const classMap = { export const cardTypes = { ability: { id: 'ability', - label: 'DAGGERHEART.Domain.CardTypes.Ability', + label: 'DAGGERHEART.Domain.CardTypes.ability', img: '' }, spell: { id: 'spell', - label: 'DAGGERHEART.Domain.CardTypes.Spell', + label: 'DAGGERHEART.Domain.CardTypes.spell', img: '' }, grimoire: { id: 'grimoire', - label: 'DAGGERHEART.Domain.CardTypes.Grimoire', + label: 'DAGGERHEART.Domain.CardTypes.grimoire', img: '' } }; diff --git a/styles/daggerheart.css b/styles/daggerheart.css index 178e4d69..56c1e0d7 100755 --- a/styles/daggerheart.css +++ b/styles/daggerheart.css @@ -2796,40 +2796,11 @@ div.daggerheart.views.multiclass { scrollbar-width: thin; scrollbar-color: light-dark(#18162e, #f3c267) transparent; } -.application.sheet.daggerheart.dh-style.feature .tab.actions .actions-list { - display: flex; - flex-direction: column; - list-style: none; - padding: 0; - margin: 0; - width: 100%; - gap: 5px; -} -.application.sheet.daggerheart.dh-style.feature .tab.actions .actions-list .action-item { - display: grid; - align-items: center; - grid-template-columns: 1fr 4fr 1fr; - cursor: pointer; -} -.application.sheet.daggerheart.dh-style.feature .tab.actions .actions-list .action-item h4 { - font-family: 'Montserrat', sans-serif; - font-weight: lighter; - color: #efe6d8; -} -.application.sheet.daggerheart.dh-style.feature .tab.actions .actions-list .action-item .image { - height: 40px; - width: 40px; - object-fit: cover; - border-radius: 6px; - border: none; -} -.application.sheet.daggerheart.dh-style.feature .tab.actions .actions-list .action-item .controls { - display: flex; - justify-content: center; - gap: 10px; -} -.application.sheet.daggerheart.dh-style.feature .tab.actions .actions-list .action-item .controls a { - text-shadow: none; +.application.sheet.daggerheart.dh-style.domain-card section.tab { + height: 400px; + overflow-y: auto; + scrollbar-width: thin; + scrollbar-color: light-dark(#18162e, #f3c267) transparent; } @font-face { font-family: 'Cinzel'; @@ -3145,6 +3116,41 @@ div.daggerheart.views.multiclass { text-shadow: none; font-family: 'Montserrat', sans-serif; } +.sheet.daggerheart.dh-style .tab.actions .actions-list { + display: flex; + flex-direction: column; + list-style: none; + padding: 0; + margin: 0; + width: 100%; + gap: 5px; +} +.sheet.daggerheart.dh-style .tab.actions .actions-list .action-item { + display: grid; + align-items: center; + grid-template-columns: 1fr 4fr 1fr; + cursor: pointer; +} +.sheet.daggerheart.dh-style .tab.actions .actions-list .action-item h4 { + font-family: 'Montserrat', sans-serif; + font-weight: lighter; + color: #efe6d8; +} +.sheet.daggerheart.dh-style .tab.actions .actions-list .action-item .image { + height: 40px; + width: 40px; + object-fit: cover; + border-radius: 6px; + border: none; +} +.sheet.daggerheart.dh-style .tab.actions .actions-list .action-item .controls { + display: flex; + justify-content: center; + gap: 10px; +} +.sheet.daggerheart.dh-style .tab.actions .actions-list .action-item .controls a { + text-shadow: none; +} .application.sheet.daggerheart.dh-style .item-sheet-header { display: flex; } @@ -3188,6 +3194,135 @@ div.daggerheart.views.multiclass { .application.sheet.daggerheart.dh-style .item-sheet-header .item-info h3 { font-size: 1rem; } +.application.sheet.daggerheart.dh-style .item-card-header { + display: flex; + flex-direction: column; + justify-content: start; + text-align: center; +} +.application.sheet.daggerheart.dh-style .item-card-header .profile { + height: 300px; + width: 100%; + object-fit: cover; + mask-image: linear-gradient(0deg, transparent 0%, black 10%); +} +.application.sheet.daggerheart.dh-style .item-card-header .item-icons-list { + position: absolute; + display: flex; + align-items: center; + justify-content: center; + top: 50px; + right: 10px; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-icons-list .item-icon { + display: flex; + align-items: center; + justify-content: end; + text-align: center; + padding-right: 8px; + max-width: 50px; + height: 50px; + font-size: 1.2rem; + background: light-dark(rgba(0, 0, 0, 0.3), rgba(24, 22, 46, 0.33)); + border: 4px double light-dark(#efe6d8, #f3c267); + color: light-dark(#efe6d8, #f3c267); + border-radius: 999px; + transition: all 0.3s ease; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-icons-list .item-icon .recall-label { + font-size: 14px; + opacity: 0; + margin-right: 0.3rem; + transition: all 0.3s ease; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-icons-list .item-icon i { + font-size: 0.8rem; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-icons-list .item-icon:hover { + max-width: 300px; + padding: 0 10px; + border-radius: 60px; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-icons-list .item-icon:hover .recall-label { + opacity: 1; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-info { + display: flex; + flex-direction: column; + align-items: center; + position: relative; + top: -25px; + gap: 5px; + margin-bottom: -20px; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-info .item-name input[type='text'] { + font-size: 32px; + height: 42px; + text-align: center; + width: 90%; + transition: all 0.3s ease; + outline: 2px solid transparent; + border: 1px solid transparent; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-info .item-name input[type='text']:hover[type='text'], +.application.sheet.daggerheart.dh-style .item-card-header .item-info .item-name input[type='text']:focus[type='text'] { + box-shadow: none; + outline: 2px solid light-dark(#18162e, #f3c267); +} +.application.sheet.daggerheart.dh-style .item-card-header .item-info .item-description { + display: flex; + flex-direction: column; + gap: 10px; +} +.application.sheet.daggerheart.dh-style .item-card-header .item-info h3 { + font-size: 1rem; +} +.sheet.daggerheart.dh-style.item .tab.features { + padding: 0 10px; + max-height: 265px; + overflow-y: auto; + scrollbar-width: thin; + scrollbar-color: light-dark(#18162e, #f3c267) transparent; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list { + display: flex; + flex-direction: column; + list-style: none; + padding: 0; + margin: 0; + width: 100%; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item { + margin-bottom: 10px; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item:last-child { + margin-bottom: 0px; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item .feature-line { + display: grid; + align-items: center; + grid-template-columns: 1fr 4fr 1fr; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item .feature-line h4 { + font-family: 'Montserrat', sans-serif; + font-weight: lighter; + color: light-dark(#222, #efe6d8); +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item .feature-line .image { + height: 40px; + width: 40px; + object-fit: cover; + border-radius: 6px; + border: none; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item .feature-line .controls { + display: flex; + justify-content: center; + gap: 10px; +} +.sheet.daggerheart.dh-style.item .tab.features .feature-list .feature-item .feature-line .controls a { + text-shadow: none; +} #logo { content: url(../assets/DaggerheartLogo.webp); height: 50px; diff --git a/styles/daggerheart.less b/styles/daggerheart.less index d55a4aec..4821f52d 100755 --- a/styles/daggerheart.less +++ b/styles/daggerheart.less @@ -13,6 +13,8 @@ // new styles imports @import './less/items/feature.less'; +@import './less/items/ancestry.less'; +@import './less/items/domainCard.less'; @import './less/utils/colors.less'; @import './less/utils/fonts.less'; @@ -20,7 +22,9 @@ @import './less/global/sheet.less'; @import './less/global/elements.less'; @import './less/global/tab-navigation.less'; +@import './less/global/tab-actions.less'; @import './less/global/item-header.less'; +@import './less/global/feature-section.less'; #logo { content: url(../assets/DaggerheartLogo.webp); diff --git a/styles/less/global/feature-section.less b/styles/less/global/feature-section.less new file mode 100644 index 00000000..50ffaefa --- /dev/null +++ b/styles/less/global/feature-section.less @@ -0,0 +1,51 @@ +@import '../utils/colors.less'; +@import '../utils/fonts.less'; + +.sheet.daggerheart.dh-style.item { + .tab.features { + padding: 0 10px; + max-height: 265px; + overflow-y: auto; + scrollbar-width: thin; + scrollbar-color: light-dark(@dark-blue, @golden) transparent; + .feature-list { + display: flex; + flex-direction: column; + list-style: none; + padding: 0; + margin: 0; + width: 100%; + .feature-item { + margin-bottom: 10px; + &:last-child { + margin-bottom: 0px; + } + .feature-line { + display: grid; + align-items: center; + grid-template-columns: 1fr 4fr 1fr; + h4 { + font-family: @font-body; + font-weight: lighter; + color: light-dark(@dark, @beige); + } + .image { + height: 40px; + width: 40px; + object-fit: cover; + border-radius: 6px; + border: none; + } + .controls { + display: flex; + justify-content: center; + gap: 10px; + a { + text-shadow: none; + } + } + } + } + } + } +} diff --git a/styles/less/global/item-header.less b/styles/less/global/item-header.less index 290e3bdd..06919b77 100755 --- a/styles/less/global/item-header.less +++ b/styles/less/global/item-header.less @@ -50,4 +50,103 @@ } } } + + .item-card-header { + display: flex; + flex-direction: column; + justify-content: start; + text-align: center; + + .profile { + height: 300px; + width: 100%; + object-fit: cover; + mask-image: linear-gradient(0deg, transparent 0%, black 10%); + cursor: pointer; + } + + .item-icons-list { + position: absolute; + display: flex; + align-items: center; + justify-content: center; + top: 50px; + right: 10px; + + .item-icon { + display: flex; + align-items: center; + justify-content: end; + text-align: center; + padding-right: 8px; + max-width: 50px; + height: 50px; + font-size: 1.2rem; + background: light-dark(@light-black, @semi-transparent-dark-blue); + border: 4px double light-dark(@beige, @golden); + color: light-dark(@beige, @golden); + border-radius: 999px; + transition: all 0.3s ease; + + .recall-label { + font-size: 14px; + opacity: 0; + margin-right: 0.3rem; + transition: all 0.3s ease; + } + + i { + font-size: 0.8rem; + } + + &:hover { + max-width: 300px; + padding: 0 10px; + border-radius: 60px; + + .recall-label { + opacity: 1; + } + } + } + } + + .item-info { + display: flex; + flex-direction: column; + align-items: center; + position: relative; + top: -25px; + gap: 5px; + margin-bottom: -20px; + + .item-name { + input[type='text'] { + font-size: 32px; + height: 42px; + text-align: center; + width: 90%; + transition: all 0.3s ease; + outline: 2px solid transparent; + border: 1px solid transparent; + + &:hover[type='text'], + &:focus[type='text'] { + box-shadow: none; + outline: 2px solid light-dark(@dark-blue, @golden); + } + } + } + + .item-description { + display: flex; + flex-direction: column; + gap: 10px; + } + + h3 { + font-size: 1rem; + } + } + } } diff --git a/styles/less/global/sheet.less b/styles/less/global/sheet.less index b3fe4960..e557ae7e 100755 --- a/styles/less/global/sheet.less +++ b/styles/less/global/sheet.less @@ -67,7 +67,6 @@ background-position: center; } } -// D:\Foundry\v13\data\Data\systems\daggerheart\assets\parchments\dh-parchment-light.png .application.sheet.daggerheart.dh-style { .window-content { diff --git a/styles/less/global/tab-actions.less b/styles/less/global/tab-actions.less new file mode 100644 index 00000000..fb4f8850 --- /dev/null +++ b/styles/less/global/tab-actions.less @@ -0,0 +1,46 @@ +@import '../utils/colors.less'; +@import '../utils/fonts.less'; + +.sheet.daggerheart.dh-style { + .tab.actions { + .actions-list { + display: flex; + flex-direction: column; + list-style: none; + padding: 0; + margin: 0; + width: 100%; + gap: 5px; + + .action-item { + display: grid; + align-items: center; + grid-template-columns: 1fr 4fr 1fr; + cursor: pointer; + + h4 { + font-family: @font-body; + font-weight: lighter; + color: @beige; + } + + .image { + height: 40px; + width: 40px; + object-fit: cover; + border-radius: 6px; + border: none; + } + + .controls { + display: flex; + justify-content: center; + gap: 10px; + a { + text-shadow: none; + } + } + } + } + } +} diff --git a/styles/less/items/domainCard.less b/styles/less/items/domainCard.less new file mode 100644 index 00000000..2cb1e361 --- /dev/null +++ b/styles/less/items/domainCard.less @@ -0,0 +1,12 @@ +@import '../utils/colors.less'; +@import '../utils/fonts.less'; + +.application.sheet.daggerheart.dh-style.domain-card { + + section.tab { + height: 400px; + overflow-y: auto; + scrollbar-width: thin; + scrollbar-color: light-dark(@dark-blue, @golden) transparent; + } +} diff --git a/styles/less/items/feature.less b/styles/less/items/feature.less index 08002406..f4c117eb 100755 --- a/styles/less/items/feature.less +++ b/styles/less/items/feature.less @@ -17,46 +17,4 @@ scrollbar-width: thin; scrollbar-color: light-dark(@dark-blue, @golden) transparent; } - - .tab.actions { - .actions-list { - display: flex; - flex-direction: column; - list-style: none; - padding: 0; - margin: 0; - width: 100%; - gap: 5px; - - .action-item { - display: grid; - align-items: center; - grid-template-columns: 1fr 4fr 1fr; - cursor: pointer; - - h4 { - font-family: @font-body; - font-weight: lighter; - color: @beige; - } - - .image { - height: 40px; - width: 40px; - object-fit: cover; - border-radius: 6px; - border: none; - } - - .controls { - display: flex; - justify-content: center; - gap: 10px; - a { - text-shadow: none; - } - } - } - } - } } diff --git a/templates/sheets/ancestry.hbs b/templates/sheets/ancestry.hbs deleted file mode 100644 index 8cb6bbf1..00000000 --- a/templates/sheets/ancestry.hbs +++ /dev/null @@ -1,11 +0,0 @@ -