Skip to content

Conversation

@KathrynmHansen
Copy link
Contributor

Ticket Link

https://codeforamerica.atlassian.net/browse/TEF-86
Its just a small portion of this ticket, only creating the link.

What was done

  • Added new link component
  • Added alt text for different type of icons
  • Added icon paths for different type of icons
  • So far the only icon is the information icon
  • Made it so the icon is optional in links
  • Added two examples of the link, one with an icon and one without

Copy link
Contributor

@jachan jachan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved with some comments to consider!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PEBBLE: if we're not putting a real test here, I'd prefer this file to not exist to not clutter the codebase. Curious how CFA feels though!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently repo has no tests and stubs for all tests - talked over this w Mike/Kat and I'm fine leaving as is

<% if @icon.present? %>
<%= image_tag icon_image_path, alt: icon_alt_text, class: "size-[20px]" %>
<% end %>
<%= link_to @label, @url %>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DUST - We may want to set target=_blank for the link so it opens in a new tab instead of taking the user out of the GetStateCTC flow.

We did so in vita-min on almost all links, and also set rel=noopener nofollow. What do you think?

def icon_alt_text
case @icon
when "info"
"info circle"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DUST - perhaps info icon is a more descriptive name?

@KathrynmHansen KathrynmHansen merged commit 175f8d6 into main Nov 19, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants