/silverstripe-elemental-elementals

Bootstrap CSS framework based basics for silverstripe-elemental

Primary LanguagePHPBSD 3-Clause "New" or "Revised" LicenseBSD-3-Clause

Silverstripe Elemental Elementals

🎭 Tests codecov Dependabot phpstan composer Packagist Version

Introduction

Provides a sensible default setup and more for Silverstripe projects built with elemental and bootstrap.

Installation

To install this module, run the following command:

composer require syntro/silverstripe-elemental-elementals

Docs

Title Customization

This module adds title configuration settings to elemental objects. These allow the configuration of

  • title tag
  • title alignment
  • title extra classes

These can be accessed in templates using $TitleTag, $TitleAlignment and $TitleExtraClasses. $TitleAlignment follows the bootstrap conventions and renders as start, center, end. If you want to quickly drop in support, you can use our preset to render the title as follows:

<% if $ShowTitle %>
    <% include ElementTitle %>
<% end_if %>

If you want to disable title editing for a specific element, set the following config:

YourElement:
  allow_title_customization: false

Editor and Content

See 📚 Editor configuration.

Spacing Between Elements

See 📚 Spacing.

Contributing

See CONTRIBUTION.md for mor info.