scrabble-solver 2.16.5 → 2.16.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.
Files changed (119) hide show
  1. package/.github/workflows/bunx.yml +26 -2
  2. package/.github/workflows/deploy.yml +1 -1
  3. package/.github/workflows/npx.yml +26 -2
  4. package/.nx/workspace-data/d/server-process.json +3 -3
  5. package/.nx/workspace-data/file-map.json +624 -618
  6. package/.nx/workspace-data/lockfile-dependencies.hash +1 -1
  7. package/.nx/workspace-data/lockfile-nodes.hash +1 -1
  8. package/.nx/workspace-data/nx_files.nxt +0 -0
  9. package/.nx/workspace-data/parsed-lock-file.dependencies.json +2643 -2158
  10. package/.nx/workspace-data/parsed-lock-file.nodes.json +3789 -5328
  11. package/.nx/workspace-data/project-graph.json +6770 -7839
  12. package/.nx/workspace-data/source-maps.json +267 -267
  13. package/CLAUDE.md +5 -5
  14. package/README.md +2 -2
  15. package/bun.lock +1063 -2896
  16. package/bunfig.toml +6 -0
  17. package/cypress.config.ts +7 -0
  18. package/lerna.json +1 -1
  19. package/nx.json +3 -1
  20. package/package.json +16 -17
  21. package/packages/configs/package.json +4 -4
  22. package/packages/constants/package.json +2 -2
  23. package/packages/dictionaries/package.json +6 -6
  24. package/packages/logger/package.json +2 -2
  25. package/packages/scrabble-solver/.next/BUILD_ID +1 -1
  26. package/packages/scrabble-solver/.next/build-manifest.json +12 -12
  27. package/packages/scrabble-solver/.next/cache/.previewinfo +1 -1
  28. package/packages/scrabble-solver/.next/cache/.rscinfo +1 -1
  29. package/packages/scrabble-solver/.next/cache/.tsbuildinfo +1 -1
  30. package/packages/scrabble-solver/.next/cache/webpack/client-production/0.pack +0 -0
  31. package/packages/scrabble-solver/.next/cache/webpack/client-production/index.pack +0 -0
  32. package/packages/scrabble-solver/.next/cache/webpack/client-production/index.pack.old +0 -0
  33. package/packages/scrabble-solver/.next/cache/webpack/edge-server-production/index.pack +0 -0
  34. package/packages/scrabble-solver/.next/cache/webpack/edge-server-production/index.pack.old +0 -0
  35. package/packages/scrabble-solver/.next/cache/webpack/server-production/0.pack +0 -0
  36. package/packages/scrabble-solver/.next/cache/webpack/server-production/index.pack +0 -0
  37. package/packages/scrabble-solver/.next/cache/webpack/server-production/index.pack.old +0 -0
  38. package/packages/scrabble-solver/.next/diagnostics/framework.json +1 -1
  39. package/packages/scrabble-solver/.next/next-minimal-server.js.nft.json +1 -1
  40. package/packages/scrabble-solver/.next/next-server.js.nft.json +1 -1
  41. package/packages/scrabble-solver/.next/prerender-manifest.json +7 -4
  42. package/packages/scrabble-solver/.next/required-server-files.js +26 -8
  43. package/packages/scrabble-solver/.next/required-server-files.json +26 -8
  44. package/packages/scrabble-solver/.next/routes-manifest.json +1 -1
  45. package/packages/scrabble-solver/.next/server/chunks/30.js +2 -2
  46. package/packages/scrabble-solver/.next/server/chunks/318.js +3 -3
  47. package/packages/scrabble-solver/.next/server/chunks/671.js +1 -1
  48. package/packages/scrabble-solver/.next/server/chunks/712.js +1 -1
  49. package/packages/scrabble-solver/.next/server/chunks/791.js +3 -3
  50. package/packages/scrabble-solver/.next/server/middleware-build-manifest.js +1 -1
  51. package/packages/scrabble-solver/.next/server/pages/404.html +1 -1
  52. package/packages/scrabble-solver/.next/server/pages/500.html +1 -1
  53. package/packages/scrabble-solver/.next/server/pages/_app.js.nft.json +1 -1
  54. package/packages/scrabble-solver/.next/server/pages/_document.js.nft.json +1 -1
  55. package/packages/scrabble-solver/.next/server/pages/_error.js.nft.json +1 -1
  56. package/packages/scrabble-solver/.next/server/pages/api/dictionary/[locale]/[word].js +2 -2
  57. package/packages/scrabble-solver/.next/server/pages/api/dictionary/[locale]/[word].js.nft.json +1 -1
  58. package/packages/scrabble-solver/.next/server/pages/api/dictionary/[locale].js +1 -1
  59. package/packages/scrabble-solver/.next/server/pages/api/dictionary/[locale].js.nft.json +1 -1
  60. package/packages/scrabble-solver/.next/server/pages/api/solve.js +1 -1
  61. package/packages/scrabble-solver/.next/server/pages/api/solve.js.nft.json +1 -1
  62. package/packages/scrabble-solver/.next/server/pages/api/verify.js +1 -1
  63. package/packages/scrabble-solver/.next/server/pages/api/verify.js.nft.json +1 -1
  64. package/packages/scrabble-solver/.next/server/pages/api/visit.js +1 -1
  65. package/packages/scrabble-solver/.next/server/pages/api/visit.js.nft.json +1 -1
  66. package/packages/scrabble-solver/.next/server/pages/index.html +1 -1
  67. package/packages/scrabble-solver/.next/server/pages/index.js.nft.json +1 -1
  68. package/packages/scrabble-solver/.next/server/pages/index.json +1 -1
  69. package/packages/scrabble-solver/.next/server/pages/not-found.html +1 -1
  70. package/packages/scrabble-solver/.next/server/pages-manifest.json +1 -1
  71. package/packages/scrabble-solver/.next/static/chunks/framework-3cf15b8041c59dd3.js +1 -0
  72. package/packages/scrabble-solver/.next/static/chunks/main-852475ca502b4e49.js +5 -0
  73. package/packages/scrabble-solver/.next/static/chunks/pages/_app-a5bbe02710f13d05.js +7 -0
  74. package/packages/scrabble-solver/.next/static/chunks/pages/{index-1d609730ebea97fd.js → index-ec0f6aeeaf7be227.js} +1 -1
  75. package/packages/scrabble-solver/.next/static/{QzOFuqqrEDsCEV0MLUrPP → vYpMmuC_yEurZGcyGVnLf}/_buildManifest.js +1 -1
  76. package/packages/scrabble-solver/.next/trace +21 -21
  77. package/packages/scrabble-solver/.next/trace-build +1 -1
  78. package/packages/scrabble-solver/.next/types/cache-life.d.ts +1 -0
  79. package/packages/scrabble-solver/.next/types/root-params.d.ts +3 -0
  80. package/packages/scrabble-solver/next-env.d.ts +1 -0
  81. package/packages/scrabble-solver/next.config.js +5 -0
  82. package/packages/scrabble-solver/package.json +19 -21
  83. package/packages/scrabble-solver/public/service-worker.js +1 -1
  84. package/packages/scrabble-solver/public/service-worker.js.map +1 -1
  85. package/packages/scrabble-solver/src/components/Tooltip/Tooltip.tsx +4 -1
  86. package/packages/scrabble-solver/tsconfig.tsbuildinfo +1 -1
  87. package/packages/solver/build/fillPattern.d.ts +3 -1
  88. package/packages/solver/package.json +7 -7
  89. package/packages/types/package.json +3 -3
  90. package/packages/word-definitions/build/languages/english.d.ts +1 -1
  91. package/packages/word-definitions/build/languages/english.js +23 -11
  92. package/packages/word-definitions/package.json +3 -3
  93. package/packages/word-definitions/src/__tests__/expected/en-US.awe.json +7 -4
  94. package/packages/word-definitions/src/__tests__/expected/en-US.oe.json +2 -2
  95. package/packages/word-definitions/src/__tests__/expected/en-US.pawn.json +11 -8
  96. package/packages/word-definitions/src/__tests__/expected/en-US.pawnee.json +3 -1
  97. package/packages/word-definitions/src/__tests__/expected/en-US.pean.json +4 -4
  98. package/packages/word-definitions/src/__tests__/expected/en-US.wiz.json +7 -1
  99. package/packages/word-definitions/src/__tests__/expected/en-US.zzzzqq.json +4 -0
  100. package/packages/word-definitions/src/__tests__/input/en-US.awe.json +1 -0
  101. package/packages/word-definitions/src/__tests__/input/en-US.oe.json +1 -0
  102. package/packages/word-definitions/src/__tests__/input/en-US.pawn.json +1 -0
  103. package/packages/word-definitions/src/__tests__/input/en-US.pawnee.json +1 -0
  104. package/packages/word-definitions/src/__tests__/input/en-US.pean.json +1 -0
  105. package/packages/word-definitions/src/__tests__/input/en-US.wiz.json +1 -0
  106. package/packages/word-definitions/src/__tests__/input/en-US.zzzzqq.json +1 -0
  107. package/packages/word-definitions/src/languages/english.ts +36 -12
  108. package/packages/word-definitions/src/parse.test.ts +9 -8
  109. package/packages/word-lists/package.json +4 -4
  110. package/packages/scrabble-solver/.next/static/chunks/framework-a23f7f643b59a2ca.js +0 -1
  111. package/packages/scrabble-solver/.next/static/chunks/main-00489babb6f51cdf.js +0 -5
  112. package/packages/scrabble-solver/.next/static/chunks/pages/_app-9b8d13beabe62d43.js +0 -7
  113. package/packages/word-definitions/src/__tests__/input/en-US.awe.html +0 -2235
  114. package/packages/word-definitions/src/__tests__/input/en-US.oe.html +0 -1337
  115. package/packages/word-definitions/src/__tests__/input/en-US.pawn.html +0 -2435
  116. package/packages/word-definitions/src/__tests__/input/en-US.pawnee.html +0 -1356
  117. package/packages/word-definitions/src/__tests__/input/en-US.pean.html +0 -1512
  118. package/packages/word-definitions/src/__tests__/input/en-US.wiz.html +0 -1556
  119. /package/packages/scrabble-solver/.next/static/{QzOFuqqrEDsCEV0MLUrPP → vYpMmuC_yEurZGcyGVnLf}/_ssgManifest.js +0 -0
@@ -1,4 +1,6 @@
1
1
  import { type Trie } from '@kamilmielnik/trie';
2
2
  import { type Config, type Pattern, type Tile } from '@scrabble-solver/types';
3
3
  export declare const fillPattern: (trie: Trie, config: Config, pattern: Pattern, tiles: Tile[]) => Pattern[];
4
- export declare const fillPatternRecursive: (results: Pattern[], trie: Trie, config: Config, pattern: Pattern, word: string, tiles: Tile[]) => void;
4
+ export declare const fillPatternRecursive: (
5
+ /** gets mutated when this function is called */
6
+ results: Pattern[], trie: Trie, config: Config, pattern: Pattern, word: string, tiles: Tile[]) => void;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scrabble-solver/solver",
3
- "version": "2.16.5",
3
+ "version": "2.16.7",
4
4
  "description": "Scrabble Solver 2 - Solver",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -19,18 +19,18 @@
19
19
  },
20
20
  "homepage": "https://scrabble-solver.org",
21
21
  "scripts": {
22
- "build": "tsgo --project .",
22
+ "build": "tsc --project .",
23
23
  "clean": "rimraf build/",
24
24
  "test": "bun test --timeout 180000 src"
25
25
  },
26
26
  "dependencies": {
27
- "@kamilmielnik/trie": "^5.0.0",
28
- "@scrabble-solver/types": "^2.16.5"
27
+ "@kamilmielnik/trie": "^5.1.0",
28
+ "@scrabble-solver/types": "^2.16.7"
29
29
  },
30
30
  "devDependencies": {
31
- "@scrabble-solver/configs": "^2.16.5",
32
- "@scrabble-solver/constants": "^2.16.5",
33
- "@scrabble-solver/dictionaries": "^2.16.5"
31
+ "@scrabble-solver/configs": "^2.16.7",
32
+ "@scrabble-solver/constants": "^2.16.7",
33
+ "@scrabble-solver/dictionaries": "^2.16.7"
34
34
  },
35
35
  "gitHead": "1e2d1ad49a288d4a44196d8e3336740da132c637"
36
36
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scrabble-solver/types",
3
- "version": "2.16.5",
3
+ "version": "2.16.7",
4
4
  "description": "Scrabble Solver 2 - Types",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -19,11 +19,11 @@
19
19
  },
20
20
  "homepage": "https://scrabble-solver.org",
21
21
  "scripts": {
22
- "build": "tsgo --project .",
22
+ "build": "tsc --project .",
23
23
  "clean": "rimraf build/"
24
24
  },
25
25
  "dependencies": {
26
- "@scrabble-solver/constants": "^2.16.5"
26
+ "@scrabble-solver/constants": "^2.16.7"
27
27
  },
28
28
  "gitHead": "1e2d1ad49a288d4a44196d8e3336740da132c637"
29
29
  }
@@ -1,3 +1,3 @@
1
1
  import type { ParsingResult } from '../types';
2
2
  export declare const crawl: (word: string) => Promise<string>;
3
- export declare const parse: (html: string) => ParsingResult;
3
+ export declare const parse: (json: string) => ParsingResult;
@@ -3,24 +3,36 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.parse = exports.crawl = void 0;
4
4
  const cheerio_1 = require("cheerio");
5
5
  const lib_1 = require("../lib");
6
- const DOES_NOT_EXIST_MESSAGE = "The word you've entered isn't in the dictionary. Click on a spelling suggestion below or try again using the search bar above.";
7
6
  const crawl = (word) => {
8
7
  return (0, lib_1.request)({
9
8
  protocol: 'https',
10
- hostname: 'www.merriam-webster.com',
11
- path: `/dictionary/${encodeURIComponent(word)}`,
9
+ hostname: 'en.wiktionary.org',
10
+ path: `/api/rest_v1/page/definition/${encodeURIComponent(word)}`,
11
+ headers: {
12
+ 'User-Agent': 'scrabble-solver (https://github.com/kamilmielnik/scrabble-solver)',
13
+ },
12
14
  });
13
15
  };
14
16
  exports.crawl = crawl;
15
- const parse = (html) => {
16
- const $ = (0, cheerio_1.load)(html);
17
- $('strong.mw_t_bc').replaceWith(', ');
18
- $('.text-lowercase').remove();
19
- $('.sub-content-thread').remove();
20
- const $definitions = $('[id^=dictionary-entry]').find('.dtText, .cxl-ref');
17
+ const parse = (json) => {
18
+ let data;
19
+ try {
20
+ data = JSON.parse(json);
21
+ }
22
+ catch {
23
+ return { definitions: [], exists: false };
24
+ }
25
+ const usages = data?.en ?? [];
26
+ if (!Array.isArray(usages)) {
27
+ return { definitions: [], exists: false };
28
+ }
29
+ const definitions = usages
30
+ .flatMap((usage) => (usage.definitions ?? []).map(({ definition }) => definition))
31
+ .map((definition) => (0, cheerio_1.load)(definition).text().trim())
32
+ .filter(Boolean);
21
33
  return {
22
- definitions: Array.from($definitions).map((definition) => $(definition).text().replace(/\n/g, '')),
23
- exists: $('.spelling-suggestion-text').text().trim() !== DOES_NOT_EXIST_MESSAGE,
34
+ definitions,
35
+ exists: definitions.length > 0,
24
36
  };
25
37
  };
26
38
  exports.parse = parse;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scrabble-solver/word-definitions",
3
- "version": "2.16.5",
3
+ "version": "2.16.7",
4
4
  "description": "Scrabble Solver 2 - Word definitions",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -19,12 +19,12 @@
19
19
  },
20
20
  "homepage": "https://scrabble-solver.org",
21
21
  "scripts": {
22
- "build": "tsgo --project .",
22
+ "build": "tsc --project .",
23
23
  "clean": "rimraf build/",
24
24
  "test": "bun test --timeout 180000 src"
25
25
  },
26
26
  "dependencies": {
27
- "@scrabble-solver/types": "^2.16.5",
27
+ "@scrabble-solver/types": "^2.16.7",
28
28
  "cheerio": "^1.2.0",
29
29
  "follow-redirects": "^1.16.0",
30
30
  "striptags": "^3.2.0"
@@ -1,9 +1,12 @@
1
1
  {
2
2
  "definitions": [
3
- "an emotion variously combining dread, veneration, and wonder that is inspired by authority or by the sacred or sublime",
4
- "dread, terror",
5
- "the power to inspire dread",
6
- "to inspire or fill with awe"
3
+ "ISO 639-3 language code for Awetí.",
4
+ "A feeling of fear and reverence.",
5
+ "A feeling of amazement.",
6
+ "Power to inspire awe.",
7
+ "To inspire fear and reverence in.",
8
+ "To control by inspiring dread.",
9
+ "A bucket (blade) attached to water wheels."
7
10
  ],
8
11
  "exists": true
9
12
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "definitions": [
3
- "oersted",
4
- "Kenzaburo 1935– Japanese writer"
3
+ "A small island.",
4
+ "A grandchild."
5
5
  ],
6
6
  "exists": true
7
7
  }
@@ -1,13 +1,16 @@
1
1
  {
2
2
  "definitions": [
3
- "one of the chessmen of least value having the power to move only forward ordinarily one square at a time, to capture only diagonally forward, and to be promoted to any piece except a king upon reaching the eighth rank",
4
- "one that can be used to further the purposes of another",
5
- "something delivered to or deposited with another as security for a loan",
6
- "hostage",
7
- "the state of being pledged",
8
- "something used as a pledge, guaranty",
9
- "the act of pawning",
10
- "to deposit in pledge or as security especially in exchange for money"
3
+ "The state of being held as security for a loan, or as a pledge.",
4
+ "An instance of pawning something.",
5
+ "An item given as security on a loan, or as a pledge.",
6
+ "A pawnshop; pawnbroker.",
7
+ "To pledge; to stake or wager.",
8
+ "To give as security on a loan of money; especially, to deposit (something) at a pawn shop.",
9
+ "The most numerous chess piece, or a similar piece in a similar game. In chess, each side starts with eight; moves are only forward, and attacks are only diagonally or en passant.",
10
+ "A person being manipulated by another, being used to some end.",
11
+ "Alternative form of paan.",
12
+ "A gallery.",
13
+ "Alternative spelling of pwn."
11
14
  ],
12
15
  "exists": true
13
16
  }
@@ -1,4 +1,6 @@
1
1
  {
2
- "definitions": ["a member of an American Indian people originally of Kansas and Nebraska"],
2
+ "definitions": [
3
+ "One or to whom a pledge is delivered as security one who takes anything in pawn."
4
+ ],
3
5
  "exists": true
4
6
  }
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "definitions": [
3
- "variant of paean",
4
- "a heraldic fur consisting of ermine spots of gold on a black field",
5
- "of the heraldic fur pean",
6
- "variant spelling of peen"
3
+ "A heraldic fur of gold spots on a black field.",
4
+ "In blazon, a heraldic fur of a black field with gold spots.",
5
+ "Alternative spelling of paean.",
6
+ "Alternative spelling of peen."
7
7
  ],
8
8
  "exists": true
9
9
  }
@@ -1,4 +1,10 @@
1
1
  {
2
- "definitions": ["a person who is very good at something, wizard"],
2
+ "definitions": [
3
+ "A person who is exceptionally clever, gifted or skilled in a particular area.",
4
+ "A wizard; an administrator of a multi-user dungeon.",
5
+ "To be promoted to wizard (administrator) status in a multi-user dungeon, by completing the game quest.",
6
+ "Alternative spelling of whiz: an act of urination.",
7
+ "Pronunciation spelling of with."
8
+ ],
3
9
  "exists": true
4
10
  }
@@ -0,0 +1,4 @@
1
+ {
2
+ "definitions": [],
3
+ "exists": false
4
+ }
@@ -0,0 +1 @@
1
+ {"en":[{"partOfSpeech":"Symbol","language":"Translingual","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt6\" typeof=\"mw:Transclusion\"></span><span about=\"#mwt6\"> </span><i about=\"#mwt6\"><a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/ISO%20639-3\" title=\"w:ISO 639-3\" class=\"extiw\">ISO 639-3</a><link rel=\"mw:PageProp/Category\" href=\"./Category:ISO_639-3\"> <a rel=\"mw:WikiLink\" href=\"/wiki/language_code\" title=\"language code\">language code</a> for </i><a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/ISO%20639:awe\" title=\"w:ISO 639:awe\" about=\"#mwt6\" class=\"extiw\"><b>Awetí</b></a><i about=\"#mwt6\">.</i>"}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"A feeling of fear and <a rel=\"mw:WikiLink\" href=\"/wiki/reverence\" title=\"reverence\">reverence</a>."},{"definition":"A feeling of amazement."},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt40\" typeof=\"mw:Transclusion\"></span> Power to inspire <a rel=\"mw:WikiLink\" href=\"/wiki/awe\" class=\"mw-selflink selflink\">awe</a>."}]},{"partOfSpeech":"Verb","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt125\" typeof=\"mw:Transclusion\"></span> To <a rel=\"mw:WikiLink\" href=\"/wiki/inspire\" title=\"inspire\">inspire</a> <a rel=\"mw:WikiLink\" href=\"/wiki/fear\" title=\"fear\">fear</a> and <a rel=\"mw:WikiLink\" href=\"/wiki/reverence\" title=\"reverence\">reverence</a> in."},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt127\" typeof=\"mw:Transclusion\"></span> To <a rel=\"mw:WikiLink\" href=\"/wiki/control\" title=\"control\">control</a> by inspiring <a rel=\"mw:WikiLink\" href=\"/wiki/dread\" title=\"dread\">dread</a>."}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt173\" typeof=\"mw:Transclusion\"></span> A <a rel=\"mw:WikiLink\" href=\"/wiki/bucket\" title=\"bucket\">bucket</a> (<a rel=\"mw:WikiLink\" href=\"/wiki/blade\" title=\"blade\">blade</a>) attached to <a rel=\"mw:WikiLink\" href=\"/wiki/water_wheel\" title=\"water wheel\">water wheels</a>."}]}],"other":[{"partOfSpeech":"Noun","language":"Anyi","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/rice\" title=\"rice\">rice</a>","parsedExamples":[{"example":"mɩn nin a tʋn <b>awe</b>.","translation":"My mother prepared <b>rice</b>."}],"examples":["mɩn nin a tʋn <b>awe</b>."]}]},{"partOfSpeech":"Noun","language":"Baoule","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/hunger\" title=\"hunger\">hunger</a>"}]},{"partOfSpeech":"Numeral","language":"Gun","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/two\" title=\"two\">two</a>"}]},{"partOfSpeech":"Adjective","language":"Gun","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/two\" title=\"two\">two</a>"},{"definition":"<span class=\"mw-cite-backlink\"><a href=\"/wiki/awe#cite_ref-1\" rel=\"mw:referencedBy\"><span class=\"mw-linkback-text\">↑</span></a></span> <span id=\"mw-reference-text-cite_note-1\" class=\"mw-reference-text reference-text\"><span class=\"citation-whole\" about=\"#mwt187\" typeof=\"mw:Transclusion\"><span class=\"cited-source\"><a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/Hounkpati%20B%20Christophe%20Capo\" title=\"w:Hounkpati B Christophe Capo\" class=\"extiw\">Capo, Hounkpati B.C.</a> (<span class=\"None\" lang=\"und\">1991</span>), <cite>A Comparative Phonology of Gbe</cite> (Publications in African Languages and Linguistics<span typeof=\"mw:Entity\">;</span> <span class=\"None\" lang=\"und\">14</span>), Berlin/New York; Garome, Benin<span typeof=\"mw:Entity\">:</span> Foris Publications &amp; Labo Gbe (Int), page <span class=\"None\" lang=\"und\">224</span></span></span></span>"}]},{"partOfSpeech":"Noun","language":"Māori","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/soot\" title=\"soot\">soot</a>"},{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/white\" title=\"white\">white</a> feather"},{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/power\" title=\"power\">power</a>, <a rel=\"mw:WikiLink\" href=\"/wiki/influence\" title=\"influence\">influence</a>"}]},{"partOfSpeech":"Adverb","language":"Mapudungun","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/quickly\" title=\"quickly\">quickly</a>, <a rel=\"mw:WikiLink\" href=\"/wiki/promptly\" title=\"promptly\">promptly</a>."},{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/soon\" title=\"soon\">soon</a>"}]},{"partOfSpeech":"Noun","language":"Middle English","definitions":[{"definition":"<span class=\"Latn\" lang=\"en\" about=\"#mwt229\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/awe#English\" class=\"mw-selflink-fragment\">awe</a></span>, <a rel=\"mw:WikiLink\" href=\"/wiki/wonder\" title=\"wonder\">wonder</a>, <a rel=\"mw:WikiLink\" href=\"/wiki/reverence\" title=\"reverence\">reverence</a>"},{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/fear\" title=\"fear\">fear</a>, <a rel=\"mw:WikiLink\" href=\"/wiki/horror\" title=\"horror\">horror</a>"},{"definition":"that which elicits or incites <a rel=\"mw:WikiLink\" href=\"/wiki/horror\" title=\"horror\">horror</a>; something <a rel=\"mw:WikiLink\" href=\"/wiki/horrifying\" title=\"horrifying\">horrifying</a>"}]},{"partOfSpeech":"Adverb","language":"Middle English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt243\" typeof=\"mw:Transclusion\">alternative form of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"enm\"><a rel=\"mw:WikiLink\" href=\"/wiki/away#Middle_English\" title=\"away\">away</a></i></span></span>"}]},{"partOfSpeech":"Noun","language":"Middle English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt245\" typeof=\"mw:Transclusion\">alternative form of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"enm\"><a rel=\"mw:WikiLink\" href=\"/wiki/ewe#Middle_English\" title=\"ewe\">ewe</a></i></span></span>"}]},{"partOfSpeech":"Noun","language":"Tabaru","definitions":[{"definition":"a <a rel=\"mw:WikiLink\" href=\"/wiki/thread\" title=\"thread\">thread</a>"}]},{"partOfSpeech":"Pronoun","language":"Tooro","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/your\" title=\"your\">your</a> <span class=\"mention-gloss-paren\" about=\"#mwt259\" typeof=\"mw:Transclusion\">(</span><span class=\"mention-gloss\" about=\"#mwt259\">second-person singular possessive pronoun</span><span class=\"mention-gloss-paren\" about=\"#mwt259\">)</span>"}]},{"partOfSpeech":"Interjection","language":"Western Arrernte","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/yes\" title=\"yes\">yes</a>"}]}],"pap":[{"partOfSpeech":"Pronoun","language":"Papiamentu","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/today\" title=\"today\">today</a>"}]}],"sw":[{"partOfSpeech":"Verb","language":"Swahili","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt253\" typeof=\"mw:Transclusion\">inflection of <span class=\"form-of-definition-link\"><i class=\"Latn mention nowrap\" lang=\"sw\"><a rel=\"mw:WikiLink\" href=\"/wiki/wa#Swahili\" title=\"wa\">-wa</a></i></span>:</span><span about=\"#mwt253\">\n</span><ol about=\"#mwt253\"><li><span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#subjunctive_mood\" title=\"Appendix:Glossary\">subjunctive</a> <a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/affirmation%20and%20negation\" title=\"w:affirmation and negation\" class=\"extiw\">affirmative</a></span></li>\n<li><span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Swahili_noun_classes#M-wa_class\" title=\"Appendix:Swahili noun classes\">m-wa class subject inflected</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#subjunctive_mood\" title=\"Appendix:Glossary\">subjunctive</a> <a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/affirmation%20and%20negation\" title=\"w:affirmation and negation\" class=\"extiw\">affirmative</a></span></li></ol>"},{"definition":"<span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#subjunctive_mood\" title=\"Appendix:Glossary\">subjunctive</a> <a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/affirmation%20and%20negation\" title=\"w:affirmation and negation\" class=\"extiw\">affirmative</a></span>"},{"definition":"<span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Swahili_noun_classes#M-wa_class\" title=\"Appendix:Swahili noun classes\">m-wa class subject inflected</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#subjunctive_mood\" title=\"Appendix:Glossary\">subjunctive</a> <a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/affirmation%20and%20negation\" title=\"w:affirmation and negation\" class=\"extiw\">affirmative</a></span>"}]}],"yo":[{"partOfSpeech":"Noun","language":"Yoruba","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/friend\" title=\"friend\">friend</a>"},{"definition":"an <a rel=\"mw:WikiLink\" href=\"/wiki/unknown\" title=\"unknown\">unknown</a> <a rel=\"mw:WikiLink\" href=\"/wiki/person\" title=\"person\">person</a>","parsedExamples":[{"example":"Táni <b>àwé</b> yẹn<span typeof=\"mw:Entity\">?</span>","translation":"Who is that <b>unknown person</b>?"}],"examples":["Táni <b>àwé</b> yẹn<span typeof=\"mw:Entity\">?</span>"]}]}]}
@@ -0,0 +1 @@
1
+ {"en":[{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt12\" typeof=\"mw:Transclusion\"></span> A <a rel=\"mw:WikiLink\" href=\"/wiki/small#Adjective\" title=\"small\">small</a> <a rel=\"mw:WikiLink\" href=\"/wiki/island\" title=\"island\">island</a>."}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"A <a rel=\"mw:WikiLink\" href=\"/wiki/grandchild\" title=\"grandchild\">grandchild</a>."}]}],"other":[{"partOfSpeech":"Interjection","language":"Ambonese Malay","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/hey\" title=\"hey\">hey</a>","parsedExamples":[{"example":"<b>Oe</b>, pi mana<span typeof=\"mw:Entity\">?</span>","translation":"<b>Hey</b>, where are you heading?"}],"examples":["<b>Oe</b>, pi mana<span typeof=\"mw:Entity\">?</span>"]}]},{"partOfSpeech":"Noun","language":"Muna","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/water\" title=\"water\">water</a>"}]},{"partOfSpeech":"Noun","language":"Nungon","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/woman\" title=\"woman\">woman</a>"}]},{"partOfSpeech":"Noun","language":"Termanu","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/water\" title=\"water\">water</a>"}]},{"partOfSpeech":"Noun","language":"Uab Meto","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/water\" title=\"water\">water</a>"}]}],"fr":[{"partOfSpeech":"Interjection","language":"French","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt30\" typeof=\"mw:Transclusion\"></span> <span class=\"form-of-definition use-with-mention\" about=\"#mwt31\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/pronunciation_spelling\" title=\"pronunciation spelling\">pronunciation spelling</a> of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"fr\"><a rel=\"mw:WikiLink\" href=\"/wiki/ouais#French\" title=\"ouais\">ouais</a></i></span></span><link rel=\"mw:PageProp/Category\" href=\"./Category:French_pronunciation_spellings#OE\" about=\"#mwt31\">: <a rel=\"mw:WikiLink\" href=\"/wiki/yeah\" title=\"yeah\">yeah</a>; <a rel=\"mw:WikiLink\" href=\"/wiki/yh\" title=\"yh\">yh</a>"}]}],"gl":[{"partOfSpeech":"Verb","language":"Galician","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt33\" typeof=\"mw:Transclusion\">inflection of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"gl\"><a rel=\"mw:WikiLink\" href=\"/wiki/oír#Galician\" title=\"oír\">oír</a></i></span>:</span><span about=\"#mwt33\">\n</span><ol about=\"#mwt33\"><li><span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#present_tense\" title=\"Appendix:Glossary\">present</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#indicative_mood\" title=\"Appendix:Glossary\">indicative</a></span></li>\n<li><span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#second_person\" title=\"Appendix:Glossary\">second-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#imperative_mood\" title=\"Appendix:Glossary\">imperative</a></span></li></ol>"},{"definition":"<span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#present_tense\" title=\"Appendix:Glossary\">present</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#indicative_mood\" title=\"Appendix:Glossary\">indicative</a></span>"},{"definition":"<span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#second_person\" title=\"Appendix:Glossary\">second-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#imperative_mood\" title=\"Appendix:Glossary\">imperative</a></span>"}]}],"ja":[{"partOfSpeech":"Romanization","language":"Japanese","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt35\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/romaji\" title=\"romaji\">Rōmaji</a> transcription of <span class=\"form-of-definition-link\"><i class=\"Jpan mention\" lang=\"ja\"><a rel=\"mw:WikiLink\" href=\"/wiki/おえ#Japanese\" title=\"おえ\">おえ</a></i></span></span>"}]}],"gv":[{"partOfSpeech":"Noun","language":"Manx","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/grandchild\" title=\"grandchild\">grandchild</a>"}]}],"sc":[{"partOfSpeech":"Adverb","language":"Sardinian","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt56\" typeof=\"mw:Transclusion\"></span> <a rel=\"mw:WikiLink\" href=\"/wiki/today\" title=\"today\">today</a>\n\n<span class=\"mw-empty-elt\" about=\"#mwt57\" typeof=\"mw:Transclusion\"><link rel=\"mw:PageProp/Category\" href=\"./Category:sc:Time#OE\"></span>"}]}],"sco":[{"partOfSpeech":"Noun","language":"Scots","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt62\" typeof=\"mw:Transclusion\"></span> <a rel=\"mw:WikiLink\" href=\"/wiki/grandchild\" title=\"grandchild\">grandchild</a> (especially illegitimate)"}]}],"es":[{"partOfSpeech":"Interjection","language":"Spanish","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt66\" typeof=\"mw:Transclusion\"></span> <a rel=\"mw:WikiLink\" href=\"/wiki/hey\" title=\"hey\">hey</a>!"}]}],"tr":[{"partOfSpeech":"Noun","language":"Turkish","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt78\" typeof=\"mw:Transclusion\"></span> <span class=\"form-of-definition use-with-mention\" about=\"#mwt79\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#initialism\" title=\"Appendix:Glossary\">initialism</a> of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"tr\"><a rel=\"mw:WikiLink\" href=\"/wiki/orospu_evladı#Turkish\" title=\"orospu evladı\">orospu evladı</a></i> <span class=\"mention-gloss-paren annotation-paren\">(</span><span lang=\"tr-Latn\" class=\"mention-tr tr Latn\">son of a bitch</span><span class=\"mention-gloss-paren annotation-paren\">)</span></span></span><link rel=\"mw:PageProp/Category\" href=\"./Category:Turkish_initialisms#OE\" about=\"#mwt79\">","parsedExamples":[{"example":"Yutamayacağını bildiğin lokmayı neden yedin<span typeof=\"mw:Entity\">?</span> Niye yaptın <b>O.E</b><span typeof=\"mw:Entity\">?</span>","translation":"Why did you knowingly bit off more than you could chew? Why did you do it [you] <b>son of a bitch</b>"}],"examples":["Yutamayacağını bildiğin lokmayı neden yedin<span typeof=\"mw:Entity\">?</span> Niye yaptın <b>O.E</b><span typeof=\"mw:Entity\">?</span>"]}]}]}
@@ -0,0 +1 @@
1
+ {"en":[{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt32\" typeof=\"mw:Transclusion\"></span> The state of being held as <a rel=\"mw:WikiLink\" href=\"/wiki/security\" title=\"security\">security</a> for a loan, or as a pledge.","parsedExamples":[{"example":"All our jewellery was in <b>pawn</b> by this stage."}],"examples":["All our jewellery was in <b>pawn</b> by this stage."]},{"definition":"An instance of pawning something."},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt36\" typeof=\"mw:Transclusion\"></span> An item given as <a rel=\"mw:WikiLink\" href=\"/wiki/security\" title=\"security\">security</a> on a loan, or as a pledge."},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt40\" typeof=\"mw:Transclusion\"></span> A <a rel=\"mw:WikiLink\" href=\"/wiki/pawnshop\" title=\"pawnshop\">pawnshop</a>; <a rel=\"mw:WikiLink\" href=\"/wiki/pawnbroker\" title=\"pawnbroker\">pawnbroker</a>."}]},{"partOfSpeech":"Verb","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt101\" typeof=\"mw:Transclusion\"></span> To <a rel=\"mw:WikiLink\" href=\"/wiki/pledge\" title=\"pledge\">pledge</a>; to <a rel=\"mw:WikiLink\" href=\"/wiki/stake\" title=\"stake\">stake</a> or <a rel=\"mw:WikiLink\" href=\"/wiki/wager\" title=\"wager\">wager</a>."},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt102\" typeof=\"mw:Transclusion\"></span> To give as <a rel=\"mw:WikiLink\" href=\"/wiki/security\" title=\"security\">security</a> on a <a rel=\"mw:WikiLink\" href=\"/wiki/loan\" title=\"loan\">loan</a> of <a rel=\"mw:WikiLink\" href=\"/wiki/money\" title=\"money\">money</a>; especially, to <a rel=\"mw:WikiLink\" href=\"/wiki/deposit\" title=\"deposit\">deposit</a> (something) at a <a rel=\"mw:WikiLink\" href=\"/wiki/pawn_shop\" title=\"pawn shop\">pawn shop</a>."}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":""},{"definition":"<span class=\"usage-label-sense\"></span> The most numerous <a rel=\"mw:WikiLink\" href=\"/wiki/chess\" title=\"chess\">chess</a> piece, or a similar piece in a similar game. In chess, each side starts with eight; moves are only <a rel=\"mw:WikiLink\" href=\"/wiki/forward\" title=\"forward\">forward</a>, and <a rel=\"mw:WikiLink\" href=\"/wiki/attack\" title=\"attack\">attacks</a> are only diagonally or <a rel=\"mw:WikiLink\" href=\"/wiki/en_passant\" title=\"en passant\">en passant</a>."},{"definition":""},{"definition":"<span class=\"usage-label-sense\"></span> A person being <a rel=\"mw:WikiLink\" href=\"/wiki/manipulated\" title=\"manipulated\">manipulated</a> by another, being used to some end.","parsedExamples":[{"example":"Though a <b>pawn</b> of the gods, her departure is the precipitating cause of the Trojan War."}],"examples":["Though a <b>pawn</b> of the gods, her departure is the precipitating cause of the Trojan War."]}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt330\" typeof=\"mw:Transclusion\">Alternative form of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/paan#English\" title=\"paan\">paan</a></i></span></span>."}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"A <a rel=\"mw:WikiLink\" href=\"/wiki/gallery\" title=\"gallery\">gallery</a>.<!--Chambers 1908-->"}]},{"partOfSpeech":"Verb","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt337\" typeof=\"mw:Transclusion\"></span> <span class=\"form-of-definition use-with-mention\" about=\"#mwt338\" typeof=\"mw:Transclusion\">Alternative spelling of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/pwn#English\" title=\"pwn\">pwn</a></i></span></span>."}]}],"other":[{"partOfSpeech":"Noun","language":"Middle English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt342\" typeof=\"mw:Transclusion\">alternative form of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"enm\"><a rel=\"mw:WikiLink\" href=\"/wiki/pown#Middle_English:_pawn\" title=\"pown\">pown</a></i> <span class=\"mention-gloss-paren annotation-paren\">(</span><span class=\"mention-gloss-double-quote\">“</span><span class=\"mention-gloss\">pawn</span><span class=\"mention-gloss-double-quote\">”</span><span class=\"mention-gloss-paren annotation-paren\">)</span></span></span>"}]}]}
@@ -0,0 +1 @@
1
+ {"en":[{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt4\" typeof=\"mw:Transclusion\"></span> One or to whom a <a rel=\"mw:WikiLink\" href=\"/wiki/pledge\" title=\"pledge\">pledge</a> is <a rel=\"mw:WikiLink\" href=\"/wiki/deliver\" title=\"deliver\">delivered</a> as <a rel=\"mw:WikiLink\" href=\"/wiki/security\" title=\"security\">security</a> one who takes anything in <a rel=\"mw:WikiLink\" href=\"/wiki/pawn\" title=\"pawn\">pawn</a>."}]}],"fr":[{"partOfSpeech":"Noun","language":"French","definitions":[{"definition":"the <a rel=\"mw:WikiLink\" href=\"/wiki/Pawnee\" title=\"Pawnee\">Pawnee</a> language"}]}]}
@@ -0,0 +1 @@
1
+ {"en":[{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt10\" typeof=\"mw:Transclusion\"></span> A <a rel=\"mw:WikiLink\" href=\"/wiki/heraldic\" title=\"heraldic\">heraldic</a> <a rel=\"mw:WikiLink\" href=\"/wiki/fur\" title=\"fur\">fur</a> of gold spots on a black field."}]},{"partOfSpeech":"Adjective","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt12\" typeof=\"mw:Transclusion\"></span> In <a rel=\"mw:WikiLink\" href=\"/wiki/blazon\" title=\"blazon\">blazon</a>, a <a rel=\"mw:WikiLink\" href=\"/wiki/heraldic\" title=\"heraldic\">heraldic</a> <a rel=\"mw:WikiLink\" href=\"/wiki/fur\" title=\"fur\">fur</a> of a black field with gold spots."}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt23\" typeof=\"mw:Transclusion\">Alternative spelling of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/paean#English\" title=\"paean\">paean</a></i></span></span>."}]},{"partOfSpeech":"Verb","language":"English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt27\" typeof=\"mw:Transclusion\">Alternative spelling of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/paean#English\" title=\"paean\">paean</a></i></span></span>."}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt33\" typeof=\"mw:Transclusion\">Alternative spelling of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/peen#English\" title=\"peen\">peen</a></i></span></span>."}]},{"partOfSpeech":"Verb","language":"English","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt35\" typeof=\"mw:Transclusion\">Alternative spelling of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/peen#English\" title=\"peen\">peen</a></i></span></span>."}]}],"eu":[{"partOfSpeech":"Noun","language":"Basque","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt39\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink/Interwiki\" href=\"https://en.wikipedia.org/wiki/inessive%20case\" title=\"w:inessive case\" class=\"extiw\">inessive</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"eu\"><a rel=\"mw:WikiLink\" href=\"/wiki/pe#Basque\" title=\"pe\">pe</a></i></span></span>"}]}],"et":[{"partOfSpeech":"Verb","language":"Estonian","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt41\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#first_person\" title=\"Appendix:Glossary\">first-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#singular_number\" title=\"Appendix:Glossary\">singular</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#present_tense\" title=\"Appendix:Glossary\">present</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#indicative_mood\" title=\"Appendix:Glossary\">indicative</a> of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"et\"><a rel=\"mw:WikiLink\" href=\"/wiki/pidama#Estonian\" title=\"pidama\">pidama</a></i></span></span>"}]}],"pl":[{"partOfSpeech":"Noun","language":"Polish","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt49\" typeof=\"mw:Transclusion\"></span> <a rel=\"mw:WikiLink\" href=\"/wiki/eulogy\" title=\"eulogy\">eulogy</a>, <a rel=\"mw:WikiLink\" href=\"/wiki/paean\" title=\"paean\">paean</a> <span class=\"mention-gloss-paren\" about=\"#mwt50\" typeof=\"mw:Transclusion\">(</span><span class=\"mention-gloss\" about=\"#mwt50\">chant or song, especially a hymn of thanksgiving for deliverance or victory, to Apollo or sometimes another god or goddess</span><span class=\"mention-gloss-paren\" about=\"#mwt50\">)</span>"},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt51\" typeof=\"mw:Transclusion\"></span> <a rel=\"mw:WikiLink\" href=\"/wiki/paean\" title=\"paean\">paean</a> <span class=\"mention-gloss-paren\" about=\"#mwt52\" typeof=\"mw:Transclusion\">(</span><span class=\"mention-gloss\" about=\"#mwt52\">enthusiastic expression of praise</span><span class=\"mention-gloss-paren\" about=\"#mwt52\">)</span>"}]},{"partOfSpeech":"Noun","language":"Polish","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/hemostat\" title=\"hemostat\">hemostat</a>, <span class=\"Latn\" lang=\"en\" about=\"#mwt56\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/pean#English\" class=\"mw-selflink-fragment\">pean</a></span>"}]}],"ro":[{"partOfSpeech":"Noun","language":"Romanian","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/paean\" title=\"paean\">paean</a>"}]}],"es":[{"partOfSpeech":"Verb","language":"Spanish","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt66\" typeof=\"mw:Transclusion\">inflection of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"es\"><a rel=\"mw:WikiLink\" href=\"/wiki/peer#Spanish\" title=\"peer\">peer</a></i></span>:</span><span about=\"#mwt66\">\n</span><ol about=\"#mwt66\"><li><span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#plural_number\" title=\"Appendix:Glossary\">plural</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#present_tense\" title=\"Appendix:Glossary\">present</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#subjunctive_mood\" title=\"Appendix:Glossary\">subjunctive</a></span></li>\n<li><span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#plural_number\" title=\"Appendix:Glossary\">plural</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#imperative_mood\" title=\"Appendix:Glossary\">imperative</a></span></li></ol>"},{"definition":"<span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#plural_number\" title=\"Appendix:Glossary\">plural</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#present_tense\" title=\"Appendix:Glossary\">present</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#subjunctive_mood\" title=\"Appendix:Glossary\">subjunctive</a></span>"},{"definition":"<span class=\"form-of-definition use-with-mention\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#third_person\" title=\"Appendix:Glossary\">third-person</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#plural_number\" title=\"Appendix:Glossary\">plural</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#imperative_mood\" title=\"Appendix:Glossary\">imperative</a></span>"}]}]}
@@ -0,0 +1 @@
1
+ {"en":[{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"A person who is <a rel=\"mw:WikiLink\" href=\"/wiki/exceptionally\" title=\"exceptionally\">exceptionally</a> <a rel=\"mw:WikiLink\" href=\"/wiki/clever\" title=\"clever\">clever</a>, <a rel=\"mw:WikiLink\" href=\"/wiki/gifted\" title=\"gifted\">gifted</a> or <a rel=\"mw:WikiLink\" href=\"/wiki/skilled\" title=\"skilled\">skilled</a> in a particular area.","parsedExamples":[{"example":"a maths <b>wiz</b>"}],"examples":["a maths <b>wiz</b>"]},{"definition":"<span class=\"usage-label-sense\" about=\"#mwt9\" typeof=\"mw:Transclusion\"></span> A <a rel=\"mw:WikiLink\" href=\"/wiki/wizard\" title=\"wizard\">wizard</a>; an <a rel=\"mw:WikiLink\" href=\"/wiki/administrator\" title=\"administrator\">administrator</a> of a <a rel=\"mw:WikiLink\" href=\"/wiki/multi-user_dungeon\" title=\"multi-user dungeon\">multi-user dungeon</a>."}]},{"partOfSpeech":"Verb","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt13\" typeof=\"mw:Transclusion\"></span> To be promoted to wizard (administrator) status in a <a rel=\"mw:WikiLink\" href=\"/wiki/multi-user_dungeon\" title=\"multi-user dungeon\">multi-user dungeon</a>, by completing the game quest.","parsedExamples":[{"example":"I lost interest and stopped playing soon after I <b>wizzed</b>."}],"examples":["I lost interest and stopped playing soon after I <b>wizzed</b>."]}]},{"partOfSpeech":"Noun","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt17\" typeof=\"mw:Transclusion\"></span> <span class=\"form-of-definition use-with-mention\" about=\"#mwt18\" typeof=\"mw:Transclusion\">Alternative spelling of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/whiz#English\" title=\"whiz\">whiz</a></i></span></span>: an <a rel=\"mw:WikiLink\" href=\"/wiki/act\" title=\"act\">act</a> of <a rel=\"mw:WikiLink\" href=\"/wiki/urination\" title=\"urination\">urination</a>.","parsedExamples":[{"example":"I have to take a <b>wiz</b>."}],"examples":["I have to take a <b>wiz</b>."]}]},{"partOfSpeech":"Preposition","language":"English","definitions":[{"definition":"<span class=\"usage-label-sense\" about=\"#mwt23\" typeof=\"mw:Transclusion\"></span> <span class=\"form-of-definition use-with-mention\" about=\"#mwt24\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/pronunciation_spelling\" title=\"pronunciation spelling\">Pronunciation spelling</a> of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"en\"><a rel=\"mw:WikiLink\" href=\"/wiki/with#English\" title=\"with\">with</a></i></span></span><link rel=\"mw:PageProp/Category\" href=\"./Category:English_pronunciation_spellings#WIZ\" about=\"#mwt24\">.\n\n<span class=\"mw-empty-elt\" about=\"#mwt25\" typeof=\"mw:Transclusion\"><link rel=\"mw:PageProp/Category\" href=\"./Category:en:Bodily_fluids#WIZ\"><link rel=\"mw:PageProp/Category\" href=\"./Category:en:People#WIZ\"></span>\n<span class=\"mw-empty-elt\" about=\"#mwt26\" typeof=\"mw:Transclusion\"><link rel=\"mw:PageProp/Category\" href=\"./Category:English_3-letter_words#WIZ\"></span>"}]}],"other":[{"partOfSpeech":"Adjective","language":"Old High German","definitions":[{"definition":"<a rel=\"mw:WikiLink\" href=\"/wiki/white\" title=\"white\">white</a>"}]}],"pl":[{"partOfSpeech":"Noun","language":"Polish","definitions":[{"definition":"<span class=\"form-of-definition use-with-mention\" about=\"#mwt108\" typeof=\"mw:Transclusion\"><a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#genitive_case\" title=\"Appendix:Glossary\">genitive</a> <a rel=\"mw:WikiLink\" href=\"/wiki/Appendix:Glossary#plural_number\" title=\"Appendix:Glossary\">plural</a> of <span class=\"form-of-definition-link\"><i class=\"Latn mention\" lang=\"pl\"><a rel=\"mw:WikiLink\" href=\"/wiki/wiza#Polish\" title=\"wiza\">wiza</a></i></span></span>"}]}]}
@@ -0,0 +1 @@
1
+ {"status":404,"type":"Internal error"}
@@ -3,27 +3,51 @@ import { load } from 'cheerio';
3
3
  import { request } from '../lib';
4
4
  import type { ParsingResult } from '../types';
5
5
 
6
- const DOES_NOT_EXIST_MESSAGE =
7
- "The word you've entered isn't in the dictionary. Click on a spelling suggestion below or try again using the search bar above.";
6
+ interface ResponsePayload {
7
+ en?: Usage[];
8
+ }
9
+
10
+ interface Usage {
11
+ definitions?: Definition[];
12
+ }
13
+
14
+ interface Definition {
15
+ definition: string;
16
+ }
8
17
 
9
18
  export const crawl = (word: string): Promise<string> => {
10
19
  return request({
11
20
  protocol: 'https',
12
- hostname: 'www.merriam-webster.com',
13
- path: `/dictionary/${encodeURIComponent(word)}`,
21
+ hostname: 'en.wiktionary.org',
22
+ path: `/api/rest_v1/page/definition/${encodeURIComponent(word)}`,
23
+ headers: {
24
+ 'User-Agent': 'scrabble-solver (https://github.com/kamilmielnik/scrabble-solver)',
25
+ },
14
26
  });
15
27
  };
16
28
 
17
- export const parse = (html: string): ParsingResult => {
18
- const $ = load(html);
19
- $('strong.mw_t_bc').replaceWith(', ');
20
- $('.text-lowercase').remove();
21
- $('.sub-content-thread').remove();
29
+ export const parse = (json: string): ParsingResult => {
30
+ let data: ResponsePayload;
31
+
32
+ try {
33
+ data = JSON.parse(json);
34
+ } catch {
35
+ return { definitions: [], exists: false };
36
+ }
37
+
38
+ const usages: Usage[] = data?.en ?? [];
39
+
40
+ if (!Array.isArray(usages)) {
41
+ return { definitions: [], exists: false };
42
+ }
22
43
 
23
- const $definitions = $('[id^=dictionary-entry]').find('.dtText, .cxl-ref');
44
+ const definitions = usages
45
+ .flatMap((usage) => (usage.definitions ?? []).map(({ definition }) => definition))
46
+ .map((definition) => load(definition).text().trim())
47
+ .filter(Boolean);
24
48
 
25
49
  return {
26
- definitions: Array.from($definitions).map((definition) => $(definition).text().replace(/\n/g, '')),
27
- exists: $('.spelling-suggestion-text').text().trim() !== DOES_NOT_EXIST_MESSAGE,
50
+ definitions,
51
+ exists: definitions.length > 0,
28
52
  };
29
53
  };
@@ -19,12 +19,13 @@ const tests = [
19
19
  { locale: Locale.DE_DE, word: 'ho' },
20
20
  { locale: Locale.DE_DE, word: 'kolla' },
21
21
  { locale: Locale.DE_DE, word: 'vom' },
22
- { locale: Locale.EN_US, word: 'awe' },
23
- { locale: Locale.EN_US, word: 'oe' },
24
- { locale: Locale.EN_US, word: 'pawn' },
25
- { locale: Locale.EN_US, word: 'pawnee' },
26
- { locale: Locale.EN_US, word: 'pean' },
27
- { locale: Locale.EN_US, word: 'wiz' },
22
+ { extension: 'json', locale: Locale.EN_US, word: 'awe' },
23
+ { extension: 'json', locale: Locale.EN_US, word: 'oe' },
24
+ { extension: 'json', locale: Locale.EN_US, word: 'pawn' },
25
+ { extension: 'json', locale: Locale.EN_US, word: 'pawnee' },
26
+ { extension: 'json', locale: Locale.EN_US, word: 'pean' },
27
+ { extension: 'json', locale: Locale.EN_US, word: 'wiz' },
28
+ { extension: 'json', locale: Locale.EN_US, word: 'zzzzqq' },
28
29
  { locale: Locale.ES_ES, word: 'corma' },
29
30
  { locale: Locale.ES_ES, word: 'portero' },
30
31
  { locale: Locale.RO_RO, word: 'aciua' },
@@ -32,8 +33,8 @@ const tests = [
32
33
  ];
33
34
 
34
35
  describe('parse', () => {
35
- it.each(tests)(`[$locale] "$word"`, ({ locale, word }) => {
36
- const input = readTestFile(`input/${locale}.${word}.html`);
36
+ it.each(tests)(`[$locale] "$word"`, ({ extension = 'html', locale, word }) => {
37
+ const input = readTestFile(`input/${locale}.${word}.${extension}`);
37
38
  const expected = readExpected(`expected/${locale}.${word}.json`);
38
39
  expect(parse(locale, input)).toEqual(expected);
39
40
  });
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scrabble-solver/word-lists",
3
- "version": "2.16.5",
3
+ "version": "2.16.7",
4
4
  "description": "Scrabble Solver 2 - Word lists",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -19,15 +19,15 @@
19
19
  },
20
20
  "homepage": "https://scrabble-solver.org",
21
21
  "scripts": {
22
- "build": "tsgo --project .",
22
+ "build": "tsc --project .",
23
23
  "clean": "rimraf build/"
24
24
  },
25
25
  "dependencies": {
26
- "@scrabble-solver/types": "^2.16.5",
26
+ "@scrabble-solver/types": "^2.16.7",
27
27
  "cheerio": "^1.2.0",
28
28
  "follow-redirects": "^1.16.0",
29
29
  "transliteration": "^2.6.1",
30
- "unzipper": "^0.12.3"
30
+ "unzipper": "^0.12.5"
31
31
  },
32
32
  "devDependencies": {
33
33
  "@types/follow-redirects": "^1.14.4",