Skip to content

settings-level-expert: hide them by default#3487

Merged
PromoFaux merged 1 commit into
pi-hole:developmentfrom
XhmikosR:xmr/settings-expert
May 30, 2025
Merged

settings-level-expert: hide them by default#3487
PromoFaux merged 1 commit into
pi-hole:developmentfrom
XhmikosR:xmr/settings-expert

Conversation

@XhmikosR

@XhmikosR XhmikosR commented May 26, 2025

Copy link
Copy Markdown
Contributor

Matches the previous behavior before 8556b65

Thank you for your contribution to the Pi-hole Community!

Please read the comments below to help us consider your Pull Request.

We are all volunteers and completing the process outlined will help us review your commits quicker.

Please make sure you

  1. Base your code and PRs against the repositories developmental branch.
  2. Sign Off all commits as we enforce the DCO for all contributions
  3. Sign all your commits as they must have verified signatures
  4. File a pull request for any change that requires changes to our documentation at our documentation repo

What does this PR aim to accomplish?:

How does this PR accomplish the above?:

Link documentation PRs if any are needed to support this PR:


By submitting this pull request, I confirm the following:

  1. I have read and understood the contributors guide, as well as this entire template. I understand which branch to base my commits and Pull Requests against.
  2. I have commented my proposed changes within the code and I have tested my changes.
  3. I am willing to help maintain this change if there are issues with it later.
  4. It is compatible with the EUPL 1.2 license
  5. I have squashed any insignificant commits. (git rebase)
  6. I have checked that another pull request for this purpose does not exist.
  7. I have considered, and confirmed that this submission will be valuable to others.
  8. I accept that this submission may not be used, and the pull request closed at the will of the maintainer.
  9. I give this submission freely, and claim no ownership to its content.

  • I have read the above and my PR is ready for review. Check this box to confirm

@XhmikosR

Copy link
Copy Markdown
Contributor Author

To clarify the reasoning behind this change. I should have done this in 8556b65. Because without this, when the DOM loads, the expert settings elements are visible and then become hidden. This way, they are hidden by default unless the option to show them is true. Which matches the previous behavior.

@yubiuser yubiuser left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there is no need to have settings-level-expert in settings-all.lp as the page is only accessible when expert mode is enabled.

Additionally, I think it can be removed in child elements when the parents have it already set.

Comment thread settings-system.lp
<button type="button" class="btn btn-danger confirm-flusharp btn-block button-pad destructive_action" disabled>Flush network table</button>
</div>
<div class="col-xs-12 col-md-6 col-lg-3 settings-level-expert">
<div class="col-xs-12 col-md-6 col-lg-3 settings-level-expert d-none">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<div class="col-xs-12 col-md-6 col-lg-3 settings-level-expert d-none">
<div class="col-xs-12 col-md-6 col-lg-3">

Comment thread settings-system.lp
<td id="sysinfo-dns-replies-unanswered">&nbsp;</td>
</tr>
<tr class="settings-level-expert">
<tr class="settings-level-expert d-none">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<tr class="settings-level-expert d-none">
<tr>

Comment thread settings-system.lp
</tbody>
</table>
<!-- <table class="table table-striped table-bordered nowrap settings-level-expert">
<!-- <table class="table table-striped table-bordered nowrap settings-level-expert d-none">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<!-- <table class="table table-striped table-bordered nowrap settings-level-expert d-none">
<!-- <table class="table table-striped table-bordered nowrap">

Comment thread settings-all.lp
</div>

<div class="col-sm-12 settings-level-expert save-button-container">
<div class="col-sm-12 settings-level-expert d-none save-button-container">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<div class="col-sm-12 settings-level-expert d-none save-button-container">
<div class="col-sm-12 save-button-container">

Comment thread settings-all.lp
mg.include('scripts/lua/settings_header.lp','r')
?>
<div class="row settings-level-expert" id="advanced-content">
<div class="row settings-level-expert d-none" id="advanced-content">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<div class="row settings-level-expert d-none" id="advanced-content">
<div class="row" id="advanced-content">

@XhmikosR

XhmikosR commented May 26, 2025 via email

Copy link
Copy Markdown
Contributor Author

@github-actions

Copy link
Copy Markdown
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Matches the previous behavior before 8556b65

Signed-off-by: XhmikosR <xhmikosr@gmail.com>
@github-actions

Copy link
Copy Markdown
Contributor

Conflicts have been resolved.

@PromoFaux PromoFaux merged commit abd4d9d into pi-hole:development May 30, 2025
8 checks passed
@PromoFaux PromoFaux mentioned this pull request May 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants