from django.contrib.auth.forms import ReadOnlyPasswordHashField, UserChangeForm

from engine.core.widgets import JSONTableWidget
from engine.vibes_auth.models import User


class UserForm(UserChangeForm):
    password = ReadOnlyPasswordHashField(label="Password")

    class Meta:
        model = User
        fields = "__all__"
        widgets = {
            "attributes": JSONTableWidget(),
        }
