diff --git a/libs/blocks/locui/locui.css b/libs/blocks/locui/locui.css new file mode 100644 index 0000000000..2c9de0b76a --- /dev/null +++ b/libs/blocks/locui/locui.css @@ -0,0 +1,8 @@ +.locui.container { + margin: 0 auto; + margin-top: 10vh; + max-width: 700px; + border-radius: 10px; + border: 10px solid #eee; + padding: 10px 30px 30px; +} diff --git a/libs/blocks/locui/locui.js b/libs/blocks/locui/locui.js new file mode 100644 index 0000000000..2c9acdac1b --- /dev/null +++ b/libs/blocks/locui/locui.js @@ -0,0 +1,16 @@ +import { createTag } from '../../utils/utils.js'; + +export default function init(el) { + el.classList.add('container'); + const heading = createTag('h2', null, 'Missing project details'); + const paragraph = createTag('p', null, 'The project details were removed after you logged in. To resolve this:'); + const steps = createTag('ol', null); + const stepList = ['Close this window or tab.', 'Open your project Excel file.', 'Click "Localize..." in Sidekick again.']; + stepList.forEach((step) => steps.append(createTag('li', null, step))); + const learnmore = createTag('a', { + class: 'con-button', + href: 'https://milo.adobe.com/docs/authoring/localization#:~:text=at%20render%20time.-,Troubleshooting,-Error%20matrix', + target: '_blank', + }, 'Learn More'); + el.append(heading, paragraph, steps, learnmore); +} diff --git a/libs/utils/utils.js b/libs/utils/utils.js index ed41f1ad0d..a70602485f 100644 --- a/libs/utils/utils.js +++ b/libs/utils/utils.js @@ -41,6 +41,7 @@ const MILO_BLOCKS = [ 'icon-block', 'iframe', 'instagram', + 'locui', 'marketo', 'marquee', 'marquee-anchors',