hubspot-cms-vscode icon indicating copy to clipboard operation
hubspot-cms-vscode copied to clipboard

convert_rgb filter causes syntax error

Open Acemandinga opened this issue 1 year ago • 0 comments

Describe the bug When using the convert_rgb filter (in my case {% macro to_rgba(color) %}rgba({{ color.color|convert_rgb }}, {{ color.opacity|int(100)/100 }}){% endmacro %}), the line will turn red with the error Passed #null into convert_rgb, needs to be in #87c95f format.

To Reproduce Steps to reproduce the behavior:

  1. add the above macro to your code
  2. Run/build
  3. Notice red line and error in vscode

Expected behavior No error, since a) it is a macro, and b) convert_rgb has no parameters (aka you can't do color|convert_rgb(#ffffff) according to the docs)

** Environment Versions: **

  • VSCode Version: 1.82.0
  • HubSpot VSCode Extension version: 1.2.1
  • OS: MacOS Ventura 13.5.2

Additional context Add any other context about the problem here.

Acemandinga avatar Sep 08 '23 13:09 Acemandinga