The origin is the context of a purchase transaction where the exchange of money for goods seemed fair (good value for both the purchaser and seller).
Since it is typically more common for exchanges to be worth more to the seller in order for them to generate a profit, if an exchange is described as fair this would be recognised as decent or generous by the recipient when compared to normal.
Over time this word fair used outside of the context of trade would still typically be interpreted as decent, synonymous with generous, substantial or quite big when referring to a generic quantity (duration, length, distance etc).
Etymology of the word fair showing relation to the sale of goods:
"Middle English (in the sense ‘periodic gathering for the sale of goods’): from Old French feire, from late Latin feria, singular of Latin feriae ‘holy days’ (on which such fairs were often held)." - Google Search.
Reference to fair in context of trade showing inequality in perception of a fair price:
"In exchange relationships, seller’s fair price will be higher than buyer’s fair price. The hypothesis assumes that buyers and sellers are considering only their own well being. In terms of price information, the seller’s alternative is the opportunity cost, while the buyer’s alternative is the market price. For each of the parties, either opportunity cost or market price represents a reference price if they were doing business with someone else." - Maria-Eugenia Boza and William Diamond (1998) ,"The Social Context of Exchange: Transaction Utility, Relationships and Legitimacy", in NA - Advances in Consumer Research Volume 25, eds. Joseph W. Alba & J. Wesley Hutchinson, Provo, UT : Association for Consumer Research, Pages: 557-562.
Example of fair meaning "Adequate, reasonable, or decent":
"My hopes wa'n't disappointed. I never saw clams thicker than they was along them inshore flats. I filled my dreener in no time, and then it come to me that 'twouldn't be a bad idee to get a lot more, take 'em with me to Wellmouth, and peddle 'em out. Clams was fairly scarce over that side of the bay and ought to fetch a fair price." - 1913, Joseph C. Lincoln, chapter 3, in Mr. Pratt's Patients.
Etymology of fair in context of trade/commerce going back to at least early 14c:
"a stated market in a town or city; a regular meeting to buy, sell, or trade," early 14c., from Anglo-French feyre (late 13c.), from Old French feire, faire "fair, market; feast day," from Vulgar Latin *feria "holiday, market fair," from Latin feriae "religious festivals, holidays," related to festus "solemn, festive, joyous" - Online Etymology Dictionary by Douglas Harper.