diff --git a/_i18n/en.yml b/_i18n/en.yml index 40f750c..9644f5f 100644 --- a/_i18n/en.yml +++ b/_i18n/en.yml @@ -35,6 +35,10 @@ ipfs_text: 'Upload a file from your device to the Interplanetary File System. T ipfs_button_text: 'Upload' ipfs_secondary_cta: 'See what others have uploaded' ipfs_image_alt: 'Interplanetary File System logo' +file_folder_title: 'More data available with or without Internet' +file_folder_image_alt: 'File folder icon' +file_folder_text: 'The administrator of this Butter Box uploaded additional content.' +file_folder_cta: 'View files' upload: ui_source_ack: "Upload UI upstream source" page_title: Upload files to diff --git a/assets/images/placeholder-file-folder.webp b/assets/images/placeholder-file-folder.webp new file mode 100644 index 0000000..e9a4c5e Binary files /dev/null and b/assets/images/placeholder-file-folder.webp differ diff --git a/assets/js/main.js b/assets/js/main.js index 1cfa9de..bc92cb2 100644 --- a/assets/js/main.js +++ b/assets/js/main.js @@ -32,3 +32,15 @@ const btnModal = document.querySelector('.btn-modal'); btnModal.addEventListener('click', (event) => { event.preventDefault(); }); + +// If #usb-butter exists and a request to thishost.tld/usb-butter returns status 200 +// change display of #usb-butter to inherit +const usbButter = document.querySelector('#usb-butter'); +if (usbButter) { + fetch('/usb-butter') + .then(response => { + if (response.status === 200) { + usbButter.style.display = 'inherit'; + } + }); +} \ No newline at end of file diff --git a/index.html b/index.html index eb97c00..fb13e42 100644 --- a/index.html +++ b/index.html @@ -68,6 +68,19 @@ layout: default {% endif %} + +