diff --git a/.github/actions/check-pr-status/package.json b/.github/actions/check-pr-status/package.json index e8b8ea2a72e..c971ecc1ee3 100644 --- a/.github/actions/check-pr-status/package.json +++ b/.github/actions/check-pr-status/package.json @@ -1,6 +1,6 @@ { "name": "check-pr-status", - "version": "4.15.4", + "version": "4.15.5", "private": true, "license": "MIT", "main": "dist/index.js", diff --git a/.github/workflows/changeFreeze.yml b/.github/workflows/changeFreeze.yml index f5fef4724f6..0be4ec96e07 100644 --- a/.github/workflows/changeFreeze.yml +++ b/.github/workflows/changeFreeze.yml @@ -8,7 +8,7 @@ permissions: read-all jobs: check-ownership: - name: "Check if PR was created by a Strapi Team Member" + name: 'Check if PR was created by a Strapi Team Member' runs-on: ubuntu-latest outputs: isTeamMember: ${{ steps.get-user-teams-membership.outputs.isTeamMember }} @@ -20,7 +20,7 @@ jobs: team: team username: ${{ github.actor }} send-response: - name: "Alert user to change freeze" + name: 'Alert user to change freeze' runs-on: ubuntu-latest permissions: pull-requests: write diff --git a/.yarnrc.yml b/.yarnrc.yml index b2b02d20be7..286e2aa3a71 100644 --- a/.yarnrc.yml +++ b/.yarnrc.yml @@ -1,6 +1,6 @@ compressionLevel: mixed -defaultSemverRangePrefix: "" +defaultSemverRangePrefix: '' enableGlobalCache: true diff --git a/examples/getstarted/config/middlewares.js b/examples/getstarted/config/middlewares.js index d676d6382be..8904cd55c3f 100644 --- a/examples/getstarted/config/middlewares.js +++ b/examples/getstarted/config/middlewares.js @@ -3,11 +3,11 @@ const responseHandlers = require('./src/response-handlers'); module.exports = [ + 'strapi::logger', 'strapi::errors', 'strapi::security', 'strapi::cors', 'strapi::poweredBy', - 'strapi::logger', 'strapi::query', 'strapi::body', 'strapi::session', diff --git a/examples/getstarted/jsconfig.json b/examples/getstarted/jsconfig.json index 4ebd9272cf4..43e55dec515 100644 --- a/examples/getstarted/jsconfig.json +++ b/examples/getstarted/jsconfig.json @@ -1,5 +1,6 @@ { "compilerOptions": { + "jsx": "react", "moduleResolution": "nodenext", "target": "ES2021", "checkJs": true, diff --git a/examples/getstarted/package.json b/examples/getstarted/package.json index 08af4e0f61d..4bf1385a175 100644 --- a/examples/getstarted/package.json +++ b/examples/getstarted/package.json @@ -1,6 +1,6 @@ { "name": "getstarted", - "version": "4.15.4", + "version": "4.15.5", "private": true, "description": "A Strapi application.", "license": "SEE LICENSE IN LICENSE", @@ -14,16 +14,16 @@ }, "dependencies": { "@strapi/icons": "1.11.0", - "@strapi/plugin-color-picker": "4.15.4", - "@strapi/plugin-documentation": "4.15.4", - "@strapi/plugin-graphql": "4.15.4", - "@strapi/plugin-i18n": "4.15.4", - "@strapi/plugin-sentry": "4.15.4", - "@strapi/plugin-users-permissions": "4.15.4", - "@strapi/provider-email-mailgun": "4.15.4", - "@strapi/provider-upload-aws-s3": "4.15.4", - "@strapi/provider-upload-cloudinary": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/plugin-color-picker": "4.15.5", + "@strapi/plugin-documentation": "4.15.5", + "@strapi/plugin-graphql": "4.15.5", + "@strapi/plugin-i18n": "4.15.5", + "@strapi/plugin-sentry": "4.15.5", + "@strapi/plugin-users-permissions": "4.15.5", + "@strapi/provider-email-mailgun": "4.15.5", + "@strapi/provider-upload-aws-s3": "4.15.5", + "@strapi/provider-upload-cloudinary": "4.15.5", + "@strapi/strapi": "4.15.5", "better-sqlite3": "8.6.0", "lodash": "4.17.21", "mysql": "2.18.1", diff --git a/examples/getstarted/src/admin/app.js b/examples/getstarted/src/admin/app.js index 3acc1c2c166..78994130c70 100644 --- a/examples/getstarted/src/admin/app.js +++ b/examples/getstarted/src/admin/app.js @@ -1,8 +1,18 @@ +import React from 'react'; +import { Button } from '@strapi/design-system'; + const config = { locales: ['it', 'es', 'en'], }; -const bootstrap = () => { +const bootstrap = (app) => { console.log('I AM BOOTSTRAPPED'); + + app.injectContentManagerComponent('editView', 'right-links', { + name: 'PreviewButton', + Component: () => ( + + ), + }); }; export default { diff --git a/examples/kitchensink-ts/config/middlewares.ts b/examples/kitchensink-ts/config/middlewares.ts index 3ab20d955b5..829f5c04df0 100644 --- a/examples/kitchensink-ts/config/middlewares.ts +++ b/examples/kitchensink-ts/config/middlewares.ts @@ -1,9 +1,9 @@ export default [ + 'strapi::logger', 'strapi::errors', 'strapi::security', 'strapi::cors', 'strapi::poweredBy', - 'strapi::logger', 'strapi::query', 'strapi::body', 'strapi::session', diff --git a/examples/kitchensink-ts/package.json b/examples/kitchensink-ts/package.json index 653c61baa09..db7cb2d0208 100644 --- a/examples/kitchensink-ts/package.json +++ b/examples/kitchensink-ts/package.json @@ -1,6 +1,6 @@ { "name": "kitchensink-ts", - "version": "4.15.4", + "version": "4.15.5", "private": true, "description": "A Strapi application", "license": "MIT", @@ -14,9 +14,9 @@ "strapi": "strapi" }, "dependencies": { - "@strapi/plugin-i18n": "4.15.4", - "@strapi/plugin-users-permissions": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/plugin-i18n": "4.15.5", + "@strapi/plugin-users-permissions": "4.15.5", + "@strapi/strapi": "4.15.5", "better-sqlite3": "8.6.0", "react": "^18.2.0", "react-dom": "^18.2.0", diff --git a/examples/kitchensink/package.json b/examples/kitchensink/package.json index c61cc350eb6..547f4c7888b 100644 --- a/examples/kitchensink/package.json +++ b/examples/kitchensink/package.json @@ -1,6 +1,6 @@ { "name": "kitchensink", - "version": "4.15.4", + "version": "4.15.5", "private": true, "description": "A Strapi application.", "license": "SEE LICENSE IN LICENSE", @@ -13,10 +13,10 @@ "strapi": "strapi" }, "dependencies": { - "@strapi/provider-email-mailgun": "4.15.4", - "@strapi/provider-upload-aws-s3": "4.15.4", - "@strapi/provider-upload-cloudinary": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/provider-email-mailgun": "4.15.5", + "@strapi/provider-upload-aws-s3": "4.15.5", + "@strapi/provider-upload-cloudinary": "4.15.5", + "@strapi/strapi": "4.15.5", "lodash": "4.17.21", "mysql": "2.18.1", "mysql2": "3.6.0", diff --git a/lerna.json b/lerna.json index 06f115a5fd7..431a093febb 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "4.15.4", + "version": "4.15.5", "packages": ["packages/*", "examples/*"], "npmClient": "yarn", "useWorkspaces": true, diff --git a/packages/admin-test-utils/package.json b/packages/admin-test-utils/package.json index 1d1314168f7..6c014e8aeb9 100644 --- a/packages/admin-test-utils/package.json +++ b/packages/admin-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/admin-test-utils", - "version": "4.15.4", + "version": "4.15.5", "private": true, "description": "Test utilities for the Strapi administration panel", "license": "MIT", @@ -75,8 +75,8 @@ "@reduxjs/toolkit": "1.9.7", "@strapi/pack-up": "workspace:*", "@testing-library/jest-dom": "5.16.5", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "peerDependencies": { "@reduxjs/toolkit": "^1.9.7", diff --git a/packages/cli/create-strapi-app/package.json b/packages/cli/create-strapi-app/package.json index 81e2d7725d7..4c5d2c22c85 100644 --- a/packages/cli/create-strapi-app/package.json +++ b/packages/cli/create-strapi-app/package.json @@ -1,6 +1,6 @@ { "name": "create-strapi-app", - "version": "4.15.4", + "version": "4.15.5", "description": "Generate a new Strapi application.", "keywords": [ "create-strapi-app", @@ -44,14 +44,14 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/generate-new": "4.15.4", + "@strapi/generate-new": "4.15.5", "commander": "8.3.0", "inquirer": "8.2.5" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/cli/create-strapi-starter/package.json b/packages/cli/create-strapi-starter/package.json index 118817d1b97..44223c756a2 100644 --- a/packages/cli/create-strapi-starter/package.json +++ b/packages/cli/create-strapi-starter/package.json @@ -1,6 +1,6 @@ { "name": "create-strapi-starter", - "version": "4.15.4", + "version": "4.15.5", "description": "Generate a new Strapi application.", "keywords": [ "create-strapi-starter", @@ -44,7 +44,7 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/generate-new": "4.15.4", + "@strapi/generate-new": "4.15.5", "chalk": "4.1.2", "ci-info": "3.8.0", "commander": "8.3.0", @@ -54,9 +54,9 @@ "ora": "5.4.1" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/core/admin/_internal/node/build.ts b/packages/core/admin/_internal/node/build.ts index 3396dbeb429..7432a529353 100644 --- a/packages/core/admin/_internal/node/build.ts +++ b/packages/core/admin/_internal/node/build.ts @@ -1,13 +1,11 @@ +import type { CLIContext } from '@strapi/strapi'; +import EE from '@strapi/strapi/dist/utils/ee'; import * as tsUtils from '@strapi/typescript-utils'; import { checkRequiredDependencies } from './core/dependencies'; +import { getTimer, prettyTime } from './core/timer'; +import { createBuildContext } from './createBuildContext'; import { writeStaticClientFiles } from './staticFiles'; import { build as buildWebpack } from './webpack/build'; -import { createBuildContext } from './createBuildContext'; - -import EE from '@strapi/strapi/dist/utils/ee'; -import { getTimer } from './core/timer'; - -import type { CLIContext } from '@strapi/strapi'; interface BuildOptions extends CLIContext { /** @@ -56,7 +54,7 @@ const build = async ({ logger, cwd, tsconfig, ignorePrompts, ...options }: Build tsUtils.compile(cwd, { configOptions: { ignoreDiagnostics: false } }); const compilingDuration = timer.end('compilingTS'); - compilingTsSpinner.text = `Compiling TS (${compilingDuration}ms)`; + compilingTsSpinner.text = `Compiling TS (${prettyTime(compilingDuration)})`; compilingTsSpinner.succeed(); } @@ -71,7 +69,7 @@ const build = async ({ logger, cwd, tsconfig, ignorePrompts, ...options }: Build options, }); const contextDuration = timer.end('createBuildContext'); - contextSpinner.text = `Building build context (${contextDuration}ms)`; + contextSpinner.text = `Building build context (${prettyTime(contextDuration)})`; contextSpinner.succeed(); timer.start('buildAdmin'); @@ -85,7 +83,7 @@ const build = async ({ logger, cwd, tsconfig, ignorePrompts, ...options }: Build await buildWebpack(ctx); const buildDuration = timer.end('buildAdmin'); - buildingSpinner.text = `Building admin panel (${buildDuration}ms)`; + buildingSpinner.text = `Building admin panel (${prettyTime(buildDuration)})`; buildingSpinner.succeed(); } catch (err) { buildingSpinner.fail(); diff --git a/packages/core/admin/_internal/node/core/admin-customisations.ts b/packages/core/admin/_internal/node/core/admin-customisations.ts index 6e8612c6b1d..cae6af48534 100644 --- a/packages/core/admin/_internal/node/core/admin-customisations.ts +++ b/packages/core/admin/_internal/node/core/admin-customisations.ts @@ -1,5 +1,6 @@ import path from 'node:path'; -import { loadFile } from './files'; +import { convertSystemPathToModulePath, pathExists } from '../core/files'; +import { BuildContext } from '../createBuildContext'; const ADMIN_APP_FILES = ['app.js', 'app.mjs', 'app.ts', 'app.jsx', 'app.tsx']; @@ -11,17 +12,28 @@ interface AdminCustomisations { } interface AppFile { + /** + * The system path to the file + */ path: string; - config: AdminCustomisations['config']; + /** + * The module path to the file i.e. how you would import it + */ + modulePath: string; } -const loadUserAppFile = async (appDir: string): Promise => { +const loadUserAppFile = async ({ + runtimeDir, + appDir, +}: Pick): Promise => { for (const file of ADMIN_APP_FILES) { const filePath = path.join(appDir, 'src', 'admin', file); - const configFile = await loadFile(filePath); - if (configFile) { - return { path: filePath, config: configFile }; + if (await pathExists(filePath)) { + return { + path: filePath, + modulePath: convertSystemPathToModulePath(path.relative(runtimeDir, filePath)), + }; } } diff --git a/packages/core/admin/_internal/node/core/files.ts b/packages/core/admin/_internal/node/core/files.ts index 644f1afd7e8..aaa83f1acee 100644 --- a/packages/core/admin/_internal/node/core/files.ts +++ b/packages/core/admin/_internal/node/core/files.ts @@ -1,3 +1,4 @@ +import path from 'node:path'; import { access } from 'node:fs/promises'; import { register } from 'esbuild-register/dist/node'; @@ -18,7 +19,9 @@ const pathExists = async (path: string) => { */ const loadFile = async (path: string): Promise => { if (await pathExists(path)) { - const esbuildOptions = { extensions: ['.js', '.mjs', '.ts'] }; + const esbuildOptions: Parameters[0] = { + extensions: ['.js', '.mjs', '.ts'], + }; const { unregister } = register(esbuildOptions); @@ -38,4 +41,34 @@ const loadFile = async (path: string): Promise => { return undefined; }; -export { pathExists, loadFile }; +/** + * @internal + * + * @description Converts a system path to a module path mainly for `Windows` systems. + * where the path separator is `\` instead of `/`, on linux systems the path separator + * is identical to the module path separator. + */ +const convertSystemPathToModulePath = (sysPath: string) => { + if (process.platform === 'win32') { + return sysPath.split(path.sep).join(path.posix.sep); + } else { + return sysPath; + } +}; + +/** + * @internal + * + * @description Converts a module path to a system path, again largely used for Windows systems. + * The original use case was plugins where the resolve path was in module format but we want to + * have it relative to the runtime directory. + */ +const convertModulePathToSystemPath = (modulePath: string) => { + if (process.platform === 'win32') { + return modulePath.split(path.posix.sep).join(path.sep); + } else { + return modulePath; + } +}; + +export { pathExists, loadFile, convertSystemPathToModulePath, convertModulePathToSystemPath }; diff --git a/packages/core/admin/_internal/node/core/plugins.ts b/packages/core/admin/_internal/node/core/plugins.ts index f71459df2fb..6ab16563cd0 100644 --- a/packages/core/admin/_internal/node/core/plugins.ts +++ b/packages/core/admin/_internal/node/core/plugins.ts @@ -4,16 +4,51 @@ import fs from 'node:fs'; import camelCase from 'lodash/camelCase'; import { env } from '@strapi/utils'; import { getModule, PackageJson } from './dependencies'; -import { loadFile } from './files'; +import { convertModulePathToSystemPath, convertSystemPathToModulePath, loadFile } from './files'; import { BuildContext } from '../createBuildContext'; import { isError } from './errors'; -interface PluginMeta { +interface LocalPluginMeta { name: string; - pathToPlugin: string; - isLocal?: boolean; + /** + * camelCased version of the plugin name + */ + importName: string; + /** + * The path to the plugin, relative to the app's root directory + * in system format + */ + path: string; + /** + * The path to the plugin, relative to the runtime directory + * in module format (i.e. with forward slashes) because thats + * where it should be used as an import + */ + modulePath: string; + type: 'local'; +} + +interface ModulePluginMeta { + name: string; + /** + * camelCased version of the plugin name + */ + importName: string; + /** + * Modules don't have a path because we never resolve them to their node_modules + * because we simply do not require it. + */ + path?: never; + /** + * The path to the plugin, relative to the app's root directory + * in module format (i.e. with forward slashes) + */ + modulePath: string; + type: 'module'; } +type PluginMeta = LocalPluginMeta | ModulePluginMeta; + interface StrapiPlugin extends PackageJson { strapi: { description?: string; @@ -36,10 +71,13 @@ const validatePackageIsPlugin = (pkg: PackageJson): pkg is StrapiPlugin => validatePackageHasStrapi(pkg) && pkg.strapi.kind === 'plugin'; const getEnabledPlugins = async ({ - strapi, cwd, logger, -}: Pick): Promise> => { + runtimeDir, + strapi, +}: Pick): Promise< + Record +> => { const plugins: Record = {}; /** @@ -68,7 +106,9 @@ const getEnabledPlugins = async ({ plugins[name] = { name, - pathToPlugin: dep, + importName: camelCase(name), + type: 'module', + modulePath: dep, }; } } @@ -79,14 +119,17 @@ const getEnabledPlugins = async ({ for (const [userPluginName, userPluginConfig] of Object.entries(userPluginsFile)) { if (userPluginConfig.enabled && userPluginConfig.resolve) { + const sysPath = convertModulePathToSystemPath(userPluginConfig.resolve); plugins[userPluginName] = { name: userPluginName, - isLocal: true, + importName: camelCase(userPluginName), + type: 'local', /** * User plugin paths are resolved from the entry point * of the app, because that's how you import them. */ - pathToPlugin: userPluginConfig.resolve, + modulePath: convertSystemPathToModulePath(path.relative(runtimeDir, sysPath)), + path: sysPath, }; } } @@ -114,10 +157,7 @@ const loadUserPluginsFile = async (root: string): Promise return {}; }; -const getMapOfPluginsWithAdmin = ( - plugins: Record, - { runtimeDir }: { runtimeDir: string } -) => +const getMapOfPluginsWithAdmin = (plugins: Record) => Object.values(plugins) .filter((plugin) => { if (!plugin) { @@ -128,7 +168,7 @@ const getMapOfPluginsWithAdmin = ( * There are two ways a plugin should be imported, either it's local to the strapi app, * or it's an actual npm module that's installed and resolved via node_modules. * - * We first check if the plugin is local to the strapi app, using a regular `resolve` because + * We first check if the plugin is local to the strapi app, using a regular `fs.existsSync` because * the pathToPlugin will be relative i.e. `/Users/my-name/strapi-app/src/plugins/my-plugin`. * * If the file doesn't exist well then it's probably a node_module, so instead we use `require.resolve` @@ -136,20 +176,11 @@ const getMapOfPluginsWithAdmin = ( * then it doesn't have an admin part to the package. */ try { - const isLocalPluginWithLegacyAdminFile = fs.existsSync( - //@ts-ignore - path.resolve(`${plugin.pathToPlugin}/strapi-admin.js`) - ); + const isLocalPluginWithLegacyAdminFile = + plugin.path && fs.existsSync(path.join(plugin.path, 'strapi-admin.js')); if (!isLocalPluginWithLegacyAdminFile) { - //@ts-ignore - let pathToPlugin = plugin.pathToPlugin; - - if (process.platform === 'win32') { - pathToPlugin = pathToPlugin.split(path.sep).join(path.posix.sep); - } - - const isModuleWithFE = require.resolve(`${pathToPlugin}/strapi-admin`); + const isModuleWithFE = require.resolve(`${plugin.modulePath}/strapi-admin`); return isModuleWithFE; } @@ -167,19 +198,10 @@ const getMapOfPluginsWithAdmin = ( throw err; } }) - .map((plugin) => { - const systemPath = plugin.isLocal - ? path.relative(runtimeDir, plugin.pathToPlugin.split('/').join(path.sep)) - : undefined; - const modulePath = systemPath ? systemPath.split(path.sep).join('/') : undefined; - - return { - path: !plugin.isLocal - ? `${plugin.pathToPlugin}/strapi-admin` - : `${modulePath}/strapi-admin`, - name: plugin.name, - importName: camelCase(plugin.name), - }; - }); + .map((plugin) => ({ + ...plugin, + modulePath: `${plugin.modulePath}/strapi-admin`, + })); export { getEnabledPlugins, getMapOfPluginsWithAdmin }; +export type { PluginMeta, LocalPluginMeta, ModulePluginMeta }; diff --git a/packages/core/admin/_internal/node/core/timer.ts b/packages/core/admin/_internal/node/core/timer.ts index 51218db607f..c55a2b5148a 100644 --- a/packages/core/admin/_internal/node/core/timer.ts +++ b/packages/core/admin/_internal/node/core/timer.ts @@ -29,3 +29,7 @@ export function getTimer(): TimeMeasurer { return { start, end, getTimings: () => timings }; } + +export const prettyTime = (timeInMs: number): string => { + return Math.ceil(timeInMs) + 'ms'; +}; diff --git a/packages/core/admin/_internal/node/createBuildContext.ts b/packages/core/admin/_internal/node/createBuildContext.ts index cc6130d59fc..e2a602a276c 100644 --- a/packages/core/admin/_internal/node/createBuildContext.ts +++ b/packages/core/admin/_internal/node/createBuildContext.ts @@ -9,7 +9,7 @@ import { getStrapiAdminEnvVars, loadEnv } from './core/env'; import type { BuildOptions } from './build'; import { DevelopOptions } from './develop'; -import { getEnabledPlugins, getMapOfPluginsWithAdmin } from './core/plugins'; +import { PluginMeta, getEnabledPlugins, getMapOfPluginsWithAdmin } from './core/plugins'; import { Strapi } from '@strapi/types'; import { AppFile, loadUserAppFile } from './core/admin-customisations'; @@ -56,11 +56,7 @@ interface BuildContext { * The plugins to be included in the JS bundle * incl. internal plugins, third party plugins & local plugins */ - plugins: Array<{ - path: string; - name: string; - importName: string; - }>; + plugins: PluginMeta[]; /** * The absolute path to the runtime directory */ @@ -113,6 +109,8 @@ const createBuildContext = async ({ const { serverUrl, adminPath } = getConfigUrls(strapiInstance.config, true); + const appDir = strapiInstance.dirs.app.root; + await loadEnv(cwd); const env = getStrapiAdminEnvVars({ @@ -150,20 +148,20 @@ const createBuildContext = async ({ const runtimeDir = path.join(cwd, '.strapi', 'client'); const entry = path.relative(cwd, path.join(runtimeDir, 'app.js')); - const plugins = await getEnabledPlugins({ cwd, logger, strapi: strapiInstance }); + const plugins = await getEnabledPlugins({ cwd, logger, runtimeDir, strapi: strapiInstance }); logger.debug('Enabled plugins', os.EOL, plugins); - const pluginsWithFront = getMapOfPluginsWithAdmin(plugins, { runtimeDir }); + const pluginsWithFront = getMapOfPluginsWithAdmin(plugins); logger.debug('Enabled plugins with FE', os.EOL, plugins); const target = browserslist.loadConfig({ path: cwd }) ?? DEFAULT_BROWSERSLIST; - const customisations = await loadUserAppFile(strapiInstance.dirs.app.root); + const customisations = await loadUserAppFile({ appDir, runtimeDir }); const buildContext = { - appDir: strapiInstance.dirs.app.root, + appDir, basePath: `${adminPath}/`, customisations, cwd, diff --git a/packages/core/admin/_internal/node/develop.ts b/packages/core/admin/_internal/node/develop.ts index 3d274790819..58ff11cc721 100644 --- a/packages/core/admin/_internal/node/develop.ts +++ b/packages/core/admin/_internal/node/develop.ts @@ -2,17 +2,20 @@ import type { CLIContext } from '@strapi/strapi'; import * as tsUtils from '@strapi/typescript-utils'; import { joinBy } from '@strapi/utils'; import chokidar from 'chokidar'; +import fs from 'node:fs/promises'; +import path from 'node:path'; + import cluster from 'node:cluster'; -import { getTimer } from './core/timer'; import { checkRequiredDependencies } from './core/dependencies'; +import { getTimer, prettyTime, type TimeMeasurer } from './core/timer'; import { createBuildContext } from './createBuildContext'; -import { WebpackWatcher, watch as watchWebpack } from './webpack/watch'; import { build as buildWebpack } from './webpack/build'; +import { watch as watchWebpack, WebpackWatcher } from './webpack/watch'; +import strapiFactory from '@strapi/strapi'; import EE from '@strapi/strapi/dist/utils/ee'; import { writeStaticClientFiles } from './staticFiles'; -import strapiFactory from '@strapi/strapi'; interface DevelopOptions extends CLIContext { /** @@ -24,6 +27,48 @@ interface DevelopOptions extends CLIContext { watchAdmin?: boolean; } +// This method removes all non-admin build files from the dist directory +const cleanupDistDirectory = async ({ + tsconfig, + logger, + timer, +}: Pick & { timer: TimeMeasurer }) => { + const distDir = tsconfig?.config?.options?.outDir; + + if ( + !distDir || // we don't have a dist dir + (await fs + .access(distDir) + .then(() => false) + .catch(() => true)) // it doesn't exist -- if it does but no access, that will be caught later + ) { + return; + } + + const timerName = 'cleaningDist' + Date.now(); + timer.start(timerName); + const cleaningSpinner = logger.spinner(`Cleaning dist dir ${distDir}`).start(); + + try { + const dirContent = await fs.readdir(distDir); + const validFilenames = dirContent + // Ignore the admin build folder + .filter((filename) => filename !== 'build'); + for (const filename of validFilenames) { + await fs.rm(path.resolve(distDir, filename), { recursive: true }); + } + } catch (err: unknown) { + const generatingDuration = timer.end(timerName); + cleaningSpinner.text = `Error cleaning dist dir: ${err} (${prettyTime(generatingDuration)})`; + cleaningSpinner?.fail(); + return; + } + + const generatingDuration = timer.end(timerName); + cleaningSpinner.text = `Cleaning dist dir (${prettyTime(generatingDuration)})`; + cleaningSpinner?.succeed(); +}; + const develop = async ({ cwd, polling, @@ -47,6 +92,12 @@ const develop = async ({ return; } + if (tsconfig?.config) { + // Build without diagnostics in case schemas have changed + await cleanupDistDirectory({ tsconfig, logger, timer }); + await tsUtils.compile(cwd, { configOptions: { ignoreDiagnostics: true } }); + } + /** * IF we're not watching the admin we're going to build it, this makes * sure that at least the admin is built for users & they can interact @@ -64,7 +115,7 @@ const develop = async ({ options, }); const contextDuration = timer.end('createBuildContext'); - contextSpinner.text = `Building build context (${contextDuration}ms)`; + contextSpinner.text = `Building build context (${prettyTime(contextDuration)})`; contextSpinner.succeed(); timer.start('creatingAdmin'); @@ -75,13 +126,18 @@ const develop = async ({ await buildWebpack(ctx); const adminDuration = timer.end('creatingAdmin'); - adminSpinner.text = `Creating admin (${adminDuration}ms)`; + adminSpinner.text = `Creating admin (${prettyTime(adminDuration)})`; adminSpinner.succeed(); } cluster.on('message', async (worker, message) => { switch (message) { case 'reload': { + if (tsconfig?.config) { + // Build without diagnostics in case schemas have changed + await cleanupDistDirectory({ tsconfig, logger, timer }); + await tsUtils.compile(cwd, { configOptions: { ignoreDiagnostics: true } }); + } logger.debug('cluster has the reload message, sending the worker kill message'); worker.send('kill'); break; @@ -104,16 +160,8 @@ const develop = async ({ } if (cluster.isWorker) { - if (tsconfig?.config) { - timer.start('compilingTS'); - const compilingTsSpinner = logger.spinner(`Compiling TS`).start(); - - tsUtils.compile(cwd, { configOptions: { ignoreDiagnostics: false } }); - - const compilingDuration = timer.end('compilingTS'); - compilingTsSpinner.text = `Compiling TS (${compilingDuration}ms)`; - compilingTsSpinner.succeed(); - } + timer.start('loadStrapi'); + const loadStrapiSpinner = logger.spinner(`Loading Strapi`).start(); const strapi = strapiFactory({ appDir: cwd, @@ -121,7 +169,6 @@ const develop = async ({ autoReload: true, serveAdminPanel: !watchAdmin, }); - let webpackWatcher: WebpackWatcher | undefined; /** @@ -141,7 +188,7 @@ const develop = async ({ options, }); const contextDuration = timer.end('createBuildContext'); - contextSpinner.text = `Building build context (${contextDuration}ms)`; + contextSpinner.text = `Building build context (${prettyTime(contextDuration)})`; contextSpinner.succeed(); timer.start('creatingAdmin'); @@ -152,12 +199,16 @@ const develop = async ({ webpackWatcher = await watchWebpack(ctx); const adminDuration = timer.end('creatingAdmin'); - adminSpinner.text = `Creating admin (${adminDuration}ms)`; + adminSpinner.text = `Creating admin (${prettyTime(adminDuration)})`; adminSpinner.succeed(); } const strapiInstance = await strapi.load(); + const loadStrapiDuration = timer.end('loadStrapi'); + loadStrapiSpinner.text = `Loading Strapi (${prettyTime(loadStrapiDuration)})`; + loadStrapiSpinner.succeed(); + timer.start('generatingTS'); const generatingTsSpinner = logger.spinner(`Generating types`).start(); @@ -170,9 +221,21 @@ const develop = async ({ }); const generatingDuration = timer.end('generatingTS'); - generatingTsSpinner.text = `Generating types (${generatingDuration}ms)`; + generatingTsSpinner.text = `Generating types (${prettyTime(generatingDuration)})`; generatingTsSpinner.succeed(); + if (tsconfig?.config) { + timer.start('compilingTS'); + const compilingTsSpinner = logger.spinner(`Compiling TS`).start(); + + await cleanupDistDirectory({ tsconfig, logger, timer }); + await tsUtils.compile(cwd, { configOptions: { ignoreDiagnostics: false } }); + + const compilingDuration = timer.end('compilingTS'); + compilingTsSpinner.text = `Compiling TS (${prettyTime(compilingDuration)})`; + compilingTsSpinner.succeed(); + } + const restart = async () => { if (strapiInstance.reload.isWatching && !strapiInstance.reload.isReloading) { strapiInstance.reload.isReloading = true; diff --git a/packages/core/admin/_internal/node/staticFiles.ts b/packages/core/admin/_internal/node/staticFiles.ts index 914e7725bf8..fbc19338c49 100644 --- a/packages/core/admin/_internal/node/staticFiles.ts +++ b/packages/core/admin/_internal/node/staticFiles.ts @@ -4,6 +4,7 @@ import outdent from 'outdent'; import { format } from 'prettier'; import { createElement } from 'react'; import { renderToStaticMarkup } from 'react-dom/server'; +import camelCase from 'lodash/camelCase'; import { DefaultDocument as Document } from '../../admin/src/components/DefaultDocument'; import type { BuildContext } from './createBuildContext'; @@ -14,7 +15,7 @@ const getEntryModule = (ctx: BuildContext): string => { .join(',\n'); const pluginsImport = ctx.plugins - .map(({ importName, path }) => `import ${importName} from '${path}';`) + .map(({ importName, modulePath }) => `import ${importName} from '${modulePath}';`) .join('\n'); return outdent` @@ -24,20 +25,17 @@ const getEntryModule = (ctx: BuildContext): string => { */ ${pluginsImport} import { renderAdmin } from "@strapi/strapi/admin" - + ${ - ctx.customisations?.path - ? `import customisations from '${path.relative( - ctx.runtimeDir, - ctx.customisations.path - )}'` + ctx.customisations?.modulePath + ? `import customisations from '${ctx.customisations.modulePath}'` : '' } - + renderAdmin( document.getElementById("strapi"), { - ${ctx.customisations?.path ? 'customisations,' : ''} + ${ctx.customisations?.modulePath ? 'customisations,' : ''} plugins: { ${pluginsObject} } diff --git a/packages/core/admin/admin/src/pages/ProfilePage.tsx b/packages/core/admin/admin/src/pages/ProfilePage.tsx index 74b03140534..6eb97b8c59d 100644 --- a/packages/core/admin/admin/src/pages/ProfilePage.tsx +++ b/packages/core/admin/admin/src/pages/ProfilePage.tsx @@ -120,7 +120,7 @@ const ProfilePage = () => { const isLoading = isLoadingUser || isLoadingSSO; - type UpdateUsersMeBody = Omit & { + type UpdateUsersMeBody = UpdateMe.Request['body'] & { confirmPassword: string; currentTheme: ThemeName; }; @@ -131,7 +131,26 @@ const ProfilePage = () => { UpdateUsersMeBody >( async (body) => { - const { confirmPassword: _confirmPassword, currentTheme, ...dataToSend } = body; + const { confirmPassword: _confirmPassword, currentTheme, ...bodyRest } = body; + let dataToSend = bodyRest; + + const isPasswordRequestBody = ( + data: UpdateMe.Request['body'] + ): data is UpdateMe.PasswordRequestBody => { + return 'password' in data; + }; + + // The password fields are optional. If the user didn't touch them, don't send any password + // to the API, because an empty string would throw a validation error + if (isPasswordRequestBody(dataToSend) && dataToSend.password === '') { + const { + password: _password, + currentPassword: _currentPassword, + ...passwordRequestBodyRest + } = dataToSend; + dataToSend = passwordRequestBodyRest; + } + const { data } = await put('/admin/users/me', dataToSend); return { ...data.data, currentTheme }; @@ -254,8 +273,7 @@ const ProfilePage = () => { username, preferedLanguage, currentTheme, - password, - confirmPassword, + ...passwordValues }, handleChange, isSubmitting, @@ -293,7 +311,7 @@ const ProfilePage = () => { )} { * -----------------------------------------------------------------------------------------------*/ interface PasswordSectionProps { - errors: { password?: string; confirmPassword?: string }; + errors: { currentPassword?: string; password?: string; confirmPassword?: string }; onChange: React.ChangeEventHandler; values: { + currentPassword?: string; password?: string; confirmPassword?: string; }; @@ -331,6 +350,7 @@ interface PasswordSectionProps { const PasswordSection = ({ errors, onChange, values }: PasswordSectionProps) => { const { formatMessage } = useIntl(); + const [currentPasswordShown, setCurrentPasswordShown] = React.useState(false); const [passwordShown, setPasswordShown] = React.useState(false); const [passwordConfirmShown, setPasswordConfirmShown] = React.useState(false); @@ -351,6 +371,49 @@ const PasswordSection = ({ errors, onChange, values }: PasswordSectionProps) => defaultMessage: 'Change password', })} + + + { + e.stopPropagation(); + setCurrentPasswordShown((prev) => !prev); + }} + label={formatMessage( + currentPasswordShown + ? { + id: 'Auth.form.password.show-password', + defaultMessage: 'Show password', + } + : { + id: 'Auth.form.password.hide-password', + defaultMessage: 'Hide password', + } + )} + > + {currentPasswordShown ? : } + + } + /> + + value={values.confirmPassword} label={formatMessage({ id: 'Auth.form.confirmPassword.label', - defaultMessage: 'Password confirmation', + defaultMessage: 'Confirm Password', })} name="confirmPassword" type={passwordConfirmShown ? 'text' : 'password'} diff --git a/packages/core/admin/admin/src/pages/tests/ProfilePage.test.tsx b/packages/core/admin/admin/src/pages/tests/ProfilePage.test.tsx index c4f1ca62b88..8bd8e284926 100644 --- a/packages/core/admin/admin/src/pages/tests/ProfilePage.test.tsx +++ b/packages/core/admin/admin/src/pages/tests/ProfilePage.test.tsx @@ -28,7 +28,7 @@ describe('Profile page', () => { jest.clearAllMocks(); }); - it('renders and show the Interface Language section', async () => { + it('renders and shows the Interface Language section', async () => { const { getByText } = render(); await waitFor(() => { expect(getByText('Interface language')).toBeInTheDocument(); @@ -54,10 +54,9 @@ describe('Profile page', () => { name: 'Change password', }) ).toBeInTheDocument(); - - expect(getByLabelText('Password')).toBeInTheDocument(); - - expect(getByLabelText('Password confirmation')).toBeInTheDocument(); + expect(getByLabelText(/current password/i)).toBeInTheDocument(); + expect(getByLabelText(/^password$/i)).toBeInTheDocument(); + expect(getByLabelText(/confirm password/i)).toBeInTheDocument(); }); it('should not display the change password section and all the fields if the user role is Locked', async () => { @@ -84,9 +83,8 @@ describe('Profile page', () => { }); expect(changePasswordHeading).not.toBeInTheDocument(); - - expect(queryByLabelText('Password')).not.toBeInTheDocument(); - - expect(queryByLabelText('Password confirmation')).not.toBeInTheDocument(); + expect(queryByLabelText(/current password/i)).not.toBeInTheDocument(); + expect(queryByLabelText(/^password$/)).not.toBeInTheDocument(); + expect(queryByLabelText(/confirm password/i)).not.toBeInTheDocument(); }); }); diff --git a/packages/core/admin/package.json b/packages/core/admin/package.json index eb87b1dadd3..a93af0301bc 100644 --- a/packages/core/admin/package.json +++ b/packages/core/admin/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/admin", - "version": "4.15.4", + "version": "4.15.5", "description": "Strapi Admin", "repository": { "type": "git", @@ -75,15 +75,15 @@ "@radix-ui/react-context": "1.0.1", "@radix-ui/react-toolbar": "1.0.4", "@reduxjs/toolkit": "1.9.7", - "@strapi/data-transfer": "4.15.4", + "@strapi/data-transfer": "4.15.5", "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/permissions": "4.15.4", - "@strapi/provider-audit-logs-local": "4.15.4", - "@strapi/types": "4.15.4", - "@strapi/typescript-utils": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/permissions": "4.15.5", + "@strapi/provider-audit-logs-local": "4.15.5", + "@strapi/types": "4.15.5", + "@strapi/typescript-utils": "4.15.5", + "@strapi/utils": "4.15.5", "axios": "1.6.0", "bcryptjs": "2.4.3", "boxen": "5.1.2", @@ -172,9 +172,9 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/admin-test-utils": "4.15.4", - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/admin-test-utils": "4.15.5", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@testing-library/dom": "9.2.0", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", @@ -188,7 +188,7 @@ "vite": "4.4.9" }, "peerDependencies": { - "@strapi/data-transfer": "4.15.4", + "@strapi/data-transfer": "4.15.5", "@strapi/strapi": "^4.3.4", "react": "^17.0.0 || ^18.0.0", "react-dom": "^17.0.0 || ^18.0.0", diff --git a/packages/core/admin/shared/contracts/users.ts b/packages/core/admin/shared/contracts/users.ts index 268b9ad26f5..3f5691bdcf7 100644 --- a/packages/core/admin/shared/contracts/users.ts +++ b/packages/core/admin/shared/contracts/users.ts @@ -20,17 +20,22 @@ export declare namespace GetMe { * PUT /users/me - Update the current admin user */ export declare namespace UpdateMe { + export interface BaseRequestBody { + email?: string; + firstname?: string; + lastname?: string; + username?: string; + preferedLanguage?: string; + } + + export interface PasswordRequestBody extends BaseRequestBody { + currentPassword: string; + password: string; + } + export interface Request { query: {}; - body: { - email?: string; - firstname?: string; - lastname?: string; - username?: string; - password?: string; - currentPassword?: string; - preferedLanguage?: string; - }; + body: BaseRequestBody | PasswordRequestBody; } export interface Response { diff --git a/packages/core/content-manager/package.json b/packages/core/content-manager/package.json index 56d39b4c701..9760945f5c0 100644 --- a/packages/core/content-manager/package.json +++ b/packages/core/content-manager/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-content-manager", - "version": "4.15.4", + "version": "4.15.5", "description": "A powerful UI to easily manage your data.", "repository": { "type": "git", @@ -26,7 +26,7 @@ }, "dependencies": { "@sindresorhus/slugify": "1.1.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "lodash": "4.17.21", "qs": "6.11.1" }, diff --git a/packages/core/content-type-builder/admin/src/components/SelectComponents/index.js b/packages/core/content-type-builder/admin/src/components/SelectComponents/index.js index f6d70cd94d9..5b1f286a3f9 100644 --- a/packages/core/content-type-builder/admin/src/components/SelectComponents/index.js +++ b/packages/core/content-type-builder/admin/src/components/SelectComponents/index.js @@ -54,7 +54,7 @@ const SelectComponents = ({ dynamicZoneTarget, intlLabel, name, onChange, value defaultMessage: '{number, plural, =0 {# components} one {# component} other {# components}} selected', }, - { number: value.length } + { number: value?.length ?? 0 } ); return ( diff --git a/packages/core/content-type-builder/package.json b/packages/core/content-type-builder/package.json index b9e81ce1a37..c9433888a88 100644 --- a/packages/core/content-type-builder/package.json +++ b/packages/core/content-type-builder/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-content-type-builder", - "version": "4.15.4", + "version": "4.15.5", "description": "Strapi plugin to create content type", "repository": { "type": "git", @@ -49,10 +49,10 @@ "dependencies": { "@sindresorhus/slugify": "1.1.0", "@strapi/design-system": "1.13.1", - "@strapi/generators": "4.15.4", - "@strapi/helper-plugin": "4.15.4", + "@strapi/generators": "4.15.5", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "fs-extra": "10.0.0", "immer": "9.0.19", "lodash": "4.17.21", @@ -65,8 +65,8 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@testing-library/react": "14.0.0", "history": "^4.9.0", "react": "^18.2.0", diff --git a/packages/core/data-transfer/package.json b/packages/core/data-transfer/package.json index c0628ed7f48..5e1ca143adf 100644 --- a/packages/core/data-transfer/package.json +++ b/packages/core/data-transfer/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/data-transfer", - "version": "4.15.4", + "version": "4.15.5", "description": "Data transfer capabilities for Strapi", "keywords": [ "strapi", @@ -41,10 +41,10 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/logger": "4.15.4", - "@strapi/strapi": "4.15.4", - "@strapi/types": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/logger": "4.15.5", + "@strapi/strapi": "4.15.5", + "@strapi/types": "4.15.5", + "@strapi/utils": "4.15.5", "chalk": "4.1.2", "cli-table3": "0.6.2", "commander": "8.3.0", @@ -61,8 +61,8 @@ "ws": "8.13.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@types/fs-extra": "9.0.13", "@types/jest": "29.5.2", "@types/koa": "2.13.4", diff --git a/packages/core/database/package.json b/packages/core/database/package.json index d1bb207f2d0..a94bc85b347 100644 --- a/packages/core/database/package.json +++ b/packages/core/database/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/database", - "version": "4.15.4", + "version": "4.15.5", "description": "Strapi's database layer", "homepage": "https://strapi.io", "bugs": { @@ -40,7 +40,7 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "date-fns": "2.30.0", "debug": "4.3.4", "fs-extra": "10.0.0", @@ -50,9 +50,9 @@ "umzug": "3.2.1" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/core/email/package.json b/packages/core/email/package.json index 6c41a9acb19..7448f129fd7 100644 --- a/packages/core/email/package.json +++ b/packages/core/email/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-email", - "version": "4.15.4", + "version": "4.15.5", "description": "Easily configure your Strapi application to send emails.", "repository": { "type": "git", @@ -54,10 +54,10 @@ }, "dependencies": { "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/provider-email-sendmail": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/provider-email-sendmail": "4.15.5", + "@strapi/utils": "4.15.5", "lodash": "4.17.21", "prop-types": "^15.8.1", "react-intl": "6.4.1", @@ -65,8 +65,8 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/types": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/types": "4.15.5", "@testing-library/react": "14.0.0", "@types/koa": "2.13.4", "@types/lodash": "^4.14.191", diff --git a/packages/core/helper-plugin/package.json b/packages/core/helper-plugin/package.json index 9661583cbd6..1b9a0d586e9 100644 --- a/packages/core/helper-plugin/package.json +++ b/packages/core/helper-plugin/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/helper-plugin", - "version": "4.15.4", + "version": "4.15.5", "description": "Helper for Strapi plugins development", "repository": { "type": "git", @@ -69,11 +69,11 @@ "@storybook/addon-mdx-gfm": "7.4.0", "@storybook/builder-vite": "7.4.0", "@storybook/react-vite": "7.4.0", - "@strapi/admin-test-utils": "4.15.4", + "@strapi/admin-test-utils": "4.15.5", "@strapi/design-system": "1.13.1", "@strapi/icons": "1.13.0", - "@strapi/pack-up": "4.15.4", - "@strapi/types": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/types": "4.15.5", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", "@types/react": "18.2.7", @@ -82,7 +82,7 @@ "@types/react-router-dom": "5.3.3", "@types/styled-components": "5.1.26", "cross-env": "^7.0.3", - "eslint-config-custom": "4.15.4", + "eslint-config-custom": "4.15.5", "eslint-plugin-storybook": "0.6.14", "msw": "1.3.0", "react": "^18.2.0", diff --git a/packages/core/permissions/package.json b/packages/core/permissions/package.json index 254604022f1..4379ee4b71c 100644 --- a/packages/core/permissions/package.json +++ b/packages/core/permissions/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/permissions", - "version": "4.15.4", + "version": "4.15.5", "description": "Strapi's permission layer.", "repository": { "type": "git", @@ -38,15 +38,15 @@ }, "dependencies": { "@casl/ability": "6.5.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "lodash": "4.17.21", "qs": "6.11.1", "sift": "16.0.1" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/core/strapi/package.json b/packages/core/strapi/package.json index 16e8fdfc1e4..8efa558d30d 100644 --- a/packages/core/strapi/package.json +++ b/packages/core/strapi/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/strapi", - "version": "4.15.4", + "version": "4.15.5", "description": "An open source headless CMS solution to create and manage your own API. It provides a powerful dashboard and features to make your life easier. Databases supported: MySQL, MariaDB, PostgreSQL, SQLite", "keywords": [ "strapi", @@ -114,21 +114,21 @@ "dependencies": { "@koa/cors": "3.4.3", "@koa/router": "10.1.1", - "@strapi/admin": "4.15.4", - "@strapi/data-transfer": "4.15.4", - "@strapi/database": "4.15.4", - "@strapi/generate-new": "4.15.4", - "@strapi/generators": "4.15.4", - "@strapi/logger": "4.15.4", - "@strapi/pack-up": "4.15.4", - "@strapi/permissions": "4.15.4", - "@strapi/plugin-content-manager": "4.15.4", - "@strapi/plugin-content-type-builder": "4.15.4", - "@strapi/plugin-email": "4.15.4", - "@strapi/plugin-upload": "4.15.4", - "@strapi/types": "4.15.4", - "@strapi/typescript-utils": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/admin": "4.15.5", + "@strapi/data-transfer": "4.15.5", + "@strapi/database": "4.15.5", + "@strapi/generate-new": "4.15.5", + "@strapi/generators": "4.15.5", + "@strapi/logger": "4.15.5", + "@strapi/pack-up": "4.15.5", + "@strapi/permissions": "4.15.5", + "@strapi/plugin-content-manager": "4.15.5", + "@strapi/plugin-content-type-builder": "4.15.5", + "@strapi/plugin-email": "4.15.5", + "@strapi/plugin-upload": "4.15.5", + "@strapi/types": "4.15.5", + "@strapi/typescript-utils": "4.15.5", + "@strapi/utils": "4.15.5", "bcryptjs": "2.4.3", "boxen": "5.1.2", "chalk": "4.1.2", @@ -188,9 +188,9 @@ "@types/node": "18.18.4", "@types/node-schedule": "2.1.0", "@types/statuses": "2.0.1", - "eslint-config-custom": "4.15.4", + "eslint-config-custom": "4.15.5", "supertest": "6.3.3", - "tsconfig": "4.15.4" + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/core/strapi/src/services/server/register-middlewares.ts b/packages/core/strapi/src/services/server/register-middlewares.ts index b474f0ef673..f948ffcb23f 100644 --- a/packages/core/strapi/src/services/server/register-middlewares.ts +++ b/packages/core/strapi/src/services/server/register-middlewares.ts @@ -5,12 +5,12 @@ import { resolveMiddlewares } from './middleware'; type MiddlewareConfig = (string | { name?: string; resolve?: string; config?: unknown })[]; const defaultConfig = [ + 'strapi::logger', 'strapi::errors', 'strapi::security', 'strapi::cors', 'strapi::poweredBy', 'strapi::session', - 'strapi::logger', 'strapi::query', 'strapi::body', 'strapi::favicon', diff --git a/packages/core/types/package.json b/packages/core/types/package.json index 56c9bdc7cf6..6921890c24f 100644 --- a/packages/core/types/package.json +++ b/packages/core/types/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/types", - "version": "4.15.4", + "version": "4.15.5", "description": "Shared typescript types for Strapi internal use", "keywords": [ "strapi" @@ -46,10 +46,10 @@ "dependencies": { "@koa/cors": "3.4.3", "@koa/router": "10.1.1", - "@strapi/database": "4.15.4", - "@strapi/logger": "4.15.4", - "@strapi/permissions": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/database": "4.15.5", + "@strapi/logger": "4.15.5", + "@strapi/permissions": "4.15.5", + "@strapi/utils": "4.15.5", "commander": "8.3.0", "https-proxy-agent": "5.0.1", "koa": "2.13.4", @@ -57,14 +57,14 @@ "node-schedule": "2.1.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "@strapi/ts-zen": "^0.2.0", "@types/jest": "29.5.2", "@types/koa": "2.13.4", "@types/koa__router": "12.0.0", "@types/node-schedule": "2.1.0", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5", "typescript": "5.2.2" }, "engines": { diff --git a/packages/core/upload/package.json b/packages/core/upload/package.json index 3838d50fd88..548477d6011 100644 --- a/packages/core/upload/package.json +++ b/packages/core/upload/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-upload", - "version": "4.15.4", + "version": "4.15.5", "description": "Makes it easy to upload images and files to your Strapi Application.", "license": "SEE LICENSE IN LICENSE", "author": { @@ -44,10 +44,10 @@ }, "dependencies": { "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/provider-upload-local": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/provider-upload-local": "4.15.5", + "@strapi/utils": "4.15.5", "axios": "1.6.0", "byte-size": "7.0.1", "cropperjs": "1.6.0", @@ -71,8 +71,8 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@testing-library/dom": "9.2.0", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", diff --git a/packages/core/utils/package.json b/packages/core/utils/package.json index fb09e742803..1b300dfbc94 100644 --- a/packages/core/utils/package.json +++ b/packages/core/utils/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/utils", - "version": "4.15.4", + "version": "4.15.5", "description": "Shared utilities for the Strapi packages", "keywords": [ "strapi", @@ -53,13 +53,14 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/types": "4.15.5", "@types/koa": "2.13.4", "@types/node": "18.18.4", - "eslint-config-custom": "4.15.4", + "eslint-config-custom": "4.15.5", "koa": "2.13.4", "koa-body": "4.2.0", - "tsconfig": "4.15.4" + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/core/utils/src/__tests__/query-populate.test.ts b/packages/core/utils/src/__tests__/query-populate.test.ts new file mode 100644 index 00000000000..8e423b3c777 --- /dev/null +++ b/packages/core/utils/src/__tests__/query-populate.test.ts @@ -0,0 +1,265 @@ +import { traverseQueryPopulate } from '../traverse'; +import { setGlobalStrapi, getStrapiFactory } from './test-utils'; + +describe('traverseQueryPopulate', () => { + test('should return an empty object incase no populatable field exists', async () => { + const query = await traverseQueryPopulate(jest.fn(), { + schema: { + kind: 'collectionType', + attributes: { + title: { + type: 'string', + }, + }, + }, + })('*'); + + expect(query).toEqual({}); + }); + + test('should return all populatable fields', async () => { + const strapi = getStrapiFactory({ + getModel: jest.fn((uid) => { + return { + uid, + attributes: { + street: { + type: 'string', + }, + }, + }; + }), + db: { + metadata: { + get: jest.fn(() => ({ + columnToAttribute: { + address: 'address', + some: 'some', + }, + })), + }, + }, + })(); + + setGlobalStrapi(strapi); + + const query = await traverseQueryPopulate(jest.fn(), { + schema: { + kind: 'collectionType', + attributes: { + title: { + type: 'string', + }, + address: { + type: 'relation', + relation: 'oneToOne', + target: 'api::address.address', + }, + some: { + type: 'relation', + relation: 'ManyToMany', + target: 'api::some.some', + }, + }, + }, + })('*'); + + expect(query).toEqual({ address: true, some: true }); + }); + + test('should return only selected populatable field', async () => { + const strapi = getStrapiFactory({ + getModel: jest.fn((uid) => { + return { + uid, + attributes: { + street: { + type: 'string', + }, + }, + }; + }), + db: { + metadata: { + get: jest.fn(() => ({ + columnToAttribute: { + address: 'address', + }, + })), + }, + }, + })(); + + setGlobalStrapi(strapi); + + const query = await traverseQueryPopulate(jest.fn(), { + schema: { + kind: 'collectionType', + attributes: { + title: { + type: 'string', + }, + address: { + type: 'relation', + relation: 'oneToOne', + target: 'api::address.address', + }, + some: { + type: 'relation', + relation: 'ManyToMany', + target: 'api::some.some', + }, + }, + }, + })('address'); + + expect(query).toEqual('address'); + }); + + test('should populate dynamiczone', async () => { + const strapi = getStrapiFactory({ + getModel: jest.fn((uid) => { + return { + uid, + attributes: { + street: { + type: 'string', + }, + }, + }; + }), + db: { + metadata: { + get: jest.fn(() => ({ + columnToAttribute: { + address: 'address', + }, + })), + }, + }, + })(); + + setGlobalStrapi(strapi); + + const query = await traverseQueryPopulate(jest.fn(), { + schema: { + kind: 'collectionType', + attributes: { + title: { + type: 'string', + }, + address: { + type: 'relation', + relation: 'oneToOne', + target: 'api::address.address', + }, + some: { + type: 'relation', + relation: 'ManyToMany', + target: 'api::some.some', + }, + zone: { + type: 'dynamiczone', + components: ['blog.test-como', 'some.another-como'], + }, + }, + }, + })('*'); + + expect(query).toEqual({ + address: true, + some: true, + zone: true, + }); + }); + + test('should deep populate dynamiczone components', async () => { + const strapi = getStrapiFactory({ + getModel: jest.fn((uid) => { + if (uid === 'blog.test-como') { + return { + uid, + attributes: { + street: { + type: 'string', + }, + address: { + type: 'relation', + relation: 'oneToOne', + target: 'api::address.address', + }, + }, + }; + } + if (uid === 'some.another-como') { + return { + uid, + attributes: { + street: { + type: 'string', + }, + some: { + type: 'relation', + relation: 'ManyToMany', + target: 'api::some.some', + }, + }, + }; + } + return { + uid, + attributes: { + street: { + type: 'string', + }, + }, + }; + }), + db: { + metadata: { + get: jest.fn(() => ({ + columnToAttribute: { + address: 'address', + }, + })), + }, + }, + })(); + + setGlobalStrapi(strapi); + + const query = await traverseQueryPopulate(jest.fn(), { + schema: { + kind: 'collectionType', + attributes: { + title: { + type: 'string', + }, + address: { + type: 'relation', + relation: 'oneToOne', + target: 'api::address.address', + }, + some: { + type: 'relation', + relation: 'ManyToMany', + target: 'api::some.some', + }, + zone: { + type: 'dynamiczone', + components: ['blog.test-como', 'some.another-como'], + }, + }, + }, + })({ zone: { populate: '*' } }); + + expect(query).toEqual({ + zone: { + populate: { + address: true, + some: true, + }, + }, + }); + }); +}); diff --git a/packages/core/utils/src/__tests__/test-utils.ts b/packages/core/utils/src/__tests__/test-utils.ts new file mode 100644 index 00000000000..2a3c1e51f75 --- /dev/null +++ b/packages/core/utils/src/__tests__/test-utils.ts @@ -0,0 +1,24 @@ +import type { LoadedStrapi } from '@strapi/types'; + +/** + * Update the global store with the given strapi value + */ +export const setGlobalStrapi = (strapi: LoadedStrapi): void => { + (global as unknown as Global).strapi = strapi; +}; + +/** + * Create a "Strapi" like object factory based on the + * given params and cast it to the correct type + */ +export const getStrapiFactory = + < + T extends { + [key in keyof Partial]: unknown; + } + >( + properties?: T + ) => + (additionalProperties?: Partial) => { + return { ...properties, ...additionalProperties } as LoadedStrapi; + }; diff --git a/packages/core/utils/src/traverse/query-populate.ts b/packages/core/utils/src/traverse/query-populate.ts index a54f963ca85..7660fe24378 100644 --- a/packages/core/utils/src/traverse/query-populate.ts +++ b/packages/core/utils/src/traverse/query-populate.ts @@ -11,6 +11,7 @@ import { join, first, omit, + merge, } from 'lodash/fp'; import traverseFactory from './factory'; @@ -210,7 +211,9 @@ const populate = traverseFactory() for (const componentUID of components) { const componentSchema = strapi.getModel(componentUID); - newProperties = await recurse(visitor, { schema: componentSchema, path }, newProperties); + + const properties = await recurse(visitor, { schema: componentSchema, path }, value); + newProperties = merge(newProperties, properties); } Object.assign(newValue, newProperties); diff --git a/packages/generators/app/package.json b/packages/generators/app/package.json index 2e7afe714db..0243b7b6a7d 100644 --- a/packages/generators/app/package.json +++ b/packages/generators/app/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/generate-new", - "version": "4.15.4", + "version": "4.15.5", "description": "Generate a new Strapi application.", "keywords": [ "generate", @@ -58,7 +58,7 @@ "tar": "6.1.13" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "copyfiles": "2.4.1" }, "engines": { diff --git a/packages/generators/app/src/resources/files/js/config/middlewares.js b/packages/generators/app/src/resources/files/js/config/middlewares.js index 04a9aa99246..6eaf586ac81 100644 --- a/packages/generators/app/src/resources/files/js/config/middlewares.js +++ b/packages/generators/app/src/resources/files/js/config/middlewares.js @@ -1,9 +1,9 @@ module.exports = [ + 'strapi::logger', 'strapi::errors', 'strapi::security', 'strapi::cors', 'strapi::poweredBy', - 'strapi::logger', 'strapi::query', 'strapi::body', 'strapi::session', diff --git a/packages/generators/app/src/resources/files/ts/config/middlewares.ts b/packages/generators/app/src/resources/files/ts/config/middlewares.ts index 3ab20d955b5..829f5c04df0 100644 --- a/packages/generators/app/src/resources/files/ts/config/middlewares.ts +++ b/packages/generators/app/src/resources/files/ts/config/middlewares.ts @@ -1,9 +1,9 @@ export default [ + 'strapi::logger', 'strapi::errors', 'strapi::security', 'strapi::cors', 'strapi::poweredBy', - 'strapi::logger', 'strapi::query', 'strapi::body', 'strapi::session', diff --git a/packages/generators/generators/package.json b/packages/generators/generators/package.json index a87d9fc9c81..297fd402279 100644 --- a/packages/generators/generators/package.json +++ b/packages/generators/generators/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/generators", - "version": "4.15.4", + "version": "4.15.5", "description": "Interactive API generator.", "keywords": [ "strapi", @@ -47,8 +47,8 @@ }, "dependencies": { "@sindresorhus/slugify": "1.1.0", - "@strapi/typescript-utils": "4.15.4", - "@strapi/utils": "4.15.4", + "@strapi/typescript-utils": "4.15.5", + "@strapi/utils": "4.15.5", "chalk": "4.1.2", "copyfiles": "2.4.1", "fs-extra": "10.0.0", @@ -57,9 +57,9 @@ "pluralize": "8.0.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/plugins/cloud/package.json b/packages/plugins/cloud/package.json index f12412aee56..170a3989a2a 100644 --- a/packages/plugins/cloud/package.json +++ b/packages/plugins/cloud/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-cloud", - "version": "4.15.4", + "version": "4.15.5", "description": "Instructions to deploy your local project to Strapi Cloud", "license": "MIT", "author": { @@ -38,22 +38,22 @@ }, "dependencies": { "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", "react-intl": "6.4.1" }, "devDependencies": { - "@strapi/strapi": "4.15.4", + "@strapi/strapi": "4.15.5", "@types/react": "18.2.7", "@types/react-dom": "18.2.12", "@types/react-router-dom": "^5.3.3", "@types/styled-components": "5.1.26", - "eslint-config-custom": "4.15.4", + "eslint-config-custom": "4.15.5", "react": "18.2.0", "react-dom": "18.2.0", "react-router-dom": "5.3.4", "styled-components": "5.3.3", - "tsconfig": "4.15.4", + "tsconfig": "4.15.5", "typescript": "5.2.2" }, "peerDependencies": { diff --git a/packages/plugins/color-picker/package.json b/packages/plugins/color-picker/package.json index 32451711f5b..77a5d64a867 100644 --- a/packages/plugins/color-picker/package.json +++ b/packages/plugins/color-picker/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-color-picker", - "version": "4.15.4", + "version": "4.15.5", "description": "Strapi maintained Custom Fields", "repository": { "type": "git", @@ -55,14 +55,14 @@ }, "dependencies": { "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", "prop-types": "^15.8.1", "react-colorful": "5.6.1", "react-intl": "6.4.1" }, "devDependencies": { - "@strapi/strapi": "4.15.4", + "@strapi/strapi": "4.15.5", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", "@types/styled-components": "5.1.26", diff --git a/packages/plugins/documentation/package.json b/packages/plugins/documentation/package.json index 960a853951b..46a985cc9c0 100644 --- a/packages/plugins/documentation/package.json +++ b/packages/plugins/documentation/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-documentation", - "version": "4.15.4", + "version": "4.15.5", "description": "Create an OpenAPI Document and visualize your API with SWAGGER UI.", "repository": { "type": "git", @@ -47,9 +47,9 @@ }, "dependencies": { "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "bcryptjs": "2.4.3", "cheerio": "^1.0.0-rc.12", "formik": "2.4.0", @@ -67,8 +67,8 @@ }, "devDependencies": { "@apidevtools/swagger-parser": "^10.1.0", - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", "msw": "1.3.0", diff --git a/packages/plugins/documentation/server/services/helpers/utils/clean-schema-attributes.js b/packages/plugins/documentation/server/services/helpers/utils/clean-schema-attributes.js index 13de56fbac9..bdf6dffc200 100644 --- a/packages/plugins/documentation/server/services/helpers/utils/clean-schema-attributes.js +++ b/packages/plugins/documentation/server/services/helpers/utils/clean-schema-attributes.js @@ -202,7 +202,9 @@ const cleanSchemaAttributes = ( properties: { data: { type: 'array', - items: componentSchemaRefName.length ? { $ref: componentSchemaRefName } : {}, + items: componentSchemaRefName.length + ? { $ref: `${componentSchemaRefName}ListResponseDataItemLocalized` } + : {}, }, }, }; diff --git a/packages/plugins/graphql/package.json b/packages/plugins/graphql/package.json index f8c2133f73e..3ba0d76cd46 100644 --- a/packages/plugins/graphql/package.json +++ b/packages/plugins/graphql/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-graphql", - "version": "4.15.4", + "version": "4.15.5", "description": "Adds GraphQL endpoint with default API methods.", "repository": { "type": "git", @@ -52,9 +52,9 @@ "@graphql-tools/schema": "8.5.1", "@graphql-tools/utils": "^8.13.1", "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "apollo-server-core": "3.12.1", "apollo-server-koa": "3.10.0", "graphql": "^15.5.1", @@ -68,18 +68,18 @@ "pluralize": "8.0.0" }, "devDependencies": { - "@strapi/strapi": "4.15.4", - "@strapi/types": "4.15.4", + "@strapi/strapi": "4.15.5", + "@strapi/types": "4.15.5", "@types/graphql-depth-limit": "1.1.5", "@types/graphql-upload": "8.0.12", "cross-env": "^7.0.3", - "eslint-config-custom": "4.15.4", + "eslint-config-custom": "4.15.5", "koa": "2.13.4", "react": "^18.2.0", "react-dom": "^18.2.0", "react-router-dom": "5.3.4", "styled-components": "5.3.3", - "tsconfig": "4.15.4", + "tsconfig": "4.15.5", "typescript": "5.2.2" }, "peerDependencies": { diff --git a/packages/plugins/i18n/package.json b/packages/plugins/i18n/package.json index 0dc9a1988f6..89621ecbce8 100644 --- a/packages/plugins/i18n/package.json +++ b/packages/plugins/i18n/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-i18n", - "version": "4.15.4", + "version": "4.15.5", "description": "This plugin enables to create, to read and to update content in different languages, both from the Admin Panel and from the API", "repository": { "type": "git", @@ -50,9 +50,9 @@ "dependencies": { "@reduxjs/toolkit": "1.9.7", "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "formik": "2.4.0", "immer": "9.0.19", "lodash": "4.17.21", @@ -64,8 +64,8 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@testing-library/react": "14.0.0", "msw": "1.3.0", "react": "^18.2.0", diff --git a/packages/plugins/i18n/server/constants/iso-locales.json b/packages/plugins/i18n/server/constants/iso-locales.json index b569812edb7..5306075508c 100644 --- a/packages/plugins/i18n/server/constants/iso-locales.json +++ b/packages/plugins/i18n/server/constants/iso-locales.json @@ -718,6 +718,10 @@ { "code":"en-MP", "name":"English (Northern Mariana Islands) (en-MP)" + }, + { + "code":"en-NO", + "name":"English (Norway) (en-NO)" }, { "code":"en-PA", diff --git a/packages/plugins/i18n/server/services/__tests__/__snapshots__/iso-locales.test.js.snap b/packages/plugins/i18n/server/services/__tests__/__snapshots__/iso-locales.test.js.snap index e74741af541..246c58b25f3 100644 --- a/packages/plugins/i18n/server/services/__tests__/__snapshots__/iso-locales.test.js.snap +++ b/packages/plugins/i18n/server/services/__tests__/__snapshots__/iso-locales.test.js.snap @@ -722,6 +722,10 @@ exports[`ISO locales getIsoLocales 1`] = ` "code": "en-MP", "name": "English (Northern Mariana Islands) (en-MP)", }, + { + "code": "en-NO", + "name": "English (Norway) (en-NO)", + }, { "code": "en-PA", "name": "English (Panama) (en-PA)", diff --git a/packages/plugins/sentry/package.json b/packages/plugins/sentry/package.json index 13ac2b3515f..84c41d8e17f 100644 --- a/packages/plugins/sentry/package.json +++ b/packages/plugins/sentry/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-sentry", - "version": "4.15.4", + "version": "4.15.5", "description": "Send Strapi error events to Sentry", "repository": { "type": "git", @@ -46,12 +46,12 @@ "dependencies": { "@sentry/node": "6.19.7", "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "react": "^18.2.0", "react-dom": "^18.2.0", "react-router-dom": "5.3.4", diff --git a/packages/plugins/users-permissions/package.json b/packages/plugins/users-permissions/package.json index 0fdbd343352..3f669857ea2 100644 --- a/packages/plugins/users-permissions/package.json +++ b/packages/plugins/users-permissions/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/plugin-users-permissions", - "version": "4.15.4", + "version": "4.15.5", "description": "Protect your API with a full-authentication process based on JWT", "repository": { "type": "git", @@ -48,9 +48,9 @@ }, "dependencies": { "@strapi/design-system": "1.13.1", - "@strapi/helper-plugin": "4.15.4", + "@strapi/helper-plugin": "4.15.5", "@strapi/icons": "1.13.0", - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "bcryptjs": "2.4.3", "formik": "2.4.0", "grant-koa": "5.4.8", @@ -69,8 +69,8 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/strapi": "4.15.4", + "@strapi/pack-up": "4.15.5", + "@strapi/strapi": "4.15.5", "@testing-library/dom": "9.2.0", "@testing-library/react": "14.0.0", "@testing-library/user-event": "14.4.3", diff --git a/packages/providers/audit-logs-local/package.json b/packages/providers/audit-logs-local/package.json index 830b51ee2f4..f2b3912e65b 100644 --- a/packages/providers/audit-logs-local/package.json +++ b/packages/providers/audit-logs-local/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-audit-logs-local", - "version": "4.15.4", + "version": "4.15.5", "description": "Local provider for strapi audit logs", "keywords": [ "audit-logs", @@ -42,10 +42,10 @@ "watch": "pack-up watch" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "@strapi/types": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "@strapi/types": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/email-amazon-ses/package.json b/packages/providers/email-amazon-ses/package.json index 3eb718205ff..095cb1a65c1 100644 --- a/packages/providers/email-amazon-ses/package.json +++ b/packages/providers/email-amazon-ses/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-email-amazon-ses", - "version": "4.15.4", + "version": "4.15.5", "description": "Amazon SES provider for strapi email", "keywords": [ "email", @@ -43,13 +43,13 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "node-ses": "^3.0.3" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/email-mailgun/package.json b/packages/providers/email-mailgun/package.json index 9c7ef2ab98b..ac1d0a1ac06 100644 --- a/packages/providers/email-mailgun/package.json +++ b/packages/providers/email-mailgun/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-email-mailgun", - "version": "4.15.4", + "version": "4.15.5", "description": "Mailgun provider for strapi email plugin", "keywords": [ "email", @@ -45,14 +45,14 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "form-data": "^4.0.0", "mailgun.js": "8.2.1" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/email-nodemailer/package.json b/packages/providers/email-nodemailer/package.json index 15500d37e13..19b848aea5b 100644 --- a/packages/providers/email-nodemailer/package.json +++ b/packages/providers/email-nodemailer/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-email-nodemailer", - "version": "4.15.4", + "version": "4.15.5", "description": "Nodemailer provider for Strapi 3", "keywords": [ "strapi", @@ -60,10 +60,10 @@ "nodemailer": "6.9.1" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "@types/nodemailer": "6.4.7", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/email-sendgrid/package.json b/packages/providers/email-sendgrid/package.json index 6a2f5d564fc..4d6dfc94914 100644 --- a/packages/providers/email-sendgrid/package.json +++ b/packages/providers/email-sendgrid/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-email-sendgrid", - "version": "4.15.4", + "version": "4.15.5", "description": "Sendgrid provider for strapi email", "keywords": [ "email", @@ -44,12 +44,12 @@ }, "dependencies": { "@sendgrid/mail": "7.7.0", - "@strapi/utils": "4.15.4" + "@strapi/utils": "4.15.5" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/email-sendmail/package.json b/packages/providers/email-sendmail/package.json index d575ffcbb0e..93e2a046a96 100644 --- a/packages/providers/email-sendmail/package.json +++ b/packages/providers/email-sendmail/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-email-sendmail", - "version": "4.15.4", + "version": "4.15.5", "description": "Sendmail provider for strapi email", "keywords": [ "email", @@ -42,14 +42,14 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "sendmail": "^1.6.1" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "@types/sendmail": "1.4.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/upload-aws-s3/README.md b/packages/providers/upload-aws-s3/README.md index b707b81bf15..5851e862069 100644 --- a/packages/providers/upload-aws-s3/README.md +++ b/packages/providers/upload-aws-s3/README.md @@ -171,7 +171,7 @@ module.exports = [ ]; ``` -If you use dots in your bucket name, the url of the ressource is in directory style (`s3.yourRegion.amazonaws.com/your.bucket.name/image.jpg`) instead of `yourBucketName.s3.yourRegion.amazonaws.com/image.jpg`. Then only add `s3.yourRegion.amazonaws.com` to img-src and media-src directives. +If you use dots in your bucket name, the url of the resource is in directory style (`s3.yourRegion.amazonaws.com/your.bucket.name/image.jpg`) instead of `yourBucketName.s3.yourRegion.amazonaws.com/image.jpg` so in that case the img-src and media-src directives to add will be `s3.yourRegion.amazonaws.com` without the bucket name in the url. ## Bucket CORS Configuration @@ -202,3 +202,45 @@ These are the minimum amount of permissions needed for this provider to work. "s3:PutObjectAcl" ], ``` + +## Update to AWS SDK V3 and URL Format Change + +In the recent update of the `@strapi/provider-upload-aws-s3` plugin, we have transitioned from AWS SDK V2 to AWS SDK V3. This significant update brings along a change in the format of the URLs used in Amazon S3 services. + +### Understanding the New URL Format + +AWS SDK V3 adopts the virtual-hosted–style URI format for S3 URLs. This format is recommended by AWS and is likely to become required in the near future, as the path-style URI is being deprecated. More details on this format can be found in the [AWS User Guide](https://docs.aws.amazon.com/AmazonS3/latest/userguide/VirtualHosting.html#virtual-hosted-style-access). + +### Why the Change? + +The move to virtual-hosted–style URIs aligns with AWS's recommendation and future-proofing strategies. For an in-depth understanding of AWS's decision behind this transition, you can refer to their detailed post [here](https://aws.amazon.com/es/blogs/aws/amazon-s3-path-deprecation-plan-the-rest-of-the-story/). + +### Configuring Your Strapi Application + +If you wish to continue using the plugin with Strapi 4.15.x versions or newer without changing your URL format, it's possible to specify your desired URL format directly in the plugin's configuration. Below is an example configuration highlighting the critical `baseUrl` property: + +```javascript +upload: { + config: { + provider: 'aws-s3', + providerOptions: { + accessKeyId: process.env.AWS_ACCESS_KEY_ID, + secretAccessKey: process.env.AWS_ACCESS_SECRET, + region: process.env.AWS_REGION, + baseUrl: `https://s3.${region}.amazonaws.com/${bucket}`, // This line sets the custom url format + params: { + ACL: process.env.AWS_ACL || 'public-read', + signedUrlExpires: process.env.AWS_SIGNED_URL_EXPIRES || 15 * 60, + Bucket: process.env.AWS_BUCKET, + }, + }, + actionOptions: { + upload: {}, + uploadStream: {}, + delete: {}, + }, + }, +} +``` + +This configuration ensures compatibility with the updated AWS SDK while providing flexibility in URL format selection, catering to various user needs. diff --git a/packages/providers/upload-aws-s3/package.json b/packages/providers/upload-aws-s3/package.json index 16cf12efe9b..1826cc97d99 100644 --- a/packages/providers/upload-aws-s3/package.json +++ b/packages/providers/upload-aws-s3/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-upload-aws-s3", - "version": "4.15.4", + "version": "4.15.5", "description": "AWS S3 provider for strapi upload", "keywords": [ "upload", @@ -53,10 +53,10 @@ "lodash": "4.17.21" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "@types/jest": "29.5.2", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/upload-cloudinary/package.json b/packages/providers/upload-cloudinary/package.json index 98409e43aa3..2474f011bd6 100644 --- a/packages/providers/upload-cloudinary/package.json +++ b/packages/providers/upload-cloudinary/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-upload-cloudinary", - "version": "4.15.4", + "version": "4.15.5", "description": "Cloudinary provider for strapi upload", "keywords": [ "upload", @@ -43,14 +43,14 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "cloudinary": "^1.41.0", "into-stream": "^5.1.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/providers/upload-local/package.json b/packages/providers/upload-local/package.json index 2873baa8d5d..ac63d18ecab 100644 --- a/packages/providers/upload-local/package.json +++ b/packages/providers/upload-local/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/provider-upload-local", - "version": "4.15.4", + "version": "4.15.5", "description": "Local provider for strapi upload", "keywords": [ "upload", @@ -44,14 +44,14 @@ "watch": "pack-up watch" }, "dependencies": { - "@strapi/utils": "4.15.4", + "@strapi/utils": "4.15.5", "fs-extra": "10.0.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "@types/jest": "29.5.2", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/utils/api-tests/package.json b/packages/utils/api-tests/package.json index 743cf465516..4da96a03537 100644 --- a/packages/utils/api-tests/package.json +++ b/packages/utils/api-tests/package.json @@ -1,6 +1,6 @@ { "name": "api-tests", - "version": "4.15.4", + "version": "4.15.5", "private": true, "dependencies": { "dotenv": "14.2.0", diff --git a/packages/utils/eslint-config-custom/package.json b/packages/utils/eslint-config-custom/package.json index fcfad99e778..7a8903b0814 100644 --- a/packages/utils/eslint-config-custom/package.json +++ b/packages/utils/eslint-config-custom/package.json @@ -1,6 +1,6 @@ { "name": "eslint-config-custom", - "version": "4.15.4", + "version": "4.15.5", "private": true, "main": "index.js" } diff --git a/packages/utils/logger/package.json b/packages/utils/logger/package.json index 2955d122e99..8fb7c1fc22d 100644 --- a/packages/utils/logger/package.json +++ b/packages/utils/logger/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/logger", - "version": "4.15.4", + "version": "4.15.5", "description": "Strapi's logger", "homepage": "https://strapi.io", "bugs": { @@ -43,9 +43,9 @@ "winston": "3.10.0" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", - "eslint-config-custom": "4.15.4", - "tsconfig": "4.15.4" + "@strapi/pack-up": "4.15.5", + "eslint-config-custom": "4.15.5", + "tsconfig": "4.15.5" }, "engines": { "node": ">=18.0.0 <=20.x.x", diff --git a/packages/utils/pack-up/package.json b/packages/utils/pack-up/package.json index ce016e589b0..1f19dc8d004 100644 --- a/packages/utils/pack-up/package.json +++ b/packages/utils/pack-up/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/pack-up", - "version": "4.15.4", + "version": "4.15.5", "description": "Simple tools for creating interoperable CJS & ESM packages.", "keywords": [ "strapi", @@ -84,11 +84,11 @@ "yup": "0.32.9" }, "devDependencies": { - "@strapi/pack-up": "4.15.4", + "@strapi/pack-up": "4.15.5", "@types/git-url-parse": "9.0.1", "@types/ini": "1.3.31", "@types/prompts": "2.4.4", - "eslint-config-custom": "4.15.4", + "eslint-config-custom": "4.15.5", "rimraf": "3.0.2" }, "engines": { diff --git a/packages/utils/tsconfig/package.json b/packages/utils/tsconfig/package.json index 5652803f12d..ee3cf750199 100644 --- a/packages/utils/tsconfig/package.json +++ b/packages/utils/tsconfig/package.json @@ -1,6 +1,6 @@ { "name": "tsconfig", - "version": "4.15.4", + "version": "4.15.5", "private": true, "devDependencies": { "@tsconfig/node18": "18.2.2" diff --git a/packages/utils/typescript/package.json b/packages/utils/typescript/package.json index c9c4e3d8d7f..5fb1e12915f 100644 --- a/packages/utils/typescript/package.json +++ b/packages/utils/typescript/package.json @@ -1,6 +1,6 @@ { "name": "@strapi/typescript-utils", - "version": "4.15.4", + "version": "4.15.5", "description": "Typescript support for Strapi", "keywords": [ "strapi", diff --git a/scripts/front/package.json b/scripts/front/package.json index b2061da8cee..33b55591287 100644 --- a/scripts/front/package.json +++ b/scripts/front/package.json @@ -1,6 +1,6 @@ { "name": "scripts-front", - "version": "4.15.4", + "version": "4.15.5", "private": true, "scripts": { "test:front": "jest --config jest.config.front.js" diff --git a/yarn.lock b/yarn.lock index bc7536d9352..44c8c86deb4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8906,7 +8906,7 @@ __metadata: languageName: node linkType: hard -"@strapi/admin-test-utils@npm:4.15.4, @strapi/admin-test-utils@workspace:*, @strapi/admin-test-utils@workspace:packages/admin-test-utils": +"@strapi/admin-test-utils@npm:4.15.5, @strapi/admin-test-utils@workspace:*, @strapi/admin-test-utils@workspace:packages/admin-test-utils": version: 0.0.0-use.local resolution: "@strapi/admin-test-utils@workspace:packages/admin-test-utils" dependencies: @@ -8914,9 +8914,9 @@ __metadata: "@reduxjs/toolkit": "npm:1.9.7" "@strapi/pack-up": "workspace:*" "@testing-library/jest-dom": "npm:5.16.5" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" jest-styled-components: "npm:7.1.1" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" whatwg-fetch: "npm:3.6.2" peerDependencies: "@reduxjs/toolkit": ^1.9.7 @@ -8924,7 +8924,7 @@ __metadata: languageName: unknown linkType: soft -"@strapi/admin@npm:4.15.4, @strapi/admin@workspace:packages/core/admin": +"@strapi/admin@npm:4.15.5, @strapi/admin@workspace:packages/core/admin": version: 0.0.0-use.local resolution: "@strapi/admin@workspace:packages/core/admin" dependencies: @@ -8933,18 +8933,18 @@ __metadata: "@radix-ui/react-context": "npm:1.0.1" "@radix-ui/react-toolbar": "npm:1.0.4" "@reduxjs/toolkit": "npm:1.9.7" - "@strapi/admin-test-utils": "npm:4.15.4" - "@strapi/data-transfer": "npm:4.15.4" + "@strapi/admin-test-utils": "npm:4.15.5" + "@strapi/data-transfer": "npm:4.15.5" "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/permissions": "npm:4.15.4" - "@strapi/provider-audit-logs-local": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/types": "npm:4.15.4" - "@strapi/typescript-utils": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/permissions": "npm:4.15.5" + "@strapi/provider-audit-logs-local": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" + "@strapi/typescript-utils": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/dom": "npm:9.2.0" "@testing-library/react": "npm:14.0.0" "@testing-library/user-event": "npm:14.4.3" @@ -9043,7 +9043,7 @@ __metadata: webpack-hot-middleware: "npm:2.25.4" yup: "npm:0.32.9" peerDependencies: - "@strapi/data-transfer": 4.15.4 + "@strapi/data-transfer": 4.15.5 "@strapi/strapi": ^4.3.4 react: ^17.0.0 || ^18.0.0 react-dom: ^17.0.0 || ^18.0.0 @@ -9052,15 +9052,15 @@ __metadata: languageName: unknown linkType: soft -"@strapi/data-transfer@npm:4.15.4, @strapi/data-transfer@workspace:packages/core/data-transfer": +"@strapi/data-transfer@npm:4.15.5, @strapi/data-transfer@workspace:packages/core/data-transfer": version: 0.0.0-use.local resolution: "@strapi/data-transfer@workspace:packages/core/data-transfer" dependencies: - "@strapi/logger": "npm:4.15.4" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/types": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/logger": "npm:4.15.5" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@types/fs-extra": "npm:9.0.13" "@types/jest": "npm:29.5.2" "@types/koa": "npm:2.13.4" @@ -9095,20 +9095,36 @@ __metadata: languageName: unknown linkType: soft -"@strapi/database@npm:4.15.4, @strapi/database@workspace:packages/core/database": +"@strapi/database@npm:4.15.4": + version: 4.15.4 + resolution: "@strapi/database@npm:4.15.4" + dependencies: + "@strapi/utils": "npm:4.15.4" + date-fns: "npm:2.30.0" + debug: "npm:4.3.4" + fs-extra: "npm:10.0.0" + knex: "npm:2.5.0" + lodash: "npm:4.17.21" + semver: "npm:7.5.4" + umzug: "npm:3.2.1" + checksum: daa19bf4bc8f2ed59dee3db5e2dc120673fd993d779bd88ed39b01fd7edc614929a4edbbe19d4bdcfb125d0025488ec81904cef609f67da27fac88772a1bb549 + languageName: node + linkType: hard + +"@strapi/database@npm:4.15.5, @strapi/database@workspace:packages/core/database": version: 0.0.0-use.local resolution: "@strapi/database@workspace:packages/core/database" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" date-fns: "npm:2.30.0" debug: "npm:4.3.4" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" fs-extra: "npm:10.0.0" knex: "npm:2.5.0" lodash: "npm:4.17.21" semver: "npm:7.5.4" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" umzug: "npm:3.2.1" languageName: unknown linkType: soft @@ -9171,12 +9187,12 @@ __metadata: languageName: node linkType: hard -"@strapi/generate-new@npm:4.15.4, @strapi/generate-new@workspace:packages/generators/app": +"@strapi/generate-new@npm:4.15.5, @strapi/generate-new@workspace:packages/generators/app": version: 0.0.0-use.local resolution: "@strapi/generate-new@workspace:packages/generators/app" dependencies: "@sentry/node": "npm:6.19.7" - "@strapi/pack-up": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" chalk: "npm:^4.1.2" copyfiles: "npm:2.4.1" execa: "npm:5.1.1" @@ -9191,26 +9207,26 @@ __metadata: languageName: unknown linkType: soft -"@strapi/generators@npm:4.15.4, @strapi/generators@workspace:packages/generators/generators": +"@strapi/generators@npm:4.15.5, @strapi/generators@workspace:packages/generators/generators": version: 0.0.0-use.local resolution: "@strapi/generators@workspace:packages/generators/generators" dependencies: "@sindresorhus/slugify": "npm:1.1.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/typescript-utils": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/typescript-utils": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" chalk: "npm:4.1.2" copyfiles: "npm:2.4.1" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" fs-extra: "npm:10.0.0" node-plop: "npm:0.26.3" plop: "npm:2.7.6" pluralize: "npm:8.0.0" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/helper-plugin@npm:4.15.4, @strapi/helper-plugin@workspace:packages/core/helper-plugin": +"@strapi/helper-plugin@npm:4.15.5, @strapi/helper-plugin@workspace:packages/core/helper-plugin": version: 0.0.0-use.local resolution: "@strapi/helper-plugin@workspace:packages/core/helper-plugin" dependencies: @@ -9220,11 +9236,11 @@ __metadata: "@storybook/addon-mdx-gfm": "npm:7.4.0" "@storybook/builder-vite": "npm:7.4.0" "@storybook/react-vite": "npm:7.4.0" - "@strapi/admin-test-utils": "npm:4.15.4" + "@strapi/admin-test-utils": "npm:4.15.5" "@strapi/design-system": "npm:1.13.1" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/types": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" "@testing-library/react": "npm:14.0.0" "@testing-library/user-event": "npm:14.4.3" "@types/react": "npm:18.2.7" @@ -9235,7 +9251,7 @@ __metadata: axios: "npm:1.6.0" cross-env: "npm:^7.0.3" date-fns: "npm:2.30.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" eslint-plugin-storybook: "npm:0.6.14" formik: "npm:2.4.0" immer: "npm:9.0.19" @@ -9285,23 +9301,33 @@ __metadata: languageName: node linkType: hard -"@strapi/logger@npm:4.15.4, @strapi/logger@workspace:packages/utils/logger": +"@strapi/logger@npm:4.15.4": + version: 4.15.4 + resolution: "@strapi/logger@npm:4.15.4" + dependencies: + lodash: "npm:4.17.21" + winston: "npm:3.10.0" + checksum: 281bc6257afa1576f9dcf0e392aacf1062d4bd8da4d7df24238978db7478c86f7fd834f98610dab7d0c78c5ce91e9fce5c02110369c22c7c155a81a3826b6e79 + languageName: node + linkType: hard + +"@strapi/logger@npm:4.15.5, @strapi/logger@workspace:packages/utils/logger": version: 0.0.0-use.local resolution: "@strapi/logger@workspace:packages/utils/logger" dependencies: - "@strapi/pack-up": "npm:4.15.4" - eslint-config-custom: "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + eslint-config-custom: "npm:4.15.5" lodash: "npm:4.17.21" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" winston: "npm:3.10.0" languageName: unknown linkType: soft -"@strapi/pack-up@npm:4.15.4, @strapi/pack-up@workspace:*, @strapi/pack-up@workspace:packages/utils/pack-up": +"@strapi/pack-up@npm:4.15.5, @strapi/pack-up@workspace:*, @strapi/pack-up@workspace:packages/utils/pack-up": version: 0.0.0-use.local resolution: "@strapi/pack-up@workspace:packages/utils/pack-up" dependencies: - "@strapi/pack-up": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" "@types/git-url-parse": "npm:9.0.1" "@types/ini": "npm:1.3.31" "@types/prompts": "npm:2.4.4" @@ -9313,7 +9339,7 @@ __metadata: commander: "npm:8.3.0" esbuild: "npm:0.19.2" esbuild-register: "npm:3.5.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" get-latest-version: "npm:5.1.0" git-url-parse: "npm:13.1.0" ini: "npm:4.1.1" @@ -9333,18 +9359,31 @@ __metadata: languageName: unknown linkType: soft -"@strapi/permissions@npm:4.15.4, @strapi/permissions@workspace:packages/core/permissions": +"@strapi/permissions@npm:4.15.4": + version: 4.15.4 + resolution: "@strapi/permissions@npm:4.15.4" + dependencies: + "@casl/ability": "npm:6.5.0" + "@strapi/utils": "npm:4.15.4" + lodash: "npm:4.17.21" + qs: "npm:6.11.1" + sift: "npm:16.0.1" + checksum: cd62c331bc2a8bafc1a6054203a35002ff7a7825752c7ac1cc8bd5bd25d4a96968f57838bd04ef88a6ac5ee7955143be52a3286fd0d579db39af412b563565d0 + languageName: node + linkType: hard + +"@strapi/permissions@npm:4.15.5, @strapi/permissions@workspace:packages/core/permissions": version: 0.0.0-use.local resolution: "@strapi/permissions@workspace:packages/core/permissions" dependencies: "@casl/ability": "npm:6.5.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" - eslint-config-custom: "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" + eslint-config-custom: "npm:4.15.5" lodash: "npm:4.17.21" qs: "npm:6.11.1" sift: "npm:16.0.1" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft @@ -9353,20 +9392,20 @@ __metadata: resolution: "@strapi/plugin-cloud@workspace:packages/plugins/cloud" dependencies: "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/strapi": "npm:4.15.4" + "@strapi/strapi": "npm:4.15.5" "@types/react": "npm:18.2.7" "@types/react-dom": "npm:18.2.12" "@types/react-router-dom": "npm:^5.3.3" "@types/styled-components": "npm:5.1.26" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" react: "npm:18.2.0" react-dom: "npm:18.2.0" react-intl: "npm:6.4.1" react-router-dom: "npm:5.3.4" styled-components: "npm:5.3.3" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" typescript: "npm:5.2.2" peerDependencies: "@strapi/strapi": ^4.4.0 @@ -9377,14 +9416,14 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-color-picker@npm:4.15.4, @strapi/plugin-color-picker@workspace:packages/plugins/color-picker": +"@strapi/plugin-color-picker@npm:4.15.5, @strapi/plugin-color-picker@workspace:packages/plugins/color-picker": version: 0.0.0-use.local resolution: "@strapi/plugin-color-picker@workspace:packages/plugins/color-picker" dependencies: "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/strapi": "npm:4.15.4" + "@strapi/strapi": "npm:4.15.5" "@testing-library/react": "npm:14.0.0" "@testing-library/user-event": "npm:14.4.3" "@types/styled-components": "npm:5.1.26" @@ -9405,29 +9444,29 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-content-manager@npm:4.15.4, @strapi/plugin-content-manager@workspace:packages/core/content-manager": +"@strapi/plugin-content-manager@npm:4.15.5, @strapi/plugin-content-manager@workspace:packages/core/content-manager": version: 0.0.0-use.local resolution: "@strapi/plugin-content-manager@workspace:packages/core/content-manager" dependencies: "@sindresorhus/slugify": "npm:1.1.0" - "@strapi/utils": "npm:4.15.4" + "@strapi/utils": "npm:4.15.5" lodash: "npm:4.17.21" qs: "npm:6.11.1" languageName: unknown linkType: soft -"@strapi/plugin-content-type-builder@npm:4.15.4, @strapi/plugin-content-type-builder@workspace:packages/core/content-type-builder": +"@strapi/plugin-content-type-builder@npm:4.15.5, @strapi/plugin-content-type-builder@workspace:packages/core/content-type-builder": version: 0.0.0-use.local resolution: "@strapi/plugin-content-type-builder@workspace:packages/core/content-type-builder" dependencies: "@sindresorhus/slugify": "npm:1.1.0" "@strapi/design-system": "npm:1.13.1" - "@strapi/generators": "npm:4.15.4" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/generators": "npm:4.15.5" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/react": "npm:14.0.0" fs-extra: "npm:10.0.0" history: "npm:^4.9.0" @@ -9453,17 +9492,17 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-documentation@npm:4.15.4, @strapi/plugin-documentation@workspace:packages/plugins/documentation": +"@strapi/plugin-documentation@npm:4.15.5, @strapi/plugin-documentation@workspace:packages/plugins/documentation": version: 0.0.0-use.local resolution: "@strapi/plugin-documentation@workspace:packages/plugins/documentation" dependencies: "@apidevtools/swagger-parser": "npm:^10.1.0" "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/react": "npm:14.0.0" "@testing-library/user-event": "npm:14.4.3" bcryptjs: "npm:2.4.3" @@ -9494,17 +9533,17 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-email@npm:4.15.4, @strapi/plugin-email@workspace:packages/core/email": +"@strapi/plugin-email@npm:4.15.5, @strapi/plugin-email@workspace:packages/core/email": version: 0.0.0-use.local resolution: "@strapi/plugin-email@workspace:packages/core/email" dependencies: "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/provider-email-sendmail": "npm:4.15.4" - "@strapi/types": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/provider-email-sendmail": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/react": "npm:14.0.0" "@types/koa": "npm:2.13.4" "@types/lodash": "npm:^4.14.191" @@ -9528,24 +9567,24 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-graphql@npm:4.15.4, @strapi/plugin-graphql@workspace:packages/plugins/graphql": +"@strapi/plugin-graphql@npm:4.15.5, @strapi/plugin-graphql@workspace:packages/plugins/graphql": version: 0.0.0-use.local resolution: "@strapi/plugin-graphql@workspace:packages/plugins/graphql" dependencies: "@graphql-tools/schema": "npm:8.5.1" "@graphql-tools/utils": "npm:^8.13.1" "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/strapi": "npm:4.15.4" - "@strapi/types": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/strapi": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@types/graphql-depth-limit": "npm:1.1.5" "@types/graphql-upload": "npm:8.0.12" apollo-server-core: "npm:3.12.1" apollo-server-koa: "npm:3.10.0" cross-env: "npm:^7.0.3" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" graphql: "npm:^15.5.1" graphql-depth-limit: "npm:^1.1.0" graphql-playground-middleware-koa: "npm:^1.6.21" @@ -9560,7 +9599,7 @@ __metadata: react-dom: "npm:^18.2.0" react-router-dom: "npm:5.3.4" styled-components: "npm:5.3.3" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" typescript: "npm:5.2.2" peerDependencies: "@strapi/strapi": ^4.0.0 @@ -9571,17 +9610,17 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-i18n@npm:4.15.4, @strapi/plugin-i18n@workspace:packages/plugins/i18n": +"@strapi/plugin-i18n@npm:4.15.5, @strapi/plugin-i18n@workspace:packages/plugins/i18n": version: 0.0.0-use.local resolution: "@strapi/plugin-i18n@workspace:packages/plugins/i18n" dependencies: "@reduxjs/toolkit": "npm:1.9.7" "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/react": "npm:14.0.0" formik: "npm:2.4.0" immer: "npm:9.0.19" @@ -9606,16 +9645,16 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-sentry@npm:4.15.4, @strapi/plugin-sentry@workspace:packages/plugins/sentry": +"@strapi/plugin-sentry@npm:4.15.5, @strapi/plugin-sentry@workspace:packages/plugins/sentry": version: 0.0.0-use.local resolution: "@strapi/plugin-sentry@workspace:packages/plugins/sentry" dependencies: "@sentry/node": "npm:6.19.7" "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" react: "npm:^18.2.0" react-dom: "npm:^18.2.0" react-router-dom: "npm:5.3.4" @@ -9629,17 +9668,17 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-upload@npm:4.15.4, @strapi/plugin-upload@workspace:packages/core/upload": +"@strapi/plugin-upload@npm:4.15.5, @strapi/plugin-upload@workspace:packages/core/upload": version: 0.0.0-use.local resolution: "@strapi/plugin-upload@workspace:packages/core/upload" dependencies: "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/provider-upload-local": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/provider-upload-local": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/dom": "npm:9.2.0" "@testing-library/react": "npm:14.0.0" "@testing-library/user-event": "npm:14.4.3" @@ -9678,16 +9717,16 @@ __metadata: languageName: unknown linkType: soft -"@strapi/plugin-users-permissions@npm:4.15.4, @strapi/plugin-users-permissions@workspace:packages/plugins/users-permissions": +"@strapi/plugin-users-permissions@npm:4.15.5, @strapi/plugin-users-permissions@workspace:packages/plugins/users-permissions": version: 0.0.0-use.local resolution: "@strapi/plugin-users-permissions@workspace:packages/plugins/users-permissions" dependencies: "@strapi/design-system": "npm:1.13.1" - "@strapi/helper-plugin": "npm:4.15.4" + "@strapi/helper-plugin": "npm:4.15.5" "@strapi/icons": "npm:1.13.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@testing-library/dom": "npm:9.2.0" "@testing-library/react": "npm:14.0.0" "@testing-library/user-event": "npm:14.4.3" @@ -9721,14 +9760,14 @@ __metadata: languageName: unknown linkType: soft -"@strapi/provider-audit-logs-local@npm:4.15.4, @strapi/provider-audit-logs-local@workspace:packages/providers/audit-logs-local": +"@strapi/provider-audit-logs-local@npm:4.15.5, @strapi/provider-audit-logs-local@workspace:packages/providers/audit-logs-local": version: 0.0.0-use.local resolution: "@strapi/provider-audit-logs-local@workspace:packages/providers/audit-logs-local" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/types": "npm:4.15.4" - eslint-config-custom: "npm:4.15.4" - tsconfig: "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" + eslint-config-custom: "npm:4.15.5" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft @@ -9736,24 +9775,24 @@ __metadata: version: 0.0.0-use.local resolution: "@strapi/provider-email-amazon-ses@workspace:packages/providers/email-amazon-ses" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" - eslint-config-custom: "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" + eslint-config-custom: "npm:4.15.5" node-ses: "npm:^3.0.3" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/provider-email-mailgun@npm:4.15.4, @strapi/provider-email-mailgun@workspace:packages/providers/email-mailgun": +"@strapi/provider-email-mailgun@npm:4.15.5, @strapi/provider-email-mailgun@workspace:packages/providers/email-mailgun": version: 0.0.0-use.local resolution: "@strapi/provider-email-mailgun@workspace:packages/providers/email-mailgun" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" - eslint-config-custom: "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" + eslint-config-custom: "npm:4.15.5" form-data: "npm:^4.0.0" mailgun.js: "npm:8.2.1" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft @@ -9761,12 +9800,12 @@ __metadata: version: 0.0.0-use.local resolution: "@strapi/provider-email-nodemailer@workspace:packages/providers/email-nodemailer" dependencies: - "@strapi/pack-up": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" "@types/nodemailer": "npm:6.4.7" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" lodash: "npm:4.17.21" nodemailer: "npm:6.9.1" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft @@ -9775,27 +9814,27 @@ __metadata: resolution: "@strapi/provider-email-sendgrid@workspace:packages/providers/email-sendgrid" dependencies: "@sendgrid/mail": "npm:7.7.0" - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" - eslint-config-custom: "npm:4.15.4" - tsconfig: "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" + eslint-config-custom: "npm:4.15.5" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/provider-email-sendmail@npm:4.15.4, @strapi/provider-email-sendmail@workspace:packages/providers/email-sendmail": +"@strapi/provider-email-sendmail@npm:4.15.5, @strapi/provider-email-sendmail@workspace:packages/providers/email-sendmail": version: 0.0.0-use.local resolution: "@strapi/provider-email-sendmail@workspace:packages/providers/email-sendmail" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@types/sendmail": "npm:1.4.4" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" sendmail: "npm:^1.6.1" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/provider-upload-aws-s3@npm:4.15.4, @strapi/provider-upload-aws-s3@workspace:packages/providers/upload-aws-s3": +"@strapi/provider-upload-aws-s3@npm:4.15.5, @strapi/provider-upload-aws-s3@workspace:packages/providers/upload-aws-s3": version: 0.0.0-use.local resolution: "@strapi/provider-upload-aws-s3@workspace:packages/providers/upload-aws-s3" dependencies: @@ -9803,62 +9842,62 @@ __metadata: "@aws-sdk/lib-storage": "npm:3.433.0" "@aws-sdk/s3-request-presigner": "npm:3.433.0" "@aws-sdk/types": "npm:3.433.0" - "@strapi/pack-up": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" "@types/jest": "npm:29.5.2" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" lodash: "npm:4.17.21" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/provider-upload-cloudinary@npm:4.15.4, @strapi/provider-upload-cloudinary@workspace:packages/providers/upload-cloudinary": +"@strapi/provider-upload-cloudinary@npm:4.15.5, @strapi/provider-upload-cloudinary@workspace:packages/providers/upload-cloudinary": version: 0.0.0-use.local resolution: "@strapi/provider-upload-cloudinary@workspace:packages/providers/upload-cloudinary" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" cloudinary: "npm:^1.41.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" into-stream: "npm:^5.1.0" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/provider-upload-local@npm:4.15.4, @strapi/provider-upload-local@workspace:packages/providers/upload-local": +"@strapi/provider-upload-local@npm:4.15.5, @strapi/provider-upload-local@workspace:packages/providers/upload-local": version: 0.0.0-use.local resolution: "@strapi/provider-upload-local@workspace:packages/providers/upload-local" dependencies: - "@strapi/pack-up": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@types/jest": "npm:29.5.2" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" fs-extra: "npm:10.0.0" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" languageName: unknown linkType: soft -"@strapi/strapi@npm:4.15.4, @strapi/strapi@workspace:packages/core/strapi": +"@strapi/strapi@npm:4.15.5, @strapi/strapi@workspace:packages/core/strapi": version: 0.0.0-use.local resolution: "@strapi/strapi@workspace:packages/core/strapi" dependencies: "@koa/cors": "npm:3.4.3" "@koa/router": "npm:10.1.1" - "@strapi/admin": "npm:4.15.4" - "@strapi/data-transfer": "npm:4.15.4" - "@strapi/database": "npm:4.15.4" - "@strapi/generate-new": "npm:4.15.4" - "@strapi/generators": "npm:4.15.4" - "@strapi/logger": "npm:4.15.4" + "@strapi/admin": "npm:4.15.5" + "@strapi/data-transfer": "npm:4.15.5" + "@strapi/database": "npm:4.15.5" + "@strapi/generate-new": "npm:4.15.5" + "@strapi/generators": "npm:4.15.5" + "@strapi/logger": "npm:4.15.5" "@strapi/pack-up": "workspace:*" - "@strapi/permissions": "npm:4.15.4" - "@strapi/plugin-content-manager": "npm:4.15.4" - "@strapi/plugin-content-type-builder": "npm:4.15.4" - "@strapi/plugin-email": "npm:4.15.4" - "@strapi/plugin-upload": "npm:4.15.4" + "@strapi/permissions": "npm:4.15.5" + "@strapi/plugin-content-manager": "npm:4.15.5" + "@strapi/plugin-content-type-builder": "npm:4.15.5" + "@strapi/plugin-email": "npm:4.15.5" + "@strapi/plugin-upload": "npm:4.15.5" "@strapi/ts-zen": "npm:^0.2.0" - "@strapi/types": "npm:4.15.4" - "@strapi/typescript-utils": "npm:4.15.4" - "@strapi/utils": "npm:4.15.4" + "@strapi/types": "npm:4.15.5" + "@strapi/typescript-utils": "npm:4.15.5" + "@strapi/utils": "npm:4.15.5" "@types/bcryptjs": "npm:2.4.3" "@types/configstore": "npm:5.0.1" "@types/delegates": "npm:1.0.0" @@ -9884,7 +9923,7 @@ __metadata: debug: "npm:4.3.4" delegates: "npm:1.0.0" dotenv: "npm:14.2.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" execa: "npm:5.1.1" fs-extra: "npm:10.0.0" glob: "npm:10.3.10" @@ -9914,7 +9953,7 @@ __metadata: semver: "npm:7.5.4" statuses: "npm:2.0.1" supertest: "npm:6.3.3" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" typescript: "npm:5.2.2" yup: "npm:0.32.9" bin: @@ -9932,34 +9971,53 @@ __metadata: languageName: node linkType: hard -"@strapi/types@npm:4.15.4, @strapi/types@workspace:packages/core/types": - version: 0.0.0-use.local - resolution: "@strapi/types@workspace:packages/core/types" +"@strapi/types@npm:4.15.4": + version: 4.15.4 + resolution: "@strapi/types@npm:4.15.4" dependencies: "@koa/cors": "npm:3.4.3" "@koa/router": "npm:10.1.1" "@strapi/database": "npm:4.15.4" "@strapi/logger": "npm:4.15.4" - "@strapi/pack-up": "npm:4.15.4" "@strapi/permissions": "npm:4.15.4" - "@strapi/ts-zen": "npm:^0.2.0" "@strapi/utils": "npm:4.15.4" + commander: "npm:8.3.0" + https-proxy-agent: "npm:5.0.1" + koa: "npm:2.13.4" + node-fetch: "npm:2.7.0" + node-schedule: "npm:2.1.0" + checksum: 1ed689827af66e86a9111f6b12aea2d909baea8c835397e8c11746eb1b4a00566839488dadbd54a7cc59cb77b1256c4d3c495a5d93856680f4f57d70a63c35a0 + languageName: node + linkType: hard + +"@strapi/types@npm:4.15.5, @strapi/types@workspace:packages/core/types": + version: 0.0.0-use.local + resolution: "@strapi/types@workspace:packages/core/types" + dependencies: + "@koa/cors": "npm:3.4.3" + "@koa/router": "npm:10.1.1" + "@strapi/database": "npm:4.15.5" + "@strapi/logger": "npm:4.15.5" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/permissions": "npm:4.15.5" + "@strapi/ts-zen": "npm:^0.2.0" + "@strapi/utils": "npm:4.15.5" "@types/jest": "npm:29.5.2" "@types/koa": "npm:2.13.4" "@types/koa__router": "npm:12.0.0" "@types/node-schedule": "npm:2.1.0" commander: "npm:8.3.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" https-proxy-agent: "npm:5.0.1" koa: "npm:2.13.4" node-fetch: "npm:2.7.0" node-schedule: "npm:2.1.0" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" typescript: "npm:5.2.2" languageName: unknown linkType: soft -"@strapi/typescript-utils@npm:4.15.4, @strapi/typescript-utils@workspace:packages/utils/typescript": +"@strapi/typescript-utils@npm:4.15.5, @strapi/typescript-utils@workspace:packages/utils/typescript": version: 0.0.0-use.local resolution: "@strapi/typescript-utils@workspace:packages/utils/typescript" dependencies: @@ -10030,22 +10088,37 @@ __metadata: languageName: unknown linkType: soft -"@strapi/utils@npm:4.15.4, @strapi/utils@workspace:packages/core/utils": +"@strapi/utils@npm:4.15.4": + version: 4.15.4 + resolution: "@strapi/utils@npm:4.15.4" + dependencies: + "@sindresorhus/slugify": "npm:1.1.0" + date-fns: "npm:2.30.0" + http-errors: "npm:1.8.1" + lodash: "npm:4.17.21" + p-map: "npm:4.0.0" + yup: "npm:0.32.9" + checksum: 9267dded0718b8c7fb528e2a79aede131d1904700282f94faba77c2a55f31d9dbac70aa5f39cf9ab816dac1f8f4104d2011d1cc0acf54edacf8c28092a8c7c39 + languageName: node + linkType: hard + +"@strapi/utils@npm:4.15.5, @strapi/utils@workspace:packages/core/utils": version: 0.0.0-use.local resolution: "@strapi/utils@workspace:packages/core/utils" dependencies: "@sindresorhus/slugify": "npm:1.1.0" - "@strapi/pack-up": "npm:4.15.4" + "@strapi/pack-up": "npm:4.15.5" + "@strapi/types": "npm:4.15.5" "@types/koa": "npm:2.13.4" "@types/node": "npm:18.18.4" date-fns: "npm:2.30.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" http-errors: "npm:1.8.1" koa: "npm:2.13.4" koa-body: "npm:4.2.0" lodash: "npm:4.17.21" p-map: "npm:4.0.0" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" yup: "npm:0.32.9" languageName: unknown linkType: soft @@ -15464,12 +15537,12 @@ __metadata: version: 0.0.0-use.local resolution: "create-strapi-app@workspace:packages/cli/create-strapi-app" dependencies: - "@strapi/generate-new": "npm:4.15.4" - "@strapi/pack-up": "npm:4.15.4" + "@strapi/generate-new": "npm:4.15.5" + "@strapi/pack-up": "npm:4.15.5" commander: "npm:8.3.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" inquirer: "npm:8.2.5" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" bin: create-strapi-app: ./bin/index.js languageName: unknown @@ -15479,17 +15552,17 @@ __metadata: version: 0.0.0-use.local resolution: "create-strapi-starter@workspace:packages/cli/create-strapi-starter" dependencies: - "@strapi/generate-new": "npm:4.15.4" - "@strapi/pack-up": "npm:4.15.4" + "@strapi/generate-new": "npm:4.15.5" + "@strapi/pack-up": "npm:4.15.5" chalk: "npm:4.1.2" ci-info: "npm:3.8.0" commander: "npm:8.3.0" - eslint-config-custom: "npm:4.15.4" + eslint-config-custom: "npm:4.15.5" execa: "npm:5.1.1" fs-extra: "npm:10.0.0" inquirer: "npm:8.2.5" ora: "npm:5.4.1" - tsconfig: "npm:4.15.4" + tsconfig: "npm:4.15.5" bin: create-strapi-starter: ./bin/index.js languageName: unknown @@ -17392,7 +17465,7 @@ __metadata: languageName: node linkType: hard -"eslint-config-custom@npm:4.15.4, eslint-config-custom@workspace:*, eslint-config-custom@workspace:packages/utils/eslint-config-custom": +"eslint-config-custom@npm:4.15.5, eslint-config-custom@workspace:*, eslint-config-custom@workspace:packages/utils/eslint-config-custom": version: 0.0.0-use.local resolution: "eslint-config-custom@workspace:packages/utils/eslint-config-custom" languageName: unknown @@ -19327,16 +19400,16 @@ __metadata: resolution: "getstarted@workspace:examples/getstarted" dependencies: "@strapi/icons": "npm:1.11.0" - "@strapi/plugin-color-picker": "npm:4.15.4" - "@strapi/plugin-documentation": "npm:4.15.4" - "@strapi/plugin-graphql": "npm:4.15.4" - "@strapi/plugin-i18n": "npm:4.15.4" - "@strapi/plugin-sentry": "npm:4.15.4" - "@strapi/plugin-users-permissions": "npm:4.15.4" - "@strapi/provider-email-mailgun": "npm:4.15.4" - "@strapi/provider-upload-aws-s3": "npm:4.15.4" - "@strapi/provider-upload-cloudinary": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" + "@strapi/plugin-color-picker": "npm:4.15.5" + "@strapi/plugin-documentation": "npm:4.15.5" + "@strapi/plugin-graphql": "npm:4.15.5" + "@strapi/plugin-i18n": "npm:4.15.5" + "@strapi/plugin-sentry": "npm:4.15.5" + "@strapi/plugin-users-permissions": "npm:4.15.5" + "@strapi/provider-email-mailgun": "npm:4.15.5" + "@strapi/provider-upload-aws-s3": "npm:4.15.5" + "@strapi/provider-upload-cloudinary": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" better-sqlite3: "npm:8.6.0" lodash: "npm:4.17.21" mysql: "npm:2.18.1" @@ -22933,9 +23006,9 @@ __metadata: version: 0.0.0-use.local resolution: "kitchensink-ts@workspace:examples/kitchensink-ts" dependencies: - "@strapi/plugin-i18n": "npm:4.15.4" - "@strapi/plugin-users-permissions": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" + "@strapi/plugin-i18n": "npm:4.15.5" + "@strapi/plugin-users-permissions": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" better-sqlite3: "npm:8.6.0" react: "npm:^18.2.0" react-dom: "npm:^18.2.0" @@ -22948,10 +23021,10 @@ __metadata: version: 0.0.0-use.local resolution: "kitchensink@workspace:examples/kitchensink" dependencies: - "@strapi/provider-email-mailgun": "npm:4.15.4" - "@strapi/provider-upload-aws-s3": "npm:4.15.4" - "@strapi/provider-upload-cloudinary": "npm:4.15.4" - "@strapi/strapi": "npm:4.15.4" + "@strapi/provider-email-mailgun": "npm:4.15.5" + "@strapi/provider-upload-aws-s3": "npm:4.15.5" + "@strapi/provider-upload-cloudinary": "npm:4.15.5" + "@strapi/strapi": "npm:4.15.5" lodash: "npm:4.17.21" mysql: "npm:2.18.1" mysql2: "npm:3.6.0" @@ -31929,7 +32002,7 @@ __metadata: languageName: node linkType: hard -"tsconfig@npm:4.15.4, tsconfig@workspace:packages/utils/tsconfig": +"tsconfig@npm:4.15.5, tsconfig@workspace:packages/utils/tsconfig": version: 0.0.0-use.local resolution: "tsconfig@workspace:packages/utils/tsconfig" dependencies: