Skip to content

Commit 622e2cd

Browse files
committed
chore: add action to fixture data
- Added action property - Action opens internal content - Content type and id specified
1 parent 5c7ed5c commit 622e2cd

File tree

4 files changed

+81
-11
lines changed

4 files changed

+81
-11
lines changed

lib/src/fixtures/categories.json

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,44 @@
33
"id": "c1a2b3c4-d5e6-f789-0123-456789abcdef",
44
"name": "Technology",
55
"description": "News about software development, hardware, and the internet.",
6-
"icon_url": null
6+
"icon_url": null,
7+
"action": {
8+
"type": "open_internal_content",
9+
"content_id": "c1a2b3c4-d5e6-f789-0123-456789abcdef",
10+
"content_type": "category"
11+
}
712
},
813
{
914
"id": "c2b3c4d5-e6f7-a890-1234-567890abcdef",
1015
"name": "Mobile Development",
1116
"description": "Articles related to mobile app development for iOS and Android.",
12-
"icon_url": null
17+
"icon_url": null,
18+
"action": {
19+
"type": "open_internal_content",
20+
"content_id": "c2b3c4d5-e6f7-a890-1234-567890abcdef",
21+
"content_type": "category"
22+
}
1323
},
1424
{
1525
"id": "c3d4e5f6-a7b8-c901-d234-e56789abcdef",
1626
"name": "Business",
1727
"description": "News about companies, finance, and the economy.",
18-
"icon_url": null
28+
"icon_url": null,
29+
"action": {
30+
"type": "open_internal_content",
31+
"content_id": "c3d4e5f6-a7b8-c901-d234-e56789abcdef",
32+
"content_type": "category"
33+
}
1934
},
2035
{
2136
"id": "c4e5f6a7-b8c9-d012-e345-f67890abcdef",
2237
"name": "Sports",
2338
"description": "Latest updates from the world of sports.",
24-
"icon_url": null
39+
"icon_url": null,
40+
"action": {
41+
"type": "open_internal_content",
42+
"content_id": "c4e5f6a7-b8c9-d012-e345-f67890abcdef",
43+
"content_type": "category"
44+
}
2545
}
2646
]

lib/src/fixtures/countries.json

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,44 @@
33
"id": "country-us",
44
"iso_code": "US",
55
"name": "United States",
6-
"flag_url": "https://example.com/flags/us.png"
6+
"flag_url": "https://example.com/flags/us.png",
7+
"action": {
8+
"type": "open_internal_content",
9+
"content_id": "country-us",
10+
"content_type": "country"
11+
}
712
},
813
{
914
"id": "country-gb",
1015
"iso_code": "GB",
1116
"name": "United Kingdom",
12-
"flag_url": "https://example.com/flags/gb.png"
17+
"flag_url": "https://example.com/flags/gb.png",
18+
"action": {
19+
"type": "open_internal_content",
20+
"content_id": "country-gb",
21+
"content_type": "country"
22+
}
1323
},
1424
{
1525
"id": "country-ca",
1626
"iso_code": "CA",
1727
"name": "Canada",
18-
"flag_url": "https://example.com/flags/ca.png"
28+
"flag_url": "https://example.com/flags/ca.png",
29+
"action": {
30+
"type": "open_internal_content",
31+
"content_id": "country-ca",
32+
"content_type": "country"
33+
}
1934
},
2035
{
2136
"id": "country-de",
2237
"iso_code": "DE",
2338
"name": "Germany",
24-
"flag_url": "https://example.com/flags/de.png"
39+
"flag_url": "https://example.com/flags/de.png",
40+
"action": {
41+
"type": "open_internal_content",
42+
"content_id": "country-de",
43+
"content_type": "country"
44+
}
2545
}
2646
]

lib/src/fixtures/headlines.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@
1616
"id": "c1a2b3c4-d5e6-f789-0123-456789abcdef",
1717
"name": "Technology",
1818
"description": "News about software development and frameworks."
19+
},
20+
"action": {
21+
"type": "open_internal_content",
22+
"content_id": "a1b2c3d4-e5f6-7890-1234-567890abcdef",
23+
"content_type": "headline"
1924
}
2025
},
2126
{
@@ -35,6 +40,11 @@
3540
"id": "c2b3c4d5-e6f7-a890-1234-567890abcdef",
3641
"name": "Mobile Development",
3742
"description": "Articles related to mobile app development."
43+
},
44+
"action": {
45+
"type": "open_internal_content",
46+
"content_id": "b2c3d4e5-f6a7-8901-2345-67890abcdef0",
47+
"content_type": "headline"
3848
}
3949
}
4050
]

lib/src/fixtures/sources.json

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,12 @@
66
"url": "https://vgv.dev/blog",
77
"type": "blog",
88
"language": "en",
9-
"headquarters": null
9+
"headquarters": null,
10+
"action": {
11+
"type": "open_internal_content",
12+
"content_id": "s1a2b3c4-d5e6-f789-0123-456789abcdef",
13+
"content_type": "source"
14+
}
1015
},
1116
{
1217
"id": "s2b3c4d5-e6f7-a890-1234-567890abcdef",
@@ -15,7 +20,12 @@
1520
"url": "https://flutter.dev",
1621
"type": "specializedPublisher",
1722
"language": "en",
18-
"headquarters": null
23+
"headquarters": null,
24+
"action": {
25+
"type": "open_internal_content",
26+
"content_id": "s2b3c4d5-e6f7-a890-1234-567890abcdef",
27+
"content_type": "source"
28+
}
1929
},
2030
{
2131
"id": "s3c4d5e6-f7a8-b901-c234-d56789abcdef",
@@ -24,7 +34,12 @@
2434
"url": "https://techcrunch.com/",
2535
"type": "specializedPublisher",
2636
"language": "en",
27-
"headquarters": null
37+
"headquarters": null,
38+
"action": {
39+
"type": "open_internal_content",
40+
"content_id": "s3c4d5e6-f7a8-b901-c234-d56789abcdef",
41+
"content_type": "source"
42+
}
2843
},
2944
{
3045
"id": "s4d5e6f7-a8b9-c012-d345-e67890abcdef",
@@ -38,6 +53,11 @@
3853
"iso_code": "GB",
3954
"name": "United Kingdom",
4055
"flag_url": "https://example.com/flags/gb.png"
56+
},
57+
"action": {
58+
"type": "open_internal_content",
59+
"content_id": "s4d5e6f7-a8b9-c012-d345-e67890abcdef",
60+
"content_type": "source"
4161
}
4262
}
4363
]

0 commit comments

Comments
 (0)