@liner-fe/prism 2.1.31 → 2.1.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (276) hide show
  1. package/lib/components/Icon/index.d.ts +2 -1
  2. package/lib/components/IconButton/index.d.ts +1 -1
  3. package/lib/components/Illust/index.d.ts +12 -12
  4. package/lib/components/Label/index.d.ts +1 -1
  5. package/lib/components/Snackbar/SnackbarButton/index.d.ts +10 -0
  6. package/lib/components/Snackbar/SnackbarClose/index.d.ts +7 -0
  7. package/lib/components/Snackbar/SnackbarDescription/index.d.ts +5 -0
  8. package/lib/components/Snackbar/SnackbarIcon/index.d.ts +6 -0
  9. package/lib/components/Snackbar/SnackbarTitle/index.d.ts +5 -0
  10. package/lib/components/Snackbar/index.d.ts +3 -0
  11. package/lib/components/TextButton/index.d.ts +1 -1
  12. package/lib/components/Toast/export.d.ts +1 -1
  13. package/lib/components/Typography/Set/Heading.d.ts +3 -3
  14. package/lib/components/Typography/types.d.ts +8 -1
  15. package/lib/constants/illust/name.d.ts +2 -1
  16. package/lib/constants/illust/path.d.ts +3 -0
  17. package/lib/constants/illust/size.d.ts +2 -2
  18. package/lib/hooks/useIllust.d.ts +9 -0
  19. package/lib/hooks/useSnackbar.d.ts +5 -0
  20. package/lib/hooks/useToast.d.ts +9 -0
  21. package/lib/illust.d.ts +1 -0
  22. package/lib/illust.js +64 -26
  23. package/lib/illust.js.map +3 -3
  24. package/lib/index.cjs +45 -49
  25. package/lib/index.cjs.map +4 -4
  26. package/lib/index.mjs +45 -49
  27. package/lib/index.mjs.map +4 -4
  28. package/lib/static/illust/dark/object-bomb-1_1.webp +0 -0
  29. package/lib/static/illust/dark/object-brain-1_1.webp +0 -0
  30. package/lib/static/illust/dark/object-clap-1_1.webp +0 -0
  31. package/lib/static/illust/dark/object-documents_02-1_1.webp +0 -0
  32. package/lib/static/illust/dark/object-empty_box-1_1.webp +0 -0
  33. package/lib/static/illust/dark/object-empty_box-4_3.webp +0 -0
  34. package/lib/static/illust/dark/object-folder_01-1_1.webp +0 -0
  35. package/lib/static/illust/dark/object-folder_02-1_1.webp +0 -0
  36. package/lib/static/illust/dark/object-free_ticket-1_1.webp +0 -0
  37. package/lib/static/illust/dark/object-gift-1_1.webp +0 -0
  38. package/lib/static/illust/dark/object-give_gift-1_1.webp +0 -0
  39. package/lib/static/illust/dark/object-graduation_cap_pencil-4_3.webp +0 -0
  40. package/lib/static/illust/dark/object-lock-4_3.webp +0 -0
  41. package/lib/static/illust/dark/object-magnifying_glass-1_1.webp +0 -0
  42. package/lib/static/illust/dark/object-magnifying_glass-4_3.webp +0 -0
  43. package/lib/static/illust/dark/object-megaphone-1_1.webp +0 -0
  44. package/lib/static/illust/dark/object-paper-1_1.webp +0 -0
  45. package/lib/static/illust/dark/object-pencil_paper-16_9.webp +0 -0
  46. package/lib/static/illust/dark/object-puzzle-4_3.webp +0 -0
  47. package/lib/static/illust/dark/object-smoke-16_9.webp +0 -0
  48. package/lib/static/illust/dark/object_documents_01-1_1.webp +0 -0
  49. package/lib/static/illust/dark/object_find_man-1_1.webp +0 -0
  50. package/lib/static/illust/dark/person-bye-4_3.webp +0 -0
  51. package/lib/static/illust/dark/person-holding_a_book-1_1.webp +0 -0
  52. package/lib/static/illust/dark/person-introduce-1_1.webp +0 -0
  53. package/lib/static/illust/dark/person-introduce-pro-1_1.webp +0 -0
  54. package/lib/static/illust/dark/person-make_profile-1_1.webp +0 -0
  55. package/lib/static/illust/dark/person-raining-1_1.webp +0 -0
  56. package/lib/static/illust/dark/person-searching-16_9.webp +0 -0
  57. package/lib/static/illust/dark/person-searching_01-1_1.webp +0 -0
  58. package/lib/static/illust/dark/person-searching_01-4_3.webp +0 -0
  59. package/lib/static/illust/dark/person-searching_02-1_1.webp +0 -0
  60. package/lib/static/illust/dark/person-space_in_work-4_3.webp +0 -0
  61. package/lib/static/illust/dark/person-standing_with_a_star-16_9.webp +0 -0
  62. package/lib/static/illust/dark/person-time_out_01-1_1.webp +0 -0
  63. package/lib/static/illust/dark/person-time_out_02-1_1.webp +0 -0
  64. package/lib/static/illust/dark/person-time_out_03-1_1.webp +0 -0
  65. package/lib/static/illust/dark/person-time_out_04-1_1.webp +0 -0
  66. package/lib/static/illust/dark/person-time_out_05-1_1.webp +0 -0
  67. package/lib/static/illust/dark/person-working_01-4_3.webp +0 -0
  68. package/lib/static/illust/dark/person-worried-1_1.webp +0 -0
  69. package/lib/static/illust/dark/person-worried_01-4_3.webp +0 -0
  70. package/lib/static/illust/dark/person-worried_02-4_3.webp +0 -0
  71. package/lib/static/illust/dark/person-worried_03-4_3.webp +0 -0
  72. package/lib/static/illust/dark/person-worried_04-4_3.webp +0 -0
  73. package/lib/static/illust/dark/person-writing_01-1_1.webp +0 -0
  74. package/lib/static/illust/light/object-bomb-1_1.webp +0 -0
  75. package/lib/static/illust/light/object-book_pencil-4_3.webp +0 -0
  76. package/lib/static/illust/light/object-brain-1_1.webp +0 -0
  77. package/lib/static/illust/light/object-clap-1_1.webp +0 -0
  78. package/lib/static/illust/light/object-documents_02-1_1.webp +0 -0
  79. package/lib/static/illust/light/object-empty_box-1_1.webp +0 -0
  80. package/lib/static/illust/light/object-empty_box-4_3.webp +0 -0
  81. package/lib/static/illust/light/object-feather_pen-1_1.webp +0 -0
  82. package/lib/static/illust/light/object-folder_01-1_1.webp +0 -0
  83. package/lib/static/illust/light/object-folder_02-1_1.webp +0 -0
  84. package/lib/static/illust/light/object-free_ticket-1_1.webp +0 -0
  85. package/lib/static/illust/light/object-gift-1_1.webp +0 -0
  86. package/lib/static/illust/light/object-give_gift-1_1.webp +0 -0
  87. package/lib/static/illust/light/object-graduation_cap_pencil-4_3.webp +0 -0
  88. package/lib/static/illust/light/object-lock-4_3.webp +0 -0
  89. package/lib/static/illust/light/object-magnifying_glass-1_1.webp +0 -0
  90. package/lib/static/illust/light/object-magnifying_glass-4_3.webp +0 -0
  91. package/lib/static/illust/light/object-megaphone-1_1.webp +0 -0
  92. package/lib/static/illust/light/object-paper-1_1.webp +0 -0
  93. package/lib/static/illust/light/object-pencil_paper-16_9.webp +0 -0
  94. package/lib/static/illust/light/object-puzzle-4_3.webp +0 -0
  95. package/lib/static/illust/light/object-smoke-16_9.webp +0 -0
  96. package/lib/static/illust/light/object-university_01-1_1.webp +0 -0
  97. package/lib/static/illust/light/object-university_02-1_1.webp +0 -0
  98. package/lib/static/illust/light/object_documents_01-1_1.webp +0 -0
  99. package/lib/static/illust/light/object_find_man-1_1.webp +0 -0
  100. package/lib/static/illust/light/person-ai_writing-1_1.webp +0 -0
  101. package/lib/static/illust/light/person-bye-4_3.webp +0 -0
  102. package/lib/static/illust/light/person-cheerup-16_9.webp +0 -0
  103. package/lib/static/illust/light/person-cheerup-4_3.webp +0 -0
  104. package/lib/static/illust/light/person-holding_a_book-1_1.webp +0 -0
  105. package/lib/static/illust/light/person-introduce-1_1.webp +0 -0
  106. package/lib/static/illust/light/person-introduce-pro-1_1.webp +0 -0
  107. package/lib/static/illust/light/person-make_profile-1_1.webp +0 -0
  108. package/lib/static/illust/light/person-raining-1_1.webp +0 -0
  109. package/lib/static/illust/light/person-searching-16_9.webp +0 -0
  110. package/lib/static/illust/light/person-searching_01-1_1.webp +0 -0
  111. package/lib/static/illust/light/person-searching_01-4_3.webp +0 -0
  112. package/lib/static/illust/light/person-searching_02-1_1.webp +0 -0
  113. package/lib/static/illust/light/person-space_in_work-4_3.webp +0 -0
  114. package/lib/static/illust/light/person-standing_with_a_star-16_9.webp +0 -0
  115. package/lib/static/illust/light/person-time_out_01-1_1.webp +0 -0
  116. package/lib/static/illust/light/person-time_out_02-1_1.webp +0 -0
  117. package/lib/static/illust/light/person-time_out_03-1_1.webp +0 -0
  118. package/lib/static/illust/light/person-time_out_04-1_1.webp +0 -0
  119. package/lib/static/illust/light/person-time_out_05-1_1.webp +0 -0
  120. package/lib/static/illust/light/person-understand-1_1.webp +0 -0
  121. package/lib/static/illust/light/person-working_01-4_3.webp +0 -0
  122. package/lib/static/illust/light/person-working_02-4_3.webp +0 -0
  123. package/lib/static/illust/light/person-worried-1_1.webp +0 -0
  124. package/lib/static/illust/light/person-worried_01-4_3.webp +0 -0
  125. package/lib/static/illust/light/person-worried_02-4_3.webp +0 -0
  126. package/lib/static/illust/light/person-worried_03-4_3.webp +0 -0
  127. package/lib/static/illust/light/person-worried_04-4_3.webp +0 -0
  128. package/lib/static/illust/light/person-writing_01-1_1.webp +0 -0
  129. package/lib/static/illust/light/person-writing_02-1_1.webp +0 -0
  130. package/lib/types/generateRandomId.d.ts +1 -0
  131. package/lib/types/illust.d.ts +4 -1
  132. package/lib/types/snackbar.d.ts +38 -0
  133. package/lib/types/typescript.d.ts +4 -0
  134. package/lib/utils/illust.d.ts +5 -0
  135. package/lib/utils/object.d.ts +1 -1
  136. package/package.json +10 -3
  137. package/lib/components/Toast/hooks/useToast.d.ts +0 -11
  138. package/lib/static/illust/dark/rectangle_searching.webp +0 -0
  139. package/lib/static/illust/dark/rectangle_space_work.webp +0 -0
  140. package/lib/static/illust/dark/rectangle_standing_with_a_star.webp +0 -0
  141. package/lib/static/illust/dark/square_bomb_timeout.webp +0 -0
  142. package/lib/static/illust/dark/square_brain_deep_q_a.webp +0 -0
  143. package/lib/static/illust/dark/square_bye_end_custom_AI.webp +0 -0
  144. package/lib/static/illust/dark/square_clap.webp +0 -0
  145. package/lib/static/illust/dark/square_documents_reliable_citation.webp +0 -0
  146. package/lib/static/illust/dark/square_documents_reliable_source.webp +0 -0
  147. package/lib/static/illust/dark/square_empty_box.webp +0 -0
  148. package/lib/static/illust/dark/square_empty_box_2.webp +0 -0
  149. package/lib/static/illust/dark/square_find_man.webp +0 -0
  150. package/lib/static/illust/dark/square_folder_01.webp +0 -0
  151. package/lib/static/illust/dark/square_folder_02.webp +0 -0
  152. package/lib/static/illust/dark/square_free_ticket_welcome.webp +0 -0
  153. package/lib/static/illust/dark/square_gift_welcome.webp +0 -0
  154. package/lib/static/illust/dark/square_give_gift.webp +0 -0
  155. package/lib/static/illust/dark/square_holding_a_book_onboarding.webp +0 -0
  156. package/lib/static/illust/dark/square_introduce.webp +0 -0
  157. package/lib/static/illust/dark/square_introduce_pro.webp +0 -0
  158. package/lib/static/illust/dark/square_lock_locked_thread.webp +0 -0
  159. package/lib/static/illust/dark/square_magnifying_glass.webp +0 -0
  160. package/lib/static/illust/dark/square_magnifying_glass_not_found.webp +0 -0
  161. package/lib/static/illust/dark/square_make_profile_onboarding.webp +0 -0
  162. package/lib/static/illust/dark/square_paper.webp +0 -0
  163. package/lib/static/illust/dark/square_pencil_paper_empty_history.webp +0 -0
  164. package/lib/static/illust/dark/square_raining_error.webp +0 -0
  165. package/lib/static/illust/dark/square_searching_01.webp +0 -0
  166. package/lib/static/illust/dark/square_searching_02.webp +0 -0
  167. package/lib/static/illust/dark/square_searching_03.webp +0 -0
  168. package/lib/static/illust/dark/square_smoke_timeout.webp +0 -0
  169. package/lib/static/illust/dark/square_time_out.webp +0 -0
  170. package/lib/static/illust/dark/square_time_out_time_out_01.webp +0 -0
  171. package/lib/static/illust/dark/square_time_out_time_out_02.webp +0 -0
  172. package/lib/static/illust/dark/square_time_out_time_out_03.webp +0 -0
  173. package/lib/static/illust/dark/square_time_out_time_out_04.webp +0 -0
  174. package/lib/static/illust/dark/square_working_01.webp +0 -0
  175. package/lib/static/illust/dark/square_worried_01.webp +0 -0
  176. package/lib/static/illust/dark/square_worried_02.webp +0 -0
  177. package/lib/static/illust/dark/square_worried_03.webp +0 -0
  178. package/lib/static/illust/dark/square_worried_04.webp +0 -0
  179. package/lib/static/illust/dark/square_worried_05.webp +0 -0
  180. package/lib/static/illust/dark/square_writing_onboarding.webp +0 -0
  181. package/lib/static/illust/light/rectangle_cheerup_01.webp +0 -0
  182. package/lib/static/illust/light/rectangle_cheerup_02.webp +0 -0
  183. package/lib/static/illust/light/rectangle_searching.webp +0 -0
  184. package/lib/static/illust/light/rectangle_space_work.webp +0 -0
  185. package/lib/static/illust/light/rectangle_standing_with_a_star.webp +0 -0
  186. package/lib/static/illust/light/square_ai_writing_essay_mode.webp +0 -0
  187. package/lib/static/illust/light/square_bomb_timeout.webp +0 -0
  188. package/lib/static/illust/light/square_book_pencil_general_mode.webp +0 -0
  189. package/lib/static/illust/light/square_brain_deep_q_a.webp +0 -0
  190. package/lib/static/illust/light/square_bye_end_custom_ai.webp +0 -0
  191. package/lib/static/illust/light/square_clap.webp +0 -0
  192. package/lib/static/illust/light/square_documents_reliable_citation.webp +0 -0
  193. package/lib/static/illust/light/square_documents_reliable_source.webp +0 -0
  194. package/lib/static/illust/light/square_empty_box_2.webp +0 -0
  195. package/lib/static/illust/light/square_empty_box_empty_page.webp +0 -0
  196. package/lib/static/illust/light/square_feather_pen.webp +0 -0
  197. package/lib/static/illust/light/square_find_man.webp +0 -0
  198. package/lib/static/illust/light/square_find_paper_use_liner.webp +0 -0
  199. package/lib/static/illust/light/square_folder_01.webp +0 -0
  200. package/lib/static/illust/light/square_folder_02.webp +0 -0
  201. package/lib/static/illust/light/square_free_ticket_welcome.webp +0 -0
  202. package/lib/static/illust/light/square_gift_welcome.webp +0 -0
  203. package/lib/static/illust/light/square_give_gift.webp +0 -0
  204. package/lib/static/illust/light/square_graduation_cap_pencil_scholar_mode.webp +0 -0
  205. package/lib/static/illust/light/square_holding_a_book_onboarding.webp +0 -0
  206. package/lib/static/illust/light/square_introduce.webp +0 -0
  207. package/lib/static/illust/light/square_introduce_pro.webp +0 -0
  208. package/lib/static/illust/light/square_lock_locked_thread.webp +0 -0
  209. package/lib/static/illust/light/square_magnifying_glass.webp +0 -0
  210. package/lib/static/illust/light/square_magnifying_glass_not_found.webp +0 -0
  211. package/lib/static/illust/light/square_make_profile_onboarding.webp +0 -0
  212. package/lib/static/illust/light/square_megaphone.webp +0 -0
  213. package/lib/static/illust/light/square_paper.webp +0 -0
  214. package/lib/static/illust/light/square_pencil_paper_empty_history.webp +0 -0
  215. package/lib/static/illust/light/square_raining_error.webp +0 -0
  216. package/lib/static/illust/light/square_searching_01.webp +0 -0
  217. package/lib/static/illust/light/square_searching_02.webp +0 -0
  218. package/lib/static/illust/light/square_searching_03.webp +0 -0
  219. package/lib/static/illust/light/square_smoke_timeout.webp +0 -0
  220. package/lib/static/illust/light/square_time_out.webp +0 -0
  221. package/lib/static/illust/light/square_time_out_time_out_01.webp +0 -0
  222. package/lib/static/illust/light/square_time_out_time_out_02.webp +0 -0
  223. package/lib/static/illust/light/square_time_out_time_out_03.webp +0 -0
  224. package/lib/static/illust/light/square_time_out_time_out_04.webp +0 -0
  225. package/lib/static/illust/light/square_understand_concepts_use_liner.webp +0 -0
  226. package/lib/static/illust/light/square_university_01.webp +0 -0
  227. package/lib/static/illust/light/square_university_02.webp +0 -0
  228. package/lib/static/illust/light/square_working_01.webp +0 -0
  229. package/lib/static/illust/light/square_worried_01.webp +0 -0
  230. package/lib/static/illust/light/square_worried_02.webp +0 -0
  231. package/lib/static/illust/light/square_worried_03.webp +0 -0
  232. package/lib/static/illust/light/square_worried_04.webp +0 -0
  233. package/lib/static/illust/light/square_worried_05.webp +0 -0
  234. package/lib/static/illust/light/square_write_essay_use_liner.webp +0 -0
  235. package/lib/static/illust/light/square_writing.webp +0 -0
  236. package/lib/static/illust/light/square_writing_essay_mode.webp +0 -0
  237. /package/lib/static/illust/dark/{square_pricing_page_airplane.webp → decoration-airplane-1_1.webp} +0 -0
  238. /package/lib/static/illust/dark/{square_decoration_bulb.webp → decoration-bulb-1_1.webp} +0 -0
  239. /package/lib/static/illust/dark/{square_pricing_page_car.webp → decoration-car-1_1.webp} +0 -0
  240. /package/lib/static/illust/dark/{square_pricing_page_flag.webp → decoration-flag-1_1.webp} +0 -0
  241. /package/lib/static/illust/dark/{square_decoration_hourglass.webp → decoration-hourglass-1_1.webp} +0 -0
  242. /package/lib/static/illust/dark/{square_pricing_page_rocket.webp → decoration-rocket-1_1.webp} +0 -0
  243. /package/lib/static/illust/dark/{square_decoration_star_01.webp → decoration-star_01-1_1.webp} +0 -0
  244. /package/lib/static/illust/dark/{square_decoration_star_02.webp → decoration-star_02-1_1.webp} +0 -0
  245. /package/lib/static/illust/dark/{square_decoration_star_03.webp → decoration-star_03-1_1.webp} +0 -0
  246. /package/lib/static/illust/dark/{square_decoration_star_04.webp → decoration-star_04-1_1.webp} +0 -0
  247. /package/lib/static/illust/dark/{square_decoration_star_05.webp → decoration-star_05-1_1.webp} +0 -0
  248. /package/lib/static/illust/dark/{square_decoration_star_06.webp → decoration-star_06-1_1.webp} +0 -0
  249. /package/lib/static/illust/dark/{square_decoration_star_07.webp → decoration-star_07-1_1.webp} +0 -0
  250. /package/lib/static/illust/dark/{square_decoration_star_08.webp → decoration-star_08-1_1.webp} +0 -0
  251. /package/lib/static/illust/dark/{square_decoration_star_09.webp → decoration-star_09-1_1.webp} +0 -0
  252. /package/lib/static/illust/dark/{square_decoration_star_10.webp → decoration-star_10-1_1.webp} +0 -0
  253. /package/lib/static/illust/dark/{square_decoration_star_11.webp → decoration-star_11-1_1.webp} +0 -0
  254. /package/lib/static/illust/light/{square_pricing_page_airplane.webp → decoration-airplane-1_1.webp} +0 -0
  255. /package/lib/static/illust/light/{square_decoration_bulb.webp → decoration-bulb-1_1.webp} +0 -0
  256. /package/lib/static/illust/light/{square_pricing_page_car.webp → decoration-car-1_1.webp} +0 -0
  257. /package/lib/static/illust/light/{square_careers_page_coffee.webp → decoration-coffee-1_1.webp} +0 -0
  258. /package/lib/static/illust/light/{square_careers_page_english.webp → decoration-english-1_1.webp} +0 -0
  259. /package/lib/static/illust/light/{square_pricing_page_flag.webp → decoration-flag-1_1.webp} +0 -0
  260. /package/lib/static/illust/light/{square_decoration_hourglass.webp → decoration-hourglass-1_1.webp} +0 -0
  261. /package/lib/static/illust/light/{square_careers_page_money.webp → decoration-money-1_1.webp} +0 -0
  262. /package/lib/static/illust/light/{square_careers_page_palm.webp → decoration-palm-1_1.webp} +0 -0
  263. /package/lib/static/illust/light/{square_pricing_page_rocket.webp → decoration-rocket-1_1.webp} +0 -0
  264. /package/lib/static/illust/light/{square_careers_page_shake_hands.webp → decoration-shake_hands-1_1.webp} +0 -0
  265. /package/lib/static/illust/light/{square_decoration_star_01.webp → decoration-star_01-1_1.webp} +0 -0
  266. /package/lib/static/illust/light/{square_decoration_star_02.webp → decoration-star_02-1_1.webp} +0 -0
  267. /package/lib/static/illust/light/{square_decoration_star_03.webp → decoration-star_03-1_1.webp} +0 -0
  268. /package/lib/static/illust/light/{square_decoration_star_04.webp → decoration-star_04-1_1.webp} +0 -0
  269. /package/lib/static/illust/light/{square_decoration_star_05.webp → decoration-star_05-1_1.webp} +0 -0
  270. /package/lib/static/illust/light/{square_decoration_star_06.webp → decoration-star_06-1_1.webp} +0 -0
  271. /package/lib/static/illust/light/{square_decoration_star_07.webp → decoration-star_07-1_1.webp} +0 -0
  272. /package/lib/static/illust/light/{square_decoration_star_08.webp → decoration-star_08-1_1.webp} +0 -0
  273. /package/lib/static/illust/light/{square_decoration_star_09.webp → decoration-star_09-1_1.webp} +0 -0
  274. /package/lib/static/illust/light/{square_decoration_star_10.webp → decoration-star_10-1_1.webp} +0 -0
  275. /package/lib/static/illust/light/{square_decoration_star_11.webp → decoration-star_11-1_1.webp} +0 -0
  276. /package/lib/static/illust/light/{square_careers_page_tennis.webp → decoration-tennis-1_1.webp} +0 -0
@@ -2,6 +2,7 @@ import { VariantProps } from 'cva';
2
2
  import { IconKey, IconMapType } from '../../type';
3
3
  import { SystemKeys } from '@liner-fe/design-token';
4
4
  import { BasicColorType } from '../../types/color';
5
+ import { SVGProps } from 'react';
5
6
  declare const iconSizeMap: {
6
7
  readonly xs: 16;
7
8
  readonly s: 20;
@@ -24,7 +25,7 @@ declare const iconVariants: (props?: ({
24
25
  export declare const getIconComponent: (iconKey: IconKey, map: IconMapType) => import("../../type").IconComponent;
25
26
  export type IconSizeKey = keyof typeof iconSizeMap;
26
27
  export type IconColorType = Extract<SystemKeys, BasicColorType>;
27
- export interface IconProps extends VariantProps<typeof iconVariants> {
28
+ export interface IconProps extends VariantProps<typeof iconVariants>, Omit<SVGProps<SVGSVGElement>, 'fill'> {
28
29
  name: IconKey;
29
30
  type?: IconColorType;
30
31
  fillType?: IconColorType;
@@ -2,7 +2,7 @@ import { VariantProps } from 'cva';
2
2
  import { ButtonHTMLAttributes } from 'react';
3
3
  import { IconProps } from '../Icon';
4
4
  declare const iconButtonVariants: (props?: ({
5
- level?: "primary" | "secondary" | "tertiary" | "quaternary" | "negative" | "static" | "inverse" | "inverse-static" | undefined;
5
+ level?: "inverse" | "primary" | "secondary" | "tertiary" | "quaternary" | "negative" | "static" | "inverse-static" | undefined;
6
6
  size?: "m" | "s" | "xs" | "l" | undefined;
7
7
  fill?: boolean | undefined;
8
8
  } & ({
@@ -1,17 +1,17 @@
1
- import { IllustName } from '../../types/illust';
2
- import { Property } from 'csstype';
3
1
  import { ImageProps } from 'next/image';
4
- interface IProps extends Omit<ImageProps, 'alt' | 'width' | 'height' | 'fill'> {
5
- src: IllustName;
6
- isOnlyLight?: boolean;
2
+ import { IllustType } from '../../types/illust';
3
+ import { Property } from 'csstype';
4
+ export interface Source<T extends false | true = true> {
5
+ name: IllustType;
6
+ inverse?: T;
7
+ }
8
+ interface IProps extends Omit<ImageProps, 'alt' | 'width' | 'height' | 'fill' | 'src'> {
7
9
  width: number;
8
- height: number;
9
- justifyContent?: Property.JustifyContent;
10
- alignItems?: Property.AlignItems;
10
+ src: {
11
+ light: Source<false>;
12
+ dark?: Source;
13
+ };
14
+ margin?: Property.Margin<string>;
11
15
  }
12
16
  export declare const Illust: (props: IProps) => import("react/jsx-runtime").JSX.Element;
13
- export declare const prefetchIllust: ({ name, isDark }: {
14
- name: IllustName;
15
- isDark?: boolean;
16
- }) => Promise<Response>;
17
17
  export {};
@@ -3,7 +3,7 @@ import * as LabelPrimitive from '@radix-ui/react-label';
3
3
  import { VariantProps } from 'cva';
4
4
  declare const defaultLabelVariants: (props?: ({
5
5
  level?: "primary" | "secondary" | undefined;
6
- position?: "right" | "top" | undefined;
6
+ position?: "top" | "right" | undefined;
7
7
  size?: "m" | "s" | "l" | undefined;
8
8
  offset?: "high" | "low" | "medium" | undefined;
9
9
  disabled?: boolean | undefined;
@@ -0,0 +1,10 @@
1
+ import { ButtonType } from '../../../types/snackbar';
2
+ interface SnackbarButtonProps {
3
+ button?: {
4
+ text?: ButtonType;
5
+ basic?: ButtonType;
6
+ };
7
+ containerStyle?: string;
8
+ }
9
+ export declare const SnackbarButton: ({ button, containerStyle }: SnackbarButtonProps) => import("react/jsx-runtime").JSX.Element | null;
10
+ export {};
@@ -0,0 +1,7 @@
1
+ import { IconButtonProps } from '../../../components/IconButton';
2
+ import { StrictOmit } from '../../../types/typescript';
3
+ interface SnackbarCloseProps extends StrictOmit<IconButtonProps, 'icon' | 'level' | 'size' | 'fill' | 'onClick'> {
4
+ onCloseSnackbar: () => void;
5
+ }
6
+ export declare const SnackbarClose: ({ onCloseSnackbar, className }: SnackbarCloseProps) => import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,5 @@
1
+ interface SnackbarDescriptionProps {
2
+ description?: string;
3
+ }
4
+ export declare const SnackbarDescription: ({ description }: SnackbarDescriptionProps) => import("react/jsx-runtime").JSX.Element | null;
5
+ export {};
@@ -0,0 +1,6 @@
1
+ import { IconProps } from '../../../components/Icon';
2
+ interface SnackbarIconProps {
3
+ icon?: Pick<IconProps, 'name' | 'fill' | 'thick'>;
4
+ }
5
+ export declare const SnackbarIcon: (props: SnackbarIconProps) => import("react/jsx-runtime").JSX.Element | null;
6
+ export {};
@@ -0,0 +1,5 @@
1
+ interface SnackbarTitleProps {
2
+ title: string;
3
+ }
4
+ export declare const SnackbarTitle: ({ title }: SnackbarTitleProps) => import("react/jsx-runtime").JSX.Element;
5
+ export {};
@@ -0,0 +1,3 @@
1
+ import { SnackbarPropWithId } from '../../types/snackbar';
2
+ export declare const Snackbar: () => import("react/jsx-runtime").JSX.Element;
3
+ export declare const SingleSnackbar: (props: SnackbarPropWithId) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { ButtonIconProps, ButtonSizeType, CommonButtonProps } from '../../index';
2
2
  import { VariantProps } from 'cva';
3
3
  declare const textButtonVariants: (props?: ({
4
- level?: "primary" | "secondary" | "tertiary" | "inverse" | "inverse-static" | undefined;
4
+ level?: "inverse" | "primary" | "secondary" | "tertiary" | "inverse-static" | undefined;
5
5
  size?: "m" | "s" | undefined;
6
6
  thick?: boolean | undefined;
7
7
  underline?: boolean | undefined;
@@ -1,2 +1,2 @@
1
- export { useToast } from './hooks/useToast';
1
+ export { useToast } from '../../hooks/useToast';
2
2
  export { Toaster } from './index';
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
- import { ITypographyCommon } from '../types';
3
- export interface IHeadingProps extends ITypographyCommon<HTMLHeadingElement> {
2
+ import { HTMLAsElement, ITypographyCommon } from '../types';
3
+ export interface IHeadingProps extends ITypographyCommon<HTMLAsElement> {
4
4
  type: 'answer';
5
5
  size: 1 | 2 | 3 | 4 | 5 | 6;
6
6
  }
7
- export declare const Heading: React.ForwardRefExoticComponent<IHeadingProps & React.RefAttributes<HTMLHeadingElement>>;
7
+ export declare const Heading: React.ForwardRefExoticComponent<IHeadingProps & React.RefAttributes<HTMLAsElement>>;
@@ -1,6 +1,6 @@
1
1
  import { BasicColorType } from '../../types/color';
2
2
  import { HTMLAttributes } from 'react';
3
- export interface ITypographyCommon<T extends HTMLElement = HTMLParagraphElement> extends Omit<HTMLAttributes<T>, 'color'> {
3
+ export interface ITypographyCommon<T extends HTMLElement = HTMLParagraphElement> extends Omit<HTMLAttributes<T>, 'color'>, WithHTMLAsProps {
4
4
  color?: BasicColorType;
5
5
  }
6
6
  export type BLACK = 'black';
@@ -11,3 +11,10 @@ export type ANSWER = 'answer';
11
11
  export type ACCENT = 'accent';
12
12
  export type NORMAL = 'normal';
13
13
  export type POST = 'post';
14
+ type AcceptAsHTMLTag = 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'header' | 'footer' | 'p' | 'article' | 'body' | 'main' | 'b' | 'blockquote';
15
+ export interface WithHTMLAsProps {
16
+ as?: Extract<keyof HTMLElementTagNameMap, AcceptAsHTMLTag>;
17
+ }
18
+ type HTMLAsElementObject = Pick<HTMLElementTagNameMap, AcceptAsHTMLTag>;
19
+ export type HTMLAsElement = HTMLAsElementObject[keyof HTMLAsElementObject];
20
+ export {};
@@ -1 +1,2 @@
1
- export declare const illustNames: readonly ["rectangle_cheerup_01", "rectangle_cheerup_02", "rectangle_searching", "rectangle_space_work", "rectangle_standing_with_a_star", "square_ai_writing_essay_mode", "square_bomb_timeout", "square_book_pencil_general_mode", "square_brain_deep_q_a", "square_bye_end_custom_ai", "square_careers_page_coffee", "square_careers_page_english", "square_careers_page_money", "square_careers_page_palm", "square_careers_page_shake_hands", "square_careers_page_tennis", "square_clap", "square_decoration_bulb", "square_decoration_hourglass", "square_decoration_star_01", "square_decoration_star_02", "square_decoration_star_03", "square_decoration_star_04", "square_decoration_star_05", "square_decoration_star_06", "square_decoration_star_07", "square_decoration_star_08", "square_decoration_star_09", "square_decoration_star_10", "square_decoration_star_11", "square_documents_reliable_citation", "square_documents_reliable_source", "square_empty_box_2", "square_empty_box_empty_page", "square_feather_pen", "square_find_man", "square_find_paper_use_liner", "square_folder_01", "square_folder_02", "square_free_ticket_welcome", "square_gift_welcome", "square_give_gift", "square_graduation_cap_pencil_scholar_mode", "square_holding_a_book_onboarding", "square_introduce", "square_introduce_pro", "square_lock_locked_thread", "square_magnifying_glass", "square_magnifying_glass_not_found", "square_make_profile_onboarding", "square_megaphone", "square_paper", "square_pencil_paper_empty_history", "square_pricing_page_airplane", "square_pricing_page_car", "square_pricing_page_flag", "square_pricing_page_rocket", "square_raining_error", "square_searching_01", "square_searching_02", "square_searching_03", "square_smoke_timeout", "square_time_out", "square_time_out_time_out_01", "square_time_out_time_out_02", "square_time_out_time_out_03", "square_time_out_time_out_04", "square_understand_concepts_use_liner", "square_university_01", "square_university_02", "square_working_01", "square_worried_01", "square_worried_02", "square_worried_03", "square_worried_04", "square_worried_05", "square_write_essay_use_liner", "square_writing", "square_writing_essay_mode"];
1
+ export declare const illustNames: readonly ["decoration-airplane-1_1", "decoration-bulb-1_1", "decoration-car-1_1", "decoration-coffee-1_1", "decoration-english-1_1", "decoration-flag-1_1", "decoration-hourglass-1_1", "decoration-money-1_1", "decoration-palm-1_1", "decoration-rocket-1_1", "decoration-shake_hands-1_1", "decoration-star_01-1_1", "decoration-star_02-1_1", "decoration-star_03-1_1", "decoration-star_04-1_1", "decoration-star_05-1_1", "decoration-star_06-1_1", "decoration-star_07-1_1", "decoration-star_08-1_1", "decoration-star_09-1_1", "decoration-star_10-1_1", "decoration-star_11-1_1", "decoration-tennis-1_1", "object-bomb-1_1", "object-book_pencil-4_3", "object-brain-1_1", "object-clap-1_1", "object-documents_02-1_1", "object-empty_box-1_1", "object-empty_box-4_3", "object-feather_pen-1_1", "object-folder_01-1_1", "object-folder_02-1_1", "object-free_ticket-1_1", "object-gift-1_1", "object-give_gift-1_1", "object-graduation_cap_pencil-4_3", "object-lock-4_3", "object-magnifying_glass-1_1", "object-magnifying_glass-4_3", "object-megaphone-1_1", "object-paper-1_1", "object-pencil_paper-16_9", "object-puzzle-4_3", "object-smoke-16_9", "object-university_01-1_1", "object-university_02-1_1", "object_documents_01-1_1", "object_find_man-1_1", "person-ai_writing-1_1", "person-bye-4_3", "person-cheerup-16_9", "person-cheerup-4_3", "person-holding_a_book-1_1", "person-introduce-1_1", "person-introduce-pro-1_1", "person-make_profile-1_1", "person-raining-1_1", "person-searching-16_9", "person-searching_01-1_1", "person-searching_01-4_3", "person-searching_02-1_1", "person-space_in_work-4_3", "person-standing_with_a_star-16_9", "person-time_out_01-1_1", "person-time_out_02-1_1", "person-time_out_03-1_1", "person-time_out_04-1_1", "person-time_out_05-1_1", "person-understand-1_1", "person-working_01-4_3", "person-working_02-4_3", "person-worried-1_1", "person-worried_01-4_3", "person-worried_02-4_3", "person-worried_03-4_3", "person-worried_04-4_3", "person-writing_01-1_1", "person-writing_02-1_1"];
2
+ export declare const darkIllustNames: readonly ["decoration-airplane-1_1", "decoration-bulb-1_1", "decoration-car-1_1", "decoration-flag-1_1", "decoration-hourglass-1_1", "decoration-rocket-1_1", "decoration-star_01-1_1", "decoration-star_02-1_1", "decoration-star_03-1_1", "decoration-star_04-1_1", "decoration-star_05-1_1", "decoration-star_06-1_1", "decoration-star_07-1_1", "decoration-star_08-1_1", "decoration-star_09-1_1", "decoration-star_10-1_1", "decoration-star_11-1_1", "object-bomb-1_1", "object-brain-1_1", "object-clap-1_1", "object-documents_02-1_1", "object-empty_box-1_1", "object-empty_box-4_3", "object-folder_01-1_1", "object-folder_02-1_1", "object-free_ticket-1_1", "object-gift-1_1", "object-give_gift-1_1", "object-graduation_cap_pencil-4_3", "object-lock-4_3", "object-magnifying_glass-1_1", "object-magnifying_glass-4_3", "object-megaphone-1_1", "object-paper-1_1", "object-pencil_paper-16_9", "object-puzzle-4_3", "object-smoke-16_9", "object_documents_01-1_1", "object_find_man-1_1", "person-bye-4_3", "person-holding_a_book-1_1", "person-introduce-1_1", "person-introduce-pro-1_1", "person-make_profile-1_1", "person-raining-1_1", "person-searching-16_9", "person-searching_01-1_1", "person-searching_01-4_3", "person-searching_02-1_1", "person-space_in_work-4_3", "person-standing_with_a_star-16_9", "person-time_out_01-1_1", "person-time_out_02-1_1", "person-time_out_03-1_1", "person-time_out_04-1_1", "person-time_out_05-1_1", "person-working_01-4_3", "person-worried-1_1", "person-worried_01-4_3", "person-worried_02-4_3", "person-worried_03-4_3", "person-worried_04-4_3", "person-writing_01-1_1"];
@@ -0,0 +1,3 @@
1
+ export declare const ILLUST = "/illust";
2
+ export declare const DARK_MODE_ILLUST_PREFIX = "/illust/dark/";
3
+ export declare const LIGHT_MODE_ILLUST_PREFIX = "/illust/light/";
@@ -1,5 +1,5 @@
1
- import { IllustName } from '../../types/illust';
2
- export declare const illustSize: Partial<Record<IllustName, {
1
+ import { IllustType } from '../../types/illust';
2
+ export declare const illustSize: Partial<Record<IllustType, {
3
3
  width: number;
4
4
  height: number;
5
5
  }>>;
@@ -0,0 +1,9 @@
1
+ import { Source } from '../illust';
2
+ export declare const useIllust: ({ darkSrc, src }: {
3
+ darkSrc?: Source;
4
+ src: Source<false>;
5
+ }) => {
6
+ sourcePrefix: string;
7
+ currentSourceByColorTheme: import("../types/illust").IllustType;
8
+ isDarkMode: boolean;
9
+ };
@@ -0,0 +1,5 @@
1
+ import { SnackbarProp, SnackbarPropWithId } from '../types/snackbar';
2
+ export declare const snackbarAtom: import("recoil").RecoilState<SnackbarPropWithId[]>;
3
+ export declare const useSnackbar: () => {
4
+ open: (info: SnackbarProp) => void;
5
+ };
@@ -0,0 +1,9 @@
1
+ import { ToastProp } from '../components/Toast';
2
+ import { StrictOmit } from '../types/typescript';
3
+ export declare const toastAtom: import("recoil").RecoilState<ToastProp[]>;
4
+ export declare const useToast: () => {
5
+ open: (toast: StrictOmit<ToastProp, "toastId" | "timer">) => {
6
+ toastId: number;
7
+ };
8
+ endLoading: (toastId: number) => void;
9
+ };
package/lib/illust.d.ts CHANGED
@@ -1 +1,2 @@
1
1
  export * from './components/Illust';
2
+ export * from './utils/illust';
package/lib/illust.js CHANGED
@@ -37,44 +37,82 @@ __export(illust_exports, {
37
37
  module.exports = __toCommonJS(illust_exports);
38
38
 
39
39
  // src/constants/illust/size.ts
40
+ var ratio = { "16:9": { width: 1344, height: 756 }, "4:3": { width: 1008, height: 756 } };
40
41
  var illustSize = {
41
- rectangle_standing_with_a_star: { width: 2422, height: 1282 },
42
- rectangle_space_work: { width: 2422, height: 1282 },
43
- rectangle_searching: { width: 2422, height: 1282 },
44
- rectangle_cheerup_01: { width: 2422, height: 1282 },
45
- rectangle_cheerup_02: { width: 2422, height: 1282 }
42
+ "object-pencil_paper-16_9": ratio["16:9"],
43
+ "object-smoke-16_9": ratio["16:9"],
44
+ "person-standing_with_a_star-16_9": ratio["16:9"],
45
+ "person-searching-16_9": ratio["16:9"],
46
+ "person-cheerup-16_9": ratio["16:9"],
47
+ "object-graduation_cap_pencil-4_3": ratio["4:3"],
48
+ "object-book_pencil-4_3": ratio["4:3"],
49
+ "object-puzzle-4_3": ratio["4:3"],
50
+ "object-magnifying_glass-4_3": ratio["4:3"],
51
+ "object-lock-4_3": ratio["4:3"],
52
+ "object-empty_box-4_3": ratio["4:3"],
53
+ "person-working_01-4_3": ratio["4:3"],
54
+ "person-searching_01-4_3": ratio["4:3"],
55
+ "person-worried_01-4_3": ratio["4:3"],
56
+ "person-worried_02-4_3": ratio["4:3"],
57
+ "person-worried_03-4_3": ratio["4:3"],
58
+ "person-worried_04-4_3": ratio["4:3"],
59
+ "person-working_02-4_3": ratio["4:3"],
60
+ "person-bye-4_3": ratio["4:3"],
61
+ "person-space_in_work-4_3": ratio["4:3"],
62
+ "person-cheerup-4_3": ratio["4:3"]
46
63
  };
47
64
 
48
65
  // src/components/Illust/index.tsx
49
- var import_design_token = require("@liner-fe/design-token");
50
66
  var import_image = __toESM(require("next/image"));
51
- var import_jsx_runtime = require("react/jsx-runtime");
67
+
68
+ // src/constants/illust/path.ts
52
69
  var ILLUST = "/illust";
53
- var Illust = /* @__PURE__ */ __name((props) => {
70
+ var DARK_MODE_ILLUST_PREFIX = `${ILLUST}/dark/`;
71
+ var LIGHT_MODE_ILLUST_PREFIX = `${ILLUST}/light/`;
72
+
73
+ // src/hooks/useIllust.ts
74
+ var import_design_token = require("@liner-fe/design-token");
75
+ var useIllust = /* @__PURE__ */ __name(({ darkSrc, src }) => {
54
76
  const { isDarkMode } = (0, import_design_token.useDarkTheme)();
55
- const { src, isOnlyLight, width, height, justifyContent = "center", alignItems = "center" } = props;
56
- const prefixSrc = (() => {
57
- const darkModeIllust = `${ILLUST}/dark/`;
58
- const lightModeIllust = `${ILLUST}/light/`;
59
- if (isDarkMode && !isOnlyLight) {
60
- return darkModeIllust;
77
+ const sourcePrefix = (() => {
78
+ if (isDarkMode) {
79
+ if (darkSrc?.inverse) {
80
+ return LIGHT_MODE_ILLUST_PREFIX;
81
+ }
82
+ return DARK_MODE_ILLUST_PREFIX;
83
+ }
84
+ if (src.inverse === false) {
85
+ return DARK_MODE_ILLUST_PREFIX;
61
86
  }
62
- return lightModeIllust;
87
+ return LIGHT_MODE_ILLUST_PREFIX;
63
88
  })();
64
- const aspectRatio = illustSize[src] ? illustSize[src].width / illustSize[src].height : void 0;
89
+ const currentSourceByColorTheme = isDarkMode ? darkSrc?.name || src.name : src.name;
90
+ return { sourcePrefix, currentSourceByColorTheme, isDarkMode };
91
+ }, "useIllust");
92
+
93
+ // src/components/Illust/index.tsx
94
+ var import_jsx_runtime = require("react/jsx-runtime");
95
+ var Illust = /* @__PURE__ */ __name((props) => {
96
+ const { src, width, margin } = props;
97
+ const { sourcePrefix, currentSourceByColorTheme } = useIllust({ darkSrc: src.dark, src: src.light });
98
+ const aspectRatio = illustSize[currentSourceByColorTheme] ? illustSize[currentSourceByColorTheme].width / illustSize[currentSourceByColorTheme].height : void 0;
65
99
  const css = {
66
100
  width,
67
- height,
68
- display: "flex",
69
- justifyContent,
70
- alignItems
101
+ margin
71
102
  };
72
- const source = `${prefixSrc}${src}.webp`;
73
- if (aspectRatio) {
74
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { style: css, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_image.default, { alt: src, ...props, src: source, width, height: width / aspectRatio }) });
75
- }
76
- const size = width > height ? height : width;
77
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { style: css, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_image.default, { alt: src, ...props, src: source, width: size, height: size }) });
103
+ const source = `${sourcePrefix}${currentSourceByColorTheme}.webp`;
104
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { style: css, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
105
+ import_image.default,
106
+ {
107
+ alt: currentSourceByColorTheme,
108
+ ...props,
109
+ src: source,
110
+ width,
111
+ height: aspectRatio ? width / aspectRatio : width
112
+ }
113
+ ) });
78
114
  }, "Illust");
115
+
116
+ // src/utils/illust.ts
79
117
  var prefetchIllust = /* @__PURE__ */ __name(async ({ name, isDark = false }) => await fetch(`${ILLUST}${isDark ? "/dark/" : "/light/"}${name}.webp`), "prefetchIllust");
80
118
  //# sourceMappingURL=illust.js.map
package/lib/illust.js.map CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
- "sources": ["../src/illust.ts", "../src/constants/illust/size.ts", "../src/components/Illust/index.tsx"],
4
- "sourcesContent": ["export * from './components/Illust';\n", "import { IllustName } from '@/types/illust';\n\nexport const illustSize: Partial<Record<IllustName, { width: number; height: number }>> = {\n rectangle_standing_with_a_star: { width: 2422, height: 1282 },\n rectangle_space_work: { width: 2422, height: 1282 },\n rectangle_searching: { width: 2422, height: 1282 },\n rectangle_cheerup_01: { width: 2422, height: 1282 },\n rectangle_cheerup_02: { width: 2422, height: 1282 },\n};\n", "import { illustSize } from '@/constants/illust/size';\nimport { IllustName } from '@/types/illust';\nimport { useDarkTheme } from '@liner-fe/design-token';\nimport { Property } from 'csstype';\nimport Image, { ImageProps } from 'next/image';\nimport { CSSProperties } from 'react';\n\ninterface IProps extends Omit<ImageProps, 'alt' | 'width' | 'height' | 'fill'> {\n src: IllustName;\n isOnlyLight?: boolean;\n width: number;\n height: number;\n justifyContent?: Property.JustifyContent;\n alignItems?: Property.AlignItems;\n}\n\nconst ILLUST = '/illust';\n\n// \uB2E4\uD06C\uBAA8\uB4DC \uB9E8 \uCC98\uC74C \uC811\uADFC \uAE5C\uBE61\uC784 \uC774\uC288 \uD574\uACB0\nexport const Illust = (props: IProps) => {\n const { isDarkMode } = useDarkTheme();\n const { src, isOnlyLight, width, height, justifyContent = 'center', alignItems = 'center' } = props;\n\n const prefixSrc = (() => {\n const darkModeIllust = `${ILLUST}/dark/`;\n const lightModeIllust = `${ILLUST}/light/`;\n\n if (isDarkMode && !isOnlyLight) {\n return darkModeIllust;\n }\n\n return lightModeIllust;\n })();\n\n const aspectRatio = illustSize[src] ? illustSize[src].width / illustSize[src].height : undefined;\n\n const css: CSSProperties = {\n width,\n height,\n display: 'flex',\n justifyContent,\n alignItems,\n };\n\n const source = `${prefixSrc}${src}.webp`;\n\n if (aspectRatio) {\n return (\n <div style={css}>\n <Image alt={src} {...props} src={source} width={width} height={width / aspectRatio} />\n </div>\n );\n }\n\n const size = width > height ? height : width;\n\n return (\n <div style={css}>\n <Image alt={src} {...props} src={source} width={size} height={size} />\n </div>\n );\n};\n\nexport const prefetchIllust = async ({ name, isDark = false }: { name: IllustName; isDark?: boolean }) =>\n await fetch(`${ILLUST}${isDark ? '/dark/' : '/light/'}${name}.webp`);\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACEO,IAAM,aAA6E;AAAA,EACxF,gCAAgC,EAAE,OAAO,MAAM,QAAQ,KAAK;AAAA,EAC5D,sBAAsB,EAAE,OAAO,MAAM,QAAQ,KAAK;AAAA,EAClD,qBAAqB,EAAE,OAAO,MAAM,QAAQ,KAAK;AAAA,EACjD,sBAAsB,EAAE,OAAO,MAAM,QAAQ,KAAK;AAAA,EAClD,sBAAsB,EAAE,OAAO,MAAM,QAAQ,KAAK;AACpD;;;ACNA,0BAA6B;AAE7B,mBAAkC;AA6C1B;AAjCR,IAAM,SAAS;AAGR,IAAM,SAAS,wBAAC,UAAkB;AACvC,QAAM,EAAE,WAAW,QAAI,kCAAa;AACpC,QAAM,EAAE,KAAK,aAAa,OAAO,QAAQ,iBAAiB,UAAU,aAAa,SAAS,IAAI;AAE9F,QAAM,aAAa,MAAM;AACvB,UAAM,iBAAiB,GAAG,MAAM;AAChC,UAAM,kBAAkB,GAAG,MAAM;AAEjC,QAAI,cAAc,CAAC,aAAa;AAC9B,aAAO;AAAA,IACT;AAEA,WAAO;AAAA,EACT,GAAG;AAEH,QAAM,cAAc,WAAW,GAAG,IAAI,WAAW,GAAG,EAAE,QAAQ,WAAW,GAAG,EAAE,SAAS;AAEvF,QAAM,MAAqB;AAAA,IACzB;AAAA,IACA;AAAA,IACA,SAAS;AAAA,IACT;AAAA,IACA;AAAA,EACF;AAEA,QAAM,SAAS,GAAG,SAAS,GAAG,GAAG;AAEjC,MAAI,aAAa;AACf,WACE,4CAAC,SAAI,OAAO,KACV,sDAAC,aAAAA,SAAA,EAAM,KAAK,KAAM,GAAG,OAAO,KAAK,QAAQ,OAAc,QAAQ,QAAQ,aAAa,GACtF;AAAA,EAEJ;AAEA,QAAM,OAAO,QAAQ,SAAS,SAAS;AAEvC,SACE,4CAAC,SAAI,OAAO,KACV,sDAAC,aAAAA,SAAA,EAAM,KAAK,KAAM,GAAG,OAAO,KAAK,QAAQ,OAAO,MAAM,QAAQ,MAAM,GACtE;AAEJ,GA1CsB;AA4Cf,IAAM,iBAAiB,8BAAO,EAAE,MAAM,SAAS,MAAM,MAC1D,MAAM,MAAM,GAAG,MAAM,GAAG,SAAS,WAAW,SAAS,GAAG,IAAI,OAAO,GADvC;",
3
+ "sources": ["../src/illust.ts", "../src/constants/illust/size.ts", "../src/components/Illust/index.tsx", "../src/constants/illust/path.ts", "../src/hooks/useIllust.ts", "../src/utils/illust.ts"],
4
+ "sourcesContent": ["export * from './components/Illust';\nexport * from './utils/illust';\n", "import { IllustType } from '@/types/illust';\n\nconst ratio = { '16:9': { width: 1344, height: 756 }, '4:3': { width: 1008, height: 756 } };\n\nexport const illustSize: Partial<Record<IllustType, { width: number; height: number }>> = {\n 'object-pencil_paper-16_9': ratio['16:9'],\n 'object-smoke-16_9': ratio['16:9'],\n 'person-standing_with_a_star-16_9': ratio['16:9'],\n 'person-searching-16_9': ratio['16:9'],\n 'person-cheerup-16_9': ratio['16:9'],\n 'object-graduation_cap_pencil-4_3': ratio['4:3'],\n 'object-book_pencil-4_3': ratio['4:3'],\n 'object-puzzle-4_3': ratio['4:3'],\n 'object-magnifying_glass-4_3': ratio['4:3'],\n 'object-lock-4_3': ratio['4:3'],\n 'object-empty_box-4_3': ratio['4:3'],\n 'person-working_01-4_3': ratio['4:3'],\n 'person-searching_01-4_3': ratio['4:3'],\n 'person-worried_01-4_3': ratio['4:3'],\n 'person-worried_02-4_3': ratio['4:3'],\n 'person-worried_03-4_3': ratio['4:3'],\n 'person-worried_04-4_3': ratio['4:3'],\n 'person-working_02-4_3': ratio['4:3'],\n 'person-bye-4_3': ratio['4:3'],\n 'person-space_in_work-4_3': ratio['4:3'],\n 'person-cheerup-4_3': ratio['4:3'],\n};\n", "import { illustSize } from '@/constants/illust/size';\nimport Image, { ImageProps } from 'next/image';\nimport { CSSProperties } from 'react';\nimport { useIllust } from '@/hooks/useIllust';\nimport { IllustType } from '@/types/illust';\nimport { Property } from 'csstype';\n\nexport interface Source<T extends false | true = true> {\n name: IllustType;\n inverse?: T;\n}\n\ninterface IProps extends Omit<ImageProps, 'alt' | 'width' | 'height' | 'fill' | 'src'> {\n width: number;\n src: { light: Source<false>; dark?: Source };\n margin?: Property.Margin<string>;\n}\n\nexport const Illust = (props: IProps) => {\n const { src, width, margin } = props;\n const { sourcePrefix, currentSourceByColorTheme } = useIllust({ darkSrc: src.dark, src: src.light });\n\n const aspectRatio = illustSize[currentSourceByColorTheme]\n ? illustSize[currentSourceByColorTheme].width / illustSize[currentSourceByColorTheme].height\n : undefined;\n\n const css: CSSProperties = {\n width,\n margin,\n };\n\n const source = `${sourcePrefix}${currentSourceByColorTheme}.webp`;\n\n return (\n <div style={css}>\n <Image\n alt={currentSourceByColorTheme}\n {...props}\n src={source}\n width={width}\n height={aspectRatio ? width / aspectRatio : width}\n />\n </div>\n );\n};\n", "export const ILLUST = '/illust';\n\nexport const DARK_MODE_ILLUST_PREFIX = `${ILLUST}/dark/`;\nexport const LIGHT_MODE_ILLUST_PREFIX = `${ILLUST}/light/`;\n", "import { DARK_MODE_ILLUST_PREFIX, LIGHT_MODE_ILLUST_PREFIX } from '@/constants/illust/path';\nimport { Source } from '@/illust';\nimport { useDarkTheme } from '@liner-fe/design-token';\n\nexport const useIllust = ({ darkSrc, src }: { darkSrc?: Source; src: Source<false> }) => {\n const { isDarkMode } = useDarkTheme();\n\n const sourcePrefix = (() => {\n if (isDarkMode) {\n if (darkSrc?.inverse) {\n return LIGHT_MODE_ILLUST_PREFIX;\n }\n\n return DARK_MODE_ILLUST_PREFIX;\n }\n\n if (src.inverse === false) {\n return DARK_MODE_ILLUST_PREFIX;\n }\n\n return LIGHT_MODE_ILLUST_PREFIX;\n })();\n\n const currentSourceByColorTheme = isDarkMode ? darkSrc?.name || src.name : src.name;\n\n return { sourcePrefix, currentSourceByColorTheme, isDarkMode };\n};\n", "import { ILLUST } from '@/constants/illust/path';\nimport { IllustType } from '@/types/illust';\n\nexport const prefetchIllust = async ({ name, isDark = false }: { name: IllustType; isDark?: boolean }) =>\n await fetch(`${ILLUST}${isDark ? '/dark/' : '/light/'}${name}.webp`);\n"],
5
+ "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACEA,IAAM,QAAQ,EAAE,QAAQ,EAAE,OAAO,MAAM,QAAQ,IAAI,GAAG,OAAO,EAAE,OAAO,MAAM,QAAQ,IAAI,EAAE;AAEnF,IAAM,aAA6E;AAAA,EACxF,4BAA4B,MAAM,MAAM;AAAA,EACxC,qBAAqB,MAAM,MAAM;AAAA,EACjC,oCAAoC,MAAM,MAAM;AAAA,EAChD,yBAAyB,MAAM,MAAM;AAAA,EACrC,uBAAuB,MAAM,MAAM;AAAA,EACnC,oCAAoC,MAAM,KAAK;AAAA,EAC/C,0BAA0B,MAAM,KAAK;AAAA,EACrC,qBAAqB,MAAM,KAAK;AAAA,EAChC,+BAA+B,MAAM,KAAK;AAAA,EAC1C,mBAAmB,MAAM,KAAK;AAAA,EAC9B,wBAAwB,MAAM,KAAK;AAAA,EACnC,yBAAyB,MAAM,KAAK;AAAA,EACpC,2BAA2B,MAAM,KAAK;AAAA,EACtC,yBAAyB,MAAM,KAAK;AAAA,EACpC,yBAAyB,MAAM,KAAK;AAAA,EACpC,yBAAyB,MAAM,KAAK;AAAA,EACpC,yBAAyB,MAAM,KAAK;AAAA,EACpC,yBAAyB,MAAM,KAAK;AAAA,EACpC,kBAAkB,MAAM,KAAK;AAAA,EAC7B,4BAA4B,MAAM,KAAK;AAAA,EACvC,sBAAsB,MAAM,KAAK;AACnC;;;ACzBA,mBAAkC;;;ACD3B,IAAM,SAAS;AAEf,IAAM,0BAA0B,GAAG,MAAM;AACzC,IAAM,2BAA2B,GAAG,MAAM;;;ACDjD,0BAA6B;AAEtB,IAAM,YAAY,wBAAC,EAAE,SAAS,IAAI,MAAgD;AACvF,QAAM,EAAE,WAAW,QAAI,kCAAa;AAEpC,QAAM,gBAAgB,MAAM;AAC1B,QAAI,YAAY;AACd,UAAI,SAAS,SAAS;AACpB,eAAO;AAAA,MACT;AAEA,aAAO;AAAA,IACT;AAEA,QAAI,IAAI,YAAY,OAAO;AACzB,aAAO;AAAA,IACT;AAEA,WAAO;AAAA,EACT,GAAG;AAEH,QAAM,4BAA4B,aAAa,SAAS,QAAQ,IAAI,OAAO,IAAI;AAE/E,SAAO,EAAE,cAAc,2BAA2B,WAAW;AAC/D,GAtByB;;;AF+BnB;AAjBC,IAAM,SAAS,wBAAC,UAAkB;AACvC,QAAM,EAAE,KAAK,OAAO,OAAO,IAAI;AAC/B,QAAM,EAAE,cAAc,0BAA0B,IAAI,UAAU,EAAE,SAAS,IAAI,MAAM,KAAK,IAAI,MAAM,CAAC;AAEnG,QAAM,cAAc,WAAW,yBAAyB,IACpD,WAAW,yBAAyB,EAAE,QAAQ,WAAW,yBAAyB,EAAE,SACpF;AAEJ,QAAM,MAAqB;AAAA,IACzB;AAAA,IACA;AAAA,EACF;AAEA,QAAM,SAAS,GAAG,YAAY,GAAG,yBAAyB;AAE1D,SACE,4CAAC,SAAI,OAAO,KACV;AAAA,IAAC,aAAAA;AAAA,IAAA;AAAA,MACC,KAAK;AAAA,MACJ,GAAG;AAAA,MACJ,KAAK;AAAA,MACL;AAAA,MACA,QAAQ,cAAc,QAAQ,cAAc;AAAA;AAAA,EAC9C,GACF;AAEJ,GA1BsB;;;AGff,IAAM,iBAAiB,8BAAO,EAAE,MAAM,SAAS,MAAM,MAC1D,MAAM,MAAM,GAAG,MAAM,GAAG,SAAS,WAAW,SAAS,GAAG,IAAI,OAAO,GADvC;",
6
6
  "names": ["Image"]
7
7
  }