Advertisement
Guest User

Translate your React app using Format.js - CSS styles for ./src/App.css for example project

a guest
Feb 23rd, 2023
330
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
CSS 3.79 KB | Software | 0 0
  1. p {
  2.   margin: 0;
  3. }
  4.  
  5. h1:has(~ *),
  6. h2:has(~ *),
  7. h3:has(~ *),
  8. h4:has(~ *),
  9. h5:has(~ *),
  10. h6:has(~ *) {
  11.   margin: 0;
  12. }
  13.  
  14. ul {
  15.   list-style-type: none;
  16.   padding-inline-start: 0;
  17.   margin: 0;
  18. }
  19.  
  20. button {
  21.   width: fit-content;
  22.   padding: 0.5rem 1rem;
  23.   border: 1px solid #e5e5e5;
  24.   border-radius: 1rem;
  25.  
  26.   /* background gradient */
  27.   background-image: linear-gradient(
  28.     to bottom,
  29.     #ffffff 0%,
  30.     #ffffff 51%,
  31.     #f5f5f5 100%
  32.   );
  33.   cursor: pointer;
  34. }
  35.  
  36. button:disabled {
  37.   cursor: not-allowed;
  38. }
  39.  
  40. button:hover {
  41.   background-image: linear-gradient(
  42.     to bottom,
  43.     #ffffff 0%,
  44.     #ffffff 51%,
  45.     #e5e5e5 100%
  46.   );
  47. }
  48.  
  49. button:focus {
  50.   outline: none;
  51.   box-shadow: 0 0 0 1px #d6d6d6;
  52. }
  53.  
  54. button:active {
  55.   background-image: linear-gradient(
  56.     to top,
  57.     #ffffff 0%,
  58.     #ffffff 51%,
  59.     #f5f5f5 100%
  60.   );
  61. }
  62.  
  63. .badge {
  64.   display: inline-block;
  65.   padding: 0.5rem 1rem;
  66.   border-radius: 1rem;
  67.   background: #f5f5f5;
  68.   border: 1px solid #e5e5e5;
  69.   color: #000;
  70.   font-size: 0.75rem;
  71.   font-weight: 600;
  72. }
  73.  
  74. .img-cont img {
  75.   width: 100%;
  76.   object-fit: cover;
  77. }
  78.  
  79. .dropdown {
  80.   position: relative;
  81. }
  82.  
  83. .dropdown .content {
  84.   position: absolute;
  85.   top: calc(100% + 1rem);
  86.   right: 0;
  87.   width: max-content;
  88.   visibility: hidden;
  89.   opacity: 0;
  90.   transition: all 0.12s ease;
  91.   pointer-events: none;
  92. }
  93.  
  94. .dropdown .trigger.group :first-child {
  95.   border-top-right-radius: 0;
  96.   border-bottom-right-radius: 0;
  97. }
  98.  
  99. .dropdown .trigger.group :last-child {
  100.   border-top-left-radius: 0;
  101.   border-bottom-left-radius: 0;
  102. }
  103.  
  104. .dropdown .trigger:focus ~ .content,
  105. .dropdown .trigger:focus-within ~ .content,
  106. .content:focus,
  107. .content:focus-within,
  108. .content:hover {
  109.   visibility: visible;
  110.   opacity: 1;
  111.   pointer-events: auto;
  112. }
  113.  
  114. .app-header {
  115.   position: sticky;
  116.   top: 0;
  117.   background: #fff;
  118.   padding: 0 1rem;
  119.   border-bottom: 1px solid #e5e5e5;
  120. }
  121.  
  122. .app-header > .wrapper {
  123.   display: flex;
  124.   justify-content: space-between;
  125.   align-items: center;
  126.   padding: 1rem 0;
  127.   max-width: 60rem;
  128.   margin: 0 auto;
  129. }
  130.  
  131. .app-section {
  132.   padding: 1rem;
  133. }
  134.  
  135. .app-section > .wrapper {
  136.   max-width: 76rem;
  137.   margin: 0 auto;
  138. }
  139.  
  140. .products-header {
  141.   margin: 1rem 0;
  142.   padding: 2rem;
  143.   border: 1px solid #e5e5e5;
  144.   border-radius: 1rem;
  145. }
  146.  
  147. .products-header > .wrapper {
  148.   display: flex;
  149.   flex-direction: column;
  150.   /* gap: 1rem; */
  151. }
  152.  
  153. .products-header .caption {
  154.   font-size: 2rem;
  155.   font-weight: 600;
  156.   margin: 0;
  157. }
  158.  
  159. .products-list {
  160.   display: grid;
  161.   grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
  162.   gap: 1rem;
  163.   padding: 1rem 0;
  164. }
  165.  
  166. .product {
  167.   display: flex;
  168.   flex-direction: column;
  169.   justify-content: space-between;
  170.   gap: 1rem;
  171.   padding: 1rem;
  172.   border-radius: 1.5rem;
  173.   background: #fff;
  174.   border: 1px solid #e5e5e5;
  175. }
  176.  
  177. .product-image {
  178.   height: 16rem;
  179.   border-radius: 1rem;
  180.   overflow: hidden;
  181. }
  182.  
  183. .product-image img {
  184.   height: 100%;
  185. }
  186.  
  187. .product-price {
  188.   font-size: 2rem;
  189.   font-weight: 600;
  190. }
  191.  
  192. .cart {
  193.   background: #fff;
  194.   border: 1px solid #e5e5e5;
  195.   border-radius: 2rem;
  196.   overflow: auto;
  197. }
  198.  
  199. .cart .cart-header {
  200.   padding: 1rem;
  201. }
  202.  
  203. .cart .items {
  204.   display: flex;
  205.   flex-direction: column;
  206.   max-height: calc(100vh - 12rem);
  207. }
  208.  
  209. .cart .item {
  210.   display: flex;
  211.   gap: 1rem;
  212.   padding: 1rem;
  213.   border-top: 1px solid #e5e5e5;
  214.   cursor: pointer;
  215. }
  216.  
  217. .cart .item:hover,
  218. .cart .item:focus {
  219.   background: #f5f5f5;
  220. }
  221.  
  222. .cart .item-details {
  223.   display: flex;
  224.   flex-direction: column;
  225.   gap: 0.5rem;
  226. }
  227.  
  228. /* .cart .item:last-of-type {
  229.   border-bottom: none;
  230. } */
  231.  
  232. .cart .item-image {
  233.   /* height: 4rem; */
  234.   width: 4rem;
  235.   overflow: hidden;
  236.   border-radius: 1rem;
  237.   border: 1px solid #e5e5e5;
  238. }
  239.  
  240. .cart .item-image img {
  241.   height: 100%;
  242.   object-fit: cover;
  243. }
  244.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement