-
-
Notifications
You must be signed in to change notification settings - Fork 842
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AdminUX Patch and Admin Page #2593
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is a bit hard, there's many changes that address different things.
I do have a few things to point out and/or ask about.
I think we want methods for the options in info()
instead of returning an object.
Why were fields
removed in BasicsPage
and MailPage
? I don't see a reason given in the PR description.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall makes sense, left some code nitpicks. Will test locally later.
Going forward, it would be preferable to split big changes like this up into commits (or even better, separate PRs when possible) to make review easier.
Like
There's no need for them as there is a settings helper already apart of AdminPage now. |
Yes, that's what other components do. This was just a thought by the way, but I feel like it'd be more intuitive than returning an object. If we wanted a simple |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this, it makes the interface so much more customizable!
@datitisev I'm mostly in favor of keeping it inside one function and return an object. I think having functions for all four info items is a bit redundant and although there will have to be a certain level of redundancy this takes up the smallest footprint. It's just as easy to extend as well. Let's keep discussing! For now, I'm going to just change it to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could any of the CSS common across pages be factored out into an AdminPage.less
file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@askvortsov1 there are some pages like Basics, Appearence and Email, that have similar bottom padding and container CSS code, but it's also different in Dashboard, ExtensionPage and PermissionsPage, so I don't think we could
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me!
* AdminPage * More fixes * Settings Modal Drop * Translation and docblock * settingS * Convert Fieldset to JSX * info -> headerInfo, className * Overflow fixes * MailPage * Admin Less * Basics Page * Changes * Cleanup * Permission Page * Add padding
* AdminPage * More fixes * Settings Modal Drop * Translation and docblock * settingS * Convert Fieldset to JSX * info -> headerInfo, className * Overflow fixes * MailPage * Admin Less * Basics Page * Changes * Cleanup * Permission Page * Add padding
Fixes #2498
Fixes #2503
Fixes #2504
Fixes #2520
Changes proposed in this pull request:
buildSettingsComponent
helper and a few other helpful save functions.buildSettingsComponent
now assigns attrs to the components it is building (min/max/classname etc). Also allows built in helptext.AdminLinkButton
(breaking/deprecated),AddExtensionModal
, andapp.extensionSettings
. Drop support forSettingsModals
for extensions.ExtensionWidget
functions of JSX.Reviewers should focus on:
AdminPage, specifically the info section. Is this how we want to do it or do you have any better ideas?
Confirmed
Frontend changes: tested on a local Flarum installation.
Required changes:
Related documentation PR: Will put docs PR when I make it
Related core extension PRs: Tags: Max-height for tags settings tags#116 and English: AdminUx lang-english#183