您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

shared.tsx 974B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. import styled from 'styles'
  2. export const IconButton = styled('button', {
  3. height: '32px',
  4. width: '32px',
  5. backgroundColor: '$panel',
  6. borderRadius: '4px',
  7. padding: '0',
  8. margin: '0',
  9. display: 'flex',
  10. alignItems: 'center',
  11. justifyContent: 'center',
  12. outline: 'none',
  13. border: 'none',
  14. pointerEvents: 'all',
  15. cursor: 'pointer',
  16. '&:hover:not(:disabled)': {
  17. backgroundColor: '$hover',
  18. },
  19. '&:disabled': {
  20. opacity: '0.5',
  21. },
  22. '& > svg': {
  23. height: '16px',
  24. width: '16px',
  25. },
  26. variants: {
  27. size: {
  28. small: {},
  29. medium: {
  30. height: 44,
  31. width: 44,
  32. '& svg': {
  33. height: 16,
  34. width: 16,
  35. strokeWidth: 0,
  36. },
  37. },
  38. large: {
  39. height: 44,
  40. width: 44,
  41. '& svg': {
  42. height: 24,
  43. width: 24,
  44. strokeWidth: 0,
  45. },
  46. },
  47. },
  48. isActive: {
  49. true: {
  50. color: '$selected',
  51. },
  52. },
  53. },
  54. })