heart-bits/contao-article-backgrounds-bundle 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

heart-bits/contao-article-backgrounds-bundle

最新稳定版本:2.0.1

Composer 安装命令:

composer require heart-bits/contao-article-backgrounds-bundle

包简介

Article backgrounds/Helper extension for Contao Open Source CMS

README 文档

README

This contao extension allows the backend user to set an individual background-image on every article and even add a colored article separator.

The separator/polygon can be added via a file under templates/polygons/polygon-[polygon_style].php. [polygon_style] is referring to the translation array, which at the moment includes "top", "right", "bottom", "left" and "cross". The selected color can also be picked up in the polygon templates via <?= \Input::get('color') ?>. This way e.g. an svg can easily be colored through the backend.

The extension does not deliver any CSS! So the positioning has to be done manually (See example below).

.mod_article {
    position: relative;
}

.mod_article > .article-image {
   position: absolute;
   z-index: 1;
   top: 0;
   left: 0;
   width: 100%;
   height: 100%;
   overflow: hidden
}

.mod_article > .inside {
   position: relative;
   z-index: 3;
}

.mod_article > .article-image.float-right {
   left: auto;
   right: 0;
   width: 50%
}

.mod_article > .article-image.float-left {
   left: 0;
   width: 50%
}

.mod_article > .article-image .image_container,
.mod_article > .article-image picture {
   position: absolute;
   top: 0;
   left: 0;
   width: 100%;
   height: 100%
}

.mod_article > .article-image .image_container img,
.mod_article > .article-image picture img {
   position: absolute;
   top: 50%;
   left: 50%;
   max-width: none;
   min-width: 100%;
   min-height: 100%;
   width: auto;
   height: auto;
   -webkit-transform: translate(-50%, -50%);
   transform: translate(-50%, -50%)
}

统计信息

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

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 2
  • 开发语言: PHP

其他信息

  • 授权协议: LGPL-3.0
  • 更新时间: 2019-09-10