4-rings or 4-squares puzzle

You are encouraged to solve this task according to the task description, using any language you may know.
Task

Replace       a, b, c, d, e, f,   and
  g        with the decimal
digits   LOW   ───►   HIGH

such that the sum of the letters inside of each of the four large squares add up to
the same sum.

            ╔══════════════╗      ╔══════════════╗
            ║              ║      ║              ║
            ║      a       ║      ║      e       ║
            ║              ║      ║              ║
            ║          ┌───╫──────╫───┐      ┌───╫─────────┐
            ║          │   ║      ║   │      │   ║         │
            ║          │ b ║      ║ d │      │ f ║         │
            ║          │   ║      ║   │      │   ║         │
            ║          │   ║      ║   │      │   ║         │
            ╚══════════╪═══╝      ╚═══╪══════╪═══╝         │
                       │       c      │      │      g      │
                       │              │      │             │
                       │              │      │             │
                       └──────────────┘      └─────────────┘

Show all output here.



   Show all solutions for each letter being unique with
        LOW=1     HIGH=7

   Show all solutions for each letter being unique with
        LOW=3     HIGH=9

   Show only the   number   of solutions when each letter can be non-unique
        LOW=0     HIGH=9



Related task

 Solve the no connection puzzle


func four_squares (list, unique=true, show=true) {
 
    var solutions = []
 
    func check(c) {
        solutions << c if ([
            c[0] + c[1],
            c[1] + c[2] + c[3],
            c[3] + c[4] + c[5],
            c[5] + c[6],
        ].uniq.len == 1)
    }
 
    if (unique) {
        list.combinations(7, {|*a|
            a.permutations { |*c|
                check(c)
            }
        })
    } else {
        7.of { list }.cartesian {|*c|
            check(c)
        }
    }
 
    say (solutions.len,
        (unique ? ' ' : ' non-'),
        "unique solutions found using #{list.join(', ')}.\n")
 
    if (show) {
        var f = "%#{list.max.len+1}s"
        say ("\n".join(
                ('a'..'g').map{f % _}.join,
                solutions.map{ .map{f % _}.join }...
        ), "\n")
    }
}
 
# TASK
four_squares(@(1..7))
four_squares(@(3..9))
four_squares([8, 9, 11, 12, 17, 18, 20, 21])
four_squares(@(0..9), unique: false, show: false)