(
context: TaskModalUserFieldContext,
inputRefs: Map<string, HTMLInputElement>,
field: UserMappedField,
input: HTMLInputElement,
options: { attachSuggest?: boolean } = {}
)
| 285 | } |
| 286 | |
| 287 | function registerTextInput( |
| 288 | context: TaskModalUserFieldContext, |
| 289 | inputRefs: Map<string, HTMLInputElement>, |
| 290 | field: UserMappedField, |
| 291 | input: HTMLInputElement, |
| 292 | options: { attachSuggest?: boolean } = {} |
| 293 | ): void { |
| 294 | inputRefs.set(field.key, input); |
| 295 | context.attachMobileKeyboardScrollGuard(input); |
| 296 | |
| 297 | if (options.attachSuggest !== false) { |
| 298 | new UserFieldSuggest(context.app, input, context.plugin, field); |
| 299 | } |
| 300 | } |
| 301 | |
| 302 | function getTextValue(text: TextComponent): string { |
| 303 | return typeof text.getValue === "function" ? text.getValue() : text.inputEl.value; |
no test coverage detected