Atto: Styles

atto_styles
Maintained by Picture of Ulm University Ulm University, Picture of Alexander Bias Alexander Bias
Moodle Atto plugin which lets the administrator provide custom CSS classes which can afterwards be applied by users to block and inline text in Atto
838 sites
471 downloads
37 fans

The purpose of this Atto plugin is to let users apply custom CSS classes to block and inline text.

Please see README file for details about the usage and features of this plugin.

No support in the comments section on this page

Please note that we don't provide any support for this plugin in the comments section on this page anymore.

We appreciate your commendation and reviews for this plugin in the comments. For bug reports and support requests, please read the extensive information in the plugin's README file first and create, if needed, a ticket in the bug tracker which is linked below.

Thanks for your cooperation.

Screenshots

Screenshot #0

Contributors

Picture of Ulm University
Ulm University (Lead maintainer)
Picture of Alexander Bias
Alexander Bias: Developer
Picture of Andrew Davidson
Andrew Davidson: Initial Developer
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Picture of Björn Fisseler
    Mon, 27 Jul 2015, 9:22 PM
    Hi,

    I like the idea and also agree with David on the fact that this is the way content should be formated. But...

    Using styles for block element replaces the other block element with a div. This is not how I think it should work, especially when it comes to producing accessible content (see WCAG2.0, Section 508, you name it). Is it possible to simply apply the class to the current block element instead of replacing it?

    Let's say I want to use a certain style to highlight a paragraph. In HTML, paragraphs are structured using p elements. When you now replace the p element with a div, the semantic has changed. See: http://www.w3.org/TR/2014/NOTE-WCAG20-TECHS-20140916/G115

    Any ideas what the solution could look like?

    Regards

    Bjoern
  • Picture of Alexander Bias
    Tue, 28 Jul 2015, 2:44 PM
    Hi Björn,

    thanks for your feedback. Of course, you're right, the current strategy of replacing semantic elements with divs is not perfect, but I have to admit that I wasn't aware of this behaviour up to now.

    I will talk to our developers if we can improve that.

    Thanks,
    Alex
  • Picture of Pau Ferrer Ocaña
    Tue, 22 Sep 2015, 6:42 PM
    This plugin is great! This can solve some html design problems :D It should be great to have this into core! :D
  • Picture of Alexander Bias
    Tue, 22 Sep 2015, 7:25 PM
    Hi Pau,

    thanks for your positive feedback!

    Well, not everything has to be present in Core - that's what plugins are there for. We plan to maintain this plugin in the long run, so feel free to just rely on us smile

    Alex
  • Just wondering . . .
    Tue, 17 Nov 2015, 8:29 AM
    Alex, I just posted here: https://moodle.org/mod/forum/discuss.php?d=323307 and you were recommended.
    Does your plugin work for 3.0??

    -Derek
  • Picture of Alexander Bias
    Tue, 17 Nov 2015, 9:05 PM
    Hi Derek,

    due to our local release schedule (see the plugin's readme file for more about that), there haven't been any tests for 3.0 yet. Please feel free to give the plugin a try and report back any problems with 3.0 - we will then try to fix them ahead of schedule.

    Thanks,
    Alex
  • Just wondering . . .
    Tue, 15 Dec 2015, 8:21 PM
    Alex, thanks.
    We have set up a dev server, and installed your plugin. Since I have not used it I am unsure 100% of how it is meant to go.

    But: I copied a few of the styles listed in the settings page, added the button to the tool bar.

    So far it seems to work well, and it is nice. Now I just wish I had good design skills.

    Regards, Derek
  • DigiDago
    Mon, 25 Jan 2016, 10:17 PM
    Thank your for your plugin. A very good point to help trainers to integrate content in Moodle.

    Regards.
    Clément
  • DigiDago
    Wed, 24 Feb 2016, 4:42 PM
    Hi,

    I think we have a bug with Moodle 3.0.2 and "Build: 2016010100". I describe the problem here : https://github.com/moodleuulm/moodle-atto_styles/issues/4
    In summary and on Moodle 3.0.2, I can not use "inline" and class with words separated by a blank / a space.

    No one else is experiencing this bug?

    ++
  • DigiDago
    Sat, 5 Mar 2016, 6:09 AM
    Thank to fix this bug. It works fine with your last update. If I can make a suggestion, I think we can improve usability of the list of styles.
    The possibility to organize Atto menu with 2 levels would be a pleasure. Here is an exemple : Level 1 (for example "title"), level 2 (for example "title H1", "title H2", "title H2").

    - Title Style
    -- Title H1
    -- Title H2
    -- Title H3

    I never see that with Atto so I don't know if it's possible...

    Thanks again for this plugin who help us to improve design of our courses.

    Regards.
  • Picture of Alexander Bias
    Sat, 5 Mar 2016, 6:24 AM
    Clement, can you please recreate this feature request on https://github.com/moodleuulm/moodle-atto_styles/issues so we can discuss there?

    And please try to answer my questions when creating the ticket:
    * What is your goal with the 2 levels, do you really create that much styles that you get lost in the list of styles? You are free to name the styles however you want, so you already can group the list by using prefix strings as style titles which will then be alphabetically sorted. For example:
    Box blue
    Box green
    Paragraph blinking
    Paragraph small
    Title big
    Title medium
    Title small

    * Do you really intend to add H1, H2, H3 to the list of styles? The purpose if the plugin is _not_ to replace the default templates containing titles and paragraphs as it does not create semantic HTML, but create spans and divs.

    Thanks,
    Alex
  • Picture of Nick Varney
    Wed, 13 Apr 2016, 8:45 PM
    Great plugin!
    Just trying things out with bootstrap classes in our theme (a clone of More).
    Are we able to *combine* bootstrap classes with this? What I want to be able to do is to provide an alert along with a cross to close the alert i.e. using type="button", class="close" data-dismiss="alert" as seen here http://getbootstrap.com/2.3.2/components.html#alerts
  • Picture of Alexander Bias
    Wed, 13 Apr 2016, 10:34 PM
    Hi Nick,

    well, the atto_styles plugin is able to add 2 or more classes if you ask it to do so. Just add the classes, separates by spaces, to the "classes" attribute of the configuration on /admin/settings.php?section=atto_styles_settings.

    The question if combining two bootstrap classes will produce a decent result is another thing. Atto_styles will just assist you in adding these classes to your text, but you have to test yourself if the two classes in combination will produce the result you want. If you can't produce the result you want just with bootstrap classes, you will have to create a custom style with CSS and add the CSS to your theme. Then again, atto_style will assist you to apply this custom CSS style / class to your text.

    I hope this helps...

    Thanks,
    Alex
  • Picture of Benjamin Young
    Fri, 9 Dec 2016, 2:01 AM
    A great feature for this plugin would be to expand the "Type" feature to include other HTML tag types such as h1, h2, h3, h4, h5, h6, and paragraph.
  • Picture of Alexander Bias
    Fri, 9 Dec 2016, 2:33 PM
    Hi Benjamin,

    well, these tag types are already covered by the core plugin atto_title. The goal of atto_styles is to be able to define own CSS classes and assign them to text blocks or inline text.

    From a end users' perspective, you may be right. End users just want to style their text and don't want to think about implementation or HTML code details. However, including these tags would basically mean to duplicate code. I will think about it, but I can't promise anything yet.

    Thanks,
    Alex
1 2
Please login to post comments