Skip to content

Commit 2952ac8

Browse files
authored
Merge pull request #406 from acelaya-forks/feature/reduce-margins
Feature/reduce margins
2 parents c3d6c83 + cf4fc4f commit 2952ac8

File tree

7 files changed

+28
-23
lines changed

7 files changed

+28
-23
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org).
66

7-
## [Unreleased]
7+
## [3.1.0] - 2021-03-29
88
### Added
99
* [#379](https://github.com/shlinkio/shlink-web-client/issues/379) and [#384](https://github.com/shlinkio/shlink-web-client/issues/384) Improved QR code modal, including controls to customize size, format and margin, as well as a button to copy the link to the clipboard.
1010
* [#385](https://github.com/shlinkio/shlink-web-client/issues/385) Added setting to determine if "validate URL" should be enabled or disabled by default.

src/servers/CreateServer.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ const CreateServer = (ImportServersBtn: FC<ImportServersBtnProps>, useStateFlagT
4242
</ServerForm>
4343

4444
{(serversImported || errorImporting) && (
45-
<div className="mt-4">
45+
<div className="mt-3">
4646
{serversImported && <ImportResult type="success" />}
4747
{errorImporting && <ImportResult type="error" />}
4848
</div>

src/servers/Overview.tsx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { FC, useEffect } from 'react';
2-
import { Card, CardBody, CardHeader, CardText, CardTitle } from 'reactstrap';
2+
import { Card, CardBody, CardHeader, CardText, CardTitle, Row } from 'reactstrap';
33
import { Link, useHistory } from 'react-router-dom';
44
import { ShortUrlsListParams } from '../short-urls/reducers/shortUrlsListParams';
55
import { ShortUrlsList as ShortUrlsListState } from '../short-urls/reducers/shortUrlsList';
@@ -51,9 +51,9 @@ export const Overview = (
5151

5252
return (
5353
<>
54-
<div className="row mb-3">
54+
<Row>
5555
<div className="col-md-6 col-xl-3">
56-
<Card className="overview__card mb-2" body>
56+
<Card className="overview__card mb-3" body>
5757
<CardTitle tag="h5" className="overview__card-title">Visits</CardTitle>
5858
<CardText tag="h2">
5959
<ForServerVersion minVersion="2.2.0">
@@ -66,7 +66,7 @@ export const Overview = (
6666
</Card>
6767
</div>
6868
<div className="col-md-6 col-xl-3">
69-
<Card className="overview__card mb-2" body tag={Link} to={`/server/${serverId}/orphan-visits`}>
69+
<Card className="overview__card mb-3" body tag={Link} to={`/server/${serverId}/orphan-visits`}>
7070
<CardTitle tag="h5" className="overview__card-title">Orphan visits</CardTitle>
7171
<CardText tag="h2">
7272
<ForServerVersion minVersion="2.6.0">
@@ -79,21 +79,21 @@ export const Overview = (
7979
</Card>
8080
</div>
8181
<div className="col-md-6 col-xl-3">
82-
<Card className="overview__card mb-2" body tag={Link} to={`/server/${serverId}/list-short-urls/1`}>
82+
<Card className="overview__card mb-3" body tag={Link} to={`/server/${serverId}/list-short-urls/1`}>
8383
<CardTitle tag="h5" className="overview__card-title">Short URLs</CardTitle>
8484
<CardText tag="h2">
8585
{loading ? 'Loading...' : prettify(shortUrls?.pagination.totalItems ?? 0)}
8686
</CardText>
8787
</Card>
8888
</div>
8989
<div className="col-md-6 col-xl-3">
90-
<Card className="overview__card mb-2" body tag={Link} to={`/server/${serverId}/manage-tags`}>
90+
<Card className="overview__card mb-3" body tag={Link} to={`/server/${serverId}/manage-tags`}>
9191
<CardTitle tag="h5" className="overview__card-title">Tags</CardTitle>
9292
<CardText tag="h2">{loadingTags ? 'Loading...' : prettify(tagsList.tags.length)}</CardText>
9393
</Card>
9494
</div>
95-
</div>
96-
<Card className="mb-4">
95+
</Row>
96+
<Card className="mb-3">
9797
<CardHeader>
9898
<span className="d-sm-none">Create a short URL</span>
9999
<h5 className="d-none d-sm-inline">Create a short URL</h5>

src/servers/helpers/ServerForm.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export const ServerForm: FC<ServerFormProps> = ({ onSubmit, initialValues, child
2525

2626
return (
2727
<form className="server-form" onSubmit={handleSubmit}>
28-
<SimpleCard className="mb-4" title={title}>
28+
<SimpleCard className="mb-3" title={title}>
2929
<FormGroupContainer value={name} onChange={setName}>Name</FormGroupContainer>
3030
<FormGroupContainer type="url" value={url} onChange={setUrl}>URL</FormGroupContainer>
3131
<FormGroupContainer value={apiKey} onChange={setApiKey}>API key</FormGroupContainer>

src/settings/Settings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const SettingsSections: FC<{ items: ReactNode[][] }> = ({ items }) => (
77
{items.map((child, index) => (
88
<Row key={index}>
99
{child.map((subChild, subIndex) => (
10-
<div key={subIndex} className="col-lg-6 mb-3 mb-md-4">
10+
<div key={subIndex} className="col-lg-6 mb-3">
1111
{subChild}
1212
</div>
1313
))}

src/utils/DateInput.scss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,11 @@
7171
color: inherit;
7272
}
7373

74+
.react-datepicker__day--disabled.react-datepicker__day--disabled {
75+
cursor: default;
76+
color: var(--border-color) !important;
77+
}
78+
7479
.react-datepicker__day--keyboard-selected.react-datepicker__day--keyboard-selected,
7580
.react-datepicker__month-text--keyboard-selected.react-datepicker__month-text--keyboard-selected,
7681
.react-datepicker__quarter-text--keyboard-selected.react-datepicker__quarter-text--keyboard-selected,

src/visits/VisitsStats.tsx

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ const VisitsStats: FC<VisitsStatsProps> = (
154154
<Row>
155155
<Switch>
156156
<Route exact path={baseUrl}>
157-
<div className="col-12 mt-4">
157+
<div className="col-12 mt-3">
158158
<LineChartCard
159159
title="Visits during time"
160160
visits={normalizedVisits}
@@ -166,13 +166,13 @@ const VisitsStats: FC<VisitsStatsProps> = (
166166
</Route>
167167

168168
<Route exact path={`${baseUrl}${sections.byContext.subPath}`}>
169-
<div className={classNames('mt-4 col-lg-6', { 'col-xl-4': !isOrphanVisits })}>
169+
<div className={classNames('mt-3 col-lg-6', { 'col-xl-4': !isOrphanVisits })}>
170170
<GraphCard title="Operating systems" stats={os} />
171171
</div>
172-
<div className={classNames('mt-4 col-lg-6', { 'col-xl-4': !isOrphanVisits })}>
172+
<div className={classNames('mt-3 col-lg-6', { 'col-xl-4': !isOrphanVisits })}>
173173
<GraphCard title="Browsers" stats={browsers} />
174174
</div>
175-
<div className={classNames('mt-4', { 'col-xl-4': !isOrphanVisits, 'col-lg-6': isOrphanVisits })}>
175+
<div className={classNames('mt-3', { 'col-xl-4': !isOrphanVisits, 'col-lg-6': isOrphanVisits })}>
176176
<SortableBarGraph
177177
title="Referrers"
178178
stats={referrers}
@@ -187,7 +187,7 @@ const VisitsStats: FC<VisitsStatsProps> = (
187187
/>
188188
</div>
189189
{isOrphanVisits && (
190-
<div className="mt-4 col-lg-6">
190+
<div className="mt-3 col-lg-6">
191191
<SortableBarGraph
192192
title="Visited URLs"
193193
stats={visitedUrls}
@@ -204,7 +204,7 @@ const VisitsStats: FC<VisitsStatsProps> = (
204204
</Route>
205205

206206
<Route exact path={`${baseUrl}${sections.byLocation.subPath}`}>
207-
<div className="col-lg-6 mt-4">
207+
<div className="col-lg-6 mt-3">
208208
<SortableBarGraph
209209
title="Countries"
210210
stats={countries}
@@ -217,7 +217,7 @@ const VisitsStats: FC<VisitsStatsProps> = (
217217
onClick={highlightVisitsForProp('country')}
218218
/>
219219
</div>
220-
<div className="col-lg-6 mt-4">
220+
<div className="col-lg-6 mt-3">
221221
<SortableBarGraph
222222
title="Cities"
223223
stats={cities}
@@ -258,7 +258,7 @@ const VisitsStats: FC<VisitsStatsProps> = (
258258
<>
259259
{children}
260260

261-
<section className="mt-4">
261+
<section className="mt-3">
262262
<div className="row flex-md-row-reverse">
263263
<div className="col-lg-7 col-xl-6">
264264
<div className="d-md-flex">
@@ -273,15 +273,15 @@ const VisitsStats: FC<VisitsStatsProps> = (
273273
{isOrphanVisits && (
274274
<OrphanVisitTypeDropdown
275275
text="Filter by type"
276-
className="ml-0 ml-md-2 mt-4 mt-md-0"
276+
className="ml-0 ml-md-2 mt-3 mt-md-0"
277277
selected={orphanVisitType}
278278
onChange={setOrphanVisitType}
279279
/>
280280
)}
281281
</div>
282282
</div>
283283
{visits.length > 0 && (
284-
<div className="col-lg-5 col-xl-6 mt-4 mt-lg-0">
284+
<div className="col-lg-5 col-xl-6 mt-3 mt-lg-0">
285285
<div className="d-flex">
286286
<Button
287287
outline
@@ -305,7 +305,7 @@ const VisitsStats: FC<VisitsStatsProps> = (
305305
</div>
306306
</section>
307307

308-
<section className="mt-4">
308+
<section className="mt-3">
309309
{renderVisitsContent()}
310310
</section>
311311
</>

0 commit comments

Comments
 (0)