diff --git a/.env.production b/.env.production deleted file mode 100644 index e97c0efc41..0000000000 --- a/.env.production +++ /dev/null @@ -1,5 +0,0 @@ -# DO NOT add secrets here - this file is checked into git. -# Production defaults for the shared navbar/footer integration. -FOOTER_FRAGMENT_URL=https://octopus.com/fragments/footer -SHARED_ASSETS_BASE_URL=https://octopus.com/octopus-public/assets -SHARED_ASSETS_ORIGIN=https://octopus.com diff --git a/.env.staging b/.env.staging deleted file mode 100644 index 2353580109..0000000000 --- a/.env.staging +++ /dev/null @@ -1,8 +0,0 @@ -# DO NOT add secrets here - this file is checked into git. -# -# Defaults match production. Edit temporarily to point at staging URLs -# (e.g. https://a.dev.octopus.com/...) when you want to preview upcoming -# shared navbar/footer changes locally before they ship to prod. -FOOTER_FRAGMENT_URL=https://octopus.com/fragments/footer -SHARED_ASSETS_BASE_URL=https://octopus.com/octopus-public/assets -SHARED_ASSETS_ORIGIN=https://octopus.com diff --git a/README.md b/README.md index 82fc6b55ff..28abfad61b 100644 --- a/README.md +++ b/README.md @@ -227,47 +227,16 @@ Within an MDX file, this looks like a code block and will error. Escape the stat MDX files don't allow short-form links, instead of using `` use `[https://example.com](https://example.com)`, or even better - put in useful link text, like `[example website](https://example.com)`. -## Shared footer +## Footer -The footer is not maintained in this repo. It is fetched at build time from the -main site: +The footer is built in this repo by `src/components/Footer.astro`. It renders +the page's last-updated date, the copyright line, and a row of links. Edit the +links in `src/data/footer.ts`; edit the wording in `src/data/language.json` +under `octopus_footer`. -- `https://octopus.com/fragments/footer` - -CSS, JS, and fonts load at page-view time from -`https://octopus.com/octopus-public/assets/...` via `` and -` diff --git a/src/components/NewsletterForm.astro b/src/components/NewsletterForm.astro deleted file mode 100644 index d77b6f94a3..0000000000 --- a/src/components/NewsletterForm.astro +++ /dev/null @@ -1,19 +0,0 @@ ---- -import MarketoForm from './MarketoForm.astro'; - -type Props = { - formId: number; - dreamdataTrackingId?: string; -}; - -const { formId, dreamdataTrackingId } = Astro.props satisfies Props; ---- - -
-

Newsletter

-

- Join ~80,000 DevOps professionals and sign up for the latest Octopus news, - events, and opinions. No spam. Unsubscribe at any time. -

- -
diff --git a/src/components/SharedFooter.astro b/src/components/SharedFooter.astro deleted file mode 100644 index e6c5860211..0000000000 --- a/src/components/SharedFooter.astro +++ /dev/null @@ -1,29 +0,0 @@ ---- -import { fetchFooter } from '../lib/sharedNavbarFooter'; -import { splitFooterAtMarketoPlaceholder } from '../lib/footerSplitter'; -import MarketoForm from './MarketoForm.astro'; - -const footer = await fetchFooter(); -const parts = splitFooterAtMarketoPlaceholder(footer.html); ---- - -
- { - parts.map((part) => - part.kind === 'html' ? ( - - ) : ( -
- -
- ) - ) - } -
diff --git a/src/components/SharedScripts.astro b/src/components/SharedScripts.astro deleted file mode 100644 index c18e3c7d4a..0000000000 --- a/src/components/SharedScripts.astro +++ /dev/null @@ -1,5 +0,0 @@ ---- -import { ASSETS } from '../lib/sharedNavbarFooter'; ---- - - diff --git a/src/config.ts b/src/config.ts index 350c802660..5c6e2dc5a4 100644 --- a/src/config.ts +++ b/src/config.ts @@ -30,6 +30,12 @@ export const SITE: Site = { month: 'long', day: 'numeric', }, + // "Jun 23, 2026" - the footer's last-updated line + shortDateOptions: { + year: 'numeric', + month: 'short', + day: 'numeric', + }, cacheMaxAge: 200, featureFlags: { stickyNav: { top: 112 }, diff --git a/src/data/footer.ts b/src/data/footer.ts index 344145106a..9848ec5a78 100644 --- a/src/data/footer.ts +++ b/src/data/footer.ts @@ -1,167 +1,13 @@ -import type { MenuItem } from 'astro-accelerator-utils/types/NavPage'; - -export const menu: (MenuItem | 'categories' | 'tags' | 'toptags')[] = [ - { - title: - '', - order: 1, - }, - { - title: 'Product', - order: 2, - children: [ - { - title: 'Features', - url: 'https://octopus.com/features', - order: 1, - }, - { - title: 'Tenanted deployments', - url: 'https://octopus.com/use-case/tenanted-deployments', - order: 2, - }, - { - title: 'Container deployments', - url: 'https://octopus.com/use-case/container-deployments', - order: 3, - }, - { - title: "What's new", - url: 'https://octopus.com/whatsnew', - order: 4, - }, - { - title: 'Roadmap', - url: 'https://roadmap.octopus.com/tabs/2-planned', - order: 5, - }, - { - title: 'Octopus vs. Azure DevOps', - url: 'https://octopus.com/azure-devops', - order: 6, - }, - { - title: 'Octopus vs. Jenkins', - url: 'https://octopus.com/jenkins', - order: 7, - }, - ], - }, - { - title: 'Learn', - order: 3, - children: [ - { - title: 'Getting started', - url: '/docs/getting-started', - order: 1, - }, - { - title: 'Guides', - url: 'https://octopus.com/docs/guides', - order: 2, - }, - { - title: 'DevOps handbook', - url: 'https://octopus.com/devops/', - order: 3, - }, - { - title: 'Deployments', - url: '/docs/deployment-process', - order: 4, - }, - { - title: 'Runbooks', - url: '/docs/runbooks', - order: 5, - }, - { - title: 'Training videos', - url: 'https://www.youtube.com/playlist?list=PLAGskdGvlaw268i2ZTPC1ZrxwFjjKIdKH', - order: 6, - }, - ], - }, - { - title: 'Help', - order: 4, - children: [ - { - title: 'Contact', - url: 'https://octopus.com/company/contact', - order: 1, - }, - { - title: 'Help and support', - url: 'https://octopus.com/support', - order: 2, - }, - { - title: 'Community', - url: 'https://octopus.com/community', - order: 3, - }, - { - title: 'Discussion forum', - url: 'https://help.octopus.com/', - order: 4, - }, - { - title: 'Upgrade and renew', - url: 'https://octopus.com/upgrade', - order: 5, - }, - ], - }, - { - title: 'About us', - order: 5, - children: [ - { - title: 'Company', - url: 'https://octopus.com/company', - order: 1, - }, - { - title: 'Partners', - url: 'https://octopus.com/partners', - order: 2, - }, - { - title: 'Careers', - url: 'https://octopus.com/company/careers', - order: 3, - }, - { - title: 'Trust center', - url: 'https://octopus.com/company/trust', - order: 4, - }, - { - title: 'Security', - url: 'https://octopus.com/docs/security', - order: 5, - }, - { - title: 'Webinars and events', - url: 'https://octopus.com/events', - order: 6, - }, - { - title: 'Stickers and swag', - url: 'https://shop.octopus.com/', - order: 7, - }, - ], - }, +export type FooterLink = { + title: string; + url: string; +}; + +// Rendered by components/Footer.astro, in this order. +export const links: FooterLink[] = [ + { title: 'Privacy', url: 'https://octopus.com/legal/privacy' }, + { title: 'GDPR', url: 'https://octopus.com/legal/gdpr' }, + { title: 'Terms', url: 'https://octopus.com/legal/customer-agreement' }, + { title: 'Status', url: 'https://status.octopus.com/' }, + { title: 'Support', url: 'https://octopus.com/support' }, ]; - -/* -See navigation.ts -Allows customisation of the footer navigation - -'categories' -> Auto columns of links for categories -'tags' -> Auto columns of links for tags - -*/ diff --git a/src/data/language.json b/src/data/language.json index 3d59270d31..0d074fd80a 100644 --- a/src/data/language.json +++ b/src/data/language.json @@ -17,6 +17,17 @@ "en": "Read more" } }, + "octopus_footer": { + "last_updated": { + "en": "Last updated" + }, + "copyright": { + "en": "Copyright" + }, + "links_label": { + "en": "Legal and support" + } + }, "octopus_github": { "edit_on_github": { "en": "Edit on GitHub" diff --git a/src/env.d.ts b/src/env.d.ts index e843fe904a..acef35f175 100644 --- a/src/env.d.ts +++ b/src/env.d.ts @@ -1,11 +1,2 @@ /// /// - -interface ImportMetaEnv { - readonly FOOTER_FRAGMENT_URL: string; - readonly SHARED_ASSETS_BASE_URL: string; - readonly SHARED_ASSETS_ORIGIN: string; -} -interface ImportMeta { - readonly env: ImportMetaEnv; -} diff --git a/src/fallback/footer.html b/src/fallback/footer.html deleted file mode 100644 index 44861e67e4..0000000000 --- a/src/fallback/footer.html +++ /dev/null @@ -1,740 +0,0 @@ - - - - diff --git a/src/layouts/Default.astro b/src/layouts/Default.astro index e574e748c4..2fc28c559f 100644 --- a/src/layouts/Default.astro +++ b/src/layouts/Default.astro @@ -21,11 +21,9 @@ import Related from '../components/Related.astro'; import ArticleJourney from '../components/ArticleJourney.astro'; import Feedback from '../components/Feedback.astro'; import EditOnGithub from '../components/EditOnGithub.astro'; -import LastUpdated from '../components/LastUpdated.astro'; import CopyMarkdown from '../components/CopyMarkdown.astro'; import Plausible from 'src/components/Plausible.astro'; -import SharedFooter from 'src/components/SharedFooter.astro'; -import SharedScripts from 'src/components/SharedScripts.astro'; +import Footer from 'src/components/Footer.astro'; type Props = { frontmatter: OriginalFrontmatter; @@ -59,6 +57,9 @@ const isSearchPage = accelerator.urlFormatter.formatAddress(Astro.url.pathname) === searchUrl; const showSearch = !isSearchPage; + +// The footer prints this; the article keeps it in its schema.org markup. +const lastUpdated = frontmatter.modDate ?? frontmatter.pubDate ?? null; --- @@ -97,11 +98,6 @@ const showSearch = !isSearchPage; /> - {metaImage && } + { + lastUpdated && ( + + ) + } @@ -122,9 +126,9 @@ const showSearch = !isSearchPage; /> --> +