Salesforce

Salesforce

Simple lightningsnapin/baseChatMessage LWC Component

Sample Code: HTML: <template> <h1>Welcome to the Chat</h1> <div class={messageStyle}> <lightning-formatted-rich-text value={messageContent.value}> </lightning-formatted-rich-text> </div> </template> JavaScript: import BaseChatMessage from 'lightningsnapin/baseChatMessage'; const CHAT_CONTENT_CLASS = 'chat-content'; const AGENT_USER_TYPE = 'agent'; const CHASITOR_USER_TYPE ....

Salesforce

Custom sorting with Up and Down Arrow using LWC in Salesforce

Sample Code: HTML: <template> <div class="slds-box slds-theme--default"> <div class="slds-text-color_inverse slds-text-heading_large" style="padding:0.5rem;background:#16325c"> Accounts </div> <table class="slds-table slds-table_cell-buffer slds-table_bordered slds-table_striped"> <thead> <tr class="slds-line-height_reset"> <th class="" scope="col"> <a class="slds-th__action slds-text-link_reset" href="javascript:void(0);" role="button" tabindex="0" ....