import { jsx as _jsx } from "react/jsx-runtime";
import { forwardRef } from "react";
import { formMessageCounter } from "./formMessageStyles.js";
/**
 * This component can be used to create a "counter" within the
 * {@link FormMessage} component.
 *
 * Note: This is really only useful when using the {@link FormMessage} component
 * without a {@link TextField}.
 *
 * @example Example Usage
 * ```ts
 * interface ExampleProps {
 *   min: number;
 *   max: number;
 * }
 *
 * function Example({ min, max }: ExampleProps) {
 *   return (
 *     <FormMessage disableWrap>
 *       <FormMessageCounter>
 *         {`${min} / ${max}`}
 *       </FormMessageCounter>
 *     </FormMessage>
 *   );
 * }
 * ```
 *
 * @see {@link https://react-md.dev/components/form-message | FormMessage Demos}
 * @see {@link https://react-md.dev/components/text-field | TextField Demos}
 * @since 2.9.0
 * @since 6.3.0 Supports refs.
 */ export const FormMessageCounter = /*#__PURE__*/ forwardRef(function FormMessageCounter(props, ref) {
    const { children, className, ...remaining } = props;
    return /*#__PURE__*/ _jsx("span", {
        ref: ref,
        ...remaining,
        className: formMessageCounter({
            className
        }),
        children: children
    });
});

//# sourceMappingURL=FormMessageCounter.js.map