6.5.0B2 - Feedback List

Another great beta release! Thank you @charlie for all of the changes incorporated into this round. A few comments:

1. Possible Issue: I was playing around with an interesting concept. The concept isn’t really relevant to the issue but it might provide some context so here’s the backstory:

a. I was attempting to create a faux ‘load more’ button using a formula on a looper provider count field Something like: {{{{ looper.count }} + {{ url.param({"key":"load"}) }} }} where the url ‘load’ key would pass an always incrementing value like ?load={{ {{ url.param({"key":"load"}) | default('0') }} + 2 }}

b. However, when attempting this, nothing seemed to work. That url parameter on the button with ?load={{ {{ url.param({"key":"load"}) | default('0') }} + 2 }} simply did this to the url: /blog/?load={{%20{{%20url.param({"key":"load"})%20|%20default(%270%27)%20}}%20+%202%20}}

c. And even if it was passing the correct value into the url the looper provider wasn’t changing the count at all. But here’s where the interesting part comes in. If I change all of the Dynamic Content 2.0 formatting back to 1.0 formatting but still use the twig formula all works perfectly in this setup. So looper provider = {{ {{dc:looper:count}} + {{dc:url:param key="load"}} }} and button url =
?load={{{{dc:url:param key="load" fallback="0"}} + 2 }}

So in a nutshell, we don’t have to get my experimental setup working it’s more a question as to why the Dynamic Content 2.0 syntax doesn’t appear to be working?

2. Opinionated Preference / Thoughts The new font selector is awesome but for quick selection feels a little bit distracting. I do love that you’ve built in the option to show / hide the expanded font family with preview. What do you think about the following:

a. To get the default picker input to look the same as the native weight input, if you added font-size: var(--fs-input) and font-weight: var(--fw-input) back, it would get these looking more uniform:

Adding .tco-form-font-picker .tco-picker-swatch>div {padding:var--d-input-padding-y) var(--d-input-padding-x); would balance it out padding-wise as well.

b. I also played around a bit with the idea of de-emphasizing the font category headlines, shrinking down the size of the fonts themselves to make the browsing process a bit cleaner, and reducing the width when the expansion previews aren’t active so that the selector looks more like this:

For context I was just playing around with values here but something along these lines is where I ended up: .infinite-scroll-component h4.tco-app-standard-padding { font-size: 10px; text-transform: uppercase; margin: 1em 0em;

c. I also changed the padding and font size of the individiual fonts to match the --fs-input and --fw-input variables from the other pickers. So something like .tco-font-family-picker-item .tco-app-standard-padding { padding:0.25em; font-size: var(--fs-input); font-weight: var(--fw-input);

d. I also added a consistent CS accent hover color. Currently it’s grey but think it should be blue. I didn’t use the variable here but something like .tco-font-famil-picker-item:hover {background: #048df3;}

1 Like

You would actually do that in Twig with {{ ( url.param({"key":"load"}) | default(0) ) + 2 }} or {{ looper.count + url.param({"key":"load"}) }} in your other example.

Since filters happen before math happens you don’t actually need the parenthesis too {{ url.param({"key":"load"}) | default(0) + 2 }}, but it’s probably more readable in the first example.

This has come up before and I’ll update the docs with more info, but there isn’t inner Twig blocks. Once you’ve started the initial {{ You can use any number of dynamic data points. Example {{ looper.count + looper.index}} doesn’t need more tags for looper.count and looper.index. It’s probably just a confusion based around Inner Dynamic Content, but that isn’t needed with Twig and it doesn’t exist. You probably should have gotten a error actually so I’ll see what’s up with that. I know errors in Custom CSS don’t show up correctly and I’ll need to fix that.

As to why your c example works, it is because normal Dynamic Content runs and renders first. So as far as Twig is concerned, what it’s actually seeing is {{ 2 + 2 }}, which is valid Twig.

Let me know if this helps.

  1. Love the looks on all these and I’ll get that updated in beta3. I think I’ll keep the same width on “Expanded” mode, but I would encourage you to check out this mode if you haven’t already and would love to hear your thoughts on this.