diff --git a/.eslintrc.js b/.eslintrc.js index 2d5f2822ac..f6407fa6fa 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -33,6 +33,7 @@ module.exports = { ], 'bsky-internal/use-exact-imports': 'error', 'bsky-internal/use-typed-gates': 'error', + 'bsky-internal/use-prefixed-imports': 'warn', 'simple-import-sort/imports': [ 'warn', { diff --git a/app.config.js b/app.config.js index ddd72f75f0..fe65c4fde5 100644 --- a/app.config.js +++ b/app.config.js @@ -55,6 +55,7 @@ module.exports = function (config) { : undefined const UPDATES_ENABLED = !!UPDATES_CHANNEL + const USE_SENTRY = Boolean(process.env.SENTRY_AUTH_TOKEN) const SENTRY_DIST = `${PLATFORM}.${VERSION}.${IS_TESTFLIGHT ? 'tf' : ''}${ IS_DEV ? 'dev' : '' }` @@ -186,7 +187,15 @@ module.exports = function (config) { }, plugins: [ 'expo-localization', - Boolean(process.env.SENTRY_AUTH_TOKEN) && 'sentry-expo', + USE_SENTRY && [ + '@sentry/react-native/expo', + { + organization: 'blueskyweb', + project: 'react-native', + release: VERSION, + dist: SENTRY_DIST, + }, + ], [ 'expo-build-properties', { @@ -221,6 +230,31 @@ module.exports = function (config) { './plugins/shareExtension/withShareExtensions.js', './plugins/notificationsExtension/withNotificationsExtension.js', './plugins/withAppDelegateReferrer.js', + [ + 'expo-font', + { + fonts: [ + // './assets/fonts/inter/Inter-Thin.otf', + // './assets/fonts/inter/Inter-ThinItalic.otf', + // './assets/fonts/inter/Inter-ExtraLight.otf', + // './assets/fonts/inter/Inter-ExtraLightItalic.otf', + // './assets/fonts/inter/Inter-Light.otf', + // './assets/fonts/inter/Inter-LightItalic.otf', + './assets/fonts/inter/Inter-Regular.otf', + './assets/fonts/inter/Inter-Italic.otf', + './assets/fonts/inter/Inter-Medium.otf', + './assets/fonts/inter/Inter-MediumItalic.otf', + './assets/fonts/inter/Inter-SemiBold.otf', + './assets/fonts/inter/Inter-SemiBoldItalic.otf', + './assets/fonts/inter/Inter-Bold.otf', + './assets/fonts/inter/Inter-BoldItalic.otf', + './assets/fonts/inter/Inter-ExtraBold.otf', + './assets/fonts/inter/Inter-ExtraBoldItalic.otf', + './assets/fonts/inter/Inter-Black.otf', + './assets/fonts/inter/Inter-BlackItalic.otf', + ], + }, + ], ].filter(Boolean), extra: { eas: { @@ -263,7 +297,7 @@ module.exports = function (config) { * @see https://docs.expo.dev/guides/using-sentry/#app-configuration */ { - file: 'sentry-expo/upload-sourcemaps', + file: './postHooks/uploadSentrySourcemapsPostHook', config: { organization: 'blueskyweb', project: 'react-native', diff --git a/assets/fonts/inter/Inter-Black.otf b/assets/fonts/inter/Inter-Black.otf new file mode 100644 index 0000000000..44d1779af6 Binary files /dev/null and b/assets/fonts/inter/Inter-Black.otf differ diff --git a/assets/fonts/inter/Inter-BlackItalic.otf b/assets/fonts/inter/Inter-BlackItalic.otf new file mode 100644 index 0000000000..6fc475e415 Binary files /dev/null and b/assets/fonts/inter/Inter-BlackItalic.otf differ diff --git a/assets/fonts/inter/Inter-Bold.otf b/assets/fonts/inter/Inter-Bold.otf new file mode 100644 index 0000000000..58a38073e8 Binary files /dev/null and b/assets/fonts/inter/Inter-Bold.otf differ diff --git a/assets/fonts/inter/Inter-BoldItalic.otf b/assets/fonts/inter/Inter-BoldItalic.otf new file mode 100644 index 0000000000..e67935aa5a Binary files /dev/null and b/assets/fonts/inter/Inter-BoldItalic.otf differ diff --git a/assets/fonts/inter/Inter-ExtraBold.otf b/assets/fonts/inter/Inter-ExtraBold.otf new file mode 100644 index 0000000000..66cd95228c Binary files /dev/null and b/assets/fonts/inter/Inter-ExtraBold.otf differ diff --git a/assets/fonts/inter/Inter-ExtraBoldItalic.otf b/assets/fonts/inter/Inter-ExtraBoldItalic.otf new file mode 100644 index 0000000000..f269814a64 Binary files /dev/null and b/assets/fonts/inter/Inter-ExtraBoldItalic.otf differ diff --git a/assets/fonts/inter/Inter-ExtraLight.otf b/assets/fonts/inter/Inter-ExtraLight.otf new file mode 100644 index 0000000000..b603db3c77 Binary files /dev/null and b/assets/fonts/inter/Inter-ExtraLight.otf differ diff --git a/assets/fonts/inter/Inter-ExtraLightItalic.otf b/assets/fonts/inter/Inter-ExtraLightItalic.otf new file mode 100644 index 0000000000..f65051941c Binary files /dev/null and b/assets/fonts/inter/Inter-ExtraLightItalic.otf differ diff --git a/assets/fonts/inter/Inter-Italic.otf b/assets/fonts/inter/Inter-Italic.otf new file mode 100644 index 0000000000..f78848b987 Binary files /dev/null and b/assets/fonts/inter/Inter-Italic.otf differ diff --git a/assets/fonts/inter/Inter-Light.otf b/assets/fonts/inter/Inter-Light.otf new file mode 100644 index 0000000000..7da794bd3b Binary files /dev/null and b/assets/fonts/inter/Inter-Light.otf differ diff --git a/assets/fonts/inter/Inter-LightItalic.otf b/assets/fonts/inter/Inter-LightItalic.otf new file mode 100644 index 0000000000..32ef937c52 Binary files /dev/null and b/assets/fonts/inter/Inter-LightItalic.otf differ diff --git a/assets/fonts/inter/Inter-Medium.otf b/assets/fonts/inter/Inter-Medium.otf new file mode 100644 index 0000000000..f44f89adac Binary files /dev/null and b/assets/fonts/inter/Inter-Medium.otf differ diff --git a/assets/fonts/inter/Inter-MediumItalic.otf b/assets/fonts/inter/Inter-MediumItalic.otf new file mode 100644 index 0000000000..1970f57214 Binary files /dev/null and b/assets/fonts/inter/Inter-MediumItalic.otf differ diff --git a/assets/fonts/inter/Inter-Regular.otf b/assets/fonts/inter/Inter-Regular.otf new file mode 100644 index 0000000000..2d0bd1d645 Binary files /dev/null and b/assets/fonts/inter/Inter-Regular.otf differ diff --git a/assets/fonts/inter/Inter-SemiBold.otf b/assets/fonts/inter/Inter-SemiBold.otf new file mode 100644 index 0000000000..52c84550ba Binary files /dev/null and b/assets/fonts/inter/Inter-SemiBold.otf differ diff --git a/assets/fonts/inter/Inter-SemiBoldItalic.otf b/assets/fonts/inter/Inter-SemiBoldItalic.otf new file mode 100644 index 0000000000..b725bfc883 Binary files /dev/null and b/assets/fonts/inter/Inter-SemiBoldItalic.otf differ diff --git a/assets/fonts/inter/Inter-Thin.otf b/assets/fonts/inter/Inter-Thin.otf new file mode 100644 index 0000000000..568a18560c Binary files /dev/null and b/assets/fonts/inter/Inter-Thin.otf differ diff --git a/assets/fonts/inter/Inter-ThinItalic.otf b/assets/fonts/inter/Inter-ThinItalic.otf new file mode 100644 index 0000000000..c5ed37c358 Binary files /dev/null and b/assets/fonts/inter/Inter-ThinItalic.otf differ diff --git a/assets/icons/aspectRatio11_stroke2_corner0_rounded.svg b/assets/icons/aspectRatio11_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..949eba697b --- /dev/null +++ b/assets/icons/aspectRatio11_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/assets/icons/aspectRatio34_stroke2_corner0_rounded.svg b/assets/icons/aspectRatio34_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..50761a05c5 --- /dev/null +++ b/assets/icons/aspectRatio34_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/assets/icons/aspectRatio43_stroke2_corner0_rounded.svg b/assets/icons/aspectRatio43_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..4ca8362e94 --- /dev/null +++ b/assets/icons/aspectRatio43_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/assets/icons/flipHorizontal_stroke2_corner0_rounded.svg b/assets/icons/flipHorizontal_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..0d4c81d2c1 --- /dev/null +++ b/assets/icons/flipHorizontal_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/assets/icons/flipVertical_stroke2_corner0_rounded.svg b/assets/icons/flipVertical_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..42fca985c5 --- /dev/null +++ b/assets/icons/flipVertical_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/assets/icons/textSize_stroke2_corner0_rounded.svg b/assets/icons/textSize_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..6c7537d100 --- /dev/null +++ b/assets/icons/textSize_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/assets/icons/titleCase_stroke2_corner0_rounded.svg b/assets/icons/titleCase_stroke2_corner0_rounded.svg new file mode 100644 index 0000000000..facdfc0e16 --- /dev/null +++ b/assets/icons/titleCase_stroke2_corner0_rounded.svg @@ -0,0 +1 @@ + diff --git a/bskyweb/cmd/bskyweb/server.go b/bskyweb/cmd/bskyweb/server.go index 2d75a2b723..fd80a5ed14 100644 --- a/bskyweb/cmd/bskyweb/server.go +++ b/bskyweb/cmd/bskyweb/server.go @@ -210,6 +210,11 @@ func serve(cctx *cli.Context) error { maxAge = 7 * (60 * 60 * 24) // 1 week } + // fonts can be cached for a year + if strings.HasSuffix(path, ".otf") { + maxAge = 365 * (60 * 60 * 24) // 1 year + } + c.Response().Header().Set("Cache-Control", fmt.Sprintf("public, max-age=%d", maxAge)) return next(c) } diff --git a/bskyweb/static/media/Inter-Black.66e9a87f1c921e844ed4.otf b/bskyweb/static/media/Inter-Black.66e9a87f1c921e844ed4.otf new file mode 100644 index 0000000000..44d1779af6 Binary files /dev/null and b/bskyweb/static/media/Inter-Black.66e9a87f1c921e844ed4.otf differ diff --git a/bskyweb/static/media/Inter-BlackItalic.27b9f0ad06fd13a7b9da.otf b/bskyweb/static/media/Inter-BlackItalic.27b9f0ad06fd13a7b9da.otf new file mode 100644 index 0000000000..6fc475e415 Binary files /dev/null and b/bskyweb/static/media/Inter-BlackItalic.27b9f0ad06fd13a7b9da.otf differ diff --git a/bskyweb/static/media/Inter-Bold.8d330503e1d034ad68de.otf b/bskyweb/static/media/Inter-Bold.8d330503e1d034ad68de.otf new file mode 100644 index 0000000000..58a38073e8 Binary files /dev/null and b/bskyweb/static/media/Inter-Bold.8d330503e1d034ad68de.otf differ diff --git a/bskyweb/static/media/Inter-BoldItalic.bb17e63f9baa0d861a20.otf b/bskyweb/static/media/Inter-BoldItalic.bb17e63f9baa0d861a20.otf new file mode 100644 index 0000000000..e67935aa5a Binary files /dev/null and b/bskyweb/static/media/Inter-BoldItalic.bb17e63f9baa0d861a20.otf differ diff --git a/bskyweb/static/media/Inter-ExtraBold.ff2581a193bf6b7e0b06.otf b/bskyweb/static/media/Inter-ExtraBold.ff2581a193bf6b7e0b06.otf new file mode 100644 index 0000000000..66cd95228c Binary files /dev/null and b/bskyweb/static/media/Inter-ExtraBold.ff2581a193bf6b7e0b06.otf differ diff --git a/bskyweb/static/media/Inter-ExtraBoldItalic.0e50b40728d24d40fdf4.otf b/bskyweb/static/media/Inter-ExtraBoldItalic.0e50b40728d24d40fdf4.otf new file mode 100644 index 0000000000..f269814a64 Binary files /dev/null and b/bskyweb/static/media/Inter-ExtraBoldItalic.0e50b40728d24d40fdf4.otf differ diff --git a/bskyweb/static/media/Inter-Italic.95778eb0c75dc956257e.otf b/bskyweb/static/media/Inter-Italic.95778eb0c75dc956257e.otf new file mode 100644 index 0000000000..f78848b987 Binary files /dev/null and b/bskyweb/static/media/Inter-Italic.95778eb0c75dc956257e.otf differ diff --git a/bskyweb/static/media/Inter-Medium.296aa2d65964269836b3.otf b/bskyweb/static/media/Inter-Medium.296aa2d65964269836b3.otf new file mode 100644 index 0000000000..f44f89adac Binary files /dev/null and b/bskyweb/static/media/Inter-Medium.296aa2d65964269836b3.otf differ diff --git a/bskyweb/static/media/Inter-MediumItalic.0e57e17a6311368e2114.otf b/bskyweb/static/media/Inter-MediumItalic.0e57e17a6311368e2114.otf new file mode 100644 index 0000000000..1970f57214 Binary files /dev/null and b/bskyweb/static/media/Inter-MediumItalic.0e57e17a6311368e2114.otf differ diff --git a/bskyweb/static/media/Inter-Regular.1f5ed03b6dd9fd1f9982.otf b/bskyweb/static/media/Inter-Regular.1f5ed03b6dd9fd1f9982.otf new file mode 100644 index 0000000000..2d0bd1d645 Binary files /dev/null and b/bskyweb/static/media/Inter-Regular.1f5ed03b6dd9fd1f9982.otf differ diff --git a/bskyweb/static/media/Inter-SemiBold.2277990330981b8409bb.otf b/bskyweb/static/media/Inter-SemiBold.2277990330981b8409bb.otf new file mode 100644 index 0000000000..52c84550ba Binary files /dev/null and b/bskyweb/static/media/Inter-SemiBold.2277990330981b8409bb.otf differ diff --git a/bskyweb/static/media/Inter-SemiBoldItalic.f62fea3df3a521d6c8a7.otf b/bskyweb/static/media/Inter-SemiBoldItalic.f62fea3df3a521d6c8a7.otf new file mode 100644 index 0000000000..b725bfc883 Binary files /dev/null and b/bskyweb/static/media/Inter-SemiBoldItalic.f62fea3df3a521d6c8a7.otf differ diff --git a/bskyweb/static/media/MaterialIcons.f20305dee9d396fea5c7.ttf b/bskyweb/static/media/MaterialIcons.f20305dee9d396fea5c7.ttf new file mode 100644 index 0000000000..9d09b0feb8 Binary files /dev/null and b/bskyweb/static/media/MaterialIcons.f20305dee9d396fea5c7.ttf differ diff --git a/bskyweb/templates/base.html b/bskyweb/templates/base.html index 5dc5a9e8a2..b0c3c2195e 100644 --- a/bskyweb/templates/base.html +++ b/bskyweb/templates/base.html @@ -13,7 +13,105 @@ + + + + + + + + + + + + +