Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
@filerobot/explorer / lib / components / AssetsList / ListView / ListView.styled.js
Size: Mime:
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23, _templateObject24, _templateObject25, _templateObject26, _templateObject27, _templateObject28, _templateObject29, _templateObject30;
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
import styled, { css } from 'styled-components';
import { PC, FV, PSH } from '@filerobot/common';
import { Label as SfxLabel, Button, TableHead as SfxTableHead, IconButton, Skeleton as SfxSkeleton, TableCell as SfxTableCell, Tag as SfxTag, TableRow as SfxTableRow, TooltipV2, CheckBox as SfxCheckBox } from '@scaleflex/ui/core';
import { ArrowDown } from '@scaleflex/icons';
import { loadingItemMixin } from '../AssetsList.styled';
var HeaderTableCell = styled(SfxTableCell)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n  position: sticky;\n  left: 0;\n  background-color: ", ";\n  border-bottom: ", ";\n  z-index: 1;\n"])), function (_ref) {
  var theme = _ref.theme,
    selected = _ref.selected;
  return selected ? theme.palette[PC.BackgroundActive] : theme.palette[PC.BackgroundStateless];
}, function (_ref2) {
  var theme = _ref2.theme;
  return "1px solid ".concat(theme.palette[PC.BordersSecondary]);
});
var TableCell = styled(SfxTableCell)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n  border-bottom: ", ";\n"])), function (_ref3) {
  var theme = _ref3.theme;
  return "1px solid ".concat(theme.palette[PC.BordersSecondary]);
});
var FileExtension = styled.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n  display: flex;\n  text-align: start;\n  text-transform: lowercase;\n  ", "\n  color: ", ";\n  max-width: 60px;\n  margin-left: 4px;\n"])), function (_ref4) {
  var theme = _ref4.theme;
  return theme.typography.font[FV.LabelSmall];
}, function (_ref5) {
  var theme = _ref5.theme;
  return theme.palette[PC.TextSecondary];
});
var Label = styled(SfxLabel)(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n  cursor: ", ";\n"])), function (_ref6) {
  var defaultCursor = _ref6.defaultCursor;
  return defaultCursor ? 'default' : 'pointer';
});
var ModifyAtLabel = styled(SfxLabel)(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n color: ", ";\n"])), function (_ref7) {
  var theme = _ref7.theme;
  return theme.palette[PC.TextPrimary];
});
var ClickableText = styled(Button)(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n  color: ", ";\n  cursor: pointer;\n  text-decoration: underline;\n\n  .SfxButton-Label {\n    ", ";\n  }\n\n  .SfxButton-StartIcon {\n    margin-right: 4px;\n  }\n\n  &:not(:last-child) {\n    margin-right: 8px;\n  }\n"])), function (_ref8) {
  var theme = _ref8.theme;
  return theme.palette[PC.AccentStateless];
}, function (_ref9) {
  var typography = _ref9.theme.typography;
  return typography.font[FV.ButtonSmEmphasis];
});
var InnerHeaderTableCell = styled(SfxTableCell)(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n&:first-child {\n  display: flex;\n  align-items: center;\n  position: sticky;\n  left: 0;\n  z-index: 2;\n  background-color: ", ";\n}"])), function (_ref10) {
  var theme = _ref10.theme;
  return theme.palette[PC.BackgroundStateless];
});
var FadedWrapper = styled.div(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n    white-space: nowrap;\n    max-width: 175px;\n    overflow: hidden;\n    position: relative;\n\n    &:after {\n      content: \"\";\n      position: absolute;\n      z-index: ", ";\n      top: 0;\n      right: 0;\n      bottom: 0;\n      pointer-events: none;\n      background: linear-gradient(270deg, #FFFFFF 1.56%, rgba(255, 255, 255, 0.89) 52.4%, rgba(255, 255, 255, 0.532165) 76.04%, rgba(255, 255, 255, 0) 100%);\n      width: 70px;\n    }\n "])), function (_ref11) {
  var fade = _ref11.fade;
  return fade ? 0 : -1;
});
var TableRow = styled(SfxTableRow)(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n  cursor: pointer;\n  ", "\n\n  ", " {\n    &:after {\n        background: ", ";\n    }\n  }\n  &:hover {\n     ", " {\n       &:after {\n        background:", ";\n       }\n     }\n\n     ", " {\n       background-color: ", ";\n     }\n  }\n"])), function (_ref12) {
  var $loading = _ref12.$loading;
  return $loading && loadingItemMixin;
}, FadedWrapper, function (_ref13) {
  var selected = _ref13.selected;
  return selected && 'linear-gradient(270deg, #F3F7FA 1.56%, #F3F7FA 52.4%, rgba(243, 247, 250, 0.53) 76.04%, rgba(243, 247, 250, 0) 100%)';
}, FadedWrapper, function (_ref14) {
  var selected = _ref14.selected;
  return selected ? 'linear-gradient(270deg, #F3F7FA 1.56%, #F3F7FA 52.4%, rgba(243, 247, 250, 0.53) 76.04%, rgba(243, 247, 250, 0) 100%)' : 'linear-gradient(270deg, #F9FBFC 1.56%, #F9FBFC 52.4%, rgba(249, 251, 252, 0.53) 76.04%, rgba(249, 251, 252, 0) 100%)';
}, HeaderTableCell, function (_ref15) {
  var theme = _ref15.theme,
    selected = _ref15.selected;
  return selected ? theme.palette[PC.BackgroundActive] : theme.palette[PC.BackgroundHover];
});
var HeaderCheckboxWrapper = styled.div(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n  display: flex;\n  align-items: center;\n"])));
var CheckBox = styled(SfxCheckBox)(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n  margin-right: 20px;\n"])));
var FirstColumnWrapper = styled.div(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n  display: flex;\n  align-items: center;\n"])));
var FirstColumnContentWrapper = styled.div(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n  display: flex;\n  column-gap: 12px;\n"])));
var AssetPreviewSkeleton = styled(SfxSkeleton)(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n  width: 70px;\n  height: 52px;\n  border-radius: 4px;\n"])));
var FolderSkeleton = styled(SfxSkeleton)(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["\n  width: 48px;\n  height: 38px;\n  margin: 8px 0px;\n  border-radius: 4px;\n"])));
var FileInfoSkeletonWrapper = styled.div(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["\n  display: flex;\n  flex-direction: column;\n  justify-content: center;\n  row-gap: 8px;\n"])));
var FileNameSkeleton = styled(SfxSkeleton)(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["\n  width: 174px;\n  height: 16px;\n"])));
var FileSizAndResolutionSkeleton = styled(SfxSkeleton)(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["\n  width: 80px;\n  height: 16px;\n"])));
var TableCellSkeleton = styled(SfxSkeleton)(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["\n  width: 185px;\n  height: 16px;\n"])));
var TableHead = styled(SfxTableHead)(function (_ref16) {
  var palette = _ref16.theme.palette,
    _ref16$$tableHeadStic = _ref16.$tableHeadStickTop,
    $tableHeadStickTop = _ref16$$tableHeadStic === void 0 ? -1 : _ref16$$tableHeadStic;
  return "\n  position: sticky;\n  top: ".concat($tableHeadStickTop, "px;\n  z-index: 100;\n  background-color:  ").concat(palette[PC.BackgroundStateless], ";\n");
});
var SortLabel = styled(Button)(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["\n  font-weight: 400;\n  color: ", ";\n\n  ", "\n\n  .SfxButton-Label {\n    font-weight: 400;\n  }\n"])), function (_ref17) {
  var palette = _ref17.theme.palette,
    active = _ref17.active;
  return active && palette[PC.LinkPressed];
}, function (_ref18) {
  var sortable = _ref18.sortable;
  return !sortable && css(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["\n    pointer-events: none;\n  "])));
});
var SortArrowIcon = styled(ArrowDown)(_templateObject22 || (_templateObject22 = _taggedTemplateLiteral(["\n  padding: 0;\n  margin-left: 8px;\n  color: ", ";\n  transition: transform 100ms linear;\n  transform: ", ";\n"])), function (_ref19) {
  var palette = _ref19.theme.palette;
  return palette[PC.IconsPrimary];
}, function (_ref20) {
  var $isAscOrder = _ref20.$isAscOrder;
  return !$isAscOrder ? 'rotate(-180deg)' : 'rotate(0)';
});
var TableCheckboxSkeleton = styled(SfxSkeleton)(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["\n  width: 20px;\n  height: 20px;\n  margin-right: 20px;\n"])));
var TableHeaderSkeleton = styled(SfxSkeleton)(_templateObject24 || (_templateObject24 = _taggedTemplateLiteral(["\n  width: 185px;\n  height: 16px;\n  margin: 4px;\n  background-color: ", ";\n"])), function (_ref21) {
  var palette = _ref21.theme.palette;
  return palette[PC.BordersSecondary];
});
var Tag = styled(SfxTag)(_templateObject25 || (_templateObject25 = _taggedTemplateLiteral(["\n  margin-right: 8px;\n  margin-bottom: 8px;\n\n\n  &:hover {\n    background-color: ", ";\n    border: 1px solid ", ";\n  }\n"])), function (_ref22) {
  var palette = _ref22.theme.palette;
  return palette[PC.BordersSecondary];
}, function (_ref23) {
  var palette = _ref23.theme.palette;
  return palette[PC.BorderPrimaryStateless];
});
var TagsTooltip = styled(TooltipV2)(_templateObject26 || (_templateObject26 = _taggedTemplateLiteral(["\n  display: flex;\n  flex-wrap: wrap;\n  background-color: ", ";\n  padding-bottom: 0px;\n  max-width: 499px;\n  gap: 8px;\n  border-radius: 4px;\n  padding: 8px 12px;\n  box-shadow: ", ";\n\n  &> .SfxTooltip-root {\n    box-shadow: none;\n    padding: 0;\n    gap:0;\n  }\n\n  & + .SfxPopper-arrow::before {\n    background: ", ";\n  }\n"])), function (_ref24) {
  var theme = _ref24.theme;
  return theme.palette[PC.BackgroundStateless];
}, function (_ref25) {
  var theme = _ref25.theme;
  return theme.shadows[PSH.ShadowLg];
}, function (_ref26) {
  var theme = _ref26.theme;
  return theme.palette[PC.BackgroundStateless];
});
var TagsTooltipTitleContainer = styled.div(_templateObject27 || (_templateObject27 = _taggedTemplateLiteral(["\n  display: flex;\n  flex-wrap: wrap;\n"])));
var LabelsTooltip = styled(TagsTooltip)(_templateObject28 || (_templateObject28 = _taggedTemplateLiteral(["\n   gap: 12px;\n"])));
var HeaderIconButton = styled(IconButton)(_templateObject29 || (_templateObject29 = _taggedTemplateLiteral(["\n  margin-right: 12px;\n"])));
var AssetPreviewWrapper = styled.div(_templateObject30 || (_templateObject30 = _taggedTemplateLiteral(["\n  position: relative;\n  width: 70px;\n  height: 52px;\n  border: 1px solid ", ";\n  border-radius: 2px;\n  display: flex;\n  align-items: center;\n"])), function (_ref27) {
  var theme = _ref27.theme;
  return theme.palette[PC.BordersPrimary];
});
var Styled = {
  FileExtension: FileExtension,
  Label: Label,
  ClickableText: ClickableText,
  InnerHeaderTableCell: InnerHeaderTableCell,
  TableCell: TableCell,
  HeaderCheckboxWrapper: HeaderCheckboxWrapper,
  CheckBox: CheckBox,
  FadedWrapper: FadedWrapper,
  TableHead: TableHead,
  SortLabel: SortLabel,
  SortArrowIcon: SortArrowIcon,
  TableCheckboxSkeleton: TableCheckboxSkeleton,
  TableHeaderSkeleton: TableHeaderSkeleton,
  FirstColumnWrapper: FirstColumnWrapper,
  FirstColumnContentWrapper: FirstColumnContentWrapper,
  AssetPreviewSkeleton: AssetPreviewSkeleton,
  FolderSkeleton: FolderSkeleton,
  FileInfoSkeletonWrapper: FileInfoSkeletonWrapper,
  FileNameSkeleton: FileNameSkeleton,
  FileSizAndResolutionSkeleton: FileSizAndResolutionSkeleton,
  TableCellSkeleton: TableCellSkeleton,
  Tag: Tag,
  TableRow: TableRow,
  HeaderTableCell: HeaderTableCell,
  TagsTooltip: TagsTooltip,
  TagsTooltipTitleContainer: TagsTooltipTitleContainer,
  LabelsTooltip: LabelsTooltip,
  HeaderIconButton: HeaderIconButton,
  ModifyAtLabel: ModifyAtLabel,
  AssetPreviewWrapper: AssetPreviewWrapper
};
export default Styled;