Assuming you don't actually need that relationship embedded in the database, you can simply do:
class Foo
{
public ICollection<Bar> Bars { get; set; }
public Bar ActiveBar => Bars?.FirstOrDefault(b => b.IsActive);
}
You'll probably also want a unique filtered index on the
Bar
table, so that you can only have one active Bar per Foo:
modelBuilder.Entity<Bar>().HasIndex(b => b.FooID).IsUnique().HasFilter("IsActive = 1");