Restrict uploading files or hide sidebar

Hello,

I don’t want to allow some users to upload files in certain pages, how can I restrict that. the options apply to fields but not to files. the file blueprints File blueprint | Kirby CMS is not the sidebar with the listed files, or am I misunderstanding it. the easiest way would be if I could show the sidebar only for certain users.

thanks for reading.

title: home
files: true
options:
  create:
    *: false
    admin: true
  delete:
    *: false
    admin: true
  update:
    *: false
    admin: true
  duplicate:
    *: false
    admin: true


columns:
  # main content
  main:
    width: 2/3
    sections:
      content:
        type: fields
        fields:
          title:
            label: Title
            type: title

          gallery_01:
            label: Gallery 01
            type: structure
            style: table
            fields:
              gallery_img:
                type: files
                query: page.images
              caption:
                label: caption
                type: text

          info:
            label: Infobox
            extends: fields/markdown_editor

          info_view:
            label: show/hide Infobox
            type: toggle

          palette:
            label: Infobox color
            type: color-palette
            options:
              - "#135fdc"
              - "#f6917e"
              - "#6a96e4"
              - "#ff8e8e"
  # files
  sidebar:
    width: 1/3
    sections:
      files:
        headline: Files
        type: files
        layout: list

I’d create the blueprint in a plugin conditionally, like explained here: Programmable blueprints | Kirby CMS

Maybe even load a different blueprint so that it doesn’t look as if something was missing.

@texnixe Thank you for your answer.

I completely overlooked the key/value read:false, so I can achieve what I wanted.