cozy-harvest-lib 37.0.25 → 37.0.26
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 +4 -0
- package/package.json +3 -3
- package/dist/components/AccountField.spec.js +0 -141
- package/dist/components/AccountFields.spec.js +0 -39
- package/dist/components/AccountForm/__snapshots__/index.spec.jsx.snap +0 -203
- package/dist/components/AccountsList/__snapshots__/AccountsList.spec.js.snap +0 -87
- package/dist/components/AccountsList/__snapshots__/AccountsListItem.spec.jsx.snap +0 -63
- package/dist/components/FlowProvider.spec.js +0 -141
- package/dist/components/KonnectorConfiguration/DataTab.spec.js +0 -137
- package/dist/components/KonnectorConfiguration/KonnectorAccountTabs.js +0 -208
- package/dist/components/KonnectorConfiguration/KonnectorAccountTabs.spec.js +0 -335
- package/dist/components/Maintenance/__snapshots__/index.spec.jsx.snap +0 -3
- package/dist/components/MountPointContext.js +0 -81
- package/dist/components/Routes/RoutesV4.js +0 -83
- package/dist/components/Routes/RoutesV6.js +0 -92
- package/dist/components/Routes.js +0 -134
- package/dist/components/__snapshots__/AccountField.spec.js.snap +0 -365
- package/dist/components/__snapshots__/AccountFields.spec.js.snap +0 -39
- package/dist/components/__snapshots__/AccountModal.spec.jsx.snap +0 -174
- package/dist/components/__snapshots__/KonnectorAccounts.spec.jsx.snap +0 -20
- package/dist/components/__snapshots__/KonnectorSuccess.spec.js.snap +0 -26
- package/dist/components/__snapshots__/Popup.spec.js.snap +0 -3
- package/dist/components/cards/LaunchTriggerCard.spec.js +0 -152
- package/dist/components/cards/__snapshots__/LaunchTriggerCard.spec.jsx.snap +0 -5
- package/dist/components/hoc/withRouter.js +0 -75
- package/dist/components/hoc/withRouter.spec.js +0 -85
- package/dist/sentry.js +0 -20
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,10 @@
|
|
|
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
|
+
## [37.0.26](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@37.0.25...cozy-harvest-lib@37.0.26) (2026-05-26)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package cozy-harvest-lib
|
|
9
|
+
|
|
6
10
|
## [37.0.25](https://github.com/cozy/cozy-libs/compare/cozy-harvest-lib@37.0.24...cozy-harvest-lib@37.0.25) (2026-05-22)
|
|
7
11
|
|
|
8
12
|
**Note:** Version bump only for package cozy-harvest-lib
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cozy-harvest-lib",
|
|
3
|
-
"version": "37.0.
|
|
3
|
+
"version": "37.0.26",
|
|
4
4
|
"description": "Provides logic, modules and components for Cozy's harvest applications.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"author": "Cozy",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
"cozy-tsconfig": "^2.0.0",
|
|
76
76
|
"cozy-ui": "^138.1.0",
|
|
77
77
|
"cozy-ui-plus": "^8.0.1",
|
|
78
|
-
"cozy-viewer": "^28.0.
|
|
78
|
+
"cozy-viewer": "^28.0.27",
|
|
79
79
|
"form-data": "4.0.0",
|
|
80
80
|
"identity-obj-proxy": "3.0.0",
|
|
81
81
|
"isomorphic-fetch": "^2.2.1",
|
|
@@ -112,5 +112,5 @@
|
|
|
112
112
|
"twake-i18n": ">=0.3.0"
|
|
113
113
|
},
|
|
114
114
|
"sideEffects": false,
|
|
115
|
-
"gitHead": "
|
|
115
|
+
"gitHead": "5fd20886ef0dfec91783b81bce0ae59d210a0cfa"
|
|
116
116
|
}
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
5
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
6
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
7
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
8
|
-
|
|
9
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
10
|
-
|
|
11
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
12
|
-
|
|
13
|
-
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
14
|
-
|
|
15
|
-
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
16
|
-
|
|
17
|
-
import { AccountField } from 'components/AccountForm/AccountField';
|
|
18
|
-
import { shallow } from 'enzyme';
|
|
19
|
-
import PropTypes from 'prop-types';
|
|
20
|
-
import React from 'react';
|
|
21
|
-
var fixtures = {
|
|
22
|
-
username: {
|
|
23
|
-
encrypted: false,
|
|
24
|
-
required: true,
|
|
25
|
-
type: 'text'
|
|
26
|
-
},
|
|
27
|
-
passphrase: {
|
|
28
|
-
encrypted: true,
|
|
29
|
-
required: true,
|
|
30
|
-
type: 'password'
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
var t = jest.fn();
|
|
34
|
-
describe('AccountField', function () {
|
|
35
|
-
beforeEach(function () {
|
|
36
|
-
t.mockClear();
|
|
37
|
-
t.mockImplementation(function (key) {
|
|
38
|
-
return key;
|
|
39
|
-
});
|
|
40
|
-
});
|
|
41
|
-
it('should render', function () {
|
|
42
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, _extends({}, fixtures.username, {
|
|
43
|
-
name: "username",
|
|
44
|
-
t: t
|
|
45
|
-
})));
|
|
46
|
-
var component = wrapper.dive().getElement();
|
|
47
|
-
expect(component).toMatchSnapshot();
|
|
48
|
-
});
|
|
49
|
-
it('render a date field', function () {
|
|
50
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, {
|
|
51
|
-
required: true,
|
|
52
|
-
type: "date",
|
|
53
|
-
name: "date",
|
|
54
|
-
t: t
|
|
55
|
-
}));
|
|
56
|
-
var component = wrapper.dive().getElement();
|
|
57
|
-
expect(component).toMatchSnapshot();
|
|
58
|
-
});
|
|
59
|
-
it('render a password field', function () {
|
|
60
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, _extends({}, fixtures.passphrase, {
|
|
61
|
-
name: "passphrase",
|
|
62
|
-
t: t
|
|
63
|
-
})));
|
|
64
|
-
var component = wrapper.dive().getElement();
|
|
65
|
-
expect(component).toMatchSnapshot();
|
|
66
|
-
});
|
|
67
|
-
it('hide the password toggle on empty fields', function () {
|
|
68
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, _extends({}, fixtures.passphrase, {
|
|
69
|
-
name: "passphrase",
|
|
70
|
-
t: t,
|
|
71
|
-
value: ""
|
|
72
|
-
})));
|
|
73
|
-
var component = wrapper.dive().dive();
|
|
74
|
-
expect(component.prop('side')).toBe(null);
|
|
75
|
-
});
|
|
76
|
-
it('show the password toggle on non-empty fields', function () {
|
|
77
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, _extends({}, fixtures.passphrase, {
|
|
78
|
-
name: "passphrase",
|
|
79
|
-
value: "123",
|
|
80
|
-
t: t
|
|
81
|
-
})));
|
|
82
|
-
var component = wrapper.dive().dive();
|
|
83
|
-
expect(component.prop('side')).not.toBe(null);
|
|
84
|
-
});
|
|
85
|
-
it('render a dropdown field', function () {
|
|
86
|
-
var options = [{
|
|
87
|
-
label: 'Option 1',
|
|
88
|
-
value: 'option1'
|
|
89
|
-
}, {
|
|
90
|
-
label: 'Option 2',
|
|
91
|
-
value: 'option2'
|
|
92
|
-
}];
|
|
93
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, {
|
|
94
|
-
name: "multiple",
|
|
95
|
-
options: options,
|
|
96
|
-
required: true,
|
|
97
|
-
t: t,
|
|
98
|
-
type: "dropdown"
|
|
99
|
-
}));
|
|
100
|
-
var component = wrapper.dive().getElement();
|
|
101
|
-
expect(component).toMatchSnapshot();
|
|
102
|
-
});
|
|
103
|
-
it('uses predefined label', function () {
|
|
104
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountField, {
|
|
105
|
-
label: "login",
|
|
106
|
-
name: "username",
|
|
107
|
-
required: true,
|
|
108
|
-
type: "text",
|
|
109
|
-
t: t
|
|
110
|
-
}));
|
|
111
|
-
expect(wrapper.props().label).toBe('fields.login.label');
|
|
112
|
-
});
|
|
113
|
-
it('ignores invalid predefined label', function () {
|
|
114
|
-
// Avoid warning
|
|
115
|
-
var AccountFieldWithPermissiveLabel = /*#__PURE__*/function (_AccountField) {
|
|
116
|
-
_inherits(AccountFieldWithPermissiveLabel, _AccountField);
|
|
117
|
-
|
|
118
|
-
var _super = _createSuper(AccountFieldWithPermissiveLabel);
|
|
119
|
-
|
|
120
|
-
function AccountFieldWithPermissiveLabel() {
|
|
121
|
-
_classCallCheck(this, AccountFieldWithPermissiveLabel);
|
|
122
|
-
|
|
123
|
-
return _super.apply(this, arguments);
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
return _createClass(AccountFieldWithPermissiveLabel);
|
|
127
|
-
}(AccountField);
|
|
128
|
-
|
|
129
|
-
AccountFieldWithPermissiveLabel.propTypes = _objectSpread(_objectSpread({}, AccountField.propTypes), {}, {
|
|
130
|
-
label: PropTypes.string
|
|
131
|
-
});
|
|
132
|
-
var wrapper = shallow( /*#__PURE__*/React.createElement(AccountFieldWithPermissiveLabel, {
|
|
133
|
-
label: "foo",
|
|
134
|
-
name: "username",
|
|
135
|
-
required: true,
|
|
136
|
-
type: "text",
|
|
137
|
-
t: t
|
|
138
|
-
}));
|
|
139
|
-
expect(wrapper.props().label).toBe('fields.username.label');
|
|
140
|
-
});
|
|
141
|
-
});
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { AccountFields } from 'components/AccountForm/AccountFields';
|
|
2
|
-
import { shallow } from 'enzyme';
|
|
3
|
-
import React from 'react';
|
|
4
|
-
var fixtures = {
|
|
5
|
-
fields: {
|
|
6
|
-
username: {
|
|
7
|
-
type: 'text'
|
|
8
|
-
},
|
|
9
|
-
passphrase: {
|
|
10
|
-
type: 'password'
|
|
11
|
-
}
|
|
12
|
-
},
|
|
13
|
-
sanitized: {
|
|
14
|
-
username: {
|
|
15
|
-
encrypted: false,
|
|
16
|
-
required: true,
|
|
17
|
-
type: 'text'
|
|
18
|
-
},
|
|
19
|
-
passphrase: {
|
|
20
|
-
encrypted: true,
|
|
21
|
-
required: true,
|
|
22
|
-
type: 'password'
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
};
|
|
26
|
-
describe('AccountFields', function () {
|
|
27
|
-
it('should render', function () {
|
|
28
|
-
var component = shallow( /*#__PURE__*/React.createElement(AccountFields, {
|
|
29
|
-
fields: fixtures.fields
|
|
30
|
-
})).getElement();
|
|
31
|
-
expect(component).toMatchSnapshot();
|
|
32
|
-
});
|
|
33
|
-
it('should render encrypted fields with placeholder', function () {
|
|
34
|
-
var component = shallow( /*#__PURE__*/React.createElement(AccountFields, {
|
|
35
|
-
fields: fixtures.sanitized
|
|
36
|
-
})).getElement();
|
|
37
|
-
expect(component).toMatchSnapshot();
|
|
38
|
-
});
|
|
39
|
-
});
|
|
@@ -1,203 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`AccountForm should not render error 1`] = `
|
|
4
|
-
<div
|
|
5
|
-
onFocusCapture={[Function]}
|
|
6
|
-
onKeyUp={[Function]}
|
|
7
|
-
>
|
|
8
|
-
<React.Fragment>
|
|
9
|
-
<AccountFields
|
|
10
|
-
fields={
|
|
11
|
-
Object {
|
|
12
|
-
"passphrase": Object {
|
|
13
|
-
"encrypted": true,
|
|
14
|
-
"required": true,
|
|
15
|
-
"type": "password",
|
|
16
|
-
},
|
|
17
|
-
"username": Object {
|
|
18
|
-
"encrypted": false,
|
|
19
|
-
"required": true,
|
|
20
|
-
"role": "identifier",
|
|
21
|
-
"type": "text",
|
|
22
|
-
},
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
hasError={false}
|
|
26
|
-
initialValues={Object {}}
|
|
27
|
-
inputRefByName={[Function]}
|
|
28
|
-
t={[Function]}
|
|
29
|
-
/>
|
|
30
|
-
<ForwardRef
|
|
31
|
-
busy={false}
|
|
32
|
-
className="u-mt-2 u-mb-1-half"
|
|
33
|
-
data-testid="submit-btn"
|
|
34
|
-
disabled={false}
|
|
35
|
-
fullWidth={true}
|
|
36
|
-
height="default"
|
|
37
|
-
label="Connect"
|
|
38
|
-
onClick={[Function]}
|
|
39
|
-
variant="primary"
|
|
40
|
-
/>
|
|
41
|
-
</React.Fragment>
|
|
42
|
-
</div>
|
|
43
|
-
`;
|
|
44
|
-
|
|
45
|
-
exports[`AccountForm should render 1`] = `
|
|
46
|
-
<div
|
|
47
|
-
onFocusCapture={[Function]}
|
|
48
|
-
onKeyUp={[Function]}
|
|
49
|
-
>
|
|
50
|
-
<React.Fragment>
|
|
51
|
-
<AccountFields
|
|
52
|
-
fields={
|
|
53
|
-
Object {
|
|
54
|
-
"passphrase": Object {
|
|
55
|
-
"encrypted": true,
|
|
56
|
-
"required": true,
|
|
57
|
-
"type": "password",
|
|
58
|
-
},
|
|
59
|
-
"username": Object {
|
|
60
|
-
"encrypted": false,
|
|
61
|
-
"required": true,
|
|
62
|
-
"role": "identifier",
|
|
63
|
-
"type": "text",
|
|
64
|
-
},
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
initialValues={Object {}}
|
|
68
|
-
inputRefByName={[Function]}
|
|
69
|
-
t={[Function]}
|
|
70
|
-
/>
|
|
71
|
-
<ForwardRef
|
|
72
|
-
busy={false}
|
|
73
|
-
className="u-mt-2 u-mb-1-half"
|
|
74
|
-
data-testid="submit-btn"
|
|
75
|
-
disabled={true}
|
|
76
|
-
fullWidth={true}
|
|
77
|
-
height="default"
|
|
78
|
-
label="Connect"
|
|
79
|
-
onClick={[Function]}
|
|
80
|
-
variant="primary"
|
|
81
|
-
/>
|
|
82
|
-
</React.Fragment>
|
|
83
|
-
</div>
|
|
84
|
-
`;
|
|
85
|
-
|
|
86
|
-
exports[`AccountForm should render error 1`] = `
|
|
87
|
-
<div
|
|
88
|
-
onFocusCapture={[Function]}
|
|
89
|
-
onKeyUp={[Function]}
|
|
90
|
-
>
|
|
91
|
-
<ForwardRef
|
|
92
|
-
className="u-mb-1"
|
|
93
|
-
error={[Error: Test error]}
|
|
94
|
-
konnector={
|
|
95
|
-
Object {
|
|
96
|
-
"fields": Object {
|
|
97
|
-
"passphrase": Object {
|
|
98
|
-
"type": "password",
|
|
99
|
-
},
|
|
100
|
-
"username": Object {
|
|
101
|
-
"type": "text",
|
|
102
|
-
},
|
|
103
|
-
},
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
/>
|
|
107
|
-
<React.Fragment>
|
|
108
|
-
<AccountFields
|
|
109
|
-
fields={
|
|
110
|
-
Object {
|
|
111
|
-
"passphrase": Object {
|
|
112
|
-
"encrypted": true,
|
|
113
|
-
"required": true,
|
|
114
|
-
"type": "password",
|
|
115
|
-
},
|
|
116
|
-
"username": Object {
|
|
117
|
-
"encrypted": false,
|
|
118
|
-
"required": true,
|
|
119
|
-
"role": "identifier",
|
|
120
|
-
"type": "text",
|
|
121
|
-
},
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
hasError={false}
|
|
125
|
-
initialValues={Object {}}
|
|
126
|
-
inputRefByName={[Function]}
|
|
127
|
-
t={[Function]}
|
|
128
|
-
/>
|
|
129
|
-
<ForwardRef
|
|
130
|
-
busy={false}
|
|
131
|
-
className="u-mt-2 u-mb-1-half"
|
|
132
|
-
data-testid="submit-btn"
|
|
133
|
-
disabled={false}
|
|
134
|
-
fullWidth={true}
|
|
135
|
-
height="default"
|
|
136
|
-
label="Connect"
|
|
137
|
-
onClick={[Function]}
|
|
138
|
-
variant="primary"
|
|
139
|
-
/>
|
|
140
|
-
</React.Fragment>
|
|
141
|
-
</div>
|
|
142
|
-
`;
|
|
143
|
-
|
|
144
|
-
exports[`AccountForm should render normally when client side konnector with launcher 1`] = `
|
|
145
|
-
<div
|
|
146
|
-
onFocusCapture={[Function]}
|
|
147
|
-
onKeyUp={[Function]}
|
|
148
|
-
>
|
|
149
|
-
<React.Fragment>
|
|
150
|
-
<AccountFields
|
|
151
|
-
fields={Object {}}
|
|
152
|
-
initialValues={Object {}}
|
|
153
|
-
inputRefByName={[Function]}
|
|
154
|
-
t={[Function]}
|
|
155
|
-
/>
|
|
156
|
-
<ConnectCard
|
|
157
|
-
buttonProps={
|
|
158
|
-
Object {
|
|
159
|
-
"busy": false,
|
|
160
|
-
"data-testid": "submit-btn",
|
|
161
|
-
"disabled": false,
|
|
162
|
-
"label": "Connect",
|
|
163
|
-
"onClick": [Function],
|
|
164
|
-
}
|
|
165
|
-
}
|
|
166
|
-
description="Connect testkonnector to your Twake to synchronize your account and retrieve all your data. "
|
|
167
|
-
title="Connect to your Twake"
|
|
168
|
-
/>
|
|
169
|
-
</React.Fragment>
|
|
170
|
-
</div>
|
|
171
|
-
`;
|
|
172
|
-
|
|
173
|
-
exports[`AccountForm should render with specific message when client side konnector without launcher 1`] = `
|
|
174
|
-
<div
|
|
175
|
-
onFocusCapture={[Function]}
|
|
176
|
-
onKeyUp={[Function]}
|
|
177
|
-
>
|
|
178
|
-
<React.Fragment>
|
|
179
|
-
<Media
|
|
180
|
-
align="top"
|
|
181
|
-
>
|
|
182
|
-
<Img
|
|
183
|
-
className="u-m-1"
|
|
184
|
-
>
|
|
185
|
-
<Icon
|
|
186
|
-
icon={[Function]}
|
|
187
|
-
spin={false}
|
|
188
|
-
/>
|
|
189
|
-
</Img>
|
|
190
|
-
<Bd
|
|
191
|
-
className="u-m-1"
|
|
192
|
-
>
|
|
193
|
-
<ForwardRef>
|
|
194
|
-
To synchronize your testkonnector data in your Twake you must use the Twake app on your phone or tablet.
|
|
195
|
-
</ForwardRef>
|
|
196
|
-
</Bd>
|
|
197
|
-
</Media>
|
|
198
|
-
<InstallFlagshipButton
|
|
199
|
-
className="u-mt-2 u-mb-1-half"
|
|
200
|
-
/>
|
|
201
|
-
</React.Fragment>
|
|
202
|
-
</div>
|
|
203
|
-
`;
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`AccountsList should render 1`] = `
|
|
4
|
-
<ForwardRef(DialogContent)
|
|
5
|
-
className="u-pb-2 u-pt-0 u-ph-0"
|
|
6
|
-
classes={
|
|
7
|
-
Object {
|
|
8
|
-
"dividers": "MuiDialogContent-dividers",
|
|
9
|
-
"root": "MuiDialogContent-root",
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
>
|
|
13
|
-
<ul
|
|
14
|
-
className="u-nolist u-p-0 u-m-0"
|
|
15
|
-
>
|
|
16
|
-
<li
|
|
17
|
-
className="u-mb-half"
|
|
18
|
-
>
|
|
19
|
-
<AccountsListItem
|
|
20
|
-
account={
|
|
21
|
-
Object {
|
|
22
|
-
"_id": "account-1",
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
konnector={
|
|
26
|
-
Object {
|
|
27
|
-
"name": "test-konnector",
|
|
28
|
-
"vendor_link": "test konnector link",
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
onClick={[Function]}
|
|
32
|
-
trigger={
|
|
33
|
-
Object {
|
|
34
|
-
"_id": "trigger-1",
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
/>
|
|
38
|
-
</li>
|
|
39
|
-
<li
|
|
40
|
-
className="u-mb-half"
|
|
41
|
-
>
|
|
42
|
-
<AccountsListItem
|
|
43
|
-
account={
|
|
44
|
-
Object {
|
|
45
|
-
"_id": "account-2",
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
konnector={
|
|
49
|
-
Object {
|
|
50
|
-
"name": "test-konnector",
|
|
51
|
-
"vendor_link": "test konnector link",
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
onClick={[Function]}
|
|
55
|
-
trigger={
|
|
56
|
-
Object {
|
|
57
|
-
"_id": "trigger-2",
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
/>
|
|
61
|
-
</li>
|
|
62
|
-
<li
|
|
63
|
-
className="u-mb-half"
|
|
64
|
-
>
|
|
65
|
-
<Card
|
|
66
|
-
className="u-p-0"
|
|
67
|
-
tag="div"
|
|
68
|
-
>
|
|
69
|
-
<ForwardRef
|
|
70
|
-
className="u-bdrs-4"
|
|
71
|
-
fullWidth={true}
|
|
72
|
-
height="default"
|
|
73
|
-
icon={
|
|
74
|
-
<Icon
|
|
75
|
-
icon={[Function]}
|
|
76
|
-
spin={false}
|
|
77
|
-
/>
|
|
78
|
-
}
|
|
79
|
-
label="modal.addAccount.button"
|
|
80
|
-
onClick={[MockFunction]}
|
|
81
|
-
variant="text"
|
|
82
|
-
/>
|
|
83
|
-
</Card>
|
|
84
|
-
</li>
|
|
85
|
-
</ul>
|
|
86
|
-
</ForwardRef(DialogContent)>
|
|
87
|
-
`;
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`AccountsListItem should not render the caption since accountLogin is undefined 1`] = `
|
|
4
|
-
<div
|
|
5
|
-
className="styles__c-card___YgP7B u-flex u-flex-justify-between u-flex-items-center u-c-pointer u-maw-100"
|
|
6
|
-
onClick={[MockFunction]}
|
|
7
|
-
>
|
|
8
|
-
<div
|
|
9
|
-
className="u-flex-grow-1 u-flex-shrink-1 u-ov-hidden u-mr-1"
|
|
10
|
-
>
|
|
11
|
-
<ForwardRef
|
|
12
|
-
className="u-ellipsis"
|
|
13
|
-
variant="body1"
|
|
14
|
-
>
|
|
15
|
-
account-1
|
|
16
|
-
</ForwardRef>
|
|
17
|
-
</div>
|
|
18
|
-
<ForwardRef
|
|
19
|
-
konnector={
|
|
20
|
-
Object {
|
|
21
|
-
"name": "test-konnector",
|
|
22
|
-
"vendor_link": "test konnector link",
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
trigger={Object {}}
|
|
26
|
-
/>
|
|
27
|
-
</div>
|
|
28
|
-
`;
|
|
29
|
-
|
|
30
|
-
exports[`AccountsListItem should render the caption since accountName !== login 1`] = `
|
|
31
|
-
<div
|
|
32
|
-
className="styles__c-card___YgP7B u-flex u-flex-justify-between u-flex-items-center u-c-pointer u-maw-100"
|
|
33
|
-
onClick={[MockFunction]}
|
|
34
|
-
>
|
|
35
|
-
<div
|
|
36
|
-
className="u-flex-grow-1 u-flex-shrink-1 u-ov-hidden u-mr-1"
|
|
37
|
-
>
|
|
38
|
-
<ForwardRef
|
|
39
|
-
className="u-ellipsis"
|
|
40
|
-
gutterBottom={true}
|
|
41
|
-
variant="body1"
|
|
42
|
-
>
|
|
43
|
-
myAccountName
|
|
44
|
-
</ForwardRef>
|
|
45
|
-
<ForwardRef
|
|
46
|
-
className="u-ellipsis"
|
|
47
|
-
color="textSecondary"
|
|
48
|
-
variant="caption"
|
|
49
|
-
>
|
|
50
|
-
mylogin
|
|
51
|
-
</ForwardRef>
|
|
52
|
-
</div>
|
|
53
|
-
<ForwardRef
|
|
54
|
-
konnector={
|
|
55
|
-
Object {
|
|
56
|
-
"name": "test-konnector",
|
|
57
|
-
"vendor_link": "test konnector link",
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
trigger={Object {}}
|
|
61
|
-
/>
|
|
62
|
-
</div>
|
|
63
|
-
`;
|