View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
15267 | Bug reports | Other | public | 2019-09-11 12:17 | 2020-03-09 15:36 |
Reporter | ollehar | Assigned To | LimeBot | ||
Priority | none | Severity | partial_block | ||
Status | closed | Resolution | fixed | ||
Product Version | 4.0.0-RC3 | ||||
Target Version | 4.0.0-RC4 | ||||
Summary | 15267: Translation strings in vue templates must be picked up by glotpress | ||||
Description | Title. Example: assets/packages/textelements/src/TextElementsApp.vue 215 <label for="">{{'Decimal mark' | translate }}</label> Adapt the glotpress regexp that scans PHP-files? | ||||
Tags | No tags attached. | ||||
Bug heat | 6 | ||||
Complete LimeSurvey version number (& build) | latest | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | - | ||||
Database type & version | - | ||||
Server OS (if known) | - | ||||
Webserver software & version (if known) | - | ||||
PHP Version | - | ||||
Can someone explain to me why it's not possible to simply adjust the regexp to feed these translations to globpress? Why do we need to put twig file gT into php files? |
|
|
|
because there is nothing like "a regexp" to adjust. Btw: many people, like a lot, tried to hack the glot press parser to make it compatible with twig. All of them finally decided to use the twig cache method. For vuejs, knowing it can use a "twig compatible syntax", I'd suggest to replace the translate filter by a gT function, then to move all the html in different files (not mixed with vuejs logic, just pure HTML and {{ }} ), and finally to use twig to create php files out of it. Then, just register to the Unbelievable Hackish Nobels. |
|
OK, but somewhere there is some code that says "read gT() inside PHP file", no? So it should be able to expand to "read gT() inside twig file"? |
|
since you repeat your question in a different way, I will just repeat my answer in a different way. I didn't waste too much time reading GlotPress code. I tried a bit, then I googled, then I see that anyone who tried just felt in the "twig cache solution", then I thought it could be useful for LimeSurvey to deal with cash flush/asset regeneration, then I did the Twig Command Line tool. |
|
BTW: So, googling > debatting :) |
|
You should learn to read code, Louis, not only write code. <3 |
|
so @ollehar wich solution did you suggest ? |
|
First step: Find the code which scans PHP files for gT/eT/... |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2019-09-11 12:17 | ollehar | New Issue | |
2019-09-11 12:17 | ollehar | Summary | Translation string in vue templates must be picked up by glotpress => Translation strings in vue templates must be picked up by glotpress |
2019-09-11 12:17 | ollehar | Description Updated | |
2019-09-11 17:39 | cdorin | Relationship added | related to 15146 |
2019-10-02 11:04 | LimeBot | Assigned To | => LimeBot |
2019-10-02 11:04 | LimeBot | Status | new => confirmed |
2019-10-02 11:59 | ollehar | Note Added: 53820 | |
2019-10-02 12:12 | ollehar | Note Added: 53821 | |
2019-10-02 12:36 |
|
Note Added: 53822 | |
2019-10-02 12:41 | ollehar | Note Added: 53823 | |
2019-10-02 13:38 |
|
Note Added: 53824 | |
2019-10-02 17:18 |
|
Note Added: 53858 | |
2019-10-02 18:33 | ollehar | Note Added: 53864 | |
2019-10-04 13:05 | LimeBot | Note Added: 53879 | |
2019-10-04 13:15 | ollehar | Note Added: 53880 | |
2020-02-17 10:20 | LimeBot | Status | confirmed => resolved |
2020-02-17 10:20 | LimeBot | Resolution | open => fixed |
2020-03-09 15:36 | c_schmitz | Status | resolved => closed |