A recording of the November 18th webinar is available on YouTube. We discussed the difference between formulas and trigger formulas and shared tips on specific formula functions.
I just watched the “Build with Grist Webinar - Custom Widgets - Apr 14, 2022”, excellent by the way!
I just had a question regarding the webinar. @natalie-grist focused on the Notepad, Markdown and HTML custom widgets. I was wondering if it is possible to place a variable from a table with a custom widget.
For example - If I have the variable $name in a table and I have any of the above custom widgets, richtext, html etc. Can I use $name within the text of the custom widget? “$name has a birthday today!”
I’m glad you enjoyed the webinar While you can’t use $Name directly in the widget, you can use it in a formula column that the widget then pulls data from. I created an example using “$Name has a birthday today!” at the link below:
In my table, I have Name, Birthday and ‘Birthday Today?’. This is a formula column that returns a string of text when the Month and Day from the date listed in $Birthday match TODAY()'s Month and Day.
Part of the string that is returned is “***” which is used for formatting within our Markdown widget. You could add more formatting than this, just be sure to wrap the formatting in quotes to make it a string.
You can filter out all rows that contain an empty value in ‘Birthday Today?’.
On the same page as this table, I have added a markdown widget that updates based on what row is selected in the Birthdays table. You’ll see that the formatting that we added in the Birthday Today? column appears as expected in the Markdown widget.
If you take a look at the Markdown Widget page, you’ll see this page only includes a widget. I have the widget filtered by ‘Birthday Today?’.
Penelope shows up because her record appears first in the table after filtering. There isn’t a great way to see a second record when a second record exists so I added the Filter Button for Birthday Today? at the top of the widget. That way, you could click the filter icon to see if another record had a birthday today.
If there are no birthdays today and Birthday Today? only contains blank values, nothing will appear in the widget.
I hope this helps! Let me know if you have any other questions.
Thank you so much for your in-depth reply @natalie-grist ! I am currently trying out your ideas on my custom widgets. It is exciting to see the possibilities that are available. My main use for Grist is my company CRM and I must say that all these little improvements make a huge difference to the usability and user-friendliness of my application.