Paragraph Type NCIDS Promo Block - NCIOCPL/cgov-digital-platform GitHub Wiki

An NCIDS Promo Block which includes a link (internal or external), image, title, description, button text, and button alt text.

NCIDS Promo Blocks are placed inside of the Landing Page Contents field of Home and Landing pages with the NCIDS Style.

Component Properties

There are two types of NCIDS Promo Block:

Both of these types include a theme, image position, link (internal or external), image override, title override, description override, and button text.

Component Styles

  • Theme: Dark or Light
  • Image Position: Left or Right

NCIDS Promo Block Internal

  • Display Name: NCIDS Promo Block Internal
  • Machine-readable Name: ncids_promo_block_internal
  • Description: Featured internal content in an NCIDS promo block display.

Common Fields

Local Fields

Image Position

  • Field Name: field_image_position (existing field)
  • Label: Image Position
  • Type: Dropdown
    • Image Left
    • Image Right
    • No Image
  • Required: Yes
  • Max characters: N/A
  • Tooltip Text: Select whether to display an image left or right, or no image. When adding multiple Promo Blocks, recommend alternating the image display and adding no more than 2-3 blocks together.
  • Cardinality: 1
  • Translatable: No

Featured Item

  • Field Name: field_featured_item (existing field)
  • Label: Featured Item
  • Type: Entity Reference to Content
    • Field Widget: Entity Browser field
  • Selection Display: Rendered Entity using Entity Browser Selected Entity
  • Required: Yes
  • Tooltip Text: None
  • Cardinality: 1
  • Translatable: No

Button Text

  • Field Name: field_button_text (existing field)
  • Label: Button Text
  • Type: Text (plain)
  • Required: Yes
  • Max characters: 50
  • Tooltip Text: Text to be displayed on button. Should guide users to take desired call to action.
  • Cardinality: 1
  • Translatable: No

Button Alt Text

  • Field Name: field_button_alt (existing field)
  • Label: Button Alt Text
  • Type: Text (plain)
  • Required: No
  • Max characters: 255
  • Tooltip Text: A description of the link destination for use by screen readers. Suggest using the title of the destination page. Include the text of the button.
  • Cardinality: 1
  • Translatable: No
  • NOTE: Should output "" when no alt text is entered

Form Display Order

  • Theme
  • Image Position
  • Featured Item
  • Override Title
  • Override Description
  • Override Promotional Image
  • Button Text
  • Button Alt Text

NCIDS Promo Block External

  • Display Name: NCIDS Promo Block External
  • Machine-readable Name: ncids_promo_block_external
  • Description: Featured external content in an NCIDS promo block display.

Common Fields

Theme

  • Field Name: field_ncids_theme
  • Label: Theme
  • Type: Dropdown
    • Dark
    • Light
  • Required: Yes
  • Max characters: N/A
  • Tooltip Text: Changes the background color of the promo block.
  • Cardinality: 1
  • Translatable: No

Local Fields

Image Position

  • Field Name: field_image_position (existing field)
  • Label: Image Position
  • Type: Dropdown
    • Image Left
    • Image Right
    • No Image
  • Required: Yes
  • Max characters: N/A
  • Tooltip Text: Select whether to display an image left or right, or no image. When adding multiple Promo Blocks, recommend alternating the image display and adding no more than 2-3 blocks together.
  • Cardinality: 1
  • Translatable: No

Featured Item Url

  • Field Name: field_featured_url (existing field)
  • Label: Featured Item Url
  • Type: Text field
  • Required: Yes
  • Tooltip Text: Enter the full URL starting with https://
  • Cardinality: 1
  • Translatable: No

Title

  • Field Name:
  • Label: Title
  • Type: Text field
  • Required: Yes
  • Tooltip Text: Title of promotional content. Can be action-oriented or the page title
  • Cardinality: 1
  • Translatable: No

Description

  • Field Name:
  • Label: Description
  • Type: Text field
  • Required: No
  • Tooltip Text: Add description of promotional content.
  • Cardinality: 1
  • Translatable: No

Button Text

  • Field Name: field_button_text (existing field)
  • Label: Button Text
  • Type: Text (plain)
  • Required: Yes
  • Max characters: 50
  • Tooltip Text: Text to be displayed on button. Should guide users to take desired call to action.
  • Cardinality: 1
  • Translatable: No

Button Alt Text

  • Field Name: field_button_alt (existing field)
  • Label: Button Alt Text
  • Type: Text (plain)
  • Required: No
  • Max characters: 255
  • Tooltip Text: A description of the link destination for use by screen readers. Suggest using the title of the destination page. (Update to the same as internal promo block)
  • Cardinality: 1
  • Translatable: No
  • NOTE: Should output "" when no alt text is entered

Form Display Order

  • Theme
  • Image Position
  • Featured Item Url
  • External Link Display
  • Title
  • Description
  • Promotional Image
  • Button Text
  • Button Alt Text