Skip to content

feat(fileuploaderdropcontainer): added pattern for accepted file ext#9929

Merged
kodiakhq[bot] merged 9 commits into
carbon-design-system:mainfrom
TannerS:addCustomPatternForFileUploaderFileExt
Oct 28, 2021
Merged

feat(fileuploaderdropcontainer): added pattern for accepted file ext#9929
kodiakhq[bot] merged 9 commits into
carbon-design-system:mainfrom
TannerS:addCustomPatternForFileUploaderFileExt

Conversation

@TannerS

@TannerS TannerS commented Oct 22, 2021

Copy link
Copy Markdown
Contributor

Closes #

#9919

Changelog

Changed

I made a change based off a feature request I proposed and if the idea is worth taking into account, I thought I could take a gamble at it for my first carbon PR and get some experience with contributing to carbon

Basically, we found ourselves allowing file extensions that contain - an _ for our project. Even though we allow it in the accept prop, the built in regex does not allow it. So I thought if we could give he user access to changing/modifying that regex directly to work with what they pass into the accept prop it could help cases like ours. This best making changes to the regex like hard coding things for our need or every person's need that may or may not come a need.

Testing / Reviewing

My attempt at testing was a few things.

Regression test was my main thing. I added the default regex as a default prop to keep default behavior and tested this in a local storybook copy (after modifying the story book) and added unit test.

Thoughts

This idea is something I believe can be useful but i understand if this idea gets thrown out. If it does or does not, if there is any advice for the code or unit test (coding design, style, framework, etc) please let me know so I can learn and do better next time, thanks!

@TannerS TannerS requested a review from a team as a code owner October 22, 2021 23:15
@TannerS TannerS requested review from jnm2377 and joshblack October 22, 2021 23:15
@netlify

netlify Bot commented Oct 22, 2021

Copy link
Copy Markdown

✔️ Deploy Preview for carbon-react-next ready!

🔨 Explore the source changes: 7be01bc

🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-react-next/deploys/617ae7ea977e550008d2b2aa

😎 Browse the preview: https://deploy-preview-9929--carbon-react-next.netlify.app

@github-actions

github-actions Bot commented Oct 22, 2021

Copy link
Copy Markdown
Contributor

DCO Assistant Lite bot All contributors have signed the DCO.

@TannerS

TannerS commented Oct 22, 2021

Copy link
Copy Markdown
Contributor Author

I have read the DCO document and I hereby sign the DCO.

@netlify

netlify Bot commented Oct 22, 2021

Copy link
Copy Markdown

✔️ Deploy Preview for carbon-elements ready!

🔨 Explore the source changes: ec2b211

🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-elements/deploys/617346026d2ef8000809f7bb

😎 Browse the preview: https://deploy-preview-9929--carbon-elements.netlify.app

@netlify

netlify Bot commented Oct 22, 2021

Copy link
Copy Markdown

✔️ Deploy Preview for carbon-components-react ready!
Built without sensitive environment variables

🔨 Explore the source changes: ec2b211

🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-components-react/deploys/61734602e5870d000708a447

😎 Browse the preview: https://deploy-preview-9929--carbon-components-react.netlify.app

@netlify

netlify Bot commented Oct 23, 2021

Copy link
Copy Markdown

✔️ Deploy Preview for carbon-elements ready!

🔨 Explore the source changes: 7be01bc

🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-elements/deploys/617ae7eaad2b17000703f664

😎 Browse the preview: https://deploy-preview-9929--carbon-elements.netlify.app

@netlify

netlify Bot commented Oct 23, 2021

Copy link
Copy Markdown

✔️ Deploy Preview for carbon-components-react ready!
Built without sensitive environment variables

🔨 Explore the source changes: 7be01bc

🔍 Inspect the deploy log: https://app.netlify.com/sites/carbon-components-react/deploys/617ae7ea6cc22e00073ad156

😎 Browse the preview: https://deploy-preview-9929--carbon-components-react.netlify.app

@joshblack joshblack left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🎉

@jnm2377 jnm2377 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for contributing this! It looks great! 🎉

@TannerS TannerS requested a review from a team as a code owner October 28, 2021 18:11
@kodiakhq kodiakhq Bot merged commit 90ffba0 into carbon-design-system:main Oct 28, 2021
@TannerS TannerS deleted the addCustomPatternForFileUploaderFileExt branch October 28, 2021 19:16
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.

4 participants