YJSGframework / yjsg

YJSG Template Framework Plugin
GNU General Public License v2.0
17 stars 14 forks source link

Shortcodes templates ready for extend and translations #25

Closed danyj closed 9 years ago

danyj commented 9 years ago

OK , we have converted shortcodes to php files. You can now extend them with php and add anything you require in them,

@ptopenweb this is ready for you if you like to contribute further for lang strings translations.

ptopenweb commented 9 years ago

danyj did you see my comment on this commit? https://github.com/YJSGframework/yjsg/commit/430b96b7731865d84a0348100684f191e3454b12#commitcomment-9567839

ptopenweb commented 9 years ago

PR https://github.com/YJSGframework/yjsg/pull/27 Please note that js vars still not in PR Read my previous comment

danyj commented 9 years ago

Yes yes , I saw the comment and will have those moved to inline. Doing it now and will push new php files.

ptopenweb commented 9 years ago

oh already done that

ptopenweb commented 9 years ago

check here https://github.com/ptopenweb/yjsg/commits/master (last two comiits) shall i do a PR?

danyj commented 9 years ago

oh , no no , should not have done it that way only the lang strings will be added to php at the bottom of the shortcodes files

ptopenweb commented 9 years ago

ok, so you do it.

danyj commented 9 years ago

on it now. lucky that the 27 did not had those just the string. no prob, I am on this. thnx

danyj commented 9 years ago

all done, will have guys test it.

ptopenweb commented 9 years ago

hum, i noticed now that there is still one point missing for finalizing shortcodes translations: The button names in shortcodes.js There are already lang vars for them they are 'YJSGSHORTCODES*_NAME'. Maybe it's needed js again in yjsg_head.php files for this

mikimaus144 commented 9 years ago

it works fine on 2.5, no bugs, everything is ok.

Wasah commented 9 years ago

Tested on joomla 3 , all fine.

danyj commented 9 years ago

@ptopenweb "hum, i noticed now that there is still one point missing for finalizing shortcodes translations" how are you going to translate , media shortcodes, icons shortcodes etc, they seem like globals to me

danyj commented 9 years ago

@ptopenweb you are talking about those http://screencast.com/t/4hg5xML7bIV right?

ptopenweb commented 9 years ago

yes, they are already translated in https://github.com/YJSGframework/yjsg-translations/blob/master/pt-PT/pt-PT.plg_system_yjsg.ini

also if you notice there is var to YJSG_SHORTCODES_TITLE="YJsg Shortcodes" that is in that js file too

danyj commented 9 years ago

I really would not touch those , those are global words, I do not see any benefit from trying to translate them. But if you guys think that is a benefit than it should be added here https://github.com/YJSGframework/yjsg/blob/master/yjsg.php#L1050

like var jstr_media_button ="...";

ptopenweb commented 9 years ago

danyj, in translation there is no such thing as a global word :) imagine, for instance, greek, russian, arabic, chinese, etc in our case we have portuguese content editors (no IT personal) that will use it. Knowing english is not a pre-requisite. That's why we need all strings translated, especially frontend and frontend edition. I can imagine a lot of cases like that.

If we do that change can i PR to main master? As you can understand, we don't want to change the core of yjsg and them lose the changes at each update.

danyj commented 9 years ago

ok go ahead, you wont loose changes, those strings https://github.com/YJSGframework/yjsg/blob/master/yjsg.php#L1050 will get outputted in html head and are required for shortcodes to work, so adding 5 more for buttons is not a big deal . Send pr il look over and merge.

danyj commented 9 years ago

In meantime I am on eximium repos and translations

ptopenweb commented 9 years ago

ok close this ticket, i now have other things to do, when i have time i will do that thanks!

And cool for eximium! I will check that too when i have time.

danyj commented 9 years ago

just follow the string

jstr_button_media jstr_button_icons ...

ptopenweb commented 9 years ago

ok

ptopenweb commented 9 years ago

Hi danyj i think about the shortcodes and putted up in a branch of ours a new working method for them, that i think can simplify the shortcodes. It uses json files

See were, read the comments, and tell me what you guys think https://github.com/ptopenweb/yjsg/commit/0f4830a57aa17b7cd4ed38bd54a4dda8b8f32ecc

Oh and it spares some bytes in js :)