Issue with Confluence content byline item Icon

Hey Everyone,

Seems I can’t get my dynamic icon working for the confluence byline action. No issues reported with forge lint but when I deploy the app, I receive a console error stating the icon is a URL when I have it bundled with my resources. Not sure why it is trying to treat it as a URL. I’ve tried both .svg and .png files with no success. The dynamic properties to adjust the title and tooltip are working accordingly but the icon won’t render. Below is an example excerpt taken from my code:

backend logic excerpt from server.js:

  let status;
  let iconPath;
  let tooltipText;

  if (!cond1 || cond1 === 'cond1') {
    pageStatus = 'example';
    iconPath = 'resource:resource1;icon-1.png';
    tooltipText = `xxx.`;
  } else if (cond2 === 'cond2') {
    pageStatus = 'example2';
    iconPath = 'resource:resource1;icon-2.png';
    tooltipText = `xxx.`;
  } else {
    pageStatus = 'example3';
    iconPath = 'resource:resource1;icon-3.png';
    tooltipText = `x`;
  }

  return {
    title: `Current Cond.`,
    icon: iconPath,
    tooltip: tooltipText,
  };

Manifest.yml:

modules:
  confluence:contentBylineItem:
    - key: key-1
      resource: resource1
      title: "xxx"
      tooltip: "xxx"
      resolver:
        function: handler
      dynamicProperties:
        function: getDP
  function:
  - key: handler
    handler: resolver.handler
  - key: getDP
    handler: server.getDP 
resources:
  - key: resource1
    path: static/resource1/build
permissions:
  scopes:
    - write:confluence-content
    - read:confluence-content.all
    - read:confluence-content.summary
    - read:confluence-space.summary
    - storage:app
    - read:confluence-props
    - write:confluence-props
  external:
    images:
      - '*.atlassian.com'
  content:
    styles:
      - 'unsafe-inline'

Any help would be appreciated, thanks!

When I tried to get this to work a while back, I ran into similar issues. I found it easier to just convert the SVGs into base64 and include them as icon: "data:image/svg+xml;base64,...". Might be a way to get it to work otherwise. :person_shrugging: