Skip to content
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

Fix/widget localized labels #270

Merged
merged 2 commits into from
Nov 3, 2023
Merged

Conversation

bezhanSalleh
Copy link
Owner

fixes #269

Copy link

what-the-diff bot commented Nov 3, 2023

PR Summary

  • Updated FilamentShield.php file
    This pull request introduces updates to the FilamentShield.php file.

  • Addition of New Imports
    Two new imports, namely TableWidget and Widget, have been included to enhance functionality.

  • Improvement of getLocalizedWidgetLabel method
    The getLocalizedWidgetLabel method now utilizes the newly imported TableWidget and Widget features, and includes additional conditions to accurately return specific widget labels based on varying instances of TableWidget or Widget.

  • Elimination of Redundant Variables
    Some variable entries that were not essential or in use have been effectively removed to streamline the code.

  • Enhancements in Function and Statement Usage
    The invade function is now employed to access methods on the widget instance, and the match statement is leveraged to accurately determine the widget label, depending on the instance type.

  • Improved Default Behavior
    In scenarios where none of the preset conditions are met, the updated default operation will return the widget label extracted directly from the class name of the widget. This helps to preserve design integrity and consistent naming conventions.

@bezhanSalleh bezhanSalleh merged commit fae4c9b into 3.x Nov 3, 2023
5 checks passed
@bezhanSalleh bezhanSalleh deleted the fix/widget-localized-labels branch November 3, 2023 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

widget localized label issue
1 participant