Opened 8 years ago

Closed 8 years ago

Last modified 5 years ago

#10503 closed (fixed)

trans noop documentation could be made more clear

Reported by: liangent Owned by: Matt Boersma
Component: Documentation Version: 1.0
Severity: Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

i used {% trans "yes" noop %} in templates and yes appears unless i comment it out.

Attachments (1)

10503.diff (720 bytes) - added by Matt Boersma 8 years ago.
Reworded description of "noop" using admin docs' description

Download all attachments as: .zip

Change History (8)

comment:1 Changed 8 years ago by liangent

Needs documentation: unset
Needs tests: unset
Patch needs improvement: unset

i'm not sure if it's because of my misunderstanding of document.

in document:

If the noop option is present, variable lookup still takes place but the translation is skipped. This is useful when "stubbing out" content that will require translation in the future:

i think it means that the tag will output nothing.

comment:2 Changed 8 years ago by Alex Gaynor

Component: Template systemDocumentation
Summary: trans noop doesn'tworktrans noop documentation could be made more clear
Triage Stage: UnreviewedAccepted

This seems to do exactly what it said it would do, it does the variable lookup but doesn't translate it. Perhaps the docs could be made a tiny bit more clear. Changed the title to reflect this.

comment:3 Changed 8 years ago by Jacob

milestone: 1.1

Changed 8 years ago by Matt Boersma

Attachment: 10503.diff added

Reworded description of "noop" using admin docs' description

comment:4 Changed 8 years ago by Matt Boersma

Has patch: set
Owner: changed from nobody to Matt Boersma
Status: newassigned
Triage Stage: AcceptedReady for checkin

I reworded this sentence to use the description of "noop" that appears in the admin documentation. It's a bit clearer, and makes it plain that "yes" would be returned in the case liangent mentioned.

comment:5 Changed 8 years ago by Russell Keith-Magee

Resolution: fixed
Status: assignedclosed

(In [10151]) Fixed #10503 -- Clarified docs on the operation of the noop option to {% trans %}. Thanks to liangent for the report.

comment:6 Changed 8 years ago by Russell Keith-Magee

(In [10159]) [1.0.X] Fixed #10503 -- Clarified docs on the operation of the noop option to {% trans %}. Thanks to liangent for the report.

Merge of r10151 from trunk.

comment:7 Changed 5 years ago by Jacob

milestone: 1.1

Milestone 1.1 deleted

Note: See TracTickets for help on using tickets.
Back to Top