Skip to content

Commit

Permalink
feat: estimated time lexicon
Browse files Browse the repository at this point in the history
  • Loading branch information
hbjydev committed Dec 9, 2024
1 parent a1df13f commit 052c1b9
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 0 deletions.
14 changes: 14 additions & 0 deletions lexicons/moe/hayden/cookware/defs.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,20 @@
"description": "The instruction to provide to the user."
}
}
},
"elapsedTime": {
"type": "object",
"required": ["amount", "unit"],
"properties": {
"amount": {
"type": "integer",
"description": "The amount of (#unit) to display."
},
"unit": {
"type": "string",
"description": "The unit to display the time in."
}
}
}
}
}
4 changes: 4 additions & 0 deletions lexicons/moe/hayden/cookware/recipe.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@
"maxGraphemes": 300,
"description": "The description of the recipe."
},
"estimate": {
"type": "ref",
"ref": "moe.hayden.cookware.defs#elapsedTime"
},
"ingredients": {
"type": "array",
"items": {
Expand Down
8 changes: 8 additions & 0 deletions libs/lexicons/src/atcute.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,13 @@ import "@atcute/client/lexicons";

declare module "@atcute/client/lexicons" {
namespace MoeHaydenCookwareDefs {
interface ElapsedTime {
[Brand.Type]?: "moe.hayden.cookware.defs#elapsedTime";
/** The amount of (#unit) to display. */
amount: number;
/** The unit to display the time in. */
unit: string;
}
interface Ingredient {
[Brand.Type]?: "moe.hayden.cookware.defs#ingredient";
/** How much of the ingredient is needed. */
Expand Down Expand Up @@ -103,6 +110,7 @@ declare module "@atcute/client/lexicons" {
* Maximum grapheme length: 300
*/
description?: string;
estimate?: MoeHaydenCookwareDefs.ElapsedTime;
}
}

Expand Down

0 comments on commit 052c1b9

Please sign in to comment.