bernhard Posted December 4, 2022 Author Share Posted December 4, 2022 I can't remember for sure but I don't think so. I think it has always been injected automatically (as it was meant to be zero-setup from the very beginning) and I wanted to avoid having instructions in my readme that are necessary to make everything work. Is your problem fixed now? 1 Link to comment Share on other sites More sharing options...
MarkE Posted December 4, 2022 Share Posted December 4, 2022 2 hours ago, bernhard said: Is your problem fixed now? Yes thanks. I think those elements must have dated from the early days of RockFrontend and I never updated that _main.php. So I've re-done it all now as per the latest readme and it all seems fine. 1 Link to comment Share on other sites More sharing options...
bernhard Posted December 10, 2022 Author Share Posted December 10, 2022 Thx to a PR by @wbmnfktrΒ everybody using Twig can now use {{ dump($var) }}Β ? https://github.com/baumrock/RockFrontend/pull/14 1 Link to comment Share on other sites More sharing options...
gornycreative Posted December 11, 2022 Share Posted December 11, 2022 I'm sure the answer is yes, but... This replaces RockLESS functionality, correct? RockLESS can be replaced/removed since the styles array and vars covers the same ground? Link to comment Share on other sites More sharing options...
bernhard Posted December 11, 2022 Author Share Posted December 11, 2022 6 hours ago, gornycreative said: I'm sure the answer is yes, but... This replaces RockLESS functionality, correct? RockLESS can be replaced/removed since the styles array and vars covers the same ground? Yes and no. I think the answer to what you mean is yes, but to be precise:Β The LESS module (https://github.com/ryancramerdesign/Less) got some updates some time ago that make RockLESS obsolete. I'll update RockLESS readme, thx! 1 Link to comment Share on other sites More sharing options...
zoeck Posted January 4, 2023 Share Posted January 4, 2023 Happy new year ?Β and another rockfrontend question ?Β I saw this information in the Latte documentation:Β https://latte.nette.org/en/develop#toc-debugging-and-tracy Is there an easy way to use this with the Tracy debugger and RockFrontend module? is it possible to add it here?Β https://github.com/baumrock/RockFrontend/blob/c7ac651f198f6470710b814ec50530b71dcfafb2/RockFrontend.module.php#L1443 When the templates get a bit bigger and more nested, that's definitely interesting ?Β Link to comment Share on other sites More sharing options...
bernhard Posted January 4, 2023 Author Share Posted January 4, 2023 Hi @zoeckΒ thx and same to you! It would have been nice to create a new topic for that question. It's easier for everybody to keep track of it and this thread is already 7 pages long... ?Β To your question: I don't know. I've also seen that screenshot and thought it would be great to have, but I don't know if or how that would work. If you find it out I'm happy to add it to the module ?Β 1 Link to comment Share on other sites More sharing options...
zoeck Posted January 4, 2023 Share Posted January 4, 2023 54 minutes ago, bernhard said: If you find it out I'm happy to add it to the module ? Okay then I'll have a look at it, I hope it's not that difficult to implement ?Β 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 4, 2023 Author Share Posted January 4, 2023 GreatΒ ?Β If you need any assistance let me know. Though maybe @adrian might also have some quicktips for us? Link to comment Share on other sites More sharing options...
sz-ligatur Posted January 12, 2023 Share Posted January 12, 2023 HiΒ @bernhard, I'm not 100% sure if it's correct to assign it to RockFrontend β today I found a strange one: I'm using a fieldΒ FieldtypeOptions v0.0.2 with value and title as entries. It's config is radios = only single value. I'm used to call it as noted in the api example: // Ausgabe einer einzelnen Auswahl: echo '<h2>' . $page->test_options->title . '</h2>'; // Ausgabe mehrerer Auswahlen: foreach($page->test_options as $item) { echo '<li>' . $item->title . '</li>'; } Actually it's output is different in context with RockFrontend and its renderLayout() function. One has to use the ->first() call to get the title, otherwise the page-title gets rendered instead. This is the case in any template file, if it's a section.latte or main.php β¦ same thing - please see attached screenshot. Any ideas what's going on? It's not a big thing, but it took me some time to figure it out and maybe worth fixing it with regard toΒ compatibility. The field settings: 'test_options' => [ 'label' => 'test-options', 'flags' => 0, 'type' => 'FieldtypeOptions', 'inputfieldClass' => 'InputfieldRadios', 'optionsLang' => [ 'default' => [ 1 => 'a|ONE', 2 => 'b|TWO', 3 => 'c|THREE', ], ], ] 2023-01-12_18-28-41.pdf 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 12, 2023 Author Share Posted January 12, 2023 Hi, that's an interesting one. Could you also check the value in different locations please. Eg in site/ready.php or in _main.php before anything else? Maybe that tells us something. Because I have no idea until now..Β Link to comment Share on other sites More sharing options...
sz-ligatur Posted January 13, 2023 Share Posted January 13, 2023 Hi @bernhard, thank you for replying⦠echo $page->test_options->title⦠ in ready.php works as expected  in _main.php it gets replaced by page title field, same in main render file latteRenderer.php or any section.latte template file a bd($page->test_options) looks good a bd($page->test_options->title) shows the page title instead a tracy console call echoes correct $page->test_options->title 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 14, 2023 Author Share Posted January 14, 2023 @sz-ligaturΒ I've tried, but I can't reproduce on an installation having RockFrontend + RockMigrations running. Link to comment Share on other sites More sharing options...
sz-ligatur Posted January 14, 2023 Share Posted January 14, 2023 Thank you @bernhard! I can reproduce this behaviour in three of my instances (all are using your awesome modules) β but they all share some boilerplate code of mineβ¦ so I won't excludeΒ some mistake on my side. One fresh install with no custom additions nor using rf or rm has no issues so far. To my excuse, I do the first steps with your modules and custom PageClasses and latte β¦ for me a lot of new stuff to learn β so no stone is left unturnedβ¦Β and maybe i messed up something. I'll keep a look at it and report back here, if I find anything causing thisβ¦Β hopefully not too embarrassingΒ at the end Β ?. Β 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 14, 2023 Author Share Posted January 14, 2023 17 minutes ago, sz-ligatur said: I can reproduce this behaviour in three of my instances (all are using your awesome modules) First of all thx for that and I'm happy to hear thatΒ ?Β 20 minutes ago, sz-ligatur said: One fresh install with no custom additions nor using rf or rm has no issues so far. It would be interesting to add things step by step and see when things start going wrong! Maybe you can share a test project so I can have a look. But I'd appreciate if you can find it yourself of course ?? Link to comment Share on other sites More sharing options...
Stefanowitsch Posted January 24, 2023 Share Posted January 24, 2023 I saw this new "Topbar" Checkbox in the settings. What exactly does this do? When checked I expected some kind of new element floating in the frontend but I didn't see anything ? Link to comment Share on other sites More sharing options...
bernhard Posted January 24, 2023 Author Share Posted January 24, 2023 Hi @StefanowitschΒ it should show this: I'm not sure about the logo there and am open to feedback. 1 Link to comment Share on other sites More sharing options...
Stefanowitsch Posted January 24, 2023 Share Posted January 24, 2023 Aaaah! I have a fixed navbar in my project which acts as an overlay. So your topbar was hidden underneath it. My only advise would be to increase the z-index of the topbar to a really high value to make sure it will be visible in most of the cases. I love the mobile toggle option. It would be nice to be able to chose between tablet and phone size. Β Link to comment Share on other sites More sharing options...
zoeck Posted January 24, 2023 Share Posted January 24, 2023 13 minutes ago, Stefanowitsch said: My only advise would be to increase the z-index of the topbar to a really high value to make sure it will be visible in most of the cases. Or configurable as in the Tracy Bar ?Β 2 Link to comment Share on other sites More sharing options...
Stefanowitsch Posted January 24, 2023 Share Posted January 24, 2023 3 minutes ago, zoeck said: Or configurable as in the Tracy Bar ?Β That would be nice too. I am using UIKit and the sticky navbar has a default z-index of 980.Β 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 24, 2023 Author Share Posted January 24, 2023 Thanks guys, I've added a config setting for the z-index of the topbar and changed the default from 99 to 999 ?Β 2 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 25, 2023 Author Share Posted January 25, 2023 Thx to feedback and a good find from @StefanowitschΒ v2.18.0 also copies .css.map files over to the assets folder, which is helpful if you are using one of the postCSS features like rfGrow() or rfShrink() You are not using them yet? You are missing something! They are so greatΒ ?Β 1 1 Link to comment Share on other sites More sharing options...
bernhard Posted January 26, 2023 Author Share Posted January 26, 2023 v2.19.0 comes with a new handy javascript snippet that can help, for example, to create to-top-links that slide in after a certain scroll position: Quote Add/remove class on scroll position Usage: <a href='#' rf-scrollclass='show@300'>Add class "show" at 300px scrollposition</a> If you have ideas for improvement let me know! 1 Link to comment Share on other sites More sharing options...
Sonia MargollΓ© Posted January 30, 2023 Share Posted January 30, 2023 I don't understand, it says on the doc that all variables defined in _init.php should be available in the latte files. But I always get "undefined variable" ...Β it's the same result if the latte file is called with render or renderLayout I don't know what I missed ?Β Link to comment Share on other sites More sharing options...
bernhard Posted January 30, 2023 Author Share Posted January 30, 2023 It works for me as expected. Do you haveΒ $config->prependTemplateFile = '_init.php'; in your config.php? Do you have a recent version? Β Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now