How to add field object to existing site.yml

How do I add these field objects to the site yml (below). When I try it breaks the panel. I’m trying to create some global data sets to share across the site. Kirby 5

  fields:
    CD1:
      type: object
      fields:
        uk:
          type: Number
        europe:
          type: Number
        restofworld:
          type: Number

     CD2:
      type: object
      fields:
        uk:
          type: Number
        europe:
          type: Number
        restofworld:
          type: Number

     CD3:
      type: object
      fields:
        uk:
          type: Number
        europe:
          type: Number
        restofworld:
          type: Number

      CD4:
        type: object
        fields:
          uk:
            type: Number
          europe:
            type: Number
          restofworld:
            type: Number

      LP:
        type: object
        fields:
          uk:
            type: Number
          europe:
            type: Number
          restofworld:
            type: Number
# The `site.yml` blueprint defines the look of the start page (Dashboard) of the Panel.

# The site blueprint usually provides easy access to all main pages of the site.
# In this example blueprint, we also show subpages of the `photography` and `notes` pages.
# More about the site blueprint: https://getkirby.com/docs/reference/panel/blueprints/site

# The layout of this form has two columns:
columns:
  # The first column has one section for the subpages of the `photography` page in card layout
  # It reuses the pages section defined in `/site/blueprints/sections/albums.yml`
  - width: 1/2
    sections:
      albums: sections/albums

trying to do it simply. I added a single field to the existing site.xml, under a fields section.

And all I see under the image albums is ‘No fields yet’

My code:

columns:
  - width: 1/2
    sections:
      albums: sections/albums
      fields:
        field:
          title1:
            type: text

I guess this cannot be done, so I have switched to adding my global field data to the home page panel. There it can be edited by the end-user, and then fetched by any page.

Yes, you can of course add global fields in your site.yml. The “No fields yet” message you’re seeing is Kirby’s placeholder when a fields section comes up empty, in your case because the key is field: instead of fields:.

When you want to combine other sections (like albums) with fields, put them into a fields section’s fields:

columns:
  - width: 1/2
    sections:
      albums: sections/albums
      # your fields section
      my_fields:
        type: fields
        fields:
          # your field
          my_text:
            type: text

There’s also a shorthand for when you’re not trying to combine sections (the album) with fields:

columns:
  - width: 1/2
    fields:
      # your field
      my_text:
        type: text

Or even shorter when you’re not using columns:

fields:
  # your field
  my_text:
    type: text

Yes, that’s the full site.yml.

And one more small issue: field type names are lowercase (type: number, not type: Number).

Many thanks! I’m still learning this stuff.