-
Notifications
You must be signed in to change notification settings - Fork 60
EPS-1483: New Post duplicator feature #1401
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
base: release-candidate
Are you sure you want to change the base?
Changes from all commits
c08e124
b936794
066acb2
08b0806
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| /** | ||
| * Admin styles for Post Duplicator. | ||
| * | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What: Consider adding more context to the comment above the Why: While the comment generally states it's for the Post Duplicator, including what the notice signifies (e.g., success or error messages) can improve maintainability and understanding for future developers. How: Change the comment to something like: |
||
| * @package header-footer-elementor | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What: The color definitions used here may benefit from being stored as CSS variables for easier theming or future changes. Why: Utilizing CSS variables enhances maintainability and makes it easier to apply changes if the color scheme requires updates later on. How: Define CSS variables in a root selector, like |
||
| */ | ||
|
|
||
| .hfe-post-duplicator-notice { | ||
| padding: 10px 15px; | ||
| background-color: #fff; | ||
| border-left: 4px solid #00a0d2; | ||
| margin: 5px 0 15px; | ||
| box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); | ||
| } | ||
|
|
||
| .hfe-post-duplicator-notice p { | ||
| margin: 0.5em 0; | ||
| padding: 2px; | ||
| } | ||
|
|
||
| /* Style for the UA Duplicate link in row actions */ | ||
| .row-actions .hfe_duplicate a { | ||
| color: #0073aa; | ||
| } | ||
|
|
||
| .row-actions .hfe_duplicate a:hover { | ||
| color: #00a0d2; | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -635,6 +635,7 @@ public function includes() { | |
|
|
||
| require_once HFE_DIR . 'inc/hfe-functions.php'; | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What: The addition of the Post Duplicator class appears to be correctly included, but I recommend considering the implications of loading this class for all users who access the admin interface. If this class introduces heavy operations or data processing, it could impact performance. Why: Loading unnecessary classes can lead to increased memory usage and slower performance, particularly for users who do not utilize the duplication feature. This is crucial for maintaining a responsive admin experience, especially if many users will be accessing the admin interface. How: To improve performance, consider utilizing a conditional loading mechanism. For example, load the |
||
| require_once HFE_DIR . 'inc/class-hfe-rollback.php'; | ||
| require_once HFE_DIR . 'inc/class-hfe-post-duplicator.php'; | ||
|
|
||
| // Load Elementor Canvas Compatibility. | ||
| require_once HFE_DIR . 'inc/class-hfe-elementor-canvas-compat.php'; | ||
|
|
||
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.
What: Consider specifying a version for the CSS file if applicable.
Why: Versioning helps in managing assets and ensures that users receive the correct style updates. It aids in cache management.
How: Add a comment at the top of the CSS file indicating the version, e.g.,
/* Version 1.0.0 */. This practice can be integrated with your build process or asset management approach.