mediawiki-projects-list 4.3.1 → 4.4.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/index.d.ts CHANGED
@@ -1,5 +1,20 @@
1
1
  declare module 'mediawiki-projects-list' {
2
2
 
3
+ /** A wiki farm */
4
+ export type WikiFarm = (
5
+ "biligame" |
6
+ "fandom" |
7
+ "huijiwiki" |
8
+ "miraheze" |
9
+ "shoutwiki" |
10
+ "telepedia" |
11
+ "wiki.gg" |
12
+ "wikiforge" |
13
+ "wikimedia" |
14
+ "wikitide" |
15
+ null
16
+ );
17
+
3
18
  /** A MediaWiki project */
4
19
  export type WikiProject = {
5
20
  /** Hostname of the project */
@@ -26,7 +41,7 @@ declare module 'mediawiki-projects-list' {
26
41
  /** Whether the paths include matches of the regex */
27
42
  regexPaths: boolean;
28
43
  /** Wiki farm of the project */
29
- wikiFarm: ("biligame" | "fandom" | "huijiwiki" | "miraheze" | "shoutwiki" | "telepedia" | "wiki.gg" | "wikiforge" | "wikimedia") | null;
44
+ wikiFarm: WikiFarm;
30
45
  /** List of extensions providing useful API endpoints */
31
46
  extensions: ("Cargo" | "CentralAuth" | "OAuth")[];
32
47
  /** Replacement for spaces in the article URL */
package/index.js CHANGED
@@ -1,6 +1,11 @@
1
1
  const {properties: {wikiProjects: {items: {properties: wikiProjectSchema}}, frontendProxies: {items: {properties: frontendProxySchema}}}} = require('./projects-schema.json');
2
2
  const PROJECTS = require('./projects.json');
3
3
 
4
+ /**
5
+ * A wiki farm
6
+ * @typedef {"biligame"|"fandom"|"huijiwiki"|"miraheze"|"shoutwiki"|"telepedia"|"wiki.gg"|"wikiforge"|"wikimedia"|"wikitide"|null} WikiFarm
7
+ */
8
+
4
9
  /**
5
10
  * A MediaWiki project
6
11
  * @typedef {object} WikiProject
@@ -15,7 +20,7 @@ const PROJECTS = require('./projects.json');
15
20
  * @property {string} idString.regex - Regex to match the id string
16
21
  * @property {string[]} idString.scriptPaths - How to turn the group matches of the id string regex into an URL to the script path, index based on group matches
17
22
  * @property {boolean} regexPaths - Whether the paths include matches of the regex
18
- * @property {?("biligame"|"fandom"|"huijiwiki"|"miraheze"|"shoutwiki"|"telepedia"|"wiki.gg"|"wikiforge"|"wikimedia")} wikiFarm - Wiki farm of the project
23
+ * @property {WikiFarm} wikiFarm - Wiki farm of the project
19
24
  * @property {("Cargo"|"CentralAuth"|"OAuth")[]} extensions - List of extensions providing useful API endpoints
20
25
  * @property {string} urlSpaceReplacement - Replacement for spaces in the article URL
21
26
  * @property {?string} note - Note about the specific project
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mediawiki-projects-list",
3
- "version": "4.3.1",
3
+ "version": "4.4.0",
4
4
  "type": "commonjs",
5
5
  "description": "List of MediaWiki projects for use in discord-wiki-bot",
6
6
  "main": "index.js",
@@ -181,7 +181,8 @@
181
181
  "telepedia",
182
182
  "wiki.gg",
183
183
  "wikiforge",
184
- "wikimedia"
184
+ "wikimedia",
185
+ "wikitide"
185
186
  ],
186
187
  "default": null
187
188
  },
package/projects.json CHANGED
@@ -2054,6 +2054,23 @@
2054
2054
  "OAuth"
2055
2055
  ]
2056
2056
  },
2057
+ {
2058
+ "name": "wikitide.com",
2059
+ "regex": "(([a-z\\d-]{1,50})\\.wikitide\\.com)",
2060
+ "articlePath": "/wiki/",
2061
+ "scriptPath": "/w/",
2062
+ "idString": {
2063
+ "regex": "([a-z\\d-]{1,50})",
2064
+ "scriptPaths": [
2065
+ "https://$1.wikitide.com/w/"
2066
+ ]
2067
+ },
2068
+ "wikiFarm": "wikitide",
2069
+ "extensions": [
2070
+ "CentralAuth",
2071
+ "OAuth"
2072
+ ]
2073
+ },
2057
2074
  {
2058
2075
  "name": "wikiversity.org",
2059
2076
  "regex": "((?:([a-z\\d-]{1,50})\\.)?(?:m\\.)?wikiversity\\.org)",