cozy-harvest-lib 9.26.4 → 9.26.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,34 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [9.26.7](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.26.6...cozy-harvest-lib@9.26.7) (2022-09-06)
7
+
8
+ **Note:** Version bump only for package cozy-harvest-lib
9
+
10
+
11
+
12
+
13
+
14
+ ## [9.26.6](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.26.5...cozy-harvest-lib@9.26.6) (2022-08-31)
15
+
16
+
17
+ ### Bug Fixes
18
+
19
+ * Add realtime on bank accounts ([3a03448](https://github.com/cozy/cozy-libs/commit/3a03448e0a371377023f9ec1c856dbdb53fd3e68))
20
+ * Better msg on ACCOUNT_WITH_SAME_IDENTIFIER_ALREADY_DEFINED error ([afc1f1c](https://github.com/cozy/cozy-libs/commit/afc1f1c84cb7a8c16a0d84942c6a6bbd68bd50ba))
21
+
22
+
23
+
24
+
25
+
26
+ ## [9.26.5](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.26.4...cozy-harvest-lib@9.26.5) (2022-08-29)
27
+
28
+ **Note:** Version bump only for package cozy-harvest-lib
29
+
30
+
31
+
32
+
33
+
6
34
  ## [9.26.4](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@9.26.3...cozy-harvest-lib@9.26.4) (2022-08-29)
7
35
 
8
36
  **Note:** Version bump only for package cozy-harvest-lib
@@ -6,6 +6,13 @@ import bankAccounts from './KonnectorConfiguration/ConfigurationTab/bank-account
6
6
  describe('DisconnectedAccountModal', function () {
7
7
  var setup = function setup() {
8
8
  var mockClient = {};
9
+ mockClient.plugins = {
10
+ realtime: {
11
+ subscribe: jest.fn(),
12
+ unsubscribe: jest.fn()
13
+ }
14
+ };
15
+ mockClient.dispatch = jest.fn();
9
16
  var root = render( /*#__PURE__*/React.createElement(AppLike, {
10
17
  client: mockClient
11
18
  }, /*#__PURE__*/React.createElement(DisconnectedAccountModal, {
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import compose from 'lodash/flowRight';
4
- import CozyClient, { Q, queryConnect } from 'cozy-client';
4
+ import CozyClient, { Q, queryConnect, RealTimeQueries } from 'cozy-client';
5
5
  import MuiCozyTheme from 'cozy-ui/transpiled/react/MuiCozyTheme';
6
6
  import { useI18n } from 'cozy-ui/transpiled/react/I18n';
7
7
  import NavigationList, { NavigationListSection, NavigationListHeader } from 'cozy-ui/transpiled/react/NavigationList';
@@ -42,7 +42,9 @@ var DumbContracts = function DumbContracts(_ref2) {
42
42
  if (contractData.length === 0) return null;
43
43
  var doctype = contractData[0] ? contractData[0]._type : null;
44
44
  var headerKey = customHeaderPerDoctype[doctype] || 'default';
45
- return /*#__PURE__*/React.createElement(MuiCozyTheme, null, /*#__PURE__*/React.createElement(NavigationList, null, /*#__PURE__*/React.createElement(NavigationListHeader, null, t("contracts.headers.".concat(headerKey))), /*#__PURE__*/React.createElement(NavigationListSection, null, contractData && contractData.map(function (contract, i) {
45
+ return /*#__PURE__*/React.createElement(MuiCozyTheme, null, /*#__PURE__*/React.createElement(RealTimeQueries, {
46
+ doctype: "io.cozy.bank.accounts"
47
+ }), /*#__PURE__*/React.createElement(NavigationList, null, /*#__PURE__*/React.createElement(NavigationListHeader, null, t("contracts.headers.".concat(headerKey))), /*#__PURE__*/React.createElement(NavigationListSection, null, contractData && contractData.map(function (contract, i) {
46
48
  return /*#__PURE__*/React.createElement(ContractItem, {
47
49
  key: contract._id,
48
50
  konnector: konnector,
@@ -217,7 +217,7 @@
217
217
  },
218
218
  "ACCOUNT_WITH_SAME_IDENTIFIER_ALREADY_DEFINED": {
219
219
  "title": "This account already exists",
220
- "description": "You already have configured an account with these identifiers."
220
+ "description": "Your possible modification of the list of synchronized accounts will be taken into account within a few minutes."
221
221
  }
222
222
  }
223
223
  },
@@ -541,4 +541,4 @@
541
541
  "caption": "This service retrieves your latest documents and keeps a complete back-up for you."
542
542
  }
543
543
  }
544
- }
544
+ }
@@ -217,7 +217,7 @@
217
217
  },
218
218
  "ACCOUNT_WITH_SAME_IDENTIFIER_ALREADY_DEFINED": {
219
219
  "title": "Ce compte est déjà configuré",
220
- "description": "Vous avez déjà configuré un compte avec ces identifiants."
220
+ "description": "Votre éventuelle modification de la liste des comptes synchronisés sera prise en compte sous quelques minutes."
221
221
  }
222
222
  }
223
223
  },
@@ -541,4 +541,4 @@
541
541
  "caption": "Ce service récupère vos derniers documents et garde une sauvegarde complète pour vous."
542
542
  }
543
543
  }
544
- }
544
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cozy-harvest-lib",
3
- "version": "9.26.4",
3
+ "version": "9.26.7",
4
4
  "description": "Provides logic, modules and components for Cozy's harvest applications.",
5
5
  "main": "dist/index.js",
6
6
  "author": "Cozy",
@@ -29,8 +29,8 @@
29
29
  "@cozy/minilog": "^1.0.0",
30
30
  "@sentry/browser": "^6.0.1",
31
31
  "cozy-bi-auth": "0.0.25",
32
- "cozy-doctypes": "^1.85.2",
33
- "cozy-logger": "^1.9.0",
32
+ "cozy-doctypes": "^1.85.3",
33
+ "cozy-logger": "^1.9.1",
34
34
  "date-fns": "^1.30.1",
35
35
  "final-form": "^4.18.5",
36
36
  "lodash": "^4.17.19",
@@ -53,11 +53,11 @@
53
53
  "babel-plugin-inline-react-svg": "1.1.2",
54
54
  "babel-preset-cozy-app": "^2.0.3",
55
55
  "cozy-client": "27.17.0",
56
- "cozy-device-helper": "^2.2.2",
56
+ "cozy-device-helper": "^2.3.0",
57
57
  "cozy-flags": "^2.10.1",
58
- "cozy-intent": "^2.3.1",
58
+ "cozy-intent": "^2.3.2",
59
59
  "cozy-keys-lib": "^4.1.9",
60
- "cozy-realtime": "^4.2.3",
60
+ "cozy-realtime": "^4.2.4",
61
61
  "cozy-ui": "60.6.0",
62
62
  "enzyme": "3.11.0",
63
63
  "enzyme-adapter-react-16": "1.15.6",
@@ -90,5 +90,5 @@
90
90
  "react-router-dom": "^5.0.1"
91
91
  },
92
92
  "sideEffects": false,
93
- "gitHead": "22a0d5c93fe14bcf1f424838f9a63bf8baf4e7e0"
93
+ "gitHead": "0cca4e2d694e0238d7317c3c3558d2ef5d16f52c"
94
94
  }
@@ -8,6 +8,13 @@ import bankAccounts from './KonnectorConfiguration/ConfigurationTab/bank-account
8
8
  describe('DisconnectedAccountModal', () => {
9
9
  const setup = () => {
10
10
  const mockClient = {}
11
+ mockClient.plugins = {
12
+ realtime: {
13
+ subscribe: jest.fn(),
14
+ unsubscribe: jest.fn()
15
+ }
16
+ }
17
+ mockClient.dispatch = jest.fn()
11
18
  const root = render(
12
19
  <AppLike client={mockClient}>
13
20
  <DisconnectedAccountModal
@@ -2,7 +2,7 @@ import React from 'react'
2
2
  import PropTypes from 'prop-types'
3
3
  import compose from 'lodash/flowRight'
4
4
 
5
- import CozyClient, { Q, queryConnect } from 'cozy-client'
5
+ import CozyClient, { Q, queryConnect, RealTimeQueries } from 'cozy-client'
6
6
  import MuiCozyTheme from 'cozy-ui/transpiled/react/MuiCozyTheme'
7
7
  import { useI18n } from 'cozy-ui/transpiled/react/I18n'
8
8
  import NavigationList, {
@@ -52,6 +52,7 @@ const DumbContracts = ({
52
52
 
53
53
  return (
54
54
  <MuiCozyTheme>
55
+ <RealTimeQueries doctype="io.cozy.bank.accounts" />
55
56
  <NavigationList>
56
57
  <NavigationListHeader>
57
58
  {t(`contracts.headers.${headerKey}`)}
@@ -217,7 +217,7 @@
217
217
  },
218
218
  "ACCOUNT_WITH_SAME_IDENTIFIER_ALREADY_DEFINED": {
219
219
  "title": "This account already exists",
220
- "description": "You already have configured an account with these identifiers."
220
+ "description": "Your possible modification of the list of synchronized accounts will be taken into account within a few minutes."
221
221
  }
222
222
  }
223
223
  },
@@ -541,4 +541,4 @@
541
541
  "caption": "This service retrieves your latest documents and keeps a complete back-up for you."
542
542
  }
543
543
  }
544
- }
544
+ }
@@ -217,7 +217,7 @@
217
217
  },
218
218
  "ACCOUNT_WITH_SAME_IDENTIFIER_ALREADY_DEFINED": {
219
219
  "title": "Ce compte est déjà configuré",
220
- "description": "Vous avez déjà configuré un compte avec ces identifiants."
220
+ "description": "Votre éventuelle modification de la liste des comptes synchronisés sera prise en compte sous quelques minutes."
221
221
  }
222
222
  }
223
223
  },
@@ -541,4 +541,4 @@
541
541
  "caption": "Ce service récupère vos derniers documents et garde une sauvegarde complète pour vous."
542
542
  }
543
543
  }
544
- }
544
+ }