@websline/cms-view-utils 1.5.3 → 1.6.0
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 +3 -3
- package/src/client/fetchFaqs.js +9 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@websline/cms-view-utils",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"files": [
|
|
6
6
|
"src",
|
|
@@ -21,10 +21,10 @@
|
|
|
21
21
|
"devDependencies": {
|
|
22
22
|
"@eslint/compat": "^2.1.0",
|
|
23
23
|
"@eslint/js": "^10.0.1",
|
|
24
|
-
"eslint": "^10.
|
|
24
|
+
"eslint": "^10.8.0",
|
|
25
25
|
"eslint-config-prettier": "^10.1.8",
|
|
26
26
|
"eslint-plugin-svelte": "^3.22.0",
|
|
27
|
-
"globals": "^17.
|
|
27
|
+
"globals": "^17.9.0",
|
|
28
28
|
"prettier": "^3.9.6",
|
|
29
29
|
"prettier-plugin-svelte": "^4.1.1",
|
|
30
30
|
"prettier-plugin-tailwindcss": "^0.8.1",
|
package/src/client/fetchFaqs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const fetchFaqs = async ({ excludeId, limit, locale, tags }) => {
|
|
1
|
+
const fetchFaqs = async ({ excludeId, limit, locale, tags, groups }) => {
|
|
2
2
|
const params = new URLSearchParams();
|
|
3
3
|
|
|
4
4
|
if (excludeId != null && excludeId !== "") {
|
|
@@ -17,6 +17,14 @@ const fetchFaqs = async ({ excludeId, limit, locale, tags }) => {
|
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
+
if (Array.isArray(groups)) {
|
|
21
|
+
for (const group of groups) {
|
|
22
|
+
if (group != null && group !== "") {
|
|
23
|
+
params.append("groups", group);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
20
28
|
const query = params.toString();
|
|
21
29
|
const url = `/api/cms/api/public/abm-faqs/${locale}${query ? `?${query}` : ""}`;
|
|
22
30
|
|