Yes, by Leonard Wibberley, an Irish born American in 1955. The sequel, The Mouse on the Moon, was also a film. There were two other sequels, the Mouse On Wall Street and The Mouse That Saved the West.
The Duchess is based on Queen Victoria (hence the fact that she's widowed). The Prime Minister is based on Victorian Prime Minister Gladstone. The Leader of the Opposition is just a typical Old Labour Minister.