How to use the @commercetools-uikit/design-system.customProperties.colorInfo function in @commercetools-uikit/design-system

To help you get started, we’ve selected a few @commercetools-uikit/design-system examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github commercetools / ui-kit / src / components / buttons / icon-button / icon-button.styles.js View on Github external
`;
    switch (theme) {
      case 'info':
        return [
          activeStyle,
          isDisabled &&
            // When the button is active and somehow is disabled it should have
            // a different color to indicate that it's active but can't receive any actions
            css`
              background-color: ${vars.colorInfo85};
              border-color: ${vars.colorInfo85};
              color: ${vars.colorSurface};
              box-shadow: ${vars.shadow9};
            `,
          css`
            background-color: ${vars.colorInfo};
            border-color: ${vars.colorInfo};
            color: ${vars.colorSurface};
            &:hover {
              background-color: ${vars.colorInfo85};
              border-color: ${vars.colorInfo85};
            }
          `,
        ];
      case 'primary':
        return [
          activeStyle,
          // When the button is active and somehow is disabled it should have
          // a different color to indicate that it's active but can't receive any actions
          isDisabled &&
            css`
              background-color: ${vars.colorPrimary85};
github commercetools / ui-kit / src / components / buttons / secondary-button / secondary-button.styles.js View on Github external
const getThemeStyles = theme => {
  if (!theme) return css``;

  if (theme === 'default') return css``;

  switch (theme) {
    case 'info':
      return css`
        &:hover {
          color: ${vars.colorInfo};

          * {
            fill: ${vars.colorInfo};
          }
        }
      `;
    default: {
      invariant(
        false,
        `ui-kit/SecondaryButton: the specified theme '${theme}' is not supported.`
      );
      return css`
        &:hover {
          box-shadow: ${vars.shadow8};
        }
        &:active {
github commercetools / ui-kit / packages / components / table / src / table.story.js View on Github external
{({ css: makeClassName }) => {
            this.columns = baseColumns({
              onCheckboxClick: this.onCheckboxClick,
              checkboxClassName: makeClassName({
                backgroundColor: '#f2f2f2',
                borderLeft: `2px solid ${vars.colorInfo}`,
                ':hover': {
                  backgroundColor: '#e0e0e0',
                  cursor: 'pointer',
                },
              }),
            });
            return (
              
                  this.renderItem({
                    rowIndex,
                    columnIndex,
                    showTooltip: this.props.showTooltip,
                    tooltipText: this.props.tooltipText,<table></table>
github commercetools / ui-kit / src / components / internals / calendar-day / calendar-day.js View on Github external
if (props.isRangeBetween) {
    styles.push(
      css`
        background-color: ${vars.colorNeutral90};
        color: ${vars.fontColorForInput};
      `
    );
  }
  if (
    !props.isSelected &&
    !props.isRangeStart &&
    !props.isRangeEnd &&
    props.isToday
  ) {
    styles.push(css`
      color: ${vars.colorInfo};
      font-weight: bold;
    `);
  }

  if (props.disabled) {
    styles.push(css`
      color: ${vars.fontColorForInputWhenDisabled};
      cursor: not-allowed;
    `);
  }

  return styles;
};
github commercetools / ui-kit / src / components / stamp / stamp.js View on Github external
case 'warning': {
      return css`
        background-color: ${vars.colorWarning95};
        border: 1px solid ${vars.colorWarning};
      `;
    }
    case 'positive': {
      return css`
        background-color: ${vars.colorPrimary85};
        border: 1px solid ${vars.colorPrimary40};
      `;
    }
    case 'information': {
      return css`
        background-color: ${vars.colorInfo95};
        border: 1px solid ${vars.colorInfo};
      `;
    }
    case 'primary': {
      return css`
        background-color: ${vars.colorPrimary95};
        border: 1px solid ${vars.colorPrimary25};
      `;
    }
    case 'secondary': {
      return css`
        background-color: ${vars.colorNeutral90};
        border: 1px solid ${vars.colorNeutral60};
      `;
    }
    default:
      return css``;
github commercetools / merchant-center-application-kit / packages / react-notifications / src / components / notification / notification.styles.ts View on Github external
const getColorByType = (value: TAppNotificationKind) => {
  switch (value) {
    case NOTIFICATION_KINDS_SIDE.success:
      return customProperties.colorPrimary;
    case NOTIFICATION_KINDS_SIDE.info:
      return customProperties.colorInfo;
    case NOTIFICATION_KINDS_SIDE.error:
      return customProperties.colorError;
    case NOTIFICATION_KINDS_SIDE.warning:
      return customProperties.colorWarning;
    default:
      return 'transparent';
  }
};
github commercetools / ui-kit / src / components / notifications / content-notification / content-notification.js View on Github external
const getContentBorderColor = props => {
  switch (props.type) {
    case 'error':
      return vars.colorError;
    case 'info':
      return vars.colorInfo;
    case 'warning':
      return vars.colorWarning;
    case 'success':
      return vars.colorPrimary;
    default:
      return '';
  }
};

@commercetools-uikit/design-system

Core package of the commercetools design system.

MIT
Latest version published 5 days ago

Package Health Score

87 / 100
Full package analysis