Was looking for a way to improve UX for end users when creating dimensions that link to other URLs and explores.
A common LookML use case to enable further exploration is to create a dimension that links to another Looker report or explore. For example you may create a dimension that links to a history of all orders that user has ever created.
Typically we create a HTML parameter with liquid templating to generate a URL for a given user and their order history:
dimension: history {
sql: ${TABLE}.id ;;
html: <a href="/explore/thelook/order_items?fields=order_items.detail*&f[users.id]={{ value }}">Order History</a>
;;
}
However it’s not immediately obvious to the end user they can click on this dimension value. We can simply add a <button>
HTML tag to render the link as a button, making the UX a bit more clear for our end users.
dimension: history_button {
sql: ${TABLE}.id ;;
html: <a href="/explore/thelook/order_items?fields=order_items.detail*&f[users.id]={{ value }}"><button>Order History</button></a>
;;
}
Here’s what the two fields look like side by side:
Do you have any other UX tricks that better guide users towards all the exploring and drilling they can do in Looker? Would love to see what you’ve come up with.