pixelfed/patches/0006-Link-legal-notice.patch

53 lines
363 KiB
Diff
Raw Permalink Normal View History

2024-05-26 11:45:38 +00:00
From 952b84c634d64f003c06aab3ed871c4dae580f79 Mon Sep 17 00:00:00 2001
2023-10-24 09:47:34 +00:00
From: chris <cg@zknt.org>
2024-05-26 11:45:38 +00:00
Date: Sun, 26 May 2024 13:43:52 +0200
2023-10-08 13:00:18 +00:00
Subject: [PATCH 6/6] Link legal notice
local jurisdiction requires a prominent link to a legal notice at the frontpage.
---
public/js/landing.js | 2 +-
resources/assets/components/landing/sections/footer.vue | 2 +-
resources/views/layouts/partial/footer.blade.php | 4 +---
3 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/public/js/landing.js b/public/js/landing.js
2024-04-20 14:23:22 +00:00
index 9c93b6e2..be37d2d0 100644
2023-10-08 13:00:18 +00:00
--- a/public/js/landing.js
+++ b/public/js/landing.js
@@ -1,2 +1,2 @@
/*! For license information please see landing.js.LICENSE.txt */
2024-04-20 14:23:22 +00:00
-(self.webpackChunkpixelfed=self.webpackChunkpixelfed||[]).push([[3891],{75948:(e,t,o)=>{"use strict";o.r(t),o.d(t,{default:()=>u});var a=o(77387),s=o(25100);function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function n(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return Array.from(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,a=new Array(t);o<t;o++)a[o]=e[o];return a}function l(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,a)}return o}function c(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?l(Object(o),!0).forEach((function(t){d(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):l(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}function d(e,t,o){var a;return a=function(e,t){if("object"!=i(e)||!e)return e;var o=e[Symbol.toPrimitive];if(void 0!==o){var a=o.call(e,t||"default");if("object"!=i(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==i(a)?a:a+"")in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}const u={components:{"user-card":a.default,intersect:s.default},data:function(){return{loading:!0,config:window.pfl,pagination:void 0,feed:[],isEmpty:!1,canLoadMore:!1,isIntersecting:!1,isLoadingMore:!1}},beforeMount:function(){0==this.config.show_directory&&this.$router.push("/")},mounted:function(){this.init()},methods:{init:function(){var e=this;axios.get("/api/landing/v1/directory").then((function(t){t.data.data.length||(e.isEmpty=!0),e.feed=t.data.data,e.pagination=c(c({},t.data.links),t.data.meta)})).finally((function(){e.canLoadMore=!0,e.$nextTick((function(){e.loading=!1}))}))},enterIntersect:function(e){var t=this;!this.isIntersecting&&this.pagination.next_cursor&&(this.isIntersecting=!0,this.isLoadingMore=!0,axios.get("/api/landing/v1/directory",{params:{cursor:this.pagination.next_cursor}}).then((function(e){var o;(o=t.feed).push.apply(o,n(e.data.data)),t.pagination=c(c({},e.data.links),e.data.meta)})).finally((function(){t.pagination.next_cursor?t.canLoadMore=!0:t.canLoadMore=!1,t.isLoadingMore=!1,t.isIntersecting=!1})),console.log(e))}}}},22912:(e,t,o)=>{"use strict";o.r(t),o.d(t,{default:()=>a});const a={components:{"post-card":o(42060).default},data:function(){return{loading:!0,config:window.pfl,isFetching:!1,range:"daily",ranges:["daily","monthly","yearly"],rangeIndex:0,feed:[]}},beforeMount:function(){0==this.config.show_explore_feed&&this.$router.push("/")},mounted:function(){this.init()},methods:{init:function(){var e=this;axios.get("/api/pixelfed/v2/discover/posts/trending?range=daily").then((function(t){t&&t.data.length>3?(e.feed=t.data,e.loading=!1):(e.rangeIndex++,e.fetchTrending())}))},fetchTrending:function(){var e=this;this.isFetching||this.rangeIndex>=3||(this.isFetching=!0,axios.get("/api/pixelfed/v2/discover/posts/trending",{params:{range:this.ranges[this.rangeIndex]}}).then((function(t){t&&t.data.length&&2==e.rangeIndex&&t.data.length>3?(e.feed=t.data,e.loading=!1):(e.rangeIndex++,e.isFetch
2023-10-08 13:00:18 +00:00
\ No newline at end of file
2024-04-20 14:23:22 +00:00
+(self.webpackChunkpixelfed=self.webpackChunkpixelfed||[]).push([[3891],{75948:(e,t,o)=>{"use strict";o.r(t),o.d(t,{default:()=>u});var a=o(77387),s=o(25100);function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function n(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return r(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return Array.from(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return r(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,a=new Array(t);o<t;o++)a[o]=e[o];return a}function l(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,a)}return o}function c(e){for(var t=1;t<arguments.length;t++){var o=null!=arguments[t]?arguments[t]:{};t%2?l(Object(o),!0).forEach((function(t){d(e,t,o[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):l(Object(o)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(o,t))}))}return e}function d(e,t,o){var a;return a=function(e,t){if("object"!=i(e)||!e)return e;var o=e[Symbol.toPrimitive];if(void 0!==o){var a=o.call(e,t||"default");if("object"!=i(a))return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==i(a)?a:a+"")in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e}const u={components:{"user-card":a.default,intersect:s.default},data:function(){return{loading:!0,config:window.pfl,pagination:void 0,feed:[],isEmpty:!1,canLoadMore:!1,isIntersecting:!1,isLoadingMore:!1}},beforeMount:function(){0==this.config.show_directory&&this.$router.push("/")},mounted:function(){this.init()},methods:{init:function(){var e=this;axios.get("/api/landing/v1/directory").then((function(t){t.data.data.length||(e.isEmpty=!0),e.feed=t.data.data,e.pagination=c(c({},t.data.links),t.data.meta)})).finally((function(){e.canLoadMore=!0,e.$nextTick((function(){e.loading=!1}))}))},enterIntersect:function(e){var t=this;!this.isIntersecting&&this.pagination.next_cursor&&(this.isIntersecting=!0,this.isLoadingMore=!0,axios.get("/api/landing/v1/directory",{params:{cursor:this.pagination.next_cursor}}).then((function(e){var o;(o=t.feed).push.apply(o,n(e.data.data)),t.pagination=c(c({},e.data.links),e.data.meta)})).finally((function(){t.pagination.next_cursor?t.canLoadMore=!0:t.canLoadMore=!1,t.isLoadingMore=!1,t.isIntersecting=!1})),console.log(e))}}}},22912:(e,t,o)=>{"use strict";o.r(t),o.d(t,{default:()=>a});const a={components:{"post-card":o(42060).default},data:function(){return{loading:!0,config:window.pfl,isFetching:!1,range:"daily",ranges:["daily","monthly","yearly"],rangeIndex:0,feed:[]}},beforeMount:function(){0==this.config.show_explore_feed&&this.$router.push("/")},mounted:function(){this.init()},methods:{init:function(){var e=this;axios.get("/api/pixelfed/v2/discover/posts/trending?range=daily").then((function(t){t&&t.data.length>3?(e.feed=t.data,e.loading=!1):(e.rangeIndex++,e.fetchTrending())}))},fetchTrending:function(){var e=this;this.isFetching||this.rangeIndex>=3||(this.isFetching=!0,axios.get("/api/pixelfed/v2/discover/posts/trending",{params:{range:this.ranges[this.rangeIndex]}}).then((function(t){t&&t.data.length&&2==e.rangeIndex&&t.data.length>3?(e.feed=t.data,e.loading=!1):(e.rangeIndex++,e.isFetch
2023-10-08 13:00:18 +00:00
diff --git a/resources/assets/components/landing/sections/footer.vue b/resources/assets/components/landing/sections/footer.vue
index 8733030e..274f6f23 100644
--- a/resources/assets/components/landing/sections/footer.vue
+++ b/resources/assets/components/landing/sections/footer.vue
@@ -7,7 +7,7 @@
<div class="spacer">·</div>
<a href="/site/privacy">Privacy</a>
<div class="spacer">·</div>
- <a href="https://pixelfed.org/mobile-apps" target="_blank">Mobile Apps</a>
+ <a href="/site/legal-notice">Impressum / Legal Notice</a>
</div>
<div class="footer-component-attribution">
diff --git a/resources/views/layouts/partial/footer.blade.php b/resources/views/layouts/partial/footer.blade.php
index 5fb4e27d..6188d2f3 100644
--- a/resources/views/layouts/partial/footer.blade.php
+++ b/resources/views/layouts/partial/footer.blade.php
@@ -7,9 +7,7 @@
<a href="{{route('site.terms')}}" class="text-dark p-2">{{__('site.terms')}}</a>
<a href="{{route('site.privacy')}}" class="text-dark p-2">{{__('site.privacy')}}</a>
<a href="{{route('site.language')}}" class="text-dark p-2">{{__('site.language')}}</a>
- @if(config_cache('instance.has_legal_notice'))
- <a href="/site/legal-notice" class="text-dark p-2">Legal Notice</a>
- @endif
+ <a href="/site/legal-notice" class="text-dark p-2">Legal Notice</a>
</p>
<p class="text-center text-muted small mb-0">
<span class="text-muted">© {{date('Y')}} {{config('pixelfed.domain.app')}}</span>
--
2024-05-26 11:45:38 +00:00
2.45.0
2023-10-08 13:00:18 +00:00