Test with name suggestion index

This commit is contained in:
Robin van der Linde 2024-04-25 00:56:36 +02:00
parent 00ab3a1b77
commit 6786c8f321
Signed by untrusted user: Robin-van-der-Linde
GPG key ID: 53956B3252478F0D
7 changed files with 371 additions and 5 deletions

View file

@ -0,0 +1,37 @@
import Title from "../../Base/Title"
import Combine from "../../Base/Combine"
import { Validator } from "../Validator"
import Table from "../../Base/Table"
export default class NameSuggestionIndexValidator extends Validator {
constructor() {
super(
"nsi",
new Combine([
"Gives a list of possible suggestions for a brand or operator tag.",
new Title("Helper arguments"),
new Table(
["name", "doc"],
[
[
"options",
new Combine([
"A JSON-object of type `{ main: string, key: string }`. ",
new Table(
["subarg", "doc"],
[
[
"main",
"The main tag to give suggestions for, e.g. `amenity=restaurant`.",
],
["key", "The key to give suggestions for, e.g. `brand`."],
]
),
]),
],
]
),
])
)
}
}