npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@pikulinpw/ckeditor5-resizableheight

v1.0.0

Published

Optimize your CKEditor 5 editing space with the ResizableHeight plugin. This plugin adds the ability to set the height of the editor and also change its size. Adds the ability to resize.

Downloads

484

Readme

CKEditor 5 ResizableHeight Plugin

Optimize your CKEditor 5 editing space with the ResizableHeight plugin. This plugin adds the ability to set the height of the editor and also change its size. Adds the ability to resize. This plugin is compatible with various browsers including Chrome, Firefox, Safari, Edge and Internet Explorer, among others. It supports both the latest and older versions of these browsers and is optimized for devices such as iPhone, iPad, Android devices and desktop computers.

ResizableHeight Plugin Screenshot

Support the Author

If you find this plugin useful, consider supporting the author to create and maintain more open-source projects. Every contribution, however big or small, is very valuable.

Support with PayPal

Prerequisites

Before you begin, ensure you have the following dependencies installed:

Install them using npm:

npm install --save @ckeditor/ckeditor5-core

Features

  • Dynamically adjust the height of the CKEditor instance for custom editing.
  • Adds the ability to resize the editor.
  • Set specific height options or let the plugin determine the height based on the content.
  • Seamless integration with CKEditor 5.

Installation

  1. Using npm:

    npm install @pikulinpw/ckeditor5-resizableheight
  2. Manual Installation:

    • Clone or download this repository.
    • Add it to your CKEditor 5 build using the standard Webpack module imports.

Usage

  1. Add 'ResizableHeight' to your editor's plugin list:
import ResizableHeight from '@pikulinpw/ckeditor5-resizableheight';

ClassicEditor
    .create(document.querySelector('#editor'), {
        plugins: [ ..., ResizableHeight, ...],
        toolbar: [ ..., ...]
    })
    .then(editor => {
        console.log(editor);
    })
    .catch(error => {
        console.error(error.stack);
    });

Configuration

The ResizableHeight plugin provides several configuration options to customize the editor's behavior. You can specify these options either in the CKEditor configuration object or directly through HTML attributes on the editor's element.

Using CKEditor Configuration:

  • resize: A boolean value that determines whether the editor should be resizable. Default is true.
  • height: Specifies the initial height of the editor. It can be any valid CSS height value.
  • minHeight: Specifies the minimum height to which the editor can be resized. It can be any valid CSS height value.
  • maxHeight: Specifies the maximum height to which the editor can be resized. It can be any valid CSS height value.
import ResizableHeight from '@pikulinpw/ckeditor5-resizableheight';

ClassicEditor
    .create(document.querySelector('#editor'), {
        plugins: [ ..., ResizableHeight, ...],
        ResizableHeight: {
            resize: false,
            height: '500px',
            minHeight: '100px',
            maxHeight: '1000px'
        }
    })
    .then(editor => {
        console.log(editor);
    })
    .catch(error => {
        console.error(error.stack);
    });

Using HTML Attributes:

You can also set the height, minimum height, and maximum height using the data-height, data-minheight, and data-maxheight attributes respectively on the editor's HTML element:

<div id="editor" data-height="500px" data-minheight="100px" data-maxheight="1000px">...</div>

By using these attributes, you can define the height and its constraints directly in the HTML, without modifying the JavaScript configuration.

Customization

You can customize the appearance and behavior of the ResizableHeight plugin by tweaking the source code. All the necessary files (including styles) are available in the source code.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Feedback and Contributions

Feedback, bug reports, and pull requests are welcome. Feel free to open an issue or submit a pull request if you have something to contribute.