UNPKG

@elastic/eui

Version:

Elastic UI Component Library

59 lines (58 loc) 3.23 kB
function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; } /* * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one * or more contributor license agreements. Licensed under the Elastic License * 2.0 and the Server Side Public License, v 1; you may not use this file except * in compliance with, at your election, the Elastic License 2.0 or the Server * Side Public License, v 1. */ import { css } from '@emotion/react'; import { logicalCSS } from '../../global_styling'; var _ref = process.env.NODE_ENV === "production" ? { name: "173v8a4-euiCallOut__dismissButton", styles: "position:absolute;label:euiCallOut__dismissButton;" } : { name: "173v8a4-euiCallOut__dismissButton", styles: "position:absolute;label:euiCallOut__dismissButton;", toString: _EMOTION_STRINGIFIED_CSS_ERROR__ }; var _ref2 = process.env.NODE_ENV === "production" ? { name: "192kin0-euiCallOut", styles: "position:relative;label:euiCallOut;" } : { name: "192kin0-euiCallOut", styles: "position:relative;label:euiCallOut;", toString: _EMOTION_STRINGIFIED_CSS_ERROR__ }; export var euiCallOutStyles = function euiCallOutStyles(_ref3) { var euiTheme = _ref3.euiTheme; return { euiCallOut: _ref2, hasDismissButton: { // Ensure that only the top-most (first-child) title or child text // has a padding-right on it (to account for the dismiss button) hasDimissButton: /*#__PURE__*/css("&>:first-child:is(.euiTitle),&>:first-child:is(.euiText)>:first-child{", logicalCSS('padding-right', euiTheme.size.base), ";};label:hasDimissButton;"), // Ensure the callout always has enough height for the button s: /*#__PURE__*/css(logicalCSS('min-height', euiTheme.size.xl), ";;label:s;"), m: /*#__PURE__*/css(logicalCSS('min-height', euiTheme.size.xxl), ";;label:m;") }, dismissButton: { euiCallOut__dismissButton: _ref, s: /*#__PURE__*/css(logicalCSS('top', euiTheme.size.xs), " ", logicalCSS('right', euiTheme.size.xs), ";;label:s;"), m: /*#__PURE__*/css(logicalCSS('top', euiTheme.size.s), " ", logicalCSS('right', euiTheme.size.s), ";;label:m;") } }; }; export var euiCallOutHeaderStyles = function euiCallOutHeaderStyles(_ref4) { var euiTheme = _ref4.euiTheme; return { euiCallOutHeader: /*#__PURE__*/css("font-weight:", euiTheme.font.weight.medium, ";", logicalCSS('margin-bottom', '0 !important' // In case it's nested inside EuiText ), ";;label:euiCallOutHeader;"), primary: /*#__PURE__*/css("color:", euiTheme.colors.primaryText, ";;label:primary;"), success: /*#__PURE__*/css("color:", euiTheme.colors.successText, ";;label:success;"), warning: /*#__PURE__*/css("color:", euiTheme.colors.warningText, ";;label:warning;"), danger: /*#__PURE__*/css("color:", euiTheme.colors.dangerText, ";;label:danger;"), euiCallOut__icon: /*#__PURE__*/css("position:relative;", logicalCSS('top', '-1px'), " ", logicalCSS('margin-right', euiTheme.size.s), ";;label:euiCallOut__icon;") }; };