Skip to content

Explore

On this page:

Loading...

Navigate pages, collections, and data on your site.

Explore generates automatically based on your site configuration. Images and titles come from the corresponding file’s front matter.

Screenshot of explore interface with the nav tab focused on Staff Members

Grouping

CloudCannon splits your collections, pages, and data into groups. Customize these groups to tailor the editing experience to your site. Reorder, hide, group or display items differently with the following options.

These options are set in _config.yml on the top level and affect the Explore section navigation.

_explore.groups defines the groups shown in the Explore navigation.

_config.yml
_explore:
  groups:
    - heading: Blogging
      collections:
        - posts
        - drafts
    - heading: Other
      collections:
        - pages
        - staff
        - features

Collections

These options are set in _config.yml inside specific collection metadata and affect the item lists within each Explore group.

_sort_key

String

Must match a front matter field of the collection items. Sets the sorting of the collection inside Explore.

_subtext_key

String

Must match a front matter field of the collection items.

Defines a front matter field to use when displaying subtext on an item.

_image_key

String

Must match a front matter field of the collection items.

Defines a front matter field to use when displaying an image on an item.

_image_size

String, one of cover or contain.

Sets how images are displayed in the list.

_singular_name

String

Overrides the default singular display name of the collection.

_singular_key

String

Overrides the default singular input key of the collection.

_disable_add

Boolean

Prevents users from adding new collection items. Default is false

_icon

String

Must match Material Icon name.

Overrides the default collection icon with an icon from Google’s Material Icons.

_add_options

Array of objects

Changes the options presented in the ‘add dropdown’ menu list.

Example usage:

_config.yml
collections:
  staff:
    output: true
    _sort_key: surname
    _subtext_key: role
    _image_key: profile_image
    _image_size: cover
    _singular_name: Staff Member
    _singular_key: staff_member
    _disable_add: false
    _icon: people
    _add_options:
      - name: Add Staff Member
        icon: person_add
        href: "cloudcannon::editor/:collections_dir/_staff/.:extension🆕"

Add Options

Create or change actions for the current collection in the add dropdown menu list with _add_options.

Define _add_options with the following format:

name

String

The text used in the menu

icon

String

Must match Material Icon name

href

String

The link that opens when the option is clicked.

Note

Add options can include actions on the current collection, other collections, and external links.

The href field is formatted as an Editor Link or external link. There are a number of variables you can use to make these links more flexible:

:editor

Usually explore, is update if creating an HTML file.

:collections_dir

The Jekyll `collections_dir` path defined in `_config.yml`

:base_path

The path the editor is currently viewing in the Explore section, not including the source or collections_dir

:base_path_postify

Same as `:base_path`, with /_drafts changed to /_posts

:base_path_draftify

Same as `:base_path`, with /_posts changed to /_drafts

:source

The Jekyll `source` path defined in `_config.yml`

:extension

The extension of the default content file

The default content file is the file listed after 🆕 in your Editor Link, or the Collection Defaults file if not listed.

_config.yml
collections:
  posts:
    _add_options:
      - name: Add Post
        href: "cloudcannon::editor/:collections_dir/:base_path/.:extension🆕"
      - name: Add Draft
        href: "cloudcannon::editor/:collections_dir/:base_path_draftify/.:extension🆕:base_path_postify/_defaults.:extension"
  <collection-name>: (for all collections)
    _add_options:
      - name: Add <collection-name>
        href: "cloudcannon::editor/:collections_dir/:base_path/.:extension🆕"

Extended example:

_config.yml
collections:
  posts:
    _add_options:
      - name: Add Post
        href: "cloudcannon:explore/_posts/.md🆕"
      - name: Add Draft
        href: "cloudcannon:explore/_drafts/.md🆕/_posts/_defaults.md"
  staff:
    _add_options:
      - name: Add Staff Member
        href: "cloudcannon:explore/_staff/.md🆕"
      - name: Add Author
        icon: edit
        href: "cloudcannon:explore/_staff/.md🆕/_staff/_defaults-author.md"
  offices:
    _add_options:
      - name: Add Office
        href: "cloudcannon:explore/_offices/.md🆕"
      - name: Add Office Location
        icon: public
        href: "cloudcannon:explore/_data/office-locations.yml"
      - name: Search on Google
        icon: search
        href: "https://www.google.com/"

File

These options are set in the front matter (or with Jekyll Defaults) of specific files and affect individual items in the Explore group lists.

_unlisted

Boolean

Hides specific files from the Explore section (still accessible from Visual Editor and direct links).

_enabled_editors

Array of Strings (of visual or content only)

Controls how your team edits specific files, use this to set a preferred editor and/or disable the others. The first value sets which editor opens from the Explore section, the other values specify which editors are accessible. Available values are visual and content for the Visual Editor and Content Editor, respectively. The Source Editor is always available for those with permission.

Front Matter
_unlisted: true
_enabled editors:
  - visual
  - content
On this page:

Loading...

Don’t miss the latest
CloudCannon news freshly delivered to your inbox