cjodo / convert.nvim

A plugin to do unit conversions for you.
45 stars 1 forks source link
css lua nvim nvim-plugin

convert.nvim

https://github.com/user-attachments/assets/46129dd1-35b0-41ce-a1d8-ead1922d8af4

Dependencies

Features

Installation:

Use your favourite plugin manager

Usage

You can choose you're own custom keys for the ui menu

  config = function()
    local convert = require('convert')
    -- defaults
    convert.setup({
      keymaps = {
        focus_next = { "j", "<Down>", "<Tab>" },
        focus_prev = { "k", "<Up>", "<S-Tab>" },
        close = { "<Esc>", "<C-c>", 'qq' },
        submit = { "<CR>", "<Space>" },
      }
    })
  end

Commands:

Command Description
:ConvertFindNext Finds the next convertible unit
:ConvertFindCurrent Finds the convertible unit in the current line (starting from cursor)
:ConvertAll Converts all instances of a given unit to another