Skip to content

Commit

Permalink
Link To Show Table In Schema
Browse files Browse the repository at this point in the history
  • Loading branch information
s0kil committed May 18, 2021
1 parent 4a7b9cf commit 4eb698a
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions IHP/IDE/Data/View/ShowDatabase.hs
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,18 @@ renderTableSelector tableNames activeTableName = [hsx|
where
renderTable :: Text -> Html
renderTable name = [hsx|
<a href={ShowTableRowsAction name} class={classes [("object object-table w-100 context-table", True), ("active", name == activeTableName)]}>
<a
href={ShowTableRowsAction name}
class={classes [("object object-table w-100 context-table", True), ("active", name == activeTableName)]}
oncontextmenu={"showContextMenu('" <> contextMenuId <> "'); event.stopPropagation();"}
>
<div class="d-flex">
{name}
</div>
</a>|]
</a>
<div class="custom-menu menu-for-table shadow backdrop-blur" id={contextMenuId}>
<a href={pathTo (ShowTableAction name)}>Show Schema</a>
</div>
|]
where
contextMenuId = "context-menu-table-" <> name

0 comments on commit 4eb698a

Please sign in to comment.