Commit bc0e16cb authored by Gábor Hojtsy's avatar Gábor Hojtsy

Issue #2982781 by kjay, John Cook, markconroy, smaz: Support display setting...

Issue #2982781 by kjay, John Cook, markconroy, smaz: Support display setting changes in Demo Umami's card view modes

(cherry picked from commit 12215774)
parent fe48728b
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_top
- core.entity_view_mode.node.card
- field.field.node.article.body
- field.field.node.article.field_image
- field.field.node.article.field_tags
......@@ -11,10 +11,10 @@ dependencies:
module:
- responsive_image
- user
id: node.article.highlighted_top
id: node.article.card
targetEntityType: node
bundle: article
mode: highlighted_top
mode: card
content:
field_image:
type: responsive_image
......@@ -22,7 +22,7 @@ content:
region: content
settings:
responsive_image_style: 3_2_image
image_link: content
image_link: ''
third_party_settings: { }
label: hidden
hidden:
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_small
- core.entity_view_mode.node.card_common
- field.field.node.article.body
- field.field.node.article.field_image
- field.field.node.article.field_tags
......@@ -11,10 +11,10 @@ dependencies:
module:
- responsive_image
- user
id: node.article.highlighted_small
id: node.article.card_common
targetEntityType: node
bundle: article
mode: highlighted_small
mode: card_common
content:
field_image:
type: responsive_image
......@@ -22,7 +22,7 @@ content:
region: content
settings:
responsive_image_style: 3_2_image
image_link: content
image_link: ''
third_party_settings: { }
label: hidden
hidden:
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_medium
- core.entity_view_mode.node.card_common_alt
- field.field.node.article.body
- field.field.node.article.field_image
- field.field.node.article.field_tags
......@@ -11,10 +11,10 @@ dependencies:
module:
- responsive_image
- user
id: node.article.highlighted_medium
id: node.article.card_common_alt
targetEntityType: node
bundle: article
mode: highlighted_medium
mode: card_common_alt
content:
field_image:
type: responsive_image
......@@ -22,7 +22,7 @@ content:
region: content
settings:
responsive_image_style: square
image_link: content
image_link: ''
third_party_settings: { }
label: hidden
hidden:
......
langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_bottom
- field.field.node.article.body
- field.field.node.article.field_image
- field.field.node.article.field_tags
- node.type.article
- responsive_image.styles.3_2_image
module:
- responsive_image
- user
id: node.article.highlighted_bottom
targetEntityType: node
bundle: article
mode: highlighted_bottom
content:
field_image:
type: responsive_image
weight: 0
region: content
settings:
responsive_image_style: 3_2_image
image_link: content
third_party_settings: { }
label: hidden
hidden:
body: true
content_moderation_control: true
field_tags: true
links: true
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_small
- core.entity_view_mode.node.card
- field.field.node.recipe.field_author
- field.field.node.recipe.field_cooking_time
- field.field.node.recipe.field_difficulty
......@@ -20,32 +20,27 @@ dependencies:
- options
- responsive_image
- user
id: node.recipe.highlighted_small
id: node.recipe.card
targetEntityType: node
bundle: recipe
mode: highlighted_small
mode: card
content:
field_difficulty:
weight: 1
label: above
weight: 0
label: inline
settings: { }
third_party_settings: { }
type: list_default
region: content
field_image:
weight: 0
weight: 1
label: hidden
settings:
responsive_image_style: 3_2_image
image_link: content
image_link: ''
third_party_settings: { }
type: responsive_image
region: content
links:
weight: 2
region: content
settings: { }
third_party_settings: { }
hidden:
content_moderation_control: true
field_author: true
......@@ -57,3 +52,4 @@ hidden:
field_recipe_instruction: true
field_summary: true
field_tags: true
links: true
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_top
- core.entity_view_mode.node.card_common
- field.field.node.recipe.field_author
- field.field.node.recipe.field_cooking_time
- field.field.node.recipe.field_difficulty
......@@ -19,20 +19,20 @@ dependencies:
module:
- responsive_image
- user
id: node.recipe.highlighted_top
id: node.recipe.card_common
targetEntityType: node
bundle: recipe
mode: highlighted_top
mode: card_common
content:
field_image:
type: responsive_image
weight: 0
region: content
label: hidden
settings:
responsive_image_style: 3_2_image
image_link: content
image_link: ''
third_party_settings: { }
type: responsive_image
region: content
hidden:
content_moderation_control: true
field_author: true
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_bottom
- core.entity_view_mode.node.card_common_alt
- field.field.node.recipe.field_author
- field.field.node.recipe.field_cooking_time
- field.field.node.recipe.field_difficulty
......@@ -15,21 +15,21 @@ dependencies:
- field.field.node.recipe.field_summary
- field.field.node.recipe.field_tags
- node.type.recipe
- responsive_image.styles.3_2_image
- responsive_image.styles.square
module:
- responsive_image
- user
id: node.recipe.highlighted_bottom
id: node.recipe.card_common_alt
targetEntityType: node
bundle: recipe
mode: highlighted_bottom
mode: card_common_alt
content:
field_image:
weight: 0
label: hidden
settings:
responsive_image_style: 3_2_image
image_link: content
responsive_image_style: square
image_link: ''
third_party_settings: { }
type: responsive_image
region: content
......
langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_medium
- field.field.node.recipe.field_author
- field.field.node.recipe.field_cooking_time
- field.field.node.recipe.field_difficulty
- field.field.node.recipe.field_image
- field.field.node.recipe.field_ingredients
- field.field.node.recipe.field_number_of_servings
- field.field.node.recipe.field_preparation_time
- field.field.node.recipe.field_recipe_category
- field.field.node.recipe.field_recipe_instruction
- field.field.node.recipe.field_summary
- field.field.node.recipe.field_tags
- node.type.recipe
- responsive_image.styles.square
module:
- options
- responsive_image
- user
id: node.recipe.highlighted_medium
targetEntityType: node
bundle: recipe
mode: highlighted_medium
content:
field_difficulty:
weight: 1
label: above
settings: { }
third_party_settings: { }
type: list_default
region: content
field_image:
weight: 0
label: hidden
settings:
responsive_image_style: square
image_link: content
third_party_settings: { }
type: responsive_image
region: content
links:
weight: 2
region: content
settings: { }
third_party_settings: { }
hidden:
content_moderation_control: true
field_author: true
field_cooking_time: true
field_ingredients: true
field_number_of_servings: true
field_preparation_time: true
field_recipe_category: true
field_recipe_instruction: true
field_summary: true
field_tags: true
......@@ -3,7 +3,7 @@ status: true
dependencies:
module:
- node
id: node.highlighted_top
label: 'Highlighted Top'
id: node.card
label: Card
targetEntityType: node
cache: true
......@@ -3,7 +3,7 @@ status: true
dependencies:
module:
- node
id: node.highlighted_small
label: 'Highlighted Small'
id: node.card_common
label: 'Card common'
targetEntityType: node
cache: true
......@@ -3,7 +3,7 @@ status: true
dependencies:
module:
- node
id: node.highlighted_bottom
label: 'Highlighted Bottom'
id: node.card_common_alt
label: 'Card common alt'
targetEntityType: node
cache: true
langcode: en
status: true
dependencies:
module:
- node
id: node.highlighted_medium
label: 'Highlighted Medium'
targetEntityType: node
cache: true
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_small
- core.entity_view_mode.node.card
- node.type.article
module:
- node
......@@ -58,7 +58,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_small
view_mode: card
fields:
title:
id: title
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_small
- core.entity_view_mode.node.card
- node.type.article
- system.menu.main
module:
......@@ -72,7 +72,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_small
view_mode: card
fields:
title:
id: title
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_bottom
- core.entity_view_mode.node.card_common
- core.entity_view_mode.node.rss
- node.type.recipe
module:
......@@ -218,7 +218,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_bottom
view_mode: card_common
sorts:
sticky:
admin_label: ''
......
......@@ -2,8 +2,8 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_medium
- core.entity_view_mode.node.highlighted_top
- core.entity_view_mode.node.card_common
- core.entity_view_mode.node.card_common_alt
- node.type.article
- node.type.recipe
module:
......@@ -60,7 +60,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_top
view_mode: card_common
fields:
title:
id: title
......@@ -254,7 +254,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_medium
view_mode: card_common_alt
pager:
type: some
options:
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_small
- core.entity_view_mode.node.card
- node.type.recipe
- system.menu.main
module:
......@@ -72,7 +72,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_small
view_mode: card
fields:
title:
id: title
......
......@@ -2,7 +2,7 @@ langcode: en
status: true
dependencies:
config:
- core.entity_view_mode.node.highlighted_small
- core.entity_view_mode.node.card
module:
- node
- taxonomy
......@@ -221,7 +221,7 @@ display:
type: 'entity:node'
options:
relationship: none
view_mode: highlighted_small
view_mode: card
header:
entity_taxonomy_term:
id: entity_taxonomy_term
......
/**
* @file
* This file is used to style the 'Card common alt' view mode.
*/
.node--view-mode-card-common-alt .node__content {
order: -1;
}
/**
* @file
* This file is used to style the 'Card common' view mode.
*/
.node--view-mode-card-common .read-more {
margin-bottom: 1em;
}
/**
* @file
* This file is used to style the 'Card' view mode.
*/
.view-mode-card {
display: flex;
flex-direction: column;
width: 100%;
padding: 1rem;
border: 1px solid #fcece7;
}
.view-mode-card .node__title {
flex-grow: 1;
}
.view-mode-card .field--name-title {
text-decoration: none;
color: #000;
font-size: 1.424rem;
font-weight: 400;
}
.view-mode-card .node__link {
text-decoration: none;
color: #000;
background-color: inherit;
}
.view-mode-card .node__link:focus,
.view-mode-card .node__link:hover {
text-decoration: underline;
color: #000;
}
.view-mode-card .field--name-field-image img {
display: block;
width: 100%;
margin-bottom: 1.2em;
}
.view-mode-card .label-items {
color: #5f635d;
font-size: 0.889rem;
}
/**
* @file
* This file is used to style the 'highlighted-bottom' view mode.
*/
.node--view-mode-highlighted-bottom {
border: 1px solid #fcece7;
width: 100%;
}
.node--view-mode-highlighted-bottom .node__meta {
padding: 1.5rem;
}
.node--view-mode-highlighted-bottom .node__title {
font-weight: 400;
margin-bottom: 1rem;
}
.node--view-mode-highlighted-bottom .field--name-title {
font-family: 'Scope One', Georgia, serif;
font-size: 1.424rem;
font-weight: 400;
}
.node--view-mode-highlighted-bottom .node__title .node__link {
background-color: inherit;
color: #000;
text-decoration: none;
}
.node--view-mode-highlighted-bottom .node__title .node__link:focus,
.node--view-mode-highlighted-bottom .node__title .node__link:hover {
color: #000;
text-decoration: underline;
}
.node--view-mode-highlighted-bottom .node__link .field--name-title {
color: #000;
text-decoration: none;
}
.node--view-mode-highlighted-bottom .field--name-field-image img {
width: 100%;
}
.node--view-mode-highlighted-bottom .field--name-field-difficulty {
color: #5f635d;
font-size: 0.889rem;
margin-bottom: 0.5rem;
}
/**
* @file
* This file is used to style the 'highlighted-medium' view mode.
*/
.node--view-mode-highlighted-medium {
border: 1px solid #fcece7;
width: 100%;
display: flex;
flex-direction: column;
}
.node--view-mode-highlighted-medium .node__content {
flex: 0 0 auto;
}
.node--view-mode-highlighted-medium .node__meta {
padding: 1rem 1.5rem 0 1.5rem;
}
.node--view-mode-highlighted-medium .read-more {
margin-top: auto;
padding: 0 1.5rem 1.5rem 1.5rem;
}
.node--view-mode-highlighted-medium .node__title {
font-weight: 400;
margin-bottom: 1rem;
}
.node--view-mode-highlighted-medium .field--name-title {
font-family: 'Scope One', Georgia, serif;
font-size: 1.424rem;
font-weight: 400;
}
.node--view-mode-highlighted-medium .node__title .node__link {
color: #000;
text-decoration: none;
background-color: inherit;
}
.node--view-mode-highlighted-medium .node__title .node__link:focus,
.node--view-mode-highlighted-medium .node__title .node__link:hover {
color: #000;
text-decoration: underline;
}
.node--view-mode-highlighted-medium .node__link .field--name-title {
color: #000;
text-decoration: none;
}
.node--view-mode-highlighted-medium .field--name-field-image img {
display: block;
width: 100%;
}
.node--view-mode-highlighted-medium .field--name-field-difficulty {
color: #5f635d;
font-size: 0.889rem;
margin-bottom: 0.5rem;
}
/**
* @file
* This file is used to style the 'highlighted-small' view mode.
*/
.node--view-mode-highlighted-small {
border: 1px solid #fcece7;
width: 100%;
display: flex;
flex-direction: column;
}
.node--view-mode-highlighted-small .node__content {
flex: 0 0 auto;
}
.node--view-mode-highlighted-small .node__meta {
padding: 1rem 1.5rem 0 1.5rem;
}
.node--view-mode-highlighted-small .read-more {
margin-top: auto;
padding: 0 1.5rem 1.5rem 1.5rem;
}
.node--view-mode-highlighted-small .node__title {
font-weight: 400;
margin-bottom: 1rem;