Update UI Packages

Align with Lidarr
This commit is contained in:
Qstick
2023-01-23 22:53:16 -06:00
parent fbdc9f3a13
commit 1caa49c895
330 changed files with 3555 additions and 4096 deletions
+17 -17
View File
@@ -99,14 +99,14 @@ class AuthorIndex extends Component {
setScrollerRef = (ref) => {
this.setState({ scroller: ref });
}
};
getSelectedIds = () => {
if (this.state.allUnselected) {
return [];
}
return getSelectedIds(this.state.selectedState);
}
};
setSelectedState() {
const {
@@ -192,19 +192,19 @@ class AuthorIndex extends Component {
onPosterOptionsPress = () => {
this.setState({ isPosterOptionsModalOpen: true });
}
};
onPosterOptionsModalClose = () => {
this.setState({ isPosterOptionsModalOpen: false });
}
};
onOverviewOptionsPress = () => {
this.setState({ isOverviewOptionsModalOpen: true });
}
};
onOverviewOptionsModalClose = () => {
this.setState({ isOverviewOptionsModalOpen: false });
}
};
onEditorTogglePress = () => {
if (this.state.isEditorActive) {
@@ -214,36 +214,36 @@ class AuthorIndex extends Component {
newState.isEditorActive = true;
this.setState(newState);
}
}
};
onJumpBarItemPress = (jumpToCharacter) => {
this.setState({ jumpToCharacter });
}
};
onSelectAllChange = ({ value }) => {
this.setState(selectAll(this.state.selectedState, value));
}
};
onSelectAllPress = () => {
this.onSelectAllChange({ value: !this.state.allSelected });
}
};
onSelectedChange = ({ id, value, shiftKey = false }) => {
this.setState((state) => {
return toggleSelected(state, this.props.items, id, value, shiftKey);
});
}
};
onSaveSelected = (changes) => {
this.props.onSaveSelected({
authorIds: this.getSelectedIds(),
...changes
});
}
};
onOrganizeAuthorPress = () => {
this.setState({ isOrganizingAuthorModalOpen: true });
}
};
onOrganizeAuthorModalClose = (organized) => {
this.setState({ isOrganizingAuthorModalOpen: false });
@@ -251,11 +251,11 @@ class AuthorIndex extends Component {
if (organized === true) {
this.onSelectAllChange({ value: false });
}
}
};
onRetagAuthorPress = () => {
this.setState({ isRetaggingAuthorModalOpen: true });
}
};
onRetagAuthorModalClose = (organized) => {
this.setState({ isRetaggingAuthorModalOpen: false });
@@ -263,14 +263,14 @@ class AuthorIndex extends Component {
if (organized === true) {
this.onSelectAllChange({ value: false });
}
}
};
onRefreshAuthorPress = () => {
const selectedIds = this.getSelectedIds();
const refreshIds = this.state.isEditorActive && selectedIds.length > 0 ? selectedIds : [];
this.props.onRefreshAuthorPress(refreshIds);
}
};
//
// Render
@@ -85,15 +85,15 @@ class AuthorIndexConnector extends Component {
onViewSelect = (view) => {
this.props.dispatchSetAuthorView(view);
}
};
onSaveSelected = (payload) => {
this.props.dispatchSaveAuthorEditor(payload);
}
};
onScroll = ({ scrollTop }) => {
scrollPositions.authorIndex = scrollTop;
}
};
//
// Render
@@ -98,14 +98,14 @@ class AuthorIndexItemConnector extends Component {
name: commandNames.REFRESH_AUTHOR,
authorId: this.props.id
});
}
};
onSearchPress = () => {
this.props.dispatchExecuteCommand({
name: commandNames.AUTHOR_SEARCH,
authorId: this.props.id
});
}
};
//
// Render
@@ -51,22 +51,22 @@ class AuthorIndexOverview extends Component {
onEditAuthorPress = () => {
this.setState({ isEditAuthorModalOpen: true });
}
};
onEditAuthorModalClose = () => {
this.setState({ isEditAuthorModalOpen: false });
}
};
onDeleteAuthorPress = () => {
this.setState({
isEditAuthorModalOpen: false,
isDeleteAuthorModalOpen: true
});
}
};
onDeleteAuthorModalClose = () => {
this.setState({ isDeleteAuthorModalOpen: false });
}
};
onChange = ({ value, shiftKey }) => {
const {
@@ -75,7 +75,7 @@ class AuthorIndexOverview extends Component {
} = this.props;
onSelectedChange({ id, value, shiftKey });
}
};
//
// Render
@@ -123,7 +123,7 @@ class AuthorIndexOverviews extends Component {
setGridRef = (ref) => {
this._grid = ref;
}
};
calculateGrid = (width = this.state.width, isSmallScreen) => {
const {
@@ -141,7 +141,7 @@ class AuthorIndexOverviews extends Component {
posterHeight,
rowHeight
});
}
};
cellRenderer = ({ key, rowIndex, style }) => {
const {
@@ -197,14 +197,14 @@ class AuthorIndexOverviews extends Component {
/>
</div>
);
}
};
//
// Listeners
onMeasure = ({ width }) => {
this.calculateGrid(width, this.props.isSmallScreen);
}
};
//
// Render
@@ -122,7 +122,7 @@ class AuthorIndexOverviewOptionsModalContent extends Component {
}, () => {
this.props.onChangeOverviewOption({ [name]: value });
});
}
};
//
// Render
@@ -35,34 +35,34 @@ class AuthorIndexPoster extends Component {
onEditAuthorPress = () => {
this.setState({ isEditAuthorModalOpen: true });
}
};
onEditAuthorModalClose = () => {
this.setState({ isEditAuthorModalOpen: false });
}
};
onDeleteAuthorPress = () => {
this.setState({
isEditAuthorModalOpen: false,
isDeleteAuthorModalOpen: true
});
}
};
onDeleteAuthorModalClose = () => {
this.setState({ isDeleteAuthorModalOpen: false });
}
};
onPosterLoad = () => {
if (this.state.hasPosterError) {
this.setState({ hasPosterError: false });
}
}
};
onPosterLoadError = () => {
if (!this.state.hasPosterError) {
this.setState({ hasPosterError: true });
}
}
};
onChange = ({ value, shiftKey }) => {
const {
@@ -71,7 +71,7 @@ class AuthorIndexPoster extends Component {
} = this.props;
onSelectedChange({ id, value, shiftKey });
}
};
//
// Render
@@ -171,7 +171,7 @@ class AuthorIndexPosters extends Component {
setGridRef = (ref) => {
this._grid = ref;
}
};
calculateGrid = (width = this.state.width, isSmallScreen) => {
const {
@@ -193,7 +193,7 @@ class AuthorIndexPosters extends Component {
posterHeight,
rowHeight
});
}
};
cellRenderer = ({ key, rowIndex, columnIndex, style }) => {
const {
@@ -259,14 +259,14 @@ class AuthorIndexPosters extends Component {
/>
</div>
);
}
};
//
// Listeners
onMeasure = ({ width }) => {
this.calculateGrid(width, this.props.isSmallScreen);
}
};
//
// Render
@@ -93,7 +93,7 @@ class AuthorIndexPosterOptionsModalContent extends Component {
}, () => {
this.props.onChangePosterOption({ [name]: value });
});
}
};
//
// Render
@@ -27,22 +27,22 @@ class AuthorIndexActionsCell extends Component {
onEditAuthorPress = () => {
this.setState({ isEditAuthorModalOpen: true });
}
};
onEditAuthorModalClose = () => {
this.setState({ isEditAuthorModalOpen: false });
}
};
onDeleteAuthorPress = () => {
this.setState({
isEditAuthorModalOpen: false,
isDeleteAuthorModalOpen: true
});
}
};
onDeleteAuthorModalClose = () => {
this.setState({ isDeleteAuthorModalOpen: false });
}
};
//
// Render
@@ -40,39 +40,39 @@ class AuthorIndexRow extends Component {
onEditAuthorPress = () => {
this.setState({ isEditAuthorModalOpen: true });
}
};
onEditAuthorModalClose = () => {
this.setState({ isEditAuthorModalOpen: false });
}
};
onDeleteAuthorPress = () => {
this.setState({
isEditAuthorModalOpen: false,
isDeleteAuthorModalOpen: true
});
}
};
onDeleteAuthorModalClose = () => {
this.setState({ isDeleteAuthorModalOpen: false });
}
};
onUseSceneNumberingChange = () => {
// Mock handler to satisfy `onChange` being required for `CheckInput`.
//
}
};
onBannerLoad = () => {
if (this.state.hasBannerError) {
this.setState({ hasBannerError: false });
}
}
};
onBannerLoadError = () => {
if (!this.state.hasBannerError) {
this.setState({ hasBannerError: true });
}
}
};
//
// Render
@@ -78,7 +78,7 @@ class AuthorIndexTable extends Component {
/>
</VirtualTableRow>
);
}
};
//
// Render
@@ -60,7 +60,7 @@ class AuthorIndexTableOptions extends Component {
}
});
});
}
};
//
// Render