Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slug field: option to make field readonly #1212

Open
JohannaPeanut opened this issue Jul 4, 2024 · 1 comment
Open

Slug field: option to make field readonly #1212

JohannaPeanut opened this issue Jul 4, 2024 · 1 comment

Comments

@JohannaPeanut
Copy link

Hi
We like to work with the slug field to have automatic slug generation. However, we have found that in certain cases (especially with collections, and when it comes to relations) it would be very useful to have the option to use the slug field as a read-only field.
Thank you :)

@tordans
Copy link
Contributor

tordans commented Jul 4, 2024

For example something like a readonly:boolean property

slug?: {
  label?: string;
  generate?: (name: string) => string;
  description?: string;
+   readonly?: boolean;
  validation?: {
    length?: {
      min?: number;
      max?: number;
    };
  };
};

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants