Ensured consistent heights in settings cards

This commit is contained in:
Alejandro Celaya 2021-03-06 17:30:21 +01:00
parent e380ddb40f
commit e76b22b2ae
5 changed files with 6 additions and 6 deletions

View file

@ -15,7 +15,7 @@ const intervalValue = (interval?: number) => !interval ? '' : `${interval}`;
const RealTimeUpdates = (
{ settings: { realTimeUpdates }, toggleRealTimeUpdates, setRealTimeUpdatesInterval }: RealTimeUpdatesProps,
) => (
<SimpleCard title="Real-time updates">
<SimpleCard title="Real-time updates" className="h-100">
<FormGroup>
<ToggleSwitch checked={realTimeUpdates.enabled} onChange={toggleRealTimeUpdates}>
Enable or disable real-time updates, when using Shlink v2.2.0 or newer.

View file

@ -7,8 +7,8 @@ const SettingsSections: FC<{ items: ReactNode[][] }> = ({ items }) => (
{items.map((child, index) => (
<Row key={index}>
{child.map((subChild, subIndex) => (
<div key={subIndex} className="col-lg-6">
<div className="mb-3 mb-md-4">{subChild}</div>
<div key={subIndex} className="col-lg-6 mb-3 mb-md-4">
{subChild}
</div>
))}
</Row>

View file

@ -12,7 +12,7 @@ interface ShortUrlCreationProps {
export const ShortUrlCreation: FC<ShortUrlCreationProps> = (
{ settings: { shortUrlCreation }, setShortUrlCreationSettings },
) => (
<SimpleCard title="Short URLs creation">
<SimpleCard title="Short URLs creation" className="h-100">
<FormGroup className="mb-0">
<ToggleSwitch
checked={shortUrlCreation?.validateUrls ?? false}

View file

@ -13,7 +13,7 @@ interface UserInterfaceProps {
}
export const UserInterface: FC<UserInterfaceProps> = ({ settings: { ui }, setUiSettings }) => (
<SimpleCard title="User interface">
<SimpleCard title="User interface" className="h-100">
<FontAwesomeIcon icon={ui?.theme === 'dark' ? faMoon : faSun} className="user-interface__theme-icon" />
<ToggleSwitch
checked={ui?.theme === 'dark'}

View file

@ -10,7 +10,7 @@ interface VisitsProps {
}
export const Visits: FC<VisitsProps> = ({ settings, setVisitsSettings }) => (
<SimpleCard title="Visits">
<SimpleCard title="Visits" className="h-100">
<FormGroup className="mb-0">
<label>Default interval to load on visits sections:</label>
<DateIntervalSelector