Skip to content

πŸ“ˆ Open source, privacy-first web analytics β€” a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!

launched a changelog page

Blue Mouse3020275b0fc2
diff --git a/package.json b/package.json
index b50387907..c81c11a9f 100644
--- a/package.json
+++ b/package.json
@@ -146,6 +146,7 @@
]
},
"devDependencies": {
+ "@tailwindcss/typography": "^0.5.8",
"autoprefixer": "^10.4.13",
"cross-env": "^7.0.3",
"eslint": "^8.30.0",
diff --git a/public/locales/en.json b/public/locales/en.json
index bc41a3da1..5650c6696 100644
--- a/public/locales/en.json
+++ b/public/locales/en.json
@@ -600,6 +600,7 @@
"docs": "Documentation",
"billing": "Billing",
"contact": "Contact",
+ "changelog": "Changelog",
"main": "Ultimate open-source analytics to satisfy all your needs"
},
"footer": {
@@ -626,6 +627,7 @@
"terms": "Terms",
"status": "Status",
"donate": "Donate",
+ "changelog": "Changelog",
"about": "About us",
"comparisons": "Comparisons"
}
diff --git a/src/App.js b/src/App.js
index 812442961..0f80d9b35 100644
--- a/src/App.js
+++ b/src/App.js
@@ -44,6 +44,7 @@ const Privacy = lazy(() => import('pages/Privacy'))
const ConfirmShare = lazy(() => import('pages/Project/ConfirmShare'))
const Terms = lazy(() => import('pages/Terms'))
const NotFound = lazy(() => import('pages/NotFound'))
+const Changelog = lazy(() => import('pages/Changelog'))
const About = lazy(() => import('pages/About'))
const minimalFooterPages = [
@@ -190,6 +191,7 @@ const App = () => {
<Route path={routes.privacy} component={Privacy} exact />
<Route path={routes.terms} component={Terms} exact />
<Route path={routes.confirm_share} component={ConfirmShare} exact />
+ <Route path={routes.changelog} component={Changelog} exact />
<Route path={routes.about} component={About} exact />
<Route path='*' component={NotFound} />
</Switch>
diff --git a/src/components/Footer/index.jsx b/src/components/Footer/index.jsx
index 7fa000a00..e2975546b 100644
--- a/src/components/Footer/index.jsx
+++ b/src/components/Footer/index.jsx
@@ -8,12 +8,10 @@ import PropTypes from 'prop-types'
import {
isSelfhosted, DONATE_URL, FIREFOX_ADDON_URL, CHROME_EXTENSION_URL, GITHUB_URL,
- LINKEDIN_URL, STATUSPAGE_URL, TWITTER_URL, BLOG_URL, UTM_GENERATOR_URL,
+ LINKEDIN_URL, STATUSPAGE_URL, TWITTER_URL, BLOG_URL, UTM_GENERATOR_URL, SWETRIX_VS_GOOGLE,
} from 'redux/constants'
import routes from 'routes'
-const SWETRIX_VS_GOOGLE = 'https://blog.swetrix.com/post/vs-google-analytics/'
-
const navigation = {
support: [
(authenticated) => (authenticated ? { key: 'billing', href: routes.billing } : { key: 'pricing', href: `${routes.main}#pricing` }),
@@ -23,6 +21,7 @@ const navigation = {
],
company: [
{ key: 'about', href: routes.about, internal: true },
+ { key: 'changelog', href: routes.changelog, internal: true },
{ key: 'status', href: STATUSPAGE_URL },
{ key: 'donate', href: DONATE_URL },
{ key: 'blog', href: BLOG_URL },
diff --git a/src/pages/Changelog/index.jsx b/src/pages/Changelog/index.jsx
new file mode 100644
index 000000000..355b1fb00
--- /dev/null
+++ b/src/pages/Changelog/index.jsx
@@ -0,0 +1,94 @@
+/* eslint-disable jsx-a11y/anchor-has-content */
+import React from 'react'
+import _map from 'lodash/map'
+import { useTranslation } from 'react-i18next'
+import dayjs from 'dayjs'
+
+import { SWETRIX_VS_GOOGLE } from 'redux/constants'
+import Title from 'components/Title'
+
+// Date format: YYYY-MM-DD
+const changelog = [
+ {
+ date: '2022-12-30',
+ changes: [
+ 'Added an ability to see live visitors on your website. Now you\'re able to not only see how many visitors you have, but actually see some information about them.',
+ 'Added new metric: session duration. Now you\'re able to see how long your users are staying on your website.',
+ 'Added new chart metrics: bounce rate, views per session, trendlines and session duration.',
+ <>
+ Added the comparisons column to the footer. There&apos;s only
+ {' '}
+ <a href={SWETRIX_VS_GOOGLE} className='font-medium text-indigo-600 hover:text-indigo-500 dark:text-indigo-400 dark:hover:text-indigo-500' target='_blank' rel='noopener noreferrer'>
+ Google Analytics comparison
+ </a>
+ {' '}
+ for now, but more will be added soon.
+ </>,
+ 'Improved chart colours.',
+ 'Launched the changelog page! πŸŽ‰',
+ ],
+ },
+]
+
+const Changelog = () => {
+ const { t } = useTranslation('common')
+
+ return (
+ <Title title={t('titles.changelog')}>
+ <div className='bg-gray-50 dark:bg-gray-800 min-h-min-footer'>
+ <div className='w-11/12 md:w-4/5 mx-auto pb-16 pt-12 px-4 sm:px-6 lg:px-8 whitespace-pre-line'>
+ <h1 className='text-4xl font-bold text-gray-900 dark:text-gray-50 tracking-tight'>
+ {t('titles.changelog')}
+ </h1>
+
+ <div className='relative sm:ml-[calc(2rem+1px)] md:ml-[calc(3.5rem+1px)] lg:ml-[calc(11rem)] sm:pb-12 mt-10'>
+ <div className='hidden absolute top-3 bottom-0 right-full mr-7 md:mr-[3.25rem] w-px bg-slate-200 dark:bg-slate-700 sm:block' />
+ <div className='space-y-16'>
+ {_map(changelog, (item) => {
+ const date = dayjs(item.date).format('YYYY-MM-DDT00:00:00.000Z')
+ const displayDate = dayjs(item.date).locale('en').format('MMM DD, YYYY')
+
+ return (
+ <div key={item.date} className='relative group'>
+ <div className='absolute -inset-y-2.5 -inset-x-4 md:-inset-y-4 md:-inset-x-6 sm:rounded-2xl group-hover:bg-slate-50/70 dark:group-hover:bg-slate-800/50' />
+ <svg
+ viewBox='0 0 9 9'
+ className='hidden absolute right-full mr-6 top-2 text-slate-200 dark:text-slate-600 md:mr-12 w-[calc(0.5rem+1px)] h-[calc(0.5rem+1px)] overflow-visible sm:block'
+ >
+ <circle
+ cx='4.5'
+ cy='4.5'
+ r='4.5'
+ stroke='currentColor'
+ className='fill-white dark:fill-slate-800'
+ strokeWidth={2}
+ />
+ </svg>
+ <div className='relative'>
+ <ul className='list-disc text-gray-900 dark:text-gray-50 relative top-7 lg:top-0 lg:block text-base mt-2 mb-4 prose prose-slate prose-a:relative prose-a:z-10 dark:prose-dark line-clamp-2'>
+ {_map(item.changes, (change) => (
+ <li key={change}>{change}</li>
+ ))}
+ </ul>
+ <dl className='absolute left-1.5 top-0 lg:left-auto lg:right-full lg:mr-[calc(5rem+1px)]'>
+ <dt className='sr-only'>Date</dt>
+ <dd className='whitespace-nowrap text-sm leading-6 text-slate-700 dark:text-slate-300'>
+ <time dateTime={date}>
+ {displayDate}
+ </time>
+ </dd>
+ </dl>
+ </div>
+ </div>
+ )
+ })}
+ </div>
+ </div>
+
+ </div>
+ </div>
+ </Title>
+ )
+}
+
+export default Changelog
diff --git a/src/redux/constants/index.js b/src/redux/constants/index.js
index 6a5afa72b..4f5c4caa4 100644
--- a/src/redux/constants/index.js
+++ b/src/redux/constants/index.js
@@ -111,6 +111,8 @@ export const UTM_GENERATOR_URL = 'https://url.swetrix.com'
export const MARKETPLACE_URL = 'https://marketplace.swetrix.com'
export const CDN_URL = process.env.REACT_APP_CDN_URL
+export const SWETRIX_VS_GOOGLE = 'https://blog.swetrix.com/post/vs-google-analytics/'
+
export const isDevelopment = !process.env.NODE_ENV || process.env.NODE_ENV === 'development'
export const SUPPORTED_THEMES = ['light', 'dark']
diff --git a/src/routes.js b/src/routes.js
index 088f815a5..4389e1c2b 100644
--- a/src/routes.js
+++ b/src/routes.js
@@ -18,6 +18,7 @@ const routes = Object.freeze({
privacy: '/privacy',
terms: '/terms',
contact: '/contact',
+ changelog: '/changelog',
about: '/about',
})
diff --git a/tailwind.config.js b/tailwind.config.js
index 5102ce715..aa4b54aa2 100644
--- a/tailwind.config.js
+++ b/tailwind.config.js
@@ -60,5 +60,6 @@ module.exports = {
},
plugins: [
require('@tailwindcss/forms'),
+ require('@tailwindcss/typography'),
],
}