package ui

import (
	"errors"
	"regexp"
)

func ValidateString(s string) error {
	validRegex := regexp.MustCompile(`^[a-zA-Z0-9_.]+$`)
	if !validRegex.MatchString(s) {
		return errors.New("invalid input")
	}
	return nil
}
