* Remove 1920px max width * Fix position of list controls menu * Match size and color of search input * Adjust library header sizing * Move app menu to sidebar * Increase row buffer on play queue list * Fix query builder styles * Fix playerbar slider track bg * Adjust titlebar styles * Fix invalid modal prop * Various adjustments to detail pages * Fix sidebar height calculation * Fix list null indicators, add filter indicator * Adjust playqueue styles * Fix jellyfin releaseYear normalization * Suppress browser context menu on ag-grid * Add radius to drawer queue -- normalize layout * Add modal styles to provider theme * Fix playlist song list pagination * Add disc number to albums with more than one disc * Fix query builder boolean values * Adjust input placeholder color * Properly handle rating/favorite from context menu on table * Conform dropdown menu styles to context menu * Increase sort type select width * Fix drawer queue radius * Change primary color * Prevent volume wheel from invalid values * Add icons to query builder dropdowns * Update notification styles * Update scrollbar thumb styles * Remove "add to playlist" on smart playlists * Fix "add to playlist" from context menu
63 lines
1.2 KiB
TypeScript
63 lines
1.2 KiB
TypeScript
import type { ReactNode } from 'react';
|
|
import { Group } from '@mantine/core';
|
|
import styled from 'styled-components';
|
|
import { WindowControls } from '../../window-controls';
|
|
|
|
interface TitlebarProps {
|
|
children?: ReactNode;
|
|
}
|
|
|
|
const TitlebarContainer = styled.div`
|
|
display: flex;
|
|
flex-direction: row;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
color: var(--titlebar-fg);
|
|
|
|
button {
|
|
-webkit-app-region: no-drag;
|
|
}
|
|
`;
|
|
|
|
// const Left = styled.div`
|
|
// display: flex;
|
|
// flex: 1/3;
|
|
// justify-content: center;
|
|
// height: 100%;
|
|
// padding-left: 1rem;
|
|
// opacity: 0;
|
|
// `;
|
|
|
|
// const Center = styled.div`
|
|
// display: flex;
|
|
// flex: 1/3;
|
|
// justify-content: center;
|
|
// height: 100%;
|
|
// opacity: 0;
|
|
// `;
|
|
|
|
const Right = styled.div`
|
|
display: flex;
|
|
flex: 1/3;
|
|
justify-content: center;
|
|
height: 100%;
|
|
`;
|
|
|
|
export const Titlebar = ({ children }: TitlebarProps) => {
|
|
return (
|
|
<>
|
|
<TitlebarContainer>
|
|
<Right>
|
|
{children}
|
|
<Group spacing="xs">
|
|
<WindowControls />
|
|
</Group>
|
|
</Right>
|
|
</TitlebarContainer>
|
|
</>
|
|
);
|
|
};
|
|
|
|
Titlebar.defaultProps = {
|
|
children: undefined,
|
|
};
|