"I was right joyful of that wall of stone, That shut the flowers and trees up with the sky, And trebled all the beauty: to the bone,
"Yea right through to my heart, grown very shy With weary thoughts, it pierced, and made me glad; Exceedingly glad, and I knew verily,
"A little thing just then had made me mad;
The speaker says that she actually enjoyed the stone wall – she didn't feel trapped by it; instead, its presence made everything inside it seem even more beautiful.
All that beauty went straight to her heart and made her happy.
She needed cheering up, because, remember, she'd been feeling sad and "careless" for a few months at this point.
She says she also realized that something was making her slightly "mad" (insane) at that moment – or that some little thing could potentially make her "mad."
The tense of the verb makes it unclear – did something already make her insane, or did she just realize that she was teetering on the brink, so that some little thing could make her go crazy?
She doesn't say what that something was, though, or why it would make her "mad."