case only supports shell patterns, and not regexes. But Bash supports regexes out of the box with a different syntax.
If you mean "any number of decimal numbers separated by dots", and e.g. no trailing letters or tags, then the pattern
^[0-9]+(\.[0-9]+)*$ would perhaps be appropriate.
([0-9]+\.*)+ would also match strings with consecutive or trailing dots, like
if [[ $version =~ $re ]]; then
echo "'$version' matches the pattern"
echo "'$version' doesn't match"
The regex says to look for
any number of decimal digits (
[0-9]+), followed by any number of groups (
(·)*) consisting of a literal dot (
\.) and any number of decimal digits (
$ lock the pattern to the start and end of the string, otherwise a matching substring would be enough for a match.
That would allow a version string without any dots, like
123. If you want to require at least two numbers and the dot, then use
^[0-9]+(\.[0-9]+)+$ (changing the last
* to a
Note that depending on the locale, what
[0-9] matches might be a bit surprising, it could include some weirder Unicode digits. Spelling out the allowed characters with
 would be stricter in that, but is more awkward and error-prone to write.