breadlesscode/neos-commentable

Last activity on 17 August 2020
  • 3
  • 2
  • 1373
composer require breadlesscode/neos-commentable

Neos CMS plugin for commenting nodes

v1.1.4

Neos CMS plugin for commenting nodes

Version
v1.1.4
Type
neos-plugin
Release Date
Feb 4, 2019, 3:17:19 pm
Source
git
Distribution
zip
Requires
Requires (dev)
None
Suggest
None
Provides
None
Conflicts
None
Replaces
None
e0497fb8b268a96e66477d08f367601784e54f35

Neos comments

Latest Stable Version Downloads License GitHub stars GitHub watchers

A package for Neos CMS for commenting nodes.

Installation

Most of the time you have to make small adjustments to a package (e.g., the configuration in Settings.yaml). Because of that, it is important to add the corresponding package to the composer from your theme package. Mostly this is the site package located under Packages/Sites/. To install it correctly go to your theme package (e.g.Packages/Sites/Foo.Bar) and run following command:

composer require breadlesscode/neos-commentable --no-update

The --no-update command prevent the automatic update of the dependencies. After the package was added to your theme composer.json, go back to the root of the Neos installation and run composer update. Your desired package is now installed correctly.

Usage

1. Extend your document

You have to add the mixin Breadlesscode.Commentable:Mixin.Commentable to your commentable node. This mixin in simply adds a child node where the comments are stored.

2. Render the comments

Now you can add a the Breadlesscode.Commentable:Collection.Comment Fusion-Prototype to your node. This is a simple Neos.Neos:ContentCollection which lists the comments.

3. Add the form

This Package provides a simple form implementation Breadlesscode.Commentable:Form.Comment. This form adds the comment to the current document node comment collection. You can simply add a finisher by extend the Fusion-Prototype:

prototype(Breadlesscode.Commentable:Form.Comment) {
    finishers {
        sayThankYou = Neos.Form.Builder:FlashMessageFinisher.Definition {
            options {
                messageTitle = 'Thank you!'
                messageBody = 'Thanks for your comment'
            }
        }
    }
}

If you want to use your own Form implementation, you should add the correct finisher Breadlesscode.Commentable:From.Finisher.AddComment.

Configuration

Breadlesscode:
  Commentable:
    # should the comment be added to the top?
    addToTop: true
    # should comments be hidden by default
    hidden: true

License

The MIT License (MIT). Please see License File for more information.

The content of the readme is provided by Github
The same vendor provides 9 package(s).