Search by

odiseoteam / sylius-banner-plugin

odiseo

This plugin add banners to your Sylius project

Package info

github.com/odiseoteam/SyliusBannerPlugin

Type:sylius-plugin

pkg:composer/odiseoteam/sylius-banner-plugin

Statistics

Installs: 106 639

Dependents: 0

Suggesters: 0

Stars: 19

Open Issues: 5


README

Odiseo Sylius Banner Plugin

Version Downloads Build status Sylius versions PHP version License

Introduction

This plugin adds banners to your Sylius store. Each banner has its own image, copy and link, and is fully customizable from the admin.

What makes this plugin different?

  • ✅ Translatable banners - Each locale has its own image, texts, button and link
  • ✅ A separate mobile image - Upload a second image and it replaces the main one on small screens
  • ✅ Per channel - Enable each banner on the channels you want
  • ✅ Homepage or taxons - A banner goes on the homepage, or on the product list of the taxons you assign it to
  • ✅ Slider included - A single banner renders as an image, several as a Swiper.js slider
  • ✅ Optimized images - Rendered through LiipImagine as WebP by default, with configurable quality
  • ✅ Sortable - A position field, editable from the admin, sets the order
  • ✅ API included - Manage the banners and read them from a headless storefront through the Sylius API
Screenshots

Banners on the shop homepage

The banner of a taxon above its products
Taxons: A banner above the products of each taxon
Banners in the admin
Admin: A Banners section under Catalog

Editing a banner
Editing: Images, texts and link per locale, with the visibility on the side

Getting Started

Install it in 6 steps ⚡

  1. ✅ Require the plugin
  2. ✅ Add Swiper
  3. ✅ Import and build the assets
  4. ✅ Import the plugin configuration
  5. ✅ Add the shop and admin routes
  6. ✅ Run the migrations

👉 Follow the installation guide

Quick Example

Require the plugin and the slider it uses:

composer require odiseoteam/sylius-banner-plugin
yarn add swiper@^11.2.7

Once the remaining steps are done, a new Banners section shows up under Catalog in the admin panel, and the banner is rendered on the homepage.

How it works

A banner without taxons is shown on the homepage. A banner assigned to taxons is shown only on the product list of those taxons, and a taxon without banners of its own shows the ones of its closest parent.

Banner Shown on
Without taxons The homepage
With taxons The product list of those taxons, above the products

One banner is rendered as an image, several as a slider, ordered by position.

Learn more about displaying banners →

Documentation

  • 📦 Installation - Six steps, from Composer to the migrations
  • 🖼️ Managing banners - The list and the form of the admin panel
  • 🏠 Displaying banners - Homepage, taxons, components and templates
  • ⚙️ Configuration - Image format and quality, storage and fixtures
  • 🔌 API - The admin and shop endpoints
  • 🧩 Extending - The hooks of the admin form, the entities and the services
  • 🛠️ Development - Test application, test suites and the CI matrix
  • 📝 Changelog - What changed in each release, with the upgrade notes

Compatibility

Sylius PHP Symfony Database
2.0 · 2.1 · 2.2 · 2.3 8.2 · 8.3 · 8.4 6.4 · 7.4 MySQL · PostgreSQL

Sylius 2.3 needs PHP 8.3 or later.

Professional Support

This plugin is maintained by Odiseo. Need help with it, or with any Sylius project?

License

MIT.