は閉まっていた

was closed

→ は
phrase Rare #27,502
was closed は marks the topic; 閉まっていた describes a past state of being closed.
JA: 図書館は閉まっていた。
EN: The library was closed.

あいにく店は閉まっていた。

Unfortunately, the store was closed.

日曜日だったので、店は閉まっていた。

Since it was Sunday, the store was closed.

トムのカーテンは閉まっていた。

Tom's curtains were closed.