Skip to content

Commit

Permalink
feat: remove deprecated props & methods [EXT-4467] (#1597)
Browse files Browse the repository at this point in the history
feat: remove deprecated props & methods

BREAKING CHANGE: removed deprecated props & methods
  • Loading branch information
andipaetzold authored Jul 21, 2023
1 parent e95c81a commit 7f7240b
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 26 deletions.
6 changes: 0 additions & 6 deletions lib/editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,6 @@ export default function createEditor(
onLocaleSettingsChanged: (handler) => {
return localeSettingsSignal.attach(handler)
},
/**
* @deprecated
*/
onShowDisabledFieldsChanged: (handler) => {
return showHiddenFieldsSignal.attach(handler)
},
getShowHiddenFields(): boolean {
return showHiddenFieldsSignal.getMemoizedArgs()[0]
},
Expand Down
9 changes: 0 additions & 9 deletions lib/types/api.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,15 +158,6 @@ export interface SharedEditorSDK {
callback: (localeSettings: EditorLocaleSettings) => void
) => () => void

/**
* Subscribes to changes of whether or not disabled fields are displayed
*
* @param callback Function that is called every time the setting whether or not disabled fields are displayed changes. Called immediately with the current state.
* @returns Function to unsubscribe. `callback` won't be called anymore.
* @deprecated Use {@link onShowHiddenFieldsChanged} instead
*/
onShowDisabledFieldsChanged: (callback: (showDisabledFields: boolean) => void) => () => void

/**
* Returns whether or not hidden fields are displayed
*
Expand Down
4 changes: 0 additions & 4 deletions lib/types/app.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@ interface AppStateEditorInterfaceItem {
controls?: Array<{ fieldId: string; settings?: Record<string, any> }>
sidebar?: { position: number; settings?: Record<string, any> }
editors?: { position: number; settings?: Record<string, any> }
/**
* @deprecated use `editors` instead
*/
editor?: boolean
}

export interface AppState {
Expand Down
5 changes: 0 additions & 5 deletions lib/types/entry.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,6 @@ export interface EntryAPI extends TaskAPI {
onSysChanged: (callback: (sys: EntrySys) => void) => () => void
/** Allows to control the values of all other fields in the current entry. */
fields: { [key: string]: EntryFieldAPI }
/**
* Optional metadata on an entry
* @deprecated
*/
metadata?: Metadata
getMetadata: () => Metadata | undefined
onMetadataChanged: (callback: (metadata?: Metadata) => void) => VoidFunction
}
2 changes: 0 additions & 2 deletions test/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ export const actionSelectors = {

export const widgetLocation = {
entryField: 'entry-field',
/** @deprecated */
entryFieldSidebar: 'entry-field-sidebar',
entrySidebar: 'entry-sidebar',
dialog: 'dialog',
entryEditor: 'entry-editor',
Expand Down

0 comments on commit 7f7240b

Please sign in to comment.