定制 bigfork/htmleditorsrcset 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

bigfork/htmleditorsrcset

Composer 安装命令:

composer require bigfork/htmleditorsrcset

包简介

Simple srcset integration with SilverStripe’s HTMLEditorField

README 文档

README

Simple srcset integration with SilverStripe’s HTMLEditorField.

What it does

Adds a srcset attribute for the provided pixel densities to every image inserted through TinyMCE. Resulting in an image tag like:

<img width="100" height="50" src="assets/530dffc7f9/image__ResizedImageWzE5OCwxMzJd.jpg"
    srcset="assets/530dffc7f9/image__ResizedImageWzE5OCwxMzJd.jpg 1x, assets/530dffc7f9/image__ResizedImageWzM5NiwyNjRd.jpg 2x"
/>

What it doesn’t do

This module doesn’t add a sizes attribute, nor does it specify widths in srcset - only pixel densities.

Specifying your own pixel densities

The module will add sources for 1x and 2x pixel densities by default. You can set your own pixel densities by setting the following in your config.yml:

Bigfork\HTMLEditorSrcset\ImageShortcodeHandler:
  pixel_densities: [1, 2, 3]

统计信息

  • 总下载量: 25.88k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 10
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 10
  • Watchers: 4
  • Forks: 3
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2016-04-13

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固