shel/neos-hyphens
Composer 安装命令:
composer require shel/neos-hyphens
包简介
A plugin for Neos CMS which provides hyphens for the inline editor
README 文档
README
Introduction
This package provides a button to insert soft hyphens and non-breaking spaces for the inline editor in Neos CMS.
Many browsers support some kind of hyphenation via CSS, but it doesn't work reliably on all systems and not with all languages. See the CanIuse table for details.
Therefore this package provides a manual way to insert them. You should be careful with using the CSS-based hyphenation in combination with the manual hyphens as results can be unexpected.
It's compatible with Neos CMS 4.3, 5, 7 and 8 but only the active Neos LTS versions receive new bug fixes.
Example
In the backend, this plugin will add the option to add soft hyphens. They will look like this while editing:
And in the frontend will convert this:
Into this:
And in action:
Advantages
- Your editors gain control over word breaks.
- Stores the special character in the database with their UTF8 representation, which the browser interprets as
­. - You don't need other characters which you replace with correct characters in the frontend.
- Should work fine with Elasticsearch and other search engines.
Planned features
Installation
Run this in your site package
composer require --no-update shel/neos-hyphens
Then run composer update in your project directory.
How to use
Hyphen
Enable it for a node with editable text like this:
'Neos.NodeTypes:Text': properties: text: ui: inline: editorOptions: hyphens: true
This will add a new button to insert a soft hyphen. As an alternative, you can use the shortcut Ctrl + Shift + - to add a new soft hyphen. To change the shortcut keys, have a look at the Settings.yaml file.
Non-breaking space
Enable it for a node with editable text like this:
'Neos.NodeTypes:Text': properties: text: ui: inline: editorOptions: nbsp: true
This will add a new button to insert a non-breaking space.
Customization
Hyphen & non-breaking space styling in the backend
You can provide your own styling by referencing your own stylesheet.
See the file Override.Page.fusion on how the default styling is included.
You can either override the configuration from your own package and just use your stylesheet or you can add yours and use both.
Contributions
Contributions are very welcome!
Please create detailed issues and PRs.
If you use this package and want to support or speed up it's development, get in touch with me.
Or you can also support me directly via patreon.
License
See License
shel/neos-hyphens 适用场景与选型建议
shel/neos-hyphens 是一款 基于 JavaScript 开发的 Composer 扩展包,目前已累计 212.05k 次下载、GitHub Stars 达 21, 最近一次更新时间为 2019 年 05 月 22 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「flow」 「editor」 「CKEditor」 「Neos」 「neoscms」 「hyphens」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 shel/neos-hyphens 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 shel/neos-hyphens 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 shel/neos-hyphens 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Put images nicley in a row
The file manager intended for using Laravel with CKEditor / TinyMCE / Colorbox
Create link to static resources with cache-breaking segment based on md5 of the file
Adds more BBCode
This nova package allows you to use CKEditor 4 for text areas.
getting and sending flow
统计信息
- 总下载量: 212.05k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 21
- 点击次数: 20
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0
- 更新时间: 2019-05-22



