<?xml version="1.0" encoding="utf-8" standalone="no"?><rss xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" version="2.0"><channel><title>Fatih Hayrioğlu'nun not defteri</title><managingEditor>fatih.hayrioglu@gmail.com (Fatih Hayrioğlu)</managingEditor><pubDate>Wed, 5 Mar 2025 12:07:01 +0300</pubDate><generator>Jekyll https://github.com/mojombo/jekyll</generator><link>https://fatihhayrioglu.com</link><language>en-us</language><item><title>CSS'de lightdark() fonksiyonuyla kolayca koyu / açık mod yazımı</title><link>https://fatihhayrioglu.com/CSSde-lightdark-fonksiyonuyla-kolayca-koyu-acikk-mod-yazimi/</link><pubDate>Mon, 7 Oct 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/CSSde-lightdark-fonksiyonuyla-kolayca-koyu-acikk-mod-yazimi</guid><description>&lt;p&gt;Bir önceki yazımda bahsettiğim gibi CSS’in yeni özelliklerinin bazıları çığır açan özellikler, bazıları kulllanıcı deneyimini iyileştirme yönünde özellikler bazıları da &lt;code class="language-plaintext highlighter-rouge"&gt;lightdark()&lt;/code&gt; fonksiyonu gibi yazım kolaylığı sağlayan özellikler.&lt;/p&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;lightdark()&lt;/code&gt; fonksiyonu mevcut uyumlu web yazımındaki büyük sorun olan aşağıdaki kullanımı daha anlaşılır ve düzenli hale getirmeye yarıyor.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nd"&gt;:root&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;color-scheme&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;light&lt;/span&gt; &lt;span class="n"&gt;dark&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="py"&gt;--dark-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#292524&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--light-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#f5f5f4&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="py"&gt;--text-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--dark-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="py"&gt;--bg-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--light-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@media&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;prefers-color-scheme&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;dark&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nd"&gt;:root&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="py"&gt;--text-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--light-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="py"&gt;--bg-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--dark-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--text-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--bg-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Bu tip koyu/açık tanımlarını ayrı ayrı yapmak yerine&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nd"&gt;:root&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;color-scheme&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;light&lt;/span&gt; &lt;span class="n"&gt;dark&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;

  &lt;span class="py"&gt;--light&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#292524&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;--dark&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#f5f5f4&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;light-dark&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--light&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--dark&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;light-dark&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--dark&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--light&lt;/span&gt;&lt;span class="p"&gt;));&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Böylece daha kısa ve anlaşılır bir kod yapısına kavuşmuş oluyoruz.&lt;/p&gt;

&lt;iframe height="420" width="100%" style="width: 100%;" scrolling="no" title="lightdark() fonksiyonu" src="https://codepen.io/fatihhayri/embed/rNXLRer?default-tab=css%2Cresult&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Geliştirici araçlarındaki Styles sekmesindeki sağdan ikinci ikon yardımıyla dark / light arasında geçiş yapıp durumu simüle edebiliriz.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/light-dark.png" alt="Developer tool light dark" /&gt;&lt;/p&gt;

&lt;p&gt;Mevcut kodlarımızda kod boyutunu azaltacak bir özellik.&lt;/p&gt;

&lt;p&gt;Bu yazıyı yazdığımda tüm tarayıcıların yeni sürümlerinde desteği vardı. Türkiye’de oran %85. Güzel oran.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://www.bram.us/2023/10/09/the-future-of-css-easy-light-dark-mode-color-switching-with-light-dark/"&gt;https://www.bram.us/2023/10/09/the-future-of-css-easy-light-dark-mode-color-switching-with-light-dark/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://web.dev/articles/light-dark#:~:text=light-dark%28%29%20is%20a,the%20first%20value%20gets%20returned."&gt;https://web.dev/articles/light-dark#:~:text=light%2Ddark()%20is%20a,the%20first%20value%20gets%20returned.&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/light-dark"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/light-dark&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://frontendmasters.com/blog/dark-and-light/"&gt;https://frontendmasters.com/blog/dark-and-light/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/stuffbreaker/dark-mode-in-web-components-is-about-to-get-awesome-4i14"&gt;https://dev.to/stuffbreaker/dark-mode-in-web-components-is-about-to-get-awesome-4i14&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://daverupert.com/2024/05/light-dark-experiment/"&gt;https://daverupert.com/2024/05/light-dark-experiment/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://matuzo.at/blog/2024/100daysof-day107"&gt;https://matuzo.at/blog/2024/100daysof-day107&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/janeori/css-lightdark-mode-implementation-without-duplicating-vars-22c9"&gt;https://dev.to/janeori/css-lightdark-mode-implementation-without-duplicating-vars-22c9&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/natebirdman/status/1757224685614645290"&gt;https://x.com/natebirdman/status/1757224685614645290&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=1-yzpfTTGIg"&gt;https://www.youtube.com/watch?v=1-yzpfTTGIg&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/colisscom/status/1719151455075197210"&gt;https://x.com/colisscom/status/1719151455075197210&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://pawelgrzybek.com/light-dark-mode-simplified-by-the-css-light-dark-function/"&gt;https://pawelgrzybek.com/light-dark-mode-simplified-by-the-css-light-dark-function/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://caniuse.com/?search=light-dark"&gt;https://caniuse.com/?search=light-dark&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/CSSde-lightdark-fonksiyonuyla-kolayca-koyu-acikk-mod-yazimi/"&gt;CSS'de lightdark() fonksiyonuyla kolayca koyu / açık mod yazımı&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on October 07, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>field-sizing özelliği</title><link>https://fatihhayrioglu.com/field-sizing-ozelligi/</link><pubDate>Mon, 5 Aug 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/field-sizing-ozelligi</guid><description>&lt;p&gt;CSS’in yeni özellikleri bazen çığır açan nitelikte (anchor positioning, :has() seçicisi, vb.) olurken bazen yazıma yardımcı kurallar (iç içe yazım, @property) oluyor bazen de genel kullanılan kullanıcı deneyimi arttırıcı özellikleri oluyor. &lt;code class="language-plaintext highlighter-rouge"&gt;field-size&lt;/code&gt; özelliği genel kullanıcı deneyimini arttırıcı bir özellik. &lt;code class="language-plaintext highlighter-rouge"&gt;field-size&lt;/code&gt; özelliği genelde javascript ile çözdüğümüz bir ihtiyacı karşılıyor. Artık CSS ile kolayca bu ihtiyacımızı giderebiliyoruz. Genelde &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt; alanlarına yazılan uzun içerikler için kullanıcıya sunulan dar alanları büyütmek için kullandığımız kullanıcı metin girdikçe uzayan &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt; alanları için tanımlanmış bir özellik.&lt;/p&gt;

&lt;p&gt;Bu durum masaüstünde daha az sinir bozucuyken mobilde daha sinir bozucu bir durum oluşturuyor.&lt;/p&gt;

&lt;p&gt;Javascript ile yazılmış bir sürü script örneği ve makalesi mevcut bu durumu çözen ancak bir satır CSS kodu ile çözmenin hazzını hiçbiri vermiyor. :)&lt;/p&gt;

&lt;p&gt;Ben yukarıda &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt; için dediysem de uygulamada &lt;code class="language-plaintext highlighter-rouge"&gt;input&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;select&lt;/code&gt; elemanlarına uygulanabiliyor. Örnekler yardımıyla daha iyi anlaşılacak.&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title=" field-sizing: content;" src="https://codepen.io/fatihhayri/embed/abgpvgy?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/abgpvgy"&gt;
   field-sizing: content;&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki örnekte normal durumda &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt; içinde içerik girdikçe veya enter’a bastıkça sağda kaydırma çubuğu çıkarken &lt;code class="language-plaintext highlighter-rouge"&gt;field-size&lt;/code&gt; tanımı yapılan &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt;‘da içerik girdikçe veya enter’a basıldıkça &lt;code class="language-plaintext highlighter-rouge"&gt;textarea&lt;/code&gt; otomatik olarak artmaktadır.&lt;/p&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;input&lt;/code&gt; içinde bir örnek yapalım.&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="input -  field-sizing: content;" src="https://codepen.io/fatihhayri/embed/qBzRXgQ?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/qBzRXgQ"&gt;
  input -  field-sizing: content;&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki örnekte normal &lt;code class="language-plaintext highlighter-rouge"&gt;input&lt;/code&gt;‘ta içeriği uzattığımızda içerik sağa doğru kayarken &lt;code class="language-plaintext highlighter-rouge"&gt;field-sizing: content;&lt;/code&gt; uygulanan örnekte içerik girildikçe input genişliyor.&lt;/p&gt;

&lt;p&gt;Bir diğer uygulanan elemanda &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;select&amp;gt;&lt;/code&gt;&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="input -  field-sizing: content;" src="https://codepen.io/fatihhayri/embed/oNrZGEK?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/oNrZGEK"&gt;
  input -  field-sizing: content;&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;select&amp;gt;&lt;/code&gt; farklılıkları normalde içeriğe göre genişlik sabit olurken &lt;code class="language-plaintext highlighter-rouge"&gt;field-sizing: content;&lt;/code&gt; tanımlı select’te içeriği uzun olanda genişlik uzuyor kısa olanda kısa kalıyor.&lt;/p&gt;

&lt;p&gt;Blink (Chrome, Edge, Opera, Arc)  tabanlı tarayıcılarda bu özelliğin desteği var. Firefox desteğinin &lt;a href="https://x.com/intenttoship/status/1799438829260099996"&gt;yakında geleceği haberi&lt;/a&gt; geldi. Safari ekibinin de geliştirme aşmasında olduğunu &lt;a href="https://webkit.org/css-status/#property-field-sizing"&gt;biliyoruz.&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/field-sizing"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/field-sizing&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://polypane.app/blog/field-sizing-just-works/"&gt;https://polypane.app/blog/field-sizing-just-works/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://caniuse.com/mdn-css_properties_field-sizing"&gt;https://caniuse.com/mdn-css_properties_field-sizing&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://blog.stephaniestimac.com/posts/2024/01/css-field-sizing/"&gt;https://blog.stephaniestimac.com/posts/2024/01/css-field-sizing/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/wesbos/status/1790072655913050579"&gt;https://x.com/wesbos/status/1790072655913050579&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/jh3yy/status/1799460095585308690"&gt;https://x.com/jh3yy/status/1799460095585308690&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/JohnPhamous/status/1800963715631808949"&gt;https://x.com/JohnPhamous/status/1800963715631808949&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/field-sizing-ozelligi/"&gt;field-sizing özelliği&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on August 05, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>Tarayıcı geliştirici araçlarında yakınlaştırma ve uzaklaştırma yapmak</title><link>https://fatihhayrioglu.com/tarayici-gelistirici-araclarinda-yakinlastirma-ve-uzaklastirma-yapmak/</link><pubDate>Mon, 10 Jun 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/tarayici-gelistirici-araclarinda-yakinlastirma-ve-uzaklastirma-yapmak</guid><description>&lt;p&gt;Yaşlandıkça böyle ihtiyaçlar doğuyor galiba. Belki ihtiyacı olan olur diye buraya not edeyim. Chrome Dev Tools gibi araçlarda başlangıçtaki görünüm küçük kalabiliyor. Benim için küçük mesela :)&lt;/p&gt;

&lt;p&gt;Yazı boyutlarını büyütmek için &lt;code class="language-plaintext highlighter-rouge"&gt;Cmd + +&lt;/code&gt;  and  &lt;code class="language-plaintext highlighter-rouge"&gt;Cmd + -&lt;/code&gt; (Windows’ta Cmd yerine Ctrl kullanın). Ancak bu kısayol İngilizce klavye için Türkçe klavyelerde bunu yapmak için&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Büyütmek için:&lt;/strong&gt;  &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + .&lt;/code&gt; veya  &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + shift + p&lt;/code&gt; ile açılan menüye &lt;code class="language-plaintext highlighter-rouge"&gt;zoom in&lt;/code&gt;yazarakta oluyor.
&lt;strong&gt;Küçültmek için:&lt;/strong&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + -&lt;/code&gt;
&lt;strong&gt;Başlangıç değerine dönmek için:&lt;/strong&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + 0&lt;/code&gt;&lt;/p&gt;

&lt;h2 id="safari"&gt;Safari&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Büyütmek için:&lt;/strong&gt;  Kısayol bulamadım ancak Geliştirme aracının sağ üst köşesindeki ayarlar ikonuna tıklayıp gelen General sekmesinde en altta zoom seviyesini belirleyebiliyoruz.
&lt;strong&gt;Küçültmek için:&lt;/strong&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + -&lt;/code&gt;
&lt;strong&gt;Başlangıç değerine dönmek için:&lt;/strong&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + 0&lt;/code&gt;&lt;/p&gt;

&lt;h2 id="firefox"&gt;Firefox&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Büyütmek için:&lt;/strong&gt;  Adres barına &lt;code class="language-plaintext highlighter-rouge"&gt;about:config&lt;/code&gt; yazıp, arada gelen riskleri kabul ediyorum evet deyip sonra  gelen arama kısmında &lt;code class="language-plaintext highlighter-rouge"&gt;devtools.toolbox.zoomValue&lt;/code&gt; yazıp gelen değeri 1.5 (kendi tercihinize göre değiştirin) yaparak hallettim. 
&lt;strong&gt;Küçültmek için:&lt;/strong&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + -&lt;/code&gt;
&lt;strong&gt;Başlangıç değerine dönmek için:&lt;/strong&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;cmd + 0&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Bir diğer seçenekte İngilizce klavyeye geçip standart kısayolları da kullanabilirsiniz.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://stackoverflow.com/a/61046452"&gt;https://stackoverflow.com/a/61046452&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://devtoolstips.org/tips/en/zoom-devtools-content/"&gt;https://devtoolstips.org/tips/en/zoom-devtools-content/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.chrome.com/docs/devtools/shortcuts"&gt;https://developer.chrome.com/docs/devtools/shortcuts&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/tarayici-gelistirici-araclarinda-yakinlastirma-ve-uzaklastirma-yapmak/"&gt;Tarayıcı geliştirici araçlarında yakınlaştırma ve uzaklaştırma yapmak&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on June 10, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>HTML Akordiyon bileşeni</title><link>https://fatihhayrioglu.com/html-akordiyon-bileseni/</link><pubDate>Mon, 13 May 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/html-akordiyon-bileseni</guid><description>&lt;p&gt;Uzun içerikli yapıları daha az yer kaplayacak şekilde ve daha işlevsel kullanmak için genelde akordiyon yapılarını kullanırız.  Uzun süredir kullanıla gelen bu bileşenlerin genelde işlevselliğini javascript ile yapıyoruz. HTML ve CSS ile yapılan akordiyonlar için son günlerde gelen &lt;code class="language-plaintext highlighter-rouge"&gt;name&lt;/code&gt; attribute ile işlevsellik yönünden eksik kalan kısım tamamlandı.&lt;/p&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;name&lt;/code&gt; attribute tam olarak ne sağlıyor?&lt;/p&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;details&amp;gt;&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;summary&amp;gt;&lt;/code&gt; kullanımı ile oluşturduğumuz akordiyonlar başlığa tıkladığımızda açılan detay içeriği gösteriliyor. Biz daha çok başlığa tıklandığında açılıyor ve aynı zamanda açık olan başka içerik kapanıyor.&lt;/p&gt;

&lt;p&gt;Örneklerde daha iyi anlarız.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Örnekleri trendyol’da geliştirdiğimiz baklava tasarım sisteminde uyguladığımız tasarımları kullandım. Bu arada görmeyenler için baklava github linkini de buraya ekliyeyim. &lt;a href="https://github.com/Trendyol/baklava/"&gt;https://github.com/Trendyol/baklava/&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;blockquote&gt;
  &lt;p&gt;Bir diğer not da baklava design system açık kaynak bir proje katılıp katkı verebileceğiniz güzel bir proje olduğunu düşünüyorum. Katkılarınızı bekleriz.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id="mevcut-akordiyon-checkbox-gibi"&gt;Mevcut akordiyon (checkbox gibi)&lt;/h2&gt;

&lt;p&gt;Mevcut durumda kullanılan ve tarayıcı desteği gayet iyi olan tip bu.&lt;/p&gt;

&lt;iframe height="450" width="100%" style="width: 100%;" scrolling="no" title="akordiyon - checkbox gibi" src="https://codepen.io/fatihhayri/embed/qBgoRzW?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/qBgoRzW"&gt;
  akordiyon - checkbox gibi&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki örnekte sadece HTML ve CSS kullandık. Kendi stillerimizi uyguladık sadece.&lt;/p&gt;

&lt;h2 id="name-ile-oluşturulan-akordiyon-radio-gibi"&gt;name ile oluşturulan akordiyon (radio gibi)&lt;/h2&gt;

&lt;p&gt;Chrome 120 ve Safari 17.2 ile birlikte gelen &lt;code class="language-plaintext highlighter-rouge"&gt;name&lt;/code&gt; özniteliği desteği ile artık tıklanan ögenin dışındakileri kapatan akordiyonları da yapabileceğiz.&lt;/p&gt;

&lt;iframe height="450" width="100%" style="width: 100%;" scrolling="no" title="akordiyon - radio gibi" src="https://codepen.io/fatihhayri/embed/eYxMvOb?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/eYxMvOb"&gt;
  akordiyon - radio gibi&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Eğer Chrome ve Safari’nin developer sürümlerini yüklemediyseniz yukarıdaki kod sizde bir öncekiyle aynı gözükecektir.&lt;/p&gt;

&lt;iframe width="560" height="315" src="https://www.youtube.com/embed/iB9KDtbUufU?si=PHiXZ-iiItBBn30K" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen=""&gt;&lt;/iframe&gt;

&lt;h2 id="açık-gelen-akordiyon"&gt;Açık gelen akordiyon&lt;/h2&gt;
&lt;p&gt;Başlangıç durumunda bir akordiyon elemanının açık gelmesini istiyorsanız. Açık gelmesini istediğiniz akordiyon elemanında &lt;code class="language-plaintext highlighter-rouge"&gt;open&lt;/code&gt; öz niteliğini eklemeniz yeterli. Örnek: &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;details open&amp;gt;&lt;/code&gt;&lt;/p&gt;

&lt;iframe height="450" width="100%" style="width: 100%;" scrolling="no" title="akordiyon - radio gibi" src="https://codepen.io/fatihhayri/embed/mdvxWRm?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/mdvxWRm"&gt;
  akordiyon - radio gibi&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Örnekte görüldüğü gibi ikinci öge açık olarak belirtildiği için açık gelmiştir.&lt;/p&gt;

&lt;h2 id="sonuç"&gt;Sonuç&lt;/h2&gt;

&lt;p&gt;W3C’nin tarayıcıların bünyesindeki bileşenleri arttırma ve geliştirme çabalarını takdir ile karşılıyorum. Her projede ayrı ayrı kod yazmaktan ve uğraşmaktan kurtarıyor, erişebilirlik sorunlarını çözüyor. Standart bir tasarım desteği sunuyor. Umarım bir çok UI kütüphanesindeki bileşenler bu şekilde eklenir.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://open-ui.org/components/accordion.explainer/"&gt;https://open-ui.org/components/accordion.explainer/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.zachleat.com/web/details-utils/"&gt;https://www.zachleat.com/web/details-utils/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://blog.openreplay.com/creating-accordions-with-just-html-and-css/"&gt;https://blog.openreplay.com/creating-accordions-with-just-html-and-css/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/jh3yy/status/1707939551312765206?s=20"&gt;https://x.com/jh3yy/status/1707939551312765206?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details"&gt;https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://web.dev/learn/html/details?hl=en"&gt;https://web.dev/learn/html/details?hl=en&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.scottohara.me/blog/2022/09/12/details-summary.html"&gt;https://www.scottohara.me/blog/2022/09/12/details-summary.html&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://12daysofweb.dev/2021/details-summary/"&gt;https://12daysofweb.dev/2021/details-summary/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/how-to-animate-the-details-element/"&gt;https://css-tricks.com/how-to-animate-the-details-element/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://stackoverflow.com/questions/38213329/how-to-add-css3-transition-with-html5-details-summary-tag-reveal"&gt;https://stackoverflow.com/questions/38213329/how-to-add-css3-transition-with-html5-details-summary-tag-reveal&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://medium.com/@jgustavo.wd/solved-how-to-fully-animate-the-details-html-element-with-only-css-no-javascript-b7d32c53a9d7"&gt;https://medium.com/@jgustavo.wd/solved-how-to-fully-animate-the-details-html-element-with-only-css-no-javascript-b7d32c53a9d7&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/stepfray/pen/LYWYxPM"&gt;https://codepen.io/stepfray/pen/LYWYxPM&lt;/a&gt; animasyon&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/jensimmons/status/1724885940416450810?s=20"&gt;https://x.com/jensimmons/status/1724885940416450810?s=20&lt;/a&gt; Safari desteği de geldi.&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://github.com/atherosai/ui/blob/main/accordion-04/index.html"&gt;https://github.com/atherosai/ui/blob/main/accordion-04/index.html&lt;/a&gt; Örnek akordiyon&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id="mevcut-ui-kütüphanelerinde-akordiyon"&gt;Mevcut UI kütüphanelerinde akordiyon&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://mui.com/material-ui/react-accordion/"&gt;https://mui.com/material-ui/react-accordion/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://getbootstrap.com/docs/5.3/components/accordion/"&gt;https://getbootstrap.com/docs/5.3/components/accordion/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://ant.design/components/collapse"&gt;https://ant.design/components/collapse&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://semantic-ui.com/modules/accordion.html#/definition"&gt;https://semantic-ui.com/modules/accordion.html#/definition&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/html-akordiyon-bileseni/"&gt;HTML Akordiyon bileşeni&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on May 13, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>Avatar Popout Efekti</title><link>https://fatihhayrioglu.com/avatar-popout-efekti/</link><pubDate>Tue, 6 Feb 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/avatar-popout-efekti</guid><description>&lt;p&gt;CSS ile yapılanlar serisinde bu yazımda sizlere bir köşeli veya yuvarlak alan içindeki resmin üzerine gelince köşeli ve yuvarlak alanın dışına taşacak uygulamayı anlatmaya çalışacağım.&lt;/p&gt;

&lt;h2 id="köşeli-alanlarda-popout-efekti"&gt;Köşeli alanlarda popout efekti&lt;/h2&gt;

&lt;iframe height="350" width="100%" style="width: 100%;" scrolling="no" title="pop-up avatar" src="https://codepen.io/fatihhayri/embed/zYbjYxX?default-tab=css%2Cresult&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Bir kapsayıcı &lt;code class="language-plaintext highlighter-rouge"&gt;.kapsayici&lt;/code&gt; içinde yer alan resmi &lt;code class="language-plaintext highlighter-rouge"&gt;position: absolute;&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;bottom: 0;&lt;/code&gt; ile kapsayıcının altına hizalıyoruz. Normal durumda biraz resmi küçültüyoruz. Farenin üzerine geldiğinde resmi büyüttüğümüzde &lt;code class="language-plaintext highlighter-rouge"&gt;transform: scale(1.4);&lt;/code&gt; istediğimiz sonuç ortaya çıktı.&lt;/p&gt;

&lt;h2 id="oval-alanlarda-popout-efekti"&gt;Oval alanlarda popout efekti&lt;/h2&gt;

&lt;iframe height="350" width="100%" style="width: 100%;" scrolling="no" title="pop-up avatar - border-radius" src="https://codepen.io/fatihhayri/embed/QWorWNr?default-tab=css%2Cresult&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Oval alanlarda popout efekti yapmak için köşeliye göre bir fazla kapsayıcı &lt;code class="language-plaintext highlighter-rouge"&gt;.resim-kabi&lt;/code&gt; daha eklememiz gerekiyor. Ovallik kazandırmak için &lt;code class="language-plaintext highlighter-rouge"&gt;.kapsayici&lt;/code&gt; ve  &lt;code class="language-plaintext highlighter-rouge"&gt;.resim-kabi&lt;/code&gt; elemanlarına &lt;code class="language-plaintext highlighter-rouge"&gt;border-radius&lt;/code&gt; tanımladık. Bu örnekte farklı olarak resim ve kapsayıcısını da büyüttük. Ayrıca resme gölge de ekledik.&lt;/p&gt;

&lt;h2 id="tek-elemanla-çözüm"&gt;Tek elemanla çözüm&lt;/h2&gt;

&lt;p&gt;Oval örneğin sadece bir adet HTML elemanı (&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;img&amp;gt;&lt;/code&gt;) ile yapan örnekler de var. &lt;a href="https://css-tricks.com/a-fancy-hover-effect-for-your-avatar/"&gt;https://css-tricks.com/a-fancy-hover-effect-for-your-avatar/&lt;/a&gt;  Temani Afif’in yazısı gayet başarılı.&lt;/p&gt;

&lt;iframe height="350" width="100%" style="width: 100%;" scrolling="no" title="Fancy hover effect on avatar" src="https://codepen.io/t_afif/embed/MWBjraa?default-tab=css%2Cresult&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/t_afif/pen/MWBjraa"&gt;
  Fancy hover effect on avatar&lt;/a&gt; by Temani Afif (&lt;a href="https://codepen.io/t_afif"&gt;@t_afif&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Az eleman kullanması güzel bir avantaj olsa da kodu karışıklığı beni biraz düşündürdü. Siz projenize göre bri tanesini seçip ilerleyebilirsiniz.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/a-fancy-hover-effect-for-your-avatar/"&gt;https://css-tricks.com/a-fancy-hover-effect-for-your-avatar/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.smashingmagazine.com/2023/09/re-creating-pop-out-hover-effect-css-part1/"&gt;https://www.smashingmagazine.com/2023/09/re-creating-pop-out-hover-effect-css-part1/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://youtu.be/1zDRqHifoX0?si=YcEEn2r2EGztObXg"&gt;https://youtu.be/1zDRqHifoX0?si=YcEEn2r2EGztObXg&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://youtu.be/mi-p_q2J8Ek?si=ZR1FIoBwr2LTKuK6"&gt;https://youtu.be/mi-p_q2J8Ek?si=ZR1FIoBwr2LTKuK6&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/dannievinther/pen/yLgMdWO"&gt;https://codepen.io/dannievinther/pen/yLgMdWO&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/sparshgupta007/pen/XWaQoOX"&gt;https://codepen.io/sparshgupta007/pen/XWaQoOX&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/jlevin/pen/eYvgBwy"&gt;https://codepen.io/jlevin/pen/eYvgBwy&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/ainalem/pen/QWGNzYm"&gt;https://codepen.io/ainalem/pen/QWGNzYm&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/t_afif/pen/qBQzrwq"&gt;https://codepen.io/t_afif/pen/qBQzrwq&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/matthewtole/pen/MWQWmGd"&gt;https://codepen.io/matthewtole/pen/MWQWmGd&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/avatar-popout-efekti/"&gt;Avatar Popout Efekti&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on February 06, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>Kapsayıcı sorguları (container query)</title><link>https://fatihhayrioglu.com/kapsayici-sorgulari-container-query/</link><pubDate>Mon, 29 Jan 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/kapsayici-sorgulari-container-query</guid><description>&lt;p&gt;CSS’e gelen yeni özelliklerden birini daha inceleyip sizelere yazmanın sevinci içerisindeyim.  Dilimize kapsayıcı sorguları olarak çevirmeye çalışacağım.&lt;/p&gt;

&lt;p&gt;Bu özelliği duyunca daha önce &lt;a href="https://www.zingat.com/"&gt;zingat’ta&lt;/a&gt; Murat Çorlu ile harita sayfasını kodlarken sağda harita solda haritadaki ilanların listelendiği ilan kartlarının olduğu bir yapıdaki tasarımı HTML’e dökmeye çalıştığımız zaman aklıma geldi. (Yazının ana resmindekine benzer bir sayfa yapısı)  Biz burada sağdaki harita ve yanındaki alanları dinamik olarak değiştirmek istedik. Yeterli alan varsa solda listelenen alanda 3 kolonlu bir yapı, daha az yer olduğunda 2 kolonlu yapı, daha da az yer olduğunda tek kolonlu bir yapı olsun ve en sonunda sadece haritanın kalacağı bir yapı düşündük.&lt;/p&gt;

&lt;p&gt;Bunu medya sorguları ile çözmek mümkün olmadı. Daha sonra bunu yapmak için bir JavaScript çözümü bulsak ta en son sabit bir genişlik ve 2 kolonlu kalsın deyip bırakmıştık. Kapsayıcı sorguların (container queries) çıkacağını ilk duyduğumda bu proje ve orada medya sorgularıyla uğraştığımız zaman aklıma geldi. Bu kadar girizgahtan sonra kapsayıcı sorgularının nasıl çalıştığına değinelim.&lt;/p&gt;

&lt;h2 id="kapsayıcı-sorguları-nasıl-kullanılır"&gt;Kapsayıcı sorguları nasıl kullanılır?&lt;/h2&gt;

&lt;p&gt;Kapsayıcı sorgularının genel teorisine ait tanımlara göz atalım.&lt;/p&gt;

&lt;h3 id="container-type"&gt;container-type&lt;/h3&gt;

&lt;p&gt;En yakın ebeveynine &lt;code class="language-plaintext highlighter-rouge"&gt;container-type&lt;/code&gt;  tanım yaparak başlıyoruz.  Bu tanım ile bu eleman bir kapsayıcı eleman olduğu belirtiliyor. Başlangıç değeri &lt;code class="language-plaintext highlighter-rouge"&gt;normal&lt;/code&gt;‘dir.  Aslında tüm elemanlar birer stil kapsayıcısı (Bir yazıda da bu konuya gireriz) olduğu için &lt;code class="language-plaintext highlighter-rouge"&gt;normal&lt;/code&gt; değeri alır. &lt;code class="language-plaintext highlighter-rouge"&gt;container-type&lt;/code&gt;  tanımı iki adet daha değer alır.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;inline-size&lt;/code&gt;: Metin akış ekseni olarakta tanımlayacağımız satıriçi(inline) eksen tanımıdır. &lt;strong&gt;Genelde bu değer kullanılıyor.&lt;/strong&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;size&lt;/code&gt;: Her iki eksende de kapsayıcının sorgulanabileceğini gösterir. Hem satıriçi hem de blok ekseninde sorgulama yapılmasını sağlar.&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;main&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
	&lt;span class="py"&gt;container-type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;inline-size&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Bu tanımı yaptıktan sonra bu kapsayıcı içindeki elemanlara artık belli genişliğe göre sorgulayıp ona göre kod yazabiliyoruz. Örneğin &lt;code class="language-plaintext highlighter-rouge"&gt;main&lt;/code&gt; içindeki &lt;code class="language-plaintext highlighter-rouge"&gt;.card-container&lt;/code&gt; elemanına &lt;code class="language-plaintext highlighter-rouge"&gt;1200px&lt;/code&gt; genişliğe göre tanım yapalım:&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="k"&gt;@container&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;min-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1200px&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nc"&gt;.card-container&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="py"&gt;grid-template-columns&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id="container-name"&gt;container-name&lt;/h3&gt;

&lt;p&gt;Sayfa içinde birden fazla kapsayıcı tanımı yapıldığında karışmaması için isimlendirme seçeneği de var. İsimlendirme işini &lt;code class="language-plaintext highlighter-rouge"&gt;container-name&lt;/code&gt; tanımı ile yapıyoruz.  Bu tanım tarayıcıların işini kolaylaştırmak için tanımlanmıştır.  Tarayıcı hangi elemana kapsayıcı sorgusu uygulanacağını bilirse işi daha kolay oluyor. Yukarıdaki kodu buna göre güncellersek:&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;main&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;container-type&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;inline-size&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;container-name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;card&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@container&lt;/span&gt; &lt;span class="n"&gt;card&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;min-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1200px&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nc"&gt;.card-container&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="py"&gt;grid-template-columns&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id="container-kısayolu"&gt;container kısayolu&lt;/h3&gt;

&lt;p&gt;Bu iki tanımı birleştiren bir kısayol da vardır. &lt;code class="language-plaintext highlighter-rouge"&gt;container&lt;/code&gt; tanımı bu iki tanımı birleştiren bir kısayoldur.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;main&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;container&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;card&lt;/span&gt; &lt;span class="p"&gt;/&lt;/span&gt; &lt;span class="n"&gt;inline-size&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Sıralama önemli önce isim sonra tip.&lt;/strong&gt;&lt;/p&gt;

&lt;h3 id="kapsayıcı-sorgu-birimleri"&gt;Kapsayıcı Sorgu birimleri&lt;/h3&gt;

&lt;p&gt;Kapsayıcı sorguların terorisine ait son bilgi de kapsayıcı sorgu birimleri&lt;/p&gt;

&lt;p&gt;Kapsayıcı sogrularını kendine ait birimleri vardır. Bu birimler görüş alanı birimlerine viewport (&lt;code class="language-plaintext highlighter-rouge"&gt;vw&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;vh&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;vmin&lt;/code&gt;, vd.) benzerdir. Tabi burada bakış alanına değil de kapsayıcıya göre işlem yapılır.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;1cqw&lt;/code&gt;  -  Sorgusu yapılan kapsayıcı genişliğinin &lt;code class="language-plaintext highlighter-rouge"&gt;1%&lt;/code&gt; ‘ine karşılık gelir.&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;1cqh&lt;/code&gt;  -  Sorgusu yapılan kapsayıcı yüksekliğinin &lt;code class="language-plaintext highlighter-rouge"&gt;1%&lt;/code&gt; ‘ine karşılık gelir.&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;1cqi&lt;/code&gt;  -  Sorgusu yapılan kapsayıcı satıriçi ekseninin &lt;code class="language-plaintext highlighter-rouge"&gt;1%&lt;/code&gt; ‘ine karşılık gelir.&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;1cqb&lt;/code&gt;  -  Sorgusu yapılan kapsayıcı blok ekseninin &lt;code class="language-plaintext highlighter-rouge"&gt;1%&lt;/code&gt; ‘ine karşılık gelir.&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;1cqmin&lt;/code&gt;  - &lt;code class="language-plaintext highlighter-rouge"&gt;cqi&lt;/code&gt;  ve  &lt;code class="language-plaintext highlighter-rouge"&gt;cqb&lt;/code&gt;‘nin en düşük değeri&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;1cqmax&lt;/code&gt;  - &lt;code class="language-plaintext highlighter-rouge"&gt;cqi&lt;/code&gt;  ve  &lt;code class="language-plaintext highlighter-rouge"&gt;cqb&lt;/code&gt;‘nin en büyük değeri&lt;/li&gt;
&lt;/ul&gt;

&lt;h2 id="kapsayıcı-sorgu-örnekleri"&gt;Kapsayıcı sorgu örnekleri&lt;/h2&gt;

&lt;p&gt;Peki zingat’taki ihtiyacımızı bu öğrendiklerimize göre yapmaya çalışalım.&lt;/p&gt;

&lt;iframe height="500" width="100%" style="width: 100%;" scrolling="no" title="container query" src="https://codepen.io/fatihhayri/embed/eYXWrEY?default-tab=result&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/eYXWrEY"&gt;
  container query&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki codepen örneğinde zoom seviyesi ile oynayarak ta etkiyi görebiliriz.&lt;/p&gt;

&lt;p&gt;Mobile öncelik verdiğimiz için diğer şartlar için kod yazdık.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nc"&gt;.card-container&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;grid-template-columns&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@container&lt;/span&gt; &lt;span class="n"&gt;card&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;min-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1200px&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nc"&gt;.card-container&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="py"&gt;grid-template-columns&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;@container&lt;/span&gt; &lt;span class="n"&gt;card&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;min-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1700px&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nc"&gt;.card-container&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="py"&gt;grid-template-columns&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="n"&gt;fr&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Mükemmel. Mükemmel. Mükemmel.&lt;/p&gt;

&lt;h2 id="bileşen-yapısına-geçiş"&gt;Bileşen yapısına geçiş&lt;/h2&gt;

&lt;p&gt;Kapsayıcı sorguları genelde yukarıdaki yapıda kullanmak için düşünülüyor ancak youtube’da &lt;a href="https://www.youtube.com/watch?v=A2dMca3WrJE"&gt;Maarten Van Hoof&lt;/a&gt; yaklaşımını görene kadar.&lt;/p&gt;

&lt;p&gt;Web dünyasında son zamanların popüler kullanımı olan bileşen yapılarını birçoğumuz kullanıyoruz. Kapsayıcı sorgularıyla bu konunun ne alakası var derseniz. Farklı ekipler için geliştirdiğimiz bir bileşeni düşünelim. Örneklere kart yapısından başladığımız için yine bir kart bileşeni kodluyoruz. Bu bileşeni sayfa içinde, sağ kolonda ve detay durumlarının olduğunu düşünelim. Büyük projelerde bu tip işler büyük sorun oluyor. Kapsayıcı sorguları bu sorunu da çözüyor.&lt;/p&gt;

&lt;p&gt;Max Böck’ün codepen.io örneği bu konuyu ve tanımları anlamak için mükemmel bence. 3 kolonlu bir yapı var. Solda öne çıkan kitap, ortada en çok satan kitaplar listesi ve sağda da alışveriş sepeti var. Bu ögeleri tutup taşıyabiliyoruz.&lt;/p&gt;

&lt;iframe height="610" width="100%" style="width: 100%;" scrolling="no" title="Container Query Bookstore" src="https://codepen.io/mxbck/embed/XWMrMOp?default-tab=result&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/mxbck/pen/XWMrMOp"&gt;
  Container Query Bookstore&lt;/a&gt; by Max Böck (&lt;a href="https://codepen.io/mxbck"&gt;@mxbck&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki kart bileşeni 3 yerde kullanılıyor. Herbiri için ayrı ayrı tanım yapıp kodlamak yerine kapsayıcı sorguları ile çözebilmek bileşen yapılı sistemlerde mükemmel bir şey.&lt;/p&gt;

&lt;h2 id="geliştirici-araçlarındaki-görünüm"&gt;Geliştirici araçlarındaki görünüm&lt;/h2&gt;

&lt;p&gt;Chrome ve Firefox’da aşağıdaki gibi bir etiketleme var. Safari’de göremedim.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/container-query-devtools.png" alt="dev tools container query" /&gt;&lt;/p&gt;

&lt;h2 id="tarayıcı-desteği"&gt;Tarayıcı desteği&lt;/h2&gt;

&lt;p&gt;Popüler ve çok kullanılan tarayıcıların desteği var.  Bu yazıyı yazdığımda Türkiye’deki destek oranı %94.7 olarak görünüyordu.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://ishadeed.com/article/container-queries-are-finally-here/"&gt;https://ishadeed.com/article/container-queries-are-finally-here/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=gCNMyYr7F6w"&gt;https://www.youtube.com/watch?v=gCNMyYr7F6w&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://webkit.org/blog/12824/news-from-wwdc-webkit-features-in-safari-16-beta/"&gt;https://webkit.org/blog/12824/news-from-wwdc-webkit-features-in-safari-16-beta/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.apple.com/videos/play/wwdc2022/10048/"&gt;https://developer.apple.com/videos/play/wwdc2022/10048/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.oddbird.net/2021/04/05/containerqueries/"&gt;https://www.oddbird.net/2021/04/05/containerqueries/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=zVR1WBGWVT8"&gt;https://www.youtube.com/watch?v=zVR1WBGWVT8&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.sarasoueidan.com/blog/component-level-art-direction-with-container-queries-and-picture/"&gt;https://www.sarasoueidan.com/blog/component-level-art-direction-with-container-queries-and-picture/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://mxb.dev/blog/container-queries-web-components/"&gt;https://mxb.dev/blog/container-queries-web-components/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://piccalil.li/blog/container-queries-are-actually-coming/"&gt;https://piccalil.li/blog/container-queries-are-actually-coming/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=A2dMca3WrJE"&gt;https://www.youtube.com/watch?v=A2dMca3WrJE&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_container_queries"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_container_queries&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.smashingmagazine.com/2021/05/complete-guide-css-container-queries/"&gt;https://www.smashingmagazine.com/2021/05/complete-guide-css-container-queries/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://blog.logrocket.com/css-container-queries-guide/"&gt;https://blog.logrocket.com/css-container-queries-guide/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://caniuse.com/css-container-queries"&gt;https://caniuse.com/css-container-queries&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://web.dev/blog/cq-stable?hl=en"&gt;https://web.dev/blog/cq-stable?hl=en&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://medium.com/kodcular/css-container-sorgular%C4%B1-50f1163fb23d"&gt;https://medium.com/kodcular/css-container-sorgular%C4%B1-50f1163fb23d&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.chrome.com/docs/devtools/css/container-queries?hl=en"&gt;https://developer.chrome.com/docs/devtools/css/container-queries?hl=en&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.learnwithjason.dev/demystifying-css-container-queries/"&gt;https://www.learnwithjason.dev/demystifying-css-container-queries/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/jh3yy/status/1734300848547627030?s=20"&gt;https://x.com/jh3yy/status/1734300848547627030?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/chriscoyier/status/1650636630401662980?s=20"&gt;https://x.com/chriscoyier/status/1650636630401662980?s=20&lt;/a&gt; Takvim örneği&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://moderncss.dev/container-query-units-and-fluid-typography/?utm_source=pocket_reader"&gt;https://moderncss.dev/container-query-units-and-fluid-typography/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/Robby_WebDesign/status/1622339281598676993?s=20"&gt;https://x.com/Robby_WebDesign/status/1622339281598676993?s=20&lt;/a&gt; pagination örneği&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/kevinpowell/pen/RwvWoLg"&gt;https://codepen.io/kevinpowell/pen/RwvWoLg&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/ChromiumDev/status/1742727550579691789?s=20"&gt;https://x.com/ChromiumDev/status/1742727550579691789?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/collection/XQrgJo?cursor=eyJwYWdlIjozfQ=="&gt;https://codepen.io/collection/XQrgJo?cursor=eyJwYWdlIjozfQ==&lt;/a&gt; Miriam’s CodePen collection&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/FrontendHorse/status/1412060617398177794?s=20"&gt;https://x.com/FrontendHorse/status/1412060617398177794?s=20&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/kapsayici-sorgulari-container-query/"&gt;Kapsayıcı sorguları (container query)&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on January 29, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>Renk geçişli ve Hareketli kenar çizgileri</title><link>https://fatihhayrioglu.com/renk-gecisli-ve-hareketli-kenar-cizgileri/</link><pubDate>Mon, 22 Jan 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/renk-gecisli-ve-hareketli-kenar-cizgileri</guid><description>&lt;p&gt;İnternette gezerken gördüğüm kodu basit etkisi büyük örnekleri paylaşma yazılarıma devam ediyorum. Herhangi bir elemanın kenar çizgilerini birden fazla renk tanımlamak ve üstüne bunu hareketli yapma örneklerini çok gördüm. Bu yazıda bunu anlatmaya çalışacağım.&lt;/p&gt;

&lt;h2 id="doğrusal-renk-geçişi-örneği"&gt;Doğrusal renk geçişi örneği&lt;/h2&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="Animated gradient border" src="https://codepen.io/fatihhayri/embed/gOEmREo?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;&lt;/iframe&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;border-image&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt; &lt;span class="nt"&gt;linear-gradient&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="nt"&gt;to&lt;/span&gt; &lt;span class="nt"&gt;bottom&lt;/span&gt; &lt;span class="nt"&gt;right&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;&lt;span class="nf"&gt;#ffb56b&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;&lt;span class="nf"&gt;#ac255e&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;1&lt;/span&gt;&lt;span class="o"&gt;;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;border-image&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;linear-gradient&lt;/code&gt; birlikte kullanımı ile çözümü hemen bulduk. Mükemmel. Tabi uygulamada kenar çizgilerini bu kadar büyük kullanmayız muhtemelen. Örneğin daha öne çıkması için kenar çizgi kalınlığını yüksek tuttum.&lt;/p&gt;

&lt;h2 id="konik-renk-geçişi-örneği"&gt;Konik renk geçişi örneği&lt;/h2&gt;

&lt;iframe height="500" style="width: 100%;" scrolling="no" title="Animated gradient border" src="https://codepen.io/fatihhayri/embed/WNmpEge?default-tab=Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;&lt;/iframe&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;conic-gradient&lt;/code&gt; ile daha farklı seçenekler görmek mümkün.&lt;/p&gt;

&lt;h2 id="hareketli-renk-geçişi-örneği"&gt;Hareketli renk geçişi örneği&lt;/h2&gt;

&lt;iframe height="500" style="width: 100%;" scrolling="no" title="Animated gradient border -3" src="https://codepen.io/fatihhayri/embed/oNVZeaq?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;&lt;/iframe&gt;

&lt;p&gt;İşe hareket katmakta kolay. &lt;code class="language-plaintext highlighter-rouge"&gt;linear-gradient&lt;/code&gt; tanımındaki yön tanımını açılı verip bu açıyı animasyon ile döndürdüğümüzde işte animayonlu kenar çizgisi. Tabi burada dikkat açı tanımının &lt;code class="language-plaintext highlighter-rouge"&gt;@property&lt;/code&gt; tanımını da yapmalıyız.&lt;/p&gt;

&lt;h2 id="köşeleri-oval-renk-geçiş-örneği"&gt;Köşeleri oval renk geçiş örneği&lt;/h2&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;border-image&lt;/code&gt; ile &lt;code class="language-plaintext highlighter-rouge"&gt;border-radius&lt;/code&gt; birlikte çalışmasının sorunları var. Birçok örnek sorunu çözmek için &lt;code class="language-plaintext highlighter-rouge"&gt;:before&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;mask&lt;/code&gt; ile sonuca gitmiş. Ancak &lt;code class="language-plaintext highlighter-rouge"&gt;background&lt;/code&gt;‘a renk geçişi ekleyip &lt;code class="language-plaintext highlighter-rouge"&gt;box-shadow: inset&lt;/code&gt;  ile içini beyaz (istediğiniz renk)  ile dolduruyoruz. Son olarakta kenar çizgilerinin görünmesi için saydam olarak tanımladık.&lt;/p&gt;

&lt;iframe height="400" style="width: 100%;" scrolling="no" title="Animated gradient border" src="https://codepen.io/fatihhayri/embed/YzgZQmx?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;&lt;/iframe&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://www.bram.us/2021/01/29/animating-a-css-gradient-border/"&gt;https://www.bram.us/2021/01/29/animating-a-css-gradient-border/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://stackoverflow.com/a/76297213/296373"&gt;https://stackoverflow.com/a/76297213/296373&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/andiicodes/status/1621181175577411588?s=20"&gt;https://x.com/andiicodes/status/1621181175577411588?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/tejinder_id/status/1536955048806080512?s=20"&gt;https://x.com/tejinder_id/status/1536955048806080512?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/argyleink/status/1470763758972653571?s=20"&gt;https://x.com/argyleink/status/1470763758972653571?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/codewithshripal/status/1572177594291830784?s=20"&gt;https://x.com/codewithshripal/status/1572177594291830784?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/seyedi/pen/OJdEVXZ"&gt;https://codepen.io/seyedi/pen/OJdEVXZ&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/renk-gecisli-ve-hareketli-kenar-cizgileri/"&gt;Renk geçişli ve Hareketli kenar çizgileri&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on January 22, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>Switch elementi geliyor</title><link>https://fatihhayrioglu.com/switch-elmeneti-geliyor/</link><pubDate>Tue, 16 Jan 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/switch-elmeneti-geliyor</guid><description>&lt;p&gt;Safari yeni sürümlerinde switch elementini destekleyeceğini açıklayınca nasıl birşey diye bakayım dedim. Son zamanlarda UI elementlerinin HTML’e kazandırılması kervanına Webkit’in de  katılması açısında önemli bir durum.&lt;/p&gt;

&lt;p&gt;İlk denemem&lt;/p&gt;

&lt;div class="language-html highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;&amp;lt;input&lt;/span&gt; &lt;span class="na"&gt;type=&lt;/span&gt;&lt;span class="s"&gt;"checkbox"&lt;/span&gt; &lt;span class="na"&gt;switch&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Sonuç mükemmel. Bu gelişmeleri görünce “Senelerdir niye uğraştırdınız be insafsızlar diye” içimden geçirmiyor değilim :)&lt;/p&gt;

&lt;p&gt;Şimdilik sadece &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; ile aktif durumun arka plan rengini değiştirebiliyoruz.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;input&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;accent-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--primary-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/swicth-1.webp" alt="Switch" /&gt;&lt;/p&gt;

&lt;p&gt;Şu an Safari’nin gelecek sürümlerinde desteklenecek bu özelliği umarım yakında diğer tarayıcılarda destekler.&lt;/p&gt;

&lt;p&gt;Safari henüz &lt;code class="language-plaintext highlighter-rouge"&gt;::track&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;::thumb&lt;/code&gt; sözde elementlerinin desteği henüz yok açmak için Develop &amp;gt; Feature Flags - &lt;strong&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;::thumb&lt;/code&gt;  and  &lt;code class="language-plaintext highlighter-rouge"&gt;::track&lt;/code&gt;  pseudo-elements&lt;/strong&gt; açmak gerekiyor. Muhtemelen daha sonraki sürümlerde gelecektir.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;input&lt;/span&gt;&lt;span class="nd"&gt;::thumb&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--primary-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;36px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;36px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;4px&lt;/span&gt; &lt;span class="m"&gt;8px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;transition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;all&lt;/span&gt; &lt;span class="m"&gt;0.3s&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;input&lt;/span&gt;&lt;span class="nd"&gt;:checked::thumb&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;translate&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;40px&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;white&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;  
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/swicth-2.gif" alt="Swicth" /&gt;&lt;/p&gt;

&lt;p&gt;Geçenlerde &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt;örneğinde kullandığım gece/gündüz switch’ini biraz daha değiştirip &lt;code class="language-plaintext highlighter-rouge"&gt;:before&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;:after&lt;/code&gt; olmadan çözümü:&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;input&lt;/span&gt;&lt;span class="nd"&gt;:checked::track&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#000839&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nt"&gt;input&lt;/span&gt;&lt;span class="nd"&gt;:checked::thumb&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;translate&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;40px&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#000839&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;rotate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;110deg&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;inset&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt; &lt;span class="m"&gt;8px&lt;/span&gt; &lt;span class="no"&gt;white&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/swicth-3.gif" alt="Swicth" /&gt;&lt;/p&gt;

&lt;p&gt;Farklı örnek çalışmaları incelemek için &lt;a href="https://nt1m.github.io/html-switch-demos/"&gt;buradaki&lt;/a&gt;  örneklere bakmanızı öneririm. (not: Tarayıcının zoom değerini arttırınca örneklerin görünümü daha hoş oluyor)&lt;/p&gt;

&lt;p&gt;Biliyorum daha çok erken ama araştırmışken paylaşmak istedim. :)&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://x.com/stefanjudis/status/1746236013607833657?s=20"&gt;https://x.com/stefanjudis/status/1746236013607833657?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://github.com/whatwg/html/issues/4180"&gt;https://github.com/whatwg/html/issues/4180&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/yisibl/status/1737739579418141116?s=20"&gt;https://x.com/yisibl/status/1737739579418141116?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/wesbos/status/1737916464571560445?s=20"&gt;https://x.com/wesbos/status/1737916464571560445?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/fatihhayri/pen/BabpzWr"&gt;https://codepen.io/fatihhayri/pen/BabpzWr&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/fatihhayri/pen/KKEagvV"&gt;https://codepen.io/fatihhayri/pen/KKEagvV&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/fatihhayri/pen/gOEgwzJ"&gt;https://codepen.io/fatihhayri/pen/gOEgwzJ&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/switch-elmeneti-geliyor/"&gt;Switch elementi geliyor&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on January 16, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>2023 nasıl geçti? 2024'den hedeflerim</title><link>https://fatihhayrioglu.com/2023-nasil-gecti-2024-den-hedeflerim/</link><pubDate>Mon, 8 Jan 2024 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/2023-nasil-gecti-2024-den-hedeflerim</guid><description>&lt;p&gt;2023 senesinde genelde CSS’in yeni çıkan özelliklerini olabildiğince anlatmaya çalıştım.&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-tip-tan%C4%B1m%C4%B1-property/" title="CSS ile tip tanımı @property"&gt;CSS ile tip tanımı @property&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/marker-sozde-pseudo-elemani/" title="::marker sözde (pseudo) elemanı"&gt;::marker sözde (pseudo) elemanı&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/accent-color/" title="accent-color tanımı"&gt;accent-color tanımı&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/css-scroll-snap/" title="CSS scroll-snap"&gt;CSS scroll-snap&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/user-invalid-secicisi/" title=":user-invalid seçicisi"&gt;:user-invalid seçicisi&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/yeni-bakis-alani-viewport-degerleri/" title="Yeni bakış alanı(viewport) değerleri"&gt;Yeni bakış alanı(viewport) değerleri&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/medya-sorgularinda-aralikli-genislik-tanimlama/" title="Medya sorgularında aralıklı genişlik tanımlama"&gt;Medya sorgularında aralıklı genişlik tanımlama&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/css-subgrid/" title="CSS subgrid"&gt;CSS subgrid&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/text-wrap-balanceve-text-wrap-pretty/" title="Yeni text-wrap değerleri balance ve pretty"&gt;Yeni text-wrap değerleri balance ve pretty&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/css-secicilerin-aranan-ebeveyni-bulundu-has/" title="CSS seçicilerin aranan ebeveyni bulundu :has()"&gt;CSS seçicilerin aranan ebeveyni bulundu :has()&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/sass-in-sonu-geldi-mi/" title="SASS'ın sonu geldi mi?"&gt;SASS’ın sonu geldi mi?&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/css-ic-ice-nesting-yazim/" title="CSS iç içe (nesting) yazım"&gt;CSS iç içe (nesting) yazım&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/css-aspect-ratio-tanimi/" title="CSS aspect-ratio tanımı"&gt;CSS aspect-ratio tanımı&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;HTML’in yeni bileşenleri hakkında da yenilikleri paylaşmak gibi bir hedefim vardı ancak bu konuda eksik kaldım.&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/popover-kullanimi/" title="Popover API"&gt;Popover API&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Sadece Popover bileşinini yazmışım. Bu sene daha fazla bileşen eklerim inşallah.&lt;/p&gt;

&lt;h2 id="2024-hedeflerim"&gt;2024 hedeflerim&lt;/h2&gt;

&lt;p&gt;2024’de daha çok CSS, HTML, PWA ve CSS ile yapılan basit işler hakkında birşeyler yazma planım var.&lt;/p&gt;

&lt;h3 id="css"&gt;CSS&lt;/h3&gt;

&lt;p&gt;Bu sene CSS’in yeni özellikleri hakkındaki yazılara devam etme hedefim var.&lt;/p&gt;

&lt;p&gt;Bunların dışında CSS ile yapılan basit işlerle alakalı yazılara da devam etmeyi düşünüyorum.&lt;/p&gt;

&lt;p&gt;CSS’de ki gelişmelerinin devam edeceğini düşünüyorum. 2024 interrop’da hangileri dahil edilir bilemiyorum ama aşağıdaki birçok özelliğin sene sonuda kalmadan standartlaşmasını bekliyorum.&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;Container Query&lt;/li&gt;
  &lt;li&gt;linear() tanımı&lt;/li&gt;
  &lt;li&gt;Cascade layer&lt;/li&gt;
  &lt;li&gt;Yeni renk tanımları lch, oklab, oklch&lt;/li&gt;
  &lt;li&gt;Logical properties&lt;/li&gt;
  &lt;li&gt;CSS Scope&lt;/li&gt;
  &lt;li&gt;Grid masonary&lt;/li&gt;
  &lt;li&gt;Scroll-timeline&lt;/li&gt;
  &lt;li&gt;Stil Query&lt;/li&gt;
  &lt;li&gt;Anchor positioning&lt;/li&gt;
  &lt;li&gt;View Transitions&lt;/li&gt;
  &lt;li&gt;@when else&lt;/li&gt;
  &lt;li&gt;Trigonometrik fonksiyonlar&lt;/li&gt;
&lt;/ol&gt;

&lt;h3 id="html"&gt;HTML&lt;/h3&gt;

&lt;p&gt;HTML bileşenleri konusunda bir atılım bekliyorum. Bu sayede farklı UI kütüphaneleri yerine UI ihtiyacımızı görebilecek standartlar olacak. Burada kritik nokta bence &lt;strong&gt;CSS ile yeterli derecede stillendirilebilir bileşenler&lt;/strong&gt; olursa iş görür yoksa &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;select&amp;gt;&lt;/code&gt; gibi beklenenin altında bir deneyimle kalır.&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/dialog-elementi/" title="dialog elementi"&gt;dialog elementi&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/progress-elementini-stillendirelim/" title="progress elementini stillendirelim"&gt;progress elementini stillendirelim&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/popover-kullanimi/" title="Popover API"&gt;Popover API&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;Akordiyon&lt;/li&gt;
  &lt;li&gt;Slider&lt;/li&gt;
  &lt;li&gt;Selectlist&lt;/li&gt;
  &lt;li&gt;Switch&lt;/li&gt;
  &lt;li&gt;Drawer&lt;/li&gt;
  &lt;li&gt;&lt;em&gt;Data table&lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;Tooltip&lt;/li&gt;
  &lt;li&gt;Date picker&lt;/li&gt;
  &lt;li&gt;Form Validation&lt;/li&gt;
  &lt;li&gt;&lt;em&gt;Tabs&lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;&lt;em&gt;Carousel&lt;/em&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Çoğu beklenti ama umarım böyle bir liste çıkar sene sonu. :)&lt;/p&gt;

&lt;h3 id="pwa"&gt;PWA&lt;/h3&gt;

&lt;p&gt;Safari’ye push notification desteği gelmesiyle geçen sene PWA alanında ciddi bir atılım bekliyordum ancak gözle görülür bir sıçrama olmadı. Nasip diyelim. PWA’i birçok konuda avatajlı görmeme rağmen sektör bu konuda benimle aynı düşünmüyor galiba.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Tek kod bloku&lt;/strong&gt;: Mevcut sitelerde mobil için iki ayrı (iOS, Android) geliştirme ortamı var. Ayrıca hala Türkiye’de responsive olmayan birçok siteden dolayı web ve mobil web var. Bu 4 farklı ortam yerine tek ortamda işlerimizi halledebileceğimiz bir sistem var ve kimse kullanmıyor :)&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Tek platform öğrenme ihtiyacı:&lt;/strong&gt; Mobilde mevcut şartlarda Android için farklı iOS için farklı bir öğrenme eğrisi var. Bunun için React Native ve Flutter gibi çözümler olsa da hala birçok şirket native olanları tercih ediyor. PWA’in tüm bunlardan daha iyi bir çözümü var. Sadece HTML, CSS ve Javascript ile tüm her yerde çalışan siteler / uygulamalar yapma imkanı.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;SEO&lt;/strong&gt;: Mobil uygulamalrın arama motoru konusundaki sıkıntıları malum. PWA arama motorları konusunda olmazsa olmaz.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Güncelleme kolaylığı:&lt;/strong&gt; Mobil uygulamaların Web marketlerinde güncellemenin  zorluğunu bilenler bu konuda PWA’nin ne kadar büyük bir nimet olduğunu anlar.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Erişilebilirlik:&lt;/strong&gt; Bu konuda mevcut sitelerinde eksikleri olsa da PWA’nın erişilebilirlik çözümlerinin daha çok ve kolay olduğunu kabul etmeliyiz.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Eski araçlarda çalışma:&lt;/strong&gt; Düşük kalitedeki araçlarda dahi çalışma imkanı sağlamasıyla mobil uygulamalara göre avantajı vardır.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Hız:&lt;/strong&gt; Web tekonolojileri hız konusunda daha fazla araç sunmaktadır. Hız ölçümü ve geliştirmesi daha kolay. Ön bellek yönetimi ve lazy load yöntemleri daha uzun süre  tecrübe edilmiştir. Örneğin &lt;a href="https://www.orange.pl/"&gt;Orange Polska S.A.&lt;/a&gt;‘nın verilerine göre %30 daha hızlıymış.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Daha güvenli:&lt;/strong&gt; Web’in süregelen güvenlik araçları nedeniyle native uygulamalara göre avantajlıdır. HTTPS seçeneği ile güvenli siteler/uygulamalar yapma imkanı sağlar.&lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;&lt;strong&gt;Daha az maliyetli:&lt;/strong&gt; Geliştirme ve idame ettirme maliyetleri daha düşüktür.&lt;/p&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Eksi olarak yazabileceğimiz iki konu var mobil cihazlarda cihaz özelliklerine erişim sıkıntılı ve animasyon. Animasyon konusunda kesin çözüm geldi diyebilirim. &lt;a href="https://developer.mozilla.org/en-US/docs/Web/API/View_Transitions_API"&gt;View Transitions API&lt;/a&gt; bence mobil uygulamardaki animasyonu aratmayan tecrübe sunuyor. Apple’ıın yani Safari’nin iOS cihazlardaki cihaz özelliklerine erişim konusunda son yıllarda ki atağı da o eksiğinde yakında giderileceği konusunda ümitlendiriyor bizi. Ne diyelim umarım bu sefer “Bu sene PWA’nın yılı” dedirtiriz. :)&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://survey.devographics.com/en-US/survey/state-of-html/2023"&gt;https://survey.devographics.com/en-US/survey/state-of-html/2023&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://medium.com/@julianneagu/progressive-web-app-pwa-statistics-2023-46950788b513"&gt;https://medium.com/@julianneagu/progressive-web-app-pwa-statistics-2023-46950788b513&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://web.dev/case-studies/orange?hl=en"&gt;https://web.dev/case-studies/orange?hl=en&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/2023-nasil-gecti-2024-den-hedeflerim/"&gt;2023 nasıl geçti? 2024'den hedeflerim&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on January 08, 2024.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>NVM kullanarak varsayılan nodejs sürmünü değiştirme</title><link>https://fatihhayrioglu.com/nvm-kullanarak-varsayilan-node-surmunu-degistirme/</link><pubDate>Fri, 29 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/nvm-kullanarak-varsayilan-node-surmunu-degistirme</guid><description>&lt;p&gt;Farklı projelerde çalışırken her projenin node sürüm ihtiyacı farklı ise bunlarla baş etmek için &lt;a href="https://fatihhayrioglu.com/nvm-nedir-nasil-kullanilir/"&gt;nvm kullanmaya&lt;/a&gt; başlamıştım. Ancak bazı durumlarda node sürümünü devamlı değiştirmek sorun oluyor. Varsayılan node sürümünü güncellemek gerektiğinde bu konuda NVM bize kolay bir yöntem sunuyor.&lt;/p&gt;

&lt;p&gt;İlk önce mevcut node sürmünü öğrenelim ve sonra sistemde yüklü &lt;code class="language-plaintext highlighter-rouge"&gt;nodejs&lt;/code&gt; sürümlerini &lt;code class="language-plaintext highlighter-rouge"&gt;nvm&lt;/code&gt; ile kontrol edelim.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/nvm-node-1.png" alt="node version" /&gt;&lt;/p&gt;

&lt;p&gt;Mevcut durumda &lt;code class="language-plaintext highlighter-rouge"&gt;nodejs&lt;/code&gt; sürmümüz &lt;code class="language-plaintext highlighter-rouge"&gt;v12.22.12&lt;/code&gt; olarak görünüyor. Yukarıdaki listede istediğiniz sürüm yok ise &lt;code class="language-plaintext highlighter-rouge"&gt;nvm&lt;/code&gt; ile hemen istediğiniz sürümü yükleyebilirsiniz. &lt;code class="language-plaintext highlighter-rouge"&gt;nvm install 19.5.0&lt;/code&gt; gibi. Şimdi gelelim varsayılan &lt;code class="language-plaintext highlighter-rouge"&gt;nodejs&lt;/code&gt; sürümünü ayarlamaya&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/nvm-node-2.png" alt="nvm default node" /&gt;&lt;/p&gt;

&lt;p&gt;Evet varsayılan sürmümüz artık 19.5.0. &lt;code class="language-plaintext highlighter-rouge"&gt;node -v&lt;/code&gt; ile kontrol edebiliriz. Bazen hemen olmuyor terminali açıp kapamak gerekiyor.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://fatihhayrioglu.com/nvm-nedir-nasil-kullanilir/" title="NVM Nedir? Nasıl Kullanılır?"&gt;NVM Nedir? Nasıl Kullanılır?&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://stackoverflow.com/a/47787025/296373"&gt;https://stackoverflow.com/a/47787025/296373&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://tiloid.com/p/setting-the-default-node-version-using-nvm"&gt;https://tiloid.com/p/setting-the-default-node-version-using-nvm&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;


  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/nvm-kullanarak-varsayilan-node-surmunu-degistirme/"&gt;NVM kullanarak varsayılan nodejs sürmünü değiştirme&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 29, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS ile hareketli renk geçişli arka planı yapmak</title><link>https://fatihhayrioglu.com/css-ile-hareketli-renk-gecisli-arka-plan-yapmak/</link><pubDate>Thu, 28 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-ile-hareketli-renk-gecisli-arka-plan-yapmak</guid><description>&lt;p&gt;Web’de gördüğüm CSS ile yapılmış bazı uygulamarı burada paylaşmak istiyorum. Bunlardan birisi de renk geçişi ile yapılmış hareketli arka plan resimleri. Kodu çok basit ama etkisi çok iyi. Bundan 10 sene önce bu işi yapsak muhtemlen tarayıcılar çok zorlanacağı işleri artık CSS ile çok basit bir şekilde yapabilmek güzel.&lt;/p&gt;

&lt;p&gt;Konuyu daha da uzatmadan koda gelelim. &lt;a href="https://fatihhayrioglu.com/css-renk-gecisleri-gradients/"&gt;CSS ile renk geçişi&lt;/a&gt; yapmak çok basit. En basit hali&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;linear-gradient&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="nt"&gt;top&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;&lt;span class="nf"&gt;#fff&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;&lt;span class="nf"&gt;#f8b500&lt;/span&gt;&lt;span class="o"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;İki renk arasında başlangıç noktasını verdiğimiz bir tanım. Kodu daha da geliştirip açılı ve çok renkli renk geçişleri de yapabiliyoruz.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;linear-gradient&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="nt"&gt;-45deg&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;3&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;03&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;04&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;54&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;08&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;13&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;82&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;13&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;08&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;25&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;11&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;13&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;38&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;3&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;03&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;04&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;50&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;54&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;08&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;62&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;82&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;13&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;08&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;75&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;11&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;13&lt;/span&gt; &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;87&lt;/span&gt;&lt;span class="o"&gt;%,&lt;/span&gt; &lt;span class="nt"&gt;oklab&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;3&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;03&lt;/span&gt; &lt;span class="nt"&gt;-0&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="err"&gt;04&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="err"&gt;100&lt;/span&gt;&lt;span class="o"&gt;%);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Güzel bir arkaplan geçişi elde ettik. Peki bunu nasıl hareketlendireceğiz?&lt;/p&gt;

&lt;p&gt;4 renk seçtiğimiz için arka plan alanını genişletmemiz lazım. &lt;code class="language-plaintext highlighter-rouge"&gt;background-size: 400% 400%;&lt;/code&gt; ile genişlettik. Sıra geldi bu arka plana hareket kazandırmaya. Hareket kazandırmak içinde arka plan konumunu değiştirmemiz yeterli olacak.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="k"&gt;@keyframes&lt;/span&gt; &lt;span class="n"&gt;arkaPlanaHareketKat&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="err"&gt;0&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="err"&gt;50&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="err"&gt;100&lt;/span&gt;&lt;span class="o"&gt;%&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;background-position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt; &lt;span class="m"&gt;50%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;Sonuç aşağıdaki gibi olacaktır.&lt;/p&gt;

&lt;iframe height="350.08203125" style="width: 100%;" scrolling="no" title="Animated Background" src="https://codepen.io/fatihhayri/embed/NWJPpeK?default-tab=css%2Cresult&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Farklı alanlarda bu tekniği uygulayabiliriz. Bu örnekte olduğu gibi sayfanın tümünün arka planında kullandığımız gibi bir butonun arka planında da kullanabiliriz.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/ahmedriad1/pen/BaamKgv"&gt;https://codepen.io/ahmedriad1/pen/BaamKgv&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://weekendprojects.dev/posts/creating-a-gradient-animation-with-css/"&gt;https://weekendprojects.dev/posts/creating-a-gradient-animation-with-css/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://youtu.be/u2j9Ke6CCcg?si=6hGBjnTUU15rES35"&gt;https://youtu.be/u2j9Ke6CCcg?si=6hGBjnTUU15rES35&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/kentaro_au/pen/KKZxeVE?editors=1100"&gt;https://codepen.io/kentaro_au/pen/KKZxeVE?editors=1100&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/TWilson/pen/jOdWqbZ"&gt;https://codepen.io/TWilson/pen/jOdWqbZ&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/uixmat/pen/XWovXvg"&gt;https://codepen.io/uixmat/pen/XWovXvg&lt;/a&gt; (güzel bg)&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/chaseottofy/pen/BaGqJKK"&gt;https://codepen.io/chaseottofy/pen/BaGqJKK&lt;/a&gt; (gradient üretme aracı)&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/13twelve/pen/OJwgxOo?editors=1100"&gt;https://codepen.io/13twelve/pen/OJwgxOo?editors=1100&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-hareketli-renk-gecisli-arka-plan-yapmak/"&gt;CSS ile hareketli renk geçişli arka planı yapmak&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 28, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS ile tip tanımı @property</title><link>https://fatihhayrioglu.com/css-ile-tip-tan%C4%B1m%C4%B1-property/</link><pubDate>Mon, 25 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-ile-tip-tanımı-property</guid><description>&lt;p&gt;@property nedir? CSS’in yeni bir özelliği mi? Aslında yeni bir CSS tanımı ve özelliği değil. @property geliştiriciler olarak bizim hiç dahil omadığımız alanlara girmemize izin verilen bir tanım daha doğrusu &lt;a href="https://developer.mozilla.org/en-US/docs/Web/Guide/Houdini"&gt;CSS Houdini&lt;/a&gt;‘nin bir parçasıdır.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;CSS Houdini, Tarayıcı API’leri koleksiyonu için bir çatı terim olan Houdini, web geliştirme sürecine ve genel olarak CSS standartlarının geliştirilmesine önemli iyileştirmeler getirmeyi amaçlamaktadır. Front-end geliştiricileri, JavaScript kullanarak CSS’i yeni özelliklerle genişletebilecek, CSS oluşturma motoruna bağlanabilecek ve tarayıcıya bir oluşturma işlemi sırasında CSS’i nasıl uygulayacağını söyleyebilecek. Houdini’nin tarayıcı desteği gelişiyor ve bazı API’ler bugün kullanıma hazır.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Kısaca, tarayıcı geliştiricilerin biz web geliştiricilere gelin birazda siz geliştirin diye açtığı kapıdır CSS Houdini. @property’de CSS Houdini’nin bir parçasıdır. Parçanın parçası, evet çok fazla parça oldu :)&lt;/p&gt;

&lt;p&gt;@property, biz geliştiricilere  &lt;a href="https://fatihhayrioglu.com/css-degiskenleri-custom-properties/" title="CSS Değişkenleri (Custom Properties)"&gt;CSS değişkenleri (Custom Properties)&lt;/a&gt;‘nin tipini, başlangıç değerini ve kalıtsallığını tarayıcıya bildirmemize olanak sağlar.&lt;/p&gt;

&lt;p&gt;Genel yapısı:&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="k"&gt;@property&lt;/span&gt;  &lt;span class="n"&gt;--anaRenk&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;syntax&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;'&amp;lt;color&amp;gt;'&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;initial-value&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;blue&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;inherits&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;Söz dizimi(syntax) &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;length&amp;gt;, &amp;lt;number&amp;gt;, &amp;lt;percentage&amp;gt;, &amp;lt;length-percentage&amp;gt;,&lt;/code&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;color&amp;gt;, &amp;lt;image&amp;gt;, &amp;lt;url&amp;gt;, &amp;lt;integer&amp;gt;, &amp;lt;angle&amp;gt;, &amp;lt;time&amp;gt;,&lt;/code&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;resolution&amp;gt;, &amp;lt;transform-function&amp;gt;, &amp;lt;custom-ident&amp;gt;, &amp;lt;transform-list&amp;gt;&lt;/code&gt; değerlerinden birini alabiliyor.&lt;/p&gt;

&lt;p&gt;Bu tanımı yaptığımızda tarayıcı, CSS değişkenini belirttiğimiz türde  kaydederek. Daha sonra geçişlerde ve animasyonlarda kullanıldığında bu özelliğin değerlerini nasıl enterpolasyona tabi tutacağını bilir.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://x.com/slashdev_io/status/1728782613039739059?s=20"&gt;slashdev.io&lt;/a&gt;‘nun örneği konuyu anlamak için çok güzel.&lt;/p&gt;

&lt;iframe height="375.6015625" style="width: 100%;" scrolling="no" title="@property  - öncesi" src="https://codepen.io/fatihhayri/embed/QWYeQgm?default-tab=css%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Rengi ve boyutu değişen bir kutu animasyonu yapalım. Tabi buradaki &lt;code class="language-plaintext highlighter-rouge"&gt;--scale: .5;&lt;/code&gt; değerinin tipini anlamayan tarayıcı kutu boyutunu değiştirme kısmını uygulamayacak.&lt;/p&gt;

&lt;iframe height="476.88671875" style="width: 100%;" scrolling="no" title="@property  - sonrası" src="https://codepen.io/fatihhayri/embed/NWoQyvy?default-tab=css%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="k"&gt;@property&lt;/span&gt; &lt;span class="n"&gt;--scale&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="py"&gt;syntax&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;"&amp;lt;number&amp;gt;"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;inherits&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;false&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;initial-value&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;tanımıyla tarayıcıya bunun bir sayı olduğunu söylediğimizde animasyon istediğimiz gibi çalışacaktır.&lt;/p&gt;

&lt;h2 id="tarayıcıların-geliştirme-ortamında-yönetimi"&gt;Tarayıcıların geliştirme ortamında yönetimi&lt;/h2&gt;

&lt;p&gt;Şimdilik sadece Chrome’da tarayıcı geliştirme aracında gösterim var. Safari desteği var ama gösterim yok. Firefox’da yeni ekledi zamanla ekleyeceklerini düşünüyorum.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/property-tanimi.png" alt="property" /&gt;&lt;/p&gt;

&lt;p&gt;Üzerine gelince çıkan popup’da gösteriyor ve ayrıca listenin en altında da gösteriyor.&lt;/p&gt;

&lt;p&gt;## Tarayıcı desteği&lt;/p&gt;

&lt;p&gt;Tarayıcı desteği konusunda gayet iyi yerlerde. Türkiye’de %91’lik bir oranla desteği var.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://nerdy.dev/cant-break-this-design-system"&gt;https://nerdy.dev/cant-break-this-design-system&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/@property"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/@property&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://blog.logrocket.com/using-property-loosely-typed-css-custom-properties/"&gt;https://blog.logrocket.com/using-property-loosely-typed-css-custom-properties/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/exploring-property-and-its-animating-powers/"&gt;https://css-tricks.com/exploring-property-and-its-animating-powers/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://web.dev/articles/at-property?hl=en"&gt;https://web.dev/articles/at-property?hl=en&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://obetomuniz.medium.com/css-custom-properties-with-property-3a86a04f9d05"&gt;https://obetomuniz.medium.com/css-custom-properties-with-property-3a86a04f9d05&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.bram.us/2023/02/01/the-gotcha-with-animating-custom-properties/"&gt;https://www.bram.us/2023/02/01/the-gotcha-with-animating-custom-properties/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/jecfish/status/1726827782775218270?s=20"&gt;https://x.com/jecfish/status/1726827782775218270?s=20&lt;/a&gt; tarayıcıda property gösterimi&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/aaroniker_me/status/1706946055059685492?s=20"&gt;https://x.com/aaroniker_me/status/1706946055059685492?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/argyleink/status/1697672085181698444?s=20"&gt;https://x.com/argyleink/status/1697672085181698444?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/slashdev_io/status/1728782613039739059?s=20"&gt;https://x.com/slashdev_io/status/1728782613039739059?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/animating-number-counters/"&gt;https://css-tricks.com/animating-number-counters/&lt;/a&gt; sayı animasyonu&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/amit_sheen/status/1602661845034229763?s=20"&gt;https://x.com/amit_sheen/status/1602661845034229763?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/argyleink/status/1681724861834723328?s=20"&gt;https://x.com/argyleink/status/1681724861834723328?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/argyleink/status/1648777788915322885?s=20"&gt;https://x.com/argyleink/status/1648777788915322885?s=20&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-tip-tan%C4%B1m%C4%B1-property/"&gt;CSS ile tip tanımı @property&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 25, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>Listenin son elemanını bulmak</title><link>https://fatihhayrioglu.com/listenin-son-elemanini-bulmak/</link><pubDate>Fri, 22 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/listenin-son-elemanini-bulmak</guid><description>&lt;p&gt;Geçen gün &lt;a href="https://github.com/Trendyol/baklava"&gt;baklava&lt;/a&gt; select komponentine arama ekleme işini yapıyordu &lt;a href="https://twitter.com/koalafied_dev"&gt;Erbil&lt;/a&gt;. Bu geliştirme sırasında şöyle bir şey yaşadık; &lt;code class="language-plaintext highlighter-rouge"&gt;hidden&lt;/code&gt; özniteliği ile gizlediğimiz listenin son elemanından dolayı son elemanın alt çizgisinin gizleme kodu çalışmıyordu.&lt;/p&gt;

&lt;p&gt;Olayı şöyle örnekleyebilirim.&lt;/p&gt;

&lt;iframe height="400" style="width: 100%;" scrolling="no" title="last-of-type" src="https://codepen.io/fatihhayri/embed/LYaPwmB?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;İlk listede normal durumda son elemanın altındaki çizgi gözükmüyor. İkinci örnekte sondan bir önceki eleman gizlendiği için yine gözükmüyor ancak son örnekte son elemanı gizlediğimiz için çizgi gözüküyor. &lt;code class="language-plaintext highlighter-rouge"&gt;:last-of-type&lt;/code&gt; seçicisi listenin gizlenmiş ögelerini dikkate almıyor. Çözmek için ürettiğimiz &lt;code class="language-plaintext highlighter-rouge"&gt;:not([hidden]):last-of-type&lt;/code&gt; seçicisi de işlemedi.&lt;/p&gt;

&lt;p&gt;Bu konu hakkındaki araştırmalarımız sonucu &lt;a href="https://stackoverflow.com/a/8300258/296373"&gt;stackoverflow’daki&lt;/a&gt; bu çözüm bize yol gösterdi. &lt;code class="language-plaintext highlighter-rouge"&gt;:nth-last-child(1 of :not([hidden]))&lt;/code&gt; ile sorun çözüldü.&lt;/p&gt;

&lt;p&gt;Shadow DOM kaynaklı bir sorun nedeni ile baklavada çözmedi ama CSS ile böyle bir sorun yaşayanlar için not olsun diye buraya ekliyeyim dedim :)&lt;/p&gt;

&lt;p&gt;Erbil burdaki sorunu çözen bir yöntem yazmış onu da ekliyeyim de web komponent için çözümü de aktarmış olalım.&lt;/p&gt;

&lt;div class="language-js highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt; &lt;span class="kr"&gt;private&lt;/span&gt; &lt;span class="nx"&gt;_handleLastVisibleSearchedOption&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="kd"&gt;const&lt;/span&gt; &lt;span class="nx"&gt;lastVisibleOption&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;[...&lt;/span&gt;&lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;options&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nx"&gt;reverse&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nx"&gt;find&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;option&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;option&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;hidden&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;

    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;lastVisibleOption&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nx"&gt;lastVisibleOption&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nx"&gt;shadowRoot&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nx"&gt;querySelector&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;div&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)?.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;add&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;no-border-bottom&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;this&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;options&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;map&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="nx"&gt;option&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="nx"&gt;option&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;hidden&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nx"&gt;option&lt;/span&gt; &lt;span class="o"&gt;!==&lt;/span&gt; &lt;span class="nx"&gt;lastVisibleOption&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="nx"&gt;option&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;shadowRoot&lt;/span&gt;&lt;span class="p"&gt;?.&lt;/span&gt;&lt;span class="nx"&gt;querySelector&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;div&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)?.&lt;/span&gt;&lt;span class="nx"&gt;classList&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nx"&gt;remove&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="s2"&gt;no-border-bottom&lt;/span&gt;&lt;span class="dl"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
      &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;});&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/:nth-child#browser_compatibility"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/:nth-child#browser_compatibility&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://stackoverflow.com/questions/8300185/combining-last-child-with-not-class-selector-in-css"&gt;https://stackoverflow.com/questions/8300185/combining-last-child-with-not-class-selector-in-css&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/listenin-son-elemanini-bulmak/"&gt;Listenin son elemanını bulmak&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 22, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS ile dinamik arka planlarda metin rengini otomatik değiştirtmek</title><link>https://fatihhayrioglu.com/css-ile-dinamik-arka-planlarda-metin-rengini-otomatik-degistirtmek/</link><pubDate>Mon, 18 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-ile-dinamik-arka-planlarda-metin-rengini-otomatik-degistirtmek</guid><description>&lt;p&gt;Durumu şöyle açıklayabilirim: Aslında başlıkta açıklamış gibiyim :) Değişen arka planların olduğu bir yapının üzerindeki metinlerin rengini dinamik değiştirmeyi göreceğiz.&lt;/p&gt;

&lt;p&gt;Böyle bir ihtiyacımız olmuştu daha önce bunu nasıl yaparız diye düşünüp çözemeyince farklı yollara başvurmuştuk.&lt;/p&gt;

&lt;p&gt;Hatırladığım dört örnek var. Kendilerini bulamasam da benzer örnekler üzerinden sorunları ve çözümlerini anlatmaya çalışacağım. Son örnek benim sitemden olduğu için onu önceki ve sonraki hallerini resim olarak ekledim.&lt;/p&gt;

&lt;h2 id="dinamik-arka-planlı-carousel"&gt;Dinamik arka planlı carousel&lt;/h2&gt;

&lt;p&gt;Çok eskilerde bir iş yapmıştım bir carousel yapıda resim üzerinde yazıların olduğu bir örnek vardı. Tasarımcının yaptığı örnekler mükemmeldi ancak iş kodlamaya dökülüp gerçek veriler girdiğinde hiçte hoş olmayan bir durum ortaya çıktı.&lt;/p&gt;

&lt;p&gt;Üzerinden çok süre geçtiği için o carousel’i bulamadım. Onun yerine &lt;a href="https://fatihhayrioglu.com/css-scroll-snap/" title="CSS scroll-snap"&gt;scroll-snap&lt;/a&gt; yazısındaki örneğe bir yazı ekleyip göstereyim dedim. Örnek olsun diye ilk resmi metin rengi ile aynı olacak şekilde ardalanı beyaz bir köpek resmi ekledim. İlk resimde yazını altına beyaz ardalan geldiği için normalde yazı gözükmeyecekti. Biz burada &lt;code class="language-plaintext highlighter-rouge"&gt;mix-blend-mode: difference;&lt;/code&gt; ekleyerek yazının arkada gelen resimden bağımsız görünmesini sağladık.&lt;/p&gt;

&lt;iframe height="699.53515625" style="width: 100%;" scrolling="no" title="Social Media Carousel with Scroll-Driven Animations" src="https://codepen.io/fatihhayri/embed/BaMgZLb?default-tab=html%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Koddaki başlık olan &lt;code class="language-plaintext highlighter-rouge"&gt;h2&lt;/code&gt;‘den &lt;code class="language-plaintext highlighter-rouge"&gt;mix-blend-mode: difference;&lt;/code&gt;  özelliğini kaldırarak sorunlu halini görebilirsiniz.&lt;/p&gt;

&lt;h2 id="mobilde-liste-üstü-buton"&gt;Mobilde liste üstü buton&lt;/h2&gt;
&lt;p&gt;Bir diğer soruna uzun bir ürün listenin olduğu alanın üstüne buton koyduğumuzda yaşadığımız benzer sorun. Buton rengine yakın renkteki listeki resimlerin üzerine geldiğimizde butonun görünürlüğü azalıyordu.&lt;/p&gt;

&lt;p&gt;Şöyle bir örnek gördüm codepen.io’da &lt;a href="https://twitter.com/jh3yy"&gt;jhey&lt;/a&gt;‘in yaptığı çözüm ile bu sorunu da halledebiliyormuşuz. &lt;code class="language-plaintext highlighter-rouge"&gt;mix-blend-mode: difference;&lt;/code&gt;  uygulaması ile çözülmüş.&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="mix-blend-mode fixed button &#129305;" src="https://codepen.io/jh3y/embed/gOqGgGz?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;h2 id="bastıkça-dolan-buton"&gt;Bastıkça dolan buton&lt;/h2&gt;

&lt;p&gt;Diğer sorun yaşadığım konu bir butonun mobilde tıklma ile değil de basıldığı sürece içinin dolduğu bir animasyon uyguladığımızda metin rengiyle ilgili yaşadığımız sorun.&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="UI Button #3 w/ Mix-Blend-Mode" src="https://codepen.io/dan10gc/embed/EQbjgP?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
&lt;/iframe&gt;

&lt;p&gt;Benzer bir örnek buldum codepen.io’da. Çözüm yine &lt;code class="language-plaintext highlighter-rouge"&gt;mix-blend-mode: difference;&lt;/code&gt; ile yapılmış.&lt;/p&gt;

&lt;h2 id="sitemdeki-resimli-başlıkların-resim-ile-olan-uyumu"&gt;Sitemdeki resimli başlıkların resim ile olan uyumu&lt;/h2&gt;

&lt;p&gt;Sitemdeki yazıların başlıkları altına resim olan bir tema kullanıyorum, burada her zaman resim ve üzerindeki yazıyı düşünerek bir şeyler üretmem gerekiyor. &lt;code class="language-plaintext highlighter-rouge"&gt;mix-blend-mode: difference;&lt;/code&gt; uygulayarak birçok başlık ve resmindeki sorunu çözmüş oluyorum.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/mix-blen--title.webp" alt="mix-blend-mode" /&gt;
Genel itibariyle sorunumu çözdü. Sadece bazı yazı içeren karmaşık arka plan resimlerinin olduğu başlıklar güzel sonuç vermedi. Bundan sonra yazılarıma arka plan resmi hazırlarken yazı olmamasına dikkat etmem yeterli olacak.&lt;/p&gt;

&lt;p&gt;Tarayıcı desteği konusunda gayet iyi. Türkiye için %96.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://www.marioaraque.com/mix-blend-mode-change-color"&gt;https://www.marioaraque.com/mix-blend-mode-change-color&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/kaos/dynamic-text-effects-with-css-mix-blend-mode-242a"&gt;https://dev.to/kaos/dynamic-text-effects-with-css-mix-blend-mode-242a&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/methods-contrasting-text-backgrounds/"&gt;https://css-tricks.com/methods-contrasting-text-backgrounds/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/deepak_kharah/pen/wvNeqpo"&gt;https://codepen.io/deepak_kharah/pen/wvNeqpo&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/dan10gc/pen/EQbjgP"&gt;https://codepen.io/dan10gc/pen/EQbjgP&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/jalinb/pen/ExOgOBZ"&gt;https://codepen.io/jalinb/pen/ExOgOBZ&lt;/a&gt; Dİnamik bg güzel bir örnek&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-dinamik-arka-planlarda-metin-rengini-otomatik-degistirtmek/"&gt;CSS ile dinamik arka planlarda metin rengini otomatik değiştirtmek&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 18, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>::marker sözde (pseudo) elemanı</title><link>https://fatihhayrioglu.com/marker-sozde-pseudo-elemani/</link><pubDate>Thu, 14 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/marker-sozde-pseudo-elemani</guid><description>&lt;p&gt;W3C’nin son zamanlarda yaptığı güzel ataklar bize doğru yolu bulduklarını gösteriyor. Geriden de gelseler sektörün ihtiyaçlarına kulak vermeleri güzel.  &lt;code class="language-plaintext highlighter-rouge"&gt;::marker&lt;/code&gt; ile bunun ne alakası var derseniz şöyle açıklayayım: Yıllarca list işaretleyici (marker) için çeşitli yöntemler geliştirdik ve kullandık sonra &lt;code class="language-plaintext highlighter-rouge"&gt;::marker&lt;/code&gt; sözde elementi çıktı ve bu yaptığımız alternatif yöntemlere gerek kalmadı. &lt;strong&gt;Standart koyucular yerleşik olarak gelen elemanlara yeterince CSS ile erişim sağlarlarsa hem daha standart hem de daha kolay yönetilebilir bir mecraya kavuşabiliriz.&lt;/strong&gt; Son yıllardaki atılım bu konuda beklenen çizgiye geldiğini gösteriyor.&lt;/p&gt;

&lt;p&gt;Gelelim konumuza HTML’de üç çeşit liste elementi var. Sıralı listeler (&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;ol&amp;gt;&lt;/code&gt;) ve sırasız listeler (&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;ul&amp;gt;&lt;/code&gt;) ve tanımlı listeler(&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;dl&amp;gt;&lt;/code&gt; &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;dd&amp;gt;&lt;/code&gt;) Biz burada işaretçisi olan &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;ul&amp;gt;&lt;/code&gt;ve &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;ol&amp;gt;&lt;/code&gt; elementi inceleyeceğiz.&lt;/p&gt;

&lt;p&gt;Bu HTML etiketlerini oluşturduğumuzda bize tarayıcıların standart stilleri ile görünürler.  Biz bu görünümleri değiştirmek için şimdiye kadar alternatif yöntemler kullanıyorduk. Şimdi &lt;code class="language-plaintext highlighter-rouge"&gt;::marker&lt;/code&gt; sözde elementi ile bunu kolaylıkla yapabiliyoruz.&lt;/p&gt;

&lt;iframe height="332.296875" style="width: 100%;" scrolling="no" title="Listeler" src="https://codepen.io/fatihhayri/embed/wvNZGeO?default-tab=html%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/wvNZGeO"&gt;
  Listeler&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki listede yuvarlak işaretçiyi veya rakamları değiştirmek istesek te W3C’nin bize sunduğu alternatiflerden birini kullanmak durumundaydık. Kendi özel işaretçimizi kullanmak için genelde &lt;code class="language-plaintext highlighter-rouge"&gt;list-style: none;&lt;/code&gt; ile işaretçiyi gizleyip &lt;code class="language-plaintext highlighter-rouge"&gt;:before&lt;/code&gt; ile kendi işaretçimizi ekliyorduk.&lt;/p&gt;

&lt;p&gt;Şimdi &lt;code class="language-plaintext highlighter-rouge"&gt;::marker&lt;/code&gt; sözde elemanı yardımı ile bu işaretçilerin özelliklerine erişip değiştirebiliyoruz.&lt;/p&gt;

&lt;iframe height="341.765625" style="width: 100%;" scrolling="no" title="Listeler" src="https://codepen.io/fatihhayri/embed/poGByVj?default-tab=html%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/poGByVj"&gt;
  Listeler&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Bunun dışında işaretçilerin yerine resim veya emoji koyabiliyoruz.&lt;/p&gt;

&lt;iframe height="488.6953125" style="width: 100%;" scrolling="no" title="Listeler" src="https://codepen.io/fatihhayri/embed/VwgNaEd?default-tab=html%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/VwgNaEd"&gt;
  Listeler&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;h2 id="marker-sözde-sınıfına-tanımlanabilen-özellikler"&gt;::marker sözde sınıfına tanımlanabilen özellikler&lt;/h2&gt;

&lt;p&gt;Şu an uygulanabilen tanımlar aşağıdakilerdir.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;font-*&lt;/code&gt; özellikleri&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;white-space&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;color&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;direction&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;content&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;animation&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;transition&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Şu an &lt;code class="language-plaintext highlighter-rouge"&gt;background&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;margin&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;padding&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;width&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;height&lt;/code&gt; özelliklerine müdahale edemiyoruz umarım bunlarda eklenir.&lt;/p&gt;

&lt;h2 id="tarayıcıda-görünümü"&gt;Tarayıcıda görünümü&lt;/h2&gt;

&lt;p&gt;Liste işaretçilerini tarayıcılarda görüntüleyip üzerinde işlem yapabiliyoruz.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/marker-tarayici.png" alt="marker tarayıcıda görünümü" /&gt;&lt;/p&gt;

&lt;p&gt;Tarayıcı desteği de gayet iyi. Yazıyı yazdığımda %95 desteği var.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;https://css-tricks.com/css-counters-custom-list-number-styling/&lt;/li&gt;
  &lt;li&gt;https://codepen.io/ines/pen/qXrYQO&lt;/li&gt;
  &lt;li&gt;https://codepen.io/t_afif/pen/GRYZeqr&lt;/li&gt;
  &lt;li&gt;https://codepen.io/DuskoStamenic/pen/LYeEqbm&lt;/li&gt;
  &lt;li&gt;https://codepen.io/5t3ph/pen/KKgqeNB&lt;/li&gt;
  &lt;li&gt;https://webdesign.tutsplus.com/next-level-list-bullets-with-css-marker–cms-37212t&lt;/li&gt;
  &lt;li&gt;https://youtu.be/2awepiNoaZI?si=LFm0QOT5gap_x3AW&lt;/li&gt;
  &lt;li&gt;https://www.smashingmagazine.com/2019/07/css-lists-markers-counters/&lt;/li&gt;
  &lt;li&gt;https://web.dev/articles/css-marker-pseudo-element?hl=tr&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/marker-sozde-pseudo-elemani/"&gt;::marker sözde (pseudo) elemanı&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 14, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS ile animasyonlu altı çizili metinler yapmak</title><link>https://fatihhayrioglu.com/css-ile-animasyonlu-alti-cizili-metinler-yapmak/</link><pubDate>Mon, 11 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-ile-animasyonlu-alti-cizili-metinler-yapmak</guid><description>&lt;p&gt;Bu sıralar CSS ile yapabileceklerimiz konusunda codepen.io’da çok vakit geçiriyorum. Gördüklerimden güzel olanları burada paylaşmaya çalışıyorum. Bu yazıda animasyonlu altı çizli metinler yapmayı anlatmaya çalışacağım. Benim genelde basit ve kolay çözümler daha çok hoşuma gidiyor.  Çok eskilerde bu animasyonu genelde flash sitelerin menülerinde kullanıyorduk.&lt;/p&gt;

&lt;p&gt;Bu animasyonu yapmak için farklı yöntemler(underline, background- box-shadow) var ancak elemanın &lt;code class="language-plaintext highlighter-rouge"&gt;:before&lt;/code&gt; sözde elemanı ile yapmak en mantıklısı.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt;&lt;span class="nd"&gt;::before&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;""&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;position&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;absolute&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;display&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;block&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;100%&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;4px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;bottom&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;2px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;left&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--underline-color&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;scaleX&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;transition&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;transform&lt;/span&gt; &lt;span class="m"&gt;0.25s&lt;/span&gt; &lt;span class="n"&gt;ease-out&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;transform: scaleX(0);&lt;/code&gt; ile çizgiyi gizliyoruz. Aslında animasyonu da bunun üzerinden yapacağız.  Animasyonu &lt;code class="language-plaintext highlighter-rouge"&gt;transition: transform 0.25s ease-out;&lt;/code&gt; kodu ile ayarladık.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;a&lt;/span&gt;&lt;span class="nd"&gt;:hover::before&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;transform&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;scaleX&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;Sadece &lt;code class="language-plaintext highlighter-rouge"&gt;transform: scaleX(1);&lt;/code&gt; kodu ile animasyonu tamamladık.&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="animasyonlu altı çizgili metinler" src="https://codepen.io/fatihhayri/embed/vYbPOxz?default-tab=result&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/vYbPOxz"&gt;
  animasyonlu altı çizgili metinler&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Animasyonun yönünü değiştirebiliriz.&lt;/p&gt;

&lt;h2 id="soldan-sağa-animasyon"&gt;Soldan sağa animasyon&lt;/h2&gt;

&lt;p&gt;Burada sadece &lt;code class="language-plaintext highlighter-rouge"&gt;transform-origin: bottom left;&lt;/code&gt; kodu ile bunu değiştirebiliyoruz.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nc"&gt;.soldan&lt;/span&gt;&lt;span class="nd"&gt;:before&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;transform-origin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;bottom&lt;/span&gt; &lt;span class="nb"&gt;left&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id="sağdan-sola-animasyon"&gt;Sağdan sola animasyon&lt;/h2&gt;

&lt;p&gt;Burada sadece &lt;code class="language-plaintext highlighter-rouge"&gt;transform-origin: bottom right;&lt;/code&gt; kodu ile bunu değiştirebiliyoruz.&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nc"&gt;.sagdan&lt;/span&gt;&lt;span class="nd"&gt;:before&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;transform-origin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;bottom&lt;/span&gt; &lt;span class="nb"&gt;right&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Çok çeşitli örnekler var. Kaynaklar kısmına göz atmanızı öneririm.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/VladykoD/pen/ZEYMmVg"&gt;https://codepen.io/VladykoD/pen/ZEYMmVg&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://tobiasahlin.com/blog/css-trick-animating-link-underlines/"&gt;https://tobiasahlin.com/blog/css-trick-animating-link-underlines/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-irl.info/animating-underlines/"&gt;https://css-irl.info/animating-underlines/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/jstn/pen/mdoOZJ?editors=1100"&gt;https://codepen.io/jstn/pen/mdoOZJ?editors=1100&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://tympanus.net/Development/LineHoverStyles/"&gt;https://tympanus.net/Development/LineHoverStyles/&lt;/a&gt; Güzel örnekler&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://paulund.co.uk/css-animation-link-underline"&gt;https://paulund.co.uk/css-animation-link-underline&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-animasyonlu-alti-cizili-metinler-yapmak/"&gt;CSS ile animasyonlu altı çizili metinler yapmak&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 11, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>accent-color tanımı</title><link>https://fatihhayrioglu.com/accent-color/</link><pubDate>Mon, 4 Dec 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/accent-color</guid><description>&lt;p&gt;HTML form elemanları genelde tarayıcıların belirlediği standart stiller ile gelir. Çoğu zaman projelerimizde standart gelen renkleri değiştirmek için farklı yollar izleriz. Son zamanlarda genel olarak &lt;code class="language-plaintext highlighter-rouge"&gt;appearance: none&lt;/code&gt; ile tarayıcı stillerini ve davranışlarını ezip ekstra div veya &lt;code class="language-plaintext highlighter-rouge"&gt;:before&lt;/code&gt;, &lt;code class="language-plaintext highlighter-rouge"&gt;:after&lt;/code&gt; sözde sınıflarını kullanarak stillendiriyoruz. Bu yöntemler ile özelleştirilen form elemanları tarayıcının bize sunduğu özellikleri ezmemiz anlamına geliyor. Özellikle erişilebilirlik konusunda sorunlu hale geliyor.&lt;/p&gt;

&lt;p&gt;W3C bu sorunları görüp &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; tanımı çıkardı. &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; tanımı basitçe form elemanlarımızın tarayıcı tarafından belirlenmiş rengini değiştirmemizi sağlayan özelliktir. Tüm form elemanlarına uygulanmıyor.&lt;/p&gt;

&lt;h2 id="uygulanan-form-elemanları"&gt;Uygulanan form elemanları&lt;/h2&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; tanımı belirli form elemanlarında geçerli. Bu elemanlar&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;input type="checkbox"&amp;gt;&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;input type="radio"&amp;gt;&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;input type="range"&amp;gt;&lt;/code&gt;&lt;/li&gt;
  &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;progress&amp;gt;&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Aşağıdaki örnekte de görüleceği gibi bu form elemanlarına sadece &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; tanımı yaparak rengini değiştirebiliyoruz.&lt;/p&gt;

&lt;iframe height="412.83984375" style="width: 100%;" scrolling="no" title="Accent-color" src="https://codepen.io/fatihhayri/embed/XWOBdYb?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/XWOBdYb"&gt;
  Accent-color&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;h2 id="diğer-form-elemanları"&gt;Diğer form elemanları&lt;/h2&gt;

&lt;p&gt;Şimdilik yukarıdaki form elemanları için çalışan bu kod ileride yenilerinin eklenmesiyle daha etkin kullanılacaktır.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://web.dev/accent-color/"&gt;Adam Argyle’ın yazısındaki&lt;/a&gt; ek kod da değiştirebileceğimiz alanlar için güzel ipucu kod:&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nt"&gt;html&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; 
  &lt;span class="py"&gt;--brand&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;hotpink&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
  &lt;span class="py"&gt;scrollbar-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="no"&gt;hotpink&lt;/span&gt; &lt;span class="n"&gt;Canvas&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nd"&gt;:root&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="py"&gt;accent-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--brand&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nd"&gt;:focus-visible&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;outline-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--brand&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nd"&gt;::selection&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--brand&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="nd"&gt;::marker&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--brand&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="nd"&gt;:is&lt;/span&gt;&lt;span class="o"&gt;(&lt;/span&gt;
  &lt;span class="nd"&gt;::-webkit-calendar-picker-indicator&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;
  &lt;span class="nd"&gt;::-webkit-clear-button&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt;
  &lt;span class="nd"&gt;::-webkit-inner-spin-button&lt;/span&gt;&lt;span class="o"&gt;,&lt;/span&gt; 
  &lt;span class="nd"&gt;::-webkit-outer-spin-button&lt;/span&gt;
&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;var&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;--brand&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Umarım gelecekte select’in seçili option bg, takvim elemanın vb. renk değişimlerini de sağlarız. Ne kadar form elemanına erişirsek o kadar kolaylaşacak bu iş.&lt;/p&gt;

&lt;h2 id="koyu--açık-mod-durumları"&gt;Koyu / Açık mod durumları&lt;/h2&gt;

&lt;p&gt;Artık birçok sitede açık / koyu mod farkı kullanılmakta. Ayrıca sistemdeki tema seçimine göre &lt;code class="language-plaintext highlighter-rouge"&gt;prefers-color-scheme&lt;/code&gt; ile yazılan CSS kodunu da düşünmek lazım.&lt;/p&gt;

&lt;p&gt;Aşağıdaki resimde görüldüğü gibi farklı &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; seçimine göre tarayıcılar farklı renk seçeneklerine otomatik geçiyorlar. Normalde bizim özelleştirdiğimiz durumlarda bu tip durumları bizim düşünmemiz gerekiyor.&lt;/p&gt;

&lt;p&gt;Detay vermek gerekirse aşağıdaki görüntüde renk değişince checkbox’ın işareti rengin kontrastına göre siyah veya beyaz oluyor. Benzer şekilde progress’in çubuğunun rengi beyaz yada siyah oluyor. Radio’nun seçili ard alanı beyaz veya siyah oluyor.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/accent-color.gif" alt="accent-color" /&gt;&lt;/p&gt;

&lt;h2 id="sonuç"&gt;Sonuç&lt;/h2&gt;

&lt;p&gt;Sonuç olarak tüm projelerimizdeki sorunları çözmese de bazı projelerdeki ihtiyaçlarımızı karşılayacak bir özellik. Belki başka yenilikler ve yeni form elemanlarıyla daha da geliştirildiği takdirde daha çok projede kullanılabilir.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/CSS/accent-color"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/accent-color&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/almanac/properties/a/accent-color/"&gt;https://css-tricks.com/almanac/properties/a/accent-color/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://web.dev/articles/accent-color?hl=en"&gt;https://web.dev/articles/accent-color?hl=en&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.smashingmagazine.com/2021/09/simplifying-form-styles-accent-color/"&gt;https://www.smashingmagazine.com/2021/09/simplifying-form-styles-accent-color/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://blog.logrocket.com/simplify-form-styles-using-css-accent-color/"&gt;https://blog.logrocket.com/simplify-form-styles-using-css-accent-color/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/dostonnabotov/the-css-accent-color-property-explained-4h9o"&gt;https://dev.to/dostonnabotov/the-css-accent-color-property-explained-4h9o&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://caniuse.com/mdn-css_properties_accent-color"&gt;https://caniuse.com/mdn-css_properties_accent-color&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/jh3y/pen/qBmeBjw"&gt;https://codepen.io/jh3y/pen/qBmeBjw&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://davidwalsh.name/css-accent-color"&gt;https://davidwalsh.name/css-accent-color&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/argyleink/status/1500897519500333057?s=20"&gt;https://x.com/argyleink/status/1500897519500333057?s=20&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/accent-color/"&gt;accent-color tanımı&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on December 04, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS ile yükleniyor animasyonu yapmak</title><link>https://fatihhayrioglu.com/css-ile-yukleniyor-animasyonu-yapmak/</link><pubDate>Mon, 27 Nov 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-ile-yukleniyor-animasyonu-yapmak</guid><description>&lt;p&gt;CSS ile yapılabileceklerimiz her geçen gün artarken burada sizlere bazılarını sıralamak isterim. Bu yazımdan sizlere CSS ile yapılabilecek yükleniyor animasyonlarını anlatmaya çalışacağım. Burada anlattıklarım “devede kulak” bir çok sitede daha fazlasını bulabilirsiniz. &lt;a href="https://codepen.io/search/pens?q=Loading"&gt;codepen’de bir loading araması&lt;/a&gt; ile birçok örneğe erişebilirsiniz. Ayrıca hazır css kodları sunan sitelerden de yararlanabiliriz.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://css-loaders.com/"&gt;https://css-loaders.com/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://loading.io/css/"&gt;https://loading.io/css/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://cssloaders.github.io/"&gt;https://cssloaders.github.io/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://freefrontend.com/css-spinners/"&gt;https://freefrontend.com/css-spinners/&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Bunlar benim konuyu araştırırken bulduklarım. Burada anlatmamın sebebi; tasarım olarak gelen yükleniyor animasyonları buradaki örneklerden farklı olabilir biz temel kodları anlarsak birçoğunu CSS kullanarak yapabiliriz.&lt;/p&gt;

&lt;p&gt;Peki hazır resim dosyaları veya SVG ile de  biz bunları yapabiliriz niye CSS ile yapıyoruz?&lt;/p&gt;

&lt;p&gt;CSS ile yapmanın bize esneklik ve kolay değiştirebilme imkanı sağlar. Ben olabildiğince CSS ile çözme taraftarıyım.&lt;/p&gt;

&lt;h2 id="dairesel-yükleniyor-örneği"&gt;Dairesel yükleniyor örneği&lt;/h2&gt;

&lt;iframe height="250" style="width: 100%;" scrolling="no" title="CSS Spinner " src="https://codepen.io/fatihhayri/embed/bGzvWKG?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/bGzvWKG"&gt;
  CSS Spinner &lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Burada içi boş bir kutuyu &lt;code class="language-plaintext highlighter-rouge"&gt;border-radius&lt;/code&gt; ile yuvarlayıp kenarlarını saydam verip bir kenarını beyaz yaparak bir şekil elde ederiz. Bunu basit bir animasyonla &lt;code class="language-plaintext highlighter-rouge"&gt;transform: rotate(360deg)&lt;/code&gt; döndürdüğümüzde işlem tamamdır.&lt;/p&gt;

&lt;h2 id="bar-yükleniyor-örneği"&gt;Bar yükleniyor örneği&lt;/h2&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="CSS Spinner " src="https://codepen.io/fatihhayri/embed/ZEwxKjL?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/ZEwxKjL"&gt;
  CSS Spinner &lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Bu tip birden fazla eleman(3 adet bar) çözümlerin için HTML olarak eklemekte bir çözüm. ancak buradaki örnekte &lt;code class="language-plaintext highlighter-rouge"&gt;background&lt;/code&gt; özelliği üç eleman eklenmiş ve bu elemanların boyutlarıyla oynanarak animasyon elde edilmiştir.&lt;/p&gt;

&lt;h2 id="nokta-yükleniyor-örneği"&gt;Nokta yükleniyor örneği&lt;/h2&gt;

&lt;iframe height="180" style="width: 100%;" scrolling="no" title="CSS Bar" src="https://codepen.io/fatihhayri/embed/dyamZvL?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/dyamZvL"&gt;
  CSS Bar&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Bu örnekte biraz &lt;code class="language-plaintext highlighter-rouge"&gt;background&lt;/code&gt;‘a atanan &lt;code class="language-plaintext highlighter-rouge"&gt;radial-gradient&lt;/code&gt; ve &lt;code class="language-plaintext highlighter-rouge"&gt;clip-path&lt;/code&gt; yardımıyla şekil oluşturulmuş. Animasyonu da &lt;code class="language-plaintext highlighter-rouge"&gt;clip-path: inset(0 -34% 0 0)&lt;/code&gt; değiri değiştirilerek oluşturulmuştur.&lt;/p&gt;

&lt;h2 id="i̇lerleme-çubuğu-örneği"&gt;İlerleme çubuğu örneği&lt;/h2&gt;

&lt;iframe height="180" style="width: 100%;" scrolling="no" title="CSS Bar" src="https://codepen.io/fatihhayri/embed/KKJoyNm?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/KKJoyNm"&gt;
  CSS Bar&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yine bir background ile oluşturulmuş bir ardalan ve iki adet mor renkli çubuk ile şekil oluşturulmuş. Animasyon oluşturulan bu iki elmanın konumu değiştirilerek &lt;code class="language-plaintext highlighter-rouge"&gt;background-position: 250% 0,-150% 0&lt;/code&gt; yapılmış.&lt;/p&gt;

&lt;h2 id="progress-elementi-ile"&gt;progress elementi ile&lt;/h2&gt;

&lt;iframe height="180" style="width: 100%;" scrolling="no" title="CSS Bar" src="https://codepen.io/fatihhayri/embed/ZEwxKNy?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/ZEwxKNy"&gt;
  CSS Bar&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Yukarıdaki örneklerde HTML olarak hep &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;div class="yukleniyor"&amp;gt;&amp;lt;/div&amp;gt;&lt;/code&gt; diye bir elemanı kullanılarak üretildi. Burada ise &lt;code class="language-plaintext highlighter-rouge"&gt;&amp;lt;progress /&amp;gt;&lt;/code&gt; elemanı kullanılarak oluşturuldu.  Çok stiline dokunmamıza izin vermiyor standartlar. Sadece &lt;code class="language-plaintext highlighter-rouge"&gt;accent-color&lt;/code&gt; tanımıyla sağa sola hareket eden kısmın rengini değiştirebiliyoruz. Bu elemanını CSS ile erişimine olanak sağlansa hem mantıksal bir öge olmuş olur hem de işler daha kolay olur. Belki ilerde geliştirirler.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/single-element-loaders-the-spinner/"&gt;https://css-tricks.com/single-element-loaders-the-spinner/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://clba.nl/experiments/css-spinner/"&gt;https://clba.nl/experiments/css-spinner/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://kilianvalkhof.com/2010/css-html/css3-loading-spinners-without-images/"&gt;https://kilianvalkhof.com/2010/css-html/css3-loading-spinners-without-images/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/dcodeyt/how-to-create-a-css-only-loading-spinner-5fh5"&gt;https://dev.to/dcodeyt/how-to-create-a-css-only-loading-spinner-5fh5&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.freecodecamp.org/news/how-to-create-a-css-only-loader/"&gt;https://www.freecodecamp.org/news/how-to-create-a-css-only-loader/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://medium.com/nerd-for-tech/beautiful-spinner-in-css-bce7a348f50f"&gt;https://medium.com/nerd-for-tech/beautiful-spinner-in-css-bce7a348f50f&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/sdelaney/pen/wWdxPe"&gt;https://codepen.io/sdelaney/pen/wWdxPe&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/WebsiteMentor/pen/bGjNOVY"&gt;https://codepen.io/WebsiteMentor/pen/bGjNOVY&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/benjamin-pike/pen/poaQpRQ"&gt;https://codepen.io/benjamin-pike/pen/poaQpRQ&lt;/a&gt; SVG destekli&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/avabarok/pen/BaYPJaG"&gt;https://codepen.io/avabarok/pen/BaYPJaG&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/wheatup/pen/qBRXzGZ"&gt;https://codepen.io/wheatup/pen/qBRXzGZ&lt;/a&gt; Yenilikçi&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/TKS31/pen/bGVaavW"&gt;https://codepen.io/TKS31/pen/bGVaavW&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/DannyJoris/pen/mzPREe"&gt;https://codepen.io/DannyJoris/pen/mzPREe&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://codepen.io/SugarLife/pen/xzwayr"&gt;https://codepen.io/SugarLife/pen/xzwayr&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;https://web.dev/articles/building/a-loading-bar-component?hl=en&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-yukleniyor-animasyonu-yapmak/"&gt;CSS ile yükleniyor animasyonu yapmak&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on November 27, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS scroll-snap</title><link>https://fatihhayrioglu.com/css-scroll-snap/</link><pubDate>Mon, 20 Nov 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-scroll-snap</guid><description>&lt;p&gt;Yatay scroll tercih sebepleri genelde kullanıcının yoğun kullandığı alandaki yerin paylaşım sorunlarını aşmaktır. Bu paylaşım sorunu mobil ortamlarda daha fazla ortaya çıkıyor. Birçok e-ticaret ve haber sitesinde yer alan caraousel yapıları bunun en önemli örneğidir. Bu yapılar genel olarak javascript ile çözüle gelmekte idi. Sonra standart koyucular bunun CSS ile de yapılacağı bir özellik grubu açıkladı bu özellik grubunu &lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap&lt;/code&gt; olarak tanımlıyoruz.&lt;/p&gt;

&lt;p&gt;Bir içeriği kaydırırken genelde kaydırılan içeriğin neresine kadar kaydırdığımıza dikkat etmek zorunda kalırız. Çünkü arada atlama olmasını istemeyiz.  Günümüzde sonsuz kaydırmalı yapıların çoğalarak kullanıldığı yapılarda bu daha çok önem kazanır. &lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap&lt;/code&gt;   özelliği kaydırmanın belli noktalara mıknatıs gibi yapışmasını sağlıyor. Böylece kullanıcı fazladan dikkat etmek zorunda kalmadan kaydırma yapabiliyor.&lt;/p&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap&lt;/code&gt;  özellikleri kaydırma yapılacak içeriği kapsayan elemana tanımlana özellikler ve kaydırılan içeriğe atana özellikler diye ikiye ayırırız.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Kapsayıcı tanımları
    &lt;ul&gt;
      &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap-type&lt;/code&gt;&lt;/li&gt;
      &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-padding&lt;/code&gt;&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
  &lt;li&gt;Alt eleman tanımları
    &lt;ul&gt;
      &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap-align&lt;/code&gt;&lt;/li&gt;
      &lt;li&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-margin&lt;/code&gt;&lt;/li&gt;
    &lt;/ul&gt;
  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Kapsayıcı eleman tanımları ile başlayalım;&lt;/p&gt;

&lt;h2 id="scroll-snap-type"&gt;scroll-snap-type&lt;/h2&gt;

&lt;p&gt;Kaydırma işlemenin yapılacağı içeriğin kapsayıcısına tanımlanır. Tanımlanan kapsayıcının yatayda mı, dikeyde mi kaydırma yapacağını belirliyoruz bir de kaydırma işleminin tutma işleminin katı mı yoksa yarı katı mı olacağını belirliyoruz.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;strong&gt;mandatory&lt;/strong&gt;: Kaydırma işlemi yaparken kati bir şekilde belirlene noktaları tutmasını istiyorsak.&lt;/li&gt;
  &lt;li&gt;&lt;strong&gt;proximity&lt;/strong&gt;: Kaydırma işlemi yaparken kullanıcı yarıyı geçen kadar zorlama ama yarıyı geçtikten sonra yapıştır demek için kullanılır.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Bu iki ayrımı örneklerde daha iyi göreceksiniz diyelim ve diğer tanıma geçelim.&lt;/p&gt;

&lt;p&gt;mandatory örneği:&lt;/p&gt;
&lt;iframe height="300" style="width: 100%;" scrolling="no" title="scroll snap" src="https://codepen.io/fatihhayri/embed/ExrgJxa?default-tab=css%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/ExrgJxa"&gt;
  scroll snap&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;proximity örneği:&lt;/p&gt;
&lt;iframe height="300" style="width: 100%;" scrolling="no" title="scroll snap" src="https://codepen.io/fatihhayri/embed/qBgawRq?default-tab=css%2Cresult" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/qBgawRq"&gt;
  scroll snap&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;h2 id="scroll-padding"&gt;scroll-padding&lt;/h2&gt;

&lt;p&gt;Kaydırma işlemi yaparken sayfamızda veya içeriğimizde yapışık alanlar varsa veya tam belirli bir yerden değilde 20px öncesinde dursun dediğimiz durumları sağlar bize.&lt;/p&gt;

&lt;iframe height="400" style="width: 100%;" scrolling="no" title="scroll snap" src="https://codepen.io/fatihhayri/embed/JjxraML?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/JjxraML"&gt;
  scroll snap&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Gelelim alt eleman tanımlarına;&lt;/p&gt;

&lt;h2 id="scroll-snap-align"&gt;scroll-snap-align&lt;/h2&gt;

&lt;p&gt;Kaydırma yapılancak içerikteki ögelerin neresine hizalanacağını belirlememize yarıyor. Üç değer alır.&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;start: Kaydırma ögenin başlangıcına göre yapılır.&lt;/li&gt;
  &lt;li&gt;center: Kaydırma ögenin ortasına göre yapılır.&lt;/li&gt;
  &lt;li&gt;end: Kaydırma ögenin sonuna göre yapılır.&lt;/li&gt;
&lt;/ul&gt;

&lt;iframe height="426" style="width: 100%;" scrolling="no" title="scroll-snap-align" src="https://codepen.io/fatihhayri/embed/LYqjwwv?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/LYqjwwv"&gt;
  scroll-snap-align&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Not: İlk öge hep start ile başlar sonraki ögelerde tanıma göre değişir.&lt;/p&gt;

&lt;h2 id="scroll-margin"&gt;scroll-margin&lt;/h2&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-padding&lt;/code&gt; ile aynı işlevi görür. &lt;code class="language-plaintext highlighter-rouge"&gt;scroll-padding&lt;/code&gt; kapsayıcıya tanımlanırken &lt;code class="language-plaintext highlighter-rouge"&gt;scroll-margin&lt;/code&gt; alt elemana tanımlanır.&lt;/p&gt;

&lt;iframe height="400" style="width: 100%;" scrolling="no" title="scroll-margin" src="https://codepen.io/fatihhayri/embed/mdvBGzY?default-tab=result" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/mdvBGzY"&gt;
  scroll-margin&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;h2 id="tarayıcıların-geliştirici-araçlarındaki-görünümü"&gt;Tarayıcıların geliştirici araçlarındaki görünümü&lt;/h2&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/scroll-snap.png" alt="chrome scroll-snap" /&gt;
Chrome’un geliştirici aracında scroll-snap çok iyi düzenleniyor ve görünüyor. Kaydırma yapılacak alan scroll-snap kullandığı gösteriliyor. &lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap-align&lt;/code&gt; bilgisi padding ve margin bilgisi gösteriliyor. Kaydırma yapılan ögelerin izdüşümleri gösteriliyor. Firefox ve Safari’de gösteriyor ancak Chrome’un gösterimi çok iyi.&lt;/p&gt;

&lt;h2 id="tarayıcı-desteği"&gt;Tarayıcı desteği&lt;/h2&gt;

&lt;p&gt;%95 gibi gayet güzel bir desteği var.&lt;/p&gt;

&lt;picture&gt;
&lt;source type="image/webp" srcset="https://caniuse.bitsofco.de/static/v1/mdn-css__properties__scroll-snap-type-1741165381957.webp" /&gt;
&lt;source type="image/png" srcset="https://caniuse.bitsofco.de/static/v1/mdn-css__properties__scroll-snap-type-1741165381957.png" /&gt;
&lt;img src="https://caniuse.bitsofco.de/static/v1/mdn-css__properties__scroll-snap-type-1741165381957.jpg" alt="Data on support for the mdn-css__properties__scroll-snap-type feature across the major browsers from caniuse.com" /&gt;
&lt;/picture&gt;

&lt;h2 id="sonuç"&gt;Sonuç&lt;/h2&gt;

&lt;p&gt;&lt;code class="language-plaintext highlighter-rouge"&gt;scroll-snap&lt;/code&gt; özelliği bizlere bir çok yönüyle kolaylık sağlıyor. Tabi projelerimizdeki tüm kaydırma alanı ihtiyaçlarımızı karşıladığını söyleyemeyiz. Bir careousel yapabiliriz ama bu careousel’e ok eklemek istediğimizde ya statik ekleyeceğiz ya da javascript yardımı almamız gerekir. Benzer şekilde gezinmek için nokta koyduğumuzda da benzer durum geçerli. Şimdilik ihtiyaca göre javascirpt desteği sağlanıp çözüm üretmek mantıklı görünüyor.&lt;/p&gt;

&lt;p&gt;&lt;img src="https://fatihhayrioglu.com/images/scroll-snap+js.jpg" alt="slider scroll-snap + js" /&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://codepen.io/mobalti/pen/GRPMpyj"&gt;Şu örnek&lt;/a&gt; scroll-snap + js kullanımı için mükemmel bence.&lt;/p&gt;

&lt;p&gt;Bİr diğer konu da yeni gelecek olan kaydırma çubuğuna bağlı animasyon ile birlikte çok güzel uygulamalar ortaya çıkacaktır. Bu konuda &lt;a href="https://www.bram.us/2023/06/21/synchronize-videos-3d-models-to-scroll-driven-animations/"&gt;şöyle bir makale&lt;/a&gt; var.&lt;/p&gt;

&lt;p&gt;İki yönlü uygulama olarak bir takvim uygulaması gayet başarılı. &lt;a href="https://x.com/raphaelschaad/status/1636641781407264768?s=20"&gt;Örnek&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Tayfun Erbilen’in &lt;a href="https://x.com/tayfunerbilen/status/1269650827691638792?s=20"&gt;örneği de&lt;/a&gt; gayet güzel.&lt;/p&gt;

&lt;p&gt;Tabi pozitif yanlarını yanında negatif yanları da var. Bu işi js ile yapanların çıkardığı bir &lt;a href="https://alvarotrigo.com/blog/why-not-to-use-css-scroll-snap/"&gt;negatif yanlar yazısı var.&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Sonuç olarak tüm ihtiyaçları karşılaması zor bir alan ama en azından büyük çoğunluğun ihtiyacını karşılayacak bir özellik.&lt;/p&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://web.dev/css-scroll-snap/"&gt;https://web.dev/css-scroll-snap/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;https://twitter.com/CanIDevTools/status/1580409354209009664 - Chrome dev tools da gösterimi&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://12daysofweb.dev/2022/css-scroll-snap/"&gt;https://12daysofweb.dev/2022/css-scroll-snap/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://www.youtube.com/watch?v=pohyK8iz-SQ"&gt;https://www.youtube.com/watch?v=pohyK8iz-SQ&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Scroll_Snap&lt;/li&gt;
  &lt;li&gt;https://css-tricks.com/practical-css-scroll-snapping/&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css-tricks.com/how-i-added-scroll-snapping-to-my-twitter-timeline/"&gt;https://css-tricks.com/how-i-added-scroll-snapping-to-my-twitter-timeline/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;https://ishadeed.com/article/css-scroll-snap/&lt;/li&gt;
  &lt;li&gt;https://alvarotrigo.com/blog/why-not-to-use-css-scroll-snap/&lt;/li&gt;
  &lt;li&gt;https://www.filamentgroup.com/lab/introducing-snapper.html&lt;/li&gt;
  &lt;li&gt;https://blog.logrocket.com/how-to-use-css-scroll-snap/&lt;/li&gt;
  &lt;li&gt;https://www.youtube.com/watch?v=0Og_kQUsxEw&lt;/li&gt;
  &lt;li&gt;https://twitter.com/addyosmani/status/1485024476974694400&lt;/li&gt;
  &lt;li&gt;https://twitter.com/argyleink/status/1456979682344128517&lt;/li&gt;
  &lt;li&gt;https://codepen.io/argyleink/pen/wvgmMXe&lt;/li&gt;
  &lt;li&gt;https://codepen.io/mobalti/pen/GRPMpyj&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/iamakulov/status/1693563645773701422?s=20"&gt;https://x.com/iamakulov/status/1693563645773701422?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/mattgperry/status/1546838506789552133?s=20"&gt;https://x.com/mattgperry/status/1546838506789552133?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://youtu.be/WMRbz_AjDvU?si=JPHuP0Q-GxZ8XKwL"&gt;https://youtu.be/WMRbz_AjDvU?si=JPHuP0Q-GxZ8XKwL&lt;/a&gt; - CSS Scroll Snap Kullanımı - PROTOTURK&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/davidm_ml/status/1635593787371327488?s=20"&gt;https://x.com/davidm_ml/status/1635593787371327488?s=20&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://x.com/the_ross_man/status/1691913040168657348?s=20"&gt;https://x.com/the_ross_man/status/1691913040168657348?s=20&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-scroll-snap/"&gt;CSS scroll-snap&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on November 20, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item><item><title>CSS ile buzlu cam efekti yapmak</title><link>https://fatihhayrioglu.com/css-ile-buzlu-cam-efekti-yapmak/</link><pubDate>Mon, 13 Nov 2023 00:00:00 +0300</pubDate><guid isPermaLink="false">https://fatihhayrioglu.com/css-ile-buzlu-cam-efekti-yapmak</guid><description>&lt;p&gt;Buzlu cam efekti yapmak, &lt;a href="https://fatihhayrioglu.com/user-invalid-secicisi/" title=":user-invalid seçicisi"&gt;:user-invalid seçicisi&lt;/a&gt; yazısındaki örnekte de kullandığım bir teknikti. CSS’in bizlere kazandırdıklarını göstermek açısından güzel örnek.&lt;/p&gt;

&lt;p&gt;Peki buzlu cam desenli ardalanlar nasıl yapılıyor?&lt;/p&gt;

&lt;p&gt;Ben bu efekti ilk olarak Kyle Wetton’ın &lt;a href="https://codepen.io/kylewetton/pen/bGbaazX"&gt;CodePen&lt;/a&gt;‘deki örneğinde görmüştüm.&lt;/p&gt;

&lt;p&gt;Kod olarak da çok basit bir uygulaması var. Arka tarafında büyük bir resim olan bir kutunu ard alanına &lt;code class="language-plaintext highlighter-rouge"&gt;backdrop-filter: blur(18px);&lt;/code&gt; tanım yaparız. Uyguladığımız yere göre ard alanına beyaz veya siyah bir renk tanımlayıp saydamlığını da &lt;code class="language-plaintext highlighter-rouge"&gt;0.3&lt;/code&gt; tanımladıktan sonra son olarak kutuya bir gölge vermekte güzel etki yapıyor. Sonuçta kod:&lt;/p&gt;

&lt;div class="language-css highlighter-rouge"&gt;&lt;div class="highlight"&gt;&lt;pre class="highlight"&gt;&lt;code&gt;&lt;span class="nc"&gt;.glass&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;background-color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;rgba&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;255&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;255&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;255&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;-webkit-backdrop-filter&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;blur&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;18px&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="py"&gt;backdrop-filter&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;blur&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;18px&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
  &lt;span class="nl"&gt;box-shadow&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;0px&lt;/span&gt; &lt;span class="m"&gt;20px&lt;/span&gt; &lt;span class="m"&gt;18px&lt;/span&gt; &lt;span class="n"&gt;rgba&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="m"&gt;0.30&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="CSS - Frosted Glass" src="https://codepen.io/fatihhayri/embed/qBmBNbZ?default-tab=result&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/qBmBNbZ"&gt;
  CSS - Frosted Glass&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Üste yapışık menülerde de güzel efekt veriyor.&lt;/p&gt;

&lt;iframe height="300" style="width: 100%;" scrolling="no" title="Grid: grid-auto-flow: dense" src="https://codepen.io/fatihhayri/embed/rNPmKZO?default-tab=result&amp;amp;zoom=0.5" frameborder="no" loading="lazy" allowtransparency="true" allowfullscreen="true"&gt;
  See the Pen &lt;a href="https://codepen.io/fatihhayri/pen/rNPmKZO"&gt;
  Grid: grid-auto-flow: dense&lt;/a&gt; by Fatih Hayrioğlu (&lt;a href="https://codepen.io/fatihhayri"&gt;@fatihhayri&lt;/a&gt;)
  on &lt;a href="https://codepen.io"&gt;CodePen&lt;/a&gt;.
&lt;/iframe&gt;

&lt;p&gt;Bunların dışında bir çok örnek var. İncelemek isterseniz codpen &lt;a href="https://codepen.io/tag/frosted-glass"&gt;linki&lt;/a&gt;&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Not: &lt;code class="language-plaintext highlighter-rouge"&gt;filter: blur(10px)&lt;/code&gt; ile benzer sonuçlar elde edilebilir.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id="tarayıcı-desteği"&gt;Tarayıcı Desteği&lt;/h2&gt;

&lt;p&gt;Türkiye’de şu an %95’lik desteği ile kullanılır durumda.&lt;/p&gt;

&lt;picture&gt;
&lt;source type="image/webp" srcset="https://caniuse.bitsofco.de/static/v1/mdn-css__properties__backdrop-filter-1741165325362.webp" /&gt;
&lt;source type="image/png" srcset="https://caniuse.bitsofco.de/static/v1/mdn-css__properties__backdrop-filter-1741165325362.png" /&gt;
&lt;img src="https://caniuse.bitsofco.de/static/v1/mdn-css__properties__backdrop-filter-1741165325362.jpg" alt="Data on support for the mdn-css__properties__backdrop-filter feature across the major browsers from caniuse.com" /&gt;
&lt;/picture&gt;

&lt;p&gt;Kalın sağlıcakla.&lt;/p&gt;

&lt;h2 id="kaynaklar"&gt;Kaynaklar&lt;/h2&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;a href="https://webdesign.tutsplus.com/how-to-create-a-frosted-glass-effect-in-css--cms-32535t"&gt;https://webdesign.tutsplus.com/how-to-create-a-frosted-glass-effect-in-css–cms-32535t&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/tolentinoel/frosted-glass-on-css-37bg"&gt;https://dev.to/tolentinoel/frosted-glass-on-css-37bg&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://css.glass/"&gt;https://css.glass/&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://dev.to/khush2706/frosted-glass-effect-in-css-27p4"&gt;https://dev.to/khush2706/frosted-glass-effect-in-css-27p4&lt;/a&gt;&lt;/li&gt;
  &lt;li&gt;&lt;a href="https://silentlad.com/frosted-glass-effect-using-css"&gt;https://silentlad.com/frosted-glass-effect-using-css&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

  &lt;p&gt;&lt;a href="https://fatihhayrioglu.com/css-ile-buzlu-cam-efekti-yapmak/"&gt;CSS ile buzlu cam efekti yapmak&lt;/a&gt; was originally published by Fatih Hayrioğlu at &lt;a href="https://fatihhayrioglu.com"&gt;Fatih Hayrioğlu'nun not defteri&lt;/a&gt; on November 13, 2023.&lt;/p&gt;</description><author>fatih.hayrioglu@gmail.com (Fatih Hayrioglu)</author></item></channel></rss>