toolStyled.ts 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. import styled, { css } from 'styled-components';
  2. import { color } from '../constants/style';
  3. export const Wrapper = styled('div')<{ width?: string }>`
  4. margin-bottom: 10px;
  5. display: inline-block;
  6. height: auto;
  7. vertical-align: bottom;
  8. width: ${props => props.width || '100%'};
  9. `;
  10. export const Group = styled.div`
  11. display: flex;
  12. justify-content: space-around;
  13. align-items: center;
  14. `;
  15. export const Item = styled('div')<{ size?: string; selected?: boolean }>`
  16. width: ${props => (props.size === 'small' ? '30px' : '40px')};
  17. height: ${props => (props.size === 'small' ? '30px' : '40px')};
  18. border-radius: 4px;
  19. display: flex;
  20. justify-content: center;
  21. align-items: center;
  22. cursor: pointer;
  23. ${props =>
  24. props.selected
  25. ? css`
  26. background-color: ${color['light-primary']};
  27. `
  28. : ''}
  29. :hover {
  30. background-color: ${color['light-primary']};
  31. }
  32. `;
  33. export const Circle = styled('div')<{ color: string }>`
  34. width: 16px;
  35. height: 16px;
  36. border-radius: 8px;
  37. background-color: ${props => props.color};
  38. `;
  39. export const SliderWrapper = styled.div`
  40. padding: 5px 0;
  41. width: 178px;
  42. border-radius: 4px;
  43. border: solid 1px rgba(0, 0, 0, 0.12);
  44. `;
  45. export const BtnWrapper = styled.div`
  46. padding: 8px;
  47. `;
  48. export const PickerContainer = styled.div`
  49. position: fixed;
  50. z-index: 10;
  51. top: 0;
  52. left: 0;
  53. right: 0;
  54. bottom: 0;
  55. display: flex;
  56. justify-content: center;
  57. align-items: center;
  58. div[class^='chrome-picker'] {
  59. width: 350px !important;
  60. }
  61. `;
  62. export const Blanket = styled.div`
  63. position: absolute;
  64. top: 0;
  65. left: 0;
  66. right: 0;
  67. bottom: 0;
  68. `;