Skip to content

Ready-made sections

Ready-made sections show the business’s published data in its theme. Content is edited only in the panel, and the sections refresh themselves after each publication.

Section data-public-block Shows
Services services Price list per location
Team team Staff with photo and description
Opening hours hours Opening hours by day and exceptions
Contact contact Phone, email and location addresses

The portfolio has its own section. See Portfolio.

<link rel="stylesheet" href="https://zakazi.tempact.app/public-content-blocks.css">
<script src="https://zakazi.tempact.app/public-content-loader.js" defer></script>
<script src="https://zakazi.tempact.app/public-content-blocks.js" defer></script>
<div id="business-content">
<p data-public-status role="status" aria-live="polite"></p>
<div data-public-block="services"></div>
<div data-public-block="team"></div>
<div data-public-block="hours"></div>
<div data-public-block="contact"></div>
</div>
<script>
addEventListener('DOMContentLoaded', () =>
PublicContentBlocks.mount(document.getElementById('business-content'), {
apiBase: 'https://app.tempact.app',
companySlug: 'your-business',
location: 'all',
lang: 'auto',
reportSeen: true
}));
</script>

Use only the sections you need. For example, just the price list.

Option Value
apiBase https://app.tempact.app
companySlug The business’s public identifier
location Location ID, or all
lang auto follows the site’s lang attribute and switches when the site changes language without reloading; sr-Latn or en lock the language. A language the firm does not have falls back to Serbian, and text without a translation shows the original
reportSeen true reports to the panel which publication the site shows
  • Sections check again when the page regains focus and on their own schedule. Every request is conditional (ETag), so it is cheap.
  • A copy older than 15 minutes is not shown as current.
  • The element the sections are mounted on gets state attributes: data-content-phase, data-publication-version, data-theme-id and data-theme-version.

A site without JavaScript can fetch the same data through the JSON API.