8
0

splitbutton.css 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. /*
  2. * Copyright (c) 2003-2018, CKSource - Frederico Knabben. All rights reserved.
  3. * For licensing, see LICENSE.md.
  4. */
  5. @import "../../../mixins/_rounded.css";
  6. :root {
  7. --ck-color-split-button-hover-background: hsl(0, 0%, 92%);
  8. --ck-color-split-button-hover-border: hsl(0, 0%, 70%);
  9. }
  10. .ck-splitbutton {
  11. & > .ck-splitbutton__action {
  12. /* Don't round the first button on the right side */
  13. @mixin ck-rounded-corners {
  14. border-top-right-radius: unset;
  15. border-bottom-right-radius: unset;
  16. }
  17. }
  18. & > .ck-splitbutton__arrow {
  19. /* It's a text-less button but still, it should not be square. */
  20. min-width: unset;
  21. /* Don't round the arrow button on the right side */
  22. @mixin ck-rounded-corners {
  23. border-top-left-radius: unset;
  24. border-bottom-left-radius: unset;
  25. }
  26. & svg {
  27. width: var(--ck-dropdown-arrow-size);
  28. }
  29. }
  30. /* When the split button is "open" (the arrow is on) or being hovered, it should get some styling
  31. as a whole. The background of both buttons should stand out and there should be a visual
  32. separation between both buttons. */
  33. &.ck-splitbutton_open,
  34. &:hover {
  35. /* When the split button hovered as a whole, not as individual buttons. */
  36. & > .ck-button:not(.ck-on):not(:hover) {
  37. background: var(--ck-color-split-button-hover-background);
  38. }
  39. & > .ck-splitbutton__arrow {
  40. border-left-color: var(--ck-color-split-button-hover-border);
  41. }
  42. }
  43. }