TyphonJS (Michael)
TyphonJS (Michael)
TTyphonJS
Created by TyphonJS (Michael) on 8/7/2024 in #typhonjs-runtime
ProseMirror UUID discussion
Hi @Jons. I'd be glad to continue the discussion here. I don't see anything immediately that is related to the TJSProseMirror component. The actual editor and such is the Foundry implementation underneath. There are additional plugins and such added, but it's not clear yet if what you are doing in regard to interaction would hit any of the aspects added by TJSProseMirror Can you more specifically outline the problem that you are seeing and perhaps put some console.log statements in foundry-esm.js to verify the UUID being parsed. The drag and drop of documents into the editor when active should be something completely controlled by the underlying Foundry implementation.
15 replies
TTyphonJS
Created by TyphonJS (Michael) on 8/6/2024 in #typhonjs-runtime
TJSDocumentProperty Prototype
So I implemented a prototype of a custom store implementation that wraps a TJSDocument instance that allows dynamic store access to property accessors. TJSDocumentProperty is a complete Writable instance allowing update to be used when more complex modification is required for the underlying property; IE pushing to an array or modifying a nested object. I included TJSDocumentProperty as an attachment to this post. Also is a demo Svelte component that can be copied to BasicDocAppShell in essential-svelte-esm. This demo is what is shown in the video preview. Note: That I'm using the internal 0.2.0 pre-release code and likely there are modifications necessary to get this to work with 0.1.3 which likely has slightly different context callback data. Also note that the core v12 changes for renderContext are not normalized yet. TJSDocument will receive a facelift for the 0.2.0 release and quite likely a solution related to TJSDocumentProperty will be available built-in to TJSDocument I'd be glad to get some feedback and certainly can help adjust this code to the current 0.1.3 release, but it clearly shows what is possible. Here is the video preview: https://www.youtube.com/watch?v=PPW7opFlS90
16 replies
TTyphonJS
Created by TyphonJS (Michael) on 7/4/2024 in #packages
Forien's Quest Log `0.8.0-beta.1`
Greets @FVTT ▹ Quest Log users, There is a public beta release available of the next FQL release (0.8.0-beta.1). It is v11 / v12 capable and is fully functional. It should be representative of the final release. You can install this immediately if you are waiting for FQL on v12. Your quest data is stored separately in journal documents, so you can install / uninstall this beta release. Check out this video for install and quick overview of new features: https://www.youtube.com/watch?v=cX8EbdRLJe8 I'll be making an actual release video for the public release later. To install the beta release: - Uninstall any existing FQL module. - Install the beta from this package link in the Foundry package manager: https://github.com/typhonjs-fvtt-scratch/foundryvtt-forien-quest-log/releases/latest/download/module.json For good measure when the official 0.8.0 release becomes available uninstall the beta release and reinstall FQL from the Foundry package manager. - Optional: Install latest Item Piles / 3.0.5 if your system is supported. --- There are no DB changes / migrations so this is a safe update. As always though please back up your data. New features: - Actor documents can be set as rewards (Item Piles / PF2e loot actors) - All rewards can have associated image changed. - Player notes If you are using dnd5e you can use the system text enrichment capabilities to create a custom reward using: [[/award 1000xp]] to distribute XP. See the beta release video above for brief demos of how to use Item Piles w/ FQL. --- The official release may happen next week. Do remember to uninstall the beta and re-install the official release as the beta repo / resources will be taken down after the official release is available.
4 replies
TTyphonJS
Created by TyphonJS (Michael) on 5/22/2024 in #typhonjs-runtime
TRL `0.1.3` - v12 Hot Patch
Greets @FVTT ▹ Developer! I have just released a hot patch release that addresses the v12 Foundry update and fixes a few odds and ends. - Reactive embedded collections of TJSDocument continue to work on v12. - HMR for language files works again. - Default app position tweening reduced to 60ms. ----- To check out HMR for language files add the following to your Foundry manifest:
{
"flags": {
"hotReload": {
"extensions": ["json"],
"paths": ["lang"]
}
}
}
{
"flags": {
"hotReload": {
"extensions": ["json"],
"paths": ["lang"]
}
}
}
For paths insert the language file directory. Then make sure to enable hot reloading of files in the main Foundry server settings page / GUI. Restart the server and fire up the dev server and when you make changes in the lang JSON files HMR should be triggered. Make sure the proxy settings of your Vite config properly forwards lang to the main server. You can check out template-svelte-esm for an example setup. Thanks @Nekro Darkmoon for the help in testing this hot patch!
11 replies
TTyphonJS
Created by TyphonJS (Michael) on 5/18/2024 in #typhonjs-runtime
Rest & Recovery 5e
Just creating a forum post to chat about upgrading the Rest & Recovery 5e module to the latest TRL and future integration aspects w/ Tidy Sheets 5e. @Michael
19 replies
TTyphonJS
Created by TyphonJS (Michael) on 3/5/2024 in #typhonjs-runtime
TJSDocument discussion w/ VoodooFrog
Following up on this discussion from #dev-lounge from @VoodooFrog:
I have a TJSDocument for an actor in which I am creating an embedded store which filters out certain items on the actor. These are then each displayed with their own component which contains a select that sets some data. Now, I have created a new select control in the parent that sets all the items via an update to a given value, but upon doing so the child component is not reflecting the change in their own controls (and yes I am setting the selected value based on the data). Any ideas what might be happening or how I can fix it? I don't have the code in my repo yet, as I'm still working on it so I can't just link the source, unfortunately.
When you can commit something to take a look at that will help a lot.
37 replies
TTyphonJS
Created by TyphonJS (Michael) on 2/6/2024 in #typhonjs-runtime
Advanced Templates Module (PF1)
A thread to discuss Svelte and the Advanced Templates module.
40 replies
TTyphonJS
Created by TyphonJS (Michael) on 1/30/2024 in #typhonjs-runtime
Automated Animations
This is a forum post to track discussion on Automated Animations. When TRL 0.2.0 is released I plan to update AA to the latest. In the meantime this post also is for discussing AA and an attempt to provide feedback for those that are trying to add new system support to it.
125 replies
TTyphonJS
Created by TyphonJS (Michael) on 12/1/2023 in #packages
Quest Log Permissions / Info
HI @larsvonawesome. You asked:
Trying to find more info on Forien's Quest Log; I'm having an issue where I as a GM can write in the description of a quest, but my players don't see that
Thanks for checking out the quest log. There are indeed a fair amount of options / settings that could be affecting this situation. Since I assume you might be new to using the quest log all quests start as "inactive" you have to make them "active" so that they become visible to players. Besides that there are ownership settings for quests, but quite likely you haven't touched that. This is where you can set the quests to be visible by particular players to make private quests. You'll have to provide more information in regard to what you are currently doing, but my guess is that perhaps you created a quest, but didn't make it active. There is a video tutorial series that covers all of the quest log features and more here that is useful to peruse. There are topic links in the description, so you can jump around to topics of interest: https://www.youtube.com/playlist?list=PLHslnNa8QKdD_M29g_Zs0f9zyAUVJ32Ne Let me know your particular situation and I'm sure it'll be resolved soon though.
12 replies
TTyphonJS
Created by TyphonJS (Michael) on 10/24/2023 in #typhonjs-runtime
Setting up TRL / contributing to existing module (Item Piles)
Hi @Paith. I have started this forum post where we can continue to discuss setting up TRL and getting you on the path to potentially investigating / contributing to Item Piles. I'm going to include @Wasp as well who develops / maintains Item Piles. Lots to potentially discuss and I'm definitely keen to help. Check the pins in #welcome for an overview on TRL and various additional / demo resources that are available. Getting your developer setup via Node / NPM will be the first thing to make sure you have sorted.
9 replies
TTyphonJS
Created by TyphonJS (Michael) on 10/22/2023 in #typhonjs-runtime
Reactivty and prepareDerivedData
From @Wasp
So I'm using prepareDerivedData to, well, derive some data for my items; some of them are tied to each other (ie, an "equipment" type item affects a "skill" type item's bonus). I was hoping that re-calling the derived data methods would cause the TJSDocuments to pick up the alterations, but since it's not a database operation, it doesn't appear to pick that up. Is there a good way allow one item to cause the reactivity of another without manually creating stores?
Moving discusion to forum post.
26 replies
TTyphonJS
Created by TyphonJS (Michael) on 10/17/2023 in #typhonjs-runtime
Local Development w/ NPM Link
From @Gerark:
Hello! this is probably a base webdev question but I can't find a good reference for the issue I'm having atm. I'm working on a TyphonJS template project and I'm importing a custom svelte library ( basically a UI component library ). I'd like to use npm link to work a bit more effectively without having to publish to npm a new package over and over whenever I make changes to the custom library. Apart from the npm link command to call on both sides ( with different parameters ) is there anything I should take care of? [3:39 PM] I get a bunch of errors telling me I'm trying to import stuffs with a wrong path but I thought npm link was going to work seamlessly and that I shouldn't be forced into changing the way how path should be written when importing a component.
47 replies
TTyphonJS
Created by TyphonJS (Michael) on 10/6/2023 in #typhonjs-runtime
TRL / Svelte based game systems
This post is a list of repos for game systems built with TRL / Svelte for Foundry. Please DM me if you'd like to add yours to the following lists. Released (available on Foundry package manager): - Level Up A5e: https://github.com/Pjb518/FoundryVTT-Level-Up-Official; @Nekro Darkmoon, @Phil Work in progress (Github repo / direct install): - Icon: https://github.com/whitespine/foundryvtt-icon; @WHITESPINE - Titan: https://github.com/Solidor777/Titan-VTTRPG; @Solidor More to come... Send me a DM to get added to this list. This post is locked and provides an index of links to various folks game system efforts.
1 replies
TTyphonJS
Created by TyphonJS (Michael) on 9/26/2023 in #typhonjs-runtime
Fabricate
@MisterPotts. Just starting a forum post to keep track of the conversation.
Fabricate doesn't maintain any of its own documents; it only records metadata in its settings. Do you think that would be a problem for TRL? For example, is there an assumption that applications are tied to documents? I would be surprised, but thought it worth asking up front
There are no particular data / document associations for TRL apps. Depending on where you are storing the metadata there are several reactive APIs available that could help out for game settings and web storage. You'll have to describe more about what you are doing currently from a data storage perspective and I can point you in the right direction. The first thing to do though is work out the TRL SvelteApplication extension and configuration through defaultOptions as it is different than what you came up with. The next thing is to use the ApplicationShell component as the outer wrapper for any of your components. With TRL the entire application shell is Svelte powered vs embedding components in the Foundry core app shell. Installing essential-svelte-esm and taking a look at the example code should give you an idea on how that works.
7 replies
TTyphonJS
Created by TyphonJS (Michael) on 9/25/2023 in #typhonjs-runtime
Svelte 5 TJSDocument Prototype
Greets @FVTT ▹ Developer. As some of you might have seen there is a bit of paradigm shift that is going to occur when Svelte 5 drops with a new way of defining reactive state. Please check some of the recent discussion in the #dev-lounge for links to the Svelte 5 blog post and a few other things. https://svelte.dev/blog/runes https://svelte-5-preview.vercel.app/docs/introduction I just worked up a potential prototype in the Svelte 5 REPL for what this could bring to TJSDocument for direct property access and reactive manipulation. The prototype simulates the Foundry document model update cycle. This demo is naive in many ways, so is bare bones code. What I'm curious about is how folks feel / think about how the new dynamic reactive properties should be exposed in the TJSDocument API. The demo adds a new behind the scene property state management that dynamically creates Svelte 5 $state instances for properties defined in a documents schema. I made this accessible from a new getter on the TJSDocument instance itself; $. In the demo the naive document has a name and count properties. You can reactively access them via doc.$.count / doc.$.name. You can drop those into wherever things can be bound and setting the values automatically will invoke update via the Foundry document model (this is simulated). This potentially addresses a way to dynamically access document properties in a fully reactive way that automatically updates the underlying document data transparently. This needs to be vetted in real world conditions once Svelte 5 drops! I have yet to think about how document flag access could be dynamically created. You can check out the demo on the Svelte 5 REPL here: https://tinyurl.com/tjsdocument-svelte5-2
7 replies
TTyphonJS
Created by TyphonJS (Michael) on 9/14/2023 in #packages
FQL / TextEditor enrichment issue
From @ooblekie:
can anyone give me a hand as to why the text keeps coming up as object promise in the quest log? it happens regardless of what text i put in and has only started to happen on my most recent foundry world. everything is up to date with the most recent version and i don't really know what else to try
6 replies
TTyphonJS
Created by TyphonJS (Michael) on 9/4/2023 in #typhonjs-runtime
TRL `0.1.2` - Fine Tuning release
Greets @FVTT ▹ Developer! I have just released a fine tuning release that brings a few more features, but really shores up a few things that slipped by initial testing of the beta release. I got in several small enhancements suggested by the dev community. There is one possible breaking change, but it is minor and I will discuss it after the release notes below. Do keep the conversation going and let me know about things that you encounter. The API docs are updated: https://typhonjs-fvtt-lib.github.io/api-docs/index.html - Fixed min window height / width for app shells (global vs script space variable access) - Fixed SvelteApplication render gating / force: false will short circuit properly when app not already rendered. - EmptyApplicationShell component can now be made resizable via setting the resizable app option. - Added closeOnInput prop to TJSGlassPane which fires close:glasspane event on pointer down event. - Added modalOptions.closeOnInput to TJSDialog data / close modal dialog on glasspane input. - Upgraded TJSDialogData adding reactive accessors for all standard data. New replace function instead of accessor setting of all data. - Update types for transition / modal options for TJSDialog. - Fixed application shell transition prop handling - defaultCloseAnimation option not taking when set to false w/ no transition defined. - separately defined in / out transitions works correctly. - DynReducerHelper.filters.regexObjectQuery - Can now take "accessor" strings to lookup nested properties. Simply provide a string separated by . for each depth. - An additional option is available accessWarn when set to true will log warnings when property lookups fail. Breaking Change: The potential breaking change is how dialog data is set in TJSDialog. There is a new replace method on the data field rather than directly setting an object to data. This change was due to that Typescript / creating declarations and API docs didn't like the types to differ for the getter and setter accessors. This likely doesn't actually cause any problems for folks as you'd have to explicitly set the data property in a custom dialog constructor. Instead of this.data = { ... } change things to this.data.replace({ ... }); New reactive data accessors: The TJSDialogData instance now has reactive accessors for all standard dialog data. For instance you can do this.data.content = 'New Content'; or this.data.content = { class: MySvelteComponent }; and the dialog will reactively update. Check out the API docs: https://typhonjs-fvtt-lib.github.io/api-docs/classes/_runtime_svelte_application.TJSDialog.html https://typhonjs-fvtt-lib.github.io/api-docs/interfaces/_runtime_svelte_application.TJSDialogData.html
1 replies
TTyphonJS
Created by TyphonJS (Michael) on 7/26/2023 in #typhonjs-runtime
Release `TRL 0.1.1` - Patch release
Greets @FVTT ▹ Developer! I have just released a patch / fix release that fixes a small oversight in the 0.1.0 release regarding the internally used ResizableHandle Svelte component for application windows via ApplicationShell. In the 0.1.0 release if you set width or height to auto and the app window is resizable an error occured. This was just a missed refactoring aspect to some internal code and I happened to not catch it in testing for the 0.1.0 release as it was data specific in how an app is setup. Another fix is passing the element as a JQuery element in the SvelteApplication hook invocation for closeApplication. Thanks @whitespine and @mouse0270 for providing some insight into getting things tip top again. Please do reach out if you see any issues as I'm certainly keen to make sure TRL is 100% bug / issue free. If you already have moved to TRL 0.1.0 you should just need to run npm install again to get the 0.1.1 patch. To be absolutely sure you get the TRL 0.1.1 release delete package-lock.json and node_modules directories and do a completely fresh install.
1 replies
TTyphonJS
Created by TyphonJS (Michael) on 7/23/2023 in #typhonjs-runtime
Popcorn Initiative
Just opening a forum post to track @gerark progress w/ TRL & Svelte + an initial idea of implementing "popcorn initiative"... 😄
42 replies
TTyphonJS
Created by TyphonJS (Michael) on 7/21/2023 in #typhonjs-runtime
Token Action HUD
Let's continue chatting about TAH here to keep track of discussion @larkinabout
19 replies