"Collapsed Topics course format plugin" questions,...

"Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -
Number of replies: 41
  1. Is it possible to change the font size and the height of the toggle option bar?
  2. Why is the word "Toggle" in there?
  3. Can I use this in the Weekly format instead of the Topics format?

I thought I saw an option to show the date but not I do not. Was I dreaming?





Average of ratings: -
In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

  1. In CSS yes.
  2. Because it is a 'toggle' and in some situations this needs to be stated.  There is a course setting to remove this.
  3. CT has both topic and week based structures.

"not do I not" is a double negative that makes no sense.

In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

I guess it is my sloppy handwriting.  I meant to say "now I do not"  as it would be more appropriater.


In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

1) I use quite a bit of css already.  Can you enlighten me on what the code would be

2)  I did see the option to remove TOGGLE but wondered why it needed to be there to begin with. Is it a setting to change it to other words?  Even then, why?

3) I see "Collapsed Topics" as a setting.  Should I also be seeing "Collapsed Weeks"?


In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Steve, I use Collapsed Topics.  Your post made me wonder what you are seeing, and what you want to change or remove.  Could you supply a screen shot?

In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

It is difficult to do screen shots as there will probably be more than can make any sense. I experimented with enough of the CT settings that I probably smootched everything up without any help.

 I just used the Moodle from a previous course that has had no changes made to it.  I simply enabled Collapsed Topic and immediately the default section name changed from the week dates to "Section 1 - Toggle" instead.  How do I get collapsible weeks that still have the dates of each weed announced?


In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Aach, I just found it.  Course Format/Structure
It would be nice if the "help" was not so ambiguous...

Now, what is the CSS code to change the font size in the bar to collapse the topic/week
I would also like to see it as left justified.


In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Steve, below is a screen show of how collapsed topics looks in one of my courses.  I am not displaying anything in the topic (except its text.)

I am also attaching all of my CSS that I apply to my Moodle's MORE theme.  You should see some lines about "collapsed topics" in it, and I thought you might want to try some of my other changes.

Hope this helps.

Attachment Collapsed.png
In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

You probably answered my question before my discovery was posted. As noted, I finally found the answer.

As for font size, I use my own through CSS and the difference between what I use to the default in CT is considerable.  I will be making the adjustment in my settings first and see what happens.

Your CSS is very interesting and nicely commented. When I opened the file, my system used Notepad and the entire file was shown as one paragraph! Changing it over to Notepad++ fixed that one.  I am going to load that into my home Moodle before suggesting any of it to the University.  Some nice stuff in there.

Thanks for your response.


In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi Steve,

Ambiguity accepted.

There is a course format setting in the course settings 'Toggle text alignment' which already allows via the UI where the text will be aligned, left, centre or right.

When the 'Structure' is 'Week' etc. then the dates will be shown.

To change the word 'Toggle', edit the language pack - Language_customisation - and filter on 'format_topcoll.php', then find the string 'topcolltoggle'.

G

In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

RE: It would be nice if the "help" was not so ambiguous...

Don't bite the hand that feeds you.  I was going to reply with information but won't bother now.

In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Gareth, of course you know that I love all of the work that you have done for us with Collapsed Topics.  Thanks again.

In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

RE: RE: It would be nice if the "help" was not so ambiguous...

RE: Don't bite the hand that feeds you.  I was going to reply with information but won't bother now.


I am guessing that you read that as a criticism of your response.  I meant it to be the "Help" options in Moodle in general.  I meant no offense.

In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

I wonder if you solved your problem?

In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Mostly but one last question (?)

Is it possible to make a given week/topic uncollapsible?



In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

No.

But there are 'current topic' / 'current week' etc. that open automatically on page load.

In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Are these the two selectable options instead of "Week" and Topic"?  They look like the "Roll-A-Dex" idea that I proposed a year ago.  Now I see that this was already in operation/design before that.

The "Current Week" option will probably not be visible until the course is underway or I fiddle around with course starting dates.

Maybe someday there will be an option in each week/topic to allow/prevent collapse.
The CT really makes a big difference in the appearance of my course.

Thanks for all that work




Average of ratings: Useful (1)
In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi Steve,

There are five 'structures' - the current week first reacts to the date and the current topic first puts the current topic at the top.

Cheers,

Gareth

In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Mary O'Donnell -

Hi Rick;


I have the same issue, I want to remove the word toggle from the section name while using collapsed topics, here is an image.


Attachment toggle.PNG
In reply to Mary O'Donnell

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Go to the course, then Edit course, Expand All.  Scroll down to the Course Format, Elements, and pick a choice that does not have the word "Toggle" in it.  Looks like there are four choices.

Attachment Toggle.jpg
In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Apparently an Admin can change the word "Toggle" so something else if you do want a different word in that location.

Here is a citation from a previous post.

To change the word 'Toggle', edit the language pack - Language_customisation - and filter on 'format_topcoll.php', then find the string 'topcolltoggle'.

In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Mary O'Donnell -

Thanks Rick, yes I have tried all these options and wanted to set the default through site administration also. However none of the options get rid of the word toggle on my site. I will investigate further I must have something else in place that is resisting this change across the site. Thank ks for your help  at least I was looking in the right place.

In reply to Mary O'Donnell

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

I found a combination of Elements and structure to get what I want as shown in these two pics:

-----------------------------------------------------------------------------------------------------------------------------------------

----------------------------------------------------------------------------------------------------------------------

and the sections look like this:



In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Getting back to one of my original questions:
Is it possible to change the font size and the height of the toggle option bar?

It was mentioned that these could be changed in CSS but I do not know the code to do so.
The problem is that I already use CSS to have specific font sizes for my resources and the new font size for the CT bars looks out of place.




In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

The height of the toggle is determined by the content.  So how much of it and the size of the font etc.  The selectors to use in the theme custom CSS are:

.course-content ul.ctopics li.section .content .toggle span.the_toggle h3.sectionname,
.course-content ul.ctopics li.section .content.sectionhidden h3.sectionname

e.g:

.course-content ul.ctopics li.section .content .toggle span.the_toggle h3.sectionname,
.course-content ul.ctopics li.section .content.sectionhidden h3.sectionname { font-size: 64px; line-height: 64px; }
In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Where does this code go?  Custom CSS or additional HTML?

Does it matter?  What is the difference?
In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Custom CSS because it is CSS and not HTML.

Average of ratings: Useful (1)
In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

Interesting, I have been running my CSS in the Additional HTML and it has been working all  along.  It may happen because the CSS code is inside the < style> < /style> tags.  Should it matter?  

I guess I should have all my CSS code shifted to Custom CSS basically because it is the correct location.  Since I do not have access to Admin Screens, I don't know where the Custom CSS is located.


In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Richard Oelmann -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

I would agree with Gareth that it should go in CustomCSS - I'm not sure whether CSS added to the AdditionalHTML settings would get cached with the other CSS styles?

Wrapped in <style> tags it will work within the AdditionalHTML and there would apply across whatever themes you are using, while CustomCSS applies to the specific theme (and if you are using several would need to be copied across to each of them). But as I said, I would go with Gareth's view that CSS should ideally be in CustomCSS, where possible. (There's another recent thread about adding javascript through the AdditionalHTML too - and whether it should be allowed - Not sure on that one as I don't think there's anywhere else to put it, while for CSS there is an appropriate setting for it, as well as some themes having a similar customLESS setting)

Query - if you don't have access to the admin pages, eg for adding customcss (It's in each theme's settings pages), then how do you add the AdditionalHTML, which is also an admin setting?

Richard

In reply to Richard Oelmann

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

"Query - if you don't have access to the admin pages, eg for adding customcss (It's in each theme's settings pages), then how do you add the AdditionalHTML, which is also an admin setting? "

Easy, I have a cooperative admin.....  (:

In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers
Steve, I am a little bit ahead of myself.  I will be giving this presentation this week at MoodleMoot2016.  (It's in the MoodleMoot system, which you have access to.) Parts of it might be of interest to you (adding CSS code).  My presentation also has a video presentation, so you can watch my presentation at your convenience.  It is also following the Pecha Kucha technique, so it is exactly 6:40 minutes.
In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Steve Ambro v3.8 -

"Steve, I am a little bit ahead of myself.  I will be giving this presentation this week at MoodleMoot2016.  (It's in the MoodleMoot system, which you have access to.) Parts of it might be of interest to you (adding CSS code).  My presentation also has a video presentation, so you can watch my presentation at your convenience.  It is also following the Pecha Kucha technique, so it is exactly 6:40 minutes."


I finally got in to see your presentation.  Using the University system, do the changes here apply to all instructors or can I make changes just for my courses?


In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

As I understand it, custom CSS applies to the entire site.   Maybe Gareth can provide a little more detail about this, but here is how I think it works.

1) Moodle core (CSS) comes first.

2) A theme comes next.

3) Some internal theme changes made at the course level come next.

4) Custom CSS comes last.

Quite honestly, I am not sure if my #4 is in the correct position.  (Mary and Gareth, or others?)

In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Richard Oelmann -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

Customcss is part of the theme Rick, so should be applied as the last part of the theme css, assuming the theme is set up correctly.

Not sure what you mean by 'internal theme changes made at the course level'? Do you mean colours and so on applied by teachers through the text editor? in which case yes they would be applied last of all as they are treated as 'inline' styles within the content itself.

Richard

In reply to Richard Oelmann

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

I was mistaken. I was thinking about about the add-in collapsed topics, that it has its own settings.  Then I apply some CDs to change it. But collapsed topics is different than a theme.

In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Yes.  In the Custom CSS it will be cached for all pages.  In the Additional HTML it will suck up bandwidth on every page load.

The 'Custom CSS' is located in the theme.

In reply to Steve Ambro v3.8

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

Steve, I provided all of my CSS code above, and maybe some of it will help.  In addition to what Gareth mentions, I think that I am implementing a form of this.  Here is the relevant section of my CSS code file below (Gareth might be able to add some guidance about whether my code is good or not needed.)


/* Fix word wrap and tweak display of collapsed topics headings */

.course-content ul.ctopics li.section .content .toggle a  h3,

.course-content ul.ctopics li.section .content.sectionhidden h3  {

word-wrap: normal;

overflow-wrap: normal;

word-break: normal;

margin: .1em;

width: 102%;

}

Average of ratings: Useful (1)
In reply to Rick Jerz

Re: "Collapsed Topics course format plugin" questions,...

by Gareth J Barnard -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi Rick,

The 102% looks odd.  But there are some oddities.  I think I've just changed something that affects that.  But that would have been a little while ago.  Mind filled with Essential!

G

In reply to Gareth J Barnard

Re: "Collapsed Topics course format plugin" questions,...

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

I remember playing around with that 102% value, and for whatever reason, it seemed to work best.  I prefer working in percentages and ems so that my changes can be "responsive."  (I think.)  Yes, I made these changes maybe a year ago, so I have wondered if some are still needed as you have improved Collapsed Topics.