Skip to content

Commit dbbefcd

Browse files
authored
Move stateful imports into sdk (#1549)
* Move stateful imports into sdk * Apply eslint-fixer changes * Automatic frontend build --------- Co-authored-by: vin0401 <[email protected]>
1 parent 32e21ad commit dbbefcd

File tree

650 files changed

+17148
-13126
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

650 files changed

+17148
-13126
lines changed

assets/build/api/openapi-config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const pathMatcher = (pattern: RegExp): EndpointMatcherFunction => {
2222

2323
const config: ConfigFile = {
2424
schemaFile: './docs.jsonopenapi.json',
25-
apiFile: '../../js/src/core/app/api/pimcore/index.ts',
25+
apiFile: '@sdk/api',
2626
apiImport: 'api',
2727
endpointOverrides: [
2828
{

assets/bundler/plugins/entrypoints-generate/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,9 @@ const generateEntrypoints = (data: data, devServer?: DevServerContext): Entrypoi
4444

4545
entrypoints.entrypoints[key] = {
4646
js: [
47-
...value?.async?.js ?? [],
4847
...value?.initial?.js ?? [],
4948
],
5049
css: [
51-
...value?.async?.css ?? [],
5250
...value?.initial?.css ?? [],
5351
]
5452
}

assets/js/src/core/app/i18n/helper/translation-helper.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { store } from '@Pimcore/app/store'
11+
import { store } from '@sdk/app'
1212
import { api as translationApi } from '@Pimcore/modules/app/translations/translations-api-slice.gen'
1313

1414
export const addNewTranslations = async (translations: string[]): Promise<void> => {

assets/js/src/core/app/i18n/store/missingTranslations.slice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { addAppMiddleware, injectSliceWithState, type RootState } from '@Pimcore/app/store'
11+
import { addAppMiddleware, injectSliceWithState, type RootState } from '@sdk/app'
1212
import { createListenerMiddleware, createSlice } from '@reduxjs/toolkit'
1313
import { debounce } from 'lodash'
1414
import { addNewTranslations } from '../helper/translation-helper'

assets/js/src/core/app/plugin-system/plugin-system.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
import { container } from '@Pimcore/app/depency-injection'
1212
import { type Container } from 'inversify'
1313
import { moduleSystem } from '../module-system/module-system'
14-
import { init, loadRemote } from '@module-federation/enhanced/runtime'
14+
import { getInstance, type init, loadRemote } from '@module-federation/enhanced/runtime'
1515

1616
export interface ILifeCycleEvents {
1717
onInit?: (config: { container: Container }) => void
@@ -47,7 +47,7 @@ export class PluginSystem {
4747
}
4848
}
4949

50-
init(initConfig)
50+
getInstance()?.registerRemotes(initConfig.remotes)
5151

5252
for (const remote of initConfig.remotes) {
5353
promises.push(loadRemote(remote.alias!))

assets/js/src/core/app/store/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import { type Reducer, combineSlices, configureStore, type CombinedSliceReducer, createDynamicMiddleware, type MiddlewareApiConfig } from '@reduxjs/toolkit'
1212
import { type TypedUseSelectorHook, useDispatch, useSelector } from 'react-redux'
13-
import { api as pimcoreApi } from '@Pimcore/app/api/pimcore'
13+
import { api as pimcoreApi } from '@sdk/api'
1414
import { rtkQueryErrorLogger } from './middleware/rtkQueryErrorLogger'
1515

1616
// eslint-disable-next-line @typescript-eslint/no-empty-interface

assets/js/src/core/components/breadcrumb/breadcrumb.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import React, { useEffect, useRef, useState, type ReactElement, type CSSProperti
1212
import { Breadcrumb as AntBreadcrumb, type MenuItemProps, type BreadcrumbProps as AntBreadcrumbProps } from 'antd'
1313
import { type BreadcrumbItemType, type ItemType } from 'antd/es/breadcrumb/Breadcrumb'
1414
import cn from 'classnames'
15-
import { useAppDispatch } from '@Pimcore/app/store'
15+
import { useAppDispatch } from '@sdk/app'
1616
import { api as elementApi } from '@Pimcore/modules/element/element-api-slice.gen'
1717
import { useElementHelper } from '@Pimcore/modules/element/hooks/use-element-helper'
1818
import { Text } from '@Pimcore/components/text/text'

assets/js/src/core/components/drag-and-drop/__STORIES__/dnd-demo-droppable-content.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import React, { type MutableRefObject, forwardRef, useContext } from 'react'
1212
import { useStyle } from './dnd-demo-droppable-content.styles'
13-
import { droppableContext } from '../droppable-context-provider'
13+
import { droppableContext } from '@sdk/components'
1414

1515
interface DNDDemoDroppableContentProps {
1616
value: string

assets/js/src/core/components/drag-and-drop/drag-and-drop.stories.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import { Draggable } from './draggable'
1414
import { DNDDemoDroppableContent } from './__STORIES__/dnd-demo-droppable-content'
1515
import { Button } from '../button/button'
1616
import { Droppable } from './droppable'
17-
import { type DragAndDropInfo } from './context-provider'
17+
import { type DragAndDropInfo } from '@sdk/components'
1818

1919
const DragAndDropDemo = (): React.JSX.Element => {
2020
const [valueDemo1, setValueDemo1] = useState<any>('')

assets/js/src/core/components/drag-and-drop/drag-overlay.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010

1111
import React from 'react'
12-
import { type DragAndDropInfo } from './context-provider'
12+
import { type DragAndDropInfo } from '@sdk/components'
1313
import { Icon } from '../icon/icon'
1414
import { useStyle } from './drag-overlay.styles'
1515

assets/js/src/core/components/drag-and-drop/draggable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import React, { Children, isValidElement, useMemo, useState } from 'react'
1212
import { useDraggable } from '@dnd-kit/core'
13-
import { type DragAndDropInfo } from './context-provider'
13+
import { type DragAndDropInfo } from '@sdk/components'
1414
import { uuid } from '@Pimcore/utils/uuid'
1515
import { GlobalStyle } from './draggable.styles'
1616
import trackError, { GeneralError } from '@Pimcore/modules/app/error-handler'

assets/js/src/core/components/drag-and-drop/droppable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010

1111
import React, { type ReactNode, useContext, useEffect, useMemo, useState } from 'react'
12-
import { type DragAndDropInfo, DragAndDropInfoContext } from './context-provider'
12+
import { type DragAndDropInfo, DragAndDropInfoContext } from '@sdk/components'
1313
import { type UniqueIdentifier, useDroppable } from '@dnd-kit/core'
1414
import { uuid } from '@Pimcore/utils/uuid'
1515
import { BaseDroppable } from '@Pimcore/components/drag-and-drop/droppable/base-droppable'

assets/js/src/core/components/drag-and-drop/droppable/base-droppable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import React, { Children, isValidElement, type ReactNode, type RefCallback, useMemo, useState } from 'react'
1212
import cn from 'classnames'
13-
import { DroppableContextProvider } from '@Pimcore/components/drag-and-drop/droppable-context-provider'
13+
import { DroppableContextProvider } from '@sdk/components'
1414
import trackError, { GeneralError } from '@Pimcore/modules/app/error-handler'
1515
import { useStyle } from './base-droppable.styles'
1616
import { uuid } from '@Pimcore/utils/uuid'

assets/js/src/core/components/drag-and-drop/hooks/use-droppable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010

1111
import { useContext } from 'react'
12-
import { type IDroppableContext, droppableContext } from '../droppable-context-provider'
12+
import { type IDroppableContext, droppableContext } from '@sdk/components'
1313

1414
interface DroppableHookReturn extends IDroppableContext {
1515
getStateClasses: () => string[]

assets/js/src/core/components/element-tree/element-tree-slice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
/* eslint-disable max-lines */
1212
import { createSlice, type PayloadAction } from '@reduxjs/toolkit'
13-
import { injectSliceWithState, type RootState } from '@Pimcore/app/store'
13+
import { injectSliceWithState, type RootState } from '@sdk/app'
1414
import { isEqual, isUndefined } from 'lodash'
1515
import { createSelector } from 'reselect'
1616
import { type TreeLevelData } from '@Pimcore/modules/element/element-api-slice.gen'

assets/js/src/core/components/element-tree/hooks/use-element-tree-node.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { type RootState, useAppDispatch } from '@Pimcore/app/store'
11+
import { type RootState, useAppDispatch } from '@sdk/app'
1212
import { type InternalNodeState, selectNodeState, setFetchTriggered } from '../element-tree-slice'
1313
import { useSelector } from 'react-redux'
1414
import { useTreeId } from '@Pimcore/modules/element/tree/provider/tree-id-provider/use-tree-id'

assets/js/src/core/components/element-tree/hooks/use-element-tree.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { store, useAppDispatch } from '@Pimcore/app/store'
11+
import { store, useAppDispatch } from '@sdk/app'
1212
import { type InternalNodeState, selectNodeState, setNodeExpanded, setNodeLoading, setNodePage, setNodeSearchTerm, setSelectedNodeIds, setNodeScrollTo, updateNodesByParentId, setNodeFetching, setNodeHasChildren } from '../element-tree-slice'
1313
import { isUndefined } from 'lodash'
1414
import { type DataTransformerReturnType, type DataTransformerSourceNode } from '../types/node-api-hook'

assets/js/src/core/components/focal-point/focal-point.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
import React, { useContext, useEffect, useRef, useState } from 'react'
1212
import { isNull, isUndefined } from 'lodash'
1313
import { useAssetDraft } from '@Pimcore/modules/asset/hooks/use-asset-draft'
14-
import { AssetContext } from '@Pimcore/modules/asset/asset-provider'
14+
import { AssetContext } from '@sdk/modules/asset'
1515
import { FocalPointContext } from '@Pimcore/components/focal-point/context/focal-point-context'
1616
import trackError, { GeneralError } from '@Pimcore/modules/app/error-handler'
1717
import { IconButton } from '@Pimcore/components/icon-button/icon-button'

assets/js/src/core/components/grid/grid.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ export const Grid = ({
9191
...props
9292
}: GridProps): React.JSX.Element => {
9393
const { t } = useTranslation()
94-
const hashId = useCssComponentHash('table')
94+
const hashId = useCssComponentHash()
9595
const { styles } = useStyles()
9696
const [columnResizeMode] = useState<ColumnResizeMode>('onChange')
9797
const [activeCell, setActiveCell] = useState<GridCellReference | undefined>()

assets/js/src/core/components/modal-upload/modal-upload.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import React, { useState, useEffect } from 'react'
1212
import { Upload as AntUpload, type UploadProps as AntUploadProps } from 'antd'
1313
import { api as assetApi, type Asset } from '@Pimcore/modules/asset/asset-api-slice-enhanced'
1414
import type { RcFile, UploadFile } from 'antd/es/upload/interface'
15-
import { useAppDispatch } from '@Pimcore/app/store'
15+
import { useAppDispatch } from '@sdk/app'
1616
import { getPrefix } from '@Pimcore/app/api/pimcore/route'
1717
import { api as elementApi } from '@Pimcore/modules/element/element-api-slice.gen'
1818
import { isEmpty, isString, isUndefined } from 'lodash'

assets/js/src/core/components/pagination/pagination.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export const Pagination = ({
4343
}: PaginationProps): React.JSX.Element => {
4444
const { styles } = useStyle()
4545

46-
const hashId = useCssComponentHash('pagination')
46+
const hashId = useCssComponentHash()
4747

4848
const [currentPage, setCurrentPage] = useState<number>(current)
4949
const [pageSize, setPageSize] = useState<number>(defaultPageSize)

assets/js/src/core/modules/ant-design/hooks/use-css-component-hash.ts

Lines changed: 4 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -8,30 +8,11 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import useTableStyle from 'antd/es/table/style'
12-
import usePaginationStyle from 'antd/es/pagination/style'
13-
import { ConfigContext } from 'antd/es/config-provider/context'
14-
import { useContext } from 'react'
11+
import { theme } from 'antd'
12+
const { useToken } = theme
1513

16-
export const useCssComponentHash = (componentName: string): string => {
17-
const context = useContext(ConfigContext)
18-
const prefix = context.getPrefixCls(componentName, '')
19-
20-
const tableHashId = useTableStyle(prefix)[1]
21-
const paginationHashId = usePaginationStyle(prefix)[1]
22-
23-
let hashId
24-
switch (componentName) {
25-
case 'table':
26-
hashId = tableHashId
27-
break
28-
case 'pagination':
29-
hashId = paginationHashId
30-
break
31-
32-
default:
33-
hashId = ''
34-
}
14+
export const useCssComponentHash = (): string => {
15+
const { hashId } = useToken()
3516

3617
return hashId
3718
}

assets/js/src/core/modules/app/app-loader/app-loader.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010

1111
import React, { useEffect, useState } from 'react'
12-
import { store } from '@Pimcore/app/store'
12+
import { store } from '@sdk/app'
1313
import { Content } from '@Pimcore/components/content/content'
1414
import { GlobalStyles } from '@Pimcore/styles/global.styles'
1515
import { useAlertModal } from '@Pimcore/components/modal/alert-modal/hooks/use-alert-modal'

assets/js/src/core/modules/app/app-loader/loader/settings/loader.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { useAppDispatch } from '@Pimcore/app/store'
11+
import { useAppDispatch } from '@sdk/app'
1212
import trackError, { ApiError } from '@Pimcore/modules/app/error-handler'
1313
import { setSettings } from '@Pimcore/modules/app/settings/settings-slice'
1414
import { api } from '@Pimcore/modules/app/settings/settings-slice.gen'

assets/js/src/core/modules/app/app-loader/loader/translation/loader.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010

1111
import i18n, { FALLBACK_LANGUAGE } from '@Pimcore/app/i18n'
12-
import { store } from '@Pimcore/app/store'
12+
import { store } from '@sdk/app'
1313
import trackError, { GeneralError } from '@Pimcore/modules/app/error-handler'
1414
import { useTranslationGetCollectionMutation } from '@Pimcore/modules/app/translations/translations-api-slice.gen'
1515
import { selectCurrentUser } from '@Pimcore/modules/auth/user/user-slice'

assets/js/src/core/modules/app/app-loader/loader/user/loader.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { useAppDispatch } from '@Pimcore/app/store'
11+
import { useAppDispatch } from '@sdk/app'
1212
import trackError, { ApiError, GeneralError } from '@Pimcore/modules/app/error-handler'
1313
import { setUser } from '@Pimcore/modules/auth/user/user-slice'
1414
import { api } from '@Pimcore/modules/user/user-api-slice-enhanced'

assets/js/src/core/modules/app/default-page.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,15 @@ import { Background } from '@Pimcore/components/background/background'
1212
import { BaseLayoutView } from '@Pimcore/modules/app/base-layout/base-layout-view'
1313
import React from 'react'
1414
import { ClassDefinitionsProvider } from '../data-object/utils/provider/class-defintions/class-definitions-provider'
15-
import { ElementSelectorProvider } from '../element/element-selector/provider/element-selector/element-selector-provider'
15+
import { ElementSelectorProvider } from '@sdk/modules/element'
1616
import { useHandleDeepLink } from './hook/use-handle-deeplink'
17+
import useTableStyle from 'antd/es/table/style'
18+
import usePaginationStyle from 'antd/es/pagination/style'
1719

1820
export const DefaultPage = (): React.JSX.Element => {
1921
useHandleDeepLink()
22+
useTableStyle('ant-table')
23+
usePaginationStyle('ant-pagination')
2024

2125
const preventDrop = (event: React.DragEvent<HTMLDivElement>): void => {
2226
event.preventDefault()

assets/js/src/core/modules/app/global-context/global-context-slice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { type RootState, injectSliceWithState } from '@Pimcore/app/store'
11+
import { type RootState, injectSliceWithState } from '@sdk/app'
1212
import { type PayloadAction, createSlice } from '@reduxjs/toolkit'
1313

1414
export interface GlobalContext {

assets/js/src/core/modules/app/global-provider.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@
99
*/
1010

1111
import { ContainerProvider } from '@Pimcore/app/depency-injection'
12-
import { store } from '@Pimcore/app/store'
13-
import { DragAndDropContextProvider } from '@Pimcore/components/drag-and-drop/context-provider'
12+
import { store } from '@sdk/app'
13+
import { DragAndDropContextProvider } from '@sdk/components'
1414
import { ThemeProvider } from '@Pimcore/modules/app/theme/theme-provider'
1515
import React from 'react'
1616
import { Provider } from 'react-redux'
17-
import { ElementSelectorProvider } from '../element/element-selector/provider/element-selector/element-selector-provider'
17+
import { ElementSelectorProvider } from '@sdk/modules/element'
1818
import { UploadModalProvider } from '@Pimcore/components/modal-upload/provider/upload-modal-provider/upload-modal-provider'
1919

2020
export interface GlobalProviderProps {

assets/js/src/core/modules/app/mercure-api-slice.gen.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { api } from "../../app/api/pimcore/index";
1+
import { api } from "@sdk/api";
22
export const addTagTypes = ["Mercure"] as const;
33
const injectedRtkApi = api
44
.enhanceEndpoints({

assets/js/src/core/modules/app/settings/settings-slice.gen.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { api } from "../../../app/api/pimcore/index";
1+
import { api } from "@sdk/api";
22
export const addTagTypes = ["Settings"] as const;
33
const injectedRtkApi = api
44
.enhanceEndpoints({

assets/js/src/core/modules/app/settings/settings-slice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import type { PayloadAction } from '@reduxjs/toolkit'
1212
import { createSlice } from '@reduxjs/toolkit'
13-
import { injectSliceWithState, type RootState } from '@Pimcore/app/store'
13+
import { injectSliceWithState, type RootState } from '@sdk/app'
1414
import { type SystemSettingsGetApiResponse } from '@Pimcore/modules/app/settings/settings-slice.gen'
1515

1616
const initialState: SystemSettingsGetApiResponse = {}

assets/js/src/core/modules/app/translations/translations-api-slice.gen.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { api } from "../../../app/api/pimcore/index";
1+
import { api } from "@sdk/api";
22
export const addTagTypes = ["Translation"] as const;
33
const injectedRtkApi = api
44
.enhanceEndpoints({

assets/js/src/core/modules/asset/asset-api-slice.gen.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { api } from "../../app/api/pimcore/index";
1+
import { api } from "@sdk/api";
22
export const addTagTypes = ["Assets", "Asset Grid", "Metadata"] as const;
33
const injectedRtkApi = api
44
.enhanceEndpoints({

assets/js/src/core/modules/asset/asset-draft-error-slice.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* @license Pimcore Open Core License (POCL)
99
*/
1010

11-
import { injectSliceWithState } from '@Pimcore/app/store'
11+
import { injectSliceWithState } from '@sdk/app'
1212
import { createSlice, type PayloadAction } from '@reduxjs/toolkit'
1313

1414
export interface AssetDraftErrorState {

assets/js/src/core/modules/asset/asset-draft-slice.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import { type PayloadAction, createEntityAdapter, createSlice } from '@reduxjs/toolkit'
1212
import { type Asset, type ImageData } from './asset-api-slice-enhanced'
13-
import { type RootState, injectSliceWithState } from '@Pimcore/app/store'
13+
import { type RootState, injectSliceWithState } from '@sdk/app'
1414
import { type PropertiesDraft, usePropertiesReducers } from '@Pimcore/modules/element/draft/hooks/use-properties'
1515
import { type EntityAdapter } from '@reduxjs/toolkit/src/entities/models'
1616
import { type CustomMetadataDraft, useCustomMetadataReducers } from '@Pimcore/modules/asset/draft/hooks/use-custom-metadata'

assets/js/src/core/modules/asset/draft/hooks/use-custom-metadata.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
import type { ActionCreatorWithPayload, PayloadAction } from '@reduxjs/toolkit'
1212
import type { EntityAdapter, EntityState } from '@reduxjs/toolkit/src/entities/models'
1313

14-
import { useAppDispatch } from '@Pimcore/app/store'
14+
import { useAppDispatch } from '@sdk/app'
1515
import type {
1616
CustomMetadata as CustomMetadataApi
1717
} from '@Pimcore/modules/asset/editor/shared-tab-manager/tabs/custom-metadata/metadata-api-slice-enhanced'

assets/js/src/core/modules/asset/draft/hooks/use-custom-settings.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
import type { ActionCreatorWithPayload, PayloadAction } from '@reduxjs/toolkit'
1212
import type { EntityAdapter, EntityState } from '@reduxjs/toolkit/src/entities/models'
13-
import { useAppDispatch } from '@Pimcore/app/store'
13+
import { useAppDispatch } from '@sdk/app'
1414
import type { TrackableChangesDraft } from '@Pimcore/modules/element/draft/hooks/use-trackable-changes'
1515
import { type UpdateCustomSettings } from '@Pimcore/modules/asset/asset-api-slice.gen'
1616
import { findIndex, isEmpty, isUndefined } from 'lodash'

assets/js/src/core/modules/asset/draft/hooks/use-image-settings.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
import type { ActionCreatorWithPayload, PayloadAction } from '@reduxjs/toolkit'
1212
import type { EntityAdapter, EntityState } from '@reduxjs/toolkit/src/entities/models'
1313

14-
import { useAppDispatch } from '@Pimcore/app/store'
14+
import { useAppDispatch } from '@sdk/app'
1515

1616
import { type TrackableChangesDraft } from '@Pimcore/modules/element/draft/hooks/use-trackable-changes'
1717
import type { ImageData } from '@Pimcore/modules/asset/asset-api-slice.gen'

0 commit comments

Comments
 (0)