|
1 | 1 | import React, { ChangeEventHandler, useState, useMemo } from 'react';
|
2 |
| -import styled from 'styled-components'; |
| 2 | +import styled, { css } from 'styled-components'; |
3 | 3 | import { useLocation, match, Link, useHistory } from 'react-router-dom';
|
4 | 4 | import { useTranslation } from 'react-i18next';
|
5 | 5 | import { getPath, getRouteMatch, KnownURLParams } from '../../utils/routing';
|
@@ -376,24 +376,30 @@ export function findAdditionalButtons(routeMatch: match<KnownURLParams> | null,
|
376 | 376 | // Styles
|
377 | 377 | //
|
378 | 378 |
|
| 379 | +const ContainerBaseStyle = css` |
| 380 | + border: var(--breadcrumb-border); |
| 381 | + height: var(--breadcrumb-height); |
| 382 | + background: var(--breadcrumb-bg); |
| 383 | +`; |
| 384 | + |
379 | 385 | const BreadcrumbGroup = styled.div`
|
380 | 386 | ${ButtonCSS}
|
381 |
| - border: var(--breadcrumb-border); |
| 387 | + ${ContainerBaseStyle} |
382 | 388 | width: 100%;
|
383 | 389 | `;
|
384 | 390 |
|
385 | 391 | const BreadcrumbEmptyInput = styled(InputWrapper)`
|
386 |
| - border: var(--breadcrumb-border); |
| 392 | + ${ContainerBaseStyle} |
387 | 393 |
|
388 | 394 | input {
|
389 | 395 | padding-left: 0;
|
390 | 396 | margin-left: -0.25rem;
|
391 |
| - font-size: var(--breadcrumb-input-font-size); |
392 |
| - font-weight: var(--breadcrumb-input-font-weight); |
| 397 | + font-size: var(--breadcrumb-font-size); |
| 398 | + font-weight: var(--breadcrumb-font-weight); |
393 | 399 |
|
394 | 400 | &::placeholder {
|
395 | 401 | color: var(--breadcrumb-placeholder-color);
|
396 |
| - font-weight: var(--breadcrumb-input-font-weight); |
| 402 | + font-weight: var(--breadcrumb-font-weight); |
397 | 403 | }
|
398 | 404 | }
|
399 | 405 | `;
|
@@ -450,22 +456,21 @@ const StyledBreadcrumb = styled(ItemRow)`
|
450 | 456 | line-height: var(--breadcrumb-line-height);
|
451 | 457 | font-size: var(--breadcrumb-font-size);
|
452 | 458 | font-weight: var(--breadcrumb-font-weight);
|
453 |
| - background: var(--input-bg); |
| 459 | + background: var(--breadcrumb-bg); |
454 | 460 | color: var(--input-text-color);
|
455 | 461 | padding-left: 0;
|
456 | 462 | margin-left: -0.25rem;
|
457 | 463 | }
|
458 | 464 | `;
|
459 | 465 |
|
460 | 466 | const BreadcrumbInputWrapper = styled(InputWrapper)`
|
461 |
| - border: var(--breadcrumb-border); |
| 467 | + ${ContainerBaseStyle} |
462 | 468 | `;
|
463 | 469 |
|
464 | 470 | const GoToHolder = styled.div`
|
465 | 471 | position: relative;
|
466 | 472 | font-size: var(--font-size-primary);
|
467 |
| - height: 2rem; |
468 |
| - margin-top: -0.5625rem; |
| 473 | + height: var(--breadcrumb-height); |
469 | 474 | z-index: 2;
|
470 | 475 | width: 100%;
|
471 | 476 | `;
|
|
0 commit comments