Library Editor

Edit content library XML as a tree with forms. Search bodies, translate names, compare and copy locales, fix content links and file assets in folders

The Library Editor opens a content library file (root element library) as a tree of its folders, content assets and Page Designer pages, with the selected row's form under it. Every change is an edit of the XML and one Undo step. The Text tab beside Library Editor shows the same document

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

It has the toolbar, the Properties and XML panel, the actions and the license rules of every site archive editor. This page covers what the library adds

The tree

The search reads IDs, names and bodies: a word of an asset's HTML finds the asset. The scopes are All, Assets (folders and classic content assets), Pages (Page Designer pages with their regions and components) and Folders (the folder tree), each with its count

ColumnWhat it shows
NameThe ID, with the name in grey
KindAsset, Page, Component or Fragment. A folder shows how many assets it holds, such as 0 assets
LocalesHow many locales the names, the body and the data have
OnlineA check box you can tick in the tree. A site override reads On, 1 site off
SearchableA check box, for assets
CodeHow many places in scripts and templates name the asset. A click lists them

Assets in no folder sit under Unfiled, and components nothing links to under Unused components. An asset filed in a second folder shows there as Asset, also here: deleting that row removes the link, not the asset. Offline rows are grey

Pills and filters

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

The quick pills are Unused in code and Offline with the Code column, Offline and Problems without it. The other filters are in the Filters popup, each with how many rows it shows:

FilterShows
Asset, Page, Component, Fragment, FolderOne kind of entry
A type, a folder, a localeOne per component type, folder and locale in the file
Only x-default, Missing a localeContent with no other locale, or a name in a locale the body lacks
A siteFlags that site overrides
Visible, InvisiblePages visible in a locale, or in none
Has body, Empty bodyAssets with or without HTML
Has template, Has custom attributesEntries with their own template, or custom attributes besides the body
Has aspect type, Has object assignmentsPages with an aspect, or assigned to categories or products
Unknown type, Orphan component, Region limitPage Designer problems
Unknown data key, Missing required attributeComponent data the type doesn't define, or required data it lacks
Broken link, Duplicate IDLinks to content not in the file, IDs the file has twice
Marked for deletionmode="delete" entries

A filter shows only when a row has it

The asset form

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties
SectionWhat it holds
AssetName, Description and Search words per locale, the Template (The folder's or the site's when empty) with Go to Template, and Copy Script
FlagsOnline and Searchable, then a row per site that overrides them
BodyThe HTML per locale, see The body
FoldersThe classification folder and the other folders the asset is in
SEOPage title, description, keywords and URL, per locale
CodeThe places in scripts and templates, with Show All in Find

A localized field has a Translations button at its end, and +2 after it when two other locales have a value. Hover the button to read them, click it to edit every locale in a table. Copy Script copies ContentMgr.getContent('security-badges')

The body

The Locale row picks the locale and says how many have a body and their size, such as 2 locales, 2.9 KB. The body opens in the IDE's own HTML editor, with highlighting, completion, brace matching and syntax errors. Its header reads HTML:, with the size at the right before the buttons, such as 22 lines · 1.1 KB, or Empty

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties
Header controlWhat it does
ChevronFolds the editor to its header. The IDE remembers it
Soft-WrapWraps long lines, or scrolls them sideways. Remembered per language
ReformatLays the HTML out by the code style and writes it. The Reformat Code shortcut does the same
Editor PlacementBeside the Form, Below the Form or In the Form
ExpandThe body alone in the whole Properties panel. Collapse or Esc gives the form back

The body writes to the XML when you leave it or press Cmd+Enter / Ctrl+Enter. Esc puts back what it last wrote. Undo takes back your typing before the file's edits. Beside the Form falls back to below on a narrow panel, and below falls back to in the form on a short one. A body over 1 MB opens read only: Read only here: over 1 MB. Edit it in the XML

Compare and copy locales

Compare Locales… asks Compare x-default with and opens the IDE's diff of the two bodies. Both sides are editable, and the edits are one Undo step

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

Copy to Locales… copies the shown body to other locales. Cmd+Click / Ctrl+Click picks several, and a locale that has a body is marked replaces its value. Locales come from the sites of the project

The body knows the content links of the storefront: $url('Page-Show','cid','privacy-policy-message')$, $staticlink$ and the others. The delimiters and the keys get their own colours, and what resolves is underlined

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties
  • Completion lists routes, the keys of a route, and the content asset, folder, category and product IDs, each with the file it comes from, such as SoloCA/library.xml
  • Cmd+Click / Ctrl+Click opens the route, the asset or the static file
  • An ID no library holds is red: Cannot resolve content asset '…', with the fix Change to '…'. The inspection also flags an unclosed link, a missing route and a key with no value

Site overrides

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

Override for a Site… asks for the Site ID and adds an Online row for that site, under the default. Its value is one of:

ValueWrites
On, OffThe site's own value
Inheritxsi:nil: the import clears the site's value, so the default applies
Not in the fileRemoves the row: the import leaves the site's value as it is

The tree's Online cell then reads On, 1 site off, and the asset counts as Offline

Folders

Set Classification… picks the asset's classification folder from Classification folder. The row moves under that folder in the tree. Also in lists the other folders with their positions. Add or remove them, Enter IDs… to paste several, one per line, or Go to Folder

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

A folder's form holds its Name and Description per locale, Online, the Template (The site's when empty), the Parent (not for root) and the Position, a whole number, then SEO. Duplicate… copies a folder under a new ID, right after it. Rename… changes its ID, and its subfolders and folder links follow. Renaming an asset updates the links and variant assignments in the file

Several rows

Select several rows with Cmd+Click / Ctrl+Click or Shift+Click. The form reads 2 rows selected, Changes apply to all of them, and each flag is checked, unchecked or mixed. Add to Folder… files every selected asset in one folder

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

The library and its file

With no row selected, the form shows the Library (Site library, or the ID of a shared one, with its folders and assets), Add Content Asset and Add Folder, then the Code count: 5 of 7 entries, with Select the 2 Unused. The File section names the archive and the site the file applies to

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

The shared form takes two assets or more. With a folder in the selection, such as root among the unused, the form is the first row's: the folder's, under 2 rows selected

Add assets and folders

Add Content Asset in the summary, or Add › Content Asset… in the toolbar, asks for the Content ID. The new asset is online, not searchable, with an empty body, and filed in the selected row's folder or in root. Add Folder and Folder… ask for the Folder ID and add the folder under the selected row's folder or under root

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

Page… adds a Page Designer page, and Component… a component in the selected page or region

Mark for deletion

Right-click a row for Add, its own actions and the shared ones. Mark for Deletion keeps only the ID with mode="delete", so the import deletes the folder or the asset. The row is struck out, its flags and code count go, and a folder leaves its parent. Delete removes the element from the file instead

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

Properties and XML

Show in XML (Cmd+Down / F4) opens the XML tab with the caret on the row's element and its lines marked. The split button shows Properties and XML side by side, stacked on a narrow panel. Click it again, or a tab, to show one at a time

The Library Editor shows the folders and content assets of library.xml as a tree, with each asset's form beside it. Search reads ids, names and body text. Pills narrow the tree to unused or offline assets. You can edit names in every locale, show the body one locale at a time, compare two locales in the IDE's diff, copy a body to other locales, fix and complete content links inside a body, turn an asset off for one site, file several assets at once, add assets and folders, mark a folder for deletion, and show a row in the XML beside its properties

Page Designer

In Pages, a page holds its regions, and each region its components. A region reads region, 2 of 4, red over its limit. A component shows its type, red when no cartridge defines it

The site archive editors open services, jobs, site preferences, custom objects, content slots and content libraries in the design view of the Metadata Editor. Search, narrow by scope or a quick pill, open the Filters popup, jump from the problems count to the XML and fix it with Alt+Enter, see the properties and the XML side by side, hide columns and turn grouping off, then edit each kind in its form: copy a createService call, create a missing profile, add and schedule job steps, copy and move a preference across tiers, define a preference, paste and add custom objects, make a slot configuration the default, write a missing Page Designer type and find the code that uses a row
  • A page form has the type, aspect, visibility, category and product assignments, and its regions with Add Component…
  • A component form has a Data section with a field for each attribute of the type's JSON, per locale. Edit as JSON shows the data as JSON, and a key the type doesn't define reads Not in and the type ID, with Remove
  • Go to Type opens the type's JSON, and Create Page Designer Type writes its .json, .js and .isml into a cartridge from the data
  • Copy Script copies PageMgr.getPage('id')

Checks

ProblemWhy
Parent home is not in this file, Folder sale is not in this fileA folder or a link names a folder the file doesn't have
The folder tree has a cycle through …A folder is its own ancestor
More than one classification linkAn asset has one classification folder
No cartridge defines …A page or component type no cartridge has
Region main holds 5 of 4A region over its type's limit. Add Component… warns Region main holds at most 4 components.
A … value is over 4,000 charactersThe platform's limit for a localized value
Locale en_US: xml:lang takes en-USLocales are written with a hyphen
Site ID … is over 32 charactersThe platform's limit for a site ID

On this page