Thans for integrating this functionality, it has a lot of potential for visualising data!
Is there a way to set the radius (or size in general) of a pie chart?
pie showData
    title Key elements in Product X
    "Calcium" : 42.96
    "Potassium" : 50.05
    "Magnesium" : 10.01
 
            
              8 Likes 
            
            
           
          
            
              
                Tris20  
                
                  
                    September 4, 2023,  8:40am
                   
                  2 
               
             
            
              Iâm also having some size/scaling issues. Gaant charts for example are essentially useless 
Is there anyway Discourse could provide the option to view mermaid diagrams in a fullscreen way, similar to the Markdown Table Fullscreen ?
             
            
              6 Likes 
            
            
           
          
            
              
                sam  
              
                  
                    September 5, 2023,  1:18am
                   
                  5 
               
             
            
              
This is a fantastic idea, I would love to have it. We donât have this work slotted at the moment.
             
            
              8 Likes 
            
            
           
          
            
              
                Tris20  
                
                  
                    April 23, 2024,  9:12am
                   
                  7 
               
             
            
              
Are we likely to see any movement on this? It just feels such a shame to have something so usefull sit so close to perfection.
We wanted to use a pie chart to show some of the distribution of languages in the company, but this is the real size in the end 
             
            
              1 Like 
            
            
           
          
            
              
                gpetrov  
              
                  
                    May 15, 2024,  8:52am
                   
                  11 
               
             
            
              is it possible to have some zoom possibilities to the mermaid display? Larger diagrams can become quate small now.
Maybe allow the mermaid diagrams to be opened in a popup lightbox and have pan and zoom like on https://mermaid.live/ 
             
            
              3 Likes 
            
                
            
           
          
            
            
              This would be a great additional feature!
             
            
              1 Like 
            
            
           
          
            
              
                sam  
              
                  
                    May 16, 2024,  1:13am
                   
                  13 
               
             
            
              I would love this feature. It is assigned to the member experience team and will be prioritized by them.
Missing this is certainly heavily impacting how useful complex mermaid diagrams on the forums can be.
As to when? @lindsey  will be prioritizing this.
If you need it in a hurry though probably best talk to Jamie
             
            
              8 Likes 
            
            
           
          
            
              
                Tris20  
              
                  
                    May 16, 2024,  9:06am
                   
                  14 
               
             
            
              Thank you for looking at this again 
             
            
              1 Like 
            
            
           
          
            
            
              +1 for this much needed feature - any progress?
             
            
              1 Like 
            
            
           
          
            
            
              We also really need this feature at our company, scaling charts in height is limited and this make mermaid useless in discourse, need to have a way to render them externally or by showing them fullscreen.
             
            
              1 Like 
            
            
           
          
            
            
              I built something. I thought someone might want to give it a try before I release it.
The goal was to have a low-threshold and robust approach:
analyze if a post contains an SVG element 
if so, display a text link âzoomâ next to it 
open the SVG in a new browser window where you can zoom, print, etc. as you like 
 
GitHub - rstockm/svg-zoom: Discourse theme component that adds zoom functionality to Mermaid/SVG elements in posts 
             
            
              
            
           
          
            
              
                sam  
                
                  
                    February 11, 2025,  1:48am
                   
                  36 
               
             
            
              Update, @David  is working on a fix here and it looks great, we just need to clean up some APIs and will post about it soon.
  
  
    
    
  
      
    
      main â fixed-height
    
      
        
          opened 05:13PM - 10 Feb 25 UTC 
        
        
        
       
   
 
  
    The variable-height strategy used by this theme component is complex, and is not⊠ providing a good user experience. This commit removes it, and instead sets all mermaid diagrams to have a fixed aspect-ratio of `16:9` when rendered in posts. For tall diagrams, the content will be scrollable. A fullscreen button in the top right allows popping the diagram into a modal.
(WIP - this doesn't work in composer-preview or chat yet) 
   
   
  
    
    
  
  
 
             
            
              4 Likes 
            
            
           
          
            
              
                david  
              
                  
                    February 11, 2025,  5:58pm
                   
                  37 
               
             
            
              This is now merged. Diagrams will always be rendered with a 16:9 aspect ratio, and thereâs a button to pop them into a fullscreen view:
kanban
  Todo
    [Create Documentations]
    docs[Create Blog about the new diagrams]
  [In progress]
    id6[Create renderer so that it works in all cases. We also add som extra text here for testing purposes. And some more just for the extra flare.]
  id9[Ready for deploy]
    id8[Design grammar]@{ assigned: 'knsv' }
  id10[Ready for test]
    id4[Create parsing tests]@{ ticket: MC-2038, assigned: 'K.Sveidqvist', priority: 'High' }
    id66[last item]@{ priority: 'Very Low', assigned: 'knsv' }
  id11[Done]
    id5[define getData]
    id2[Title of diagram is more than 100 chars when user duplicates diagram with 100 char]@{ ticket: MC-2036, priority: 'Very High'}
    id3[Update DB function]@{ ticket: MC-2037, assigned: knsv, priority: 'High' }
  id12[Can't reproduce]
    id3[Weird flickering in Firefox]
 
            
              4 Likes 
            
            
           
          
            
              
                tvavrda  
                
                  
                    February 11, 2025,  8:39pm
                   
                  38 
               
             
            
              OMG. I am sorry, but the reaction is not enough. THANK YOU!!!
One small thing â if I zoom out a bit using the browser (Alt+ - ) the texts do not fit. If I am at 100 %, itâs all perfect.
             
            
              2 Likes 
            
            
           
          
            
              
                tvavrda  
              
                  
                    February 11, 2025,  8:46pm
                   
                  39 
               
             
            
              Also just noticed that Mermaid charts do not switch light/dark theme without refreshing the browser when using the new dark theme switcher setting.
             
            
              2 Likes 
            
            
           
          
            
              
                Tris20  
              
                  
                    February 18, 2025,  2:27pm
                   
                  40 
               
             
            
              Massive thank you from my side for putting through an update for this 
Now we can use Gaant charts and Pie charts along with Discourseâs revision history 
             
            
              
            
           
          
            
            
              Thank you, but I would prefer to open the chards in a new, dedicated window - so wie can Print, export to PDF etc.
See my approach:
             
            
              
            
           
          
            
              
                david  
              
                  
                    February 25, 2025,  6:10pm
                   
                  42 
               
             
            
              This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.