Allow array or hash syntax for partial index conditions

This is the newer version of #13353, based off of the latest master. It allows you to replace these migrations:

```ruby
add_index :foos, :user_id, unique: true, where: "status IN (0, 1)"
```

With this:

```ruby
add_index :foos, :user_id, unique: true, where: { status: [1, 2] }
```

It understands any Array that `ActiveRecord::Sanitization.sanitize_sql_array` accepts, and any Hash that `ActiveRecord::PredicateBuilder` accepts. It would've been great to just use `ActiveRecord::Sanitization.sanitize_sql_for_conditions` directly, but its implementation of `sanitize_sql_hash_for_conditions` assumes it is being called from within a `ActiveRecord::Base` class, which this is not. Figured this was a reasonable first pass!
@sgrif what if, instead of using `Relation`, I was able to directly use `ActiveRecord::Sanitization.sanitize_sql_for_conditions`? I was able to finally get that functioning correctly by creating a new `ActiveRecord::Base` class and setting `table_name` appropriately.

```ruby
def partial_index_conditions(where, table_name)
  klass = Class.new(ActiveRecord::Base).tap { |k| k.table_name = table_name }
  klass.send(:sanitize_sql_for_conditions, where)
end
```

That keeps this completely decoupled from `PredicateBuilder` as well as `Relation`.