Layouts in Drupal 8 @timplunkett Core Developer, Acquia Office of - - PowerPoint PPT Presentation

layouts in drupal 8
SMART_READER_LITE
LIVE PREVIEW

Layouts in Drupal 8 @timplunkett Core Developer, Acquia Office of - - PowerPoint PPT Presentation

The Continuing Saga of Layouts in Drupal 8 @timplunkett Core Developer, Acquia Office of the CTO Drupal 7 Block Can place each block into one region, per theme Each block can have a set of "conditions" Very


slide-1
SLIDE 1

The Continuing Saga of


Layouts in Drupal 8

@timplunkett
 Core Developer, Acquia Office of the CTO

slide-2
SLIDE 2

Drupal 7

slide-3
SLIDE 3

Block

  • Can place each block into one region, per theme
  • Each block can have a set of "conditions"
  • Very little flexibility
  • Single UI for all blocks
slide-4
SLIDE 4

Panels

  • Panels isn't what you think it is!
  • Usually means using Page Manager
  • Creates landing pages
  • Operates with the "Content" region of Block.module
slide-5
SLIDE 5

Context

  • Defines sets of conditions
  • Each condition can have blocks placed in any region
  • Easy to set up, hard to introspect later
slide-6
SLIDE 6

Display Suite

  • Extends the Field UI to allow complete control over field placement
  • Often used in conjunction with Panels
  • Operates with the "Content" region of Block.module
slide-7
SLIDE 7

Panelizer

  • Panels integration for content types
  • "All articles have two columns, events three columns"
  • Also provides per-node customizations
  • Operates with the "Content" region of Block.module
slide-8
SLIDE 8

Panels Everywhere

  • Replaces the Block.module
  • Allows control of the header/footer without interfering with the

main content

slide-9
SLIDE 9

Drupal 8

slide-10
SLIDE 10

Layout API

  • Provides ability to define layouts
  • No UI
  • Used by Panelizer, Page Manager, Display Suite
  • Now in core as Layout API
slide-11
SLIDE 11

Block

  • Can place any block into any number of regions, per theme
  • Still very little flexibility
  • Still single UI for all blocks
  • Regions defined by theme, no Layout API integration
slide-12
SLIDE 12

Panels and friends

  • The "Panels ecosystem" is being worked on as a unit
  • Panels, Page Manager, Panelizer, Panels Everywhere
  • Straight port of functionality
  • Uses the Layout API
slide-13
SLIDE 13

Context

  • Same as it ever was
  • Regions defined by theme, no Layout API integration
slide-14
SLIDE 14

Display Suite

  • First layout module to become stable!
  • Uses the Layout API
slide-15
SLIDE 15

Field Layout


(new core module)

  • Adds Layout API integration for the Field UI
  • Slimmed down version of Display Suite
  • Plans to incorporate more of Panelizer functionality
  • Available in Drupal 8.3.0 as an experimental module
slide-16
SLIDE 16

What should we do next?

slide-17
SLIDE 17

Theme Layout?

  • Replace theme-defined regions with Layout API
  • Only one layout per theme?
  • Conditions to switch layouts?
slide-18
SLIDE 18

Landing Page builder?

  • Allow creation of landing pages, each with own layout
  • Already possible with Panelizer
  • Plans for a core version, targeting 8.5.x
slide-19
SLIDE 19

Full "variant" system?

  • Incorporate the Panels concept of "variants"
  • At what level? Theme, page, content type, field?
slide-20
SLIDE 20

Unify all approaches?

  • Confusing to have many similar systems
  • If multiple are in core, even more confusing!
  • How to unify approaches without making one single confusing

system?

slide-21
SLIDE 21

Mini-Panels!!?!

  • "It's Mini-Panels all the way down"
  • Allow for more dynamic header/footer/sidebars
  • Allow individual systems to opt-in to arbitrary placement
  • Could be a single, cohesive, reusable approach if done correctly
slide-22
SLIDE 22

Blocks vs Fields

  • Fieldable blocks are in core
  • Fields displayed separately in blocks in contrib
  • Make all field displays into blocks?
  • Make all placed blocks into fields?
slide-23
SLIDE 23

What will happen next

slide-24
SLIDE 24

Per-entity overrides

  • "All nodes have a two column layout, but node 5 has three columns"
  • Allows for full editorial control of individual pieces of content
  • Essentially "Panelizer Lite"
slide-25
SLIDE 25

How to help!

Issue tag: Blocks-Layouts Plan issue #2811175 IRC: #drupal-layouts Slack: #layouts in Drupal slack

@timplunkett
 Core Developer, Acquia Office of the CTO

slide-26
SLIDE 26

Join Us for Contribution Sprints

First-Time Sprinter Workshop
 9:00am-12:00pm
 Room: 307-308

#drupalsprints

Friday, April 28, 2017

Mentored Core Sprint
 9:00am-12:00pm
 Room:301-303 General Sprints
 9:00am-6:00pm
 Room:309-310

slide-27
SLIDE 27

THANK YOU! WHAT DID YOU THINK?

Locate this session at the DrupalCon Baltimore website: http://baltimore2017.drupal.org/schedule Take the survey https://www.surveymonkey.com/r/ drupalconbaltimore