Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

ItemDetailsHeaderCard.styled.js 4.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. import { Box, Typography } from "@mui/material";
  2. import styled from "styled-components";
  3. import selectedTheme from "../../../themes";
  4. import { IconButton } from "../../Buttons/IconButton/IconButton";
  5. import { PrimaryButton } from "../../Buttons/PrimaryButton/PrimaryButton";
  6. import { ReactComponent as User} from "../../../assets/images/svg/user.svg";
  7. export const ItemDetailsHeaderContainer = styled(Box)`
  8. display: flex;
  9. flex-direction: column;
  10. width: ${(props) => (!props.halfwidth ? "100%" : "49%")};
  11. box-sizing: border-box;
  12. margin: 10px 0;
  13. background-color: ${(props) =>
  14. props.isMyProfile
  15. ? selectedTheme.primaryPurple
  16. : "white"};
  17. border-radius: 4px;
  18. border: 1px solid ${selectedTheme.primaryPurple};
  19. max-width: 2000px;
  20. position: relative;
  21. `;
  22. export const HeaderTop = styled(Box)`
  23. display: flex;
  24. flex-direction: row;
  25. padding: 18px;
  26. gap: 18px;
  27. `;
  28. export const OfferImage = styled.img`
  29. border-radius: 50%;
  30. width: 144px;
  31. height: 144px;
  32. @media (max-width: 600px) {
  33. width: 90px;
  34. height: 90px;
  35. }
  36. `;
  37. export const OfferInfo = styled(Box)`
  38. display: flex;
  39. flex: 2;
  40. flex-direction: column;
  41. justify-content: space-between;
  42. margin-left: 18px;
  43. `;
  44. export const OfferTitle = styled(Typography)`
  45. margin-bottom: 12px;
  46. font-family: "Open Sans";
  47. color: ${props => props.isMyProfile ? selectedTheme.primaryYellow : selectedTheme.primaryPurple};
  48. font-weight: 700;
  49. font-size: 24px;
  50. cursor: pointer;
  51. @media (max-width: 600px) {
  52. font-size: 18px;
  53. }
  54. `;
  55. export const OfferAuthor = styled(Box)`
  56. display: flex;
  57. flex: 1;
  58. flex-direction: column;
  59. `;
  60. export const OfferAuthorName = styled(Typography)`
  61. font-family: "Open Sans";
  62. line-height: 22px;
  63. font-size: 16px;
  64. color: ${selectedTheme.primaryDarkText};
  65. `;
  66. export const OfferLocation = styled(Box)`
  67. font-family: "Open Sans";
  68. color: ${selectedTheme.primaryText};
  69. line-height: 16px;
  70. font-size: 12px;
  71. `;
  72. export const OfferPIB = styled(Box)`
  73. font-family: "Open Sans";
  74. color: ${props => props.isMyProfile ? selectedTheme.primaryDarkTextThird : selectedTheme.primaryText};
  75. line-height: 16px;
  76. font-size: 12px;
  77. `;
  78. export const OfferDetails = styled(Box)`
  79. display: flex;
  80. flex-direction: column;
  81. flex-wrap: ${(props) => (!props.halfwidth ? "no-wrap" : "wrap")};
  82. justify-content: start;
  83. `;
  84. export const OfferCategory = styled(Box)`
  85. font-family: "Open Sans";
  86. color: ${selectedTheme.primaryText};
  87. line-height: 16px;
  88. font-size: 12px;
  89. width: 33%;
  90. `;
  91. export const OfferPackage = styled(Box)`
  92. font-family: "Open Sans";
  93. color: ${selectedTheme.primaryText};
  94. line-height: 16px;
  95. font-size: 12px;
  96. width: 34%;
  97. `;
  98. export const OfferViews = styled(Box)`
  99. font-family: "Open Sans";
  100. color: ${selectedTheme.primaryText};
  101. line-height: 16px;
  102. font-size: 12px;
  103. width: 34%;
  104. `;
  105. export const OfferDescriptionTitle = styled(Box)`
  106. font-family: "Open Sans";
  107. font-size: 12px;
  108. color: ${selectedTheme.primaryDarkText};
  109. line-height: 16px;
  110. `;
  111. export const OfferDescriptionText = styled(Box)`
  112. font-family: "Open Sans";
  113. font-size: 16px;
  114. color: ${selectedTheme.primaryDarkText};
  115. line-height: 22px;
  116. max-width: calc(100% - 230px);
  117. max-height: 120px;
  118. overflow: hidden;
  119. display: -webkit-box;
  120. -webkit-line-clamp: 5;
  121. -webkit-box-orient: vertical;
  122. `;
  123. export const OfferDescription = styled(Box)`
  124. flex: 3;
  125. margin: auto 0;
  126. padding-left: 35px;
  127. `;
  128. export const Line = styled(Box)`
  129. border-left: 1px solid rgba(0, 0, 0, 0.15);
  130. height: 100px;
  131. width: 0;
  132. margin: auto 0;
  133. `;
  134. export const CheckButton = styled(PrimaryButton)`
  135. width: 180px;
  136. height: 48px;
  137. position: absolute;
  138. bottom: 9px;
  139. right: 9px;
  140. &:hover button {
  141. background-color: ${selectedTheme.primaryPurple} !important;
  142. color: white !important;
  143. }
  144. `;
  145. export const MessageIcon = styled(IconButton)`
  146. width: 40px;
  147. height: 40px;
  148. position: absolute;
  149. top: 10px;
  150. right: 10px;
  151. background-color: ${selectedTheme.primaryPurple};
  152. border-radius: 100%;
  153. padding-top: 2px;
  154. text-align: center;
  155. @media (max-width: 600px) {
  156. width: 32px;
  157. height: 32px;
  158. & button svg {
  159. width: 16px;
  160. height: 16px;
  161. position: relative;
  162. top: -4px;
  163. left: -2px;
  164. }
  165. }
  166. `;
  167. export const UserIconContainer = styled(MessageIcon)`
  168. background-color: ${selectedTheme.primaryIconBackgroundColor};
  169. `
  170. export const UserIcon = styled(User)`
  171. `