- 🇮🇳India sd9121
I have raised the PR against 11.x and have attached before/after screenshots to demonstrate the UI changes introduced by the patch.
- @sd9121 opened merge request.
- 🇺🇸United States dww
Now that 📌 Deprecate/remove the ability to update a module from a URL and authorize.php Active and child issues are done, all this code is deprecated and will be removed in D12.
- 🇺🇸United States dww
Now that 📌 Deprecate/remove the ability to update a module from a URL and authorize.php Active and child issues are done, this code is all deprecated and will be removed in D12.
- 🇬🇧United Kingdom catch
#2702061-106: Unify & simplify render & theme system: component-based rendering (enables pattern library, style guides, interface previews, client-side re-rendering) → and downwards is relevant, but the most likely outcome would be that the number of different elements is reduced, and eventually #theme gets dropped in favour of #type component, but don't really see any reason that this couldn't all be worked on in parallel without explicit dependencies.
- 🇺🇸United States mortona2k Seattle
I added steps to create a view that triggers the error and is fixed with this patch.
- 🇦🇺Australia mstrelan
This is probably a duplicate of ✨ Add default date formats without time Closed: duplicate but this has obviously had much more recent discussion. Perhaps someone could credit @dead_arm for the original issue I've just closed.
- 🇦🇺Australia larowlan 🇦🇺🏝.au GMT+10
Yes, agree #142 is nicer and it also gels with some thinking I had in this experiment
It also means we might not have to add new classes for everything, we could possibly use the existing render element plugins but instantiate them.
- 🇺🇸United States mortona2k Seattle
I ran into this error, but replacing my site config with the default media library view fixed it.
I had changed the view display to use responsive grid.
But that display doesn't support row classes, relating to https://www.drupal.org/project/drupal/issues/2474491 →
I made a custom display that extends responsive grid to add custom classes back in, and it's working again.
The Needs Review Queue Bot → tested this issue. It no longer applies to Drupal core. Therefore, this issue status is now "Needs work".
This does not mean that the patch necessarily needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.
Consult the Drupal Contributor Guide → to find step-by-step guides for working with issues.
- First commit to issue fork.
- 🇫🇷France dydave
Super nice @elimw! Great job! 🥳
Looks like everything requested above is now in the MR, with the added Unit Test 👌
Let's see if reviewers and maintainers could take another look at this issue.
Thanks again for the great help and work @elimw! - 🇬🇧United Kingdom joachim
Closing as a duplicate of ✨ Prevent inaccessible links from being displayed in LinkFormatter Needs work .
The Needs Review Queue Bot → tested this issue. It no longer applies to Drupal core. Therefore, this issue status is now "Needs work".
This does not mean that the patch necessarily needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.
Consult the Drupal Contributor Guide → to find step-by-step guides for working with issues.
Applied the MR suggestion and rebased. Since the change is minor and there were no other suggestions, going to push this back to RTBC.
- 🇺🇸United States nicxvan
Did you mean to change the status to rtbc, because you said rtbc but did not change the status.
- 🇷🇴Romania vasike Ramnicu Valcea
MR updated with latest 11.x + some feedback for MR review.
Let's try again a review. thanks
- 🇮🇳India sagarmohite0031
Hello,
Tested and verified on Drupal 11,
MR applied successfully,
Working as expected.
Please check attachmentsRTBC+
- 🇳🇿New Zealand quietone
After about 9 months there has been no response so state that this is still needed. Therefor, closing.
If there is work to do here, then either re-open the issue or open a new issue and reference this one. If the choice is to use this issue then add a comment change make sure to change the issue status to 'Active'.
- 🇩🇰Denmark ressa Copenhagen
You're welcome! And great catch, the order is much better now.
- 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
Thanks for the quick response 😊
- 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
Tested this locally and found the sorting in the listing a bit weird. I think it would be better to prefix the labels.
I won't do it myself so I can still RTBC.PS: don't try to test on the MR tugboat because it doesn't trigger a new install.
- 🇩🇰Denmark ressa Copenhagen
Thanks for clearing that up @catch, and that's totally all right @quietone. As a side effect I realized what a useful feature the
ddev snapshot
command is, to quickly roll back changes. I also learned a bit or two about making ahook_update
and runningphpcs
, so it turned out to be a gain after all. I am pasting the end result below, just in case someone else needs to do something similar in the future. Thanks for the Doc page link @penyaskito!Unused
hook_update
code:use Drupal\Core\Datetime\Entity\DateFormat; /** * Add date-only date formats. * * @see https://www.drupal.org/project/drupal/issues/3498980 */ function system_update_11202(): string { $message = NULL; $date_formats = [ 'long_date_only' => [ 'label' => t('Long date (date only)'), 'pattern' => t('l, j F Y', [], ['context' => 'PHP date format']), ], 'medium_date_only' => [ 'label' => t('medium date (date only)'), 'pattern' => t('D, j M Y', [], ['context' => 'PHP date format']), ], 'short_date_only' => [ 'label' => t('short date (date only)'), 'pattern' => t('j M Y', [], ['context' => 'PHP date format']), ], ]; foreach ($date_formats as $id => $date_format_info) { if (!DateFormat::load($id)) { $date_format = DateFormat::create([ 'id' => $id, 'locked' => FALSE, 'status' => TRUE, 'pattern' => $date_format_info['pattern'], 'label' => $date_format_info['label'], ]); $message .= "Date format " . $date_format_info['label'] . " was created.\n"; $date_format->save(); } } return $message; }
- 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
Oh, really? Then 🚀 ship it. @pameeela said this already, but I was pretty sure this was one of the core gates.
That means we need to actually remove that upgrade from this MR and we're done.
We don't need upgrade tests if there's no upgrade. Removing tag.
@ressa For the sake of learning, see https://www.drupal.org/docs/drupal-apis/update-api/writing-automated-upd... →Updated issue summary.
Only left: Revert - 🇳🇿New Zealand quietone
Just came back to this. My question,"Why is this change limited to new installs?" was truly a question. It was not an implication that any work was needed to change that decision. Apologies for the confusion.
- 🇳🇿New Zealand quietone
In light on the comments in #32, which I agree with, this should be closed.
- 🇬🇧United Kingdom catch
I don't think we need an update here, they can just be available on new sites. Even if existing sites don't have formats with the same names, they may have all kinds of custom formats already created which are similar, and then suddenly these new ones would appear alongside them. Similarly we often don't even fix arguable bugs in shipped views like admin/content in update paths, because there is a higher chance of breaking a site than fixing it.
- 🇩🇰Denmark ressa Copenhagen
Just updating the title, since the Announcement date update will also get done here.
- 🇩🇰Denmark ressa Copenhagen
Thank you very much @penyaskito for fast and thorough review, I greatly appreciate it.
I have made the changes you suggested, and your new method for setting the date formats were spot on, so that made it a lot easier. I also restored olivero_medium format.
As you suggested in the original Announcement issue, I have updated the date format to short_date_only in this MR as well.
I have updated Remaining tasks, and added the upgrade path test task as well. I wonder if there is a documentation page on how to write upgrade path tests, going from Drupal 10 to 11 (I guess)?
- 🇩🇪Germany J-Lee 🇩🇪🇪🇺
Yes, it looks like it. As with many other things. New, large features tend to be preferred. What a pity.
- 🇬🇧United Kingdom james.williams
I wonder which will happen first, getting back to RTBC here again, or core moving faster than we can keep up with here...
....and we have the answer :'-( In all honesty, I've lost motivation. I want to see this improvement make it into core, but it's just not going to happen, is it?
- 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
See MR comments.
Also tagging for required upgrade path tests. - 🇩🇰Denmark ressa Copenhagen
I somehow managed to make an update hook for existing installations, so they now also get these date only formats. But only if there aren't pre-existing date formats with the same machine names.
I also removed Olivero Medium data format. It is replaced with the new Short date format, in the Olivero theme. Luckily, if for some reason a date format cannot be found, the fallback date format is used.
PS. I had to close the original branch, and start fresh, since rebasing was not possible. Oh, and Nightwatch had to be re-run three times, before it finally went green :)
- @ressa opened merge request.
Automatically closed - issue fixed for 2 weeks with no activity.
- 🇬🇧United Kingdom catch
Good idea to remove the Olivero date format. My main concern with this issue is that it's a lot of default date formats, but if we're able to start getting rid of one-off ones, that's a good trade-off.
- 🇩🇰Denmark ressa Copenhagen
Thanks for clearing that up so quickly @penyaskito, if you have time, feel free to update the MR with your suggestions. Maybe the update hook is safe to add, as a first step?
- 🇪🇸Spain penyaskito Seville 💃, Spain 🇪🇸, UTC+2 🇪🇺
- I'd replace "Olivero Medium" with the new one, here or maybe even on a follow-up.
- Should existing installations also get these date only formats, via an update hook? Yes, if there aren't pre-existing date formats with the same machine names.
- 🇩🇰Denmark ressa Copenhagen
Thanks for the feedback @quietone, I have updated to use "(date only)" from "(without time)".
About "Olivero Medium" I am not sure, so I have updated the Issue Summary, with these Remaining tasks:
- Figure out what to do with "Olivero Medium", since it has the same format as "Short date (date only)".
- Should existing installations also get these date only formats, via an update hook?
-
jsacksick →
committed dee9aeb1 on 8.x-2.x authored by
claudiu.cristea →
Issue #3014768 by claudiu.cristea, idebr: Missing config schema for...
-
jsacksick →
committed dee9aeb1 on 8.x-2.x authored by
claudiu.cristea →
- First commit to issue fork.
- 🇳🇿New Zealand quietone
Just a few questions
Why is this change limited to new installs?
I did a fresh install with this MR and there are now two identical formats, 'Olivero Medium' and 'Short date (without time)'. I think that is confusing and should be addressed somehow.
And, can we use a more positive description, "Short date (date only)" instead of "Short date (without time)".
Setting to NW for responses to the above.
- 🇺🇸United States nicxvan
Ok, I think this is ready.
I tested manually both in 11.x and this branch locally.
I tested block and view contextual links and tested with both mouse and keyboard. As far as I can tell both act exactly the same.I searched for references to backbone, the only references remaining are for toolbar. There are no more references in contextual.
Javascript is not my forte as mentioned, but I am familiar with it, reviewing the code directly I see nothing that looks amiss.
As far as I can tell both larowlan and _nod have worked on this to a non trivial extent.
The only thing I didn't check that may be worth it is performance. I'm not super familiar with JS performance testing so I'll leave that up to a committer to determine if it's necessary.
_nod's comment in 56 make me think the change has been addressed as far as I can tell.