Skip to content

Releases: WebCoder49/code-input

2.8.0

11 Dec 19:48

Choose a tag to compare

🆕 What's in this release?

  • The Autogrow plugin has been added to let code-input elements resize vertically, horizontally or both, potentially between minimum and maximum values, to fit their content. This is something I have seen hacked onto the library in the past, and now it's an official plugin! Use it just with CSS. - #206

🎉 Thanks for this release goes to @rdefaux for suggesting the plugin and coming up with initial code ideas for it! As always, if you find any bug or have any idea for enhancement (for this release or breaking changes for major version 3), please let me know!

2.7.3

07 Dec 19:40

Choose a tag to compare

Bug Fixes

  • The color-syncing code now does not interfere with the long-term value of the style attribute of code-input elements - #208, #207
  • The documentation now provides instructions if you want to use the Codeberg mirror as well as for this GitHub one.
  • Tiny corrections and typo fixes

As always, if you find any bug or have any idea for enhancement (for this release or breaking changes for major version 3), please let me know! 🎉

2.7.2

15 Nov 17:53

Choose a tag to compare

Bug Fixes

  • The FindAndReplace plugin's Ctrl+F keyboard shortcut can now adapt appropriately to Cmd+F on Apple operating systems - (for backwards compatibility and an acknowledgement that your user interface is no longer saying "Ctrl+F" you do need to enable this; see the docs). - #200
  • A small visual contrast bug in FindAndReplace and GoToLine plugins has been fixed - #203
  • Some slight clarifications in documentation.

Thanks for this release goes to @RaphaelDarley who reported the Ctrl+F/Cmd+F issue. As always, if you find any bug or have any idea for enhancement (for this release or breaking changes for major version 3), please let me know! 🎉

2.7.1

30 Sep 09:00

Choose a tag to compare

Bug Fixes

  • code-input.js' styles now prevent external CSS setting the overflow property to an unwanted value on the pre element from breaking the appearance. #198
  • Documentation improvements, including mentioning major version 3, and fixing autodetect plugin demo
  • Testing improvement: separating highlight.js and Prism.js styling to different i18n pages so they do not clash with each other (they are not designed to be used together, whether or not code-input.js is present).

Thanks for this release goes to @figuerom16 who reported the CSS incompatibility. As always, if you find any bug or have any idea for enhancement (for this release or breaking changes for major version 3), please let me know! 🎉

2.7.0

21 Sep 12:24

Choose a tag to compare

🆕 What's in this release?

  • Placeholder and caret colours are no longer hardcoded, but by default adapt to the highlighted theme, making them clearer and especially in light themes reducing the chance of inaccessible contrast (#183):
Screenshot of the above
  • Now you can use the color and caret-color CSS properties on code-input elements directly, which will also override the behaviour mentioned above (#182).
  • The minification code has been upgraded, fixing a bug it caused with line-number positioning.
  • The autocomplete demo code in the docs has been debugged.
  • Documentation has been made more thorough.

A (belated - sorry for forgetting earlier!) thanks to @ntward, who inspired and gave guidance for the custom color and caret-color support. 💡 If you can, please help advise the future of this library by emailing [email protected], or commenting on the Major Release v3.0.0 issue! 🎉 As always, general suggestions, bug reports and feature requests are very welcome, to [email protected] or on GitHub.

2.6.8

18 Sep 17:06

Choose a tag to compare

Bug Fixes

Slightly differently to the previous note, v2.6.8 is some small bug fixes:

  • Fix typo in TypeScript declarations
  • Remove debugging console.log from code-input.js (fixes #193)
  • Add email contribution option to CONTRIBUTING.md (fixes #192)

🎉 As always, if you find bugs please point them out, and if you have feature ideas or bugfixes/contributions let me know! They're more than welcome!

2.6.7

05 Sep 00:08

Choose a tag to compare

Bug Fix

  • The code-input element now supports IDL (JavaScript .onevent) and content (HTML onevent="") attribute event handlers (as well as the already-supported JavaScript addEventListener handlers), and event handlers on the pre-registration fallback element (graceful degradation) - #189

Status update: In-progress fixes to synchronise the caret and placeholder colour with the highlighted result, and thus minimise contrast bugs, are being cleaned of corner-cases, kept lines-of-code-and-time-efficient, and tested to avoid any breaking changes, on the synchronise-caret-color branch. It looks like they'll be released in v2.6.8.


💡 If you can, please help advise the future of this library by emailing [email protected], or commenting on the Major Release v3.0.0 issue! 🎉 As always, general suggestions, bug reports and feature requests are very welcome, to [email protected] or on GitHub.

2.6.6

19 Aug 11:25

Choose a tag to compare

Bug Fix

  • Adding a code-input element to the document after it has loaded (e.g. with JavaScript document.createElement) now works without errors - #184

Thanks so much to @MattiasBuelens for implementing this! As always, contributions to code and documentation, and bug reports/feature requests are more than welcome.

2.6.5

16 Aug 23:36

Choose a tag to compare

Small Enhancements

  • The visible instructions when using keyboard navigation with the indent plugin now display more cleanly and with the same horizontal padding as the code-input element.
  • Usage of relative paths to ECMAScript modules is now documented better.
  • --padding-left, --padding-right, --padding-top and --padding-bottom CSS variables can now be used on code-input elements as well as --padding (read the docs).
  • When a code-input element is registered and the fallback textarea is already being edited, it will retain focus and caret/scroll position for a seamless experience during slow loading.

Bug Fixes

  • Functions in the textarea interface work on code-input elements even when the elements are not registered, and eliminating a bug - #179
  • Padding is no longer duplicated in unregistered code-input elements with fallback textareas - #181
  • More elements in the code-input (keyboard navigation instructions, plugin dialogs) now keep consistent appearance, no matter the global CSS box-sizing.

As always, contributions are the fuel of this project, and bug reports, suggestions, documentation contributions and code contributions of any size are more than welcome! Just see the CONTRIBUTING.md file or email [email protected]! 🎉

2.6.4

13 Aug 09:35

Choose a tag to compare

Bug Fix

  • code-input elements now default to having a text-align of start rather than inherit, to be more like both textareas and the pre-internationalisation code-inputs.