Skip to content

Commit

Permalink
Merge branch 'master' into chore/update_emotion_to_v11
Browse files Browse the repository at this point in the history
  • Loading branch information
demshy committed Sep 8, 2023
2 parents 1a0f86e + fa7a2f0 commit 18e998b
Show file tree
Hide file tree
Showing 22 changed files with 28 additions and 28 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@
"@types/js-base64": "^3.0.0",
"@types/jwt-decode": "^2.2.1",
"@types/lodash": "^4.14.149",
"@types/uuid": "^3.4.6",
"@types/uuid": "^8.3.2",
"@typescript-eslint/eslint-plugin": "^5.0.0",
"@typescript-eslint/parser": "^5.0.0",
"all-contributors-cli": "^6.0.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
"moment": "^2.24.0",
"prop-types": "^15.7.2",
"react-immutable-proptypes": "^2.1.0",
"uuid": "^3.3.2"
"uuid": "^8.3.2"
},
"peerDependencies": {
"react": "^16.8.4 || ^17.0.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-backend-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@
"lodash": "^4.17.11",
"prop-types": "^15.7.2",
"react": "^16.8.4 || ^17.0.0",
"uuid": "^3.3.2"
"uuid": "^8.3.2"
}
}
2 changes: 1 addition & 1 deletion packages/decap-cms-backend-test/src/implementation.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { attempt, isError, take, unset, isEmpty } from 'lodash';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import {
EditorialWorkflowError,
Cursor,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import * as actions from '../editorialWorkflow';
jest.mock('../../backend');
jest.mock('../../valueObjects/AssetProxy');
jest.mock('decap-cms-lib-util');
jest.mock('uuid/v4', () => {
return jest.fn().mockReturnValue('000000000000000000000');
jest.mock('uuid', () => {
return { v4: jest.fn().mockReturnValue('000000000000000000000') };
});

const middlewares = [thunk];
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-core/src/constants/configSchema.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
prohibited,
} from 'ajv-keywords/dist/keywords';
import ajvErrors from 'ajv-errors';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';

import { frontmatterFormats, extensionFormatters } from '../formats/formats';
import { getWidgets } from '../lib/registry';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Map, fromJS } from 'immutable';
import * as actions from '../../actions/entries';
import reducer from '../entryDraft';

jest.mock('uuid/v4', () => jest.fn(() => '1'));
jest.mock('uuid', () => ({ v4: jest.fn(() => '1') }));

const initialState = Map({
entry: Map(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import mediaLibrary, {
selectMediaDisplayURL,
} from '../mediaLibrary';

jest.mock('uuid/v4');
jest.mock('uuid');
jest.mock('../entries');
jest.mock('../');

Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-core/src/reducers/entryDraft.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Map, List, fromJS } from 'immutable';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import { get } from 'lodash';
import { join } from 'path';

Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-core/src/reducers/mediaLibrary.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Map, List } from 'immutable';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import { dirname } from 'path';

import {
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-core/src/reducers/notifications.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { produce } from 'immer';
import uuid from 'uuid';
import { v4 as uuid } from 'uuid';

import {
NOTIFICATION_SEND,
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-default-exports/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"moment": "^2.24.0",
"prop-types": "^15.7.2",
"react-immutable-proptypes": "^2.1.0",
"uuid": "^3.3.2"
"uuid": "^8.3.2"
},
"peerDependencies": {
"react": "^16.8.4 || ^17.0.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-lib-auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@
"peerDependencies": {
"immutable": "^3.7.6",
"lodash": "^4.17.11",
"uuid": "^3.3.2"
"uuid": "^8.3.2"
}
}
2 changes: 1 addition & 1 deletion packages/decap-cms-lib-auth/src/utils.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';

export function createNonce() {
const nonce = uuid();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import uploadcare from 'uploadcare-widget';
import uploadcareTabEffects from 'uploadcare-widget-tab-effects';

Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-widget-code/src/CodeControl.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import ImmutablePropTypes from 'react-immutable-proptypes';
import { ClassNames } from '@emotion/react';
import { Map } from 'immutable';
import { uniq, isEqual, isEmpty } from 'lodash';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import { UnControlled as ReactCodeMirror } from 'react-codemirror2';
import CodeMirror from 'codemirror';
import 'codemirror/keymap/vim';
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-widget-file/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,6 @@
"prop-types": "^15.7.2",
"react": "^16.8.4 || ^17.0.0",
"react-immutable-proptypes": "^2.1.0",
"uuid": "^3.3.2"
"uuid": "^8.3.2"
}
}
2 changes: 1 addition & 1 deletion packages/decap-cms-widget-file/src/withFileControl.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import styled from '@emotion/styled';
import { css } from '@emotion/react';
import { Map, List } from 'immutable';
import { once } from 'lodash';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import { oneLine } from 'common-tags';
import {
lengths,
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-widget-list/src/ListControl.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import styled from '@emotion/styled';
import { css, ClassNames } from '@emotion/react';
import { List, Map, fromJS } from 'immutable';
import { partial, isEmpty, uniqueId } from 'lodash';
import uuid from 'uuid/v4';
import { v4 as uuid } from 'uuid';
import DecapCmsWidgetObject from 'decap-cms-widget-object';
import {
DndContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jest.mock('decap-cms-ui-default', () => {
ListItemTopBar,
};
});
jest.mock('uuid/v4');
jest.mock('uuid');

describe('ListControl', () => {
const props = {
Expand Down Expand Up @@ -63,9 +63,9 @@ describe('ListControl', () => {

beforeEach(() => {
jest.clearAllMocks();
const uuid = require('uuid/v4');
const uuid = require('uuid');
let id = 0;
uuid.mockImplementation(() => {
uuid.v4.mockImplementation(() => {
return id++;
});
});
Expand Down
2 changes: 1 addition & 1 deletion packages/decap-cms-widget-relation/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,6 @@
"lodash": "^4.17.11",
"prop-types": "^15.7.2",
"react": "^16.8.4 || ^17.0.0",
"uuid": "^3.3.2"
"uuid": "^8.3.2"
}
}
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4202,10 +4202,10 @@
resolved "https://registry.yarnpkg.com/@types/url-join/-/url-join-4.0.1.tgz#4989c97f969464647a8586c7252d97b449cdc045"
integrity sha512-wDXw9LEEUHyV+7UWy7U315nrJGJ7p1BzaCxDpEoLr789Dk1WDVMMlf3iBfbG2F8NdWnYyFbtTxUn2ZNbm1Q4LQ==

"@types/uuid@^3.4.6":
version "3.4.11"
resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-3.4.11.tgz#201bf1ca5756537886931aac6672c21c1a06f98a"
integrity sha512-CJNkbEu4IdVuBMRVaNC2GjASgJK7ziqDlVXWuJ1pvhOLADl7nzxhTKjHRdOmo2SuXuygcWBmzgYgn9foTX0UiA==
"@types/uuid@^8.3.2":
version "8.3.4"
resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-8.3.4.tgz#bd86a43617df0594787d38b735f55c805becf1bc"
integrity sha512-c/I8ZRb51j+pYGAu5CrFMRxqZ2ke4y2grEBO5AUjgSkSk+qT2Ea+OdWElz/OiMf5MNpn2b17kuVBwZLQJXzihw==

"@types/vfile-message@*", "@types/vfile-message@^2.0.0":
version "2.0.0"
Expand Down

0 comments on commit 18e998b

Please sign in to comment.