Skip to content

Commit

Permalink
fix ci issues caused by typescript upgrade (#4229)
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaskikutis authored Apr 11, 2023
1 parent f61daef commit 9ee9729
Show file tree
Hide file tree
Showing 9 changed files with 279 additions and 74 deletions.
322 changes: 269 additions & 53 deletions package-lock.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"@types/react-autocomplete": "1.8.5",
"@types/react-dom": "16.8.0",
"@types/react-redux": "7.1.9",
"@typescript-eslint/parser": "2.16.0",
"@typescript-eslint/parser": "5.57.0",
"angular": "1.6.9",
"angular-contenteditable": "0.3.9",
"angular-dynamic-locale": "0.1.32",
Expand Down Expand Up @@ -119,7 +119,7 @@
"sass-loader": "6.0.6",
"shortid": "2.2.8",
"style-loader": "0.20.2",
"superdesk-ui-framework": "3.0.0-rc12",
"superdesk-ui-framework": "3.0.14",
"ts-loader": "3.5.0",
"tslint": "5.11.0",
"typescript": "~4.9.5",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ export class UploadAttachmentsModal extends React.PureComponent<IProps, IState>
<div className="other-info">
<div className="form__row">
<Switch
label={{text: gettext('Internal'), hidden: true}}
label={{content: gettext('Internal'), hidden: true}}
value={item.meta.internal}
onChange={(value) => {
this.updateItemMeta(index, 'internal', value);
Expand Down
4 changes: 2 additions & 2 deletions scripts/apps/master-desk/components/HeaderComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ export class HeaderComponent extends React.Component<IProps, IState> {
<label>{gettext('Show all')}</label>
<div className="pull-right">
<Switch
label={{text: gettext('Show all'), hidden: true}}
label={{content: gettext('Show all'), hidden: true}}
value={this.state.showAllDesks}
onChange={() => this.toggleShowAll()}
/>
Expand All @@ -240,7 +240,7 @@ export class HeaderComponent extends React.Component<IProps, IState> {
<label>{item.name}</label>
<div className="pull-right">
<Switch
label={{text: item.name, hidden: true}}
label={{content: item.name, hidden: true}}
value={this.isDeskActive(item)}
onChange={() => this.toggleDesk(item)}
/>
Expand Down
4 changes: 2 additions & 2 deletions scripts/extensions/auto-tagging-widget/src/auto-tagging.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ export function getAutoTaggingComponent(superdesk: ISuperdesk, label: string) {
this.runAnalysis();
}
}}
label={{text: gettext('Run automatically')}}
label={{content: gettext('Run automatically')}}
/>
<Switch
value={showImagesPreference}
Expand All @@ -490,7 +490,7 @@ export function getAutoTaggingComponent(superdesk: ISuperdesk, label: string) {
this.setState({showImagesPreference: newValue});
superdesk.preferences.set(SHOW_IMAGES_PREFERENCE, newValue);
}}
label={{text: gettext('Show image suggestions')}}
label={{content: gettext('Show image suggestions')}}
/>
</ButtonGroup>
</div>
Expand Down
2 changes: 1 addition & 1 deletion scripts/extensions/datetimeField/src/getDateTimeField.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export function getDateTimeField(superdesk: ISuperdesk) {
render() {
const checkbox = this.props.hideToggle !== true ? (
<Switch
label={{text: ''}}
label={{content: ''}}
value={this.props.value != null}
onChange={(value) => {
if (value) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export function getToggleDateTimeField(superdesk: ISuperdesk) {
const initialConfig = this.props?.config?.initial_offset_minutes;
const checkbox = (
<Switch
label={{text: ''}}
label={{content: ''}}
value={this.props.value != null}
onChange={(value) => {
if (value) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ export class SetEditorPanelComponent extends React.Component<IProps, IState> {
<FormGroup>
<FormRow>
<Switch
label={{text: gettext('Enabled'), side: 'left'}}
label={{content: gettext('Enabled'), side: 'left'}}
value={updates.state === SET_STATE.USABLE}
onChange={this.onChange.state}
/>
Expand Down
11 changes: 0 additions & 11 deletions scripts/extensions/sams/src/store/assets/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,17 +40,6 @@ interface IAssetSetListStyleAction {
payload: ASSET_LIST_STYLE;
}

export interface IAssetState {
assets: Dictionary<string, IAssetItem>;
searchParams: IAssetSearchParams;
selectedAssetId?: string;
selectedAssetIds: Array<string>;
listItemIds: Array<string>;
searchResultTotal: number;
listStyle: ASSET_LIST_STYLE;
contentPanelState: ASSET_CONTENT_PANEL_STATE;
}

export const MANAGE_ASSETS_PREVIEW = 'manage_assets__preview';
interface IPreviewAssetAction {
type: typeof MANAGE_ASSETS_PREVIEW;
Expand Down

0 comments on commit 9ee9729

Please sign in to comment.