If this is true, then that is very bad indeed. No one has reported any issues with the included charger previously here. Rather, an adapter of some sort was always involved, but in this case you said that you only had your iPhone connected. That is very worrying. That suggests to me that this issue could be hardware-related, and if it is, there is no way I am keeping my MBA.
For the record, I have had my iPhone 12 Pro connected to my MBA while it was charging without any issues. I have also connected Apple's official AV-adapter to my MBA and then connected external drives to the adapter without issues. So the issue is not 100% reproducible, I guess.
Let me reconstruct the timelines.
I got the MacBook Air M1 on
November 17th, and I have been using it for weeks with a bunch of different adapters. With an Anker USB-C Power Supply, the original Apple powre supply, original apple HDMI/USB Adapters, 3rd party USB adapters.
The Device died on
December 3rd. I had the original Apple Power Adapter plugged into one port and wanted to test an XCode build on my phone. So I plugged my phone into the other USB-C port and I noticed that XCode did not recognize the phone. So I removed the two USB cables, plugged in the iPhone into the port that I had the power cable in before and it worked. When I plugged in the power cable into the USB port, that did not recognize the iPhone before, the device immediately turned off and was bricked.
Returned the device to the Apple Store after an appointment with the Genius Bar on
December 11th.
I got my new MacBook Pro (because an Air was not in Stock) on
December 14th. I have been using it daily since. I have paid close attention to not use
any third party USB-C accessories with this device. Everything worked fine. The only things I plugged into this was the Apple power supply, the apple USB-C->HDMI,USB-Adapter.
Today (January 8th), I was working with the device, everything went fine. I took the MacBook of the charger for lunch. When I came back with the device, I plugged in the original Apple power adapter or the usb-c dongle it died. I did not really look when exactly the screen turned off.
---
I think I just got unlucky with the devices I received ... Support was helpful and quickly offered exchanges, and all my data is in the cloud anyway. So it's a little annoyance for me, but I wouldn't go as far to say the devices are crap. Your mileage may very, of course.
They have shipped a few thousand of those devices, and here a handful of people is reporting issues. So I guess most people's devices just work fine.
Were you using an Apple adapter or a third party one?
First one: Both, at different times. When the device got bricked, I was only using the original Apple Power Supply
Second one: I only ever used the Apple Adapter for attaching USB devices or HDMI screens. But I always plugged in the Power Supply directly into the device, never through the adapter.