aboutsummaryrefslogtreecommitdiff
path: root/config.lua
diff options
context:
space:
mode:
Diffstat (limited to 'config.lua')
-rw-r--r--config.lua10
1 files changed, 10 insertions, 0 deletions
diff --git a/config.lua b/config.lua
index 68bd01b..79ab751 100644
--- a/config.lua
+++ b/config.lua
@@ -41,6 +41,16 @@ local function to_url(url)
return "https://" .. trim(url)
end
+web.keymap.set('n', '<esc>', function() web.search.set_text('') end)
+web.keymap.set('n', 'n', function() web.search.next() end)
+web.keymap.set('n', '<s-n>', function() web.search.previous() end)
+web.keymap.set('n', '<c-f>', function()
+ dmenu.input({ prompt = 'Search:' }, function(err, input)
+ if err or not input then return end
+ web.search.set_text(input)
+ end)
+end)
+
-- Open in new view
web.keymap.set('n', 'o', function()
print(web.get('new_view_url'), web.get('user_agent'))