Closed (fixed)
Project:
Drupal core
Version:
8.0.x-dev
Component:
theme system
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
18 Nov 2012 at 02:10 UTC
Updated:
29 Jul 2014 at 21:32 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
joelpittetnot sure about:
class="{{ row_classes[row_count]|join(' ')}}"should probably be converted to something likeclass="{{ row.attributes.class }}"{{ row.attributes }}?Comment #2
mbrett5062 commentedTagging.
Comment #3
joelpittetMoving to core queue
Comment #4
webthingee commentedTried to dive into this.
There's more going on here that I think I am read for re-twig/drupal.
going to switch over to some reviewing.
Comment #5
webthingee commentedComment #6
webthingee commentedGetting some better results from....
Comment #7
webthingee commentedjoelpittet,
I am getting this a little better, going to try to keep banging on it.
Comment #8
joelpittet@webthingee sorry I was giving this a crack and didn't see the message:( This is my crack.
I got most of the attributes on the objects except for
row_classes. And fixed the broken summary attribute. But there is still an issue with thecolspanon empty issues.Comment #9
dawehnerI guess it should be Default ...
I'm wondering whether this is the way to document an array of FOO, containing all label and attributes. This feels not right for me.
"classes" instead of "Classes" here.
Sure that $num and $column is right here?
Comment #10
star-szrRe-titling.
Comment #11
star-szrTagging.
Comment #12
star-szrTagging.
Comment #13
joelpittetComment #14
thedavidmeister commentedThere's already a review for this in #9.
Additional points:
There's mention of PHP data types in the Twig template docs which need to be removed.
There are variables being used in the Twig template that are not documented:
field.attributes, field.label
This comment is not right for a preprocess function at all. Should be of the form "Prepares variables for ... templates.". Need to reference the template it's for and add an @param for $variables.
These refactored comments are now over 80 characters long so need to be wrapped/re-written appropriately.
Comment #15
star-szrReference for the pending preprocess function standards: #1913208: [policy] Standardize template preprocess function documentation
Comment #16
joelpittetOk reverted the $vars=>$variables on this one cus it's big and makes it hard to see the changes. And added some doc cleanup.
Comment #18
joelpittetyeah should have tested that one... I made that fix in a separate issue because I accidentally made a regression with the way the columns are built. Also, timplunkett was preferring arrays over objects so I made that change.
Comment #20
joelpittetOk back to straight conversion, we can fix the row_classes bits here #1968398: Convert Views $row_classes to $row['attributes']
Comment #21
aczietlow commentedTested as part of the Florida Drupal Camp code sprint 2013
Comment #22
thedavidmeister commentedComment #23
dawehnerThanks aczietlow for manually testing the table.
Just some nitpicks.
... Should be "Default theme implementation"..., see http://drupal.org/node/1823416
I think documenting $vars['rows'] and $vars['result'] would be helpful as well. I think "A View object" should be better something like "A ViewExecutable object".
Comment #24
star-szrCNW for #23 and:
@param array $vars for now.
Comment #25
joelpittet@dawehner re #23 I added rows but $vars['results'] = $vars['rows'] and is documented inline, so I left that one out.
Did #24 as well.
Comment #26
thedavidmeister commentednitpick:
capitalise id to ID and we don't need the second comma in this sentence.
looks RTBC to me other than that.
Comment #27
star-szrTagging for profiling.
Comment #28
joelpittetRemoved an 80 liner and touched up docs to #26
Comment #29
thedavidmeister commentedComment #30
jerdavisProfiling this
Comment #31
jerdavisProfiling for this is complete.
Scenario setup
Results
Comment #32
star-szrWe just need to get an API key for @jerdavis so he can upload these results and the ones at #1843770: Convert views/templates/views-view-unformatted.tpl.php to twig for full review. Thanks @jerdavis!
Comment #33
alexpott+1. Ready for #1987510: [meta] Convert all core *.tpl.php templates to Twig as singular patch
Comment #34
jerdavisUploaded results.
Comment #35
alexpottCommitted 6ac1d47 and pushed to 8.x. Thanks!
Comment #36.0
(not verified) commentedUpdated issue summary.