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 anything that `ActiveRecord::Sanitization.sanitize_sql_for_conditions` accepts.
That was my hope, but unfortunately `sanitize_sql_hash_for_conditions` calls [`self.table_name`](https://github.com/rails/rails/blob/50e7c013c04544091f0081e495cacdd987f4d8e1/activerecord/lib/active_record/sanitization.rb#L93), ignoring the 2nd argument passed to `sanitize_sql_for_conditions`.