hide schema view from profile_view

hide schema from the sidebar, only show it in the "settings" screen

show schema view only if repoUUID!=="root". this will hide schema on the first screen but will still show it in the settings.

where is the component that shows "Schema of the repo"?

Right now the "Schema of the repo" is in the ViewField components, inside the switch case branchType==="array". If the branch is an array, ViewField shows the description of this branch. This branch is called "schema" and is stored in the api/schema.js file, in the variable schemaSchema. Right now ViewField works for any array. And if we want to hide the "schema" array, we will have to add an exception to ViewField for the "schema" branch. This is not great code.

So, we need to add a if inside the "case 'array'" in ViewField which checks that

  • repoUUID!=="root"
  • branch !== "schema"

This will look something like

      return { (repoUUID !== "root" && branch !== "schema") && (
        <div>
          {!isOpen ? (
            <div>
       ...
      }
Edited by fetsorn