From c680f5aa71b08e978444df07f93c381f9d47ab82 Mon Sep 17 00:00:00 2001 From: Sebastian Date: Mon, 5 Jun 2023 10:04:09 -0300 Subject: rename aml --- .../aml-backoffice-ui/src/handlers/Caption.tsx | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 packages/aml-backoffice-ui/src/handlers/Caption.tsx (limited to 'packages/aml-backoffice-ui/src/handlers/Caption.tsx') diff --git a/packages/aml-backoffice-ui/src/handlers/Caption.tsx b/packages/aml-backoffice-ui/src/handlers/Caption.tsx new file mode 100644 index 000000000..fbf154d89 --- /dev/null +++ b/packages/aml-backoffice-ui/src/handlers/Caption.tsx @@ -0,0 +1,35 @@ +import { VNode, h } from "preact"; +import { + IconAddon, + InputLine, + LabelWithTooltipMaybeRequired, + UIFormProps, +} from "./InputLine.js"; +import { TranslatedString } from "@gnu-taler/taler-util"; + +interface Props { + label: TranslatedString; + tooltip?: TranslatedString; + help?: TranslatedString; + before?: VNode; + after?: VNode; +} + +export function Caption({ before, after, label, tooltip, help }: Props): VNode { + return ( +
+ {before !== undefined && ( + {before} + )} + + {after !== undefined && ( + {after} + )} + {help && ( +

+ {help} +

+ )} +
+ ); +} -- cgit v1.2.3