### Godot version

Godot 4-beta10

### System information

Linux, KDE Neon, OpenGL3, Mesa Intel(R) UHD Graphics (CML GT2)

### Issue description

I can't move to Animation player when I open a AnimatedSprite

See the video:
https://youtu.be/_nyN42rNlTw


### Steps to reproduce

- Open Scene GPlayer
- Select Idle (Animation player) node
- Select Body (Animation sprite) node
- Select animation in bottom tab

### Minimal reproduction project

You can test in my game is open source and don't have many files 👍🏻 

[the-zero-day.zip](https://github.com/godotengine/godot/files/10304677/the-zero-day.zip)

if (p.name.begins_with(E.key) && E.key.length() > array_prefix.length()) {
				array_prefix = E.key;
			}
		}
		if (!array_prefix.is_empty()) {
			
			String str = p.name.trim_prefix(array_prefix);
			int to_char_index = 0;
			while (to_char_index < str.length()) {
				if (!is_digit(str[to_char_index])) {
					break;
				}
				to_char_index++;
			}
			if (to_char_index > 0) {
				array_index = str.left(to_char_index).to_int();
			} else {
				array_prefix = "";
			}
		}
		if (!array_prefix.is_empty()) {
			path = path.trim_prefix(array_prefix);
			int char_index = path.find("/");
			if (char_index >= 0) {
				path = path.right(-char_index - 1);
			} else {
				path = vformat(TTR("Element %s"), array_index);
			}
		} else {