Artifact filename and extension logic reworked to better distinguish plain files from other artifact kinds
Claude Code's logic for turning an artifact's title into a filename has been reworked with new helpers: one splits a filename into its stem and extension, one maps an artifact's content type and language to the right file extension (using an expanded language-to-extension map), and one derives a clean filename from an artifact's title. This replaces and extends the older extension-derivation code, and adds a set of extensions considered "plain."
This should make filenames generated for artifacts (including plain files, distinct from other artifact kinds like diagrams) more accurate and consistent, particularly for content types and languages that weren't well handled before.