Bug 220437

Summary: Web Inspector: Sources: resources should be sorted not including the extension
Product: WebKit Reporter: Devin Rousso <hi>
Component: Web InspectorAssignee: Jon Davis <jond>
Status: RESOLVED FIXED    
Severity: Normal CC: hi, inspector-bugzilla-changes, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: All   
OS: All   

Description Devin Rousso 2021-01-07 14:29:17 PST
# STEPS TO REPRODUCE
1. inspect <https://webkit.org/>
2. toggle dark mode (should have `chevron.svg` and `chevron-dark.svg`)

# EXPECTED
`chevron.svg` should be before `chevron-dark.svg`

# ACTUAL
`chevron.svg` is after `chevron-dark.svg`

I believe this is because Web Inspector does a `String.prototype.localeCompare` against the titles as they are shown in the UI which includes the extension.  It may be desirable to call `WI.fileExtensionForFilename` before sorting and only include the extension if the filename is the same.
Comment 1 Radar WebKit Bug Importer 2021-01-07 14:29:28 PST
<rdar://problem/72905353>
Comment 2 Jon Davis 2023-09-27 12:12:34 PDT
Pull request: https://github.com/WebKit/WebKit/pull/18298
Comment 3 EWS 2023-09-27 19:21:49 PDT
Committed 268557@main (5060974c125e): <https://commits.webkit.org/268557@main>

Reviewed commits have been landed. Closing PR #18298 and removing active labels.
Comment 4 Jon Davis 2023-09-28 07:12:55 PDT
Re-opening to address an enhancement recommended during review.
Comment 5 Jon Davis 2023-09-28 07:20:50 PDT
Pull request: https://github.com/WebKit/WebKit/pull/18350