Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QUESTION] is there a way to override the generatecss.php file? #19901

Closed
thednp opened this issue Mar 14, 2018 · 4 comments
Closed

[QUESTION] is there a way to override the generatecss.php file? #19901

thednp opened this issue Mar 14, 2018 · 4 comments

Comments

@thednp
Copy link
Contributor

thednp commented Mar 14, 2018

The current code doesn't allow the user to push colors or stuff like typographic measurements into the LESS compiler process, you pretty much have to use Bootstrap 2, with its default colors, so I want the user to be able to override this file within(/or only within) my template, with 2 major changes:

  • ability to push LESS variables values via PHP
  • ability to compile the LESS on template settings save

Thanks

@mbabker
Copy link
Contributor

mbabker commented Mar 14, 2018

generatecss.php doesn't ship as part of a release, it's only a convenience tool used when contributing to core and making LESS changes to the core templates to quickly regenerate the CSS for the templates. So it is not a reliable resource to use in distributed extensions/templates (and obviously not used in the template manager when LESS is compiled from there).

No, there are not hook points in the LESS compiling process to push values into the compiled CSS via PHP in any other way.

@thednp
Copy link
Contributor Author

thednp commented Mar 14, 2018

Thank you, but at least a hook point for template settings save?

@mbabker
Copy link
Contributor

mbabker commented Mar 14, 2018

Saving template styles emits the usual onContentBeforeSave and onContentAfterSave events in the com_templates.style context.

@thednp
Copy link
Contributor Author

thednp commented Mar 14, 2018

Thank you.

@thednp thednp closed this as completed Mar 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants