{"id":13770057,"url":"https://github.com/calumk/editorjs-columns","last_synced_at":"2025-04-06T23:16:10.084Z","repository":{"id":48130576,"uuid":"488765349","full_name":"calumk/editorjs-columns","owner":"calumk","description":null,"archived":false,"fork":false,"pushed_at":"2025-02-26T06:08:46.000Z","size":4006,"stargazers_count":120,"open_issues_count":5,"forks_count":31,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-03-30T22:27:36.412Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/calumk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-05-04T22:54:03.000Z","updated_at":"2025-03-05T08:56:41.000Z","dependencies_parsed_at":"2023-12-04T19:46:05.003Z","dependency_job_id":"cfc15b54-78de-40fd-ac44-2a538f820617","html_url":"https://github.com/calumk/editorjs-columns","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calumk%2Feditorjs-columns","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calumk%2Feditorjs-columns/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calumk%2Feditorjs-columns/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/calumk%2Feditorjs-columns/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/calumk","download_url":"https://codeload.github.com/calumk/editorjs-columns/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247563935,"owners_count":20958971,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T17:00:33.911Z","updated_at":"2025-04-06T23:16:10.051Z","avatar_url":"https://github.com/calumk.png","language":"HTML","funding_links":[],"categories":["Tools"],"sub_categories":["Block Tools"],"readme":"# @calumk/editorjs-Columns\n\nA **BETA** plugin which allows the user to have columns\n\n\u003e Pull requests welcomed!\n\n## Installation\n\n\n\u003e npm i @calumk/editorjs-columns\n\n\n\u003e https://cdn.jsdelivr.net/npm/@calumk/editorjs-columns@latest\n\n\n## Demo\n\n![demo](assets/demo.gif)\n\n## Features \n\n* [x] Support new vertical menu style\n* [x] Save/Load\n* [x] Support for 2 colums\n* [x] Support for 3 columns\n    * [x] Migrate storage to array\n    * [x] Add tool to change type\n    * [x] Added tool to switch/roll arrays\n* [ ] Refactor code for legibility\n* [ ] Tests\n\n\n\n## ChangeLog\n\n\u003e 28/04/23 - Re-added feature - EditorJs must now be passed as instance through tool to child, to avoid duplicate editorjs installs, and ensure only one editor js instance is used.\n\u003e 16/05/22 - Removed global tool varable. Switched to config variable for column tools (see Example)\n\u003e ~~22/05/22 - EditorJs must now be passed as instance through tool to child, to avoid duplicate editorjs installs~~ - Rolled Back \n\n\n# Known Bugs\n* Pressing enter key inside a column, will exit the column \n    * Can be solved (sort-of) by using @calumk/editorjs-paragraph-linebreakable\n* Pressing tab key inside column will launch both column, and parent tools\n* Copy/Pasting can cause duplication of data in the wrong place\n* ~~z-index issues with toolboxes~~\n* ~~Tools are hosted as global var~~\n* ~~All Styling is currently only in the example.html~~\n    * ~~Column styling should move to plugin~~\n    * ~~Opinionaited styling (Borders, rounded corners, hover shaddow) will remain in example.html~~\n* ~~SVG logo is not rendering correctly in new vertical menu~~\n\n\n## Docs\nNone yet, see example/example.html for useage.\n\n\n---\n\n\u003e Note : Tools are passed to editorjs-columns using config.tools property\n\n```javascript\n// first define the tools to be made avaliable in the columns\nlet column_tools = {\n    header: Header,\n    alert : Alert,\n    paragraph : editorjsParagraphLinebreakable,\n    delimiter : Delimiter\n}\n\n// next define the tools in the main block\n// Warning - Dont just use main_tools - you will probably generate a circular reference \nlet main_tools = {\n// Load Official Tools\n    header: Header,\n    alert : Alert,\n    paragraph : editorjsParagraphLinebreakable,\n    delimiter : Delimiter,\n\n    columns : {\n        class : editorjsColumns,\n        config : {\n          EditorJsLibrary : EditorJs, // Pass the library instance to the columns instance.\n          tools : column_tools // IMPORTANT! ref the column_tools\n        }\n      },\n}\n\n\neditor = new EditorJS({\n    tools : main_tools,\n});\n```\n\nYou can also use the i18n feature of Editor.js to change the text of the tools.\n```javascript\ni18n: {\n\tmessages: {\n\t\ttoolNames: {\n\t\t\tColumns: `Columnas`,\n\t\t},\n\t\ttools: {\n\t\t\tcolumns: {\n\t\t\t\t'2 Columns': `Dos columnas`,\n\t\t\t\t'3 Columns': `Tres columnas`, \n\t\t\t\t'Roll Columns': `Rotar columnas`,\n                'Are you sure?': `¿Está seguro?`,\n\t\t\t\t'This will delete Column 3!': `¡Esto eliminará la Columna 3!`,\n\t\t\t\t'Yes, delete it!': `¡Sí, eliminar!`,\n\t\t\t\tCancel: `Cancelar`,\n\t\t\t},\n\t\t},\n\t},\n};\n\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcalumk%2Feditorjs-columns","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcalumk%2Feditorjs-columns","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcalumk%2Feditorjs-columns/lists"}