0

Whats the best way to add a Text Resize feature in the theme instead of using contrib modules.

I have tried Text Resize but it dosn't work for my custom theme. I told it to resize in entire "body" of my page but it ends up resizing only one paragraph.

are there other themes who have done this?

3 Answers 3

1

I would recommend against including this functionality on your site. Re-sizing text is best handled by browsers and assistive technology. Check out this discussion: https://groups.drupal.org/node/85254

The key thing is to use relative CSS units (em and %) when defining font-sizes and typography-related dimensions in your theme.

0

Experiment more with the selector used in the module and try also to adjust the CSS of your theme to allow the change to happen. Use element inspector tools to see what's actually going on on the page.

If you want to write that yourself - have a loot at the code in the module. The core mechanism is pretty straightforward and relies in JS + setting up the cookies to remember the user setting.

0

I would also suggest that instead of relying on a custom functionality, its advisable to use the browser based utilities. In the unlikely case that it i essential, plz follow the JQ cookie instructions given as part of the module in the admin page or the instructions.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.