Update I added a "Ryobi Weed Trimmer cap_reinforced_tabs.stl" version.
I uploaded an updated version with extra supports for the snap-on tabs, since my printed version broke after about 30 minutes of using my weed trimmer. I think the additional supports should resolve the issue, and I also slightly increased the diameter of the disc to keep dirt and debris from getting caught underneath.
The spool cap for my Ryobi One+ 18V electric weed trimmer broke after being scraped, scratched and cracked from hitting fence posts, asphalt, etc. so I designed and printed a more durable replacement.
PETG is necessary to provide strength and flexibility required for the snap tabs; ABS may also work if it's flexible enough. PLA might initially work for a while but weaken and snap, or deform due to heat. Feel free to try it and let the community know how it works for you.
I added a Ryobi logo to add some flair to the otherwise boring, flat surface.
Designed in Tinkercad.
Amazon Basics PETG
Supports needed for clean edges on the tabs, otherwise it might not fit securely. PETG is recommended for strength, flexibility and heat resistance.