Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: cozy/cozy-libs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: cozy-intent@1.17.1
Choose a base ref
...
head repository: cozy/cozy-libs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: cozy-intent@1.17.3
Choose a head ref

Commits on Apr 29, 2022

  1. fix: VaultClient can be undefined at first

    Since the 4.1.0 of cozy-keys-lib, we
    render children even if vaultClient is
    not defined yet. In that case we we were
    displaying TriggerManager without vaultClient.
    It was raising an error.
    The current fix, is to not display the
    TriggerManager when vaultClient is null.
    
    The result for the end user, was to get a blank
    form when configuring a konnector from the store
    Crash-- committed Apr 29, 2022
    Copy the full SHA
    8a6f02b View commit details
  2. fix: Check if we need to display the unlock form

    Since the cozy-libs-key v4, we need to manually check if we want
    to display the UnlockForm or not.
    
    So let's do it.
    Crash-- committed Apr 29, 2022
    Copy the full SHA
    fe230ce View commit details
  3. chore: Add missing proptypes

    Crash-- committed Apr 29, 2022
    Copy the full SHA
    e77588c View commit details
  4. refactor: Lint

    Crash-- committed Apr 29, 2022
    Copy the full SHA
    7c2c6ef View commit details
  5. fix: Upgrade cozy-keys-lib requirement

    BREAKING CHANGE: cozy-keys-lib >= 4.1.9 is now
    required.
    Crash-- committed Apr 29, 2022
    Copy the full SHA
    c4eb57f View commit details
  6. [skip ci] Publish

     - cozy-harvest-lib@9.0.0
     - cozy-mespapiers-lib@0.9.2
    Cozy Bot committed Apr 29, 2022
    Copy the full SHA
    4595551 View commit details
  7. fix: bump schema-utils from 2.7.0 to 4.0.0

    Bumps [schema-utils](https://github.com/webpack/schema-utils) from 2.7.0 to 4.0.0.
    - [Release notes](https://github.com/webpack/schema-utils/releases)
    - [Changelog](https://github.com/webpack/schema-utils/blob/master/CHANGELOG.md)
    - [Commits](webpack/schema-utils@v2.7.0...v4.0.0)
    
    ---
    updated-dependencies:
    - dependency-name: schema-utils
      dependency-type: direct:production
      update-type: version-update:semver-major
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    dependabot[bot] authored and trollepierre committed Apr 29, 2022
    Copy the full SHA
    bfedbe8 View commit details
  8. [skip ci] Publish

     - @cozy/repo-doctor@0.7.3
    Cozy Bot committed Apr 29, 2022
    Copy the full SHA
    2f42e39 View commit details

Commits on May 2, 2022

  1. feat: Open InAppBrowser via cozy-intent when in flaghip app

    This needs implementation of showInAppBrowser and closeInAppBrowser
    methods in flagship app
    doubleface authored and doubleface committed May 2, 2022
    Copy the full SHA
    5ee31ea View commit details
  2. fix: Multiple fixes after review

    doubleface authored and doubleface committed May 2, 2022
    Copy the full SHA
    0351500 View commit details
  3. [skip ci] Publish

     - cozy-harvest-lib@9.1.0
     - cozy-mespapiers-lib@0.9.3
    Cozy Bot committed May 2, 2022
    Copy the full SHA
    2e308c2 View commit details
  4. fix: bump form-data from 3.0.0 to 4.0.0

    Bumps [form-data](https://github.com/form-data/form-data) from 3.0.0 to 4.0.0.
    - [Release notes](https://github.com/form-data/form-data/releases)
    - [Commits](form-data/form-data@v3.0.0...v4.0.0)
    
    ---
    updated-dependencies:
    - dependency-name: form-data
      dependency-type: direct:development
      update-type: version-update:semver-major
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    dependabot[bot] authored and trollepierre committed May 2, 2022
    Copy the full SHA
    0a8546f View commit details
  5. [skip ci] Publish

     - cozy-harvest-lib@9.1.1
     - cozy-mespapiers-lib@0.9.4
    Cozy Bot committed May 2, 2022
    Copy the full SHA
    319a9e2 View commit details
  6. fix: bump @babel/plugin-proposal-object-rest-spread

    Bumps [@babel/plugin-proposal-object-rest-spread](https://github.com/babel/babel/tree/HEAD/packages/babel-plugin-proposal-object-rest-spread) from 7.16.0 to 7.17.3.
    - [Release notes](https://github.com/babel/babel/releases)
    - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
    - [Commits](https://github.com/babel/babel/commits/v7.17.3/packages/babel-plugin-proposal-object-rest-spread)
    
    ---
    updated-dependencies:
    - dependency-name: "@babel/plugin-proposal-object-rest-spread"
      dependency-type: direct:production
      update-type: version-update:semver-minor
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    dependabot[bot] authored and trollepierre committed May 2, 2022
    Copy the full SHA
    591799c View commit details
  7. fix: bump stylus from 0.54.7 to 0.57.0

    Bumps [stylus](https://github.com/stylus/stylus) from 0.54.7 to 0.57.0.
    - [Release notes](https://github.com/stylus/stylus/releases)
    - [Changelog](https://github.com/stylus/stylus/blob/dev/Changelog.md)
    - [Commits](stylus/stylus@0.54.7...0.57.0)
    
    ---
    updated-dependencies:
    - dependency-name: stylus
      dependency-type: direct:development
      update-type: version-update:semver-minor
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    dependabot[bot] authored and trollepierre committed May 2, 2022
    Copy the full SHA
    30ca46a View commit details

Commits on May 3, 2022

  1. Copy the full SHA
    b4368f6 View commit details
  2. [skip ci] Publish

     - @cozy/codemods@1.15.0
     - cozy-scanner@2.1.5
    Cozy Bot committed May 3, 2022
    Copy the full SHA
    d5c10dc View commit details
  3. Copy the full SHA
    b5d5334 View commit details
  4. feat: Use new Radios button

    Merkur39 committed May 3, 2022
    Copy the full SHA
    af5f545 View commit details
  5. Copy the full SHA
    a40e711 View commit details
  6. Copy the full SHA
    d73211b View commit details
  7. feat: Add multiple choice to Contact step

    On creation of paper,
    add the possibility to choose several contacts per paper
    Merkur39 committed May 3, 2022
    Copy the full SHA
    fd71460 View commit details
  8. fix: The buildFilename function needs all the contacts

    This function must manage several contacts
    Merkur39 committed May 3, 2022
    Copy the full SHA
    4dcd523 View commit details
  9. Copy the full SHA
    88419f0 View commit details
  10. Copy the full SHA
    63e5878 View commit details
  11. refactor: Some rename on PapersListWrapper to be more generic

    Refactor isLoading.. conditions
    Merkur39 committed May 3, 2022
    Copy the full SHA
    aaa6f82 View commit details
  12. Copy the full SHA
    2f075e0 View commit details
  13. feat: Add the ability to display multiple contacts per file

    Now that we can have multiple contacts per file,
    we need to display them correctly,
    without visually duplicating the files involved.
    
    The UI rules are as follows:
    - A section containing the names of the contacts is created in the list.
    - If there are more than 2 contacts,
    then "..." is added after the contact names.
    - If the names of the contacts are identical
    (and there are only 2 of them),
    then they are merged (e.g. `Isabelle and Paul Durand`).
    Merkur39 committed May 3, 2022
    Copy the full SHA
    fc1297e View commit details
  14. Copy the full SHA
    fd46e46 View commit details
  15. refactor: Rename buildPaperslistByContact to buildFilesByContacts

    Move buildFilesByContacts to Parpers/helpers.js
    Merkur39 committed May 3, 2022
    Copy the full SHA
    bb93be6 View commit details
  16. Copy the full SHA
    e99bc2e View commit details
  17. [skip ci] Publish

     - cozy-mespapiers-lib@0.10.0
    Cozy Bot committed May 3, 2022
    Copy the full SHA
    08f1b23 View commit details

Commits on May 4, 2022

  1. Copy the full SHA
    f7ed408 View commit details
  2. [skip ci] Publish

     - cozy-mespapiers-lib@0.11.0
    Cozy Bot committed May 4, 2022
    Copy the full SHA
    6fe7fc8 View commit details
  3. refactor: Remove required on placeholder prop in ActionMenuImportDropdow

    to remove error in console
    JF-Cozy committed May 4, 2022
    Copy the full SHA
    35385df View commit details
  4. refactor: Replace condition to remove error in console

    returns unsupported boolean in some cases
    JF-Cozy committed May 4, 2022
    Copy the full SHA
    9b8b208 View commit details
  5. Copy the full SHA
    dcb2a8d View commit details
  6. Copy the full SHA
    8895446 View commit details
  7. Copy the full SHA
    85903d8 View commit details
  8. refactor: Switch arg position in getPaperDefinitionByLabel

    since we use files as first entry to compute data
    JF-Cozy committed May 4, 2022
    Copy the full SHA
    16555eb View commit details
  9. Copy the full SHA
    754146d View commit details
  10. Copy the full SHA
    d7983d2 View commit details
  11. feat: Upgrade cozy-ui to 66.2.0

    need to upgrade cozy-device-helper to 2.0.0 in peerdep because
    of cozy-ui BC https://github.com/cozy/cozy-ui/releases/tag/v66.0.0
    JF-Cozy committed May 4, 2022
    Copy the full SHA
    7128646 View commit details
  12. Copy the full SHA
    fd839dc View commit details
  13. feat: Add hasItemByLabel helper

    will be moved in cozy-client after feature validation
    JF-Cozy committed May 4, 2022
    Copy the full SHA
    9b468e5 View commit details
  14. refactor: Replace arg in object on getFeaturedPlaceholders

    to be able to add arg easily
    JF-Cozy committed May 4, 2022
    Copy the full SHA
    0c56bc8 View commit details
  15. Copy the full SHA
    73c4ace View commit details
  16. Copy the full SHA
    c6294e7 View commit details
  17. Copy the full SHA
    d9253f6 View commit details
  18. [skip ci] Publish

     - cozy-mespapiers-lib@0.12.0
    Cozy Bot committed May 4, 2022
    Copy the full SHA
    44f8e75 View commit details
Showing with 3,621 additions and 1,217 deletions.
  1. +2 −2 package.json
  2. +24 −0 packages/cozy-authentication/CHANGELOG.md
  3. +3 −3 packages/cozy-authentication/package.json
  4. +22 −0 packages/cozy-codemods/CHANGELOG.md
  5. +2 −2 packages/cozy-codemods/package.json
  6. +15 −1 packages/cozy-codemods/src/imports.js
  7. +6 −0 packages/cozy-codemods/src/transforms/__testfixtures__/transform-iconButton.input.js
  8. +6 −0 packages/cozy-codemods/src/transforms/__testfixtures__/transform-iconButton.output.js
  9. +2 −0 packages/cozy-codemods/src/transforms/__tests__/transform-iconButton.spec.js
  10. +18 −0 packages/cozy-codemods/src/transforms/transform-iconButton.js
  11. +16 −0 packages/cozy-device-helper/CHANGELOG.md
  12. +1 −1 packages/cozy-device-helper/package.json
  13. +1 −3 packages/cozy-device-helper/src/flagship.ts
  14. +85 −0 packages/cozy-harvest-lib/CHANGELOG.md
  15. +9 −7 packages/cozy-harvest-lib/package.json
  16. +3 −1 packages/cozy-harvest-lib/src/components/AccountForm/index.jsx
  17. +33 −0 packages/cozy-harvest-lib/src/components/InAppBrowser.jsx
  18. +60 −0 packages/cozy-harvest-lib/src/components/InAppBrowser.spec.jsx
  19. +3 −2 packages/cozy-harvest-lib/src/components/KonnectorConfiguration/ConfigurationTab/index.jsx
  20. +6 −2 packages/cozy-harvest-lib/src/components/NewAccountModal.spec.jsx
  21. +7 −2 packages/cozy-harvest-lib/src/components/OAuthWindow.jsx
  22. +47 −10 packages/cozy-harvest-lib/src/components/TriggerManager.jsx
  23. +2 −2 packages/cozy-harvest-lib/src/helpers/oauth.js
  24. +6 −1 packages/cozy-harvest-lib/src/konnector-policies.js
  25. +1 −1 packages/cozy-harvest-lib/src/models/ConnectionFlow.js
  26. +12 −7 packages/cozy-harvest-lib/src/models/ConnectionFlow.spec.js
  27. +192 −0 packages/cozy-harvest-lib/src/services/biWebView.js
  28. +185 −0 packages/cozy-harvest-lib/src/services/biWebView.spec.js
  29. +4 −12 packages/cozy-harvest-lib/src/services/budget-insight.js
  30. +1 −1 packages/cozy-harvest-lib/src/services/budget-insight.spec.js
  31. +19 −0 packages/cozy-intent/CHANGELOG.md
  32. +2 −2 packages/cozy-intent/package.json
  33. +18 −0 packages/cozy-intent/src/api/models/environments.spec.ts
  34. +23 −3 packages/cozy-intent/src/api/models/environments.ts
  35. +52 −34 packages/cozy-intent/src/api/services/NativeService.spec.ts
  36. +6 −1 packages/cozy-intent/src/api/services/NativeService.ts
  37. +264 −0 packages/cozy-mespapiers-lib/CHANGELOG.md
  38. +1 −1 packages/cozy-mespapiers-lib/README.md
  39. +77 −0 packages/cozy-mespapiers-lib/docs/papersDefinitions.md
  40. +16 −16 packages/cozy-mespapiers-lib/package.json
  41. +1 −1 packages/cozy-mespapiers-lib/src/components/AppRouter.jsx
  42. +2 −2 packages/cozy-mespapiers-lib/src/components/CompositeHeader/CompositeHeader.jsx
  43. +1 −1 packages/cozy-mespapiers-lib/src/components/CompositeHeader/CompositeHeaderImage.jsx
  44. +13 −7 packages/cozy-mespapiers-lib/src/components/Contexts/StepperDialogProvider.jsx
  45. +64 −37 packages/cozy-mespapiers-lib/src/components/Home/Home.jsx
  46. +4 −4 packages/cozy-mespapiers-lib/src/components/Home/Home.spec.jsx
  47. +54 −0 packages/cozy-mespapiers-lib/src/components/Home/helpers.js
  48. +127 −0 packages/cozy-mespapiers-lib/src/components/Home/helpers.spec.js
  49. +1 −1 packages/cozy-mespapiers-lib/src/components/ImportDropdown/ImportDropdown.jsx
  50. +1 −1 packages/cozy-mespapiers-lib/src/components/ModelSteps/AcquisitionResult.jsx
  51. +51 −201 packages/cozy-mespapiers-lib/src/components/ModelSteps/Contact.jsx
  52. +0 −50 packages/cozy-mespapiers-lib/src/components/ModelSteps/Contact.spec.jsx
  53. +110 −0 packages/cozy-mespapiers-lib/src/components/ModelSteps/ContactList.jsx
  54. +127 −0 packages/cozy-mespapiers-lib/src/components/ModelSteps/ContactWrapper.jsx
  55. +114 −0 packages/cozy-mespapiers-lib/src/components/ModelSteps/ContactWrapper.spec.jsx
  56. +5 −2 packages/cozy-mespapiers-lib/src/components/ModelSteps/widgets/InputDateAdapter.jsx
  57. +103 −42 packages/cozy-mespapiers-lib/src/components/ModelSteps/widgets/InputTextAdapter.jsx
  58. +144 −40 packages/cozy-mespapiers-lib/src/components/ModelSteps/widgets/InputTextAdapter.spec.jsx
  59. +48 −37 packages/cozy-mespapiers-lib/src/components/Papers/PaperGroup.jsx
  60. +2 −6 packages/cozy-mespapiers-lib/src/components/Papers/PaperLine.jsx
  61. +2 −2 packages/cozy-mespapiers-lib/src/components/Papers/PapersListByContact.jsx
  62. +53 −62 packages/cozy-mespapiers-lib/src/components/Papers/PapersListWrapper.jsx
  63. +118 −0 packages/cozy-mespapiers-lib/src/components/Papers/helpers.js
  64. +250 −0 packages/cozy-mespapiers-lib/src/components/Papers/helpers.spec.js
  65. +1 −1 packages/cozy-mespapiers-lib/src/components/PapersFab/PapersFab.jsx
  66. +1 −1 packages/cozy-mespapiers-lib/src/components/Placeholders/ActionMenuImportDropdown.jsx
  67. +3 −3 packages/cozy-mespapiers-lib/src/components/Placeholders/FeaturedPlaceholdersList.jsx
  68. +2 −2 packages/cozy-mespapiers-lib/src/components/Placeholders/PlaceholdersList.jsx
  69. +57 −0 packages/cozy-mespapiers-lib/src/components/SearchInput/SearchInput.jsx
  70. +3 −0 packages/cozy-mespapiers-lib/src/components/SearchInput/index.js
  71. +1 −1 packages/cozy-mespapiers-lib/src/components/StepperDialog/StepperDialog.jsx
  72. +2 −2 packages/cozy-mespapiers-lib/src/components/StepperDialog/StepperDialogContent.jsx
  73. +6 −4 packages/cozy-mespapiers-lib/src/components/StepperDialog/StepperDialogContent.spec.jsx
  74. +58 −0 packages/cozy-mespapiers-lib/src/components/ThemesFilter/ThemesFilter.jsx
  75. +3 −0 packages/cozy-mespapiers-lib/src/components/ThemesFilter/index.js
  76. +2 −0 packages/cozy-mespapiers-lib/src/constants/const.js
  77. +26 −2 packages/cozy-mespapiers-lib/src/constants/papersDefinitions.json
  78. +34 −21 packages/cozy-mespapiers-lib/src/helpers/buildFilename.js
  79. +24 −11 packages/cozy-mespapiers-lib/src/helpers/buildFilename.spec.js
  80. +0 −68 packages/cozy-mespapiers-lib/src/helpers/buildPaperslistByContact.js
  81. +0 −91 packages/cozy-mespapiers-lib/src/helpers/buildPaperslistByContact.spec.js
  82. +3 −3 packages/cozy-mespapiers-lib/src/helpers/createPdfAndSave.js
  83. +30 −0 packages/cozy-mespapiers-lib/src/helpers/filterWithRemaining.js
  84. +51 −0 packages/cozy-mespapiers-lib/src/helpers/filterWithRemaining.spec.js
  85. +34 −9 packages/cozy-mespapiers-lib/src/helpers/findPlaceholders.js
  86. +95 −8 packages/cozy-mespapiers-lib/src/helpers/findPlaceholders.spec.js
  87. +23 −23 packages/cozy-mespapiers-lib/src/helpers/queries.js
  88. +11 −4 packages/cozy-mespapiers-lib/src/locales/en.json
  89. +11 −4 packages/cozy-mespapiers-lib/src/locales/fr.json
  90. +5 −6 packages/cozy-mespapiers-lib/src/utils/input.js
  91. +12 −9 packages/cozy-mespapiers-lib/test/components/AppLike.jsx
  92. +11 −0 packages/cozy-realtime/CHANGELOG.md
  93. +2 −2 packages/cozy-realtime/package.json
  94. +35 −0 packages/cozy-scanner/CHANGELOG.md
  95. +4 −4 packages/cozy-scanner/package.json
  96. +24 −0 packages/cozy-sharing/CHANGELOG.md
  97. +3 −3 packages/cozy-sharing/package.json
  98. +19 −0 packages/playgrounds/CHANGELOG.md
  99. +5 −5 packages/playgrounds/package.json
  100. +11 −0 packages/repo-doctor/CHANGELOG.md
  101. +2 −2 packages/repo-doctor/package.json
  102. +360 −315 yarn.lock
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -18,7 +18,7 @@
"lint": "eslint --ext js,jsx,ts,tsx .",
"lint:md": "remark . -o",
"test": "lerna run --concurrency 1 test",
"build": "lerna run --parallel build",
"build": "lerna run --scope cozy-device-helper build && lerna run --parallel --ignore cozy-device-helper build",
"watch:doc:react": "styleguidist server --config docs/styleguidist.config.js",
"check-constraints": "node scripts/check-packages-constraints.js"
},
@@ -35,7 +35,7 @@
"mini-css-extract-plugin": "0.5.0",
"react-styleguidist": "9.1.16",
"remark-cli": "9.0.0",
"stylus": "0.54.7",
"stylus": "0.57.0",
"stylus-loader": "3.0.2",
"webpack": "4.41.2"
},
24 changes: 24 additions & 0 deletions packages/cozy-authentication/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -3,6 +3,30 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## [2.9.1](https://github.com/cozy/cozy-libs/compare/cozy-authentication@2.9.0...cozy-authentication@2.9.1) (2022-05-10)

**Note:** Version bump only for package cozy-authentication





# 2.9.0 (2022-05-09)


### Bug Fixes

* bump react-dom from 16.12.0 to 16.13.0 ([2a5b850](https://github.com/cozy/cozy-libs/commit/2a5b8509555f061b136a4b5f2e38b36eb75ea0be))


### Features

* Add papers filter on Home ([fd839dc](https://github.com/cozy/cozy-libs/commit/fd839dc6d2538799d8dafc1905d423410c251df6))





## [2.8.5](https://github.com/cozy/cozy-libs/compare/cozy-authentication@2.8.4...cozy-authentication@2.8.5) (2022-04-28)

**Note:** Version bump only for package cozy-authentication
6 changes: 3 additions & 3 deletions packages/cozy-authentication/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cozy-authentication",
"version": "2.8.5",
"version": "2.9.1",
"description": "Component providing login to a Cozy",
"main": "dist/index.js",
"files": [
@@ -34,11 +34,11 @@
"parcel": "1.12.3",
"postcss-merge-rules": "4.0.3",
"react": "16.12.0",
"react-dom": "16.12.0",
"react-dom": "16.13.0",
"react-router": "6.3.0"
},
"dependencies": {
"cozy-device-helper": "^2.0.0",
"cozy-device-helper": "^2.1.0",
"localforage": "1.7.3",
"prop-types": "15.7.2",
"snarkdown": "1.2.2",
22 changes: 22 additions & 0 deletions packages/cozy-codemods/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -3,6 +3,28 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## [1.15.1](https://github.com/cozy/cozy-libs/compare/@cozy/codemods@1.15.0...@cozy/codemods@1.15.1) (2022-05-04)


### Bug Fixes

* **deps:** Eslint-config-cozy-app not needed as dependencies of codemods ([99dd607](https://github.com/cozy/cozy-libs/commit/99dd607341fb49d6010ae4956107abe75dcc47cd))





# 1.15.0 (2022-05-03)


### Features

* Add codemods for iconButton ([b4368f6](https://github.com/cozy/cozy-libs/commit/b4368f6101374f339177b8e375f99ad382ae7cb3))





## [1.14.5](https://github.com/cozy/cozy-libs/compare/@cozy/codemods@1.14.4...@cozy/codemods@1.14.5) (2022-04-22)

**Note:** Version bump only for package @cozy/codemods
4 changes: 2 additions & 2 deletions packages/cozy-codemods/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cozy/codemods",
"version": "1.14.5",
"version": "1.15.1",
"description": "Codeshifts used inside Cozies",
"main": "index.js",
"repository": "https://github.com/cozy/cozy-libs",
@@ -17,10 +17,10 @@
},
"dependencies": {
"@cozy/cli-tree": "^0.5.0",
"eslint-config-cozy-app": "^4.0.2",
"jscodeshift": "^0.11.0"
},
"devDependencies": {
"eslint-config-cozy-app": "^4.0.2",
"jest": "26.6.3",
"jsdoc-to-markdown": "5.0.3"
}
16 changes: 15 additions & 1 deletion packages/cozy-codemods/src/imports.js
Original file line number Diff line number Diff line change
@@ -269,8 +269,22 @@ const simplify = (root, options) => {
mergeImports(root)
}

const getAttributeName = attribute => attribute?.name?.name

const getAttributeValue = attribute => attribute?.value?.expression?.value

const getAttributeByName = ({ attributes, name }) =>
attributes.find(attribute => getAttributeName(attribute) === name)

const makeAttribute = ({ name, value }) =>
j.jsxAttribute(j.jsxIdentifier(name), j.literal(value))

module.exports = {
simplify,
ensure,
removeUnused
removeUnused,
getAttributeName,
getAttributeValue,
getAttributeByName,
makeAttribute
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import React from 'react'
import IconButton from 'cozy-ui/transpiled/react/IconButton'

export const Comp = () => {
return <IconButton color="primary" disabled={false} />
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import React from 'react'
import IconButton from 'cozy-ui/transpiled/react/IconButton'

export const Comp = () => {
return <IconButton color="primary" disabled={false} size="medium" />;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
const defineTest = require('jscodeshift/dist/testUtils').defineTest
defineTest(__dirname, 'transform-iconButton')
18 changes: 18 additions & 0 deletions packages/cozy-codemods/src/transforms/transform-iconButton.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import { getAttributeByName, makeAttribute } from '../imports'

export default function transformIconButton(file, api) {
var j = api.jscodeshift
const root = j(file.source)

root.findJSXElements('IconButton').forEach(nodePath => {
const { attributes } = nodePath.node.openingElement

const sizeAttribute = getAttributeByName({ attributes, name: 'size' })

if (!sizeAttribute) {
attributes.push(makeAttribute({ name: 'size', value: 'medium' }))
}
})

return root.toSource()
}
16 changes: 16 additions & 0 deletions packages/cozy-device-helper/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -3,6 +3,22 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

# 2.1.0 (2022-05-10)


### Bug Fixes

* **cozy-device-helper:** Remove type import ([401d654](https://github.com/cozy/cozy-libs/commit/401d654ca7ddb1553ec6039ddb5b4f7708ef5869))


### Features

* Add `name` in attributes selected for buildFilesQueryByLabels ([d66c975](https://github.com/cozy/cozy-libs/commit/d66c975670761343032c72af23590c691a0b89c1))





# [2.0.0](https://github.com/cozy/cozy-libs/compare/cozy-device-helper@1.18.0...cozy-device-helper@2.0.0) (2022-04-28)


2 changes: 1 addition & 1 deletion packages/cozy-device-helper/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "cozy-device-helper",
"description": "To know more information about the device platform",
"version": "2.0.0",
"version": "2.1.0",
"author": "Cozy",
"bugs": {
"url": "https://github.com/cozy/cozy-libs/issues"
4 changes: 1 addition & 3 deletions packages/cozy-device-helper/src/flagship.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { Platform } from 'react-native'

export enum FlagshipRoutes {
Home = 'home',
Cozyapp = 'cozyapp',
@@ -11,7 +9,7 @@ export enum FlagshipRoutes {
export interface FlagshipMetadata {
immersive?: boolean
navbarHeight?: number
platform?: typeof Platform
platform?: Record<string, unknown>
route?: FlagshipRoutes
statusBarHeight?: number
version?: string
85 changes: 85 additions & 0 deletions packages/cozy-harvest-lib/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -3,6 +3,91 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## [9.2.2](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.2.1...cozy-harvest-lib@9.2.2) (2022-05-10)

**Note:** Version bump only for package cozy-harvest-lib





## [9.2.1](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.2.0...cozy-harvest-lib@9.2.1) (2022-05-09)


### Bug Fixes

* bump react-dom from 16.12.0 to 16.13.0 ([2a5b850](https://github.com/cozy/cozy-libs/commit/2a5b8509555f061b136a4b5f2e38b36eb75ea0be))





# [9.2.0](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.1.2...cozy-harvest-lib@9.2.0) (2022-05-09)


### Features

* Add BI connection creation via BI webview ([35ea078](https://github.com/cozy/cozy-libs/commit/35ea07805b5604d7882051bc0f7b43b38516922f))
* Unit tests + comments ([93e960e](https://github.com/cozy/cozy-libs/commit/93e960ee3236df742b8665d4d79cf6cf675d4f8f))





## 9.1.2 (2022-05-05)

**Note:** Version bump only for package cozy-harvest-lib





## [9.1.1](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.1.0...cozy-harvest-lib@9.1.1) (2022-05-02)


### Bug Fixes

* bump form-data from 3.0.0 to 4.0.0 ([0a8546f](https://github.com/cozy/cozy-libs/commit/0a8546f2712a8164ff2bd08dfb60230bf97e1b85))





# [9.1.0](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.0.0...cozy-harvest-lib@9.1.0) (2022-05-02)


### Bug Fixes

* Multiple fixes after review ([0351500](https://github.com/cozy/cozy-libs/commit/0351500e1845df6ef4a31211aec6061090ccf66e))


### Features

* Open InAppBrowser via cozy-intent when in flaghip app ([5ee31ea](https://github.com/cozy/cozy-libs/commit/5ee31eafcb62e23a6242386bb6b09312f778e871))





# [9.0.0](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@8.4.3...cozy-harvest-lib@9.0.0) (2022-04-29)


### Bug Fixes

* Check if we need to display the unlock form ([fe230ce](https://github.com/cozy/cozy-libs/commit/fe230ce0791c511c31098be47e633408bceb9c30))
* Upgrade cozy-keys-lib requirement ([c4eb57f](https://github.com/cozy/cozy-libs/commit/c4eb57f22b4a86d42c4422619a158605d894edcf))
* VaultClient can be undefined at first ([8a6f02b](https://github.com/cozy/cozy-libs/commit/8a6f02b9e9c161622afedff88ba4805468ee6f59))


### BREAKING CHANGES

* cozy-keys-lib >= 4.1.9 is now
required.





## [8.4.3](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@8.4.2...cozy-harvest-lib@8.4.3) (2022-04-28)

**Note:** Version bump only for package cozy-harvest-lib
16 changes: 9 additions & 7 deletions packages/cozy-harvest-lib/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cozy-harvest-lib",
"version": "8.4.3",
"version": "9.2.2",
"description": "Provides logic, modules and components for Cozy's harvest applications.",
"main": "dist/index.js",
"author": "Cozy",
@@ -53,14 +53,15 @@
"babel-plugin-inline-react-svg": "1.1.2",
"babel-preset-cozy-app": "^2.0.2",
"cozy-client": "27.17.0",
"cozy-device-helper": "^2.0.0",
"cozy-device-helper": "^2.1.0",
"cozy-flags": "^2.8.7",
"cozy-keys-lib": "3.8.0",
"cozy-realtime": "^4.0.8",
"cozy-intent": "^1.17.3",
"cozy-keys-lib": "^4.1.9",
"cozy-realtime": "^4.1.0",
"cozy-ui": "60.6.0",
"enzyme": "3.11.0",
"enzyme-adapter-react-16": "1.15.6",
"form-data": "3.0.0",
"form-data": "4.0.0",
"identity-obj-proxy": "3.0.0",
"jest": "26.6.3",
"jest-environment-jsdom-sixteen": "1.0.3",
@@ -69,7 +70,7 @@
"leaflet": "1.7.1",
"prop-types": "15.7.2",
"react": "16.12.0",
"react-dom": "16.12.0",
"react-dom": "16.13.0",
"react-swipeable-views": "0.13.9"
},
"peerDependencies": {
@@ -78,7 +79,8 @@
"cozy-client": ">=27.17.0",
"cozy-device-helper": ">=1.10.2",
"cozy-flags": ">=2.3.5",
"cozy-keys-lib": ">=3.7.0",
"cozy-intent": ">=1.14.1",
"cozy-keys-lib": ">=4.1.9",
"cozy-realtime": ">=3.12.2",
"cozy-ui": ">=60.6.0",
"leaflet": "^1.7.1",
Original file line number Diff line number Diff line change
@@ -132,7 +132,9 @@ export class AccountForm extends PureComponent {
handleSubmit(values, form) {
const { account, konnector } = this.props

const identifier = manifest.getIdentifier(manifest.sanitizeFields(konnector.fields))
const identifier = manifest.getIdentifier(
manifest.sanitizeFields(konnector.fields)
)
if (
account &&
account.auth[identifier] &&
Loading