PHPackages                             manuxi/sulu-article-configuration-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. manuxi/sulu-article-configuration-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

manuxi/sulu-article-configuration-bundle
========================================

Bundle for extended Article Configuration in Sulu

v1.1.0(5mo ago)10MITPHPPHP ^8.2CI passing

Since Jan 19Pushed 5mo agoCompare

[ Source](https://github.com/manuxi/SuluArticleConfigurationBundle)[ Packagist](https://packagist.org/packages/manuxi/sulu-article-configuration-bundle)[ RSS](/packages/manuxi-sulu-article-configuration-bundle/feed)WikiDiscussions main Synced today

READMEChangelog (1)Dependencies (9)Versions (3)Used By (0)

SuluArticleConfigurationBundle
==============================

[](#suluarticleconfigurationbundle)

[![php workflow](https://github.com/manuxi/SuluArticleConfigurationBundle/actions/workflows/php.yml/badge.svg)](https://github.com/manuxi/SuluArticleConfigurationBundle/actions/workflows/php.yml/badge.svg)[![symfony workflow](https://github.com/manuxi/SuluArticleConfigurationBundle/actions/workflows/symfony.yml/badge.svg)](https://github.com/manuxi/SuluArticleConfigurationBundle/actions/workflows/symfony.yml/badge.svg)[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://github.com/manuxi/SuluArticleConfigurationBundle/LICENSE)[![GitHub Tag](https://camo.githubusercontent.com/5cf17354c909479f7a9ae1920bfe0fcf2bb8af3b81b0b16b0045b1da8256ca4f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f6d616e7578692f53756c7541727469636c65436f6e66696775726174696f6e42756e646c65)](https://camo.githubusercontent.com/5cf17354c909479f7a9ae1920bfe0fcf2bb8af3b81b0b16b0045b1da8256ca4f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f6d616e7578692f53756c7541727469636c65436f6e66696775726174696f6e42756e646c65)[![Supports Sulu 3.0 or later](https://camo.githubusercontent.com/ad44793d91ed102decfbfdbef6ce8b883b8b3dfa0db9c265719bfa2590310882/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f25323053756c752d2533453d332e302d3030383863633f636f6c6f723d303062326466)](https://camo.githubusercontent.com/ad44793d91ed102decfbfdbef6ce8b883b8b3dfa0db9c265719bfa2590310882/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f25323053756c752d2533453d332e302d3030383863633f636f6c6f723d303062326466)

[🇩🇪 German Version](README.de.md)

The **SuluArticleConfigurationBundle** extends Sulu 3.0 Articles with a comprehensive "Configuration" tab. It allows managing additional display options, features, and publication settings directly on the article.

[![img.png](docs/img/overview.png)](docs/img/overview.png)

✨ Features
----------

[](#-features)

### 📋 Display Options

[](#-display-options)

- **Layout Style** - Choose between Default, Wide, Full Width, or Narrow (Reading Mode)
- **Sidebar** - Enable/disable sidebar and set position (Left/Right)
- **Show Elements** - Table of Contents (TOC), Reading Time, Author Box, Related Articles

### ⚙️ Functions &amp; Features

[](#️-functions--features)

- **Interactions** - Comments, Share Buttons
- **Tools** - Print Function, PDF Download

### 🚀 Publication Settings

[](#-publication-settings)

- **Highlighting** - "Featured" (for sliders/teasers)
- **List Behavior** - "Sticky" (fixed at top) or "Hide from Lists" (accessible via direct link only)
- **Metadata** - Hide Publish Date

### 🎨 Styling &amp; Advanced

[](#-styling--advanced)

- **Design** - Header background and text color, Custom CSS classes
- **Technical** - Custom Template assignment, Cache Lifetime, Custom JSON Data

### 🔄 Default-Configuration

[](#-default-configuration)

- **Inheritance System** - Set a configuration as default for all articles of the same template key
- **3-Tier Cascade** - Article-specific → Template key specific → default values
- **Automatic Template Detection** - The template key is automatically detected and stored

📋 Prerequisites
---------------

[](#-prerequisites)

- PHP 8.2 or higher
- Sulu CMS 3.0 or higher

👩🏻‍🏭 Installation
-----------------

[](#‍-installation)

### Step 1: Install the package

[](#step-1-install-the-package)

Add the repository to your `composer.json` (if local) or install directly:

```
composer require manuxi/sulu-article-configuration-bundle
```

If you are *not* using Symfony Flex, add the bundle to `config/bundles.php`:

```
return [
    //...
    Manuxi\SuluArticleConfigurationBundle\SuluArticleConfigurationBundle::class => ['all' => true],
];
```

### Step 2: Configure routes

[](#step-2-configure-routes)

Add the following to `config/routes.yaml` to load the Admin API routes:

```
sulu_article_configuration_api:
    resource: '@SuluArticleConfigurationBundle/Resources/config/routes_admin.yaml'
```

### Step 3: Update the database

[](#step-3-update-the-database)

Create the required `ar_article_configuration` table:

```
# Check what will be created
php bin/console doctrine:schema:update --dump-sql

# Execute migration
php bin/console doctrine:schema:update --force
```

🎣 Usage
-------

[](#-usage)

### Admin Interface

[](#admin-interface)

1. Navigate to **Articles** in the Sulu admin navigation.
2. Open an existing article or create a new one.
3. Click on the **Configuration** tab.
4. Select the desired options (e.g., "Enable Sidebar", "Layout Style").
5. Save the config.

### Template Defaults

[](#template-defaults)

You can set a configuration as default for all articles with the same template:

1. Open an article with the desired template (e.g., "Blog Post").
2. Go to the **Configuration** tab.
3. Configure all settings as desired.
4. Enable **"Use as default"** in the "Default Configuration" section.
5. Save the config.

Now all other articles with this template will automatically use these settings - unless they have their own configuration.

**How the cascade works:**

```
1. Article has own configuration? → Use it
2. Default config for that template exists? → Use it
3. Neither? → Use default values

```

### Frontend Usage (Twig)

[](#frontend-usage-twig)

The bundle provides a Twig function to access the resolved configuration in your twig templates:

```
{# Get configuration #}
{% set articleConfig = article_configuration(uuid, template) %}

{# Or use shortcut/alias #}
{% set articleConfig = article_config(uuid, template) %}

{# Use the configuration values #}

    {% if articleConfig.showReadingTime %}
        {{ reading_time }} min read
    {% endif %}

    {% if articleConfig.showToc %}

            {# ... TOC content ... #}

    {% endif %}

        {{ content|raw }}

    {% if articleConfig.showAuthorBox %}

            {# ... Author info ... #}

    {% endif %}

    {% if articleConfig.showRelated %}

            {# ... Related articles ... #}

    {% endif %}

    {% if articleConfig.enableShareButtons %}

            {# ... Share buttons ... #}

    {% endif %}

{# Check where the config came from #}
{% if articleConfig.configSource == 'template_default' %}

{% endif %}
```

**Available configuration values:**

PropertyTypeDefaultDescription`layoutStyle`string`'default'``default`, `wide`, `fullwidth`, `narrow``enableSidebar`bool`true`Show sidebar`sidebarPosition`string`'right'``left`, `right``showToc`bool`true`Show table of contents`showReadingTime`bool`true`Show reading time`showAuthorBox`bool`true`Show author box`showRelated`bool`true`Show related articles`enableComments`bool`false`Enable comments`enableShareButtons`bool`true`Show share buttons`enablePrint`bool`true`Show print button`enableDownloadPdf`bool`false`Show PDF download`isFeatured`bool`false`Featured article`isSticky`bool`false`Sticky in lists`hideFromLists`bool`false`Hide from lists`hidePublishDate`bool`false`Hide publish date`customCssClass`string`null`Custom CSS class`headerBgColor`string`null`Header background color`headerTextColor`string`'auto'``auto`, `light`, `dark``customTemplate`string`null`Custom template path`cacheLifetime`int`86400`Cache lifetime in seconds`customData`string`null`Custom JSON data`configSource`string-`article`, `template_default`, `hardcoded`**Example: Conditional sidebar layout**

```
{% set articleConfig = article_config(uuid, template) %}

    {% if articleConfig.enableSidebar %}

            {% if articleConfig.showToc %}
                {{ render_toc(content) }}
            {% endif %}

    {% endif %}

        {{ content|raw }}

```

**Example: Custom header styling**

```
{% set config = article_configuration(article.id, article.templateKey) %}

    {{ article.title }}

```

🗄️ Database Schema
------------------

[](#️-database-schema)

The bundle creates the following table:

```
CREATE TABLE ar_article_configuration (
    id INT AUTO_INCREMENT PRIMARY KEY,
    article_id VARCHAR(36) UNIQUE NOT NULL,
    template_key VARCHAR(128) DEFAULT NULL,
    is_default TINYINT(1) DEFAULT 0 NOT NULL,
    layout_style VARCHAR(32) DEFAULT 'default' NOT NULL,
    enable_sidebar TINYINT(1) DEFAULT 1 NOT NULL,
    sidebar_position VARCHAR(16) DEFAULT 'right' NOT NULL,
    show_toc TINYINT(1) DEFAULT 1 NOT NULL,
    show_reading_time TINYINT(1) DEFAULT 1 NOT NULL,
    show_author_box TINYINT(1) DEFAULT 1 NOT NULL,
    show_related TINYINT(1) DEFAULT 1 NOT NULL,
    enable_comments TINYINT(1) DEFAULT 0 NOT NULL,
    enable_share_buttons TINYINT(1) DEFAULT 1 NOT NULL,
    enable_print TINYINT(1) DEFAULT 1 NOT NULL,
    enable_download_pdf TINYINT(1) DEFAULT 0 NOT NULL,
    is_featured TINYINT(1) DEFAULT 0 NOT NULL,
    is_sticky TINYINT(1) DEFAULT 0 NOT NULL,
    hide_from_lists TINYINT(1) DEFAULT 0 NOT NULL,
    hide_publish_date TINYINT(1) DEFAULT 0 NOT NULL,
    custom_css_class VARCHAR(128) DEFAULT NULL,
    header_bg_color VARCHAR(32) DEFAULT NULL,
    header_text_color VARCHAR(16) DEFAULT 'auto' NOT NULL,
    custom_template VARCHAR(255) DEFAULT NULL,
    cache_lifetime INT DEFAULT 86400 NOT NULL,
    custom_data LONGTEXT DEFAULT NULL,
    INDEX idx_template_default (template_key, is_default)
);
```

🧪 Testing
---------

[](#-testing)

```
composer test
```

📄 License
---------

[](#-license)

This bundle is under the MIT license. See the complete license in the bundle: [LICENSE](LICENSE)

👤 Author
--------

[](#-author)

**Manuel Bertrams**

- GitHub: [@manuxi](https://github.com/manuxi)

###  Health Score

34

—

LowBetter than 75% of packages

Maintenance71

Regular maintenance activity

Popularity2

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

164d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8ce067feaa3f9ece08d78385c401aab7d72e9e8ee64d77d584f884b6725ad9de?d=identicon)[manuxi](/maintainers/manuxi)

---

Top Contributors

[![manuxi](https://avatars.githubusercontent.com/u/11303615?v=4)](https://github.com/manuxi "manuxi (10 commits)")

---

Tags

article-bundledisplay-settingslayout-settingssulu-30sulu-bundlesulu-cmsconfigurationarticlesulusulucms

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/manuxi-sulu-article-configuration-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/manuxi-sulu-article-configuration-bundle/health.svg)](https://phpackages.com/packages/manuxi-sulu-article-configuration-bundle)
```

###  Alternatives

[sulu/skeleton

Project template for starting your new project based on the Sulu content management system

29735.5k](/packages/sulu-skeleton)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.4M203](/packages/sulu-sulu)[rcsofttech/audit-trail-bundle

Enterprise-grade, high-performance Symfony audit trail bundle. Automatically track Doctrine entity changes with split-phase architecture, multiple transports (HTTP, Queue, Doctrine), and sensitive data masking.

1189.8k](/packages/rcsofttech-audit-trail-bundle)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
