@manuscripts/article-editor 3.8.83 → 3.8.84-LEAN-2023.0
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/dist/cjs/__mocks__/fileMock.js +15 -0
- package/dist/cjs/__mocks__/fileMock.js.map +1 -0
- package/dist/cjs/__mocks__/styleMock.js +15 -0
- package/dist/cjs/__mocks__/styleMock.js.map +1 -0
- package/dist/cjs/index.js +2 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/{es/lib/tracking.js → cjs/lib/__mocks__/token.js} +8 -31
- package/dist/cjs/lib/__mocks__/token.js.map +1 -0
- package/dist/cjs/lib/__tests__/layout.test.js +38 -0
- package/dist/cjs/lib/__tests__/layout.test.js.map +1 -0
- package/dist/cjs/lib/__tests__/preferences.test.js +50 -0
- package/dist/cjs/lib/__tests__/preferences.test.js.map +1 -0
- package/dist/cjs/lib/__tests__/roles.test.js +32 -0
- package/dist/cjs/lib/__tests__/roles.test.js.map +1 -0
- package/dist/cjs/lib/{tracking.js → __tests__/token.test.js} +17 -35
- package/dist/cjs/lib/__tests__/token.test.js.map +1 -0
- package/dist/cjs/lib/__tests__/user.test.js +41 -0
- package/dist/cjs/lib/__tests__/user.test.js.map +1 -0
- package/dist/cjs/lib/change-handlers.js +23 -4
- package/dist/cjs/lib/change-handlers.js.map +1 -1
- package/dist/cjs/lib/user.js +2 -2
- package/dist/cjs/lib/user.js.map +1 -1
- package/dist/cjs/store/TokenData.js +2 -5
- package/dist/cjs/store/TokenData.js.map +1 -1
- package/dist/es/__mocks__/fileMock.js +13 -0
- package/dist/es/__mocks__/fileMock.js.map +1 -0
- package/dist/es/__mocks__/styleMock.js +13 -0
- package/dist/es/__mocks__/styleMock.js.map +1 -0
- package/dist/es/index.js +2 -2
- package/dist/es/index.js.map +1 -1
- package/dist/es/lib/__mocks__/token.js +18 -0
- package/dist/es/lib/__mocks__/token.js.map +1 -0
- package/dist/es/lib/__tests__/layout.test.js +33 -0
- package/dist/es/lib/__tests__/layout.test.js.map +1 -0
- package/dist/es/lib/__tests__/preferences.test.js +25 -0
- package/dist/es/lib/__tests__/preferences.test.js.map +1 -0
- package/dist/es/lib/__tests__/roles.test.js +30 -0
- package/dist/es/lib/__tests__/roles.test.js.map +1 -0
- package/dist/es/lib/__tests__/token.test.js +25 -0
- package/dist/es/lib/__tests__/token.test.js.map +1 -0
- package/dist/es/lib/__tests__/user.test.js +36 -0
- package/dist/es/lib/__tests__/user.test.js.map +1 -0
- package/dist/es/lib/change-handlers.js +20 -1
- package/dist/es/lib/change-handlers.js.map +1 -1
- package/dist/es/lib/user.js +2 -2
- package/dist/es/lib/user.js.map +1 -1
- package/dist/es/store/TokenData.js +2 -2
- package/dist/es/store/TokenData.js.map +1 -1
- package/dist/types/__mocks__/fileMock.d.ts +13 -0
- package/dist/types/__mocks__/styleMock.d.ts +13 -0
- package/dist/types/components/projects/inputs.d.ts +1 -1
- package/dist/types/lib/__mocks__/token.d.ts +17 -0
- package/dist/types/lib/{tracking.d.ts → __tests__/layout.test.d.ts} +0 -17
- package/dist/types/lib/__tests__/preferences.test.d.ts +12 -0
- package/dist/types/lib/__tests__/roles.test.d.ts +12 -0
- package/dist/types/lib/__tests__/token.test.d.ts +12 -0
- package/dist/types/lib/__tests__/user.test.d.ts +12 -0
- package/package.json +78 -86
- package/dist/cjs/lib/tracking.js.map +0 -1
- package/dist/es/lib/tracking.js.map +0 -1
@@ -0,0 +1,33 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
import LayoutStorage from '../layout';
|
13
|
+
describe('layout state persistence', () => {
|
14
|
+
it('get', () => {
|
15
|
+
const loadResult = LayoutStorage.get('foo');
|
16
|
+
expect(loadResult).toEqual({ size: 200, collapsed: false });
|
17
|
+
});
|
18
|
+
it('set', () => {
|
19
|
+
const bar = {
|
20
|
+
size: 10,
|
21
|
+
collapsed: true,
|
22
|
+
};
|
23
|
+
const setResult = LayoutStorage.set('foo', bar);
|
24
|
+
expect(setResult).toEqual(bar);
|
25
|
+
// expect(Layout.get('foo')).toEqual(bar) // FIXME: I think this not being met is indicating a bug?
|
26
|
+
});
|
27
|
+
it('remove', () => {
|
28
|
+
LayoutStorage.remove();
|
29
|
+
const storage = window.localStorage;
|
30
|
+
expect(storage.getItem('layout')).toBeFalsy();
|
31
|
+
});
|
32
|
+
});
|
33
|
+
//# sourceMappingURL=layout.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"layout.test.js","sourceRoot":"","sources":["../../../../src/lib/__tests__/layout.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,aAAa,MAAM,WAAW,CAAA;AAErC,QAAQ,CAAC,0BAA0B,EAAE,GAAG,EAAE;IACxC,EAAE,CAAC,KAAK,EAAE,GAAG,EAAE;QACb,MAAM,UAAU,GAAG,aAAa,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;QAC3C,MAAM,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE,GAAG,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC,CAAA;IAC7D,CAAC,CAAC,CAAA;IAEF,EAAE,CAAC,KAAK,EAAE,GAAG,EAAE;QACb,MAAM,GAAG,GAAG;YACV,IAAI,EAAE,EAAE;YACR,SAAS,EAAE,IAAI;SAChB,CAAA;QACD,MAAM,SAAS,GAAG,aAAa,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,CAAA;QAC/C,MAAM,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,CAAA;QAC9B,mGAAmG;IACrG,CAAC,CAAC,CAAA;IAEF,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;QAChB,aAAa,CAAC,MAAM,EAAE,CAAA;QACtB,MAAM,OAAO,GAAG,MAAM,CAAC,YAAY,CAAA;QACnC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,EAAE,CAAA;IAC/C,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
import Prefs, { defaults } from '../preferences';
|
13
|
+
describe('preferences', () => {
|
14
|
+
it('have defaults', () => {
|
15
|
+
expect(Prefs.get()).toEqual(defaults);
|
16
|
+
});
|
17
|
+
it('can be set and removed', () => {
|
18
|
+
const prefs = { locale: 'ar' };
|
19
|
+
expect(Prefs.set(prefs)).toEqual(prefs);
|
20
|
+
expect(Prefs.get()).toEqual(prefs);
|
21
|
+
Prefs.remove();
|
22
|
+
expect(Prefs.get()).toEqual(defaults); // check that we're back to defaults
|
23
|
+
});
|
24
|
+
});
|
25
|
+
//# sourceMappingURL=preferences.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"preferences.test.js","sourceRoot":"","sources":["../../../../src/lib/__tests__/preferences.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAe,MAAM,gBAAgB,CAAA;AAE7D,QAAQ,CAAC,aAAa,EAAE,GAAG,EAAE;IAC3B,EAAE,CAAC,eAAe,EAAE,GAAG,EAAE;QACvB,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAA;IACvC,CAAC,CAAC,CAAA;IAEF,EAAE,CAAC,wBAAwB,EAAE,GAAG,EAAE;QAChC,MAAM,KAAK,GAAgB,EAAE,MAAM,EAAE,IAAI,EAAE,CAAA;QAC3C,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;QACvC,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;QAElC,KAAK,CAAC,MAAM,EAAE,CAAA;QACd,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAA,CAAC,oCAAoC;IAC5E,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
import { getUserRole, isOwner, isViewer, isWriter, ProjectRole } from '../roles';
|
13
|
+
describe('roles', () => {
|
14
|
+
const project = {
|
15
|
+
owners: ['User_A'],
|
16
|
+
viewers: ['User_B'],
|
17
|
+
writers: ['User_C'],
|
18
|
+
};
|
19
|
+
it('isOwner must return true if the user is an owner', () => expect(isOwner(project, 'User_A')).toBeTruthy());
|
20
|
+
it('isOwner must return false if the user is not an owner', () => expect(isOwner(project, 'User_D')).toBeFalsy());
|
21
|
+
it('isWriter must return true if the user is a writer', () => expect(isWriter(project, 'User_C')).toBeTruthy());
|
22
|
+
it('isWriter must return false if the user is not a writer', () => expect(isWriter(project, 'User_D')).toBeFalsy());
|
23
|
+
it('isViewer must return true if the user is a viewer', () => expect(isViewer(project, 'User_B')).toBeTruthy());
|
24
|
+
it('isViewer must return false if the user is not a viewer', () => expect(isViewer(project, 'User_D')).toBeFalsy());
|
25
|
+
it('getRole must return owner if the user is an owner', () => expect(getUserRole(project, 'User_A')).toBe(ProjectRole.owner));
|
26
|
+
it('getRole must return writer if the user is a writer', () => expect(getUserRole(project, 'User_C')).toBe(ProjectRole.writer));
|
27
|
+
it('getRole must return viewer if the user is a viewer', () => expect(getUserRole(project, 'User_B')).toBe(ProjectRole.viewer));
|
28
|
+
it('getRole must return null if the user not in the project', () => expect(getUserRole(project, 'User_D')).toBeNull());
|
29
|
+
});
|
30
|
+
//# sourceMappingURL=roles.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"roles.test.js","sourceRoot":"","sources":["../../../../src/lib/__tests__/roles.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAIH,OAAO,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAEhF,QAAQ,CAAC,OAAO,EAAE,GAAG,EAAE;IACrB,MAAM,OAAO,GAAY;QACvB,MAAM,EAAE,CAAC,QAAQ,CAAC;QAClB,OAAO,EAAE,CAAC,QAAQ,CAAC;QACnB,OAAO,EAAE,CAAC,QAAQ,CAAC;KACT,CAAA;IAEZ,EAAE,CAAC,kDAAkD,EAAE,GAAG,EAAE,CAC1D,MAAM,CAAC,OAAO,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,UAAU,EAAE,CAAC,CAAA;IAElD,EAAE,CAAC,uDAAuD,EAAE,GAAG,EAAE,CAC/D,MAAM,CAAC,OAAO,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC,CAAA;IAEjD,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE,CAC3D,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,UAAU,EAAE,CAAC,CAAA;IAEnD,EAAE,CAAC,wDAAwD,EAAE,GAAG,EAAE,CAChE,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC,CAAA;IAElD,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE,CAC3D,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,UAAU,EAAE,CAAC,CAAA;IAEnD,EAAE,CAAC,wDAAwD,EAAE,GAAG,EAAE,CAChE,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,SAAS,EAAE,CAAC,CAAA;IAElD,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE,CAC3D,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,CAAA;IAEjE,EAAE,CAAC,oDAAoD,EAAE,GAAG,EAAE,CAC5D,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,CAAA;IAElE,EAAE,CAAC,oDAAoD,EAAE,GAAG,EAAE,CAC5D,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,CAAA;IAElE,EAAE,CAAC,yDAAyD,EAAE,GAAG,EAAE,CACjE,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAA;AACtD,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1,25 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
import TokenStore from '../token';
|
13
|
+
describe('token', () => {
|
14
|
+
// all of get, set, remove all in one test call
|
15
|
+
// such as to make test ordering not be a factor in success.
|
16
|
+
it('get and set', () => {
|
17
|
+
expect(TokenStore.get()).toBeFalsy();
|
18
|
+
const token = 'bar';
|
19
|
+
expect(TokenStore.set(token)).toEqual(token);
|
20
|
+
expect(TokenStore.get()).toEqual(token);
|
21
|
+
TokenStore.remove();
|
22
|
+
expect(TokenStore.get()).toBe(null);
|
23
|
+
});
|
24
|
+
});
|
25
|
+
//# sourceMappingURL=token.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"token.test.js","sourceRoot":"","sources":["../../../../src/lib/__tests__/token.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,UAAU,MAAM,UAAU,CAAA;AAEjC,QAAQ,CAAC,OAAO,EAAE,GAAG,EAAE;IACrB,+CAA+C;IAC/C,4DAA4D;IAC5D,EAAE,CAAC,aAAa,EAAE,GAAG,EAAE;QACrB,MAAM,CAAC,UAAU,CAAC,GAAG,EAAE,CAAC,CAAC,SAAS,EAAE,CAAA;QAEpC,MAAM,KAAK,GAAG,KAAK,CAAA;QACnB,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;QAC5C,MAAM,CAAC,UAAU,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAA;QAEvC,UAAU,CAAC,MAAM,EAAE,CAAA;QACnB,MAAM,CAAC,UAAU,CAAC,GAAG,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IACrC,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -0,0 +1,36 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
import tokenHandler from '../token';
|
13
|
+
import { getCurrentUserId } from '../user';
|
14
|
+
jest.mock('../token');
|
15
|
+
describe('user', () => {
|
16
|
+
test('get current user id from token', () => {
|
17
|
+
const data = {
|
18
|
+
userID: '123456',
|
19
|
+
email: 'User_test@example.com',
|
20
|
+
deviceID: 'device123',
|
21
|
+
aud: 'your-audience',
|
22
|
+
iss: 'your-issuer',
|
23
|
+
iat: 1616172290,
|
24
|
+
};
|
25
|
+
const token = ['', btoa(JSON.stringify(data)), ''].join('.');
|
26
|
+
tokenHandler.set(token);
|
27
|
+
const result = getCurrentUserId();
|
28
|
+
expect(result).toBe('123456');
|
29
|
+
tokenHandler.remove();
|
30
|
+
});
|
31
|
+
test('get removed current user id', () => {
|
32
|
+
const result = getCurrentUserId();
|
33
|
+
expect(result).toBeNull();
|
34
|
+
});
|
35
|
+
});
|
36
|
+
//# sourceMappingURL=user.test.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"user.test.js","sourceRoot":"","sources":["../../../../src/lib/__tests__/user.test.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,YAAY,MAAM,UAAU,CAAA;AACnC,OAAO,EAAE,gBAAgB,EAAgB,MAAM,SAAS,CAAA;AAExD,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAA;AAErB,QAAQ,CAAC,MAAM,EAAE,GAAG,EAAE;IACpB,IAAI,CAAC,gCAAgC,EAAE,GAAG,EAAE;QAC1C,MAAM,IAAI,GAAiB;YACzB,MAAM,EAAE,QAAQ;YAChB,KAAK,EAAE,uBAAuB;YAC9B,QAAQ,EAAE,WAAW;YACrB,GAAG,EAAE,eAAe;YACpB,GAAG,EAAE,aAAa;YAClB,GAAG,EAAE,UAAU;SAChB,CAAA;QACD,MAAM,KAAK,GAAG,CAAC,EAAE,EAAE,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA;QAC5D,YAAY,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;QAEvB,MAAM,MAAM,GAAG,gBAAgB,EAAE,CAAA;QAEjC,MAAM,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAA;QAE7B,YAAY,CAAC,MAAM,EAAE,CAAA;IACvB,CAAC,CAAC,CAAA;IAEF,IAAI,CAAC,6BAA6B,EAAE,GAAG,EAAE;QACvC,MAAM,MAAM,GAAG,gBAAgB,EAAE,CAAA;QAEjC,MAAM,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,CAAA;IAC3B,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
@@ -13,7 +13,6 @@ import { affiliationLabel, authorLabel, } from '@manuscripts/body-editor';
|
|
13
13
|
import { ChangeSet, } from '@manuscripts/track-changes-plugin';
|
14
14
|
import { nodeNames, schema, } from '@manuscripts/transform';
|
15
15
|
import { NodeTextContentRetriever } from './node-content-retriever';
|
16
|
-
import { changeOperationAlias } from './tracking';
|
17
16
|
import { getParentNode } from './utils';
|
18
17
|
const isAltTitleNode = (node) => node.type === schema.nodes.alt_title;
|
19
18
|
const getTitleDisplayName = (node) => {
|
@@ -198,4 +197,24 @@ export const handleUnknownChange = () => {
|
|
198
197
|
content: 'Unknown change!',
|
199
198
|
};
|
200
199
|
};
|
200
|
+
const changeOperationAlias = (operation) => {
|
201
|
+
switch (operation) {
|
202
|
+
case 'delete': {
|
203
|
+
return 'Deleted';
|
204
|
+
}
|
205
|
+
case 'insert':
|
206
|
+
case 'wrap_with_node': {
|
207
|
+
return 'Inserted';
|
208
|
+
}
|
209
|
+
case 'set_attrs': {
|
210
|
+
return 'Updated';
|
211
|
+
}
|
212
|
+
case 'node_split': {
|
213
|
+
return 'Split';
|
214
|
+
}
|
215
|
+
default: {
|
216
|
+
return 'null';
|
217
|
+
}
|
218
|
+
}
|
219
|
+
};
|
201
220
|
//# sourceMappingURL=change-handlers.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"change-handlers.js","sourceRoot":"","sources":["../../../src/lib/change-handlers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EAEL,gBAAgB,EAChB,WAAW,GAEZ,MAAM,0BAA0B,CAAA;AACjC,OAAO,EACL,SAAS,GAKV,MAAM,mCAAmC,CAAA;AAC1C,OAAO,EAGL,SAAS,EACT,MAAM,GACP,MAAM,wBAAwB,CAAA;AAE/B,OAAO,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAA;AACnE,OAAO,EAAE,
|
1
|
+
{"version":3,"file":"change-handlers.js","sourceRoot":"","sources":["../../../src/lib/change-handlers.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EAEL,gBAAgB,EAChB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AC,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAClB,MAAM,EAAE,QAAQ,KAAK,iBAAiB;QACpC,CAAC,CAAC,IAAI,MAAM,CAAC,OAAO,GAAG;QACvB,CAAC,CAAC,MAAM,EAAE,OAAO,IAAI,EAAE,CAC1B;SACA,IAAI,CAAC,EAAE,CAAC,CAAA;IAEX,OAAO;QACL,SAAS,EAAE,oBAAoB,CAAC,WAAW,CAAC,SAAS,CAAC;QACtD,QAAQ,EAAE,aAAa,IAAI,MAAM;QACjC,OAAO;KACR,CAAA;AACH,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,mBAAmB,GAAG,GAAgB,EAAE;IACnD,OAAO;QACL,SAAS,EAAE,EAAE;QACb,QAAQ,EAAE,EAAE;QACZ,OAAO,EAAE,iBAAiB;KAC3B,CAAA;AACH,CAAC,CAAA;AAED,MAAM,oBAAoB,GAAG,CAAC,SAAiB,EAAU,EAAE;IACzD,QAAQ,SAAS,EAAE;QACjB,KAAK,QAAQ,CAAC,CAAC;YACb,OAAO,SAAS,CAAA;SACjB;QACD,KAAK,QAAQ,CAAC;QACd,KAAK,gBAAgB,CAAC,CAAC;YACrB,OAAO,UAAU,CAAA;SAClB;QACD,KAAK,WAAW,CAAC,CAAC;YAChB,OAAO,SAAS,CAAA;SACjB;QACD,KAAK,YAAY,CAAC,CAAC;YACjB,OAAO,OAAO,CAAA;SACf;QACD,OAAO,CAAC,CAAC;YACP,OAAO,MAAM,CAAA;SACd;KACF;AACH,CAAC,CAAA"}
|
package/dist/es/lib/user.js
CHANGED
@@ -9,14 +9,14 @@
|
|
9
9
|
*
|
10
10
|
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
11
|
*/
|
12
|
-
import
|
12
|
+
import { jwtDecode } from 'jwt-decode';
|
13
13
|
import tokenHandler from './token';
|
14
14
|
export const getCurrentUserId = () => {
|
15
15
|
const token = tokenHandler.get();
|
16
16
|
if (!token) {
|
17
17
|
return null;
|
18
18
|
}
|
19
|
-
const { userID } =
|
19
|
+
const { userID } = jwtDecode(token);
|
20
20
|
return userID;
|
21
21
|
};
|
22
22
|
//# sourceMappingURL=user.js.map
|
package/dist/es/lib/user.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"user.js","sourceRoot":"","sources":["../../../src/lib/user.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,
|
1
|
+
{"version":3,"file":"user.js","sourceRoot":"","sources":["../../../src/lib/user.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAA;AAEtC,OAAO,YAAY,MAAM,SAAS,CAAA;AAWlC,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,EAAE;IACnC,MAAM,KAAK,GAAG,YAAY,CAAC,GAAG,EAAE,CAAA;IAEhC,IAAI,CAAC,KAAK,EAAE;QACV,OAAO,IAAI,CAAA;KACZ;IAED,MAAM,EAAE,MAAM,EAAE,GAAG,SAAS,CAAe,KAAK,CAAC,CAAA;IACjD,OAAO,MAAM,CAAA;AACf,CAAC,CAAA"}
|
@@ -9,14 +9,14 @@
|
|
9
9
|
*
|
10
10
|
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
11
|
*/
|
12
|
-
import
|
12
|
+
import { jwtDecode } from 'jwt-decode';
|
13
13
|
const storage = window.localStorage;
|
14
14
|
// TODO: handle token expiry
|
15
15
|
// TODO: provide profile id using context?
|
16
16
|
export class TokenData {
|
17
17
|
constructor() {
|
18
18
|
this.parseToken = (token) => {
|
19
|
-
const { userID } =
|
19
|
+
const { userID } = jwtDecode(token);
|
20
20
|
if (userID) {
|
21
21
|
this.data = {
|
22
22
|
userID,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"TokenData.js","sourceRoot":"","sources":["../../../src/store/TokenData.ts"],"names":[],"mappings":"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AI,CAAA;SACnB;IACH,CAAC;IAEM,eAAe;QACpB,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE;YAChB,OAAO,IAAI,CAAA;SACZ;QAED,OAAO;YACL,GAAG,IAAI,CAAC,IAAI;YACZ,MAAM,EAAE,IAAI,CAAC,WAAW;YACxB,MAAM,EAAE,IAAI,CAAC,WAAW;SACzB,CAAA;IACH,CAAC;CA6BF"}
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
declare const _default: "test-file-stub";
|
13
|
+
export default _default;
|
@@ -0,0 +1,13 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
declare const _default: {};
|
13
|
+
export default _default;
|
@@ -9,4 +9,4 @@
|
|
9
9
|
*
|
10
10
|
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
11
|
*/
|
12
|
-
export declare const MediumTextField: import("styled-components").StyledComponent<"input", import("styled-components").DefaultTheme, import("@manuscripts/style-guide").ErrorProps, never>;
|
12
|
+
export declare const MediumTextField: import("styled-components").StyledComponent<"input", import("styled-components").DefaultTheme, import("@manuscripts/style-guide/dist/types").ErrorProps, never>;
|
@@ -0,0 +1,17 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
declare const _default: {
|
13
|
+
get: () => string | null;
|
14
|
+
set: (data: string) => string;
|
15
|
+
remove: () => null;
|
16
|
+
};
|
17
|
+
export default _default;
|
@@ -9,21 +9,4 @@
|
|
9
9
|
*
|
10
10
|
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
11
|
*/
|
12
|
-
interface Tracking {
|
13
|
-
category: string;
|
14
|
-
action: string;
|
15
|
-
label?: string;
|
16
|
-
value?: string;
|
17
|
-
}
|
18
|
-
interface InvitationsTracking extends Tracking {
|
19
|
-
category: 'Invitations';
|
20
|
-
action: 'Share' | 'Send' | 'Accept';
|
21
|
-
}
|
22
|
-
interface ManuscriptsTracking extends Tracking {
|
23
|
-
category: 'Manuscripts';
|
24
|
-
action: 'Create' | 'Import' | 'Export';
|
25
|
-
}
|
26
|
-
type TrackEvent = (f: InvitationsTracking | ManuscriptsTracking) => void;
|
27
|
-
export declare const trackEvent: TrackEvent;
|
28
|
-
export declare const changeOperationAlias: (operation: string) => string;
|
29
12
|
export {};
|
@@ -0,0 +1,12 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
export {};
|
@@ -0,0 +1,12 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
export {};
|
@@ -0,0 +1,12 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
export {};
|
@@ -0,0 +1,12 @@
|
|
1
|
+
/*!
|
2
|
+
* The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
|
3
|
+
*
|
4
|
+
* Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
|
5
|
+
*
|
6
|
+
* The Original Code is manuscripts-frontend.
|
7
|
+
*
|
8
|
+
* The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
|
9
|
+
*
|
10
|
+
* All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
|
11
|
+
*/
|
12
|
+
export {};
|