diff --git a/app/helpers/items_helper.rb b/app/helpers/items_helper.rb index 28e2fc99..e0536c86 100644 --- a/app/helpers/items_helper.rb +++ b/app/helpers/items_helper.rb @@ -141,6 +141,13 @@ module ItemsHelper def auction_genie_url_for(item) AUCTION_GENIE_URL_TEMPLATE.expand(auctiongenie: item.name).to_s end + + LEBRON_URL_TEMPLATE = Addressable::Template.new( + "https://stylisher.club/search/{name}" + ) + def lebron_url_for(item) + LEBRON_URL_TEMPLATE.expand(name: item.name).to_s + end def format_contribution_count(count) " (×#{count})".html_safe if count > 1 diff --git a/app/views/items/_item_header.html.haml b/app/views/items/_item_header.html.haml index 3b6445d9..addb6ae0 100644 --- a/app/views/items/_item_header.html.haml +++ b/app/views/items/_item_header.html.haml @@ -33,7 +33,7 @@ = link_to t('items.show.resources.jn_items'), jn_items_url_for(item) = link_to t('items.show.resources.impress_2020'), impress_2020_url_for(item) - if item.nc_trade_value - = link_to 'https://www.neopets.com/~lebron', + = link_to lebron_url_for(item), title: nc_trade_value_updated_at_text(item.nc_trade_value) do = t 'items.show.resources.lebron', value: nc_trade_value_estimate_text(item.nc_trade_value)