Others - C S S

  • cursor: pointer; => Shape of cursor when mouse hovers over it
  • pointer-events: none => Cursor will not be considered
  • -webkit-text-stroke: 2px black; => Gives stroke to text
    • text-shadow: -1px 0px black, 0 1px black, 1px 0 black, 0 -1px black; => Can this instead
    • text-shadow: x-offset y-offset color;
  • list-style: none;
    • list-style: list-style-type list-style-position list-style-image;
  • color-scheme: light/dark/normal => Sets canvas color
    • color-scheme: dark light
  • visibility: hidden/visible; => No visible but taking space
  • opacity: 1;
  • Body/HTML
    • box-sizing: border-box;
    • scroll-behavior: smooth;
    • scroll-padding: Npx 0 0 Npx;
      • scroll-padding-top: Npx;
  • Tricks
    • To make the children container take full width when restricted by its parent container (Break out of parent container)
          width: 100vw;
          margin-inline-start: 50%;
          transform: translateX(-50%);
          <!-- OR -->
          box-shadow: 0 0 0 100vmax color;
          clip-path: inset(0 -100vmax);
      
Share: