Games have had mechanics like this for a long time though
Diablo 2 for instance, you could use in-game gold to buy Unidentified Items, which when Identified could turn out to be a lot of things. Arguably the same as a loot box mechanic.
The thing that makes Loot Boxes insidious to me isn't just the RNG, or the "purchase", it's the real world money part.
Also, in the instance of Diablo 2 (and many other games), I wouldn't call the Gold earned in-game a "Digital Currency". It's a game currency sure, but I think a game currency needs some way to be expressed as in real world dollars to be considered "Digital Currency"
My example for that is Destiny 2. There is the game currency "glimmer". Then there is the digital currency you can earn through playing "bright dust". Then the premium digital currency you purchase with money "silver". Silver and Bright dust can purchase the same items, so there's more or less a conversion rate between Bright Dust and Real Money even though you can't actually convert it into real money.
So, defining digital currency this way allows Diablo 2 to skirt past the digital currency problem, but it's still "RNG rewards that are earned through playing the game"
The real money blurring line of loot boxes is terrible of course, but the real problems I have are the enforced scarcity, and the fanfare when you open them.
Game devs use all sorts of time gating tricks to make sure you can only earn so many loot boxes through gameplay in a period of time, so if you want more faster you are encouraged to buy with real money. They make sure to give a big reveal when you open a loot box to really sell the idea that opening it is exciting and fun, making you want to do it more.
It's just overall an extremely exploitative and miserable practice. I hate loot boxes.