-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit a37311e
Showing
18 changed files
with
1,210 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
## Simple List | ||
Simplelist module provides set of configurations to create simple list page like drupal.org [FAQ](https://www.drupal.org/about/faq) page. | ||
|
||
### How does it work? | ||
|
||
This module provides snippet **content type** with snippet type **taxonomy vocabulary** to create content in different categories. Using [entityqueue]() module to list/order snippets and [views]() module to expose page. All these content can be easily updated to work with different use-cases. | ||
|
||
### Install | ||
|
||
1. Install module usual. | ||
2. Create term (e.g. FAQ) under [snippet types]() taxonomy | ||
3. Create new [snippet]() nodes | ||
4. Update [view page display]() field with new term created in step 2. | ||
|
||
### Create new page | ||
|
||
Additional pages can be created by: | ||
1. Create new term. | ||
2. Create snippet nodes with new term | ||
3. Create new node queue and add new nodes. | ||
4. copying both page and attachment displays. | ||
5. Update term and node queue details in both displays. | ||
|
||
#### Screenshots | ||
![Simplelist](https://user-images.githubusercontent.com/1220029/34498438-765aeeea-eff9-11e7-896e-7ebc075a354d.gif) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"name": "drupal/simplelist", | ||
"description": "Provides an easy way to build simple FAQ like list pages.", | ||
"type": "drupal-module", | ||
"homepage": "http:https://drupal.org/project/simplelist", | ||
"license": "GPL-2.0+" | ||
} |
81 changes: 81 additions & 0 deletions
81
config/install/core.entity_form_display.node.snippet.default.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.field.node.snippet.body | ||
- field.field.node.snippet.field_snippet_type | ||
- node.type.snippet | ||
module: | ||
- path | ||
- text | ||
id: node.snippet.default | ||
targetEntityType: node | ||
bundle: snippet | ||
mode: default | ||
content: | ||
body: | ||
type: text_textarea_with_summary | ||
weight: 2 | ||
settings: | ||
rows: 9 | ||
summary_rows: 3 | ||
placeholder: '' | ||
third_party_settings: { } | ||
region: content | ||
created: | ||
type: datetime_timestamp | ||
weight: 4 | ||
region: content | ||
settings: { } | ||
third_party_settings: { } | ||
field_snippet_type: | ||
weight: 1 | ||
settings: { } | ||
third_party_settings: { } | ||
type: options_select | ||
region: content | ||
path: | ||
type: path | ||
weight: 7 | ||
region: content | ||
settings: { } | ||
third_party_settings: { } | ||
promote: | ||
type: boolean_checkbox | ||
settings: | ||
display_label: true | ||
weight: 5 | ||
region: content | ||
third_party_settings: { } | ||
status: | ||
type: boolean_checkbox | ||
settings: | ||
display_label: true | ||
weight: 8 | ||
region: content | ||
third_party_settings: { } | ||
sticky: | ||
type: boolean_checkbox | ||
settings: | ||
display_label: true | ||
weight: 6 | ||
region: content | ||
third_party_settings: { } | ||
title: | ||
type: string_textfield | ||
weight: 0 | ||
region: content | ||
settings: | ||
size: 60 | ||
placeholder: '' | ||
third_party_settings: { } | ||
uid: | ||
type: entity_reference_autocomplete | ||
weight: 3 | ||
settings: | ||
match_operator: CONTAINS | ||
size: 60 | ||
placeholder: '' | ||
region: content | ||
third_party_settings: { } | ||
hidden: { } |
34 changes: 34 additions & 0 deletions
34
config/install/core.entity_view_display.node.snippet.default.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.field.node.snippet.body | ||
- field.field.node.snippet.field_snippet_type | ||
- node.type.snippet | ||
module: | ||
- text | ||
- user | ||
id: node.snippet.default | ||
targetEntityType: node | ||
bundle: snippet | ||
mode: default | ||
content: | ||
body: | ||
label: hidden | ||
type: text_default | ||
weight: 101 | ||
settings: { } | ||
third_party_settings: { } | ||
region: content | ||
field_snippet_type: | ||
weight: 102 | ||
label: above | ||
settings: | ||
link: true | ||
third_party_settings: { } | ||
type: entity_reference_label | ||
region: content | ||
links: | ||
weight: 100 | ||
region: content | ||
hidden: { } |
27 changes: 27 additions & 0 deletions
27
config/install/core.entity_view_display.node.snippet.teaser.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- core.entity_view_mode.node.teaser | ||
- field.field.node.snippet.body | ||
- node.type.snippet | ||
module: | ||
- text | ||
- user | ||
id: node.snippet.teaser | ||
targetEntityType: node | ||
bundle: snippet | ||
mode: teaser | ||
content: | ||
body: | ||
label: hidden | ||
type: text_summary_or_trimmed | ||
weight: 101 | ||
settings: | ||
trim_length: 600 | ||
third_party_settings: { } | ||
region: content | ||
links: | ||
weight: 100 | ||
region: content | ||
hidden: { } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
module: | ||
- node | ||
id: faq | ||
label: FAQ | ||
handler: simple | ||
handler_configuration: { } | ||
entity_settings: | ||
target_type: node | ||
handler: 'default:node' | ||
handler_settings: | ||
target_bundles: | ||
snippet: snippet | ||
sort: | ||
field: title | ||
direction: ASC | ||
auto_create: false | ||
auto_create_bundle: '' | ||
queue_settings: | ||
min_size: 0 | ||
max_size: 0 | ||
act_as_queue: false | ||
reverse_in_admin: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.storage.node.body | ||
- node.type.snippet | ||
module: | ||
- text | ||
id: node.snippet.body | ||
field_name: body | ||
entity_type: node | ||
bundle: snippet | ||
label: Body | ||
description: '' | ||
required: false | ||
translatable: true | ||
default_value: { } | ||
default_value_callback: '' | ||
settings: | ||
display_summary: true | ||
field_type: text_with_summary |
32 changes: 32 additions & 0 deletions
32
config/install/field.field.node.snippet.field_snippet_type.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.storage.node.field_snippet_type | ||
- node.type.snippet | ||
- taxonomy.vocabulary.snippet_type | ||
content: | ||
- 'taxonomy_term:snippet_type:0739849e-e0ee-4f86-bb07-97b9c4dff9bc' | ||
id: node.snippet.field_snippet_type | ||
field_name: field_snippet_type | ||
entity_type: node | ||
bundle: snippet | ||
label: Type | ||
description: '' | ||
required: true | ||
translatable: false | ||
default_value: | ||
- | ||
target_uuid: 0739849e-e0ee-4f86-bb07-97b9c4dff9bc | ||
default_value_callback: '' | ||
settings: | ||
handler: 'default:taxonomy_term' | ||
handler_settings: | ||
target_bundles: | ||
snippet_type: snippet_type | ||
sort: | ||
field: name | ||
direction: asc | ||
auto_create: false | ||
auto_create_bundle: '' | ||
field_type: entity_reference |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
module: | ||
- node | ||
- taxonomy | ||
id: node.field_snippet_type | ||
field_name: field_snippet_type | ||
entity_type: node | ||
type: entity_reference | ||
settings: | ||
target_type: taxonomy_term | ||
module: core | ||
locked: false | ||
cardinality: 1 | ||
translatable: true | ||
indexes: { } | ||
persist_with_no_fields: false | ||
custom_storage: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
langcode: en | ||
status: true | ||
dependencies: {} | ||
third_party_settings: {} | ||
name: Snippet | ||
type: snippet | ||
description: 'Simple content type with title and Description for simple list.' | ||
help: '' | ||
new_revision: true | ||
preview_mode: 1 | ||
display_submitted: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
langcode: en | ||
status: true | ||
dependencies: { } | ||
name: 'Snippet types' | ||
vid: snippet_types | ||
description: 'Snippet category' | ||
hierarchy: 0 | ||
weight: 0 |
Oops, something went wrong.