feeds-fun 1.22.5 → 1.22.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/RuleForList.vue +6 -5
- package/src/components/page_footer/Footer.vue +8 -0
- package/src/components/tags/Base.vue +2 -0
- package/src/components/tags/RuleTag.vue +4 -1
- package/src/logic/settings.ts +2 -1
- package/src/logic/utils.ts +1 -1
- package/src/router/index.ts +6 -0
- package/src/stores/globalSettings.ts +7 -4
- package/vitest.config.ts +1 -0
package/package.json
CHANGED
|
@@ -24,6 +24,7 @@
|
|
|
24
24
|
v-for="tag of rule.tags"
|
|
25
25
|
:key="tag"
|
|
26
26
|
:uid="tag"
|
|
27
|
+
:excluded="rule.excludedTags.includes(tag)"
|
|
27
28
|
:css-modifier="cssModifiers[tag]" />
|
|
28
29
|
</div>
|
|
29
30
|
</div>
|
|
@@ -80,11 +81,11 @@
|
|
|
80
81
|
|
|
81
82
|
const cssModifiers: {[key: string]: string} = {};
|
|
82
83
|
|
|
84
|
+
const modifier = properties.rule.score > 0 ? "positive" : "negative";
|
|
85
|
+
|
|
86
|
+
console.log("score", properties.rule.score, "modifier", modifier);
|
|
87
|
+
|
|
83
88
|
for (const tag of properties.rule.tags) {
|
|
84
|
-
|
|
85
|
-
cssModifiers[tag] = "negative";
|
|
86
|
-
continue;
|
|
87
|
-
}
|
|
88
|
-
cssModifiers[tag] = "positive";
|
|
89
|
+
cssModifiers[tag] = modifier;
|
|
89
90
|
}
|
|
90
91
|
</script>
|
|
@@ -73,6 +73,14 @@
|
|
|
73
73
|
Privacy Policy
|
|
74
74
|
</a>
|
|
75
75
|
|
|
76
|
+
<a
|
|
77
|
+
v-if="settings.crmImpressum"
|
|
78
|
+
:href="router.resolve({name: 'impressum'}).href"
|
|
79
|
+
class="ffun-normal-link"
|
|
80
|
+
@click.prevent="router.push({name: 'impressum'})">
|
|
81
|
+
Impressum
|
|
82
|
+
</a>
|
|
83
|
+
|
|
76
84
|
<a
|
|
77
85
|
v-if="!globalState.isSingleUserMode"
|
|
78
86
|
href="#"
|
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
<div
|
|
3
3
|
:class="classes"
|
|
4
4
|
@click.prevent="onClick()">
|
|
5
|
-
<tag-base
|
|
5
|
+
<tag-base
|
|
6
|
+
:tag-info="tagInfo"
|
|
7
|
+
:excluded="excluded" />
|
|
6
8
|
</div>
|
|
7
9
|
</template>
|
|
8
10
|
|
|
@@ -26,6 +28,7 @@
|
|
|
26
28
|
const properties = defineProps<{
|
|
27
29
|
uid: string;
|
|
28
30
|
cssModifier: string;
|
|
31
|
+
excluded: boolean;
|
|
29
32
|
}>();
|
|
30
33
|
|
|
31
34
|
const tagInfo = computed(() => {
|
package/src/logic/settings.ts
CHANGED
|
@@ -4,7 +4,7 @@ export const version = __APP_VERSION__;
|
|
|
4
4
|
|
|
5
5
|
export const authRefreshInterval = import.meta.env.VITE_FFUN_AUTH_REFRESH_INTERVAL || 10 * 60 * 1000;
|
|
6
6
|
|
|
7
|
-
export const blog = import.meta.env.VITE_FFUN_BLOG || "https://
|
|
7
|
+
export const blog = import.meta.env.VITE_FFUN_BLOG || "https://feeds.fun/blog";
|
|
8
8
|
export const roadmap = import.meta.env.VITE_FFUN_ROADMAP || "https://github.com/users/Tiendil/projects/1";
|
|
9
9
|
export const githubRepo = import.meta.env.VITE_FFUN_GITHUB_REPO || "https://github.com/Tiendil/feeds.fun";
|
|
10
10
|
export const discordInvite = import.meta.env.VITE_FFUN_DISCORD_INVITE || "https://discord.gg/C5RVusHQXy";
|
|
@@ -20,6 +20,7 @@ export const utmLifetime = import.meta.env.VITE_FFUN_UTM_LIFETIME || 7; // days
|
|
|
20
20
|
|
|
21
21
|
export const crmTerms = import.meta.env.VITE_FFUN_CRM_TERMS || null;
|
|
22
22
|
export const crmPrivacy = import.meta.env.VITE_FFUN_CRM_PRIVACY || null;
|
|
23
|
+
export const crmImpressum = import.meta.env.VITE_FFUN_CRM_IMPRESSUM || null;
|
|
23
24
|
|
|
24
25
|
export const hasCollections = import.meta.env.VITE_FFUN_HAS_COLLECTIONS == "true" || false;
|
|
25
26
|
|
package/src/logic/utils.ts
CHANGED
|
@@ -137,7 +137,7 @@ export function chooseTagByUsage({
|
|
|
137
137
|
exclude = [];
|
|
138
138
|
}
|
|
139
139
|
|
|
140
|
-
const tags = _.toPairs(tagsCount).sort((a, b) => {
|
|
140
|
+
const tags = _.toPairs(tagsCount).sort((a: [string, number], b: [string, number]) => {
|
|
141
141
|
if (a[1] === b[1]) {
|
|
142
142
|
return a[0].localeCompare(b[0]);
|
|
143
143
|
}
|
package/src/router/index.ts
CHANGED
|
@@ -69,6 +69,12 @@ const router = createRouter({
|
|
|
69
69
|
component: CRMView,
|
|
70
70
|
props: {content: settings.crmPrivacy, kind: "privacy"}
|
|
71
71
|
},
|
|
72
|
+
{
|
|
73
|
+
path: "/impressum",
|
|
74
|
+
name: "impressum",
|
|
75
|
+
component: CRMView,
|
|
76
|
+
props: {content: settings.crmImpressum, kind: "impressum"}
|
|
77
|
+
},
|
|
72
78
|
{
|
|
73
79
|
path: "/:pathMatch(.*)*",
|
|
74
80
|
redirect: "/"
|
|
@@ -139,19 +139,22 @@ export const useGlobalSettingsStore = defineStore("globalSettings", () => {
|
|
|
139
139
|
);
|
|
140
140
|
}
|
|
141
141
|
|
|
142
|
-
function enumBackendSettings
|
|
143
|
-
|
|
142
|
+
function enumBackendSettings<TValue extends t.UserSettingsValue, TProperty extends {default?: boolean}>(
|
|
143
|
+
kind: string,
|
|
144
|
+
enumProperties: Map<TValue, TProperty>
|
|
145
|
+
) {
|
|
146
|
+
const defaultEntry = _.find([...enumProperties], ([, prop]: [TValue, TProperty]) => prop.default === true);
|
|
144
147
|
|
|
145
148
|
if (!defaultEntry) {
|
|
146
149
|
throw new Error(`No default entry found for enum "${kind}"`);
|
|
147
150
|
}
|
|
148
151
|
|
|
149
|
-
let defaultValue = defaultEntry[0];
|
|
152
|
+
let defaultValue: TValue = defaultEntry[0];
|
|
150
153
|
|
|
151
154
|
return backendSettings(
|
|
152
155
|
kind,
|
|
153
156
|
(rawValue: t.UserSettingsValue) => {
|
|
154
|
-
return enumProperties.has(rawValue);
|
|
157
|
+
return enumProperties.has(rawValue as TValue);
|
|
155
158
|
},
|
|
156
159
|
defaultValue
|
|
157
160
|
);
|