If the cleric uses Miracle to duplicate a spell, it is blocked by all the things that block that spell.
Without spending additional material components...
You state what you would like to have happen and request that your deity (or the power you pray to for spells) intercede.
A miracle can do any of the following things.
- Duplicate any cleric spell of 8th level or lower.
- Duplicate any other spell of 7th level or lower.
- Undo the harmful effects of certain spells, such as feeblemind or insanity.
- Have any effect whose power level is in line with the above effects.
When a uses Miracle to duplicates the effect of a spell with Miracle, her deity is not casting the spell on her behalf. Instead, her deity is using their power to create an effect that is exactly equal to the spell as if the cleric had cast it herself, except as otherwise stated in Miracle's text. (Note that the save DCs for the spell are affected by the cleric's spellcasting stat, feats, and items, and not by her Deity's!)
As such, a spell that is duplicated is subject to all of the same limitations as the original would be. Similarly, teleporting into a Dimensional Lock or Anti-Magic Field would not be "in line with" the other elements on that list, since it is expressly more powerful than Plane Shift or Greater Teleport.
If the cleric use Miracle with an expensive component, Dimensional Lock and Anti-Magic Field are (at least partially) effective
Dimensional Lock reads:
Once dimensional lock is in place, extradimensional travel into or out of the area is not possible.
There is no exception in the description of Dimensional Lock for divine beings. Even a Deity would be unable to move you through a Dimensional Lock.
Anti-Magic Field, as pointed out in the question, makes exceptions for Artifacts and Deities.
Artifacts and deities are unaffected
Therefore, if the cleric is requesting a Miracle from a Deity (and not from a non-deific entity that grants cleric spells, such as an Alignment), that Deity may ignore the anti-magic field when granting their request.
It doesn't matter, though, because the Miracle can negate the offending effect
The second effect of Miracle is unbounded as written. The examples given in the spell are just that - examples. At your DM's discretion, the entity that grants the cleric's spells, regardless of whether it is a deity or not, could simply end or suppress the Dimensional Lock/Anti-Magic Field, before depositing the cleric and her party at their destination.
In either case, Miracle cannot be cast if the cleric is already inside an Anti-Magic Field.
Miracle is a spell, and Anti-Magic Field.
prevents the functioning of any spells within its confines.
Thus, the Miracle spell would never take effect, and the deity would be unable to use the spell's effect to intercede. (But, depending on campaign/setting, might still be able to intervene of their own accord if they are inclined to help)