CommunityToolkit / CommunityToolkit/dotnet
Can't easily Map collection from .NET Standard to MetadataControl?
- Lingua principale
- C#
- Stelle
- 3.8k
- Fork
- 400
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
## Describe the bug
Since we've been doing a lot more with the MVVM Toolkit lately, I was thinking about the scenario where your data model may be coming from .NET Standard. E.g. having a list of items for tags or something.
Currently, you'd have to hard create a new list of `MetadataItem` from that list and make sure you observe any changes to re-map yourself.
It'd be nice if we could take in any collection of items and map to the properties we need instead. Like `ComboBox` does with `DisplayMemberPath` for instance. Though this may be a bit odd for commands?
It's also a lot more reflection heavy to do it that way... And I don't think we'd want a general `MetadataItem` type class in our .NET Standard libraries to be tied specifically to a control in our UI library...
Do we see this as an issue with using the control?
## Environment
NuGet Package(s): 7.1.0-rc1
Package Version(s):
Windows 10 Build Number:
- [ ] Fall Creators Update (16299)
- [ ] April 2018 Update (17134)
- [ ] October 2018 Update (17763)
- [ ] May 2019 Update (18362)
- [ ] May 2020 Update (19041)
- [ ] Insider Build ({build_number})
App min and target version:
- [ ] Fall Creators Update (16299)
- [ ] April 2018 Update (17134)
- [ ] October 2018 Update (17763)
- [ ] May 2019 Update (18362)
- [ ] May 2020 Update (19041)
- [ ] Insider Build ({build_number})
Device form factor:
- [ ] Desktop
- [ ] Xbox
- [ ] Surface Hub
- [ ] IoT
Visual Studio version:
- [ ] 2017 (15.{minor_version})
- [ ] 2019 (16.{minor_version})
- [ ] 2022 (17.{minor_version})
## Additional context
FYI @vgromfeld @Sergio0694
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Esamina l’utilizzo di MetadataControl e MetadataItem descritto nell’issue, quindi determina se il mapping delle collection appartiene al controllo o richiede un’astrazione separata. Chiarisci le proprietà degli elementi supportate, il comportamento dei comandi e le aspettative relative alle notifiche di modifica prima di definire cosa dovrebbe includere una soluzione completa.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- csharp
- Ambito
- frontend
- Tipo di issue
- Funzionalità
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 25/100