Contrary to what the button layout's simplicity might suggest, piano accordions predate button accordions in their modern chromatic forms.
The piano keyboard was already the dominant musical interface in European parlors and conservatories. Early accordion makers leveraged that familiarity—players could transfer keyboard skills directly. Button systems (diatonic then chromatic) evolved for compactness, uniform fingering across keys, and ergonomic density—advantages that matter more to advanced players than beginners.
Today, both coexist: piano accordion dominates in Americas, UK, Western Europe; chromatic button accordion (C-system/B-system) dominates in Eastern Europe, Russia, France, Scandinavia; diatonic button accordion rules folk traditions (Irish, Cajun, Tex-Mex, Balkan). The "which came first" answer depends on which branch of the family tree you're tracing—but the piano-keyboard chromatic accordion reached commercial maturity earlier.