From 97e33908a005dba3fdcf34f2a9b0c4c2759364c4 Mon Sep 17 00:00:00 2001 From: soupette Date: Fri, 18 Dec 2020 16:44:24 +0100 Subject: [PATCH] Fix input uid Signed-off-by: soupette --- packages/strapi-admin/package.json | 12 ++-- packages/strapi-helper-plugin/package.json | 12 ++-- .../admin/src/components/InputUID/index.js | 7 --- .../admin/src/containers/ListView/index.js | 2 +- .../package.json | 12 ++-- .../package.json | 12 ++-- .../strapi-plugin-documentation/package.json | 12 ++-- packages/strapi-plugin-upload/package.json | 12 ++-- .../package.json | 12 ++-- yarn.lock | 62 +++++++++---------- 10 files changed, 74 insertions(+), 81 deletions(-) diff --git a/packages/strapi-admin/package.json b/packages/strapi-admin/package.json index 6aa9ba1e1a..56704c6608 100644 --- a/packages/strapi-admin/package.json +++ b/packages/strapi-admin/package.json @@ -23,12 +23,12 @@ "@babel/preset-env": "^7.9.5", "@babel/preset-react": "^7.9.4", "@babel/runtime": "^7.9.2", - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "@casl/ability": "^4.1.5", "@fortawesome/fontawesome-free": "^5.11.2", "@fortawesome/fontawesome-svg-core": "^1.2.32", diff --git a/packages/strapi-helper-plugin/package.json b/packages/strapi-helper-plugin/package.json index 046e41a515..6ada90d412 100644 --- a/packages/strapi-helper-plugin/package.json +++ b/packages/strapi-helper-plugin/package.json @@ -50,12 +50,12 @@ "rollup-plugin-terser": "^4.0.4" }, "dependencies": { - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "bootstrap": "^4.5.3", "classnames": "^2.2.5", "immutable": "^3.8.2", diff --git a/packages/strapi-plugin-content-manager/admin/src/components/InputUID/index.js b/packages/strapi-plugin-content-manager/admin/src/components/InputUID/index.js index b1f8b948bb..f893a39e11 100644 --- a/packages/strapi-plugin-content-manager/admin/src/components/InputUID/index.js +++ b/packages/strapi-plugin-content-manager/admin/src/components/InputUID/index.js @@ -115,13 +115,6 @@ const InputUID = ({ } }; - useEffect(() => { - if (!value && validations.required) { - generateUid.current(true); - } - // eslint-disable-next-line react-hooks/exhaustive-deps - }, []); - useEffect(() => { if ( debouncedValue && diff --git a/packages/strapi-plugin-content-manager/admin/src/containers/ListView/index.js b/packages/strapi-plugin-content-manager/admin/src/containers/ListView/index.js index f157ceb595..c8c928be42 100644 --- a/packages/strapi-plugin-content-manager/admin/src/containers/ListView/index.js +++ b/packages/strapi-plugin-content-manager/admin/src/containers/ListView/index.js @@ -118,7 +118,7 @@ function ListView({ const [isFilterPickerOpen, setFilterPickerState] = useState(false); const [idToDelete, setIdToDelete] = useState(null); const contentType = layout.contentType; - const hasDraftAndPublish = contentType.options.draftAndPublish; + const hasDraftAndPublish = contentType.options.draftAndPublish || false; const allAllowedHeaders = useMemo(() => getAllAllowedHeaders(attributes), [attributes]); const filters = useMemo(() => { diff --git a/packages/strapi-plugin-content-manager/package.json b/packages/strapi-plugin-content-manager/package.json index fbf8da423c..b3302419d6 100644 --- a/packages/strapi-plugin-content-manager/package.json +++ b/packages/strapi-plugin-content-manager/package.json @@ -9,12 +9,12 @@ "required": true }, "dependencies": { - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "@sindresorhus/slugify": "1.1.0", "classnames": "^2.2.6", "codemirror": "^5.46.0", diff --git a/packages/strapi-plugin-content-type-builder/package.json b/packages/strapi-plugin-content-type-builder/package.json index 4ce11a0949..1057befea4 100644 --- a/packages/strapi-plugin-content-type-builder/package.json +++ b/packages/strapi-plugin-content-type-builder/package.json @@ -8,12 +8,12 @@ "description": "content-type-builder.plugin.description" }, "dependencies": { - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "@sindresorhus/slugify": "1.1.0", "fs-extra": "^9.0.1", "immutable": "^3.8.2", diff --git a/packages/strapi-plugin-documentation/package.json b/packages/strapi-plugin-documentation/package.json index 5167befcd3..ca8625db2f 100644 --- a/packages/strapi-plugin-documentation/package.json +++ b/packages/strapi-plugin-documentation/package.json @@ -11,12 +11,12 @@ "test": "echo \"no tests yet\"" }, "dependencies": { - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "cheerio": "^1.0.0-rc.3", "fs-extra": "^9.0.1", "immutable": "^3.8.2", diff --git a/packages/strapi-plugin-upload/package.json b/packages/strapi-plugin-upload/package.json index 060fcdbb31..a08364eeb6 100644 --- a/packages/strapi-plugin-upload/package.json +++ b/packages/strapi-plugin-upload/package.json @@ -12,12 +12,12 @@ "test": "echo \"no tests yet\"" }, "dependencies": { - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "byte-size": "^7.0.0", "cropperjs": "^1.5.6", "immer": "^7.0.14", diff --git a/packages/strapi-plugin-users-permissions/package.json b/packages/strapi-plugin-users-permissions/package.json index f3a2b585e2..43a29c8a95 100644 --- a/packages/strapi-plugin-users-permissions/package.json +++ b/packages/strapi-plugin-users-permissions/package.json @@ -12,12 +12,12 @@ "test": "echo \"no tests yet\"" }, "dependencies": { - "@buffetjs/core": "3.3.2-next.2", - "@buffetjs/custom": "3.3.2-next.2", - "@buffetjs/hooks": "3.3.2-next.2", - "@buffetjs/icons": "3.3.2-next.2", - "@buffetjs/styles": "3.3.2-next.2", - "@buffetjs/utils": "3.3.2-next.2", + "@buffetjs/core": "3.3.3-next.0", + "@buffetjs/custom": "3.3.3-next.0", + "@buffetjs/hooks": "3.3.3-next.0", + "@buffetjs/icons": "3.3.3-next.0", + "@buffetjs/styles": "3.3.3-next.0", + "@buffetjs/utils": "3.3.3-next.0", "@purest/providers": "^1.0.2", "bcryptjs": "^2.4.3", "grant-koa": "5.4.8", diff --git a/yarn.lock b/yarn.lock index f9ab096099..f803392174 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1043,15 +1043,15 @@ resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== -"@buffetjs/core@3.3.2-next.2": - version "3.3.2-next.2" - resolved "https://registry.yarnpkg.com/@buffetjs/core/-/core-3.3.2-next.2.tgz#440494812416e459abe07074fceb9207f4da9223" - integrity sha512-JyUBypuy4i6+sb2qki/bija2m3xEaucHdSEFFvDVtAKKicDZ70wrEbN09eGDGms27GKBJhdMSXLzs5ywGaFmgw== +"@buffetjs/core@3.3.3-next.0": + version "3.3.3-next.0" + resolved "https://registry.yarnpkg.com/@buffetjs/core/-/core-3.3.3-next.0.tgz#e589e4cf2c92dfab42b62a94ccde3310a094bea3" + integrity sha512-hekBFEEzevTlCJGnmiLQNpvmzGKXeawahYN/qzFGU1RjSZLV608G8qQmPArGcoHloJ2qfG6aN/TdGqTSC+l4eQ== dependencies: - "@buffetjs/hooks" "3.3.2-next.2" - "@buffetjs/icons" "3.3.2-next.2" - "@buffetjs/styles" "3.3.2-next.2" - "@buffetjs/utils" "3.3.2-next.2" + "@buffetjs/hooks" "3.3.3-next.0" + "@buffetjs/icons" "3.3.3-next.0" + "@buffetjs/styles" "3.3.3-next.0" + "@buffetjs/utils" "3.3.3-next.0" "@fortawesome/fontawesome-svg-core" "^1.2.25" "@fortawesome/free-regular-svg-icons" "^5.11.2" "@fortawesome/free-solid-svg-icons" "^5.11.2" @@ -1067,35 +1067,35 @@ react-with-direction "^1.3.1" reactstrap "^8.5.1" -"@buffetjs/custom@3.3.2-next.2": - version "3.3.2-next.2" - resolved "https://registry.yarnpkg.com/@buffetjs/custom/-/custom-3.3.2-next.2.tgz#9a1db1ad2875c40ed338f529760989fb6b20f121" - integrity sha512-cFxuThd7cKwBXC7Xy0GPZlrCCCML4I7ElhJ0aM8gFQ5NsJM+LSwsV4R8mzEH7frKRloxasF26FELsTFDfJg+0A== +"@buffetjs/custom@3.3.3-next.0": + version "3.3.3-next.0" + resolved "https://registry.yarnpkg.com/@buffetjs/custom/-/custom-3.3.3-next.0.tgz#fd5b50b8674fced2f8e6af5552974f5a9e13995b" + integrity sha512-B4ZQvvBGBwEPnrKVkjxeZGwhp+JlBcEuQ1qXPOZxaMBk2m7vCUkWUTdH9txvlWQnDerfCVsmwLRKH79LZc7zZw== dependencies: - "@buffetjs/core" "3.3.2-next.2" - "@buffetjs/styles" "3.3.2-next.2" - "@buffetjs/utils" "3.3.2-next.2" + "@buffetjs/core" "3.3.3-next.0" + "@buffetjs/styles" "3.3.3-next.0" + "@buffetjs/utils" "3.3.3-next.0" lodash "4.17.19" moment "^2.24.0" prop-types "^15.5.10" react-moment-proptypes "^1.7.0" -"@buffetjs/hooks@3.3.2-next.2": - version "3.3.2-next.2" - resolved "https://registry.yarnpkg.com/@buffetjs/hooks/-/hooks-3.3.2-next.2.tgz#a1b630338f394fd2585fee04575c0f355e787cca" - integrity sha512-h9wbjriwcF16qgro4VBYYvompOiVsn9gOStAoZomfexGlJEfaqp3fzTFs3g0Mpx4bjgZVLrD5Lu2tZVFD6MNYQ== +"@buffetjs/hooks@3.3.3-next.0": + version "3.3.3-next.0" + resolved "https://registry.yarnpkg.com/@buffetjs/hooks/-/hooks-3.3.3-next.0.tgz#dd1ef1f53ebbef165426389f1d30171063f71332" + integrity sha512-1ATXkDub/UOt+jNmJ/cHm/4WU/mV3futltB9g1CMb+abkQ+KMEMQQkSESjgs/JOdjnsd4AYwFXVA06Yplf0tUA== -"@buffetjs/icons@3.3.2-next.2": - version "3.3.2-next.2" - resolved "https://registry.yarnpkg.com/@buffetjs/icons/-/icons-3.3.2-next.2.tgz#ad52c58a42a2dd354014e57fe33f889809118392" - integrity sha512-agWYLovmWgl61tU+zpTqJGU5hNGmeYkeeKA9j9ZeSgGcjPHTQKRGZdQ2WPXvabiuDvoJqLM1NmklYcGdKbIUHA== +"@buffetjs/icons@3.3.3-next.0": + version "3.3.3-next.0" + resolved "https://registry.yarnpkg.com/@buffetjs/icons/-/icons-3.3.3-next.0.tgz#9912faaba5c5d4cea5684d17ecfd38e58512a25b" + integrity sha512-DXpyrvI7gUa6lTtW73zaFJMj0nge08jEBT8K6fe5Lwv0wol+zfQgC0h+j9th1H8CSlyAuhZutYeMHCyBON+u9g== dependencies: prop-types "^15.5.10" -"@buffetjs/styles@3.3.2-next.2": - version "3.3.2-next.2" - resolved "https://registry.yarnpkg.com/@buffetjs/styles/-/styles-3.3.2-next.2.tgz#033d6d0c639eb71bd382e1a02e3812bfabdbd9a1" - integrity sha512-kY16rtx4OkvO0meigMC602cByodMVSKAIpZTWjvZdNqvEDAASap2nGEbTJXNayskrkPrBEED4tiAaEU3VtQgIg== +"@buffetjs/styles@3.3.3-next.0": + version "3.3.3-next.0" + resolved "https://registry.yarnpkg.com/@buffetjs/styles/-/styles-3.3.3-next.0.tgz#7f5e8434a3cc83fe70b2d6f20a573017e8d10843" + integrity sha512-qgnbmo6R36H5xL+vutkCHXvtEpMtXWD6RfvYqPjVnQ3hxizonvCNMT+CVc/vn3l3+/ZHKppwwlSp+p2opwDKzA== dependencies: "@fortawesome/fontawesome-free" "^5.12.0" "@fortawesome/fontawesome-svg-core" "^1.2.22" @@ -1105,10 +1105,10 @@ prop-types "^15.7.2" react-dates "^21.1.0" -"@buffetjs/utils@3.3.2-next.2": - version "3.3.2-next.2" - resolved "https://registry.yarnpkg.com/@buffetjs/utils/-/utils-3.3.2-next.2.tgz#0417432c444029a9a49f8ea8e72daaa89a68ab9c" - integrity sha512-eppigKnXLnKdiIN5fqyP3tsvvM+UilbbGPY2K919qfXUwOd8HjNsggkBr5CJ8JQE7WIDjDEBWi0PHFECKFvdsw== +"@buffetjs/utils@3.3.3-next.0": + version "3.3.3-next.0" + resolved "https://registry.yarnpkg.com/@buffetjs/utils/-/utils-3.3.3-next.0.tgz#f2d2cc89643260d1a9276c30f43e6e8412fad27e" + integrity sha512-fddzQTInoZRycG+4m02EJDcPBK9toEP26EWyJzJsYtlskh+hvmiiATLDTu8kFpXp49Q28T0iFtEZXTj5O73USg== dependencies: lodash "4.17.19" yup "^0.27.0"