ellipsis.js 991 B

12345678910111213141516171819202122232425262728293031323334353637
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.default = void 0;
  6. var _style = require("../../style");
  7. const genEllipsisStyle = token => {
  8. const {
  9. componentCls
  10. } = token;
  11. return {
  12. [`${componentCls}-wrapper`]: {
  13. [`${componentCls}-cell-ellipsis`]: Object.assign(Object.assign({}, _style.textEllipsis), {
  14. wordBreak: 'keep-all',
  15. // Fixed first or last should special process
  16. [`
  17. &${componentCls}-cell-fix-left-last,
  18. &${componentCls}-cell-fix-right-first
  19. `]: {
  20. overflow: 'visible',
  21. [`${componentCls}-cell-content`]: {
  22. display: 'block',
  23. overflow: 'hidden',
  24. textOverflow: 'ellipsis'
  25. }
  26. },
  27. [`${componentCls}-column-title`]: {
  28. overflow: 'hidden',
  29. textOverflow: 'ellipsis',
  30. wordBreak: 'keep-all'
  31. }
  32. })
  33. }
  34. };
  35. };
  36. var _default = exports.default = genEllipsisStyle;