Skip to content

Commit

Permalink
misc: final update of settings page
Browse files Browse the repository at this point in the history
- Comb through the whole settings page and update it to be more in line with the new documentation. It is not a 1:1 copy of the docs, but very close.

[skip ci]
  • Loading branch information
revam committed Oct 10, 2024
1 parent f11bef4 commit e163f99
Show file tree
Hide file tree
Showing 3 changed files with 198 additions and 207 deletions.
5 changes: 2 additions & 3 deletions Shokofin/Pages/Scripts/Common.js
Original file line number Diff line number Diff line change
Expand Up @@ -973,9 +973,8 @@ function onLinkRedirectClick(event) {
* @returns {void} Void.
*/
function overrideLink(target) {
const href = target.getAttribute("href");
target.dataset.href = href;
target.href = location.href.split("#")[0] + "#" + getConfigurationPageUrl(href);
const page = target.dataset.page;
target.href = location.href.split("#")[0] + "#" + getConfigurationPageUrl(page);
target.addEventListener("click", onLinkRedirectClick);
}

Expand Down
4 changes: 2 additions & 2 deletions Shokofin/Pages/Scripts/Settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ function applyFormToConfig(form, config) {
config.UseGroupsForShows = form.querySelector("#UseGroupsForShows").checked;
config.SeasonOrdering = form.querySelector("#SeasonOrdering").value;
config.SeparateMovies = form.querySelector("#SeparateMovies").checked;
config.FilterMovieLibraries = form.querySelector("#FilterMovieLibraries").checked;
config.FilterMovieLibraries = !form.querySelector("#DisableFilterMovieLibraries").checked;
config.SpecialsPlacement = form.querySelector("#SpecialsPlacement").value;
config.MovieSpecialsAsExtraFeaturettes = form.querySelector("#MovieSpecialsAsExtraFeaturettes").checked;
config.AddMissingMetadata = form.querySelector("#AddMissingMetadata").checked;
Expand Down Expand Up @@ -576,7 +576,7 @@ async function applyConfigToForm(form, config) {
}
form.querySelector("#SeasonOrdering").value = config.SeasonOrdering;
form.querySelector("#SeparateMovies").checked = config.SeparateMovies;
form.querySelector("#FilterMovieLibraries").checked = config.FilterMovieLibraries;
form.querySelector("#DisableFilterMovieLibraries").checked = !config.FilterMovieLibraries;
form.querySelector("#SpecialsPlacement").value = config.SpecialsPlacement === "Default" ? "AfterSeason" : config.SpecialsPlacement;
form.querySelector("#MovieSpecialsAsExtraFeaturettes").checked = config.MovieSpecialsAsExtraFeaturettes;
form.querySelector("#AddMissingMetadata").checked = config.AddMissingMetadata;
Expand Down
Loading

0 comments on commit e163f99

Please sign in to comment.