{"id":878,"date":"2020-02-22T09:57:06","date_gmt":"2020-02-22T09:57:06","guid":{"rendered":"https:\/\/html5-chat.com\/blog\/?p=878"},"modified":"2020-02-22T09:57:08","modified_gmt":"2020-02-22T09:57:08","slug":"how-to-change-my-chat-design","status":"publish","type":"post","link":"https:\/\/html5-chat.com\/blog\/how-to-change-my-chat-design\/","title":{"rendered":"How to change my chat&#8217;s design ?"},"content":{"rendered":"\n<p>If you want to customize the look&amp;feel of your chat, you need to use CSS.<br>If you don&#8217;t know <a href=\"https:\/\/www.w3schools.com\/css\/css_intro.asp\">what is CSS<\/a>, please visit that site. (however learning CSS will take a few days, so If you have some urgent customisations, I suggest you hire a freelancer or eventually <a href=\"\/contact\">contact us<\/a> for this extra task)<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Do not overwrite, but add !<\/h2>\n\n\n\n<p>Many users ask us to send them access to CSS so they can modify it. This is a big misunderstanding about how CSS really works. <br>In order to maintain the script up to date, you will never change script or CSS, but you will add yours. <strong>The added properties will simply overwrite the existing one.<\/strong><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to add my own CSS ?<\/h2>\n\n\n\n<p>Go to your <a href=\"\/chatadmin\"><strong>chatadmin panel -&gt; config -&gt;Design\/Layout<\/strong><\/a>  and insert there the link to your own CSS under the  <strong>Link to external CSS to customize your chat<\/strong> text field.<br>Ex:<br><em>https:\/\/www.mywebsite.com\/myCss.css<\/em><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">How to write my own CSS ?<\/h2>\n\n\n\n<p>You need good knowledge of CSS. Use Google Developer tool to get the selector of your DOM, and then write the property.<br>Ex: Here is the CSS to overwrite the way messages are shown in the chat: <br>We hide the avatar, the time and make the message fit 1 line:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">div.message img.userItem {<br>    <em>display<\/em>: <strong>none<\/strong>;<br>}<br>div.message div.timeStamp {<br>    <em>display<\/em>: <strong>none<\/strong>;<br>}<br>div.message div.content {<br>    <em>box-shadow<\/em>: <strong>none<\/strong>;<br>    <em>border<\/em>: <strong>none<\/strong>;<br>    <em>display<\/em>: <strong>inline<\/strong>;<br>}<br>div.message div.flex-property {<br>    <em>display<\/em>: <strong>inline<\/strong><strong>!important<\/strong>;<br>}<br>.arrow-chat {<br>    <em>display<\/em>: <strong>none<\/strong><strong>!important<\/strong>;<br>}<br>div.message div.userItem {<br>    <em>display<\/em>: <strong>inline<\/strong>;<br>    <em>font-weight<\/em>: <strong>bold<\/strong>;<br>}<br><br>div.message div.userItem:after {<br>    <em>content<\/em>: \":\";<br>}<br><\/pre>\n\n\n\n<p>The messages will appear now: <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"349\" height=\"278\" src=\"https:\/\/html5-chat.com\/blog\/wp-content\/uploads\/2020\/02\/1lineMessages.jpg\" alt=\"\" class=\"wp-image-882\" srcset=\"https:\/\/html5-chat.com\/blog\/wp-content\/uploads\/2020\/02\/1lineMessages.jpg 349w, https:\/\/html5-chat.com\/blog\/wp-content\/uploads\/2020\/02\/1lineMessages-300x239.jpg 300w\" sizes=\"auto, (max-width: 349px) 100vw, 349px\" \/><figcaption>CSS to make messages appear on 1 line !<\/figcaption><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>If you want to customize the look&amp;feel of your chat, you need to use CSS.If you don&#8217;t know what is CSS, please visit that site. (however learning CSS will take a few days, so If you have some urgent customisations, I suggest you hire a freelancer or eventually contact us for this extra task) Do [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":890,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[32],"tags":[4],"class_list":["post-878","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-integration","tag-css"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/posts\/878","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/comments?post=878"}],"version-history":[{"count":7,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/posts\/878\/revisions"}],"predecessor-version":[{"id":893,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/posts\/878\/revisions\/893"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/media\/890"}],"wp:attachment":[{"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/media?parent=878"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/categories?post=878"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/html5-chat.com\/blog\/wp-json\/wp\/v2\/tags?post=878"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}