The detail of the law here is rather complex, involving various different types of rights to inherit, and is explained fully in a separate SPICe Briefing from 2021. In summary, where there are no children, a spouse or civil partner will:
get prior rights to a share of the deceased person's house, furniture and money, up to certain financial limits
get legal...