mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-03 20:06:08 +01:00 
			
		
		
		
	fix(calendar_view): add back note icon
This commit is contained in:
		@@ -158,6 +158,27 @@ export default class CalendarView extends ViewMode {
 | 
				
			|||||||
            eventDidMount: (e) => {
 | 
					            eventDidMount: (e) => {
 | 
				
			||||||
                const { iconClass, promotedAttributes } = e.event.extendedProps;
 | 
					                const { iconClass, promotedAttributes } = e.event.extendedProps;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					                // Prepend the icon to the title, if any.
 | 
				
			||||||
 | 
					                if (iconClass) {
 | 
				
			||||||
 | 
					                    let titleContainer;
 | 
				
			||||||
 | 
					                    switch (e.view.type) {
 | 
				
			||||||
 | 
					                        case "timeGridWeek":
 | 
				
			||||||
 | 
					                        case "dayGridMonth":
 | 
				
			||||||
 | 
					                            titleContainer = e.el.querySelector(".fc-event-title");
 | 
				
			||||||
 | 
					                            break;
 | 
				
			||||||
 | 
					                        case "multiMonthYear":
 | 
				
			||||||
 | 
					                            break;
 | 
				
			||||||
 | 
					                        case "listMonth":
 | 
				
			||||||
 | 
					                            titleContainer = e.el.querySelector(".fc-list-event-title a");
 | 
				
			||||||
 | 
					                            break;
 | 
				
			||||||
 | 
					                    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					                    if (titleContainer) {
 | 
				
			||||||
 | 
					                        const icon = /*html*/`<span class="${iconClass}"></span> `;
 | 
				
			||||||
 | 
					                        titleContainer.insertAdjacentHTML("afterbegin", icon);
 | 
				
			||||||
 | 
					                    }
 | 
				
			||||||
 | 
					                }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                // Append promoted attributes to the end of the event container.
 | 
					                // Append promoted attributes to the end of the event container.
 | 
				
			||||||
                if (promotedAttributes) {
 | 
					                if (promotedAttributes) {
 | 
				
			||||||
                    let promotedAttributesHtml = "";
 | 
					                    let promotedAttributesHtml = "";
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user