Browse Source

ensure frequency gets incremented on link click/return

main
familyfriendlymikey 2 years ago
parent
commit
5f7966d984
  1. 7
      app/client.imba
  2. 2
      package.json

7
app/client.imba

@ -169,7 +169,8 @@ tag app
err "adding link", e
def handle_click_link link
increment_link_frequency link
await increment_link_frequency link
window.location.href = "//{link.url}"
def handle_click_search
increment_search_engine_frequency!
@ -179,7 +180,7 @@ tag app
use_search_engine!
else
let link = state.scored_links[selection_index]
increment_link_frequency link
await increment_link_frequency link
window.location.href = "//{link.url}"
def handle_click_add
@ -390,7 +391,7 @@ tag app
<a.link
href="//{link.url}"
@pointerover=(selection_index = index)
@click=handle_click_link(link)
@click.prevent=handle_click_link(link)
.selected=(index == selection_index)
>
<.link-left>

2
package.json

@ -1,6 +1,6 @@
{
"name": "fuzzyhome",
"version": "0.1.2",
"version": "0.1.3",
"scripts": {
"start": "imba run -SMH --baseurl . -w server.imba",
"build-app": "rm -rf dist && imba build -SMH --baseurl . server.imba",

Loading…
Cancel
Save