@lunit/design-system 2.2.0 → 2.2.3

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 (351) hide show
  1. package/.babelrc.json +1 -1
  2. package/README.md +22 -21
  3. package/dist/cjs/components/Alert/index.js +1 -1
  4. package/dist/cjs/components/Alert/index.js.map +1 -1
  5. package/dist/cjs/components/Button/index.js +1 -1
  6. package/dist/cjs/components/Button/index.js.map +1 -1
  7. package/dist/cjs/components/Checkbox/index.js +1 -1
  8. package/dist/cjs/components/Checkbox/index.js.map +1 -1
  9. package/dist/cjs/components/Chip/index.js +1 -1
  10. package/dist/cjs/components/Chip/index.js.map +1 -1
  11. package/dist/cjs/components/DataTable/index.js.map +1 -1
  12. package/dist/cjs/components/DatePicker/index.js.map +1 -1
  13. package/dist/cjs/components/Dialog/index.js +1 -1
  14. package/dist/cjs/components/Dialog/index.js.map +1 -1
  15. package/dist/cjs/components/Dropdown/index.js +1 -1
  16. package/dist/cjs/components/Dropdown/index.js.map +1 -1
  17. package/dist/cjs/components/FormLabel/index.js.map +1 -1
  18. package/dist/cjs/components/Radio/index.js +1 -1
  19. package/dist/cjs/components/Radio/index.js.map +1 -1
  20. package/dist/cjs/components/RadioGroup/index.js.map +1 -1
  21. package/dist/cjs/components/TextField/index.js +1 -1
  22. package/dist/cjs/components/TextField/index.js.map +1 -1
  23. package/dist/cjs/components/Toggle/index.js +1 -1
  24. package/dist/cjs/components/Toggle/index.js.map +1 -1
  25. package/dist/cjs/components/ToggleButton/index.js +1 -1
  26. package/dist/cjs/components/ToggleButton/index.js.map +1 -1
  27. package/dist/cjs/components/Tooltip/index.js.map +1 -1
  28. package/dist/cjs/components/Typography/index.js.map +1 -1
  29. package/dist/cjs/index.js +1 -1
  30. package/dist/cjs/index.js.map +1 -1
  31. package/dist/components/Alert/Alert.js +8 -8
  32. package/dist/components/Alert/Alert.js.map +1 -1
  33. package/dist/components/Alert/Alert.styled.js +26 -26
  34. package/dist/components/Alert/Alert.styled.js.map +1 -1
  35. package/dist/components/Alert/Alert.utils.js +9 -9
  36. package/dist/components/Alert/Alert.utils.js.map +1 -1
  37. package/dist/components/Alert/index.js +1 -1
  38. package/dist/components/Button/Button.js +23 -17
  39. package/dist/components/Button/Button.js.map +1 -1
  40. package/dist/components/Button/Button.styled.js +88 -88
  41. package/dist/components/Button/Button.styled.js.map +1 -1
  42. package/dist/components/Button/index.js +1 -1
  43. package/dist/components/Button/utils/getButtonPaddingBySizeAndKind.js +9 -9
  44. package/dist/components/Button/utils/getButtonPaddingBySizeAndKind.js.map +1 -1
  45. package/dist/components/Button/utils/getHoverStyle.js +1 -1
  46. package/dist/components/Button/utils/getHoverStyle.js.map +1 -1
  47. package/dist/components/Button/utils/getIconButtonPaddingBySizeAndKind.js +6 -12
  48. package/dist/components/Button/utils/getIconButtonPaddingBySizeAndKind.js.map +1 -1
  49. package/dist/components/Checkbox/Checkbox.js +9 -9
  50. package/dist/components/Checkbox/Checkbox.js.map +1 -1
  51. package/dist/components/Checkbox/index.js +1 -1
  52. package/dist/components/Chip/Chip.js +29 -26
  53. package/dist/components/Chip/Chip.js.map +1 -1
  54. package/dist/components/Chip/Chip.styled.js +52 -52
  55. package/dist/components/Chip/Chip.styled.js.map +1 -1
  56. package/dist/components/Chip/consts.js +5 -5
  57. package/dist/components/Chip/index.js +1 -1
  58. package/dist/components/DataTable/DataTable.js +1 -1
  59. package/dist/components/DataTable/index.js +1 -1
  60. package/dist/components/DatePicker/DatePicker.js +1 -1
  61. package/dist/components/DatePicker/index.js +1 -1
  62. package/dist/components/Dialog/Dialog.js +18 -18
  63. package/dist/components/Dialog/Dialog.js.map +1 -1
  64. package/dist/components/Dialog/Dialog.styled.js +90 -90
  65. package/dist/components/Dialog/Dialog.styled.js.map +1 -1
  66. package/dist/components/Dialog/components/DialogAction.js +6 -6
  67. package/dist/components/Dialog/index.js +1 -1
  68. package/dist/components/Dropdown/Dropdown.js +23 -21
  69. package/dist/components/Dropdown/Dropdown.js.map +1 -1
  70. package/dist/components/Dropdown/Dropdown.styled.js +85 -86
  71. package/dist/components/Dropdown/Dropdown.styled.js.map +1 -1
  72. package/dist/components/Dropdown/DropdownItem.js +14 -14
  73. package/dist/components/Dropdown/DropdownItem.js.map +1 -1
  74. package/dist/components/Dropdown/index.js +2 -2
  75. package/dist/components/Dropdown/index.js.map +1 -1
  76. package/dist/components/FormLabel/FormLabel.js +1 -1
  77. package/dist/components/FormLabel/FormLabel.styled.js +2 -2
  78. package/dist/components/FormLabel/FormLabel.styled.js.map +1 -1
  79. package/dist/components/FormLabel/index.js +1 -1
  80. package/dist/components/Radio/Radio.js +8 -8
  81. package/dist/components/Radio/Radio.js.map +1 -1
  82. package/dist/components/Radio/index.js +1 -1
  83. package/dist/components/RadioGroup/index.js +1 -1
  84. package/dist/components/TextField/TextField.js +8 -8
  85. package/dist/components/TextField/TextField.js.map +1 -1
  86. package/dist/components/TextField/TextField.style.js +112 -112
  87. package/dist/components/TextField/TextField.style.js.map +1 -1
  88. package/dist/components/TextField/TextFieldIcon.js +2 -2
  89. package/dist/components/TextField/TextFieldIcon.js.map +1 -1
  90. package/dist/components/TextField/index.js +1 -1
  91. package/dist/components/Toast/Toast.js +13 -13
  92. package/dist/components/Toast/Toast.js.map +1 -1
  93. package/dist/components/Toast/Toast.styled.js +26 -26
  94. package/dist/components/Toast/Toast.utils.js +3 -3
  95. package/dist/components/Toast/Toast.utils.js.map +1 -1
  96. package/dist/components/Toast/index.js +1 -1
  97. package/dist/components/Toggle/Toggle.js +3 -4
  98. package/dist/components/Toggle/Toggle.js.map +1 -1
  99. package/dist/components/Toggle/Toggle.styled.js +30 -30
  100. package/dist/components/Toggle/Toggle.styled.js.map +1 -1
  101. package/dist/components/Toggle/index.js +1 -1
  102. package/dist/components/ToggleButton/ToggleButton.js +6 -6
  103. package/dist/components/ToggleButton/ToggleButton.js.map +1 -1
  104. package/dist/components/ToggleButton/ToggleButton.styled.js +20 -20
  105. package/dist/components/ToggleButton/ToggleButton.styled.js.map +1 -1
  106. package/dist/components/ToggleButton/index.js +1 -1
  107. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.js +2 -2
  108. package/dist/components/ToggleButtonGroup/ToggleButtonGroup.js.map +1 -1
  109. package/dist/components/ToggleButtonGroup/index.js +1 -1
  110. package/dist/components/Tooltip/Tooltip.js +1 -1
  111. package/dist/components/Tooltip/index.js +1 -1
  112. package/dist/components/Typography/Typography.js +1 -1
  113. package/dist/components/Typography/Typography.js.map +1 -1
  114. package/dist/components/Typography/index.js +1 -1
  115. package/dist/foundation/Elevation/index.js +27 -27
  116. package/dist/foundation/Elevation/utils.js +1 -1
  117. package/dist/foundation/Elevation/utils.js.map +1 -1
  118. package/dist/foundation/Typography/index.js +35 -35
  119. package/dist/foundation/Typography/index.js.map +1 -1
  120. package/dist/foundation/Typography/tokens.js +136 -136
  121. package/dist/foundation/Typography/tokens.js.map +1 -1
  122. package/dist/foundation/colors/base/blue.js +12 -12
  123. package/dist/foundation/colors/base/green.js +12 -12
  124. package/dist/foundation/colors/base/grey.js +28 -28
  125. package/dist/foundation/colors/base/index.js +11 -11
  126. package/dist/foundation/colors/base/lunitGreen.js +11 -11
  127. package/dist/foundation/colors/base/lunitTeal.js +12 -12
  128. package/dist/foundation/colors/base/magenta.js +12 -12
  129. package/dist/foundation/colors/base/opacity.js +4 -4
  130. package/dist/foundation/colors/base/orange.js +12 -12
  131. package/dist/foundation/colors/base/purple.js +12 -12
  132. package/dist/foundation/colors/base/red.js +12 -12
  133. package/dist/foundation/colors/base/yellow.js +12 -12
  134. package/dist/foundation/colors/index.js +119 -121
  135. package/dist/foundation/colors/index.js.map +1 -1
  136. package/dist/foundation/colors/token/component.js +184 -212
  137. package/dist/foundation/colors/token/component.js.map +1 -1
  138. package/dist/foundation/colors/token/core.js +112 -133
  139. package/dist/foundation/colors/token/core.js.map +1 -1
  140. package/dist/foundation/colors/token/index.js +2 -2
  141. package/dist/foundation/index.js +5 -5
  142. package/dist/index.js +20 -20
  143. package/dist/theme.js +6 -6
  144. package/dist/types/components/Alert/Alert.d.ts +2 -2
  145. package/dist/types/components/Alert/Alert.styled.d.ts +1 -2
  146. package/dist/types/components/Alert/Alert.types.d.ts +2 -2
  147. package/dist/types/components/Alert/Alert.utils.d.ts +1 -1
  148. package/dist/types/components/Alert/index.d.ts +1 -1
  149. package/dist/types/components/Button/Button.d.ts +1 -1
  150. package/dist/types/components/Button/Button.styled.d.ts +226 -227
  151. package/dist/types/components/Button/Button.types.d.ts +16 -16
  152. package/dist/types/components/Button/index.d.ts +1 -1
  153. package/dist/types/components/Button/utils/getButtonPaddingBySizeAndKind.d.ts +4 -4
  154. package/dist/types/components/Button/utils/getHoverStyle.d.ts +2 -1
  155. package/dist/types/components/Button/utils/getIconButtonPaddingBySizeAndKind.d.ts +4 -4
  156. package/dist/types/components/Checkbox/Checkbox.d.ts +1 -1
  157. package/dist/types/components/Checkbox/index.d.ts +1 -1
  158. package/dist/types/components/Chip/Chip.d.ts +1 -1
  159. package/dist/types/components/Chip/Chip.styled.d.ts +6 -7
  160. package/dist/types/components/Chip/Chip.types.d.ts +15 -14
  161. package/dist/types/components/Chip/index.d.ts +1 -1
  162. package/dist/types/components/DataTable/index.d.ts +1 -1
  163. package/dist/types/components/DatePicker/index.d.ts +1 -1
  164. package/dist/types/components/Dialog/Dialog.d.ts +11 -11
  165. package/dist/types/components/Dialog/Dialog.styled.d.ts +3 -4
  166. package/dist/types/components/Dialog/components/DialogAction.d.ts +2 -2
  167. package/dist/types/components/Dialog/index.d.ts +2 -2
  168. package/dist/types/components/Dropdown/Dropdown.d.ts +2 -2
  169. package/dist/types/components/Dropdown/Dropdown.styled.d.ts +3 -4
  170. package/dist/types/components/Dropdown/Dropdown.types.d.ts +5 -5
  171. package/dist/types/components/Dropdown/DropdownItem.d.ts +3 -3
  172. package/dist/types/components/Dropdown/index.d.ts +3 -3
  173. package/dist/types/components/FormLabel/FormLabel.d.ts +1 -1
  174. package/dist/types/components/FormLabel/index.d.ts +1 -1
  175. package/dist/types/components/Radio/Radio.d.ts +1 -1
  176. package/dist/types/components/Radio/index.d.ts +1 -1
  177. package/dist/types/components/RadioGroup/index.d.ts +1 -1
  178. package/dist/types/components/TextField/TextField.d.ts +2 -2
  179. package/dist/types/components/TextField/TextField.style.d.ts +3 -4
  180. package/dist/types/components/TextField/TextField.types.d.ts +6 -6
  181. package/dist/types/components/TextField/TextFieldIcon.d.ts +2 -2
  182. package/dist/types/components/TextField/index.d.ts +2 -2
  183. package/dist/types/components/Toast/Toast.d.ts +2 -2
  184. package/dist/types/components/Toast/Toast.types.d.ts +3 -3
  185. package/dist/types/components/Toast/Toast.utils.d.ts +1 -1
  186. package/dist/types/components/Toast/index.d.ts +2 -2
  187. package/dist/types/components/Toggle/Toggle.d.ts +1 -1
  188. package/dist/types/components/Toggle/Toggle.styled.d.ts +2 -2
  189. package/dist/types/components/Toggle/Toggle.types.d.ts +3 -3
  190. package/dist/types/components/Toggle/index.d.ts +1 -1
  191. package/dist/types/components/ToggleButton/ToggleButton.d.ts +1 -1
  192. package/dist/types/components/ToggleButton/ToggleButton.styled.d.ts +2 -3
  193. package/dist/types/components/ToggleButton/ToggleButton.types.d.ts +10 -10
  194. package/dist/types/components/ToggleButton/index.d.ts +1 -1
  195. package/dist/types/components/ToggleButtonGroup/ToggleButtonGroup.d.ts +1 -1
  196. package/dist/types/components/ToggleButtonGroup/index.d.ts +1 -1
  197. package/dist/types/components/Tooltip/index.d.ts +1 -1
  198. package/dist/types/components/Typography/Typography.d.ts +6 -6
  199. package/dist/types/components/Typography/index.d.ts +1 -1
  200. package/dist/types/components/index.d.ts +2 -2
  201. package/dist/types/foundation/Elevation/index.d.ts +22 -22
  202. package/dist/types/foundation/Typography/index.d.ts +78 -78
  203. package/dist/types/foundation/Typography/tokens.d.ts +69 -69
  204. package/dist/types/foundation/colors/base/index.d.ts +11 -11
  205. package/dist/types/foundation/colors/index.d.ts +13 -20
  206. package/dist/types/foundation/colors/token/component.d.ts +1 -1
  207. package/dist/types/foundation/colors/token/core.d.ts +1 -1
  208. package/dist/types/foundation/colors/token/index.d.ts +2 -2
  209. package/dist/types/foundation/colors/types.d.ts +0 -7
  210. package/dist/types/foundation/index.d.ts +4 -11
  211. package/dist/types/foundation/spacing.d.ts +1 -1
  212. package/dist/types/index.d.ts +20 -20
  213. package/dist/types/theme.d.ts +1 -1
  214. package/package.json +9 -11
  215. package/src/components/Alert/Alert.styled.ts +39 -49
  216. package/src/components/Alert/Alert.tsx +10 -16
  217. package/src/components/Alert/Alert.types.ts +2 -2
  218. package/src/components/Alert/Alert.utils.ts +13 -22
  219. package/src/components/Alert/index.ts +1 -1
  220. package/src/components/Button/Button.styled.ts +98 -101
  221. package/src/components/Button/Button.tsx +71 -69
  222. package/src/components/Button/Button.types.ts +19 -21
  223. package/src/components/Button/index.ts +1 -1
  224. package/src/components/Button/utils/getButtonPaddingBySizeAndKind.ts +13 -13
  225. package/src/components/Button/utils/getHoverStyle.ts +4 -2
  226. package/src/components/Button/utils/getIconButtonPaddingBySizeAndKind.ts +10 -19
  227. package/src/components/Checkbox/Checkbox.tsx +13 -25
  228. package/src/components/Checkbox/index.ts +1 -1
  229. package/src/components/Chip/Chip.styled.ts +69 -72
  230. package/src/components/Chip/Chip.tsx +33 -55
  231. package/src/components/Chip/Chip.types.ts +17 -25
  232. package/src/components/Chip/consts.ts +5 -5
  233. package/src/components/Chip/index.ts +1 -1
  234. package/src/components/DataTable/DataTable.tsx +2 -2
  235. package/src/components/DataTable/index.ts +1 -1
  236. package/src/components/DatePicker/DatePicker.tsx +2 -2
  237. package/src/components/DatePicker/index.ts +1 -1
  238. package/src/components/Dialog/Dialog.styled.ts +112 -114
  239. package/src/components/Dialog/Dialog.tsx +41 -46
  240. package/src/components/Dialog/components/DialogAction.tsx +8 -8
  241. package/src/components/Dialog/index.ts +3 -3
  242. package/src/components/Dropdown/Dropdown.styled.tsx +88 -89
  243. package/src/components/Dropdown/Dropdown.tsx +29 -30
  244. package/src/components/Dropdown/Dropdown.types.ts +5 -6
  245. package/src/components/Dropdown/DropdownItem.tsx +18 -29
  246. package/src/components/Dropdown/index.ts +3 -7
  247. package/src/components/FormLabel/FormLabel.styled.ts +3 -3
  248. package/src/components/FormLabel/FormLabel.tsx +3 -3
  249. package/src/components/FormLabel/index.ts +1 -1
  250. package/src/components/Radio/Radio.tsx +12 -29
  251. package/src/components/Radio/index.ts +1 -1
  252. package/src/components/RadioGroup/index.ts +1 -1
  253. package/src/components/TextField/TextField.style.ts +123 -132
  254. package/src/components/TextField/TextField.tsx +50 -62
  255. package/src/components/TextField/TextField.types.ts +6 -9
  256. package/src/components/TextField/TextFieldIcon.tsx +4 -7
  257. package/src/components/TextField/index.ts +2 -2
  258. package/src/components/Toast/Toast.styled.ts +26 -26
  259. package/src/components/Toast/Toast.tsx +14 -28
  260. package/src/components/Toast/Toast.types.ts +3 -8
  261. package/src/components/Toast/Toast.utils.ts +5 -8
  262. package/src/components/Toast/index.tsx +2 -2
  263. package/src/components/Toggle/Toggle.styled.ts +31 -32
  264. package/src/components/Toggle/Toggle.tsx +5 -11
  265. package/src/components/Toggle/Toggle.types.ts +3 -3
  266. package/src/components/Toggle/index.ts +1 -1
  267. package/src/components/ToggleButton/ToggleButton.styled.ts +47 -49
  268. package/src/components/ToggleButton/ToggleButton.tsx +91 -97
  269. package/src/components/ToggleButton/ToggleButton.types.ts +10 -10
  270. package/src/components/ToggleButton/index.ts +1 -1
  271. package/src/components/ToggleButtonGroup/ToggleButtonGroup.tsx +3 -8
  272. package/src/components/ToggleButtonGroup/index.tsx +1 -1
  273. package/src/components/Tooltip/Tooltip.tsx +2 -2
  274. package/src/components/Tooltip/index.ts +1 -1
  275. package/src/components/Typography/Typography.tsx +7 -10
  276. package/src/components/Typography/index.ts +1 -1
  277. package/src/components/index.ts +2 -2
  278. package/src/foundation/Elevation/index.ts +27 -27
  279. package/src/foundation/Elevation/utils.ts +14 -8
  280. package/src/foundation/Typography/index.ts +58 -57
  281. package/src/foundation/Typography/tokens.ts +138 -138
  282. package/src/foundation/colors/base/blue.ts +12 -12
  283. package/src/foundation/colors/base/green.ts +12 -12
  284. package/src/foundation/colors/base/grey.ts +28 -28
  285. package/src/foundation/colors/base/index.ts +11 -11
  286. package/src/foundation/colors/base/lunitGreen.ts +11 -11
  287. package/src/foundation/colors/base/lunitTeal.ts +12 -12
  288. package/src/foundation/colors/base/magenta.ts +12 -12
  289. package/src/foundation/colors/base/opacity.ts +4 -4
  290. package/src/foundation/colors/base/orange.ts +12 -12
  291. package/src/foundation/colors/base/purple.ts +12 -12
  292. package/src/foundation/colors/base/red.ts +12 -12
  293. package/src/foundation/colors/base/yellow.ts +12 -12
  294. package/src/foundation/colors/index.ts +119 -120
  295. package/src/foundation/colors/token/component.ts +185 -213
  296. package/src/foundation/colors/token/core.ts +113 -134
  297. package/src/foundation/colors/token/index.ts +2 -2
  298. package/src/foundation/colors/types.ts +0 -7
  299. package/src/foundation/index.ts +8 -8
  300. package/src/foundation/spacing.ts +1 -1
  301. package/src/index.ts +20 -20
  302. package/src/stories/GettingStarted.mdx +6 -6
  303. package/src/stories/components/Alert/Alert.stories.tsx +38 -45
  304. package/src/stories/components/Button/BasicButton.stories.tsx +68 -59
  305. package/src/stories/components/Button/ButtonDocs.mdx +17 -41
  306. package/src/stories/components/Button/Color.stories.tsx +28 -51
  307. package/src/stories/components/Button/IconButton.stories.tsx +40 -47
  308. package/src/stories/components/Button/Kind.stories.tsx +100 -213
  309. package/src/stories/components/CheckBox/BasicCheckbox.stories.tsx +52 -71
  310. package/src/stories/components/CheckBox/CheckboxDocs.mdx +6 -6
  311. package/src/stories/components/Chip/Chip.stories.tsx +75 -75
  312. package/src/stories/components/Chip/ChipDocs.mdx +12 -13
  313. package/src/stories/components/DataTable/DataTable.stories.tsx +4 -4
  314. package/src/stories/components/DatePicker/DatePicker.stories.tsx +4 -4
  315. package/src/stories/components/Dialog/Dialog.stories.tsx +103 -135
  316. package/src/stories/components/Dialog/DialogDocs.mdx +7 -13
  317. package/src/stories/components/Dropdown/Dropdown.stories.tsx +96 -82
  318. package/src/stories/components/Dropdown/DropdownDocs.mdx +275 -0
  319. package/src/stories/components/Dropdown/DropdownExamples.stories.tsx +40 -47
  320. package/src/stories/components/Dropdown/DropdownItem.stories.tsx +113 -98
  321. package/src/stories/components/SelectControl/RadioGroup.stories.tsx +17 -30
  322. package/src/stories/components/SelectControl/RadioStatus.stories.tsx +16 -23
  323. package/src/stories/components/SelectControl/Toggle.stories.tsx +33 -78
  324. package/src/stories/components/TextField/BasicTextField.stories.tsx +44 -53
  325. package/src/stories/components/TextField/TextFieldDocs.mdx +8 -12
  326. package/src/stories/components/TextField/TextFieldMulti.stories.tsx +39 -55
  327. package/src/stories/components/TextField/TextFieldSingle.stories.tsx +74 -118
  328. package/src/stories/components/TextField/TextFieldSize.stories.tsx +35 -55
  329. package/src/stories/components/Toast/Toast.stories.tsx +35 -50
  330. package/src/stories/components/ToggleButton/Basic.stories.tsx +115 -152
  331. package/src/stories/components/ToggleButton/ToggleButtonDocs.mdx +10 -14
  332. package/src/stories/components/ToggleButton/ToggleButtonKind.stories.tsx +141 -200
  333. package/src/stories/components/ToggleButton/WithIcon.stories.tsx +87 -107
  334. package/src/stories/components/Tooltip/Tooltip.stories.tsx +4 -4
  335. package/src/stories/foundation/Elevation/Elevation.stories.tsx +48 -54
  336. package/src/stories/foundation/Elevation/styled.ts +3 -3
  337. package/src/stories/foundation/Typography/Typography.mdx +9 -13
  338. package/src/stories/foundation/Typography/Typography.stories.tsx +25 -41
  339. package/src/stories/foundation/Typography/TypographyGroup.tsx +14 -25
  340. package/src/stories/foundation/Typography/const.ts +13 -19
  341. package/src/stories/foundation/colors/ColorSystem.tsx +42 -40
  342. package/src/stories/foundation/colors/Colors.stories.tsx +40 -41
  343. package/src/stories/foundation/colors/Docs.mdx +73 -77
  344. package/src/stories/foundation/colors/Mui.stories.tsx +6 -8
  345. package/src/stories/foundation/colors/Token.inComponent.stories.tsx +81 -71
  346. package/src/stories/foundation/colors/TokenPaletteTable.stories.tsx +7 -7
  347. package/src/stories/foundation/colors/TokenPaletteTable.tsx +23 -49
  348. package/src/stories/foundation/colors/styled.ts +26 -26
  349. package/src/theme.ts +6 -6
  350. package/src/types.d.ts +1 -1
  351. package/tsconfig.build.json +1 -5
@@ -1,121 +1,113 @@
1
- import React, { useState } from "react";
2
- import {
3
- Box,
4
- Table,
5
- TableHead,
6
- TableRow,
7
- TableBody,
8
- TableCell,
9
- } from "@mui/material";
10
- import { action } from "storybook/actions";
1
+ import React, { useState } from 'react';
2
+ import { Box, Table, TableHead, TableRow, TableBody, TableCell } from '@mui/material';
3
+ import { action } from 'storybook/actions';
11
4
 
12
- import ToggleButton from "@/components/ToggleButton";
5
+ import ToggleButton from '@/components/ToggleButton';
13
6
 
14
- import type { StoryFn, Meta } from "@storybook/react-webpack5";
7
+ import type { StoryFn, Meta } from '@storybook/react-webpack5';
15
8
 
16
9
  export default {
17
- title: "Components/ToggleButton",
10
+ title: 'Components/ToggleButton',
18
11
  component: ToggleButton,
19
12
  args: {
20
- children: "Text",
21
- kind: "contained",
22
- color: "primary",
23
- selectedColor: "primary",
24
- size: "small",
13
+ children: 'Text',
14
+ kind: 'contained',
15
+ color: 'primary',
16
+ selectedColor: 'primary',
17
+ size: 'small',
25
18
  disabled: false,
26
19
  },
27
20
  argTypes: {
28
21
  value: {
29
22
  control: false,
30
- table: { type: { summary: "any" } },
23
+ table: { type: { summary: 'any' } },
31
24
  },
32
25
  selected: {
33
26
  control: false,
34
27
  table: {
35
- defaultValue: { summary: "false" },
28
+ defaultValue: { summary: 'false' },
36
29
  },
37
30
  },
38
31
  children: {
39
- type: "string",
32
+ type: 'string',
40
33
  },
41
34
  disabled: {
42
35
  control: {
43
- type: "boolean",
36
+ type: 'boolean',
44
37
  },
45
38
  table: {
46
- defaultValue: { summary: "false" },
39
+ defaultValue: { summary: 'false' },
47
40
  },
48
41
  },
49
42
  size: {
50
43
  control: {
51
- type: "radio",
44
+ type: 'radio',
52
45
  },
53
- options: ["small", "medium", "large"],
46
+ options: ['small', 'medium', 'large'],
54
47
  table: {
55
- defaultValue: { summary: "small" },
48
+ defaultValue: { summary: 'small' },
56
49
  },
57
50
  },
58
51
  selectedColor: {
59
52
  control: {
60
- type: "radio",
53
+ type: 'radio',
61
54
  },
62
- options: ["primary", "secondary"],
55
+ options: ['primary', 'secondary'],
63
56
  description:
64
- "The color of the button when it is in an select state. It has nothing to do with active button",
57
+ 'The color of the button when it is in an select state. It has nothing to do with active button',
65
58
  table: {
66
- defaultValue: { summary: "primary" },
59
+ defaultValue: { summary: 'primary' },
67
60
  },
68
61
  },
69
62
  onChange: {
70
- type: "function",
63
+ type: 'function',
71
64
  control: false,
72
- options: ["function", undefined],
65
+ options: ['function', undefined],
73
66
  mapping: {
74
- function: action("onChange"),
67
+ function: action('onChange'),
75
68
  undefined: undefined,
76
69
  },
77
70
  },
78
71
  onClick: {
79
- type: "function",
72
+ type: 'function',
80
73
  control: {
81
- type: "radio",
74
+ type: 'radio',
82
75
  },
83
- options: ["function", undefined],
76
+ options: ['function', undefined],
84
77
  mapping: {
85
- function: action("onClick"),
78
+ function: action('onClick'),
86
79
  undefined: undefined,
87
80
  },
88
- description:
89
- "It is a callback function that is called when the button is clicked.",
81
+ description: 'It is a callback function that is called when the button is clicked.',
90
82
  },
91
83
  color: {
92
- options: ["primary", "secondary"],
84
+ options: ['primary', 'secondary'],
93
85
  table: {
94
- defaultValue: { summary: "primary" },
86
+ defaultValue: { summary: 'primary' },
95
87
  },
96
88
  },
97
89
  kind: {
98
90
  control: false,
99
- options: ["contained", "outlined", "ghost"],
100
- description: "Button has three Kinds Contained, Outlined, Ghost",
91
+ options: ['contained', 'outlined', 'ghost'],
92
+ description: 'Button has three Kinds Contained, Outlined, Ghost',
101
93
  table: {
102
- defaultValue: { summary: "contained" },
94
+ defaultValue: { summary: 'contained' },
103
95
  },
104
96
  },
105
97
  },
106
98
  parameters: {
107
99
  controls: {
108
100
  include: [
109
- "value",
110
- "kind",
111
- "selectedColor",
112
- "onClick",
113
- "children",
114
- "disabled",
115
- "size",
116
- "selected",
117
- "color",
118
- "onChange",
101
+ 'value',
102
+ 'kind',
103
+ 'selectedColor',
104
+ 'onClick',
105
+ 'children',
106
+ 'disabled',
107
+ 'size',
108
+ 'selected',
109
+ 'color',
110
+ 'onChange',
119
111
  ],
120
112
  },
121
113
  docs: {
@@ -125,17 +117,14 @@ export default {
125
117
  },
126
118
  },
127
119
  pseudo: {
128
- hover: ["#hover1", "#hover2", "#hover3"],
120
+ hover: ['#hover1', '#hover2', '#hover3'],
129
121
  },
130
122
  },
131
123
  } as Meta<typeof ToggleButton>;
132
124
 
133
- const ButtonTemplate: StoryFn<typeof ToggleButton> = ({
134
- kind,
135
- color,
136
- children,
137
- ...restProps
138
- }) => {
125
+ const ButtonTemplate: StoryFn<typeof ToggleButton> = (args) => {
126
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars, no-unused-vars
127
+ const { color, children, kind, ...restArgs } = args;
139
128
  const [values, setValues] = useState({
140
129
  contained: false,
141
130
  outlined: false,
@@ -154,8 +143,8 @@ const ButtonTemplate: StoryFn<typeof ToggleButton> = ({
154
143
  <TableCell
155
144
  colSpan={3}
156
145
  sx={{
157
- typography: "body1_16_semibold",
158
- color: "inherit",
146
+ typography: 'body1_16_semibold',
147
+ color: 'inherit',
159
148
  }}
160
149
  >
161
150
  Kind
@@ -164,19 +153,15 @@ const ButtonTemplate: StoryFn<typeof ToggleButton> = ({
164
153
  <TableRow>
165
154
  <TableCell
166
155
  sx={{
167
- width: "33.33333%",
168
- typography: "body2_14_medium",
169
- color: "inherit",
156
+ width: '33.33333%',
157
+ typography: 'body2_14_medium',
158
+ color: 'inherit',
170
159
  }}
171
160
  >
172
161
  Contained(default)
173
162
  </TableCell>
174
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
175
- Outlined
176
- </TableCell>
177
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
178
- Ghost
179
- </TableCell>
163
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>Outlined</TableCell>
164
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>Ghost</TableCell>
180
165
  </TableRow>
181
166
  </TableHead>
182
167
  <TableBody>
@@ -184,9 +169,9 @@ const ButtonTemplate: StoryFn<typeof ToggleButton> = ({
184
169
  <TableCell>
185
170
  <ToggleButton
186
171
  color={color}
187
- {...restProps}
172
+ {...restArgs}
188
173
  value="contained"
189
- onChange={() => handleChange("contained")}
174
+ onChange={() => handleChange('contained')}
190
175
  selected={values.contained}
191
176
  >
192
177
  {children}
@@ -196,9 +181,9 @@ const ButtonTemplate: StoryFn<typeof ToggleButton> = ({
196
181
  <ToggleButton
197
182
  kind="outlined"
198
183
  color="primary"
199
- {...restProps}
184
+ {...restArgs}
200
185
  value="outlined"
201
- onChange={() => handleChange("outlined")}
186
+ onChange={() => handleChange('outlined')}
202
187
  selected={values.outlined}
203
188
  >
204
189
  {children}
@@ -208,9 +193,9 @@ const ButtonTemplate: StoryFn<typeof ToggleButton> = ({
208
193
  <ToggleButton
209
194
  kind="ghost"
210
195
  color={color}
211
- {...restProps}
196
+ {...restArgs}
212
197
  value="ghost"
213
- onChange={() => handleChange("ghost")}
198
+ onChange={() => handleChange('ghost')}
214
199
  selected={values.ghost}
215
200
  >
216
201
  {children}
@@ -231,18 +216,15 @@ export const Kind = {
231
216
  argTypes: {
232
217
  color: {
233
218
  control: {
234
- type: "radio",
219
+ type: 'radio',
235
220
  },
236
221
  },
237
222
  },
238
223
  };
239
224
 
240
- const ToggleButtonDocsTemplate: StoryFn<typeof ToggleButton> = ({
241
- kind,
242
- color,
243
- children,
244
- ...restProps
245
- }) => {
225
+ const ToggleButtonDocsTemplate: StoryFn<typeof ToggleButton> = (args) => {
226
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars, no-unused-vars
227
+ const { color, children, kind, ...restArgs } = args;
246
228
  const [values, setValues] = useState({
247
229
  contained: false,
248
230
  outlined: false,
@@ -256,36 +238,36 @@ const ToggleButtonDocsTemplate: StoryFn<typeof ToggleButton> = ({
256
238
  return (
257
239
  <Box
258
240
  sx={{
259
- "& button": {
260
- marginRight: "7px",
241
+ '& button': {
242
+ marginRight: '7px',
261
243
  },
262
244
  }}
263
245
  >
264
246
  <ToggleButton
265
247
  color={color}
266
- {...restProps}
248
+ {...restArgs}
267
249
  value="contained"
268
- onChange={() => handleChange("contained")}
250
+ onChange={() => handleChange('contained')}
269
251
  selected={values.contained}
270
252
  >
271
253
  {children}
272
254
  </ToggleButton>
273
255
  <ToggleButton
274
256
  kind="outlined"
275
- color="primary"
276
- {...restProps}
257
+ {...restArgs}
277
258
  value="outlined"
278
- onChange={() => handleChange("outlined")}
259
+ onChange={() => handleChange('outlined')}
279
260
  selected={values.outlined}
280
261
  >
281
262
  {children}
282
263
  </ToggleButton>
264
+
283
265
  <ToggleButton
284
266
  kind="ghost"
285
267
  color={color}
286
- {...restProps}
268
+ {...restArgs}
287
269
  value="ghost"
288
- onChange={() => handleChange("ghost")}
270
+ onChange={() => handleChange('ghost')}
289
271
  selected={values.ghost}
290
272
  >
291
273
  {children}
@@ -302,6 +284,8 @@ export const KindDocs = {
302
284
  };
303
285
 
304
286
  const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
287
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars, no-unused-vars
288
+ const { color: _, ...restArgs } = args;
305
289
  const [values, setValues] = useState({
306
290
  primary: {
307
291
  enable: false,
@@ -332,26 +316,24 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
332
316
  <Table sx={{ width: 450 }}>
333
317
  <TableHead>
334
318
  <TableRow>
335
- <TableCell></TableCell>
336
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
319
+ <TableCell />
320
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>
337
321
  Contained Primary
338
322
  </TableCell>
339
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
323
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>
340
324
  Contained Secondary
341
325
  </TableCell>
342
326
  </TableRow>
343
327
  </TableHead>
344
328
  <TableBody>
345
329
  <TableRow>
346
- <TableCell sx={{ typography: "body2_14_regular", color: "inherit" }}>
347
- Enable
348
- </TableCell>
330
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Enable</TableCell>
349
331
  <TableCell>
350
332
  <ToggleButton
351
- {...args}
333
+ {...restArgs}
352
334
  kind="contained"
353
335
  value="enable"
354
- onChange={() => handleChange("primary", "enable")}
336
+ onChange={() => handleChange('primary', 'enable')}
355
337
  selected={values.primary.enable}
356
338
  >
357
339
  {args.children}
@@ -359,11 +341,11 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
359
341
  </TableCell>
360
342
  <TableCell>
361
343
  <ToggleButton
362
- {...args}
344
+ {...restArgs}
363
345
  kind="contained"
364
346
  color="secondary"
365
347
  value="enable"
366
- onChange={() => handleChange("secondary", "enable")}
348
+ onChange={() => handleChange('secondary', 'enable')}
367
349
  selected={values.secondary.enable}
368
350
  >
369
351
  {args.children}
@@ -371,16 +353,14 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
371
353
  </TableCell>
372
354
  </TableRow>
373
355
  <TableRow>
374
- <TableCell sx={{ typography: "body2_14_regular", color: "inherit" }}>
375
- Hover
376
- </TableCell>
356
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Hover</TableCell>
377
357
  <TableCell>
378
358
  <ToggleButton
379
- {...args}
359
+ {...restArgs}
380
360
  id="hover1"
381
361
  kind="contained"
382
362
  value="hover"
383
- onChange={() => handleChange("primary", "hover")}
363
+ onChange={() => handleChange('primary', 'hover')}
384
364
  selected={values.primary.hover}
385
365
  >
386
366
  {args.children}
@@ -388,12 +368,12 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
388
368
  </TableCell>
389
369
  <TableCell>
390
370
  <ToggleButton
391
- {...args}
371
+ {...restArgs}
392
372
  id="hover2"
393
373
  kind="contained"
394
374
  color="secondary"
395
375
  value="hover"
396
- onChange={() => handleChange("secondary", "hover")}
376
+ onChange={() => handleChange('secondary', 'hover')}
397
377
  selected={values.secondary.hover}
398
378
  >
399
379
  {args.children}
@@ -401,16 +381,14 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
401
381
  </TableCell>
402
382
  </TableRow>
403
383
  <TableRow>
404
- <TableCell sx={{ typography: "body2_14_regular", color: "inherit" }}>
405
- Focus
406
- </TableCell>
384
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Focus</TableCell>
407
385
  <TableCell>
408
386
  <ToggleButton
409
- {...args}
387
+ {...restArgs}
410
388
  kind="contained"
411
389
  className="Mui-focusVisible"
412
390
  value="focus"
413
- onChange={() => handleChange("primary", "focus")}
391
+ onChange={() => handleChange('primary', 'focus')}
414
392
  selected={values.primary.focus}
415
393
  >
416
394
  {args.children}
@@ -418,12 +396,12 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
418
396
  </TableCell>
419
397
  <TableCell>
420
398
  <ToggleButton
421
- {...args}
399
+ {...restArgs}
422
400
  kind="contained"
423
401
  color="secondary"
424
402
  className="Mui-focusVisible"
425
403
  value="focus"
426
- onChange={() => handleChange("secondary", "focus")}
404
+ onChange={() => handleChange('secondary', 'focus')}
427
405
  selected={values.secondary.focus}
428
406
  >
429
407
  {args.children}
@@ -431,22 +409,14 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
431
409
  </TableCell>
432
410
  </TableRow>
433
411
  <TableRow>
434
- <TableCell sx={{ typography: "body2_14_regular", color: "inherit" }}>
435
- Disabled
436
- </TableCell>
412
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Disabled</TableCell>
437
413
  <TableCell>
438
- <ToggleButton {...args} kind="contained" disabled value="disabled">
414
+ <ToggleButton {...restArgs} kind="contained" disabled value="disabled">
439
415
  {args.children}
440
416
  </ToggleButton>
441
417
  </TableCell>
442
418
  <TableCell>
443
- <ToggleButton
444
- {...args}
445
- kind="contained"
446
- color="secondary"
447
- disabled
448
- value="text8"
449
- >
419
+ <ToggleButton {...restArgs} kind="contained" color="secondary" disabled value="text8">
450
420
  {args.children}
451
421
  </ToggleButton>
452
422
  </TableCell>
@@ -458,7 +428,7 @@ const ContainedTemplate: StoryFn<typeof ToggleButton> = (args) => {
458
428
 
459
429
  export const KindContained = {
460
430
  render: ContainedTemplate,
461
- name: "Kind: Contained",
431
+ name: 'Kind: Contained',
462
432
 
463
433
  argTypes: {
464
434
  color: {
@@ -468,6 +438,8 @@ export const KindContained = {
468
438
  };
469
439
 
470
440
  const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
441
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars, no-unused-vars
442
+ const { color: _, ...restArgs } = args;
471
443
  const [values, setValues] = useState({
472
444
  primary: {
473
445
  enable: false,
@@ -499,28 +471,24 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
499
471
  <Table sx={{ width: 450 }}>
500
472
  <TableHead>
501
473
  <TableRow>
502
- <TableCell></TableCell>
503
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
474
+ <TableCell />
475
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>
504
476
  Ghost Primary
505
477
  </TableCell>
506
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
478
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>
507
479
  Ghost Secondary
508
480
  </TableCell>
509
481
  </TableRow>
510
482
  </TableHead>
511
483
  <TableBody>
512
484
  <TableRow>
513
- <TableCell
514
- sx={{ typography: "body2_14_regular", color: "inherit" }}
515
- >
516
- Enable
517
- </TableCell>
485
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Enable</TableCell>
518
486
  <TableCell>
519
487
  <ToggleButton
520
- {...args}
488
+ {...restArgs}
521
489
  kind="ghost"
522
490
  value="enable"
523
- onChange={() => handleChange("primary", "enable")}
491
+ onChange={() => handleChange('primary', 'enable')}
524
492
  selected={values.primary.enable}
525
493
  >
526
494
  {args.children}
@@ -528,11 +496,11 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
528
496
  </TableCell>
529
497
  <TableCell>
530
498
  <ToggleButton
531
- {...args}
499
+ {...restArgs}
532
500
  kind="ghost"
533
501
  color="secondary"
534
502
  value="enable"
535
- onChange={() => handleChange("secondary", "enable")}
503
+ onChange={() => handleChange('secondary', 'enable')}
536
504
  selected={values.secondary.enable}
537
505
  >
538
506
  {args.children}
@@ -540,18 +508,14 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
540
508
  </TableCell>
541
509
  </TableRow>
542
510
  <TableRow>
543
- <TableCell
544
- sx={{ typography: "body2_14_regular", color: "inherit" }}
545
- >
546
- Hover
547
- </TableCell>
511
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Hover</TableCell>
548
512
  <TableCell>
549
513
  <ToggleButton
550
- {...args}
514
+ {...restArgs}
551
515
  id="hover1"
552
516
  kind="ghost"
553
517
  value="hover"
554
- onChange={() => handleChange("primary", "hover")}
518
+ onChange={() => handleChange('primary', 'hover')}
555
519
  selected={values.primary.hover}
556
520
  >
557
521
  {args.children}
@@ -559,12 +523,12 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
559
523
  </TableCell>
560
524
  <TableCell>
561
525
  <ToggleButton
562
- {...args}
526
+ {...restArgs}
563
527
  id="hover2"
564
528
  kind="ghost"
565
529
  color="secondary"
566
530
  value="hover"
567
- onChange={() => handleChange("secondary", "hover")}
531
+ onChange={() => handleChange('secondary', 'hover')}
568
532
  selected={values.secondary.hover}
569
533
  >
570
534
  {args.children}
@@ -572,18 +536,14 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
572
536
  </TableCell>
573
537
  </TableRow>
574
538
  <TableRow>
575
- <TableCell
576
- sx={{ typography: "body2_14_regular", color: "inherit" }}
577
- >
578
- Focus
579
- </TableCell>
539
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Focus</TableCell>
580
540
  <TableCell>
581
541
  <ToggleButton
582
- {...args}
542
+ {...restArgs}
583
543
  kind="ghost"
584
544
  className="Mui-focusVisible"
585
545
  value="focus"
586
- onChange={() => handleChange("primary", "focus")}
546
+ onChange={() => handleChange('primary', 'focus')}
587
547
  selected={values.primary.focus}
588
548
  >
589
549
  {args.children}
@@ -591,12 +551,12 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
591
551
  </TableCell>
592
552
  <TableCell>
593
553
  <ToggleButton
594
- {...args}
554
+ {...restArgs}
595
555
  kind="ghost"
596
556
  color="secondary"
597
557
  className="Mui-focusVisible"
598
558
  value="focus"
599
- onChange={() => handleChange("secondary", "focus")}
559
+ onChange={() => handleChange('secondary', 'focus')}
600
560
  selected={values.secondary.focus}
601
561
  >
602
562
  {args.children}
@@ -604,24 +564,16 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
604
564
  </TableCell>
605
565
  </TableRow>
606
566
  <TableRow>
607
- <TableCell
608
- sx={{ typography: "body2_14_regular", color: "inherit" }}
609
- >
567
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>
610
568
  Disabled
611
569
  </TableCell>
612
570
  <TableCell>
613
- <ToggleButton {...args} kind="ghost" disabled value="disabled">
571
+ <ToggleButton {...restArgs} kind="ghost" disabled value="disabled">
614
572
  {args.children}
615
573
  </ToggleButton>
616
574
  </TableCell>
617
575
  <TableCell>
618
- <ToggleButton
619
- {...args}
620
- kind="ghost"
621
- color="secondary"
622
- disabled
623
- value="disabled"
624
- >
576
+ <ToggleButton {...restArgs} kind="ghost" color="secondary" disabled value="disabled">
625
577
  {args.children}
626
578
  </ToggleButton>
627
579
  </TableCell>
@@ -636,7 +588,7 @@ const GhostTemplate: StoryFn<typeof ToggleButton> = (args) => {
636
588
 
637
589
  export const KindGhost = {
638
590
  render: GhostTemplate,
639
- name: "Kind: Ghost",
591
+ name: 'Kind: Ghost',
640
592
 
641
593
  argTypes: {
642
594
  color: {
@@ -645,10 +597,9 @@ export const KindGhost = {
645
597
  },
646
598
  };
647
599
 
648
- const OutlinedTemplate: StoryFn<typeof ToggleButton> = ({
649
- color,
650
- ...restProps
651
- }) => {
600
+ const OutlinedTemplate: StoryFn<typeof ToggleButton> = (args) => {
601
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars, no-unused-vars
602
+ const { color, ...restProps } = args;
652
603
  const [values, setValues] = useState({
653
604
  primary: {
654
605
  enable: false,
@@ -675,25 +626,22 @@ const OutlinedTemplate: StoryFn<typeof ToggleButton> = ({
675
626
  <Table sx={{ width: 250 }}>
676
627
  <TableHead>
677
628
  <TableRow>
678
- <TableCell></TableCell>
679
- <TableCell sx={{ typography: "body2_14_medium", color: "inherit" }}>
629
+ <TableCell />
630
+ <TableCell sx={{ typography: 'body2_14_medium', color: 'inherit' }}>
680
631
  Outlined Primary
681
632
  </TableCell>
682
633
  </TableRow>
683
634
  </TableHead>
684
635
  <TableBody>
685
636
  <TableRow>
686
- <TableCell
687
- sx={{ typography: "body2_14_regular", color: "inherit" }}
688
- >
689
- Enable
690
- </TableCell>
637
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Enable</TableCell>
691
638
  <TableCell>
692
639
  <ToggleButton
693
640
  {...restProps}
694
641
  kind="outlined"
642
+ color="primary"
695
643
  value="enable"
696
- onChange={() => handleChange("primary", "enable")}
644
+ onChange={() => handleChange('primary', 'enable')}
697
645
  selected={values.primary.enable}
698
646
  >
699
647
  Text
@@ -701,18 +649,15 @@ const OutlinedTemplate: StoryFn<typeof ToggleButton> = ({
701
649
  </TableCell>
702
650
  </TableRow>
703
651
  <TableRow>
704
- <TableCell
705
- sx={{ typography: "body2_14_regular", color: "inherit" }}
706
- >
707
- Hover
708
- </TableCell>
652
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Hover</TableCell>
709
653
  <TableCell>
710
654
  <ToggleButton
711
655
  {...restProps}
712
656
  id="hover1"
713
657
  kind="outlined"
658
+ color="primary"
714
659
  value="hover"
715
- onChange={() => handleChange("primary", "hover")}
660
+ onChange={() => handleChange('primary', 'hover')}
716
661
  selected={values.primary.hover}
717
662
  >
718
663
  Text
@@ -720,18 +665,15 @@ const OutlinedTemplate: StoryFn<typeof ToggleButton> = ({
720
665
  </TableCell>
721
666
  </TableRow>
722
667
  <TableRow>
723
- <TableCell
724
- sx={{ typography: "body2_14_regular", color: "inherit" }}
725
- >
726
- Focus
727
- </TableCell>
668
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>Focus</TableCell>
728
669
  <TableCell>
729
670
  <ToggleButton
730
671
  {...restProps}
731
672
  kind="outlined"
673
+ color="primary"
732
674
  className="Mui-focusVisible"
733
675
  value="focus"
734
- onChange={() => handleChange("primary", "focus")}
676
+ onChange={() => handleChange('primary', 'focus')}
735
677
  selected={values.primary.focus}
736
678
  >
737
679
  Text
@@ -739,15 +681,14 @@ const OutlinedTemplate: StoryFn<typeof ToggleButton> = ({
739
681
  </TableCell>
740
682
  </TableRow>
741
683
  <TableRow>
742
- <TableCell
743
- sx={{ typography: "body2_14_regular", color: "inherit" }}
744
- >
684
+ <TableCell sx={{ typography: 'body2_14_regular', color: 'inherit' }}>
745
685
  Disabled
746
686
  </TableCell>
747
687
  <TableCell>
748
688
  <ToggleButton
749
689
  {...restProps}
750
690
  kind="outlined"
691
+ color="primary"
751
692
  disabled
752
693
  value="disabled"
753
694
  >
@@ -763,7 +704,7 @@ const OutlinedTemplate: StoryFn<typeof ToggleButton> = ({
763
704
 
764
705
  export const KindOutlined = {
765
706
  render: OutlinedTemplate,
766
- name: "Kind: Outlined",
707
+ name: 'Kind: Outlined',
767
708
 
768
709
  argTypes: {
769
710
  color: {