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

Renames & eslint-disable react/require-default-props removal #5251

Merged
merged 2 commits into from
Jun 17, 2024

Conversation

lakesare
Copy link
Collaborator

@lakesare lakesare commented Jun 15, 2024

These are decorative changes that will make #5050 diff easier to look at.

@lakesare lakesare marked this pull request as ready for review June 15, 2024 00:10
Copy link
Contributor

Diff output files
diff --git a/packages/@uppy/provider-views/lib/Item/components/ItemIcon.js b/packages/@uppy/provider-views/lib/Item/components/ItemIcon.js
index f101814..aebdd51 100644
--- a/packages/@uppy/provider-views/lib/Item/components/ItemIcon.js
+++ b/packages/@uppy/provider-views/lib/Item/components/ItemIcon.js
@@ -53,10 +53,11 @@ function VideoIcon() {
     }),
   );
 }
-export default function ItemIcon(props) {
-  const {
+export default function ItemIcon(_ref) {
+  let {
     itemIconString,
-  } = props;
+    alt = undefined,
+  } = _ref;
   if (itemIconString === null) return null;
   switch (itemIconString) {
     case "file":
@@ -66,9 +67,6 @@ export default function ItemIcon(props) {
     case "video":
       return h(VideoIcon, null);
     default: {
-      const {
-        alt,
-      } = props;
       return h("img", {
         src: itemIconString,
         alt: alt,
diff --git a/packages/@uppy/provider-views/lib/Item/index.js b/packages/@uppy/provider-views/lib/Item/index.js
index 52ee30c..be3e2a7 100644
--- a/packages/@uppy/provider-views/lib/Item/index.js
+++ b/packages/@uppy/provider-views/lib/Item/index.js
@@ -10,9 +10,9 @@ function _extends() {
 }
 import classNames from "classnames";
 import { h } from "preact";
-import GridListItem from "./components/GridLi.js";
+import GridItem from "./components/GridItem.js";
 import ItemIcon from "./components/ItemIcon.js";
-import ListItem from "./components/ListLi.js";
+import ListItem from "./components/ListItem.js";
 export default function Item(props) {
   const {
     author,
@@ -35,7 +35,7 @@ export default function Item(props) {
   switch (viewType) {
     case "grid":
       return h(
-        GridListItem,
+        GridItem,
         _extends({}, props, {
           className: className,
           itemIconEl: itemIconEl,
@@ -51,7 +51,7 @@ export default function Item(props) {
       );
     case "unsplash":
       return h(
-        GridListItem,
+        GridItem,
         _extends({}, props, {
           className: className,
           itemIconEl: itemIconEl,
diff --git a/packages/@uppy/provider-views/lib/ProviderView/AuthView.js b/packages/@uppy/provider-views/lib/ProviderView/AuthView.js
index 3902d4f..8e23845 100644
--- a/packages/@uppy/provider-views/lib/ProviderView/AuthView.js
+++ b/packages/@uppy/provider-views/lib/ProviderView/AuthView.js
@@ -99,15 +99,15 @@ const defaultRenderForm = _ref2 => {
     onAuth: onAuth,
   });
 };
-export default function AuthView(props) {
-  const {
+export default function AuthView(_ref3) {
+  let {
     loading,
     pluginName,
     pluginIcon,
     i18n,
     handleAuth,
     renderForm = defaultRenderForm,
-  } = props;
+  } = _ref3;
   return h(
     "div",
     {

@lakesare lakesare requested a review from Murderlon June 15, 2024 00:20
@aduh95 aduh95 merged commit 2ba00ec into 4.x Jun 17, 2024
17 checks passed
@aduh95 aduh95 deleted the lakesare/decor branch June 17, 2024 08:03
Murderlon added a commit that referenced this pull request Jun 17, 2024
* 4.x:
  Renames & `eslint-disable react/require-default-props` removal (#5251)
  coalesce options `bucket` and `getKey` (#5169)
  @uppy/aws-s3: add `endpoint` option (#5173)
  @uppy/locales: fix `fa_IR` export (#5241)
  improve companion logging (#5250)
  Release: uppy@4.0.0-beta.11 (#5243)
  @uppy/core: add generic to `getPlugin` (#5247)
  docs: add 4.x migration guide (#5206)
  @uppy/transloadit: also fix outdated assembly transloadit:result (#5246)
  docs - fix typo in the url
  @uppy/core: set default for Body generic (#5244)
  Release: uppy@3.26.1 (#5242)
  docs: clarify assemblyOptions for @uppy/transloadit (#5226)
  meta: Improve aws-node example readme (#4753)
  @uppy/react: remove `react:` prefix from `id` & allow `id` as a prop (#5228)
  Added translation string (it_IT) (#5237)
  docs: correct allowedMetaFields (#5227)
  @uppy/transloadit: fix transloadit:result event (#5231)
  docs: remove `extraData` note from migration guide (#5219)
  @uppy/provider-views: fix wrong font for files (#5234)
github-actions bot added a commit that referenced this pull request Jun 19, 2024
| Package              |       Version | Package              |       Version |
| -------------------- | ------------- | -------------------- | ------------- |
| @uppy/aws-s3         |  4.0.0-beta.7 | @uppy/locales        |  4.0.0-beta.4 |
| @uppy/box            |  3.0.0-beta.7 | @uppy/onedrive       |  4.0.0-beta.7 |
| @uppy/companion      | 5.0.0-beta.10 | @uppy/provider-views |  4.0.0-beta.9 |
| @uppy/core           | 4.0.0-beta.10 | @uppy/react          |  4.0.0-beta.7 |
| @uppy/dashboard      | 4.0.0-beta.10 | @uppy/remote-sources |  2.0.0-beta.5 |
| @uppy/dropbox        |  4.0.0-beta.8 | @uppy/transloadit    |  4.0.0-beta.9 |
| @uppy/google-drive   |  3.6.0-beta.1 | uppy                 | 4.0.0-beta.12 |
| @uppy/google-photos  |  0.2.0-beta.1 |                      |               |

- meta: ignore `require-default-props` lint rule for function components (Antoine du Hamel / #5253)
- @uppy/provider-views: Renames & `eslint-disable react/require-default-props` removal (Evgenia Karunus / #5251)
- @uppy/companion: coalesce options `bucket` and `getKey` (Mikael Finstad / #5169)
- @uppy/aws-s3: add `endpoint` option (Antoine du Hamel / #5173)
- @uppy/locales: fix `fa_IR` export (Merlijn Vos / #5241)
- @uppy/companion: improve companion logging (Mikael Finstad / #5250)
- @uppy/transloadit: also fix outdated assembly transloadit:result (Merlijn Vos / #5246)
- docs: fix typo in the url (Evgenia Karunus)
- examples,@uppy/locales,@uppy/provider-views,@uppy/transloadit: Release: uppy@3.26.1 (github-actions[bot] / #5242)
- meta: Improve aws-node example readme (Artur Paikin / #4753)
- @uppy/locales: Added translation string (it_IT) (Samuel / #5237)
- @uppy/transloadit: fix transloadit:result event (Merlijn Vos / #5231)
- @uppy/provider-views: fix wrong font for files (Merlijn Vos / #5234)
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

Successfully merging this pull request may close these issues.

3 participants