Skip to content
Snippets Groups Projects
Commit 381ba8f0 authored by Chris Hallberg's avatar Chris Hallberg Committed by Robert Lange
Browse files

Slot View Helper (#1454)


* Slot helper prototype.

- Slot/block system for easier customization.
- Designed to set block values then include parent template (helper coming).
- start/end for buffer capture.
- set for string setting.
- clear for value clearing.

* Add get method to Slot.

* Add Slot method documentation.

* Improve Slot documentation.

* Change syntax to slot('name')->action(). Fix instancing.

* Improve documentation.

* Add examples to slot PR.

* Update documentation.

* checkstyles

* Fix error with slot->get.

* Remove trim so any value type can be saved.

* Add prepend/append methods to slots.

* Move Slots helper to VuFindTheme.

* Add unit tests for Slot helper.

* Clear Slot prepends and appends.

* Space and trim block output.

* checkstyle typo

* Improve documentation of non-string slot values.

* Add method constants.

* Add __invoke(name, val) and __toString shortcuts.

* Clarify prepend/append concatination.

* Slot clear returns old contents.

* Update test to match new clear functionality.

* Remove example

* get() can now return a default.

* Make non-string tests more robust.

* Remove hardcoded string.

* Documentation for get default.

* Apply slots to root templates.

* Add isset.

* Apply slots to bootstrap templates.

* Documentation fix.

* Checkstyles.

* Bugfix: prevent overriding of ''.

* Laminas migration.

* More specific slot name for home page hero.

* Remove 'footer' full footer slot (footer).

* Add tests to cover '' cases.

* Add a few default tests.

Co-authored-by: default avatarDemian Katz <demian.katz@villanova.edu>
parent cc376cb2
No related merge requests found
Showing
with 669 additions and 85 deletions
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment