Attribution punctuation

When attribution appears in the middle of a quotation, it is generally preceded by a comma. Whether it is followed by a period or a comma depends on whether it is placed in the middle of a sentence or between two sentences:

“John went home,” she said. “I stayed behind.” … “John went outside,” she said, “to play baseball.”

Textbook: 16:1.C & following