Skip to content

Releases: Iron-E/nvim-libmodal

v0.9.3 – Popup API fixes

22 Nov 21:08
97f0ac7
Compare
Choose a tag to compare

This release brings general improvements to the popup API. Among them are:

  • Dynamic resizing according to amount of typed input.
  • Fix errors when entering a mode on a tabpage which doesn't exist by mode exit.
  • Consistent Popup appearance across tabpages.

v0.9.0 – Statusline Integration

14 Nov 01:30
636c8bf
Compare
Choose a tag to compare

Introduction

For the longest time, I've wanted to put the custom libmodal-modes that have been created with this plugin into the statusline as first-class Vim modes. This has not been possible until I found galaxyline.nvim (linked in the README)— an incredibly customizable plugin for your statusline.

While my configuration can be found here, a minimal example can also be found in the README.

Additions

  • Created vim.b.libmodalActiveModeName for Neovim 0.5+
  • Added example for galaxyline.nvim on how to use this variable to incorporate it into your statusline.

v0.8.0 – QoL Improvements

10 Sep 21:13
ac97661
Compare
Choose a tag to compare

Introduction

This release focuses on addressing some missing features in the libmodal toolkit. There aren't any big new features, but these additions should help allow developers to make use of the existing feature set.

Additions

  • Ability to use Lua functions as values in a Mode's instruction.
    • See the new examples: 1, 2
  • Ability to use Lua functions as values in a Prompt's instruction.
  • Add Mode and Prompt kill functions (libmodal.utils.api.mode_exit()).

0.7.0 – Restored Compatability

27 Aug 16:16
00b5b38
Compare
Choose a tag to compare

Introduction

As with any release, I am happy to bring the latest features and improvements to any who use this plugin. If any bugs are found, or features are desired, please open a ticket! I am happy to take a look.

0.7.0

Additions

  • Ability to pass functions into libmodal-mode from Vimscript.
  • Ability to pass functions into libmodal-prompt from Vimscript.
  • Add examples for doing almost everything that this plugin can do, from Vimscript (although I still think Lua makes it easier).

0.6.3

Fixes

  • Fix being unable to paste into Vim's command line after importing the libmodal.util.api table.

0.6.2

Fixes

  • Remove unused variables

0.6.1

Fixes

  • Mode names with spaces or underscores are now represented correctly by libmodal-lua-Vars.name().

v0.6.0 – Layers

31 May 00:54
85214c7
Compare
Choose a tag to compare

Additions

  • New module: |libmodal-layer|s.
    • Allows for use of built-in modes with overwriting of keymaps.
    • New class libmodal.Layer.
    • New function libmodal.layer.enter().
  • New examples for new additions.
  • libmodal.collections.ParseTable:
    • Added new :parseGet() method to replace the :get()
      implementation.
  • Added new libmodal.collections.ParseTable.parse() method.
    • You can override it to change how the ParseTable parses its keys.
  • Added ParseTable.stringSplit().

Breaking Changes

  • Moved libmodal.Mode.Popup to libmodal.collections.Popup.
  • Changed libmodal.collections.ParseTable.parseGet() back to
    libmodal.collections.ParseTable.get().
    • :get() requires that keys have been parsed according to
      .parse().

Changes

  • Exposed more functionality of libmodal.collections.Popup.

v0.5.0 – Metatables

31 May 00:52
1501358
Compare
Choose a tag to compare

Additions

  • New class libmodal.collections.Stack.
  • New class libmodal.Mode.
  • New class libmodal.Mode.Popup.
  • New class libmodal.Prompt.
  • New class libmodal.Vars.

Breaking Changes

  • Moved libmodal.mode.ParseTable to libmodal.collections.ParseTable.
  • Removed libmodal.utils.vars.
  • Moved libmodal.utils.Indicator to libmodal.Indicator.
  • Moved libmodal.utils.Indicator.Entry to
    libmodal.Indicator.HighlightSegment.

Changes

  • Allow creation of |libmodal-mode| and |libmodal-prompt| table-objects.

    • Call libmodal.Mode.new() or libmodal.Prompt.new() to create one.
      • Call {mode}:enter() to enter the mode.
    • More consistent mode recursion with libmodal.collections.Stack.
    • Mode creators can now override specific functionality by copying
      portions of the source code, or changing the values that are
      referenced by the mode directly.
      • This allows for finer control over how a mode behaves.
      • It also allows for modes to inherit each other through
        setmetatable().
  • Removed program logic from libmodal.mode.enter().

    • Now internally calls libmodal.Mode.new(…):enter() instead.
  • Removed program logic from libmodal.prompt.enter().

    • Now internally calls libmodal.Prompt.new(…):enter() instead.

Fixes

  • Fix unexpected behavior when repeating libmodal.mode.enter() calls
    with the from within themselves.
    • Mode popup windows may be closed prematurely by entering two different
      modes and then exiting them in reverse order, among other things. All
      previously known mysterious behavior is corrected.

v0.4.0

17 May 21:39
db764d9
Compare
Choose a tag to compare

Additions

Fixes

  • Fix bad reference to vars.windows.
  • Fix bug where help was always shown upon entering an invalid key-combo in libmodal.mode.enter().