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

feat: admin upload controls #11615

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open

feat: admin upload controls #11615

wants to merge 9 commits into from

Conversation

kendelljoseph
Copy link
Contributor

What?

Adds the ability to add additional components to the file upload component.

export const Media: CollectionConfig = {
  slug: 'media',
  upload: {
    admin: {
      components: {
        controls: [
          '/collections/components/Control/index.js#CustomControl',
        ],
      },
    },
  },
  fields: [],
}
image

Why?

To enable the ability to add custom components when uploading documents near the primary upload operations.

@kendelljoseph kendelljoseph self-assigned this Mar 10, 2025
@kendelljoseph kendelljoseph marked this pull request as ready for review March 10, 2025 19:39
@rilrom
Copy link
Contributor

rilrom commented Mar 11, 2025

This makes me very happy. I'll no longer need a custom upload component for my image search plugin, thank you!

@PatrikKozak PatrikKozak self-requested a review March 12, 2025 14:03
Copy link
Contributor

@PatrikKozak PatrikKozak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kendelljoseph Can we update the styling of the Select a file & Paste url buttons or / it's parent wrappers so that the buttons do not stretch (like shown in your image above) if the parent height changes due to the custom components?

@kendelljoseph
Copy link
Contributor Author

@PatrikKozak yep, will do!

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

Successfully merging this pull request may close these issues.

3 participants