aboutsummaryrefslogtreecommitdiff
path: root/static/ts/components/input-list.ts
diff options
context:
space:
mode:
Diffstat (limited to 'static/ts/components/input-list.ts')
-rw-r--r--static/ts/components/input-list.ts14
1 files changed, 14 insertions, 0 deletions
diff --git a/static/ts/components/input-list.ts b/static/ts/components/input-list.ts
index 0afd4999..31dd5158 100644
--- a/static/ts/components/input-list.ts
+++ b/static/ts/components/input-list.ts
@@ -1,3 +1,13 @@
+/**
+ * `<input-list />`
+ *
+ * A list of identical input fields, which forms a group. For example
+ * useful to handle keywords.
+ *
+ * @category Web Components
+ * @mergeTarget components
+ * @module
+ */
export { InputList }
/*
@@ -58,6 +68,10 @@ class InputList extends HTMLElement {
this.appendChild(new_el);
}
+ /**
+ * The value from each element, except the last which should always be empty.
+ * Has an unspecified type, since children:s value field might give non-strings.
+ */
get value(): any[] {
let value_list = []
for (let child of this.children) {