<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: mutesialine</title>
    <description>The latest articles on DEV Community by mutesialine (@mutesialine).</description>
    <link>https://dev.to/mutesialine</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F972278%2F30a750d4-1d03-41c0-bf86-89c2657640d2.jpeg</url>
      <title>DEV Community: mutesialine</title>
      <link>https://dev.to/mutesialine</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mutesialine"/>
    <language>en</language>
    <item>
      <title>Eventlistener(scroll) using tailwindcss and vanilla Javacript</title>
      <dc:creator>mutesialine</dc:creator>
      <pubDate>Wed, 16 Nov 2022 14:12:55 +0000</pubDate>
      <link>https://dev.to/mutesialine/eventlistenerscroll-using-tailwindcss-and-vanilla-javacript-6ee</link>
      <guid>https://dev.to/mutesialine/eventlistenerscroll-using-tailwindcss-and-vanilla-javacript-6ee</guid>
      <description>&lt;p&gt;Scroll event happen when user  scroll in a saturn direction  and it works on the browser window lets take an example of the page where navbar change background ,text and image when scroll event happen&lt;/p&gt;

&lt;h1&gt;
  
  
  index.html
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;html&amp;gt;
&amp;lt;head&amp;gt;
&amp;lt;title&amp;gt;capgemini&amp;lt;/title&amp;gt;
&amp;lt;/head&amp;gt;
&amp;lt;body&amp;gt;
//navbar
&amp;lt;div class="w-full h-[800px]  relative  pb-10 bg-heroImage  bg-cover"&amp;gt;
        &amp;lt;div id="navbar" class="navwhite text-white   fixed p-8 top-0 w-full  flex  gap-8 justify-between lg:justify-start z-50 items-center "&amp;gt; 
                &amp;lt;img id="image1"  class="w-28" src="./img/logo-white.svg" alt="logowhite"&amp;gt;
                &amp;lt;img  id="image2" class="w-28" src="./img/logoblue.svg" alt="logoblue"&amp;gt;

                &amp;lt;div class="flex   gap-3"&amp;gt;
                    &amp;lt;a href=""&amp;gt;Insights&amp;lt;/a&amp;gt;
                    &amp;lt;a href=""&amp;gt;Industries&amp;lt;/a&amp;gt;
                    &amp;lt;a href=""&amp;gt;Services&amp;lt;/a&amp;gt;
                    &amp;lt;a href=""&amp;gt;Carees&amp;lt;/a&amp;gt;
                    &amp;lt;a href=""&amp;gt;News&amp;lt;/a&amp;gt;
                    &amp;lt;a href=""&amp;gt;About us&amp;lt;/a&amp;gt;
                &amp;lt;/div&amp;gt;
        &amp;lt;/div&amp;gt;
        &amp;lt;div class="absolute bottom-2 lg:bottom-32 py-6  px-8  space-y-2  bg-opacity-90 text-white   lg:left-20 mx-4 bg-[#056295]  lg:mx-0"&amp;gt;
            &amp;lt;h1 class="text-3xl font-bold "&amp;gt;AUTHORS OF CHANGE&amp;lt;/h1&amp;gt;
            &amp;lt;p class=" text-lg "&amp;gt;Making the world more inclusive with words&amp;lt;/p&amp;gt;
        &amp;lt;/div&amp;gt;
    &amp;lt;/div&amp;gt;
&amp;lt;script src="/navbar.js"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;/body&amp;gt;
&amp;lt;/html&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  index.css
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@tailwind base;
@tailwind components;
@tailwind utilities;

.navwhite{
  @apply bg-white text-black; 
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  navbar.js
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;function changeNav(){
  var navbar= document.getElementById('navbar');
  var image1=document.getElementById('image1');
  var image2 = document.getElementById("image2");
  var scrollyValue=window.scrollY;
  if(scrollyValue &amp;lt; 20){
    navbar.classList.remove('navwhite')
    image2.style.display="none";
    image1.style.display="block"
  }
  else{
    navbar.classList.add('navwhite')
    image1.style.display= "none";
    image2.style.display="block"
  }
}
  window.addEventListener("scroll", changeNav);

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Before:The fixed navbar
&lt;/h1&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--zrzfNOBi--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/alf9b2vzvxs3pgrx6s94.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--zrzfNOBi--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/alf9b2vzvxs3pgrx6s94.png" alt="Image description" width="880" height="495"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  After:when scrolling  navbar changes background color, textcolor, and logo image  until user stop scrolling
&lt;/h1&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--jHDfGcJ2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vsyxcyewbdhzv9192vhb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--jHDfGcJ2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vsyxcyewbdhzv9192vhb.png" alt="Image description" width="880" height="495"&gt;&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Position in Tailwindcss</title>
      <dc:creator>mutesialine</dc:creator>
      <pubDate>Tue, 15 Nov 2022 15:33:08 +0000</pubDate>
      <link>https://dev.to/mutesialine/position-in-tailwindcss-43ho</link>
      <guid>https://dev.to/mutesialine/position-in-tailwindcss-43ho</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--h-KqJ0P3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/odwzt83ja06pcoot16nk.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--h-KqJ0P3--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/odwzt83ja06pcoot16nk.PNG" alt="Image description" width="880" height="203"&gt;&lt;/a&gt;Position property is how element is positioned in webpage  we have&lt;/p&gt;

&lt;p&gt;static: by default all elements are static means they cant be moved like top ,bottom , right or left &lt;/p&gt;

&lt;p&gt;Relative:element is positioned related to its normal position&lt;br&gt;
Absolute:  The elemenent is positioned absolutly according to its first parent and can be moved top right ,bottom or left&lt;/p&gt;

&lt;p&gt;&lt;code&gt;&amp;lt;div class="relative"&amp;gt;&lt;br&gt;
   &amp;lt;p&amp;gt;paragraphy1&amp;lt;/p&amp;gt;&lt;br&gt;
   &amp;lt;p class="absolute"&amp;gt;paragraphy2&amp;lt;/p&amp;gt;&lt;br&gt;
 &amp;lt;/div&amp;gt;&lt;br&gt;
&lt;/code&gt;&lt;br&gt;
Fixed: The element is position based on  browser window means  can not be moved&lt;br&gt;
sticky : The element is postioned based on user scroll position it act like fixed until its acrross  its parents&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Max-width ,Min-width vs width</title>
      <dc:creator>mutesialine</dc:creator>
      <pubDate>Mon, 14 Nov 2022 13:04:55 +0000</pubDate>
      <link>https://dev.to/mutesialine/max-width-min-width-vs-width-4kc7</link>
      <guid>https://dev.to/mutesialine/max-width-min-width-vs-width-4kc7</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--biMf53yH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qhaiufz4zab2t1q6ctey.PNG" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--biMf53yH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qhaiufz4zab2t1q6ctey.PNG" alt="Image description" width="880" height="256"&gt;&lt;/a&gt;The maximum width specifies the maximum screen width to the specific device&lt;br&gt;
 The Min-width specifies the minimum screen width to also the specific devices whereas&lt;br&gt;
width  set an element to the fixed width&lt;br&gt;
percentage of width : set apercentage based on a specific width&lt;/p&gt;

&lt;p&gt;Better to use width for a fixed element and use max-width for  thing that can change to any breakpoint.&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
