UNPKG

react-ocean-forms

Version:
30 lines (29 loc) 919 B
/** * Copyright (c) 2018-present, Umweltbundesamt GmbH * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ export interface IMessageValues { [s: string]: string; } export declare type TSTringFormatter = ((id: string, values?: IMessageValues) => string); interface IMessages { [s: string]: string; } export declare const TEST_MESSAGES: IMessages; /** * Uses the parameterized string and replaces the * templates with the values passed as the second * parameter. * @param id Message id to be formatted * @param values Parameter values */ export declare const stringFormatter: TSTringFormatter; /** * Adds custom messages to be supported by the * stringFormatter * @param messages Object containing messages */ export declare const addCustomMessages: (messages: IMessages) => void; export {};