The fundamental thing we need to do before we can implement the macro import operation is how we're going to represent macro tiddlers. Your implementation looks like import arbitrary wikitext tiddlers, extracting the macro definitions from them, but there are alternatives (basically to handle importing as a special kind of parameterised transclusion).

I can't tell yet how you handle refreshing; we need to make sure that if the tiddler containing the macro definitions changes (or presumably any that it imports) then we'll refresh any affected macro invocations.