### Description

### Description

The _terms_enum API [currently supports](https://github.com/elastic/elasticsearch/pull/83244) keyword, constant_keyword and flattened fields. 

Kibana would also like to support `ip` field type: https://github.com/elastic/kibana/issues/140266
Opening this issue to discuss if this is possible. 

I tried to workaround this limitation in Kibana using terms_agg for suggestions, but this also didn't work: 
https://github.com/elastic/kibana/issues/140266#issuecomment-1240828371



Note: there is a similar issue and some progress on _version_ type: https://github.com/elastic/elasticsearch/issues/83403



server/src/main/java/org/elasticsearch/index/mapper/IpFieldMapper.java
if (value instanceof InetAddress) {
                        address = (InetAddress) value;
                    } else {
                        address = InetAddresses.forString(value.toString());
                    }
                    return InetAddresses.toAddrString(address);
                }
            };
        }
        @Override
        public Query termQuery(Object value, @Nullable SearchExecutionContext context) {
            failIfNotIndexedNorDocValuesFallback(context);
            Query query;
            if (value instanceof InetAddress) {
                query = InetAddressPoint.newExactQuery(name(), (InetAddress) value);
            } else {
                if (value instanceof BytesRef) {
                    value = ((BytesRef) value).utf8ToString();
                }
                String term = value.toString();
                if (term.contains("/")) {
                    final Tuple<InetAddress, Integer> cidr = InetAddresses.parseCidr(term);
                    query = InetAddressPoint.newPrefixQuery(name(), cidr.v1(), cidr.v2());
                } else {
                    InetAddress address = InetAddresses.forString(term);
                    query = InetAddressPoint.newExactQuery(name(), address);
                }
            }
            if (isIndexed()) {
                return query;