Preview
The live preview
Section titled “The live preview”The settings screens of a skin, and the screens of the variables when they show the shop, display the Live preview beside the column of fields: the shop of the sales channel selected in the Sales channel picker, with the draft of the skin and the unsaved changes. The other screens of the skin, such as the component styles, show their own previews of the elements. The line under the title names the channel: “channel · draft, no theme compile”. The preview opens the home page of the channel; a link followed inside the preview keeps showing the draft.
The preview shows one device at a time. The device switch in its toolbar (Desktop, Tablet, Phone) renders the page at a real width of that device, inside the range of the draft’s breakpoints, and scales it down to the space available on the screen, so the shop applies the layout of that device. The same device is used by the rows of values per device in the column of fields.
Colours, sizes and other variables of the draft change in the preview at once. A change that alters the page itself, for example a setting of a component, reloads the page a moment after the last change, at the same scroll position.
A field marked After publishing is written into the stylesheet when the theme is compiled. The live preview does not show it; the full preview and the shop show it.
When the preview shows no shop
Section titled “When the preview shows no shop”- “This sales channel has no domain to show.”: the channel has no domain.
- “The storefront runs on another domain than the administration, so the preview cannot show the draft.”: the preview works only with a domain of the channel on the same address as the administration. Among the domains of a channel, the preview prefers one on that address, and among those the one in the language being edited.
- “The shop did not keep the preview of your unsaved changes, so the preview shows the saved draft. Save the draft to see them.”: the shop no longer had the unsaved changes of the preview; saving the draft makes them visible again.
The full preview
Section titled “The full preview”Full preview in the toolbar opens the shop in a new tab with the draft and the unsaved changes, and with a stylesheet compiled from them. It therefore also shows the values marked After publishing. The button needs a skin and a sales channel with a domain.
The builders have the same toolbar above their preview, with the device switch, Full preview, Undo and Redo, and in some builders the zoom (Zoom out, Zoom in, Zoom to 100%, Fit to screen) and Keyboard shortcuts.
The language switch
Section titled “The language switch”The language switch of the Shopware top bar appears on the Nova screens that edit texts of the shop or preview the shop in a language:
- the builders of documents with texts,
- the screens whose settings are shown in a column of fields beside the preview,
- Account menu, Back to top button, Product labels, Product card, Grid and toolbar, Filters and Category header.
The texts are edited in the selected language, and the previews show the shop in it. A screen without texts, such as Content → Nova → Skins → Sales channels, has no switch.
With unsaved changes the switch asks before it changes the language, and saves them if that is chosen.
Sample data
Section titled “Sample data”The previews of the product card and of the product labels show cards of real products of the sales channel, one for each case that has to be visible. The names of the cases are On sale, With variants, Sold out, Without an image, Long name, With reviews, Without reviews, With its own layout, New and Topseller; which of them a screen shows depends on the screen. The products are taken from the channel’s own catalogue, so nothing has to be set up for the preview.
Two cards with invented data come first: Every part · sample data, which shows every part of the card, and Sizes · sample data, which shows the sizes as tiles. Where the catalogue has no product for the cases On sale, New, Topseller or Sold out, a card with invented data is shown instead: On sale · sample data, New · sample data, Topseller · sample data and Sold out · sample data.
The invented cards are built from a product of the channel copied in memory, so a channel without a product to copy shows only the cards of its catalogue. Nothing is written to the catalogue.
The list To check before publishing of the screen names the cases for which the channel has no product and no card is shown instead (“The preview lacks the cards …: the sales channel has no such product.”), and the cases shown with sample data (“The sales channel has no product for …: the preview shows sample data there.”).
The builders of the product page, of the product infos and of the quick view use the same cases of the catalogue, but show one product at a time. Above their preview the button Product names the product shown and opens a choice of any product of the catalogue (Other product…). The buttons after it show the product of a case, for each case the channel has a product for: With variants, On sale, Sold out, With reviews, Without reviews, With its own layout, Without an image and Long name. The product info builder offers only With variants. Each of these builders opens on the first case in this order that the channel has a product for. These builders show no cards with invented data. When the channel has a product for none of the cases and no product has been chosen, the preview shows “The sales channel of the preview has no product to draw the page for: choose one with ‘Other product…’.”
The cart and checkout builder fills its sample cart with up to three products of the cases On sale, With variants, Topseller, New and With reviews. → Product card