The preview shows up here.
MIME lookup is an offline table of media types and the extensions that go with them. photo.JPEG matches image/jpeg, and the extensions listed are jpeg, jpg and jpe. The match uses the last suffix, so a longer filename still resolves, and the case of JPEG does not matter. application/json; charset=utf-8 matches application/json and the extension json, because the parameter after the semicolon is stripped before the lookup.
You can search by extension or by the full type. A type that the table does not contain, or an extension it has never mapped, is an error that says the offline index has no match. Some extensions belong to more than one type, and those rows all come back. The table is the Apache httpd list plus a set of modern web types. It is not a scan of a file’s bytes. The file-type detector is the tool that reads a signature instead of a name.
Empty input lists the index, which is long. Type the extension or the type you actually need.
photo.JPEG
image/jpeg jpeg, jpg, jpe
The suffix is the lookup, not the whole filename. photo.JPEG and scan.jpeg are the same row.
image/jpeg. The extensions on that row are jpeg, jpg and jpe. Capital letters in the filename do not matter.
No. application/json; charset=utf-8 is looked up as application/json, extension json.
The index records more than one media type for some suffixes. All of those rows are shown. The name alone cannot decide between them.
No. It reads the name or the type you type. A detector that looks at bytes is a different tool.