Show shifted date range in Panel title

I have a repeating panel that repeats on a Dashboard variable, $TimeRanges, which is meant to shift the data reported one week back from the $__to value in the Time Picker. The variable values are 0d, 7d, 14d, 21d,28d. This works great. My query results effectively show data from the current week, 1 week prior, 2 weeks prior, etc.
What I need to do now is to show the date ranges each panel represents, and I’ve been stymied. I tried this but instead of calculating the to and from dates minus the offset $TimeRanges, it simply display the To and From dates and then “-od” “-7d”, etc.

${__from:date:YY-MM-DD}-${TimeRanges} to ${__to:date:YY-MM-DD}-${TimeRanges}

Is this even possible in Grafana? If someone has solved this please share your solution. If this isn’t possible it would be useful to know that too so I don’t keep banging my head trying to solve a problem that isn’t solvable.

can you create a couple query variables to show the time ranges and then display those query variables in the title?

Not sure what you mean here exactly. Do you mean create Dashboard variables that are query variables and use those? I know I can’t use variables that are in the panel query (tried that!).
The problem I’m having with creating dashboard variables that show the to and from dates is that Grafana doesn’t seem to like using the $__from and $__to variables in another dashboard variable query. At least I can’t seem to make it work.

what do the queries look like to populate the data in your example panels?