Last active
March 17, 2026 02:50
-
-
Save ericboehs/56efd2341689f76510980c2ef5bb1638 to your computer and use it in GitHub Desktop.
Mattermost plugin to disable Show More/Show Less post truncation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var plugin = { | |
| initialize: function() { | |
| var style = document.createElement('style'); | |
| style.id = 'no-show-more-plugin'; | |
| style.textContent = [ | |
| '/* Remove max-height on collapsed posts */', | |
| '.post-message--collapsed .post-message__text-container {', | |
| ' max-height: none !important;', | |
| '}', | |
| '/* Remove the gradient fade mask */', | |
| '.post-message--collapsed.post-message--overflow .post-message__text-container {', | |
| ' mask-image: none !important;', | |
| ' -webkit-mask-image: none !important;', | |
| '}', | |
| '/* Hide the Show More button and lines */', | |
| '.post-collapse__show-more,', | |
| '.post-attachment-collapse__show-more {', | |
| ' display: none !important;', | |
| '}', | |
| '/* Also handle sidebar card collapsed */', | |
| '.sidebar-right__card .post-message--collapsed {', | |
| ' max-height: none !important;', | |
| '}' | |
| ].join('\n'); | |
| document.head.appendChild(style); | |
| }, | |
| uninitialize: function() { | |
| var el = document.getElementById('no-show-more-plugin'); | |
| if (el) el.remove(); | |
| } | |
| }; | |
| window.registerPlugin('com.boehs.no-show-more', plugin); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "id": "com.boehs.no-show-more", | |
| "name": "No Show More", | |
| "description": "Disables the Show More/Show Less post truncation", | |
| "version": "1.0.1", | |
| "min_server_version": "9.0.0", | |
| "webapp": { | |
| "bundle_path": "webapp/dist/main.js" | |
| } | |
| } |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Mattermost "No Show More" Plugin
Mattermost truncates posts taller than 600px behind a "Show More" button. There's no setting to disable this. This webapp-only plugin injects CSS to remove the truncation.
Install
Download
com.boehs.no-show-more.tar.gzfrom this gist, then upload it via System Console > Plugin Management and enable it.For Docker/headless installs:
(
EnableLocalMode: truerequired in config — see blog post for full details.)Hard-refresh (Cmd+Shift+R) or restart the desktop app after installing.
Tested on Mattermost 11.3.0.