[{"data":1,"prerenderedAt":23},["ShallowReactive",2],{"clay-page:\u002F3.x\u002Forganizing\u002Fclay-edit":3},{"html":4,"toc":5,"description":19,"hero":20,"list":21,"socialImage":22},"\u003Ch1 id=\"editing-with-clay-edit\">Editing with clay edit\u003C\u002Fh1>\n\u003Cp>\u003Ccode>clay edit\u003C\u002Fcode> is an editor in the terminal for everything around your pages: creating pages and folders, their front matter, their order, renaming, moving and deleting them, translations, versions and the settings in \u003Ccode>clay.yaml\u003C\u002Fcode>. It writes the same files you would edit by hand, so you can mix both ways freely.\u003C\u002Fp>\n\u003Cdiv class=\"code-block is-terminal has-bar\">\u003Cdiv class=\"code-terminal\" aria-hidden=\"true\">\u003Cspan>\u003C\u002Fspan>\u003Cspan>\u003C\u002Fspan>\u003Cspan>\u003C\u002Fspan>\u003C\u002Fdiv>\u003Cpre class=\"shiki shiki-themes light-plus dark-plus\" style=\"--shiki-light:#000000;--shiki-dark:#D4D4D4;--shiki-light-bg:#FFFFFF;--shiki-dark-bg:#1E1E1E\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line command\">\u003Cspan style=\"--shiki-light:#695221;--shiki-dark:#DCDCAA\">npx\u003C\u002Fspan>\u003Cspan style=\"--shiki-light:#A31515;--shiki-dark:#CE9178\"> clay\u003C\u002Fspan>\u003Cspan style=\"--shiki-light:#A31515;--shiki-dark:#CE9178\"> edit\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003Cbutton type=\"button\" class=\"copy-code btn btn-sm btn-square btn-ghost\" title=\"Copy code\" aria-label=\"Copy code\">\u003Ci class=\"fa-solid fa-copy\">\u003C\u002Fi>\u003C\u002Fbutton>\u003C\u002Fdiv>\n\u003Cdiv class=\"code-block\">\u003Cpre class=\"shiki shiki-themes light-plus dark-plus\" style=\"--shiki-light:#000000;--shiki-dark:#D4D4D4;--shiki-light-bg:#FFFFFF;--shiki-dark-bg:#1E1E1E\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>┌  Clay · edit   Pages   Settings   latest · en\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│   ⌂ Clay Documentation          fa-solid fa-book-open\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│   ◆ Introduction                fa-solid fa-house\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│ › ▾ Getting Started             fa-solid fa-rocket\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│   │  ◆ Installation             fa-solid fa-download\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│   │  ◆ Quick Start              fa-solid fa-bolt\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│   ▸ Writing                     fa-solid fa-pen-nib\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>│\u003C\u002Fspan>\u003C\u002Fspan>\n\u003Cspan class=\"line\">\u003Cspan>└  ⏎ details · n page · f folder · m order · o move · r rename · x delete · v\u002FV version · l language · tab · q\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003Cbutton type=\"button\" class=\"copy-code btn btn-sm btn-square btn-ghost\" title=\"Copy code\" aria-label=\"Copy code\">\u003Ci class=\"fa-solid fa-copy\">\u003C\u002Fi>\u003C\u002Fbutton>\u003C\u002Fdiv>\n\u003Cp>Changes are written right away, one file at a time, and the editor shows which files it wrote. Use git to review or undo them.\u003C\u002Fp>\n\u003Ch2 id=\"pages-and-folders\">\u003Ca class=\"heading-anchor\" href=\"#pages-and-folders\" aria-label=\"Link to this section\" data-route=\"#pages-and-folders\">#\u003C\u002Fa>Pages and folders\u003C\u002Fh2>\n\u003Cp>The \u003Cstrong>Pages\u003C\u002Fstrong> tab shows the start page (\u003Ccode>⌂\u003C\u002Fcode>), the folders (\u003Ccode>▾\u003C\u002Fcode>) and the pages (\u003Ccode>◆\u003C\u002Fcode>) in navigation order. Titles in gray are defaults, taken from the first heading or the file name.\u003C\u002Fp>\n\u003Ctable>\n\u003Cthead>\n\u003Ctr>\n\u003Cth>Key\u003C\u002Fth>\n\u003Cth>Action\u003C\u002Fth>\n\u003C\u002Ftr>\n\u003C\u002Fthead>\n\u003Ctbody>\u003Ctr>\n\u003Ctd>\u003Ckbd>↑\u003C\u002Fkbd> \u003Ckbd>↓\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Select an entry\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>←\u003C\u002Fkbd> \u003Ckbd>→\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Close and open folders\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>⏎\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Open the details: all front matter fields of the entry\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>t\u003C\u002Fkbd> \u002F \u003Ckbd>i\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Edit the title \u002F icon directly\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>n\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Create a page in the selected folder (or next to the selected page)\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>f\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Create a folder, with an \u003Ccode>index.md\u003C\u002Fcode>\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>m\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Pick the entry up; move it with \u003Ckbd>↑\u003C\u002Fkbd> \u003Ckbd>↓\u003C\u002Fkbd>, drop it with \u003Ckbd>⏎\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>o\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Move the entry into another folder\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>r\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Rename the file or folder\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>x\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Delete the entry, after asking\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>Tab\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Switch to the settings\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>q\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Quit\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftbody>\u003C\u002Ftable>\n\u003Cp>New pages get their title as front matter and as their first heading, and a file name made from the title, which you can change before it is created. New folders get an \u003Ccode>index.md\u003C\u002Fcode> with their title and \u003Ccode>list: true\u003C\u002Fcode>.\u003C\u002Fp>\n\u003Cp>Ordering numbers everything in the folder (\u003Ccode>order: 1\u003C\u002Fcode>, \u003Ccode>2\u003C\u002Fcode>, \u003Ccode>3\u003C\u002Fcode>, …) and writes only the files whose number changed.\u003C\u002Fp>\n\u003Cp>Renaming and moving take the page’s translations along. Clay does not rewrite links to the entry; instead, it lists the links that broke, so you can fix them:\u003C\u002Fp>\n\u003Cdiv class=\"code-block\">\u003Cpre class=\"shiki shiki-themes light-plus dark-plus\" style=\"--shiki-light:#000000;--shiki-dark:#D4D4D4;--shiki-light-bg:#FFFFFF;--shiki-dark-bg:#1E1E1E\" tabindex=\"0\">\u003Ccode>\u003Cspan class=\"line\">\u003Cspan>Moved setup.md → guides\u002Fsetup.md · 2 link(s) broke: introduction.md: \"setup.md\" points to a missing page (\u002Fsetup) …\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fcode>\u003C\u002Fpre>\u003Cbutton type=\"button\" class=\"copy-code btn btn-sm btn-square btn-ghost\" title=\"Copy code\" aria-label=\"Copy code\">\u003Ci class=\"fa-solid fa-copy\">\u003C\u002Fi>\u003C\u002Fbutton>\u003C\u002Fdiv>\n\u003Ch2 id=\"the-details\">\u003Ca class=\"heading-anchor\" href=\"#the-details\" aria-label=\"Link to this section\" data-route=\"#the-details\">#\u003C\u002Fa>The details\u003C\u002Fh2>\n\u003Cp>\u003Ckbd>⏎\u003C\u002Fkbd> opens all front matter fields of the selected entry: title, icon, description and order, and for folders and the start page also \u003Ccode>list\u003C\u002Fcode> and \u003Ccode>hero\u003C\u002Fcode> (see \u003Ca href=\"\u002Fclay-example-repo\u002F3.x\u002Forganizing\u002Findex-pages\" data-route=\"\u002F3.x\u002Forganizing\u002Findex-pages\">index pages\u003C\u002Fa>). Select a field and press \u003Ckbd>⏎\u003C\u002Fkbd> to change it; yes\u002Fno fields switch with \u003Ckbd>⏎\u003C\u002Fkbd>. \u003Ckbd>Esc\u003C\u002Fkbd> leads back to the list.\u003C\u002Fp>\n\u003Cp>In a text field, \u003Ckbd>⏎\u003C\u002Fkbd> applies and \u003Ckbd>Esc\u003C\u002Fkbd> cancels. Leave a field empty to remove the value and go back to the default. For a folder without an \u003Ccode>index.md\u003C\u002Fcode>, the editor creates one.\u003C\u002Fp>\n\u003Ch2 id=\"versions-and-languages\">\u003Ca class=\"heading-anchor\" href=\"#versions-and-languages\" aria-label=\"Link to this section\" data-route=\"#versions-and-languages\">#\u003C\u002Fa>Versions and languages\u003C\u002Fh2>\n\u003Cp>The header shows which version and language you are editing.\u003C\u002Fp>\n\u003Ctable>\n\u003Cthead>\n\u003Ctr>\n\u003Cth>Key\u003C\u002Fth>\n\u003Cth>Action\u003C\u002Fth>\n\u003C\u002Ftr>\n\u003C\u002Fthead>\n\u003Ctbody>\u003Ctr>\n\u003Ctd>\u003Ckbd>v\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Switch to the next version\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>V\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Save the current docs as a new version, see \u003Ca href=\"\u002Fclay-example-repo\u002F3.x\u002Fversions-and-languages\u002Fversions\" data-route=\"\u002F3.x\u002Fversions-and-languages\u002Fversions\">versions\u003C\u002Fa>\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>l\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Switch to the next language\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003Ctr>\n\u003Ctd>\u003Ckbd>c\u003C\u002Fkbd>\u003C\u002Ftd>\n\u003Ctd>Start a translation of the selected entry: copies the original into \u003Ccode>*.de.md\u003C\u002Fcode> and so on\u003C\u002Ftd>\n\u003C\u002Ftr>\n\u003C\u002Ftbody>\u003C\u002Ftable>\n\u003Cp>In another language, pages without a translation are marked \u003Cstrong>untranslated\u003C\u002Fstrong>. Setting a field of such a page creates the translation from the original first. The order is the same in every language, so it is changed in the default language.\u003C\u002Fp>\n\u003Ch2 id=\"settings\">\u003Ca class=\"heading-anchor\" href=\"#settings\" aria-label=\"Link to this section\" data-route=\"#settings\">#\u003C\u002Fa>Settings\u003C\u002Fh2>\n\u003Cp>The \u003Cstrong>Settings\u003C\u002Fstrong> tab lists the settings of \u003Ccode>clay.yaml\u003C\u002Fcode>. Select one and press \u003Ckbd>⏎\u003C\u002Fkbd> to change it. Settings with a value per language are edited in the language shown in the header. Navbar links are added with \u003Cstrong>+ Add link\u003C\u002Fstrong> and removed with \u003Ckbd>d\u003C\u002Fkbd>.\u003C\u002Fp>\n\u003Cp>Clay changes only the values you edit. Comments, quotes, the order of keys and the rest of each file stay as they were, so the diff in git shows exactly your change.\u003C\u002Fp>\n\u003Cdiv class=\"markdown-alert markdown-alert-tip\">\n\u003Cp class=\"markdown-alert-title text-primary\">\u003Ci class=\"fa-solid fa-lightbulb mr-2\">\u003C\u002Fi>Tip\u003C\u002Fp>\n\u003Cp>Run \u003Ccode>npx clay dev\u003C\u002Fcode> in a second terminal: the site reloads with every change you make in the editor.\u003C\u002Fp>\n\u003C\u002Fdiv>\n",[6,10,13,16],{"id":7,"text":8,"level":9},"pages-and-folders","Pages and folders",2,{"id":11,"text":12,"level":9},"the-details","The details",{"id":14,"text":15,"level":9},"versions-and-languages","Versions and languages",{"id":17,"text":18,"level":9},"settings","Settings","Create, edit, order, rename, move and delete pages and folders, translate them and edit the settings, for every version and language.",null,false,"\u002F_clay\u002Fsocial\u002F3.x\u002Forganizing\u002Fclay-edit.png",1792666368938]