Drafts 22 Released - Widgets, iOS 14 Support and More

I found I had to open Drafts (and other apps with widgets) at least once before they’d appear in the native widget list instead of the old form.

I’ve done that and just about everything else I can think of to get widgets working and nothing has. I can’t understand it and why it would be the same issue across all of my devices and only for the Drafts app.

I know it sounds stupid but did you restart your device already. I remember that something similar was going on on my device. The second step would be to remove and reinsert the wideget

Please report back if it changes or not.


Ok, so in the last 30 minutes I have deleted the app from all of my devices and then reinstalled only on my iPhone. After the reinstall and iCloud resync the widgets remain the same blank canvas. I did yet another phone restart and still no change. Greg also asked me if I had any strange settings on my phone and I’ve gone through everything and could find none. Could it be something in iCloud?

I too am able to click the message:blah links in Drafts without the backslashes.

The new version is exquisite. The widgets - plus the JavaScript integration - allow me to make my phone into a platform to really support me.

1 Like

Hi! I have a counter of 2 in my Inbox even though it’s empty. Is this a bug or am I getting something wrong?

The count should reflect the count in your inbox with your default workspace filters applied. If you tap that button to open the app, it should apply those settings - you are not seeing two drafts in the list after tapping that button to open the app?

1 Like

No, it shows my empty Inbox.

Huh. Are other values updating? I’ve seen widget updates get stuck a few times, where iOS doesn’t update them properly. Still a different number if you reboot the phone?

Is there a way to set template tags to call random lines?

The specific goal would be having it call a random entry out of a draft for display in the new style widgets. So under custom body template in the widget parameter something like the idea of:
[[line|Math.random() * 100]]

Seconded, I was just thinking about this feature yesterday. I would find this very useful as well.

1 Like

Reboot solved it! (This post was shorter than 20 characters.)

Pretty straight forward to set-up a custom template tag that does this.

Thanks for the reply. I see how to do it as part of running an action. I don’t know how to get there, though, as a parameter in the new style widgets. The goal being to grab a random line from a Draft and have it display in a widget.

For example, you collect vocab words in a Draft and the widget randomly displays one every day, etc.

A workaround—I might create an action that would grab a line from the repository Draft and drop it by itself in a separate draft. Then have shortcuts run it every two hours. Then have Drafts display the Draft it dropped that into.

Yes, I’d agree that’s probably the most practical right now for utilising a Drafts widget as you are constrained to the content of a draft. Maybe consider stacking them to have them rotate through, then every week you could populate several drafts and have them surfacing throughout the week?

As another alternative, I gave it a try with Widget Pack and Shortcuts, and that worked pretty well for displaying a random line from a single draft.

For testing I triggered it with running the Shortcut whenever I conneccted to power.

Is there any way to make one of the cells/squares in the grid widget link directly to a desired not? I feel like that’s missing or I’m missing something.

Create a simple action that loads the draft into the editor and point one of the grid widget entries to that.

To create such an action, add a script step into a new action and copy the script below into it; but put your own draft UUID into the constant’s value on the first line. When run the script will find the draft object based on its UUID, load that into the editor, and activate the editor.

const UUID_TO_LOAD = "0BACEC09-708F-424B-81E3-39F3BF2A11B7";

Hope that helps.

1 Like