How to hide activity type in Moodle 4.0

How to hide activity type in Moodle 4.0

ដោយ Prush Sa-nga-ngam នៅ
ចំនួនតប៖ 21

I'm trying Moodle 4.0. How to hide or remove activity type and show only icon and activity name. Thank you.

Activities type shows

មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (2)
ឆ្លើយតបទៅកាន់ Prush Sa-nga-ngam

Re: How to hide activity type in Moodle 4.0

ដោយ Dominique Palumbo នៅ
រូបភាព Particularly helpful Moodlers រូបភាព Plugin developers
Hi,

you can add these lines in Additional HTML (additionalhtmlfooter)
<script>
    $(".activityname").prev().css('display', 'none');
</script>
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (2)
ឆ្លើយតបទៅកាន់ Dominique Palumbo

ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Prush Sa-nga-ngam នៅ
Thank you Dominique. I have added the script that but It's not working. Any other setting needed?
មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Prush Sa-nga-ngam

Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Randy Thornton នៅ
រូបភាព Documentation writers
Prush

You can use this css to do that:

.activitytitle .text-uppercase { display: none; }

This new element is called the "activitytitle". CSS for this and some variants of it is already posted over this discussion in the Themes forum, thanks to Bob Gilmore. That discussion has a lot of other fixes too.
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (7)
ឆ្លើយតបទៅកាន់ Randy Thornton

ตอบ: Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Prush Sa-nga-ngam នៅ

Many thanks, Randy. I am relatively new to CSS and am beginning to learn it.

មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Prush Sa-nga-ngam

Re: ตอบ: Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Dominique Palumbo នៅ
រូបភាព Particularly helpful Moodlers រូបភាព Plugin developers
Hi,

the Randy solution is far better. I've missed the class .ctivitytitle...
when you add the css you've to put it between the tag style

<style>
....
</style>
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (1)
ឆ្លើយតបទៅកាន់ Dominique Palumbo

Re: ตอบ: Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Randy Thornton នៅ
រូបភាព Documentation writers
You can also put this in the css area for a theme as well. For the default theme Boost, you can put this in Site admin > Appearance > Themes > Boost > Advanced settings > Raw SCSS.

As general rule, if I only need pure css / scss in a theme, I put it there in the Raw SCSS box. If I need some actual html, I put it in Additional HTML. But that's just how I do it: do whatever works for you ញញឹម

Most third party themes have such a css box, though it may have a different name, such as "Custom CSS" etc. if you have several themes on the site, and want the change to apply to all the themes, you can put it in Additional HTML too since it affects all the pages. That does not mean any particular css will work properly in every theme, however, since some themes change how some css selectors work, but if it does, it can save you work since there is only one place to have to change things.
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (2)
ឆ្លើយតបទៅកាន់ Randy Thornton

Re: ตอบ: Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Rick Jerz នៅ
រូបភាព Particularly helpful Moodlers រូបភាព Testers
This supports, visually, what Rand has said.

ឯកសារភ្ជាប់ Remove_Text1.png
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (7)
ឆ្លើយតបទៅកាន់ Rick Jerz

Re: ตอบ: Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Randy Thornton នៅ
រូបភាព Documentation writers
Oh, I like those dotted arrows!
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (2)
ឆ្លើយតបទៅកាន់ Rick Jerz

ตอบ: Re: ตอบ: Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Prush Sa-nga-ngam នៅ
Thank you Rick. I noticed other customize. Could you please suggest further readings.
មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Randy Thornton

Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Anthony M នៅ
Thanks a lot Randy!

That worked to remove the "activitytitle" from the course main page.

Anyone know to to also target the activity page? (once the user click to enter the activity)...





Thanks!
មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Anthony M

Re: ตอบ: Re: How to hide activity type in Moodle 4.0

ដោយ Aleksandr Potapov នៅ

Add to CSS:

div .text-muted.text-uppercase.small.line-height-3 { display: none; }


មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Prush Sa-nga-ngam

Re: How to hide activity type in Moodle 4.0

ដោយ Howard Miller នៅ
រូបភាព Core developers រូបភាព Documentation writers រូបភាព Particularly helpful Moodlers រូបភាព Peer reviewers រូបភាព Plugin developers
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (1)
ឆ្លើយតបទៅកាន់ Howard Miller

Re: How to hide activity type in Moodle 4.0

ដោយ Ken Task នៅ
រូបភាព Particularly helpful Moodlers

Voted!   Can I get more votes!   I'd like to do at least 20! ញញឹម

Always wanted to ask ... sooo ... what's the threshold ... how many votes does it take to 'get whatever done'?

'SoS', Ken

មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Ken Task

Re: How to hide activity type in Moodle 4.0

ដោយ Howard Miller នៅ
រូបភាព Core developers រូបភាព Documentation writers រូបភាព Particularly helpful Moodlers រូបភាព Peer reviewers រូបភាព Plugin developers
I don't now but I don't get the impression it works that way. It just 'greases the wheel', so to speak.
មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Ken Task

Re: How to hide activity type in Moodle 4.0

ដោយ Visvanath Ratnaweera នៅ
រូបភាព Particularly helpful Moodlers រូបភាព Translators
What a blunder!

I added the first comment to MDL-75204. Tried my best to keep a polite tone. It was difficult, believe me!
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (2)
ឆ្លើយតបទៅកាន់ Visvanath Ratnaweera

Re: How to hide activity type in Moodle 4.0

ដោយ Howard Miller នៅ
រូបភាព Core developers រូបភាព Documentation writers រូបភាព Particularly helpful Moodlers រូបភាព Peer reviewers រូបភាព Plugin developers
I noticed សើចសប្បាយ
មធ្យមភាគនៃរង្វាយតម្លៃ: -
ឆ្លើយតបទៅកាន់ Prush Sa-nga-ngam

Re: How to hide activity type in Moodle 4.0

ដោយ Ahmed Hosny នៅ

use this course format

https://moodle.org/plugins/format_designer

and you have option for each activity to shown/hide, activty name, type, title , decription, completion, visits...

មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (1)
ឆ្លើយតបទៅកាន់ Prush Sa-nga-ngam

Re: How to hide activity type in Moodle 4.0

ដោយ Mark Sharp នៅ
រូបភាព Core developers រូបភាព Particularly helpful Moodlers រូបភាព Plugin developers
If you update to the latest version of M4.0 or M4.1, the activity type only displays now when in editing mode.
មធ្យមភាគនៃរង្វាយតម្លៃ:Useful (1)