@elastic/eui 67.1.8 → 67.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/components/button/button.js +1 -0
- package/es/components/button/button_display/_button_display.js +3 -3
- package/es/components/button/button_display/_button_display.styles.js +2 -1
- package/es/components/date_picker/super_date_picker/super_update_button.js +1 -1
- package/es/components/description_list/description_list.styles.js +2 -2
- package/es/components/description_list/description_list_description.js +6 -2
- package/es/components/description_list/description_list_description.styles.js +2 -2
- package/es/components/description_list/description_list_title.styles.js +2 -2
- package/es/components/facet/facet_button.js +55 -1
- package/es/components/flyout/flyout.styles.js +7 -7
- package/es/components/image/image_wrapper.styles.js +3 -3
- package/es/components/page/page.styles.js +2 -2
- package/es/components/toast/global_toast_list.styles.js +5 -5
- package/es/global_styling/mixins/_helpers.js +1 -1
- package/es/global_styling/mixins/_responsive.js +46 -1
- package/eui.d.ts +23 -4
- package/lib/components/button/button.js +1 -0
- package/lib/components/button/button_display/_button_display.js +3 -3
- package/lib/components/button/button_display/_button_display.styles.js +2 -1
- package/lib/components/date_picker/super_date_picker/super_update_button.js +1 -1
- package/lib/components/description_list/description_list.styles.js +1 -1
- package/lib/components/description_list/description_list_description.js +5 -1
- package/lib/components/description_list/description_list_description.styles.js +1 -1
- package/lib/components/description_list/description_list_title.styles.js +1 -1
- package/lib/components/facet/facet_button.js +56 -2
- package/lib/components/flyout/flyout.styles.js +6 -6
- package/lib/components/image/image_wrapper.styles.js +2 -2
- package/lib/components/page/page.styles.js +1 -1
- package/lib/components/toast/global_toast_list.styles.js +4 -4
- package/lib/global_styling/mixins/_helpers.js +1 -1
- package/lib/global_styling/mixins/_responsive.js +60 -3
- package/optimize/es/components/button/button.js +1 -0
- package/optimize/es/components/button/button_display/_button_display.js +2 -2
- package/optimize/es/components/button/button_display/_button_display.styles.js +2 -1
- package/optimize/es/components/date_picker/super_date_picker/super_update_button.js +1 -1
- package/optimize/es/components/description_list/description_list.styles.js +2 -2
- package/optimize/es/components/description_list/description_list_description.js +6 -2
- package/optimize/es/components/description_list/description_list_description.styles.js +2 -2
- package/optimize/es/components/description_list/description_list_title.styles.js +2 -2
- package/optimize/es/components/flyout/flyout.styles.js +7 -7
- package/optimize/es/components/image/image_wrapper.styles.js +3 -3
- package/optimize/es/components/page/page.styles.js +2 -2
- package/optimize/es/components/toast/global_toast_list.styles.js +5 -5
- package/optimize/es/global_styling/mixins/_helpers.js +1 -1
- package/optimize/es/global_styling/mixins/_responsive.js +46 -1
- package/optimize/lib/components/button/button.js +1 -0
- package/optimize/lib/components/button/button_display/_button_display.js +2 -2
- package/optimize/lib/components/button/button_display/_button_display.styles.js +2 -1
- package/optimize/lib/components/date_picker/super_date_picker/super_update_button.js +1 -1
- package/optimize/lib/components/description_list/description_list.styles.js +1 -1
- package/optimize/lib/components/description_list/description_list_description.js +5 -1
- package/optimize/lib/components/description_list/description_list_description.styles.js +1 -1
- package/optimize/lib/components/description_list/description_list_title.styles.js +1 -1
- package/optimize/lib/components/flyout/flyout.styles.js +6 -6
- package/optimize/lib/components/image/image_wrapper.styles.js +2 -2
- package/optimize/lib/components/page/page.styles.js +1 -1
- package/optimize/lib/components/toast/global_toast_list.styles.js +4 -4
- package/optimize/lib/global_styling/mixins/_helpers.js +1 -1
- package/optimize/lib/global_styling/mixins/_responsive.js +60 -3
- package/package.json +1 -1
- package/test-env/components/button/button.js +1 -0
- package/test-env/components/button/button_display/_button_display.js +3 -3
- package/test-env/components/button/button_display/_button_display.styles.js +2 -1
- package/test-env/components/date_picker/super_date_picker/super_update_button.js +1 -1
- package/test-env/components/description_list/description_list.styles.js +1 -1
- package/test-env/components/description_list/description_list_description.js +5 -1
- package/test-env/components/description_list/description_list_description.styles.js +1 -1
- package/test-env/components/description_list/description_list_title.styles.js +1 -1
- package/test-env/components/facet/facet_button.js +56 -2
- package/test-env/components/flyout/flyout.styles.js +6 -6
- package/test-env/components/image/image_wrapper.styles.js +2 -2
- package/test-env/components/page/page.styles.js +1 -1
- package/test-env/components/toast/global_toast_list.styles.js +4 -4
- package/test-env/global_styling/mixins/_helpers.js +1 -1
- package/test-env/global_styling/mixins/_responsive.js +60 -3
|
@@ -29,7 +29,7 @@ var euiDescriptionListTitleStyles = function euiDescriptionListTitleStyles(euiTh
|
|
|
29
29
|
// Types
|
|
30
30
|
row: /*#__PURE__*/(0, _react.css)(";label:row;"),
|
|
31
31
|
column: /*#__PURE__*/(0, _react.css)(columnDisplay, ";;label:column;"),
|
|
32
|
-
responsiveColumn: /*#__PURE__*/(0, _react.css)((0, _global_styling.
|
|
32
|
+
responsiveColumn: /*#__PURE__*/(0, _react.css)((0, _global_styling.euiMaxBreakpoint)(euiThemeContext, 'm'), "{", (0, _global_styling.logicalCSS)('width', '100%'), " padding:0;}", (0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{", columnDisplay, ";};label:responsiveColumn;"),
|
|
33
33
|
inline: /*#__PURE__*/(0, _react.css)("display:inline;border-radius:", euiTheme.border.radius.small, ";font-weight:", euiTheme.font.weight.medium, ";background-color:", colorMode === 'DARK' ? (0, _services.tint)(euiTheme.colors.lightestShade, 0.5) : euiTheme.colors.lightestShade, ";", (0, _global_styling.logicalCSS)('margin-vertical', '0'), " ", (0, _global_styling.logicalCSS)('margin-horizontal', euiTheme.size.xs), "&:first-of-type{", (0, _global_styling.logicalCSS)('margin-left', '0'), ";};label:inline;"),
|
|
34
34
|
// This nested block handles just the font styling based on compressed and reverse
|
|
35
35
|
fontStyles: {
|
|
@@ -120,19 +120,28 @@ EuiFacetButton.propTypes = {
|
|
|
120
120
|
/**
|
|
121
121
|
* ReactNode to render as this component's content
|
|
122
122
|
*/
|
|
123
|
-
children: _propTypes.default.node.isRequired,
|
|
123
|
+
children: _propTypes.default.oneOfType([_propTypes.default.node.isRequired, _propTypes.default.node]),
|
|
124
124
|
|
|
125
125
|
/**
|
|
126
126
|
* Any node, but preferably a `EuiIcon` or `EuiAvatar`
|
|
127
127
|
*/
|
|
128
128
|
icon: _propTypes.default.node,
|
|
129
|
-
isDisabled: _propTypes.default.bool,
|
|
129
|
+
isDisabled: _propTypes.default.oneOfType([_propTypes.default.bool, _propTypes.default.bool]),
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* Force disables the button and changes the icon to a loading spinner
|
|
133
|
+
*/
|
|
130
134
|
|
|
131
135
|
/**
|
|
132
136
|
* Adds/swaps for loading spinner & disables
|
|
133
137
|
*/
|
|
134
138
|
isLoading: _propTypes.default.bool,
|
|
135
139
|
|
|
140
|
+
/**
|
|
141
|
+
* Applies the boolean state as the `aria-pressed` property to create a toggle button.
|
|
142
|
+
* *Only use when the readable text does not change between states.*
|
|
143
|
+
*/
|
|
144
|
+
|
|
136
145
|
/**
|
|
137
146
|
* Changes visual of button to indicate it's currently selected
|
|
138
147
|
*/
|
|
@@ -142,6 +151,51 @@ EuiFacetButton.propTypes = {
|
|
|
142
151
|
* Adds a notification indicator for displaying the quantity provided
|
|
143
152
|
*/
|
|
144
153
|
quantity: _propTypes.default.number,
|
|
154
|
+
size: _propTypes.default.any,
|
|
155
|
+
|
|
156
|
+
/**
|
|
157
|
+
* Extends the button to 100% width
|
|
158
|
+
*/
|
|
159
|
+
fullWidth: _propTypes.default.bool,
|
|
160
|
+
|
|
161
|
+
/**
|
|
162
|
+
* Override the default minimum width
|
|
163
|
+
*/
|
|
164
|
+
minWidth: _propTypes.default.oneOfType([_propTypes.default.any.isRequired, _propTypes.default.oneOf([false])]),
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* Object of props passed to the <span/> wrapping the button's content
|
|
168
|
+
*/
|
|
169
|
+
contentProps: _propTypes.default.shape({
|
|
170
|
+
className: _propTypes.default.string,
|
|
171
|
+
"aria-label": _propTypes.default.string,
|
|
172
|
+
"data-test-subj": _propTypes.default.string,
|
|
173
|
+
css: _propTypes.default.any
|
|
174
|
+
}),
|
|
175
|
+
style: _propTypes.default.any,
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* Any `type` accepted by EuiIcon
|
|
179
|
+
*/
|
|
180
|
+
iconType: _propTypes.default.oneOfType([_propTypes.default.oneOf(["accessibility", "addDataApp", "advancedSettingsApp", "agentApp", "aggregate", "alert", "analyzeEvent", "annotation", "apmApp", "apmTrace", "appSearchApp", "apps", "arrowDown", "arrowLeft", "arrowRight", "arrowUp", "arrowStart", "arrowEnd", "asterisk", "auditbeatApp", "beaker", "bell", "bellSlash", "bolt", "boxesHorizontal", "boxesVertical", "branch", "branchUser", "broom", "brush", "bug", "bullseye", "calendar", "canvasApp", "casesApp", "check", "checkInCircleFilled", "cheer", "classificationJob", "clock", "cloudDrizzle", "cloudStormy", "cloudSunny", "cluster", "codeApp", "color", "compute", "console", "consoleApp", "container", "continuityAbove", "continuityAboveBelow", "continuityBelow", "continuityWithin", "controlsHorizontal", "controlsVertical", "copy", "copyClipboard", "createAdvancedJob", "createMultiMetricJob", "createPopulationJob", "createSingleMetricJob", "cross", "crossClusterReplicationApp", "crossInACircleFilled", "crosshairs", "currency", "cut", "dashboardApp", "dataVisualizer", "database", "desktop", "devToolsApp", "discoverApp", "document", "documentEdit", "documentation", "documents", "dot", "doubleArrowLeft", "doubleArrowRight", "download", "editorAlignCenter", "editorAlignLeft", "editorAlignRight", "editorBold", "editorChecklist", "editorCodeBlock", "editorComment", "editorDistributeHorizontal", "editorDistributeVertical", "editorHeading", "editorItalic", "editorItemAlignBottom", "editorItemAlignCenter", "editorItemAlignLeft", "editorItemAlignMiddle", "editorItemAlignRight", "editorItemAlignTop", "editorLink", "editorOrderedList", "editorPositionBottomLeft", "editorPositionBottomRight", "editorPositionTopLeft", "editorPositionTopRight", "editorRedo", "editorStrike", "editorTable", "editorUnderline", "editorUndo", "editorUnorderedList", "email", "empty", "emsApp", "eql", "eraser", "exit", "expand", "expandMini", "exportAction", "eye", "eyeClosed", "faceHappy", "faceNeutral", "faceSad", "filebeatApp", "filter", "flag", "fleetApp", "fold", "folderCheck", "folderClosed", "folderExclamation", "folderOpen", "frameNext", "framePrevious", "fullScreen", "fullScreenExit", "function", "gear", "gisApp", "glasses", "globe", "grab", "grabHorizontal", "graphApp", "grid", "grokApp", "heart", "heartbeatApp", "heatmap", "help", "home", "iInCircle", "image", "importAction", "indexClose", "indexEdit", "indexFlush", "indexManagementApp", "indexMapping", "indexOpen", "indexPatternApp", "indexRollupApp", "indexRuntime", "indexSettings", "inputOutput", "inspect", "invert", "ip", "keyboard", "kqlField", "kqlFunction", "kqlOperand", "kqlSelector", "kqlValue", "kubernetesNode", "kubernetesPod", "layers", "lensApp", "lettering", "lineDashed", "lineDotted", "lineSolid", "link", "list", "listAdd", "lock", "lockOpen", "logoAWS", "logoAWSMono", "logoAerospike", "logoApache", "logoAppSearch", "logoAzure", "logoAzureMono", "logoBeats", "logoBusinessAnalytics", "logoCeph", "logoCloud", "logoCloudEnterprise", "logoCode", "logoCodesandbox", "logoCouchbase", "logoDocker", "logoDropwizard", "logoElastic", "logoElasticStack", "logoElasticsearch", "logoEnterpriseSearch", "logoEtcd", "logoGCP", "logoGCPMono", "logoGithub", "logoGmail", "logoGolang", "logoGoogleG", "logoHAproxy", "logoIBM", "logoIBMMono", "logoKafka", "logoKibana", "logoKubernetes", "logoLogging", "logoLogstash", "logoMaps", "logoMemcached", "logoMetrics", "logoMongodb", "logoMySQL", "logoNginx", "logoObservability", "logoOsquery", "logoPhp", "logoPostgres", "logoPrometheus", "logoRabbitmq", "logoRedis", "logoSecurity", "logoSiteSearch", "logoSketch", "logoSlack", "logoUptime", "logoWebhook", "logoWindows", "logoWorkplaceSearch", "logsApp", "logstashFilter", "logstashIf", "logstashInput", "logstashOutput", "logstashQueue", "machineLearningApp", "magnet", "magnifyWithExclamation", "magnifyWithMinus", "magnifyWithPlus", "managementApp", "mapMarker", "memory", "menu", "menuDown", "menuLeft", "menuRight", "menuUp", "merge", "metricbeatApp", "metricsApp", "minimize", "minus", "minusInCircle", "minusInCircleFilled", "mobile", "monitoringApp", "moon", "namespace", "nested", "node", "notebookApp", "number", "offline", "online", "outlierDetectionJob", "package", "packetbeatApp", "pageSelect", "pagesSelect", "paperClip", "partial", "pause", "payment", "pencil", "percent", "pin", "pinFilled", "pipelineApp", "play", "playFilled", "plus", "plusInCircle", "plusInCircleFilled", "popout", "push", "questionInCircle", "quote", "recentlyViewedApp", "refresh", "regressionJob", "reporter", "reportingApp", "returnKey", "save", "savedObjectsApp", "scale", "search", "searchProfilerApp", "securityAnalyticsApp", "securityApp", "securitySignal", "securitySignalDetected", "securitySignalResolved", "sessionViewer", "shard", "share", "snowflake", "sortDown", "sortLeft", "sortRight", "sortUp", "sortable", "spacesApp", "sqlApp", "starEmpty", "starEmptySpace", "starFilled", "starFilledSpace", "starMinusEmpty", "starMinusFilled", "starPlusEmpty", "starPlusFilled", "stats", "stop", "stopFilled", "stopSlash", "storage", "string", "submodule", "sun", "swatchInput", "symlink", "tableDensityCompact", "tableDensityExpanded", "tableDensityNormal", "tableOfContents", "tag", "tear", "temperature", "timeline", "timelionApp", "timeRefresh", "timeslider", "training", "trash", "unfold", "unlink", "upgradeAssistantApp", "uptimeApp", "user", "userAvatar", "users", "usersRolesApp", "vector", "videoPlayer", "visArea", "visAreaStacked", "visBarHorizontal", "visBarHorizontalStacked", "visBarVertical", "visBarVerticalStacked", "visGauge", "visGoal", "visLine", "visMapCoordinate", "visMapRegion", "visMetric", "visPie", "visTable", "visTagCloud", "visText", "visTimelion", "visVega", "visVisualBuilder", "visualizeApp", "watchesApp", "wordWrap", "wordWrapDisabled", "workplaceSearchApp", "wrench", "tokenAlias", "tokenAnnotation", "tokenArray", "tokenBinary", "tokenBoolean", "tokenClass", "tokenCompletionSuggester", "tokenConstant", "tokenDate", "tokenDenseVector", "tokenElement", "tokenEnum", "tokenEnumMember", "tokenEvent", "tokenException", "tokenField", "tokenFile", "tokenFlattened", "tokenFunction", "tokenGeo", "tokenHistogram", "tokenInterface", "tokenIP", "tokenJoin", "tokenKey", "tokenKeyword", "tokenMethod", "tokenMetricCounter", "tokenMetricGauge", "tokenModule", "tokenNamespace", "tokenNested", "tokenNull", "tokenNumber", "tokenObject", "tokenOperator", "tokenPackage", "tokenParameter", "tokenPercolator", "tokenProperty", "tokenRange", "tokenRankFeature", "tokenRankFeatures", "tokenRepo", "tokenSearchType", "tokenShape", "tokenString", "tokenStruct", "tokenSymbol", "tokenTag", "tokenText", "tokenTokenCount", "tokenVariable"]).isRequired, _propTypes.default.string.isRequired, _propTypes.default.elementType.isRequired]),
|
|
181
|
+
|
|
182
|
+
/**
|
|
183
|
+
* Can only be one side `left` or `right`
|
|
184
|
+
*/
|
|
185
|
+
iconSide: _propTypes.default.oneOfType([_propTypes.default.any.isRequired, _propTypes.default.oneOf([undefined])]),
|
|
186
|
+
|
|
187
|
+
/**
|
|
188
|
+
* Object of props passed to the <span/> wrapping the content's text/children only (not icon)
|
|
189
|
+
*/
|
|
190
|
+
textProps: _propTypes.default.shape({
|
|
191
|
+
className: _propTypes.default.string,
|
|
192
|
+
"aria-label": _propTypes.default.string,
|
|
193
|
+
"data-test-subj": _propTypes.default.string,
|
|
194
|
+
css: _propTypes.default.any,
|
|
195
|
+
ref: _propTypes.default.any,
|
|
196
|
+
"data-text": _propTypes.default.string
|
|
197
|
+
}),
|
|
198
|
+
iconSize: _propTypes.default.any,
|
|
145
199
|
className: _propTypes.default.string,
|
|
146
200
|
"aria-label": _propTypes.default.string,
|
|
147
201
|
"data-test-subj": _propTypes.default.string,
|
|
@@ -20,7 +20,7 @@ var _templateObject, _templateObject2;
|
|
|
20
20
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
21
21
|
|
|
22
22
|
var euiFlyoutSlideInRight = (0, _react.keyframes)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n 0% {\n opacity: 0;\n transform: translateX(100%);\n }\n 75% {\n opacity: 1;\n transform: translateX(0%);\n }\n"])));
|
|
23
|
-
var euiFlyoutSlideInLeft = (0, _react.keyframes)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n 0% {\n opacity: 0;\n transform: translateX(-100%);\n }\n 75% {\n opacity: 1;\n transform: translateX(0%);\n}\n"])));
|
|
23
|
+
var euiFlyoutSlideInLeft = (0, _react.keyframes)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n 0% {\n opacity: 0;\n transform: translateX(-100%);\n }\n 75% {\n opacity: 1;\n transform: translateX(0%);\n }\n"])));
|
|
24
24
|
|
|
25
25
|
var euiFlyoutCloseButtonStyles = function euiFlyoutCloseButtonStyles(euiThemeContext) {
|
|
26
26
|
var euiTheme = euiThemeContext.euiTheme;
|
|
@@ -31,8 +31,8 @@ var euiFlyoutCloseButtonStyles = function euiFlyoutCloseButtonStyles(euiThemeCon
|
|
|
31
31
|
outsideSide: {
|
|
32
32
|
// `transforms` pull in close buttons a little
|
|
33
33
|
// `!important` is necessary here to override the hover/focus transitions of buttons
|
|
34
|
-
right: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('left', 0), " ", (0, _global_styling.
|
|
35
|
-
left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('right', 0), " ", (0, _global_styling.
|
|
34
|
+
right: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('left', 0), " ", (0, _global_styling.euiMaxBreakpoint)(euiThemeContext, 'm'), "{transform:translateX(calc(-100% - ", euiTheme.size.xs, "))!important;}", (0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{transform:translateX(calc(-100% - ", euiTheme.size.l, "))!important;};label:right;"),
|
|
35
|
+
left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('right', 0), " ", (0, _global_styling.euiMaxBreakpoint)(euiThemeContext, 'm'), "{transform:translateX(calc(100% + ", euiTheme.size.xs, "))!important;}", (0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{transform:translateX(calc(100% + ", euiTheme.size.l, "))!important;};label:left;")
|
|
36
36
|
}
|
|
37
37
|
};
|
|
38
38
|
};
|
|
@@ -42,7 +42,7 @@ exports.euiFlyoutCloseButtonStyles = euiFlyoutCloseButtonStyles;
|
|
|
42
42
|
var euiFlyoutStyles = function euiFlyoutStyles(euiThemeContext) {
|
|
43
43
|
var euiTheme = euiThemeContext.euiTheme;
|
|
44
44
|
return {
|
|
45
|
-
euiFlyout: /*#__PURE__*/(0, _react.css)("position:fixed;", (0, _global_styling.logicalCSS)('top', 0), " ", (0, _global_styling.logicalCSS)('bottom', 0), " ", (0, _global_styling.logicalCSS)('height', '100%'), " z-index:", euiTheme.levels.flyout, ";background:", euiTheme.colors.emptyShade, ";display:flex;flex-direction:column;align-items:stretch;&:focus{outline:none;}", (0, _global_styling.
|
|
45
|
+
euiFlyout: /*#__PURE__*/(0, _react.css)("position:fixed;", (0, _global_styling.logicalCSS)('top', 0), " ", (0, _global_styling.logicalCSS)('bottom', 0), " ", (0, _global_styling.logicalCSS)('height', '100%'), " z-index:", euiTheme.levels.flyout, ";background:", euiTheme.colors.emptyShade, ";display:flex;flex-direction:column;align-items:stretch;&:focus{outline:none;}", (0, _global_styling.euiMaxBreakpoint)(euiThemeContext, 'm'), "{", (0, _global_styling.logicalCSS)('max-width', '90vw !important'), ";};label:euiFlyout;"),
|
|
46
46
|
// Flyout sizes
|
|
47
47
|
s: /*#__PURE__*/(0, _react.css)(composeFlyoutSizing(euiThemeContext, 's'), ";;label:s;"),
|
|
48
48
|
m: /*#__PURE__*/(0, _react.css)(composeFlyoutSizing(euiThemeContext, 'm'), ";;label:m;"),
|
|
@@ -51,7 +51,7 @@ var euiFlyoutStyles = function euiFlyoutStyles(euiThemeContext) {
|
|
|
51
51
|
// Side
|
|
52
52
|
right: /*#__PURE__*/(0, _react.css)("clip-path:polygon(-50% 0, 100% 0, 100% 100%, -50% 100%);", (0, _global_styling.logicalCSS)('right', 0), " ", _global_styling.euiCanAnimate, "{animation:", euiFlyoutSlideInRight, " ", euiTheme.animation.normal, " ", euiTheme.animation.resistance, ";};label:right;"),
|
|
53
53
|
// Left-side flyouts should only be used for navigation
|
|
54
|
-
left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('left', 0), " clip-path:polygon(0 0, 150% 0, 150% 100%, 0 100%);", _global_styling.euiCanAnimate, "{animation:", euiFlyoutSlideInLeft, ";};label:left;"),
|
|
54
|
+
left: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('left', 0), " clip-path:polygon(0 0, 150% 0, 150% 100%, 0 100%);", _global_styling.euiCanAnimate, "{animation:", euiFlyoutSlideInLeft, " ", euiTheme.animation.normal, " ", euiTheme.animation.resistance, ";};label:left;"),
|
|
55
55
|
// Type
|
|
56
56
|
overlay: /*#__PURE__*/(0, _react.css)((0, _mixins.euiShadowXLarge)(euiThemeContext), ";;label:overlay;"),
|
|
57
57
|
push: /*#__PURE__*/(0, _react.css)("clip-path:none;animation-duration:0s!important;z-index:", Number(euiTheme.levels.flyout) - 1, ";;label:push;"),
|
|
@@ -96,7 +96,7 @@ var composeFlyoutSizing = function composeFlyoutSizing(euiThemeContext, size) {
|
|
|
96
96
|
max: "".concat(euiTheme.breakpoint.l, "px")
|
|
97
97
|
}
|
|
98
98
|
};
|
|
99
|
-
return "\n ".concat((0, _global_styling.logicalCSS)('max-width', flyoutSizes[size].max), "\n\n ").concat((0, _global_styling.
|
|
99
|
+
return "\n ".concat((0, _global_styling.logicalCSS)('max-width', flyoutSizes[size].max), "\n\n ").concat((0, _global_styling.euiMaxBreakpoint)(euiThemeContext, 'm'), " {\n ").concat((0, _global_styling.logicalCSS)('min-width', 0), "\n ").concat((0, _global_styling.logicalCSS)('width', flyoutSizes[size].min), "\n }\n ").concat((0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), " {\n ").concat((0, _global_styling.logicalCSS)('min-width', flyoutSizes[size].min), "\n ").concat((0, _global_styling.logicalCSS)('width', flyoutSizes[size].width), "\n }\n ");
|
|
100
100
|
};
|
|
101
101
|
|
|
102
102
|
var composeFlyoutPadding = function composeFlyoutPadding(euiThemeContext, paddingSize) {
|
|
@@ -34,8 +34,8 @@ var euiImageWrapperStyles = function euiImageWrapperStyles(euiThemeContext) {
|
|
|
34
34
|
// Floats
|
|
35
35
|
// 1: Logical properties/values in `float` is currently not yet supported by all browsers w/o flags
|
|
36
36
|
// @see https://caniuse.com/mdn-css_properties_float_flow_relative_values for when we can remove left/right fallbacks
|
|
37
|
-
left: /*#__PURE__*/(0, _react.css)((0, _global_styling.
|
|
38
|
-
right: /*#__PURE__*/(0, _react.css)((0, _global_styling.
|
|
37
|
+
left: /*#__PURE__*/(0, _react.css)((0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{float:left;float:", _global_styling.logicalSide.left, ";", (0, _global_styling.logicalCSS)('margin-left', '0'), ";", (0, _global_styling.logicalCSS)('margin-top', '0'), ";};label:left;"),
|
|
38
|
+
right: /*#__PURE__*/(0, _react.css)((0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{float:right;float:", _global_styling.logicalSide.right, ";", (0, _global_styling.logicalCSS)('margin-right', '0'), ";", (0, _global_styling.logicalCSS)('margin-top', '0'), ";};label:right;"),
|
|
39
39
|
// Sizes
|
|
40
40
|
fullWidth: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('width', '100%'), ";;label:fullWidth;")
|
|
41
41
|
};
|
|
@@ -37,7 +37,7 @@ var euiPageStyles = function euiPageStyles(euiThemeContext) {
|
|
|
37
37
|
grow: _ref2,
|
|
38
38
|
// Direction
|
|
39
39
|
column: _ref,
|
|
40
|
-
row: /*#__PURE__*/(0, _react.css)("flex-direction:column;", (0, _global_styling.
|
|
40
|
+
row: /*#__PURE__*/(0, _react.css)("flex-direction:column;", (0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{flex-direction:row;};label:row;"),
|
|
41
41
|
// Max widths
|
|
42
42
|
restrictWidth: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalCSS)('margin-horizontal', 'auto'), ";;label:restrictWidth;")
|
|
43
43
|
};
|
|
@@ -15,17 +15,17 @@ function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(
|
|
|
15
15
|
|
|
16
16
|
var euiGlobalToastListStyles = function euiGlobalToastListStyles(euiThemeContext) {
|
|
17
17
|
var euiTheme = euiThemeContext.euiTheme;
|
|
18
|
-
var euiToastWidth = euiTheme.base *
|
|
18
|
+
var euiToastWidth = euiTheme.base * 25;
|
|
19
19
|
return {
|
|
20
20
|
/**
|
|
21
21
|
* 1. Allow list to expand as items are added, but cap it at the screen height.
|
|
22
22
|
* 2. Allow some padding for shadow
|
|
23
23
|
*/
|
|
24
24
|
// Base
|
|
25
|
-
euiGlobalToastList: /*#__PURE__*/(0, _react.css)((0, _global_styling.euiScrollBarStyles)(euiThemeContext), " display:flex;flex-direction:column;align-items:stretch;position:fixed;z-index:", euiTheme.levels.toast, ";", (0, _global_styling.logicalCSS)('bottom', 0), ";", (0, _global_styling.logicalCSS)('width', "".concat(euiToastWidth
|
|
25
|
+
euiGlobalToastList: /*#__PURE__*/(0, _react.css)((0, _global_styling.euiScrollBarStyles)(euiThemeContext), " display:flex;flex-direction:column;align-items:stretch;position:fixed;z-index:", euiTheme.levels.toast, ";", (0, _global_styling.logicalCSS)('bottom', 0), ";", (0, _global_styling.logicalCSS)('width', "".concat(euiToastWidth, "px")), ";", (0, _global_styling.logicalCSS)('max-height', '100vh'), ";", (0, _global_styling.logicalCSSWithFallback)('overflow-y', 'auto'), ";scrollbar-width:none;&::-webkit-scrollbar{", (0, _global_styling.logicalSizeCSS)(0, 0), ";}&:not(:empty){", (0, _global_styling.logicalCSS)('padding-left', euiTheme.size.base), ";", (0, _global_styling.logicalCSS)('padding-right', euiTheme.size.base), ";", (0, _global_styling.logicalCSS)('padding-vertical', euiTheme.size.base), ";}", (0, _global_styling.euiMaxBreakpoint)(euiThemeContext, 'm'), "{&:not(:empty){", (0, _global_styling.logicalCSS)('left', 0), ";", (0, _global_styling.logicalCSS)('width', '100%'), ";}};label:euiGlobalToastList;"),
|
|
26
26
|
// Variants
|
|
27
|
-
right: /*#__PURE__*/(0, _react.css)("&:not(:empty){", (0, _global_styling.logicalCSS)('right', 0), ";", (0, _global_styling.
|
|
28
|
-
left: /*#__PURE__*/(0, _react.css)("&:not(:empty){", (0, _global_styling.logicalCSS)('left', 0), ";", (0, _global_styling.
|
|
27
|
+
right: /*#__PURE__*/(0, _react.css)("&:not(:empty){", (0, _global_styling.logicalCSS)('right', 0), ";", (0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{", (0, _global_styling.logicalCSS)('padding-left', "".concat(euiTheme.base * 4, "px")), ";}};label:right;"),
|
|
28
|
+
left: /*#__PURE__*/(0, _react.css)("&:not(:empty){", (0, _global_styling.logicalCSS)('left', 0), ";", (0, _global_styling.euiMinBreakpoint)(euiThemeContext, 'm'), "{", (0, _global_styling.logicalCSS)('padding-right', "".concat(euiTheme.base * 4, "px")), ";}};label:left;")
|
|
29
29
|
};
|
|
30
30
|
};
|
|
31
31
|
|
|
@@ -66,7 +66,7 @@ var euiOverflowShadowStyles = function euiOverflowShadowStyles(_ref3) {
|
|
|
66
66
|
|
|
67
67
|
var direction = _direction || 'y';
|
|
68
68
|
var side = _side || 'both';
|
|
69
|
-
var hideHeight =
|
|
69
|
+
var hideHeight = size.s;
|
|
70
70
|
var gradientStart = "\n ".concat((0, _color.transparentize)('red', 0.1), " 0%,\n ").concat((0, _color.transparentize)('red', 1), " ").concat(hideHeight, "\n ");
|
|
71
71
|
var gradientEnd = "\n ".concat((0, _color.transparentize)('red', 1), " calc(100% - ").concat(hideHeight, "),\n ").concat((0, _color.transparentize)('red', 0.1), " 100%\n ");
|
|
72
72
|
var gradient = '';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.useEuiBreakpoint = exports.euiBreakpoint = void 0;
|
|
6
|
+
exports.useEuiMinBreakpoint = exports.useEuiMaxBreakpoint = exports.useEuiBreakpoint = exports.euiMinBreakpoint = exports.euiMaxBreakpoint = exports.euiBreakpoint = void 0;
|
|
7
7
|
|
|
8
8
|
var _sorting = require("../../services/breakpoint/_sorting");
|
|
9
9
|
|
|
@@ -18,7 +18,7 @@ var _hooks = require("../../services/theme/hooks");
|
|
|
18
18
|
*/
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
|
-
* Generates a CSS media query rule string based on the input breakpoint ranges
|
|
21
|
+
* Generates a CSS media query rule string based on the input breakpoint *ranges*.
|
|
22
22
|
* Examples with default theme breakpoints:
|
|
23
23
|
*
|
|
24
24
|
* euiBreakpoint(['s']) becomes `@media only screen and (min-width: 575px) and (max-width: 767px)`
|
|
@@ -60,5 +60,62 @@ var useEuiBreakpoint = function useEuiBreakpoint(sizes) {
|
|
|
60
60
|
var euiTheme = (0, _hooks.useEuiTheme)();
|
|
61
61
|
return euiBreakpoint(euiTheme, sizes);
|
|
62
62
|
};
|
|
63
|
+
/**
|
|
64
|
+
* Min/Max width breakpoint utilities that generate only a single min/max query/bound
|
|
65
|
+
*
|
|
66
|
+
* *Unlike the above euiBreakpoint utility*, these utilities treat breakpoint
|
|
67
|
+
* sizes as a one-dimensional point, rather than a two-dimensional *screen range*.
|
|
68
|
+
* Examples with default theme breakpoints:
|
|
69
|
+
*
|
|
70
|
+
* euiMaxBreakpoint('m') becomes `@media only screen and (max-width: 767px)`
|
|
71
|
+
* euiMinBreakpoint('m') becomes `@media only screen and (min-width: 768px)`
|
|
72
|
+
*
|
|
73
|
+
* This is safer and more intentional to use than euiBreakpoint(['xs', 's']) / euiBreakpoint(['m', 'xl'])
|
|
74
|
+
* in the event that consumers add larger or smaller custom breakpoints (e.g 'xxs' or `xxl`)
|
|
75
|
+
* and if the intention of the media query is actually "m and below/above" vs. "only screens m/l/xl".
|
|
76
|
+
*/
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
exports.useEuiBreakpoint = useEuiBreakpoint;
|
|
80
|
+
|
|
81
|
+
var euiMinBreakpoint = function euiMinBreakpoint(_ref2, size) {
|
|
82
|
+
var euiTheme = _ref2.euiTheme;
|
|
83
|
+
var minBreakpointSize = euiTheme.breakpoint[size];
|
|
84
|
+
|
|
85
|
+
if (minBreakpointSize) {
|
|
86
|
+
return "@media only screen and (min-width: ".concat(minBreakpointSize, "px)");
|
|
87
|
+
} else {
|
|
88
|
+
console.warn("Invalid min breakpoint size: ".concat(size));
|
|
89
|
+
return '@media only screen';
|
|
90
|
+
}
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
exports.euiMinBreakpoint = euiMinBreakpoint;
|
|
94
|
+
|
|
95
|
+
var useEuiMinBreakpoint = function useEuiMinBreakpoint(size) {
|
|
96
|
+
var euiTheme = (0, _hooks.useEuiTheme)();
|
|
97
|
+
return euiMinBreakpoint(euiTheme, size);
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
exports.useEuiMinBreakpoint = useEuiMinBreakpoint;
|
|
101
|
+
|
|
102
|
+
var euiMaxBreakpoint = function euiMaxBreakpoint(_ref3, size) {
|
|
103
|
+
var euiTheme = _ref3.euiTheme;
|
|
104
|
+
var maxBreakpointSize = euiTheme.breakpoint[size];
|
|
105
|
+
|
|
106
|
+
if (maxBreakpointSize) {
|
|
107
|
+
return "@media only screen and (max-width: ".concat(maxBreakpointSize - 1, "px)");
|
|
108
|
+
} else {
|
|
109
|
+
console.warn("Invalid max breakpoint size: ".concat(size));
|
|
110
|
+
return '@media only screen';
|
|
111
|
+
}
|
|
112
|
+
};
|
|
113
|
+
|
|
114
|
+
exports.euiMaxBreakpoint = euiMaxBreakpoint;
|
|
115
|
+
|
|
116
|
+
var useEuiMaxBreakpoint = function useEuiMaxBreakpoint(size) {
|
|
117
|
+
var euiTheme = (0, _hooks.useEuiTheme)();
|
|
118
|
+
return euiMaxBreakpoint(euiTheme, size);
|
|
119
|
+
};
|
|
63
120
|
|
|
64
|
-
exports.
|
|
121
|
+
exports.useEuiMaxBreakpoint = useEuiMaxBreakpoint;
|
|
@@ -146,6 +146,7 @@ export var EuiButtonDisplayDeprecated = /*#__PURE__*/forwardRef(function (_ref,
|
|
|
146
146
|
|
|
147
147
|
if (minWidth !== undefined || minWidth !== null) {
|
|
148
148
|
calculatedStyle = _objectSpread(_objectSpread({}, calculatedStyle), {}, {
|
|
149
|
+
// @ts-ignore - deprecated component
|
|
149
150
|
minWidth: minWidth
|
|
150
151
|
});
|
|
151
152
|
}
|
|
@@ -68,7 +68,7 @@ export var EuiButtonDisplay = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
68
68
|
var theme = useEuiTheme();
|
|
69
69
|
var styles = euiButtonDisplayStyles(theme);
|
|
70
70
|
var buttonRadiusStyle = useEuiButtonRadiusCSS()[size];
|
|
71
|
-
var cssStyles = [styles.euiButtonDisplay, styles[size], fullWidth && styles.fullWidth, buttonIsDisabled && styles.isDisabled, buttonRadiusStyle];
|
|
71
|
+
var cssStyles = [styles.euiButtonDisplay, styles[size], fullWidth && styles.fullWidth, minWidth == null && styles.defaultMinWidth, buttonIsDisabled && styles.isDisabled, buttonRadiusStyle];
|
|
72
72
|
|
|
73
73
|
var innerNode = ___EmotionJSX(EuiButtonDisplayContent, _extends({
|
|
74
74
|
isLoading: isLoading,
|
|
@@ -105,7 +105,7 @@ export var EuiButtonDisplay = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
105
105
|
|
|
106
106
|
return createElement(element, _objectSpread(_objectSpread(_objectSpread({
|
|
107
107
|
css: cssStyles,
|
|
108
|
-
style: minWidth
|
|
108
|
+
style: minWidth ? _objectSpread(_objectSpread({}, style), {}, {
|
|
109
109
|
minInlineSize: minWidth
|
|
110
110
|
}) : style,
|
|
111
111
|
ref: ref
|
|
@@ -32,10 +32,11 @@ export var euiButtonDisplayStyles = function euiButtonDisplayStyles(euiThemeCont
|
|
|
32
32
|
var euiTheme = euiThemeContext.euiTheme;
|
|
33
33
|
return {
|
|
34
34
|
// Base
|
|
35
|
-
euiButtonDisplay: /*#__PURE__*/css(euiButtonBaseCSS(), ";
|
|
35
|
+
euiButtonDisplay: /*#__PURE__*/css(euiButtonBaseCSS(), ";font-weight:", euiTheme.font.weight.medium, ";padding:0 ", euiTheme.size.m, ";&:hover:not(:disabled),&:focus{text-decoration:underline;};label:euiButtonDisplay;"),
|
|
36
36
|
// States
|
|
37
37
|
isDisabled: _ref,
|
|
38
38
|
fullWidth: /*#__PURE__*/css("display:block;", logicalCSS('width', '100%'), ";;label:fullWidth;"),
|
|
39
|
+
defaultMinWidth: /*#__PURE__*/css(logicalCSS('min-width', "".concat(euiTheme.base * 7, "px")), ";;label:defaultMinWidth;"),
|
|
39
40
|
// Sizes
|
|
40
41
|
xs: /*#__PURE__*/css(_buttonSize(euiTheme.size.l), euiFontSize(euiThemeContext, 'xs'), ";label:xs;"),
|
|
41
42
|
s: /*#__PURE__*/css(_buttonSize(euiTheme.size.xl), euiFontSize(euiThemeContext, 's'), ";label:s;"),
|
|
@@ -163,7 +163,7 @@ export var EuiSuperUpdateButton = /*#__PURE__*/function (_Component) {
|
|
|
163
163
|
sizes: responsive || 'none'
|
|
164
164
|
}, ___EmotionJSX(EuiButton, _extends({
|
|
165
165
|
className: classes,
|
|
166
|
-
minWidth:
|
|
166
|
+
minWidth: false
|
|
167
167
|
}, sharedButtonProps, {
|
|
168
168
|
fill: fill,
|
|
169
169
|
textProps: _objectSpread(_objectSpread({}, restTextProps), {}, {
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* Side Public License, v 1.
|
|
7
7
|
*/
|
|
8
8
|
import { css } from '@emotion/react';
|
|
9
|
-
import { logicalTextAlignCSS,
|
|
9
|
+
import { logicalTextAlignCSS, euiMinBreakpoint } from '../../global_styling';
|
|
10
10
|
export var euiDescriptionListStyles = function euiDescriptionListStyles(euiThemeContext) {
|
|
11
11
|
// Flex display for column and responsive column
|
|
12
12
|
var columnDisplay = "\n display: flex;\n align-items: baseline;\n flex-wrap: wrap; \n ";
|
|
@@ -17,7 +17,7 @@ export var euiDescriptionListStyles = function euiDescriptionListStyles(euiTheme
|
|
|
17
17
|
inline: /*#__PURE__*/css(";label:inline;"),
|
|
18
18
|
column: /*#__PURE__*/css(columnDisplay, ";;label:column;"),
|
|
19
19
|
// Responsive columns behave as a row on breakpoints xs-s
|
|
20
|
-
responsiveColumn: /*#__PURE__*/css(
|
|
20
|
+
responsiveColumn: /*#__PURE__*/css(euiMinBreakpoint(euiThemeContext, 'm'), "{", columnDisplay, ";};label:responsiveColumn;"),
|
|
21
21
|
// Alignment
|
|
22
22
|
center: /*#__PURE__*/css(logicalTextAlignCSS('center'), ";;label:center;"),
|
|
23
23
|
left: /*#__PURE__*/css(logicalTextAlignCSS('left'), ";;label:left;")
|
|
@@ -12,7 +12,7 @@ var _excluded = ["children", "className"];
|
|
|
12
12
|
*/
|
|
13
13
|
import React, { useContext } from 'react';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
|
-
import { useEuiTheme } from '../../services';
|
|
15
|
+
import { useEuiTheme, useIsWithinMinBreakpoint } from '../../services';
|
|
16
16
|
import { euiDescriptionListDescriptionStyles } from './description_list_description.styles';
|
|
17
17
|
import { EuiDescriptionListContext } from './description_list_context'; // Export required for correct inference by HOCs
|
|
18
18
|
|
|
@@ -29,6 +29,7 @@ export var EuiDescriptionListDescription = function EuiDescriptionListDescriptio
|
|
|
29
29
|
align = _useContext.align,
|
|
30
30
|
gutterSize = _useContext.gutterSize;
|
|
31
31
|
|
|
32
|
+
var showResponsiveColumns = useIsWithinMinBreakpoint('m');
|
|
32
33
|
var theme = useEuiTheme();
|
|
33
34
|
var styles = euiDescriptionListDescriptionStyles(theme);
|
|
34
35
|
var conditionalStyles = compressed && textStyle === 'reverse' ? [styles.fontStyles.compressed] : [styles.fontStyles[textStyle]];
|
|
@@ -44,7 +45,10 @@ export var EuiDescriptionListDescription = function EuiDescriptionListDescriptio
|
|
|
44
45
|
conditionalStyles.push(styles.left);
|
|
45
46
|
}
|
|
46
47
|
|
|
47
|
-
|
|
48
|
+
if (type === 'column' || showResponsiveColumns) {
|
|
49
|
+
conditionalStyles.push(styles[gutterSize]);
|
|
50
|
+
}
|
|
51
|
+
|
|
48
52
|
break;
|
|
49
53
|
}
|
|
50
54
|
|
|
@@ -8,7 +8,7 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
8
8
|
* Side Public License, v 1.
|
|
9
9
|
*/
|
|
10
10
|
import { css } from '@emotion/react';
|
|
11
|
-
import { euiFontSize,
|
|
11
|
+
import { euiFontSize, euiMaxBreakpoint, euiMinBreakpoint, logicalTextAlignCSS, logicalCSS } from '../../global_styling';
|
|
12
12
|
import { euiTitle } from '../title/title.styles';
|
|
13
13
|
|
|
14
14
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
@@ -28,7 +28,7 @@ export var euiDescriptionListDescriptionStyles = function euiDescriptionListDesc
|
|
|
28
28
|
// Types
|
|
29
29
|
row: /*#__PURE__*/css(";label:row;"),
|
|
30
30
|
column: /*#__PURE__*/css(columnDisplay, ";;label:column;"),
|
|
31
|
-
responsiveColumn: /*#__PURE__*/css(
|
|
31
|
+
responsiveColumn: /*#__PURE__*/css(euiMaxBreakpoint(euiThemeContext, 'm'), "{", logicalCSS('width', '100%'), " padding:0;}", euiMinBreakpoint(euiThemeContext, 'm'), "{", columnDisplay, ";};label:responsiveColumn;"),
|
|
32
32
|
inline: _ref,
|
|
33
33
|
// This nested block handles just the font styling based on compressed and reverse
|
|
34
34
|
fontStyles: {
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* Side Public License, v 1.
|
|
7
7
|
*/
|
|
8
8
|
import { css } from '@emotion/react';
|
|
9
|
-
import { euiFontSize, euiTextBreakWord, logicalTextAlignCSS,
|
|
9
|
+
import { euiFontSize, euiTextBreakWord, logicalTextAlignCSS, euiMaxBreakpoint, euiMinBreakpoint, logicalCSS } from '../../global_styling';
|
|
10
10
|
import { tint } from '../../services';
|
|
11
11
|
import { euiTitle } from '../title/title.styles';
|
|
12
12
|
export var euiDescriptionListTitleStyles = function euiDescriptionListTitleStyles(euiThemeContext) {
|
|
@@ -18,7 +18,7 @@ export var euiDescriptionListTitleStyles = function euiDescriptionListTitleStyle
|
|
|
18
18
|
// Types
|
|
19
19
|
row: /*#__PURE__*/css(";label:row;"),
|
|
20
20
|
column: /*#__PURE__*/css(columnDisplay, ";;label:column;"),
|
|
21
|
-
responsiveColumn: /*#__PURE__*/css(
|
|
21
|
+
responsiveColumn: /*#__PURE__*/css(euiMaxBreakpoint(euiThemeContext, 'm'), "{", logicalCSS('width', '100%'), " padding:0;}", euiMinBreakpoint(euiThemeContext, 'm'), "{", columnDisplay, ";};label:responsiveColumn;"),
|
|
22
22
|
inline: /*#__PURE__*/css("display:inline;border-radius:", euiTheme.border.radius.small, ";font-weight:", euiTheme.font.weight.medium, ";background-color:", colorMode === 'DARK' ? tint(euiTheme.colors.lightestShade, 0.5) : euiTheme.colors.lightestShade, ";", logicalCSS('margin-vertical', '0'), " ", logicalCSS('margin-horizontal', euiTheme.size.xs), "&:first-of-type{", logicalCSS('margin-left', '0'), ";};label:inline;"),
|
|
23
23
|
// This nested block handles just the font styling based on compressed and reverse
|
|
24
24
|
fontStyles: {
|
|
@@ -10,12 +10,12 @@ var _templateObject, _templateObject2;
|
|
|
10
10
|
* Side Public License, v 1.
|
|
11
11
|
*/
|
|
12
12
|
import { css, keyframes } from '@emotion/react';
|
|
13
|
-
import { euiCanAnimate,
|
|
13
|
+
import { euiCanAnimate, euiMaxBreakpoint, euiMinBreakpoint, logicalCSS, mathWithUnits } from '../../global_styling';
|
|
14
14
|
import { euiShadowXLarge } from '../../themes/amsterdam/global_styling/mixins';
|
|
15
15
|
import { transparentize } from '../../services/color';
|
|
16
16
|
import { euiFormMaxWidth } from '../form/form.styles';
|
|
17
17
|
var euiFlyoutSlideInRight = keyframes(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n 0% {\n opacity: 0;\n transform: translateX(100%);\n }\n 75% {\n opacity: 1;\n transform: translateX(0%);\n }\n"])));
|
|
18
|
-
var euiFlyoutSlideInLeft = keyframes(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n 0% {\n opacity: 0;\n transform: translateX(-100%);\n }\n 75% {\n opacity: 1;\n transform: translateX(0%);\n}\n"])));
|
|
18
|
+
var euiFlyoutSlideInLeft = keyframes(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n 0% {\n opacity: 0;\n transform: translateX(-100%);\n }\n 75% {\n opacity: 1;\n transform: translateX(0%);\n }\n"])));
|
|
19
19
|
export var euiFlyoutCloseButtonStyles = function euiFlyoutCloseButtonStyles(euiThemeContext) {
|
|
20
20
|
var euiTheme = euiThemeContext.euiTheme;
|
|
21
21
|
return {
|
|
@@ -25,15 +25,15 @@ export var euiFlyoutCloseButtonStyles = function euiFlyoutCloseButtonStyles(euiT
|
|
|
25
25
|
outsideSide: {
|
|
26
26
|
// `transforms` pull in close buttons a little
|
|
27
27
|
// `!important` is necessary here to override the hover/focus transitions of buttons
|
|
28
|
-
right: /*#__PURE__*/css(logicalCSS('left', 0), " ",
|
|
29
|
-
left: /*#__PURE__*/css(logicalCSS('right', 0), " ",
|
|
28
|
+
right: /*#__PURE__*/css(logicalCSS('left', 0), " ", euiMaxBreakpoint(euiThemeContext, 'm'), "{transform:translateX(calc(-100% - ", euiTheme.size.xs, "))!important;}", euiMinBreakpoint(euiThemeContext, 'm'), "{transform:translateX(calc(-100% - ", euiTheme.size.l, "))!important;};label:right;"),
|
|
29
|
+
left: /*#__PURE__*/css(logicalCSS('right', 0), " ", euiMaxBreakpoint(euiThemeContext, 'm'), "{transform:translateX(calc(100% + ", euiTheme.size.xs, "))!important;}", euiMinBreakpoint(euiThemeContext, 'm'), "{transform:translateX(calc(100% + ", euiTheme.size.l, "))!important;};label:left;")
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
32
|
};
|
|
33
33
|
export var euiFlyoutStyles = function euiFlyoutStyles(euiThemeContext) {
|
|
34
34
|
var euiTheme = euiThemeContext.euiTheme;
|
|
35
35
|
return {
|
|
36
|
-
euiFlyout: /*#__PURE__*/css("position:fixed;", logicalCSS('top', 0), " ", logicalCSS('bottom', 0), " ", logicalCSS('height', '100%'), " z-index:", euiTheme.levels.flyout, ";background:", euiTheme.colors.emptyShade, ";display:flex;flex-direction:column;align-items:stretch;&:focus{outline:none;}",
|
|
36
|
+
euiFlyout: /*#__PURE__*/css("position:fixed;", logicalCSS('top', 0), " ", logicalCSS('bottom', 0), " ", logicalCSS('height', '100%'), " z-index:", euiTheme.levels.flyout, ";background:", euiTheme.colors.emptyShade, ";display:flex;flex-direction:column;align-items:stretch;&:focus{outline:none;}", euiMaxBreakpoint(euiThemeContext, 'm'), "{", logicalCSS('max-width', '90vw !important'), ";};label:euiFlyout;"),
|
|
37
37
|
// Flyout sizes
|
|
38
38
|
s: /*#__PURE__*/css(composeFlyoutSizing(euiThemeContext, 's'), ";;label:s;"),
|
|
39
39
|
m: /*#__PURE__*/css(composeFlyoutSizing(euiThemeContext, 'm'), ";;label:m;"),
|
|
@@ -42,7 +42,7 @@ export var euiFlyoutStyles = function euiFlyoutStyles(euiThemeContext) {
|
|
|
42
42
|
// Side
|
|
43
43
|
right: /*#__PURE__*/css("clip-path:polygon(-50% 0, 100% 0, 100% 100%, -50% 100%);", logicalCSS('right', 0), " ", euiCanAnimate, "{animation:", euiFlyoutSlideInRight, " ", euiTheme.animation.normal, " ", euiTheme.animation.resistance, ";};label:right;"),
|
|
44
44
|
// Left-side flyouts should only be used for navigation
|
|
45
|
-
left: /*#__PURE__*/css(logicalCSS('left', 0), " clip-path:polygon(0 0, 150% 0, 150% 100%, 0 100%);", euiCanAnimate, "{animation:", euiFlyoutSlideInLeft, ";};label:left;"),
|
|
45
|
+
left: /*#__PURE__*/css(logicalCSS('left', 0), " clip-path:polygon(0 0, 150% 0, 150% 100%, 0 100%);", euiCanAnimate, "{animation:", euiFlyoutSlideInLeft, " ", euiTheme.animation.normal, " ", euiTheme.animation.resistance, ";};label:left;"),
|
|
46
46
|
// Type
|
|
47
47
|
overlay: /*#__PURE__*/css(euiShadowXLarge(euiThemeContext), ";;label:overlay;"),
|
|
48
48
|
push: /*#__PURE__*/css("clip-path:none;animation-duration:0s!important;z-index:", Number(euiTheme.levels.flyout) - 1, ";;label:push;"),
|
|
@@ -85,7 +85,7 @@ var composeFlyoutSizing = function composeFlyoutSizing(euiThemeContext, size) {
|
|
|
85
85
|
max: "".concat(euiTheme.breakpoint.l, "px")
|
|
86
86
|
}
|
|
87
87
|
};
|
|
88
|
-
return "\n ".concat(logicalCSS('max-width', flyoutSizes[size].max), "\n\n ").concat(
|
|
88
|
+
return "\n ".concat(logicalCSS('max-width', flyoutSizes[size].max), "\n\n ").concat(euiMaxBreakpoint(euiThemeContext, 'm'), " {\n ").concat(logicalCSS('min-width', 0), "\n ").concat(logicalCSS('width', flyoutSizes[size].min), "\n }\n ").concat(euiMinBreakpoint(euiThemeContext, 'm'), " {\n ").concat(logicalCSS('min-width', flyoutSizes[size].min), "\n ").concat(logicalCSS('width', flyoutSizes[size].width), "\n }\n ");
|
|
89
89
|
};
|
|
90
90
|
|
|
91
91
|
var composeFlyoutPadding = function composeFlyoutPadding(euiThemeContext, paddingSize) {
|
|
@@ -8,7 +8,7 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
8
8
|
* Side Public License, v 1.
|
|
9
9
|
*/
|
|
10
10
|
import { css } from '@emotion/react';
|
|
11
|
-
import {
|
|
11
|
+
import { euiMinBreakpoint, logicalCSS, logicalTextAlignCSS, logicalSide } from '../../global_styling';
|
|
12
12
|
|
|
13
13
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
14
14
|
name: "gacnmc-allowFullScreen",
|
|
@@ -33,8 +33,8 @@ export var euiImageWrapperStyles = function euiImageWrapperStyles(euiThemeContex
|
|
|
33
33
|
// Floats
|
|
34
34
|
// 1: Logical properties/values in `float` is currently not yet supported by all browsers w/o flags
|
|
35
35
|
// @see https://caniuse.com/mdn-css_properties_float_flow_relative_values for when we can remove left/right fallbacks
|
|
36
|
-
left: /*#__PURE__*/css(
|
|
37
|
-
right: /*#__PURE__*/css(
|
|
36
|
+
left: /*#__PURE__*/css(euiMinBreakpoint(euiThemeContext, 'm'), "{float:left;float:", logicalSide.left, ";", logicalCSS('margin-left', '0'), ";", logicalCSS('margin-top', '0'), ";};label:left;"),
|
|
37
|
+
right: /*#__PURE__*/css(euiMinBreakpoint(euiThemeContext, 'm'), "{float:right;float:", logicalSide.right, ";", logicalCSS('margin-right', '0'), ";", logicalCSS('margin-top', '0'), ";};label:right;"),
|
|
38
38
|
// Sizes
|
|
39
39
|
fullWidth: /*#__PURE__*/css(logicalCSS('width', '100%'), ";;label:fullWidth;")
|
|
40
40
|
};
|
|
@@ -8,7 +8,7 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
8
8
|
* Side Public License, v 1.
|
|
9
9
|
*/
|
|
10
10
|
import { css } from '@emotion/react';
|
|
11
|
-
import {
|
|
11
|
+
import { euiMinBreakpoint, logicalCSS } from '../../global_styling';
|
|
12
12
|
|
|
13
13
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
14
14
|
name: "ll8kmq-column",
|
|
@@ -36,7 +36,7 @@ export var euiPageStyles = function euiPageStyles(euiThemeContext) {
|
|
|
36
36
|
grow: _ref2,
|
|
37
37
|
// Direction
|
|
38
38
|
column: _ref,
|
|
39
|
-
row: /*#__PURE__*/css("flex-direction:column;",
|
|
39
|
+
row: /*#__PURE__*/css("flex-direction:column;", euiMinBreakpoint(euiThemeContext, 'm'), "{flex-direction:row;};label:row;"),
|
|
40
40
|
// Max widths
|
|
41
41
|
restrictWidth: /*#__PURE__*/css(logicalCSS('margin-horizontal', 'auto'), ";;label:restrictWidth;")
|
|
42
42
|
};
|
|
@@ -10,20 +10,20 @@ var _templateObject;
|
|
|
10
10
|
* Side Public License, v 1.
|
|
11
11
|
*/
|
|
12
12
|
import { css, keyframes } from '@emotion/react';
|
|
13
|
-
import {
|
|
13
|
+
import { euiMaxBreakpoint, euiMinBreakpoint, euiScrollBarStyles, logicalCSS, logicalCSSWithFallback, logicalSizeCSS } from '../../global_styling';
|
|
14
14
|
export var euiGlobalToastListStyles = function euiGlobalToastListStyles(euiThemeContext) {
|
|
15
15
|
var euiTheme = euiThemeContext.euiTheme;
|
|
16
|
-
var euiToastWidth = euiTheme.base *
|
|
16
|
+
var euiToastWidth = euiTheme.base * 25;
|
|
17
17
|
return {
|
|
18
18
|
/**
|
|
19
19
|
* 1. Allow list to expand as items are added, but cap it at the screen height.
|
|
20
20
|
* 2. Allow some padding for shadow
|
|
21
21
|
*/
|
|
22
22
|
// Base
|
|
23
|
-
euiGlobalToastList: /*#__PURE__*/css(euiScrollBarStyles(euiThemeContext), " display:flex;flex-direction:column;align-items:stretch;position:fixed;z-index:", euiTheme.levels.toast, ";", logicalCSS('bottom', 0), ";", logicalCSS('width', "".concat(euiToastWidth
|
|
23
|
+
euiGlobalToastList: /*#__PURE__*/css(euiScrollBarStyles(euiThemeContext), " display:flex;flex-direction:column;align-items:stretch;position:fixed;z-index:", euiTheme.levels.toast, ";", logicalCSS('bottom', 0), ";", logicalCSS('width', "".concat(euiToastWidth, "px")), ";", logicalCSS('max-height', '100vh'), ";", logicalCSSWithFallback('overflow-y', 'auto'), ";scrollbar-width:none;&::-webkit-scrollbar{", logicalSizeCSS(0, 0), ";}&:not(:empty){", logicalCSS('padding-left', euiTheme.size.base), ";", logicalCSS('padding-right', euiTheme.size.base), ";", logicalCSS('padding-vertical', euiTheme.size.base), ";}", euiMaxBreakpoint(euiThemeContext, 'm'), "{&:not(:empty){", logicalCSS('left', 0), ";", logicalCSS('width', '100%'), ";}};label:euiGlobalToastList;"),
|
|
24
24
|
// Variants
|
|
25
|
-
right: /*#__PURE__*/css("&:not(:empty){", logicalCSS('right', 0), ";", logicalCSS('padding-left', "".concat(euiTheme.base * 4, "px")), ";}
|
|
26
|
-
left: /*#__PURE__*/css("&:not(:empty){", logicalCSS('left', 0), ";", logicalCSS('padding-right', "".concat(euiTheme.base * 4, "px")), ";}
|
|
25
|
+
right: /*#__PURE__*/css("&:not(:empty){", logicalCSS('right', 0), ";", euiMinBreakpoint(euiThemeContext, 'm'), "{", logicalCSS('padding-left', "".concat(euiTheme.base * 4, "px")), ";}};label:right;"),
|
|
26
|
+
left: /*#__PURE__*/css("&:not(:empty){", logicalCSS('left', 0), ";", euiMinBreakpoint(euiThemeContext, 'm'), "{", logicalCSS('padding-right', "".concat(euiTheme.base * 4, "px")), ";}};label:left;")
|
|
27
27
|
};
|
|
28
28
|
};
|
|
29
29
|
export var euiGlobalToastListItemStyles = function euiGlobalToastListItemStyles(_ref) {
|
|
@@ -55,7 +55,7 @@ var euiOverflowShadowStyles = function euiOverflowShadowStyles(_ref3) {
|
|
|
55
55
|
|
|
56
56
|
var direction = _direction || 'y';
|
|
57
57
|
var side = _side || 'both';
|
|
58
|
-
var hideHeight =
|
|
58
|
+
var hideHeight = size.s;
|
|
59
59
|
var gradientStart = "\n ".concat(transparentize('red', 0.1), " 0%,\n ").concat(transparentize('red', 1), " ").concat(hideHeight, "\n ");
|
|
60
60
|
var gradientEnd = "\n ".concat(transparentize('red', 1), " calc(100% - ").concat(hideHeight, "),\n ").concat(transparentize('red', 0.1), " 100%\n ");
|
|
61
61
|
var gradient = '';
|